idx int64 0 165k | question stringlengths 73 5.81k | target stringlengths 5 918 |
|---|---|---|
159,600 | static Selector convertRange ( Selector expr , Selector bound1 , Selector bound2 ) { return new OperatorImpl ( Operator . AND , new OperatorImpl ( Operator . GE , ( Selector ) expr . clone ( ) , bound1 ) , new OperatorImpl ( Operator . LE , ( Selector ) expr . clone ( ) , bound2 ) ) ; } | Convert a partially parsed BETWEEN expression into its more primitive form as a conjunction of inequalities . |
159,601 | static Selector convertLike ( Selector arg , String pattern , String escape ) { try { pattern = reduceStringLiteralToken ( pattern ) ; boolean escaped = false ; char esc = 0 ; if ( escape != null ) { escape = reduceStringLiteralToken ( escape ) ; if ( escape . length ( ) != 1 ) return null ; escaped = true ; esc = esca... | Convert a partially parsed LIKE expression in which the pattern and escape are in the form of token images to the proper Selector expression to represent the LIKE expression |
159,602 | public SecurityMetadata getSecurityMetadata ( ) { SecurityMetadata sm = super . getSecurityMetadata ( ) ; if ( sm == null ) { return getDefaultAdminSecurityMetadata ( ) ; } else { return sm ; } } | Get the effective SecurityMetadata for this application . First try to defer to the application collaborator to see if the application provides data . If so use it . Otherwise fallback to the default SecurityMetadata . |
159,603 | private void buildPolicyErrorMessage ( String msgKey , String defaultMessage , Object ... arg1 ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isWarningEnabled ( ) ) { String messageFromBundle = Tr . formatMessage ( tc , msgKey , arg1 ) ; Tr . error ( tc , messageFromBundle ) ; } } | Receives the message key like CSIv2_COMMON_AUTH_LAYER_DISABLED from this key we extract the message from the NLS message bundle which contains the message along with the CWWKS message code . |
159,604 | public void displaySelectionPage ( HttpServletRequest request , HttpServletResponse response , SocialTaiRequest socialTaiRequest ) throws IOException { setRequestAndConfigInformation ( request , response , socialTaiRequest ) ; if ( selectableConfigs == null || selectableConfigs . isEmpty ( ) ) { sendDisplayError ( resp... | Generates the sign in page to allow a user to select from the configured social login services . If no services are configured the user is redirected to an error page . |
159,605 | String createJavascript ( ) { StringBuilder html = new StringBuilder ( ) ; html . append ( "<script>\n" ) ; html . append ( "function " + createCookieFunctionName + "(value) {\n" ) ; html . append ( "document.cookie = \"" + ClientConstants . LOGIN_HINT + "=\" + value;\n" ) ; html . append ( "}\n" ) ; html . append ( "<... | Creates a JavaScript function for creating a social_login_hint cookie with the value provided to the function . Each provider button should be configured to call this function when the button is clicked allowing the login hint to be passed around in a cookie instead of a request parameter . |
159,606 | public boolean parseMessage ( WsByteBuffer buffer , boolean bExtractValue ) throws Exception { final boolean bTrace = TraceComponent . isAnyTracingEnabled ( ) ; boolean rc = false ; if ( ! isFirstLineComplete ( ) ) { if ( bTrace && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Parsing First Line" ) ; } rc = parseLine ... | Parse a message from the input buffer . The input flag is whether or not to save the header value immediately or delay the extraction until the header value is queried . |
159,607 | public WsByteBuffer [ ] marshallMessage ( ) throws MessageSentException { final boolean bTrace = TraceComponent . isAnyTracingEnabled ( ) ; if ( bTrace && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "marshallMessage" ) ; } preMarshallMessage ( ) ; WsByteBuffer [ ] marshalledObj = hasFirstLineChanged ( ) ? marshallLin... | Marshall a message . |
159,608 | public static URITemplate createTemplate ( Path path , List < Parameter > params , String classNameandPath ) { return createTemplate ( path == null ? null : path . value ( ) , params , classNameandPath ) ; } | Liberty Change start |
159,609 | private boolean isELReserved ( String id ) { int i = 0 ; int j = reservedWords . length ; while ( i < j ) { int k = ( i + j ) / 2 ; int result = reservedWords [ k ] . compareTo ( id ) ; if ( result == 0 ) { return true ; } if ( result < 0 ) { i = k + 1 ; } else { j = k ; } } return false ; } | Test if an id is a reserved word in EL |
159,610 | protected synchronized Class < ? > loadClass ( String name , boolean resolve ) throws ClassNotFoundException { synchronized ( getClassLoadingLock ( name ) ) { Class < ? > result = null ; if ( name == null || name . length ( ) == 0 ) return null ; result = findLoadedClass ( name ) ; if ( result == null ) { if ( name . r... | Any changes must be made to both sources |
159,611 | private static List < Integer > allocateOffsets ( List < List < Integer > > offsetsStorage ) { if ( offsetsStorage . isEmpty ( ) ) { return new ArrayList < Integer > ( ) ; } else { return ( offsetsStorage . remove ( 0 ) ) ; } } | Allocate an offsets list . |
159,612 | private static int [ ] releaseOffsets ( List < List < Integer > > offsetsStorage , List < Integer > offsets ) { int numValues = offsets . size ( ) ; int [ ] extractedValues ; if ( numValues == 0 ) { extractedValues = EMPTY_OFFSETS_ARRAY ; } else { extractedValues = new int [ numValues ] ; for ( int valueNo = 0 ; valueN... | Release an offsets list to storage . |
159,613 | public static Map < String , IteratorData > collectIteratorData ( ZipEntryData [ ] zipEntryData ) { Map < String , IteratorData > allNestingData = new HashMap < String , IteratorData > ( ) ; List < List < Integer > > offsetsStorage = new ArrayList < List < Integer > > ( 32 ) ; String r_lastPath = "" ; int r_lastPathLen... | Collect the iterator data for a collection of zip entries . |
159,614 | public static ZipEntryData [ ] collectZipEntries ( ZipFile zipFile ) { final List < ZipEntryData > entriesList = new ArrayList < ZipEntryData > ( ) ; final Enumeration < ? extends ZipEntry > zipEntries = zipFile . entries ( ) ; while ( zipEntries . hasMoreElements ( ) ) { entriesList . add ( createZipEntryData ( zipEnt... | Collect data for the entries of a zip file . |
159,615 | public static Map < String , ZipEntryData > setLocations ( ZipEntryData [ ] entryData ) { Map < String , ZipEntryData > entryDataMap = new HashMap < String , ZipEntryData > ( entryData . length ) ; for ( int entryNo = 0 ; entryNo < entryData . length ; entryNo ++ ) { ZipEntryData entry = entryData [ entryNo ] ; entry .... | Create a table of entry data using the relative paths of the entries as keys . As a side effect set the offset of each entry data to its location int he entry data array . |
159,616 | public static int locatePath ( ZipEntryData [ ] entryData , final String r_path ) { ZipEntryData targetData = new SearchZipEntryData ( r_path ) ; return Arrays . binarySearch ( entryData , targetData , ZipFileContainerUtils . ZIP_ENTRY_DATA_COMPARATOR ) ; } | Locate a path in a collection of entries . |
159,617 | private static String stripPath ( String path ) { int pathLen = path . length ( ) ; if ( pathLen == 0 ) { return path ; } else if ( pathLen == 1 ) { if ( path . charAt ( 0 ) == '/' ) { return "" ; } else { return path ; } } else { if ( path . charAt ( 0 ) == '/' ) { if ( path . charAt ( pathLen - 1 ) == '/' ) { return ... | Paths used in the zip entry table are adjusted to never have a leading slash and to never have a trailing slash . |
159,618 | private static String getDeepestNestedElementName ( String configDisplayId ) { int start = configDisplayId . lastIndexOf ( "]/" ) ; if ( start > 1 ) { int end = configDisplayId . indexOf ( '[' , start += 2 ) ; if ( end > start ) return configDisplayId . substring ( start , end ) ; } return null ; } | Returns the most deeply nested element name . |
159,619 | public void dump_memory ( Writer out ) throws IOException { int qlist_num ; out . write ( "First quick size: " + first_quick_size + "\n" ) ; out . write ( "Last quick size: " + last_quick_size + "\n" ) ; out . write ( "Grain size: " + grain_size + "\n" ) ; out . write ( "Acceptable waste: " + acceptable_waste + "\n" ) ... | Outputs storage information stored in main memory . Debugging interface writes interesting stuff to stdout . |
159,620 | protected Channel createChannel ( ChannelData config ) throws ChannelException { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "createChannel" , config ) ; Channel retChannel ; if ( config . isInbound ( ) ) { if ( tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "createChannel" , "inbound" ) ; try { C... | Creates a new channel . Uses channel configuration to determine if the channel should be inbound or outbound . |
159,621 | public Class [ ] getDeviceInterface ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "getDeviceInterface" ) ; if ( devSideInterfaceClasses == null ) { devSideInterfaceClasses = new Class [ 1 ] ; devSideInterfaceClasses [ 0 ] = com . ibm . wsspi . tcpchannel . TCPConnectionContext . class ; } if ( tc . i... | Returns the device side interfaces which our channels can work with . This is always the TCPServiceContext . |
159,622 | private void addRepository ( String repositoryId , RepositoryWrapper repositoryHolder ) { repositories . put ( repositoryId , repositoryHolder ) ; try { numRepos = getNumberOfRepositories ( ) ; } catch ( WIMException e ) { } } | Pair adding to the repositories map and resetting the numRepos int . |
159,623 | protected String getRepositoryIdByUniqueName ( String uniqueName ) throws WIMException { boolean isDn = UniqueNameHelper . isDN ( uniqueName ) != null ; if ( isDn ) uniqueName = UniqueNameHelper . getValidUniqueName ( uniqueName ) . trim ( ) ; String repo = null ; int repoMatch = - 1 ; int bestMatch = - 1 ; for ( Map .... | Returns the id of the repository to which the uniqueName belongs to . |
159,624 | public boolean isSameExecutionZone ( FailureScope anotherScope ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "isSameExecutionZone" , anotherScope ) ; boolean isSameZone = equals ( anotherScope ) ; if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "isSameExecutionZone" , new Boolean ( isSameZone ) ) ; return isSame... | Returns true if this failure scope represents the same general recovery scope as the input parameter . For instance if more than one FailureScope was created which referenced the same server they would be in the same execution zone . |
159,625 | public static String encodeCookie ( String string ) { if ( string == null ) { return null ; } string = string . replaceAll ( "%" , "%25" ) ; string = string . replaceAll ( ";" , "%3B" ) ; string = string . replaceAll ( "," , "%2C" ) ; return string ; } | Encodes the given string so that it can be used as an HTTP cookie value . |
159,626 | public static String decodeCookie ( String string ) { if ( string == null ) { return null ; } string = string . replaceAll ( "%2C" , "," ) ; string = string . replaceAll ( "%3B" , ";" ) ; string = string . replaceAll ( "%25" , "%" ) ; return string ; } | Decodes the given string from percent encoding . |
159,627 | public static String getRequestStringForTrace ( HttpServletRequest request , String [ ] secretStrings ) { if ( request == null || request . getRequestURL ( ) == null ) { return "[]" ; } StringBuffer sb = new StringBuffer ( "[" + stripSecretsFromUrl ( request . getRequestURL ( ) . toString ( ) , secretStrings ) + "]" ) ... | information and returns a string for tracing |
159,628 | public void deleteAbstractAliasDestinationHandler ( AbstractAliasDestinationHandler abstractAliasDestinationHandler ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "deleteAbstractAliasDestinationHandler" ) ; if ( abstractAliasDestinationHandler instanceof BusHandler )... | Delete the abstract alias destination handler |
159,629 | public int add ( Object dependency , ValueSet valueSet , Object entry ) { int returnCode = HTODDynacache . NO_EXCEPTION ; dependencyNotUpdatedTable . remove ( dependency ) ; valueSet . add ( entry ) ; if ( valueSet . size ( ) > this . delayOffloadEntriesLimit ) { if ( this . type == DEP_ID_TABLE ) { returnCode = this .... | This adds a entry to the ValueSet for the specified dependency . The dependency is found in the dependencyToEntryTable . |
159,630 | public int add ( Object dependency , ValueSet valueSet ) { int returnCode = HTODDynacache . NO_EXCEPTION ; if ( dependencyToEntryTable . size ( ) >= this . maxSize ) { returnCode = reduceTableSize ( ) ; } dependencyNotUpdatedTable . put ( dependency , valueSet ) ; dependencyToEntryTable . put ( dependency , valueSet ) ... | This adds a new dependency with its valueSet to the DependencyToEntryTable . |
159,631 | public int replace ( Object dependency , ValueSet valueSet ) { int returnCode = HTODDynacache . NO_EXCEPTION ; dependencyNotUpdatedTable . remove ( dependency ) ; if ( valueSet != null && valueSet . size ( ) > this . delayOffloadEntriesLimit ) { dependencyToEntryTable . remove ( dependency ) ; if ( this . type == DEP_I... | This replaces the existing dependency with new valueSet in DependencyToEntryTable . |
159,632 | public Result removeEntry ( Object dependency , Object entry ) { Result result = this . htod . getFromResultPool ( ) ; ValueSet valueSet = ( ValueSet ) dependencyToEntryTable . get ( dependency ) ; if ( valueSet == null ) { return result ; } result . bExist = HTODDynacache . EXIST ; valueSet . remove ( entry ) ; depend... | This removes the specified entry from the specified dependency . |
159,633 | public ValueSet getEntries ( Object dependency ) { ValueSet valueSet = ( ValueSet ) dependencyToEntryTable . get ( dependency ) ; return valueSet ; } | This returns the ValueSet for the specified dependency from the DependencyToEntryTable . |
159,634 | private int reduceTableSize ( ) { int returnCode = HTODDynacache . NO_EXCEPTION ; int count = this . entryRemove ; if ( count > 0 ) { int removeSize = 5 ; while ( count > 0 ) { int minSize = Integer . MAX_VALUE ; Iterator < Map . Entry < Object , Set < Object > > > e = dependencyToEntryTable . entrySet ( ) . iterator (... | This reduces the DependencyToEntryTable size by offloading some dependencies to the disk . |
159,635 | private static String getClassName ( String implClassName ) { implClassName = implClassName . substring ( 0 , implClassName . length ( ) - 4 ) ; return implClassName + "ComponentImpl" ; } | The model interface type has a name ending in Type . For the moment modify it here . |
159,636 | public void registerThread ( StoppableThread thread ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "registerThread" , thread ) ; synchronized ( this ) { _threadCache . add ( thread ) ; } if ( tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "registerThread" ) ; } | Registers a new thread for stopping |
159,637 | public void deregisterThread ( StoppableThread thread ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "deregisterThread" , thread ) ; synchronized ( this ) { _threadCache . remove ( thread ) ; } if ( tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "deregisterThread" ) ; } | Deregisters a thread for stopping |
159,638 | public void stopAllThreads ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "stopAllThreads" ) ; synchronized ( this ) { Iterator iterator = ( ( ArrayList ) _threadCache . clone ( ) ) . iterator ( ) ; while ( iterator . hasNext ( ) ) { StoppableThread thread = ( StoppableThread ) iterator . next ( ) ; if ( tc ... | Stops all the stoppable threads that haven t already been stopped |
159,639 | public ArrayList getThreads ( ) { if ( tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , "getThreads" ) ; SibTr . exit ( tc , "getThreads" , _threadCache ) ; } return _threadCache ; } | Unit test hook to check on connected threads |
159,640 | private int getAndUpdateTail ( ) { int retMe ; do { retMe = tailIndex . get ( ) ; } while ( tailIndex . compareAndSet ( retMe , getNext ( retMe ) ) == false ) ; return retMe ; } | Atomically update and return the tailIndex . |
159,641 | public boolean put ( ExpirableReference expirable ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "put" , "ObjId=" + expirable . getID ( ) + " ET=" + expirable . getExpiryTime ( ) ) ; boolean reply = tree . insert ( expirable ) ; if ( reply ) { size ++ ; } if (... | Add an ExpirableReference to the expiry index . |
159,642 | protected static Map < String , ProductInfo > getAllProductInfo ( File wlpInstallationDirectory ) throws VersionParsingException { File versionPropertyDirectory = new File ( wlpInstallationDirectory , ProductInfo . VERSION_PROPERTY_DIRECTORY ) ; if ( ! versionPropertyDirectory . exists ( ) ) { throw new VersionParsingE... | This method will create a map of product ID to the VersionProperties for that product . |
159,643 | public boolean remove ( V value ) { K key = value . getKey ( ) ; Ref < V > ref = map . get ( key ) ; return ( ref != null && ref . get ( ) == value ) ? map . remove ( key , ref ) : false ; } | Remove any mapping for the provided id |
159,644 | public V retrieveOrCreate ( K key , Factory < V > factory ) { this . cleanUpStaleEntries ( ) ; return retrieveOrCreate ( key , factory , new FutureRef < V > ( ) ) ; } | Create a value for the given key iff one has not already been stored . This method is safe to be called concurrently from multiple threads . It will ensure that only one thread succeeds to create the value for the given key . |
159,645 | void cleanUpStaleEntries ( ) { for ( KeyedRef < K , V > ref = q . poll ( ) ; ref != null ; ref = q . poll ( ) ) { map . remove ( ref . getKey ( ) , ref ) ; } } | clean up stale entries |
159,646 | public Object nextElement ( ) { if ( _array == null ) { return null ; } else { synchronized ( this ) { if ( _index < _array . length ) { Object obj = _array [ _index ] ; _index ++ ; return obj ; } else { return null ; } } } } | nextElement method comment . |
159,647 | public int execute ( String [ ] args ) { Map < String , LevelDetails > levels = readLevels ( System . getProperty ( "logviewer.custom.levels" ) ) ; String [ ] header = readHeader ( System . getProperty ( "logviewer.custom.header" ) ) ; return execute ( args , levels , header ) ; } | Runs LogViewer using values in System Properties to find custom levels and header . |
159,648 | public int execute ( String [ ] args , Map < String , LevelDetails > levels , String [ ] header ) { levelString = getLevelsString ( levels ) ; RepositoryReaderImpl logRepository ; try { if ( parseCmdLineArgs ( args ) || validateSettings ( ) ) { return 0 ; } if ( header != null ) { theFormatter . setCustomHeader ( heade... | Runs LogViewer . |
159,649 | private long collectAllKids ( ArrayList < DisplayInstance > result , ServerInstanceLogRecordList list ) { long timestamp = - 1 ; RepositoryLogRecord first = list . iterator ( ) . next ( ) ; if ( first != null ) { timestamp = first . getMillis ( ) ; } for ( Entry < String , ServerInstanceLogRecordList > kid : list . get... | collects all descendant instances into an array and calculates largest timestamp of their first records . |
159,650 | private Level createLevelByString ( String levelString ) throws IllegalArgumentException { try { return Level . parse ( levelString . toUpperCase ( ) ) ; } catch ( Exception npe ) { throw new IllegalArgumentException ( getLocalizedParmString ( "CWTRA0013E" , new Object [ ] { levelString } ) ) ; } } | This method creates a java . util . Level object from a string with the level name . |
159,651 | void setInstanceId ( String instanceId ) throws IllegalArgumentException { if ( instanceId != null && ! "" . equals ( instanceId ) ) { subInstanceId = getSubProcessInstanceId ( instanceId ) ; try { long id = getProcessInstanceId ( instanceId ) ; mainInstanceId = id < 0 ? null : new Date ( id ) ; } catch ( NumberFormatE... | Parses the instanceId into the requested main process instanceId and the subprocess instanceid . The main process instanceId must be a long value as the main instance Id is a timestamp . |
159,652 | protected File [ ] listRepositoryChoices ( ) { String currentDir = System . getProperty ( "log.repository.root" ) ; if ( currentDir == null ) currentDir = System . getProperty ( "user.dir" ) ; File logDir = new File ( currentDir ) ; if ( logDir . isDirectory ( ) ) { File [ ] result = RepositoryReaderImpl . listReposito... | Lists directories containing HPEL repositories . It is called when repository is not specified explicitly in the arguments |
159,653 | private int skipPast ( byte [ ] data , int pos , byte target ) { int index = pos ; while ( index < data . length ) { if ( target == data [ index ++ ] ) { return index ; } } return index ; } | Skip until it runs out of input data or finds the target byte . |
159,654 | private int parseTrailer ( byte [ ] input , int inOffset , List < WsByteBuffer > list ) throws DataFormatException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Parsing trailer, offset=" + this . parseOffset + " val=" + this . parseInt ) ; } int offset = inOffset ; lo... | Parse past the GZIP trailer information . This is the two ints for the CRC32 checksum validation . |
159,655 | public void logClosedException ( Exception e ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Connection closed with exception: " + e . getMessage ( ) ) ; } } | This logs the error if the connection was closed by a higher level channel with an error . |
159,656 | void outOfScope ( ) { final String methodName = "outOfScope" ; if ( TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName ) ; } _outOfScope = true ; try { _connectionClone . close ( ) ; } catch ( final SIException exception ) { FFDCFilter . processException ( exception , "com.ibm.ws.sib.ra.inbound.im... | Called to indicate that this session is now out of scope . |
159,657 | public void createAppToSecurityRolesMapping ( String appName , Collection < SecurityRole > securityRoles ) { appToSecurityRolesMap . putIfAbsent ( appName , securityRoles ) ; } | Creates the application to security roles mapping for a given application . |
159,658 | public void removeRoleToRunAsMapping ( String appName ) { Map < String , RunAs > roleToRunAsMap = roleToRunAsMappingPerApp . get ( appName ) ; if ( roleToRunAsMap != null ) { roleToRunAsMap . clear ( ) ; } appToSecurityRolesMap . remove ( appName ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ... | Removes the role to RunAs mappings for a given application . |
159,659 | public void removeRoleToWarningMapping ( String appName ) { Map < String , Boolean > roleToWarningMap = roleToWarningMappingPerApp . get ( appName ) ; if ( roleToWarningMap != null ) { roleToWarningMap . clear ( ) ; } roleToWarningMappingPerApp . remove ( appName ) ; } | Removes the role to warning mappings for a given application . |
159,660 | private static void determineHandlers ( ) { if ( textHandler != null && ! logRepositoryConfiguration . isTextEnabled ( ) ) textHandler = null ; if ( binaryHandler != null && ! logRepositoryConfiguration . isTextEnabled ( ) ) return ; Handler [ ] handlers = Logger . getLogger ( "" ) . getHandlers ( ) ; for ( Handler han... | determine two handlers needed by the repository |
159,661 | public void close ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "close" ) ; Enumeration streams = null ; synchronized ( this ) { synchronized ( streamTable ) { closed = true ; closeBrowserSessionsInternal ( ) ; streams = streamTable . elements ( ) ; } } while ( st... | Cleans up the non - persistent state . No methods on the ControlHandler interface should be called after this is called . |
159,662 | public boolean cleanup ( boolean flushStreams , boolean redriveDeletionThread ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "cleanup" , new Object [ ] { Boolean . valueOf ( flushStreams ) , Boolean . valueOf ( redriveDeletionThread ) } ) ; boolean retvalue = false ;... | Cleanup the state in this AnycastOutputHandler . Called when this localisation is being deleted . |
159,663 | public final AOStream getAOStream ( String streamKey , SIBUuid12 streamId ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getAOStream" , new Object [ ] { streamKey , streamId } ) ; StreamInfo streamInfo = getStreamInfo ( streamKey , streamId ) ; if ( streamInfo != nu... | for unit testing |
159,664 | private final void handleControlBrowseStatus ( SIBUuid8 remoteME , SIBUuid12 gatheringTargetDestUuid , long browseId , int status ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "handleControlBrowseStatus" , new Object [ ] { remoteME , gatheringTargetDestUuid , Long .... | Method to handle a ControlBrowseStatus message from an RME |
159,665 | public final void removeBrowserSession ( AOBrowserSessionKey key ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removeBrowserSession" , key ) ; browserSessionTable . remove ( key ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . ... | Remove an AOBrowserSession that is already closed |
159,666 | private final StreamInfo getStreamInfo ( String streamKey , SIBUuid12 streamId ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getStreamInfo" , new Object [ ] { streamKey , streamId } ) ; StreamInfo sinfo = streamTable . get ( streamKey ) ; if ( ( sinfo != null ) && ... | Helper method used to dispatch a message received for a particular stream . Handles its own synchronization |
159,667 | public final void streamIsFlushed ( AOStream stream ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "streamIsFlushed" , stream ) ; synchronized ( streamTable ) { String key = SIMPUtils . getRemoteGetKey ( stream . getRemoteMEUuid ( ) , stream . getGatheringTargetDestU... | Callback from a stream that it has been flushed |
159,668 | public final AOValue persistLockAndTick ( TransactionCommon t , AOStream stream , long tick , SIMPMessage msg , int storagePolicy , long waitTime , long prevTick ) throws Exception { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "persistLockAndTick" , new Object [ ] { t... | Helper method called by the AOStream when to persistently lock a message and create a persistent tick in the protocol stream |
159,669 | public final void cleanupTicks ( StreamInfo sinfo , TransactionCommon t , ArrayList valueTicks ) throws MessageStoreException , SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "cleanupTicks" , new Object [ ] { sinfo , t , valueTicks } ) ; try { int l... | Helper method called by the AOStream when a persistent tick representing a persistently locked message should be removed since we are flushing or cleaning up state . |
159,670 | public final Item writeStartedFlush ( TransactionCommon t , AOStream stream ) throws Exception { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "writeStartedFlush" ) ; String key = SIMPUtils . getRemoteGetKey ( stream . getRemoteMEUuid ( ) , stream . getGatheringTargetDe... | Helper method used by AOStream to persistently record that flush has been started |
159,671 | public final void writtenStartedFlush ( AOStream stream , Item startedFlushItem ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "writtenStartedFlush" ) ; String key = SIMPUtils . getRemoteGetKey ( stream . getRemoteMEUuid ( ) , stream . getGatheringTargetDestUuid ( ) ... | Callback when the Item that records that flush has been started has been committed to persistent storage |
159,672 | public SIMPItemStream getItemStream ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getItemStream" ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "getItemStream" , containerItemStream ) ; return ( SIMPItemStream )... | Return the SIMPItemStream associated with this AOH . This method is needed for proper cleanup of remote durable subscriptions since the usual item stream owned by the DestinationHandler is not used . |
159,673 | public final String getDestName ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getDestName" ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "getDestName" , destName ) ; return destName ; } | Return the destination name which this AOH is associated with . |
159,674 | public final SIBUuid12 getDestUUID ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , "getDestUUID" ) ; SibTr . exit ( tc , "getDestUUID" , destName ) ; } return destUuid ; } | Return the destination UUID which this AOH is associated with . This method is needed for proper cleanup of remote durable subscriptions since pseudo destinations are used rather than the destination normally associated with the DestinationHandler . |
159,675 | public void forceFlushAtSource ( SIBUuid8 remoteUuid , SIBUuid12 gatheringTargetDestUuid ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "forceFlushAtSource" , new Object [ ] { remoteUuid , gatheringTargetDestUuid } ) ; StreamInfo sinfo ; boolean success = false ; Str... | If the RME has been deleted then the stream needs to be flushed to unlock any messaqes on this DME . |
159,676 | private void deleteAndUnlockPersistentStream ( StreamInfo sinfo , ArrayList valueTicks ) throws MessageStoreException , SIRollbackException , SIConnectionLostException , SIIncorrectCallException , SIResourceException , SIErrorException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr .... | remove the persistent ticks and the itemstream and started - flush item |
159,677 | protected void init ( boolean useDirect , int outSize , int inSize , int cacheSize ) { this . useDirectBuffer = useDirect ; this . outgoingHdrBufferSize = outSize ; this . incomingBufferSize = inSize ; if ( cacheSize > this . byteCacheSize ) { this . byteCacheSize = cacheSize ; this . byteCache = new byte [ cacheSize ]... | Initialize this class instance with the chosen parse configuration options . |
159,678 | public void addParseBuffer ( WsByteBuffer buffer ) { int index = ++ this . parseIndex ; if ( null == this . parseBuffers ) { this . parseBuffers = new WsByteBuffer [ BUFFERS_INITIAL_SIZE ] ; this . parseBuffersStartPos = new int [ BUFFERS_INITIAL_SIZE ] ; for ( int i = 0 ; i < BUFFERS_INITIAL_SIZE ; i ++ ) { this . par... | Save a reference to a new buffer with header parse information . This is not part of the created list and will not be released by this message class . |
159,679 | public void addToCreatedBuffer ( WsByteBuffer buffer ) { int index = ++ this . createdIndex ; if ( null == this . myCreatedBuffers ) { this . myCreatedBuffers = new WsByteBuffer [ BUFFERS_INITIAL_SIZE ] ; } else if ( index == this . myCreatedBuffers . length ) { int size = index + BUFFERS_MIN_GROWTH ; if ( TraceCompone... | Add a buffer on the list that will be manually released later . |
159,680 | public void clear ( ) { final boolean bTrace = TraceComponent . isAnyTracingEnabled ( ) ; if ( bTrace && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "clear" ) ; } clearAllHeaders ( ) ; this . eohPosition = HeaderStorage . NOTSET ; this . currentElem = null ; this . stateOfParsing = PARSING_CRLF ; this . binaryParsing... | Clear out information on this object so that it can be re - used . |
159,681 | private void clearBuffers ( ) { final boolean bTrace = TraceComponent . isAnyTracingEnabled ( ) ; for ( int i = 0 ; i <= this . parseIndex ; i ++ ) { if ( bTrace && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Removing reference to parse buffer: " + this . parseBuffers [ i ] ) ; } this . parseBuffers [ i ] = null ; t... | Clear the array of buffers used during the parsing or marshalling of headers . |
159,682 | public void debug ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "*** Begin Header Debug ***" ) ; HeaderElement elem = this . hdrSequence ; while ( null != elem ) { Tr . debug ( tc , elem . getName ( ) + ": " + elem . getDebugValue ( ) ) ; elem = elem . nextSequence... | Print debug information on the headers to the RAS tracing log . |
159,683 | protected void destroy ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Destroying these headers: " + this ) ; } if ( null != this . hdrSequence || HeaderStorage . NOTSET != this . parseIndex ) { clear ( ) ; } this . byteCacheSize = DEFAULT_CACHESIZE ; this . incomin... | Completely clear out all the information on this object when it is no longer used . |
159,684 | protected void writeByteArray ( ObjectOutput output , byte [ ] data ) throws IOException { if ( null == data || 0 == data . length ) { output . writeInt ( - 1 ) ; } else { output . writeInt ( data . length ) ; output . write ( data ) ; } } | Write information for the input data to the output stream . If the input data is null or empty this will write a - 1 length marker . |
159,685 | private void scribbleWhiteSpace ( WsByteBuffer buffer , int start , int stop ) { if ( buffer . hasArray ( ) ) { final byte [ ] data = buffer . array ( ) ; final int offset = buffer . arrayOffset ( ) ; int myStart = start + offset ; int myStop = stop + offset ; for ( int i = myStart ; i < myStop ; i ++ ) { data [ i ] = ... | Overlay whitespace into the input buffer using the provided starting and stopping positions . |
159,686 | private void eraseValue ( HeaderElement elem ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Erasing existing header: " + elem . getName ( ) ) ; } int next_index = this . lastCRLFBufferIndex ; int next_pos = this . lastCRLFPosition ; if ( null != elem . nextSequence &... | Method to completely erase the input header from the parse buffers . |
159,687 | private int overlayBytes ( byte [ ] data , int inOffset , int inLength , int inIndex ) { int length = inLength ; int offset = inOffset ; int index = inIndex ; WsByteBuffer buffer = this . parseBuffers [ index ] ; if ( - 1 == length ) { length = data . length ; } while ( index <= this . parseIndex ) { int remaining = bu... | Utility method to overlay the input bytes into the parse buffers starting at the input index and moving forward as needed . |
159,688 | private void overlayValue ( HeaderElement elem ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Overlaying existing header: " + elem . getName ( ) ) ; } int next_index = this . lastCRLFBufferIndex ; int next_pos = this . lastCRLFPosition ; if ( null != elem . nextSeque... | Method to overlay the new header value onto the older value in the parse buffers . |
159,689 | private WsByteBuffer [ ] marshallAddedHeaders ( WsByteBuffer [ ] inBuffers , int index ) { WsByteBuffer [ ] buffers = inBuffers ; buffers [ index ] = allocateBuffer ( this . outgoingHdrBufferSize ) ; for ( HeaderElement elem = this . hdrSequence ; null != elem ; elem = elem . nextSequence ) { if ( elem . wasAdded ( ) )... | Marshall the newly added headers from the sequence list to the output buffers starting at the input index on the list . |
159,690 | private void clearAllHeaders ( ) { final boolean bTrace = TraceComponent . isAnyTracingEnabled ( ) ; if ( bTrace && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "clearAllHeaders()" ) ; } HeaderElement elem = this . hdrSequence ; while ( null != elem ) { final HeaderElement next = elem . nextSequence ; final HeaderKeys... | Clear all traces of the headers from storage . |
159,691 | public void removeSpecialHeader ( HeaderKeys key ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "removeSpecialHeader(h): " + key . getName ( ) ) ; } removeHdrInstances ( findHeader ( key ) , FILTER_NO ) ; } | Remove all instances of a special header that does not require the headerkey filterRemove method to be called . |
159,692 | public WsByteBuffer returnCurrentBuffer ( ) { WsByteBuffer buff = null ; if ( HeaderStorage . NOTSET != this . parseIndex ) { buff = this . parseBuffers [ this . parseIndex ] ; this . parseIndex -- ; } return buff ; } | Method to remove the current parsing buffer from this object s ownership so it can be used by others . |
159,693 | private void createSingleHeader ( HeaderKeys key , byte [ ] value , int offset , int length ) { HeaderElement elem = findHeader ( key ) ; if ( null != elem ) { if ( null != elem . nextInstance ) { HeaderElement temp = elem . nextInstance ; while ( null != temp ) { temp . remove ( ) ; temp = temp . nextInstance ; } } if... | Utility method to create a single header instance with the given information . If elements already exist this will delete secondary ones and overlay the value on the first element . |
159,694 | private void addHeader ( HeaderElement elem , boolean bFilter ) { final HeaderKeys key = elem . getKey ( ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Adding header [" + key . getName ( ) + "] with value [" + elem . getDebugValue ( ) + "]" ) ; } if ( getRemoteIp ( )... | Add this new instance of a header to storage . |
159,695 | private HeaderElement findHeader ( HeaderKeys key , int instance ) { final int ord = key . getOrdinal ( ) ; if ( ! storage . containsKey ( ord ) && ord <= HttpHeaderKeys . ORD_MAX ) { return null ; } HeaderElement elem = null ; if ( ord > HttpHeaderKeys . ORD_MAX ) { for ( HeaderElement header : storage . values ( ) ) ... | Find the specific instance of this header in storage . |
159,696 | private void removeHdr ( HeaderElement elem ) { if ( null == elem ) { return ; } HeaderKeys key = elem . getKey ( ) ; elem . remove ( ) ; if ( key . useFilters ( ) ) { filterRemove ( key , elem . asBytes ( ) ) ; } } | Remove this single instance of a header . |
159,697 | private void removeHdrInstances ( HeaderElement root , boolean bFilter ) { if ( null == root ) { return ; } HeaderKeys key = root . getKey ( ) ; if ( bFilter && key . useFilters ( ) ) { filterRemove ( key , null ) ; } HeaderElement elem = root ; while ( null != elem ) { elem . remove ( ) ; elem = elem . nextInstance ; ... | Remove all instances of this header . |
159,698 | protected void setSpecialHeader ( HeaderKeys key , byte [ ] value ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "setSpecialHeader(h,b[]): " + key . getName ( ) ) ; } removeHdrInstances ( findHeader ( key ) , FILTER_NO ) ; HeaderElement elem = getElement ( key ) ; ele... | Set one of the special headers that does not require the headerkey filterX methods to be called . |
159,699 | public void setHeaderChangeLimit ( int limit ) { this . headerChangeLimit = limit ; this . bOverChangeLimit = false ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Setting header change limit to " + limit ) ; } } | Set the limit on the number of allowed header changes before this message must be remarshalled . |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.