idx int64 0 165k | question stringlengths 73 4.15k | target stringlengths 5 918 | len_question int64 21 890 | len_target int64 3 255 |
|---|---|---|---|---|
159,100 | private Session createSession ( Properties props ) throws InvalidPasswordDecodingException , UnsupportedCryptoAlgorithmException { Session session = null ; // Since the password attribute in the server.xml is masked // the decryption algorythm is needed to before it can be put // it into the props object. if ( sessionP... | The createSession method creates a session using the props if the password is specified in the server . xml then a session is creating using the password . If it is not specified then session is created with out a authenticator . | 280 | 44 |
159,101 | @ Reference ( service = MailSessionRegistrar . class , policy = ReferencePolicy . DYNAMIC , cardinality = ReferenceCardinality . OPTIONAL , target = "(component.name=com.ibm.ws.javamail.management.j2ee.MailSessionRegistrarImpl)" ) protected void setMailSessionRegistrar ( ServiceReference < MailSessionRegistrar > ref ) ... | Declarative Services method for setting mail session registrar | 112 | 11 |
159,102 | void reset ( long time , long latest , AlarmListener listener , Object context , long index ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "reset" , new Object [ ] { new Long ( time ) , new Long ( latest ) , listener , context , new Long ( index ) } ) ; data = listen... | reset this alarm s values | 177 | 5 |
159,103 | public static synchronized void init ( HpelTraceServiceConfig config ) { if ( config == null ) throw new NullPointerException ( "LogProviderConfig must not be null" ) ; loggingConfig . compareAndSet ( null , config ) ; } | Initializes HPEL Configuration proxy | 52 | 6 |
159,104 | @ Override public Exception getLinkedException ( ) { //return (Exception) getCause(); Throwable t = getCause ( ) ; while ( t != null ) { if ( t instanceof Exception ) { return ( Exception ) t ; } else { t = t . getCause ( ) ; } } return null ; } | Retrieve the exception that was saved away | 68 | 8 |
159,105 | public synchronized void lock ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "lock" , this ) ; boolean interrupted = false ; // Attempt to get a lock on the mutex. // if we fail, then that is because the lock // must be held exclusively. while ( ! tryLock ( ) ) try { // Wait for 1 second then try again. if (... | This method allows multiple lockers to lock the same mutex until the lock exclusive is called . Then all lock requesters have to wait until the exclusive lock is released . | 174 | 34 |
159,106 | private boolean tryLock ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "tryLock" , this ) ; boolean result = false ; synchronized ( iMutex ) { // Check that we aren't exclusively locked. if ( ! iExclusivelyLocked || iExclusiveLockHolder == Thread . currentThread ( ) ) { incrementThreadLockCount ( ) ; result ... | This method increments a the number of locks that have been obtained . | 125 | 13 |
159,107 | private void incrementThreadLockCount ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "incrementThreadLockCount" , this ) ; //get the current thread Thread currentThread = Thread . currentThread ( ) ; //get it's current read lock count LockCount count = ( LockCount ) readerThreads . get ( currentThread ) ; //... | The mutex must be held before calling this method . | 173 | 11 |
159,108 | private boolean alienReadLocksHeld ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "alienReadLocksHeld" , this ) ; boolean locksHeld = false ; //if there is more than one thread holding read locks then return true if ( readerThreadCount > 1 ) { locksHeld = true ; } //if there is exactly one thread holding a r... | The mutex must be help before calling this method . | 236 | 11 |
159,109 | private boolean tryLockExclusive ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "tryLockExclusive" , this ) ; boolean result = false ; // Synchronize on the locking Mutex synchronized ( iMutex ) { // If it isn't already locked - lock it on this thread. if ( ! iExclusivelyLocked ) { // Block new many lock req... | This method attempts to lock the exclusively and won t succeed until it has the exclusive lock . | 318 | 18 |
159,110 | public synchronized void unlockExclusive ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "unlockExclusive" , this ) ; // Synchronize on the locking Mutex. synchronized ( iMutex ) { // Only release the lock if the holder is the current thread. if ( Thread . currentThread ( ) == iExclusiveLockHolder ) { if ( tc... | This method unlocks the exclusive lock that was held . | 276 | 10 |
159,111 | public static void init ( ExternalContext context ) { WebXmlParser parser = new WebXmlParser ( context ) ; WebXml webXml = parser . parse ( ) ; context . getApplicationMap ( ) . put ( WEB_XML_ATTR , webXml ) ; MyfacesConfig mfconfig = MyfacesConfig . getCurrentInstance ( context ) ; long configRefreshPeriod = mfconfig ... | should be called when initialising Servlet | 162 | 8 |
159,112 | private static void filterThrowable ( Throwable t ) { // Now we want to remove the superfluous lines of stack trace from the // exception (those that have been inserted as a result of the way we // created the exception. StackTraceElement [ ] stackLines = t . getStackTrace ( ) ; // If there is definitely something to w... | This method filters the stack trace of the parameter object to remove all trace of the newThrowable and reflection calls that have been made . | 402 | 27 |
159,113 | public static Throwable getJMS2Exception ( JMSException jmse , Class exceptionToBeThrown ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getJMS2Exceptions" , new Object [ ] { jmse , exceptionToBeThrown } ) ; JMSRuntimeException jmsre = null ; try { jmsre = ( JMSRunti... | This is a generic function to convert all the JMS 1 . 1 exceptions to JMS 2 . 0 exception . It uses reflection to create the desired JMS2 . 0 exception | 344 | 36 |
159,114 | private boolean isProductExtensionInstalled ( String inputString , String productExtension ) { if ( ( productExtension == null ) || ( inputString == null ) ) { return false ; } int msgIndex = inputString . indexOf ( "CWWKF0012I: The server installed the following features:" ) ; if ( msgIndex == - 1 ) { return false ; }... | Determine if the input product extension exists in the input string . | 229 | 14 |
159,115 | public static String encodePartiallyEncoded ( String encoded , boolean query ) { if ( encoded . length ( ) == 0 ) { return encoded ; } Matcher m = ENCODE_PATTERN . matcher ( encoded ) ; if ( ! m . find ( ) ) { return query ? HttpUtils . queryEncode ( encoded ) : HttpUtils . pathEncode ( encoded ) ; } int length = encod... | Encodes partially encoded string . Encode all values but those matching pattern percent char followed by two hexadecimal digits . | 251 | 25 |
159,116 | @ Override public String formatRecord ( RepositoryLogRecord record , Locale locale ) { if ( null == record ) { throw new IllegalArgumentException ( "Record cannot be null" ) ; } return getFormattedRecord ( record , locale ) ; } | Formats a RepositoryLogRecord into a localized CBE format output String . | 54 | 16 |
159,117 | public String getFormattedRecord ( RepositoryLogRecord record , Locale locale ) { StringBuilder sb = new StringBuilder ( 300 ) ; //create opening tag for the CBE Event createEventOTag ( sb , record , locale ) ; //add the CBE elements createExtendedElement ( sb , record ) ; createExtendedElement ( sb , "CommonBaseEventL... | Gets a String representation of a log record as a CBEEvent XML element | 665 | 16 |
159,118 | private void createEventOTag ( StringBuilder sb , RepositoryLogRecord record , Locale locale ) { sb . append ( "<CommonBaseEvent creationTime=\"" ) ; // create the XML dateTime format // TimeZone is UTC, but since we are dealing with Millis we are already in UTC. sb . append ( CBE_DATE_FORMAT . format ( record . getMil... | Appends the opening tag of a CommonBaseEvent XML element to a string buffer | 296 | 16 |
159,119 | private void createSituationElement ( StringBuilder sb ) { sb . append ( lineSeparator ) . append ( INDENT [ 0 ] ) . append ( "<situation categoryName=\"ReportSituation\">" ) ; sb . append ( lineSeparator ) . append ( INDENT [ 1 ] ) . append ( "<situationType xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:... | Appends the CBE Situation XML element of a record to a String buffer | 153 | 15 |
159,120 | private void createSourceElement ( StringBuilder sb , RepositoryLogRecord record ) { String hostAddr = headerProps . getProperty ( ServerInstanceLogRecordList . HEADER_HOSTADDRESS ) == null ? "" : headerProps . getProperty ( ServerInstanceLogRecordList . HEADER_HOSTADDRESS ) ; String hostType = headerProps . getPropert... | Appends the CBE Source XML element of a record to a String buffer | 388 | 15 |
159,121 | private void createMessageElement ( StringBuilder sb , RepositoryLogRecord record ) { // 660484 elim string concat sb . append ( lineSeparator ) . append ( INDENT [ 0 ] ) . append ( "<msgDataElement msgLocale=\"" ) . append ( record . getMessageLocale ( ) ) . append ( "\">" ) ; if ( record . getParameters ( ) != null )... | Appends the CBE Message Element XML element of a record to a String buffer | 553 | 16 |
159,122 | private void createExtendedElement ( StringBuilder sb , RepositoryLogRecord record ) { sb . append ( lineSeparator ) . append ( INDENT [ 0 ] ) . append ( "<extendedDataElements name=\"CommonBaseEventLogRecord:level\" type=\"noValue\">" ) ; sb . append ( lineSeparator ) . append ( INDENT [ 1 ] ) . append ( "<children na... | Appends the CBE Extended Data Element of a record to a String buffer | 336 | 15 |
159,123 | private void createExtendedElement ( StringBuilder sb , RepositoryLogRecord record , String extensionID ) { String edeValue = record . getExtension ( extensionID ) ; if ( edeValue != null && ! edeValue . isEmpty ( ) ) { createExtendedElement ( sb , extensionID , "string" , edeValue ) ; } } | Appends the CBE Extended Data Element of a record s extension to a String buffer | 79 | 17 |
159,124 | private void createExtendedElement ( StringBuilder sb , String edeName , String edeType , String edeValues ) { sb . append ( lineSeparator ) . append ( INDENT [ 0 ] ) . append ( "<extendedDataElements name=\"" ) . append ( edeName ) . append ( "\" type=\"" ) . append ( edeType ) . append ( "\">" ) ; sb . append ( lineS... | Prints and extendedDataElement for CBE output Formatter s time zone . | 166 | 16 |
159,125 | private static Cookie constructLTPACookieObj ( SingleSignonToken ssoToken ) { byte [ ] ssoTokenBytes = ssoToken . getBytes ( ) ; String ssoCookieString = Base64Coder . base64EncodeToString ( ssoTokenBytes ) ; Cookie cookie = new Cookie ( webAppSecConfig . getSSOCookieName ( ) , ssoCookieString ) ; return cookie ; } | builds an LTPACookie object | 91 | 8 |
159,126 | static Cookie getLTPACookie ( final Subject subject ) throws Exception { Cookie ltpaCookie = null ; SingleSignonToken ssoToken = null ; Set < SingleSignonToken > ssoTokens = subject . getPrivateCredentials ( SingleSignonToken . class ) ; Iterator < SingleSignonToken > ssoTokensIterator = ssoTokens . iterator ( ) ; if (... | Gets the LTPA cookie from the given subject | 224 | 10 |
159,127 | public static Cookie getSSOCookieFromSSOToken ( ) throws Exception { Subject subject = null ; Cookie ltpaCookie = null ; if ( webAppSecConfig == null ) { // if we don't have the config, we can't construct the cookie return null ; } try { subject = WSSubject . getRunAsSubject ( ) ; if ( subject == null ) { subject = WSS... | Extracts an LTPA sso cookie from the subject of current thread and builds a ltpa cookie out of it for use on downstream web invocations . The caller must check for null return value only when not null that getName and getValue can be invoked on the returned Cookie object | 209 | 59 |
159,128 | private ReturnCode packageServerDumps ( File packageFile , List < String > javaDumps ) { DumpProcessor processor = new DumpProcessor ( serverName , packageFile , bootProps , javaDumps ) ; return processor . execute ( ) ; } | Creates an archive containing the server dumps server configurations . | 56 | 11 |
159,129 | void deregister ( List < URL > urls ) { for ( URL url : urls ) { _data . remove ( url . getFile ( ) ) ; } } | Remove mappings for the provided urls . | 36 | 9 |
159,130 | void register ( URL url , InMemoryMappingFile immf ) { _data . put ( url . getFile ( ) , immf ) ; } | Register the URL mapping to the provided InMemoryMappingFile . | 32 | 13 |
159,131 | private boolean isMatchingString ( String value1 , String value2 ) { boolean valuesMatch = true ; if ( value1 == null ) { if ( value2 != null ) { valuesMatch = false ; } } else { valuesMatch = value1 . equals ( value2 ) ; } return valuesMatch ; } | Compare two string values . | 65 | 5 |
159,132 | private List < Class < ? > > getListenerInterfaces ( ) { List < Class < ? > > listenerInterfaces = new ArrayList < Class < ? > > ( Arrays . asList ( SERVLET30_LISTENER_INTERFACES ) ) ; // Condition the HTTP ID Listener on Servlet 3.1 enablement. if ( com . ibm . ws . webcontainer . osgi . WebContainer . getServletConta... | Obtain the list of enabled listener interfaces . The list contents depends on servlet 3 . 1 enablement . | 350 | 22 |
159,133 | public void configureWebAppHelperFactory ( WebAppConfiguratorHelperFactory webAppConfiguratorHelperFactory , ResourceRefConfigFactory resourceRefConfigFactory ) { webAppHelper = webAppConfiguratorHelperFactory . createWebAppConfiguratorHelper ( this , resourceRefConfigFactory , getListenerInterfaces ( ) ) ; this . conf... | Configure the WebApp helper factory | 82 | 7 |
159,134 | public < T > void validateDuplicateKeyValueConfiguration ( String parentElementName , String keyElementName , String keyElementValue , String valueElementName , T newValue , ConfigItem < T > priorConfigItem ) { T priorValue = priorConfigItem . getValue ( ) ; if ( priorValue == null ) { if ( newValue == null ) { return ... | Validate configuration items which are elements of keyed collections in two configurations . | 536 | 15 |
159,135 | public void validateDuplicateDefaultErrorPageConfiguration ( String newLocation , ConfigItem < String > priorLocationItem ) { String priorLocation = priorLocationItem . getValue ( ) ; if ( priorLocation == null ) { if ( newLocation == null ) { return ; // Same null Location; ignore } else { // Different Locations: null... | Validate default error page configuration items . | 471 | 8 |
159,136 | @ SuppressWarnings ( "unchecked" ) public < T > Map < String , ConfigItem < T > > getConfigItemMap ( String key ) { Map < String , ConfigItem < T > > configItemMap = ( Map < String , ConfigItem < T > > ) attributes . get ( key ) ; if ( configItemMap == null ) { configItemMap = new HashMap < String , ConfigItem < T > > ... | Obtain an attribute value as a mapping . Create and return a new empty mapping if one is not yet present . | 157 | 23 |
159,137 | @ SuppressWarnings ( "unchecked" ) public < T > Set < T > getContextSet ( String key ) { Set < T > set = ( Set < T > ) attributes . get ( key ) ; if ( set == null ) { set = new HashSet < T > ( ) ; attributes . put ( key , set ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( ... | Obtain an attribute value as a sset . Create and return a new empty set if one is not yet present . | 122 | 24 |
159,138 | public < T > ConfigItem < T > createConfigItem ( T value , MergeComparator < T > comparator ) { return new ConfigItemImpl < T > ( value , getConfigSource ( ) , getLibraryURI ( ) , comparator ) ; } | Create a configuration item using the current source . | 54 | 9 |
159,139 | public boolean isExpired ( ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "isExpired" ) ; boolean expired = false ; long curTime = System . currentTimeMillis ( ) ; //TODO: if ( curTime - _leaseTime > _leaseTimeout * 1000 ) // 30 seconds default for timeout { if ( tc . isDebugEnabled ( ) ) Tr . debug ( tc , "Lease... | Has the peer expired? | 217 | 5 |
159,140 | protected void returnToFreePool ( MCWrapper mcWrapper ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( this , tc , "returnToFreePool" , gConfigProps . cfName ) ; } if ( mcWrapper . shouldBeDestroyed ( ) || mcWrapper . hasFatalErrorNotificationOccurred ( fatalErrorNotificatio... | Return the mcWrapper to the free pool . | 624 | 10 |
159,141 | protected void removeMCWrapperFromList ( MCWrapper mcWrapper , boolean removeFromFreePool , boolean synchronizationNeeded , boolean skipWaiterNotify , boolean decrementTotalCounter ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( this , tc , "removeMCWrapperFromList" ) ; } /... | This method will try to cleanup and destroy the connection and remove the mcWrapper from the free pool . | 451 | 21 |
159,142 | protected void removeParkedConnection ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( this , tc , "removeParkedConnection" ) ; } // boolean errorOccured = false; if ( pm . parkedMCWrapper != null ) { // Only attempt to cleanup and destroy the parked MC if one exists... sy... | Remove the parked managed connection . This method should only be called if do not have SmartHandleSupport in effect . The PoolManager controls the SmartHandleSupported flag so we have to trust the PM not to call this method when smart handles is in effect . | 527 | 50 |
159,143 | protected void removeCleanupAndDestroyAllFreeConnections ( ) { // removed iterator code // This method is called within a synchronize block if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( this , tc , "removeCleanupAndDestroyAllFreeConnections" ) ; } int mcWrapperListIndex = mcW... | Remove the mcWrappers from the arraylist . Cleanup and destroy the managed connections . | 222 | 18 |
159,144 | protected void cleanupAndDestroyAllFreeConnections ( ) { // This method is called within a synchronize block if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( this , tc , "cleanupAndDestroyAllFreeConnections" ) ; } int mcWrapperListIndex = mcWrapperList . size ( ) - 1 ; for ( int... | During server shutdown try to cleanup and destroy the managed connections nicely . This method should only be called during server server shutdown . | 248 | 24 |
159,145 | protected void incrementFatalErrorValue ( int value1 ) { /* * value1 and value2 are index values for the free pools. * When value1 and value2 are 0, we are in free pool . */ if ( fatalErrorNotificationTime == Integer . MAX_VALUE - 1 ) { /* * We need to start over at zero. All connection * fatal error values need to be ... | This method should only be called when a fatal error occurs or when an attempt is made to remove all of the connections from the pool . | 325 | 27 |
159,146 | @ Trivial public static < K > UserConverter < K > newInstance ( Converter < K > converter ) { return newInstance ( getType ( converter ) , converter ) ; } | Construct a new PriorityConverter using discovered or default type and priority | 41 | 14 |
159,147 | @ Trivial public static < K > UserConverter < K > newInstance ( Type type , Converter < K > converter ) { return newInstance ( type , getPriority ( converter ) , converter ) ; } | Construct a new PriorityConverter using discovered or default priority | 47 | 12 |
159,148 | @ Trivial private static Type getType ( Converter < ? > converter ) { Type type = null ; Type [ ] itypes = converter . getClass ( ) . getGenericInterfaces ( ) ; for ( Type itype : itypes ) { ParameterizedType ptype = ( ParameterizedType ) itype ; if ( ptype . getRawType ( ) == Converter . class ) { Type [ ] atypes = pt... | Reflectively work out the Type of a Converter | 240 | 11 |
159,149 | @ Trivial public static File deleteWithRetry ( File file ) { String methodName = "deleteWithRetry" ; String filePath ; if ( tc . isDebugEnabled ( ) ) { filePath = file . getAbsolutePath ( ) ; Tr . debug ( tc , methodName + ": Recursively delete [ " + filePath + " ]" ) ; } else { filePath = null ; } File firstFailure = ... | Attempt to recursively delete a target file . | 400 | 10 |
159,150 | @ Trivial public static File delete ( File file ) { String methodName = "delete" ; String filePath ; if ( tc . isDebugEnabled ( ) ) { filePath = file . getAbsolutePath ( ) ; } else { filePath = null ; } if ( file . isDirectory ( ) ) { if ( filePath != null ) { Tr . debug ( tc , methodName + ": Delete directory [ " + fi... | Attempt to recursively delete a file . | 368 | 9 |
159,151 | public static void unzip ( File source , File target , boolean isEar , long lastModified ) throws IOException { byte [ ] transferBuffer = new byte [ 16 * 1024 ] ; unzip ( source , target , isEar , lastModified , transferBuffer ) ; } | Unpack a source archive into a target directory . | 58 | 10 |
159,152 | public static ELResolver makeResolverForJSP ( ) { Map < String , ImplicitObject > forJSPList = new HashMap < String , ImplicitObject > ( 8 ) ; //4 ImplicitObject io1 = new FacesContextImplicitObject ( ) ; forJSPList . put ( io1 . getName ( ) , io1 ) ; ImplicitObject io2 = new ViewImplicitObject ( ) ; forJSPList . put (... | Static factory for an ELResolver for resolving implicit objects in JSPs . See JSF 1 . 2 spec section 5 . 6 . 1 . 1 | 192 | 31 |
159,153 | public static ELResolver makeResolverForFaces ( ) { Map < String , ImplicitObject > forFacesList = new HashMap < String , ImplicitObject > ( 30 ) ; //14 ImplicitObject io1 = new ApplicationImplicitObject ( ) ; forFacesList . put ( io1 . getName ( ) , io1 ) ; ImplicitObject io2 = new ApplicationScopeImplicitObject ( ) ;... | Static factory for an ELResolver for resolving implicit objects in all of Faces . See JSF 1 . 2 spec section 5 . 6 . 1 . 2 | 695 | 31 |
159,154 | public void parse ( WsByteBuffer transmissionData ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "parse" , transmissionData ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) JFapUtils . debugTraceWsByteBufferInfo ( this , tc , tran... | Parses a chunk of inbound data into discrete transmissions . The headers for these transmissions are decoded and the payload data is dispatched to the appropriate method for processing . | 666 | 34 |
159,155 | private void parsePrimaryOnlyPayload ( WsByteBuffer contextBuffer ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "parsePrimaryOnlyPayload" , contextBuffer ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) JFapUtils . debugTraceWsBy... | Invoked to parse a primary header payload structure from the supplied buffer . May be invoked multiple times to incrementally parse the structure . Once the structure has been fully parsed transitions the state machine into the appropriate next state based on the layout of the transmission . | 704 | 50 |
159,156 | private void parseConversationPayload ( WsByteBuffer contextBuffer ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "parseConversationPayload" , contextBuffer ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) JFapUtils . debugTraceWs... | Invoked to parse a conversation payload structure from the supplied buffer . May be invoked multiple times to incrementally parse the structure . Once the structure has been fully parsed transitions the state machine into the appropriate next state based on the layout of the transmission . | 471 | 49 |
159,157 | private void parseSegmentStartPayload ( WsByteBuffer contextBuffer ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "parseSegmentStartPayload" , contextBuffer ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) JFapUtils . debugTraceWs... | Invoked to parse a segmented transmission start payload from the supplied buffer . May be invoked multiple times to incrementally parse the structure . Once the structure has been fully parsed transitions the state machine into the appropriate next state based on the layout of the transmission . | 797 | 51 |
159,158 | private boolean dispatchToConnection ( WsByteBuffer data ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "dispatchToConnection" , data ) ; //@stoptracescan@ if ( TraceComponent . isAnyTracingEnabled ( ) ) JFapUtils . debugSummaryMessage ( tc , connection , null... | Dispatches a payload to the appropriate connection for processing . The implication of dispatching to a connection is that the payload did not have a conversation header on its transmission . | 245 | 34 |
159,159 | private void reset ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "reset" ) ; throwable = null ; state = STATE_PARSING_PRIMARY_HEADER ; unparsedPrimaryHeader . position ( 0 ) ; unparsedPrimaryHeader . limit ( JFapChannelConstants . SIZEOF_PRIMARY_HEADER ) ; ... | Resets the state of the parsing state machine so that it is read to parse another transmission . | 234 | 19 |
159,160 | private WsByteBuffer readData ( WsByteBuffer unparsedData , WsByteBuffer scratchArea ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "readData" , new Object [ ] { unparsedData , scratchArea } ) ; int scratchAreaRemaining = scratchArea . remaining ( ) ; int scra... | Reads data from a buffer into a scratch area . | 250 | 11 |
159,161 | @ SuppressWarnings ( "unchecked" ) private Object createManagedBean ( final ManagedBean managedBean , final FacesContext facesContext ) throws ELException { final ExternalContext extContext = facesContext . getExternalContext ( ) ; final Map < Object , Object > facesContextMap = facesContext . getAttributes ( ) ; final... | adapted from Manfred s JSF 1 . 1 VariableResolverImpl | 291 | 15 |
159,162 | public Object run ( ) { Thread currentThread = Thread . currentThread ( ) ; oldClassLoader = threadContextAccessor . getContextClassLoader ( currentThread ) ; // 369927 // The following tests are done in a certain order to maximize performance if ( newClassLoader == oldClassLoader ) { wasChanged = false ; } else if ( (... | 146064 . 3 | 168 | 5 |
159,163 | public static final boolean isPassword ( String name ) { return PASSWORD_PROPS . contains ( name ) || name . toLowerCase ( ) . contains ( DataSourceDef . password . name ( ) ) ; } | Determines based on the name of a property if we expect the value might contain a password . | 46 | 20 |
159,164 | public static void parseDurationProperties ( Map < String , Object > vendorProps , String className , ConnectorService connectorSvc ) throws Exception { // type=long, unit=milliseconds for ( String propName : PropertyService . DURATION_MS_LONG_PROPS ) { Object propValue = vendorProps . remove ( propName ) ; if ( propVa... | Parse and convert duration type properties . | 734 | 8 |
159,165 | public static final void parsePasswordProperties ( Map < String , Object > vendorProps ) { for ( String propName : PASSWORD_PROPS ) { String propValue = ( String ) vendorProps . remove ( propName ) ; if ( propValue != null ) vendorProps . put ( propName , new SerializableProtectedString ( propValue . toCharArray ( ) ) ... | Parse and convert password properties to SerializableProtectedString . | 87 | 13 |
159,166 | public QueueElement removeTail ( ) { if ( head == null ) { return null ; } QueueElement result = tail ; if ( result . previous == null ) { head = null ; tail = null ; } else { tail = result . previous ; tail . next = null ; } result . previous = null ; result . next = null ; result . queue = null ; numElements -- ; ret... | Remove the element at the tail of this queue and return it . | 88 | 13 |
159,167 | public RemoteAllResults getLogLists ( LogQueryBean logQueryBean , RepositoryPointer after ) throws LogRepositoryException { RemoteAllResults result = new RemoteAllResults ( logQueryBean ) ; Iterable < ServerInstanceLogRecordList > lists ; if ( after == null ) { lists = logReader . getLogLists ( logQueryBean ) ; } else ... | retrieves results for all server instances in the repository . | 133 | 12 |
159,168 | public RemoteInstanceResult getLogListForServerInstance ( RemoteInstanceDetails indicator , RepositoryPointer after , int offset , int maxRecords , Locale locale ) throws LogRepositoryException { ServerInstanceLogRecordList instance ; // Pointer should be used only if start time is null. This way the same query object ... | retrieves records and header for one server instance . | 590 | 11 |
159,169 | public void setValidating ( boolean isValidating ) { if ( isValidating ) MCWrapper . isValidating . set ( true ) ; else MCWrapper . isValidating . remove ( ) ; } | Indicates to the connection manager whether validation is occurring on the current thread . | 45 | 15 |
159,170 | public synchronized BrowserProxyQueue createBrowserProxyQueue ( ) // F171893 throws SIResourceException , SIIncorrectCallException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createBrowserProxyQueue" ) ; // F171893 checkClosed ( ) ; short id = nextId ( ) ; BrowserP... | Creates a new browser proxy queue for this group . | 169 | 11 |
159,171 | public synchronized AsynchConsumerProxyQueue createAsynchConsumerProxyQueue ( OrderingContext oc ) throws SIResourceException , SIIncorrectCallException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createAsynchConsumerProxyQueue" ) ; short id = nextId ( ) ; // begin... | Creates a new asynchronous consumer proxy queue for this group . | 227 | 12 |
159,172 | public synchronized AsynchConsumerProxyQueue createReadAheadProxyQueue ( Reliability unrecoverableReliability ) // f187521.2.1 throws SIResourceException , SIIncorrectCallException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createReadAheadProxyQueue" ) ; checkClos... | Creates a new read ahead proxy queue for this group . | 222 | 12 |
159,173 | public synchronized void bury ( ProxyQueue queue ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "bury" ) ; // Get the proxy queue id short id = queue . getId ( ) ; // Remove it from the table mutableId . setValue ( id ) ; idToProxyQueueMap . remove ( mutableId ) ; if... | If a session is failed to be created then we need to bury it so that it never bothers us again . The queue is simply removed from the conversation group - no attempt is made to remove messages . It is assumed that if something went wrong in the creation then no messages would ever get to the queue . | 124 | 61 |
159,174 | public synchronized ProxyQueue find ( short proxyQueueId ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "find" , "" + proxyQueueId ) ; mutableId . setValue ( proxyQueueId ) ; ProxyQueue retQueue = idToProxyQueueMap . get ( mutableId ) ; if ( TraceComponent . isAnyTra... | Locates a proxy queue from this group via its queue ID . | 124 | 13 |
159,175 | protected void notifyClose ( ProxyQueue queue ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "notifyClose" , queue ) ; try { final short id = queue . getId ( ) ; idAllocator . releaseId ( id ) ; //Remove the id from the map synchronized ( this ) { idToProxyQueueMap .... | Notified when a proxy queue in this group is closed . Allows us to free up the ID assigned to it . | 233 | 23 |
159,176 | private short nextId ( ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "nextId" ) ; short id ; try { id = idAllocator . allocateId ( ) ; } catch ( IdAllocatorException e ) { // No FFDC code needed SIResourceException resourceException = new ... | Helper method . Returns the next id to be used for a proxy queue . | 202 | 15 |
159,177 | private void checkClosed ( ) throws SIIncorrectCallException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "checkClosed" , "" + closed ) ; if ( closed ) throw new SIIncorrectCallException ( TraceNLS . getFormattedMessage ( CommsConstants . MSG_BUNDLE , "PROXY_QUEUE_CO... | Helper method . Checks if this group has been closed and throws an exception if it has . | 178 | 18 |
159,178 | public void close ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "close" ) ; synchronized ( this ) { if ( closed ) { idToProxyQueueMap . clear ( ) ; factory . groupCloseNotification ( conversation , this ) ; } } if ( TraceComponent . isAnyTracingEnabled ( ) ... | Closes this proxy queue conversation group . | 113 | 8 |
159,179 | public void conversationDroppedNotification ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "conversationDroppedNotification" ) ; LinkedList < ProxyQueue > notifyList = null ; synchronized ( this ) { // Make a copy of the map's values to avoid a concurrent mo... | Invoked to notify the group that the conversation that backs it has gone away . Iterate over the queues and notify them . | 208 | 25 |
159,180 | public void setExtraAttribute ( String name , String value ) { if ( extraAttributes == null ) { extraAttributes = new HashMap < QName , Object > ( ) ; } if ( value == null ) { extraAttributes . remove ( new QName ( null , name ) ) ; } else { extraAttributes . put ( new QName ( null , name ) , value ) ; } } | Sets an attribute on this element that does not have an explicit setter . | 81 | 16 |
159,181 | public static String getValue ( String value ) { if ( value == null ) { return null ; } String v = removeQuotes ( value . trim ( ) ) . trim ( ) ; if ( v . isEmpty ( ) ) { return null ; } return v ; } | Sometimes the JACL representation of a null or empty value includes quotation marks . Calling this method will parse away the extra JACL syntax and return a real or null value | 56 | 35 |
159,182 | public static String removeQuotes ( String arg ) { if ( arg == null ) { return null ; } int length = arg . length ( ) ; if ( length > 1 && arg . startsWith ( "\"" ) && arg . endsWith ( "\"" ) ) { return arg . substring ( 1 , length - 1 ) ; } return arg ; } | Removes leading and trailing quotes from the input argument if they exist . | 75 | 14 |
159,183 | protected VirtualConnection processWork ( TCPBaseRequestContext req , int options ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "processWork" ) ; } TCPConnLink conn = req . getTCPConnLink ( ) ; VirtualConnection vc = null ; if ( options != 1 ) { // initialize the act... | Processes the request . If the request is already associated with a work queue - send it there . Otherwise round robin requests amongst our set of queues . | 194 | 31 |
159,184 | protected boolean dispatch ( TCPBaseRequestContext req , IOException ioe ) { if ( req . blockedThread ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "dispatcher notifying waiting synch request " ) ; } if ( ioe != null ) { req . blockingIOError = ioe ; } req . blockWai... | Dispatches requests to workrer threds or notifies waiting thread . | 120 | 16 |
159,185 | private boolean dispatchWorker ( Worker worker ) { ExecutorService executorService = CHFWBundle . getExecutorService ( ) ; if ( null == executorService ) { if ( FrameworkState . isValid ( ) ) { Tr . error ( tc , "EXECUTOR_SVC_MISSING" ) ; throw new RuntimeException ( "Missing executor service" ) ; } else { // The frame... | Dispatch a work item . | 128 | 5 |
159,186 | protected void queueConnectForSelector ( ConnectInfo connectInfo ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "queueConnectForSelector" ) ; } try { moveIntoPosition ( connectCount , connect , connectInfo , CS_CONNECTOR ) ; } catch ( IOException x ) { FFDCFilter . pr... | This method is called when work must be added to the connect selector . | 198 | 14 |
159,187 | protected void createNewThread ( ChannelSelector sr , int threadType , int number ) { StartPrivilegedThread privThread = new StartPrivilegedThread ( sr , threadType , number , this . tGroup ) ; AccessController . doPrivileged ( privThread ) ; } | Create a new reader thread . Provided so we can support pulling these from a thread pool in the SyncWorkQueueManager . This will allow these threads to have WSTHreadLocal . | 57 | 37 |
159,188 | void workerRun ( TCPBaseRequestContext req , IOException ioe ) { if ( null == req || req . getTCPConnLink ( ) . isClosed ( ) ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Ignoring IO on closed socket: " + req ) ; } return ; } try { if ( ioe == null ) { if ( TraceCom... | Main worker thread routine . | 535 | 5 |
159,189 | protected boolean dispatchConnect ( ConnectInfo work ) { if ( work . getSyncObject ( ) != null ) { // user thread waiting for work work . getSyncObject ( ) . simpleNotify ( ) ; return true ; } // dispatch async work return dispatchWorker ( new Worker ( work ) ) ; } | This is the entry point where work is added to the connect work list . As a result a separate thread from the caller will do the work . | 64 | 29 |
159,190 | public static Map < String , List < String > > getEvaluatedNavigationParameters ( FacesContext facesContext , Map < String , List < String > > parameters ) { Map < String , List < String > > evaluatedParameters = null ; if ( parameters != null && parameters . size ( ) > 0 ) { evaluatedParameters = new HashMap < String ... | Evaluate all EL expressions found as parameters and return a map that can be used for redirect or render bookmark links | 219 | 23 |
159,191 | private static List < String > _evaluateValueExpressions ( FacesContext context , List < String > values ) { // note that we have to create a new List here, because if we // change any value on the given List, it will be changed in the // NavigationCase too and the EL expression won't be evaluated again List < String >... | Checks the Strings in the List for EL expressions and evaluates them . Note that the returned List will be a copy of the given List because otherwise it will have unwanted side - effects . | 147 | 38 |
159,192 | public void register ( JMFEncapsulationManager mgr , int id ) { if ( id > JMFPart . MODEL_ID_JMF ) mmmgrTable . put ( Integer . valueOf ( id - 1 ) , mgr ) ; else throw new IllegalArgumentException ( "model ID cannot be negative" ) ; } | Register the JMFEncapsulationManager for a particular Model ID . | 72 | 14 |
159,193 | private void registerInternal ( JMFSchema schema ) { schemaTable . set ( ( HashedArray . Element ) schema ) ; Object assoc = schema . getJMFType ( ) . getAssociation ( ) ; if ( assoc != null ) associations . put ( assoc , schema ) ; } | Subroutine used by register and registerAll | 64 | 9 |
159,194 | private boolean isPresent ( JMFSchema schema ) throws JMFSchemaIdException { long id = schema . getID ( ) ; JMFSchema reg = ( JMFSchema ) schemaTable . get ( id ) ; if ( reg != null ) { // We are assuming that collisions on key don't happen if ( ! schema . equals ( reg ) ) { // The schema id is a 64bit SHA-1 derived ha... | to the same schema . | 246 | 5 |
159,195 | public static Vector getLocales ( HttpServletRequest req ) { init ( ) ; String acceptLanguage = req . getHeader ( "Accept-Language" ) ; if ( com . ibm . ejs . ras . TraceComponent . isAnyTracingEnabled ( ) && logger . isLoggable ( Level . FINE ) ) { logger . logp ( Level . FINE , CLASS_NAME , "getLocales" , "Accept-Lan... | Returns a Vector of locales from the passed in request object . | 424 | 13 |
159,196 | public static Vector processAcceptLanguage ( String acceptLanguage ) { init ( ) ; StringTokenizer languageTokenizer = new StringTokenizer ( acceptLanguage , "," ) ; TreeMap map = new TreeMap ( Collections . reverseOrder ( ) ) ; while ( languageTokenizer . hasMoreTokens ( ) ) { String language = languageTokenizer . next... | Processes the accept languages in a passed in String into a Vector object . | 696 | 15 |
159,197 | public static Vector extractLocales ( Vector languages , boolean secure ) { init ( ) ; Enumeration e = languages . elements ( ) ; Vector l = new Vector ( ) ; while ( e . hasMoreElements ( ) ) { Vector langVector = ( Vector ) e . nextElement ( ) ; Enumeration enumeration = langVector . elements ( ) ; while ( enumeration... | This method will validate the values . | 385 | 7 |
159,198 | public static String getEncodingFromLocale ( Locale locale ) { init ( ) ; if ( locale == cachedLocale ) { return cachedEncoding ; } String encoding = null ; /*(String) _localeMap.get(locale.toString()); if (encoding == null) { encoding = (String) _localeMap.get(locale.getLanguage() + "_" + locale.getCountry()); if (enc... | Get the encoding for a passed in locale . | 232 | 9 |
159,199 | public static String getJvmConverter ( String encoding ) { init ( ) ; //String converter = (String) _converterMap.get(encoding.toLowerCase()); String converter = null ; com . ibm . wsspi . http . EncodingUtils encodingUtils = com . ibm . ws . webcontainer . osgi . WebContainer . getEncodingUtils ( ) ; if ( encodingUtil... | Get the JVM Converter for the specified encoding . | 133 | 11 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.