idx int64 0 165k | question stringlengths 73 4.15k | target stringlengths 5 918 | len_question int64 21 890 | len_target int64 3 255 |
|---|---|---|---|---|
161,100 | public static synchronized void notifyStopped ( HttpEndpointImpl endpoint , String resolvedHostName , int port , boolean isHttps ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Notify endpoint stopped: " + endpoint , resolvedHostName , port , isHttps , defaultHost . g... | Remove a port associated with an endpoint that has stopped listening and notify associated virtual hosts . | 179 | 17 |
161,101 | public void addWsByteBuffer ( WsByteBuffer buffer ) { if ( this . allWsByteBuffers == null ) { this . allWsByteBuffers = new Hashtable < WsByteBuffer , WsByteBuffer > ( ) ; } this . allWsByteBuffers . put ( buffer , buffer ) ; } | Add a related buffer to the stored list for this instance . | 69 | 12 |
161,102 | public void addOwner ( String owner ) { if ( this . owners == null ) { this . owners = new Hashtable < String , String > ( ) ; } this . owners . put ( owner , owner ) ; } | Add the following owner to the list for this buffer . | 46 | 11 |
161,103 | public String getInputUniqueUserId ( String inputVirtualRealm ) { // initialize the return value String returnValue = getInputMapping ( inputVirtualRealm , Service . CONFIG_DO_UNIQUE_USER_ID_MAPPING , UNIQUE_USER_ID_DEFAULT ) ; return returnValue ; } | Get the input unique user ID mapping for the UserRegistry . | 69 | 13 |
161,104 | public String getOutputUniqueUserId ( String inputVirtualRealm ) { // initialize the return value String returnValue = getOutputMapping ( inputVirtualRealm , Service . CONFIG_DO_UNIQUE_USER_ID_MAPPING , UNIQUE_USER_ID_DEFAULT ) ; return returnValue ; } | Get the output unique user ID mapping for the UserRegistry . | 69 | 13 |
161,105 | public String getInputUserSecurityName ( String inputVirtualRealm ) { // initialize the return value String returnValue = getInputMapping ( inputVirtualRealm , Service . CONFIG_DO_USER_SECURITY_NAME_MAPPING , INPUT_USER_SECURITY_NAME_DEFAULT ) ; return returnValue ; } | Get the input user security name mapping for the UserRegistry . | 72 | 13 |
161,106 | public String getInputUserDisplayName ( String inputVirtualRealm ) { // initialize the return value String returnValue = getInputMapping ( inputVirtualRealm , Service . CONFIG_DO_USER_DISPLAY_NAME_MAPPING , USER_DISPLAY_NAME_DEFAULT ) ; return returnValue ; } | Get the input user display name mapping for the UserRegistry . | 68 | 13 |
161,107 | public String getOutputUserDisplayName ( String inputVirtualRealm ) { // initialize the return value String returnValue = getOutputMapping ( inputVirtualRealm , Service . CONFIG_DO_USER_DISPLAY_NAME_MAPPING , USER_DISPLAY_NAME_DEFAULT ) ; return returnValue ; } | Get the output user display name mapping for the UserRegistry . | 68 | 13 |
161,108 | public String getInputUniqueGroupId ( String inputVirtualRealm ) { // initialize the return value String returnValue = getInputMapping ( inputVirtualRealm , Service . CONFIG_DO_UNIQUE_GROUP_ID_MAPPING , INPUT_UNIQUE_GROUP_ID_DEFAULT ) ; return returnValue ; } | Get the input unique group ID mapping for the UserRegistry . | 72 | 13 |
161,109 | public String getOutputUniqueGroupId ( String inputVirtualRealm ) { // initialize the return value String returnValue = getOutputMapping ( inputVirtualRealm , Service . CONFIG_DO_UNIQUE_GROUP_ID_MAPPING , OUTPUT_UNIQUE_GROUP_ID_DEFAULT ) ; return returnValue ; } | Get the output unique group ID mapping for the UserRegistry . | 72 | 13 |
161,110 | public String getInputGroupSecurityName ( String inputVirtualRealm ) { // initialize the return value String returnValue = getInputMapping ( inputVirtualRealm , Service . CONFIG_DO_GROUP_SECURITY_NAME_MAPPING , INPUT_GROUP_SECURITY_NAME_DEFAULT ) ; return returnValue ; } | Get the input group security name mapping for the UserRegistry . | 72 | 13 |
161,111 | public String getOutputGroupSecurityName ( String inputVirtualRealm ) { // initialize the return value String returnValue = getOutputMapping ( inputVirtualRealm , Service . CONFIG_DO_GROUP_SECURITY_NAME_MAPPING , OUTPUT_GROUP_SECURITY_NAME_DEFAULT ) ; return returnValue ; } | Get the output group security name mapping for the UserRegistry . | 72 | 13 |
161,112 | public String getInputGroupDisplayName ( String inputVirtualRealm ) { // initialize the return value String returnValue = getInputMapping ( inputVirtualRealm , Service . CONFIG_DO_GROUP_DISPLAY_NAME_MAPPING , GROUP_DISPLAY_NAME_DEFAULT ) ; return returnValue ; } | Get the input group display name mapping for the UserRegistry . | 67 | 13 |
161,113 | public String getOutputGroupDisplayName ( String inputVirtualRealm ) { // initialize the return value String returnValue = getOutputMapping ( inputVirtualRealm , Service . CONFIG_DO_GROUP_DISPLAY_NAME_MAPPING , GROUP_DISPLAY_NAME_DEFAULT ) ; return returnValue ; } | Get the output group display name mapping for the UserRegistry . | 67 | 13 |
161,114 | @ FFDCIgnore ( Exception . class ) private String getInputMapping ( String inputVirtualRealm , String inputProperty , String inputDefaultProperty ) { String methodName = "getInputMapping" ; // initialize the return value String returnValue = null ; RealmConfig realmConfig = mappingUtils . getCoreConfiguration ( ) . get... | Get the WIM input property that maps to the UserRegistry input property . | 209 | 16 |
161,115 | private static Object _convertOrCoerceValue ( FacesContext facesContext , UIComponent uiComponent , Object value , SelectItem selectItem , Converter converter ) { Object itemValue = selectItem . getValue ( ) ; if ( converter != null && itemValue instanceof String ) { itemValue = converter . getAsObject ( facesContext ,... | If converter is available and selectItem . value is String uses getAsObject otherwise uses EL type coertion and return result . | 408 | 26 |
161,116 | public final static MessageType getMessageType ( Byte aValue ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( tc , "Value = " + aValue ) ; return set [ aValue . intValue ( ) ] ; } | Returns the corresponding MessageType for a given Byte . This method should NOT be called by any code outside the MFP component . It is only public so that it can be accessed by sub - packages . | 65 | 40 |
161,117 | void balance ( int kFactor , NodeStack stack , GBSNode fpoint , int fpidx , int maxBal ) { /* Get parent of balance point */ GBSNode bparent = stack . node ( fpidx - 1 ) ; switch ( kFactor ) { case 2 : balance2 ( stack , bparent , fpoint , fpidx , maxBal ) ; break ; case 4 : balance4 ( stack , bparent , fpoint , fpidx ... | Balance a fringe following the addition of its final node . | 276 | 11 |
161,118 | private void balance2 ( NodeStack stack , GBSNode bparent , /* Parent of fringe balance point */ GBSNode fpoint , /* Fringe balance point */ int fpidx , /* Index within stack of fpoint */ int maxBal ) /* Maximum allowed fringe imbalance */ { /* k = 2, 2k-1 = 5, k-1 = 1 [A-B-C] [3 children] becomes: *----B----* | | A C ... | Balance a fringe with a K factor of two . | 271 | 10 |
161,119 | private void balance4 ( NodeStack stack , GBSNode bparent , /* Parent of fringe balance point */ GBSNode fpoint , /* Fringe balance point */ int fpidx , /* Index within stack of fpoint */ int maxBal ) /* Maximum allowed fringe imbalance */ { /* k = 4, 2k-1 = 7, k-1 = 3 [A-B-C] [3 children] becomes: *----B----* | | A C ... | Balance a fringe with a K factor of four . | 465 | 10 |
161,120 | private void balance6 ( NodeStack stack , GBSNode bparent , /* Parent of fringe balance point */ GBSNode fpoint , /* Fringe balance point */ int fpidx , /* Index within stack of fpoint */ int maxBal ) /* Maximum allowed fringe imbalance */ { /* k = 6, 2k-1 = 11, k-1 = 5 [A-B-C-D-E] [5 children] becomes: *--C--* | | *-B... | Balance a fringe with a K factor of six . | 567 | 10 |
161,121 | private void balance8 ( NodeStack stack , GBSNode bparent , /* Parent of fringe balance point */ GBSNode fpoint , /* Fringe balance point */ int fpidx , /* Index within stack of fpoint */ int maxBal ) /* Maximum allowed fringe imbalance */ { /* k = 8, 2k-1 = 15, k-1 = 7 [A-B-C-D-E-F-G] [7 children] becomes: *------D---... | Balance a fringe with a K factor of eight . | 749 | 10 |
161,122 | @ Reference ( name = BASE_INSTANCE , service = ContextService . class , cardinality = ReferenceCardinality . OPTIONAL , policy = ReferencePolicy . DYNAMIC , policyOption = ReferencePolicyOption . GREEDY , target = "(id=unbound)" ) protected void setBaseInstance ( ServiceReference < ContextService > ref ) { lock . write... | Declarative Services method for setting the service reference to the base contextService instance . | 110 | 17 |
161,123 | @ Reference ( name = THREAD_CONTEXT_MANAGER , service = WSContextService . class , cardinality = ReferenceCardinality . MANDATORY , policy = ReferencePolicy . STATIC , target = "(component.name=com.ibm.ws.context.manager)" ) protected void setThreadContextManager ( WSContextService svc ) { threadContextMgr = ( ThreadCo... | Declarative Services method for setting the thread context manager . | 91 | 12 |
161,124 | protected void unsetBaseInstance ( ServiceReference < ContextService > ref ) { lock . writeLock ( ) . lock ( ) ; try { threadContextConfigurations = null ; } finally { lock . writeLock ( ) . unlock ( ) ; } } | Declarative Services method for unsetting the service reference to the base contextService instance . | 52 | 18 |
161,125 | @ Override public synchronized void complete ( ) { if ( com . ibm . ejs . ras . TraceComponent . isAnyTracingEnabled ( ) && logger . isLoggable ( Level . FINEST ) ) { logger . entering ( CLASS_NAME , "complete" , this ) ; } if ( ! lockHeldByDifferentThread ( ) ) { //We can't call this or WebContainer won't know to run ... | we re okay to sync on the scheduling of the complete | 485 | 11 |
161,126 | @ Override public synchronized void dispatch ( ServletContext context , String path ) throws IllegalStateException { if ( com . ibm . ejs . ras . TraceComponent . isAnyTracingEnabled ( ) && logger . isLoggable ( Level . FINEST ) ) { logger . entering ( CLASS_NAME , "dispatch(ctx,path)" , new Object [ ] { this , context... | we re okay to sync on the scheduling of the dispatch | 569 | 11 |
161,127 | public final void commit_one_phase ( ) throws XAException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "commit_one_phase" , _resource ) ; if ( tcSummary . isDebugEnabled ( ) ) Tr . debug ( tcSummary , "commit_one_phase" , this ) ; // // Commit the one-phase resource. // try { _resource . commit ( _xid , true ) ; ... | Commit a transaction using one - phase optimization . | 243 | 10 |
161,128 | public final void rollback ( ) throws XAException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "rollback" , _resource ) ; if ( tcSummary . isDebugEnabled ( ) ) Tr . debug ( tcSummary , "rollback" , this ) ; try { _resource . rollback ( _xid ) ; // Record the vote. // _completedCommit defaults to false. _vote = JT... | Rollback a transaction . | 210 | 5 |
161,129 | public final void forget ( ) throws XAException { if ( tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "forget" , _resource ) ; Tr . exit ( tc , "forget" ) ; } } | The resource manager can forget all knowledge of the transaction . Only allowed because commit_one_phase may return heuristic | 51 | 23 |
161,130 | private void verifyConfiguration ( ) throws DeploymentException { Map < URL , ModuleMetaData > mmds = getModuleMetaDataMap ( ) ; if ( mmds != null ) { for ( Map . Entry < URL , ModuleMetaData > entry : mmds . entrySet ( ) ) { ModuleMetaData mmd = entry . getValue ( ) ; if ( mmd instanceof WebModuleMetaData ) { String j... | make sure that there is one HAM for each modules and if there is a HAM in a module make sure there is no login configuration in web . xml . | 508 | 31 |
161,131 | private String getModuleFromClass ( Class < ? > klass , Map < String , ModuleProperties > moduleMap ) { String file = getClassFileLocation ( klass ) ; if ( tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "File name : " + file ) ; } String moduleName = null ; for ( Map . Entry < String , ModuleProperties > entry : moduleM... | Identify the module name from the class . If the class exists in the jar file return war file name if it is located under the war file otherwise returning jar file name . | 272 | 35 |
161,132 | private Properties getGlobalLoginBasicProps ( ) throws Exception { String realm = getWebAppSecurityConfig ( ) . getBasicAuthRealmName ( ) ; Properties props = new Properties ( ) ; if ( realm == null ) { if ( tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "basicAuthenticationMechanismRealmName is not set. the default val... | Returns BasicAuth realm name for container override basic login | 171 | 10 |
161,133 | private Properties getGlobalLoginFormProps ( ) throws Exception { WebAppSecurityConfig webAppSecConfig = getWebAppSecurityConfig ( ) ; String loginURL = webAppSecConfig . getLoginFormURL ( ) ; String errorURL = webAppSecConfig . getLoginErrorURL ( ) ; if ( loginURL == null || loginURL . isEmpty ( ) ) { Tr . error ( tc ... | Returns LoginToContinue properties for container override form login | 674 | 10 |
161,134 | private void initialize ( Map < String , Object > metadata ) { if ( metadata == null ) { metadata = new HashMap < String , Object > ( ) ; } metadata . put ( REQUEST_ID , generateRequestID ( ) ) ; this . metadata = metadata ; } | Generates a new metadata Map if none is given . Generates and adds a request ID to the metadata . | 57 | 22 |
161,135 | @ Override public void addObserver ( Observer observer ) { super . addObserver ( observer ) ; if ( countObservers ( ) > 1 ) { super . deleteObserver ( observer ) ; AbstractConnectionFactoryService cfSvc = ( AbstractConnectionFactoryService ) observer ; Object [ ] params = new Object [ ] { CONNECTION_MANAGER , name , cf... | Add an observer for this connection manager service . | 145 | 9 |
161,136 | @ Override public void destroyConnectionFactories ( ) { final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) { final String pmName ; if ( pm != null ) pmName = pm . getUniqueId ( ) ; else pmName = "factory name not avaiable" ; Tr . entry ( this , tc , "destroyConnecti... | Destroy all connection factories that are using this connection manager service . | 296 | 12 |
161,137 | private final CMConfigData getCMConfigData ( AbstractConnectionFactoryService cfSvc , ResourceInfo refInfo ) { final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . entry ( this , tc , "getCMConfigData" ) ; // Defaults for direct lookup int auth = J2CConstants . A... | Construct the CMConfigData including properties from the resource reference if applicable . | 522 | 14 |
161,138 | @ Override public ConnectionManager getConnectionManager ( ResourceInfo refInfo , AbstractConnectionFactoryService svc ) throws ResourceException { final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . entry ( this , tc , "getConnectionManager" , refInfo , svc ) ;... | Returns the connection manager for this configuration . This method lazily initializes the connection manager service if necessary . | 394 | 21 |
161,139 | private final static HashMap < String , String > toHashMap ( List < ? extends ResourceInfo . Property > propList ) { if ( propList == null ) return null ; HashMap < String , String > propMap = new HashMap < String , String > ( ) ; for ( ResourceInfo . Property prop : propList ) propMap . put ( prop . getName ( ) , prop... | Utility method that converts a list of properties to HashMap . | 94 | 13 |
161,140 | @ Override @ FFDCIgnore ( BAD_OPERATION . class ) public Object narrow ( Object narrowFrom , @ SuppressWarnings ( "rawtypes" ) Class narrowTo ) throws ClassCastException { if ( narrowFrom == null ) { return null ; } if ( narrowTo . isInstance ( narrowFrom ) ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDe... | An implementation of narrow that always attempts to load stub classes from the class loader before dynamically generating a stub class . | 489 | 22 |
161,141 | private void scanClasses ( ) throws PersistenceUnitScannerException { try { for ( URL url : urlSet ) { final HashSet < ClassInfoType > citSet = new HashSet < ClassInfoType > ( ) ; final String urlProtocol = url . getProtocol ( ) ; if ( "file" . equalsIgnoreCase ( urlProtocol ) ) { // Protocol is "file", which either ad... | Scan classes in persistence unit root and referenced jar - files | 320 | 11 |
161,142 | private void scanEntityMappings ( ) throws PersistenceUnitScannerException { /* * From the JPA 2.1 Specification: * * 8.2.1.6.2 Object/relational Mapping Files * An object/relational mapping XML file contains mapping information for the classes listed in it. * * A object/relational mapping XML file named orm.xml may be... | Scan Entity Mappings Files | 716 | 5 |
161,143 | private List < URL > findORMResources ( PersistenceUnitInfo pui , String ormFileName ) throws IOException { final boolean isMetaInfoOrmXML = "META-INF/orm.xml" . equals ( ormFileName ) ; final ArrayList < URL > retArr = new ArrayList < URL > ( ) ; Enumeration < URL > ormEnum = pui . getClassLoader ( ) . getResources ( ... | Finds all specified ORM files by name constrained in location by the persistence unit root and jar files . | 339 | 21 |
161,144 | public boolean writeSilence ( SIMPMessage m ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "writeSilence" , new Object [ ] { m } ) ; JsMessage jsMsg = m . getMessage ( ) ; // There may be Completed ticks after the Value, if so then // write... | This method uses a Value message to write Silence into the stream either because a message has been filtered out or because it has been rolled back | 414 | 27 |
161,145 | public void writeSilence ( ControlSilence m ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "writeSilence" , new Object [ ] { m } ) ; boolean sendMessage = false ; // to use in messages sent downstream long completedPrefix ; // Construct a T... | This method writes the ticks in a Silence message into the stream It is called when a Silence message arrives from another ME If the RequestedOnly flag in the message is set then the message is only sent on to downstream MEs if they have previously requested it . Otherwise it is always sent . | 569 | 58 |
161,146 | public void writeAckPrefix ( long stamp ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "writeAckPrefix" , Long . valueOf ( stamp ) ) ; synchronized ( this ) { // SIB0105 // Update controllable health state if poss if ( stamp >= lastAckExpTi... | This method is called when an Ack message is recieved from a downstream ME . It updates the ackPrefix of the stream and then passes the message up to the PubSubInputHandler which will aggregate the Acks from all InternalOutputStreams . | 389 | 51 |
161,147 | public void writeSilenceForced ( TickRange vtr ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "writeSilenceForced" , new Object [ ] { vtr } ) ; long start = vtr . startstamp ; long end = vtr . endstamp ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEn... | This method uses a Value TickRange to write Silence into the stream because a message has expired before it was sent and so needs to be removed from the stream It forces the stream to be updated to Silence without checking the existing state It then updates the upstream control with this new completed prefix | 348 | 56 |
161,148 | public static final byte [ ] serialize ( Serializable serializable ) throws IOException { if ( serializable == null ) { return null ; } ByteArrayOutputStream byteArrayOutputStream = new ByteArrayOutputStream ( ) ; ObjectOutputStream objectOutputStream = null ; byte [ ] result = null ; if ( null != _instance ) { Seriali... | This serializes an object into a byte array . | 212 | 10 |
161,149 | public Object nextElement ( ) { try { return nextElementR ( ) ; } catch ( NoMoreElementsException e ) { // FFDCFilter.processException(e, CLASS_NAME + ".nextElement", "109", this); throw new NoSuchElementException ( ) ; } catch ( EnumeratorException e ) { // FFDCFilter.processException(e, CLASS_NAME + ".nextElement", "... | Obtain the next element from the enumeration | 202 | 9 |
161,150 | public boolean hasMoreElements ( ) { try { return hasMoreElementsR ( ) ; } catch ( NoMoreElementsException e ) { // FFDCFilter.processException(e, CLASS_NAME + ".hasMoreElements", "131", this); return false ; } catch ( EnumeratorException e ) { // FFDCFilter.processException(e, CLASS_NAME + ".hasMoreElements", "134", t... | Find out if there are any more elements available | 208 | 9 |
161,151 | public synchronized boolean hasMoreElementsR ( ) throws RemoteException , EnumeratorException { if ( elements != null && index < elements . length ) { return true ; } else if ( ! exhausted ) { // Reset our local cache and attempt to fetch the next batch // from the server try { elements = null ; index = 0 ; elements = ... | Find out if there are any more elements available ; this method will perform prefetching from the remote result set . | 147 | 23 |
161,152 | public synchronized Object [ ] nextNElements ( int n ) throws RemoteException , EnumeratorException { if ( ! hasMoreElementsR ( ) ) { throw new NoMoreElementsException ( ) ; } EJBObject [ ] remainder = null ; final int numCached = elements . length - index ; if ( ! exhausted && numCached < n ) { // We must fetch more e... | Obtain the next n elements from the enumeration ; the array may contain fewer than n elements if the enumeration is exhausted . | 286 | 26 |
161,153 | public EJBObject [ ] loadEntireCollection ( ) { EJBObject [ ] result = null ; try { result = ( EJBObject [ ] ) allRemainingElements ( ) ; } catch ( NoMoreElementsException e ) { // FFDCFilter.processException(e, CLASS_NAME + ".loadEntireCollection", // "270", this); return elements ; } catch ( EnumeratorException e ) {... | Load the entire result set in a greedy fashion . This is required to support methods on the Collection interface | 186 | 20 |
161,154 | public synchronized Object [ ] allRemainingElements ( ) throws RemoteException , EnumeratorException { if ( ! hasMoreElementsR ( ) ) { throw new NoMoreElementsException ( ) ; } EJBObject [ ] remainder = null ; if ( ! exhausted ) { // We must fetch the remaining elements from the remote // result set try { //110799 rema... | Obtain all of the remaining elements from the enumeration | 355 | 11 |
161,155 | void close ( ) { synchronized ( ivPuList ) { for ( JPAPUnitInfo puInfo : ivPuList . values ( ) ) { puInfo . close ( ) ; } ivPuList . clear ( ) ; } } | Close all the active EntityManagers declared in this persistence . xml . | 51 | 14 |
161,156 | JPAPUnitInfo addPU ( String puName , JPAPUnitInfo puInfo ) { synchronized ( ivPuList ) { return ivPuList . put ( puName , puInfo ) ; } } | Adds the puInfo to the collection maintained in this xml info object . | 44 | 14 |
161,157 | StringBuilder toStringBuilder ( StringBuilder sbuf ) { synchronized ( ivPuList ) { sbuf . append ( "\n PxmlInfo: ScopeName=" ) . append ( ivScopeInfo . getScopeName ( ) ) . append ( "\tRootURL = " ) . append ( ivRootURL ) . append ( "\t# PUs = " ) . append ( ivPuList . size ( ) ) . append ( "\t[" ) ; int index = 0 ; fo... | Dump this persistence . xml data to the input StringBuilder . | 172 | 13 |
161,158 | private static void restoreInvocationSubject ( SubjectCookie cookie ) { try { if ( cookie . token != null ) { // We sync'ed the subject's identity to the thread under setInvocationSubject. // Now restore the previous identity using the token returned when we sync'ed. ThreadIdentityManager . resetChecked ( cookie . toke... | Restore the invocation subject . | 134 | 6 |
161,159 | public RetryState createRetryState ( RetryPolicy policy , MetricRecorder metricRecorder ) { if ( policy == null ) { return new RetryStateNullImpl ( ) ; } else { return new RetryStateImpl ( policy , metricRecorder ) ; } } | Create an object implementing Retry | 59 | 6 |
161,160 | public SyncBulkheadState createSyncBulkheadState ( BulkheadPolicy policy , MetricRecorder metricRecorder ) { if ( policy == null ) { return new SyncBulkheadStateNullImpl ( ) ; } else { return new SyncBulkheadStateImpl ( policy , metricRecorder ) ; } } | Create an object implementing a synchronous Bulkhead | 67 | 9 |
161,161 | public TimeoutState createTimeoutState ( ScheduledExecutorService executorService , TimeoutPolicy policy , MetricRecorder metricRecorder ) { if ( policy == null ) { return new TimeoutStateNullImpl ( ) ; } else { return new TimeoutStateImpl ( executorService , policy , metricRecorder ) ; } } | Create an object implementing Timeout | 71 | 6 |
161,162 | public CircuitBreakerState createCircuitBreakerState ( CircuitBreakerPolicy policy , MetricRecorder metricRecorder ) { if ( policy == null ) { return new CircuitBreakerStateNullImpl ( ) ; } else { return new CircuitBreakerStateImpl ( policy , metricRecorder ) ; } } | Create an object implementing CircuitBreaker | 65 | 7 |
161,163 | public Object [ ] getResults ( String topic ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getResults" , topic ) ; if ( cachedResults != null ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "getResults" , cachedResu... | postProcessMatches methods of the handlers . | 161 | 9 |
161,164 | protected String createPlainTextJWT ( ) { com . google . gson . JsonObject header = createHeader ( ) ; com . google . gson . JsonObject payload = createPayload ( ) ; String plainTextTokenString = computeBaseString ( header , payload ) ; StringBuffer sb = new StringBuffer ( plainTextTokenString ) ; sb . append ( "." ) .... | Creates the plain text JWT . | 100 | 8 |
161,165 | private ConnectionData findConnectionDataToUse ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "findConnectionDataToUse" ) ; // Look through the the connection data in this group to try and find // a connection with the lowest use count. ConnectionData connec... | Helper method chooses the connection to use for a new conversation . | 408 | 12 |
161,166 | private Conversation doConnect ( ConversationReceiveListener conversationReceiveListener , ConversationUsageType usageType , JFapAddressHolder jfapAddressHolder , final NetworkConnectionFactoryHolder ncfHolder ) throws JFapConnectFailedException , SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && t... | Actually do the connecting creating a new ConnectionData if required | 781 | 11 |
161,167 | private NetworkConnection connectOverNetwork ( JFapAddressHolder addressHolder , NetworkConnectionFactoryHolder factoryHolder ) throws JFapConnectFailedException , FrameworkException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "connectOverNetwork" , new Objec... | Create a new connection over the network | 430 | 7 |
161,168 | private ConnectionData createnewConnectionData ( NetworkConnection vc ) throws FrameworkException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "createnewConnectionData" , vc ) ; ConnectionData connectionDataToUse ; NetworkConnectionContext connLink = vc . getN... | Create a new Connection data object | 241 | 6 |
161,169 | private Conversation startNewConversation ( ConnectionData connectionDataToUse , ConversationReceiveListener conversationReceiveListener , boolean isNewConnectionData , boolean handshake ) throws SIResourceException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc ,... | start a new conversation using the specified ConnectionData object | 285 | 10 |
161,170 | protected synchronized void connectionPending ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "connectionPending" ) ; ++ connectAttemptsPending ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , connectAtt... | Marks the group as having been selected to establish a new conversation . This is used to close a window where the group can be selected but then get closed before the connect call is made . | 136 | 38 |
161,171 | protected synchronized void close ( OutboundConnection connection ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "close" , connection ) ; // Paranoia: Check that this connection believes that it belongs in this group. if ( connection . getConnectionData ( ) . ... | Close a conversation on the specified connection . The connection must be part of this group . If the connection has no more conversations left using it then it is added to the idle pool . | 366 | 36 |
161,172 | protected boolean isEmpty ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "isEmpty" ) ; boolean result ; synchronized ( this ) { synchronized ( connectionData ) { result = connectionData . isEmpty ( ) ; } result = result && ( connectAttemptsPending == 0 ) ; }... | Determines if this group is empty . For the group to be empty it must contain no connection data objects and have no connection attempts pending . This second criteria stops the group from being discarded between selection for establishing a new conversation and actually establishing the conversation . | 128 | 51 |
161,173 | protected void purgeFromInvalidateImpl ( OutboundConnection connection , boolean notifyPeer ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "purgeFromInvalidateImpl" , new Object [ ] { connection , Boolean . valueOf ( notifyPeer ) } ) ; purge ( connection , tru... | Purge a connection from this group from within invalidate processing . Purging a connection removes it from the group even if the connection still has conversations associated with it . The purged connection is closed and not added to the idle pool . | 131 | 47 |
161,174 | protected void purgeClosedConnection ( OutboundConnection connection ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "purgeClosedConnection" , connection ) ; purge ( connection , false , false ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEna... | Purge a connection from this group because it has already been closed . The purged connection is not added to the idle pool . | 105 | 26 |
161,175 | public void removeConnectionDataFromGroup ( ConnectionData cd ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "removeConnectionDataFromGroup" , new Object [ ] { cd } ) ; boolean removed = false ; synchronized ( connectionData ) { removed = connectionData . remo... | Remove the connection from the group | 132 | 6 |
161,176 | public static String getDateString ( Date date ) { SimpleDateFormat sdf = new SimpleDateFormat ( sdformatMillisec ) ; sdf . setTimeZone ( TimeZone . getTimeZone ( "GMT" ) ) ; StringBuffer dateBuffer = new StringBuffer ( sdf . format ( date ) ) ; // above string is in this format // 2005-05-04T09:34:18.444-0400 // conve... | Returns a date String from the specified Date object . It is expected to be called before passing the date to SDO set method . | 140 | 26 |
161,177 | public static String [ ] getRDNAttributes ( String dn ) { String rdnstr = getRDN ( dn ) ; StringTokenizer st = new StringTokenizer ( rdnstr . toLowerCase ( ) , "+" ) ; List < String > list = new ArrayList < String > ( ) ; while ( st . hasMoreTokens ( ) ) { String rdn = st . nextToken ( ) ; int index = rdn . indexOf ( '... | Return an array of RDN attributes of the given DN in lower case form . | 143 | 16 |
161,178 | public static String getRDN ( String DN ) { if ( DN == null || DN . trim ( ) . length ( ) == 0 ) { return DN ; } String RDN = null ; try { LdapName name = new LdapName ( DN ) ; if ( name . size ( ) == 0 ) { return DN ; } RDN = name . get ( name . size ( ) - 1 ) ; } catch ( InvalidNameException e ) { e . getMessage ( ) ... | Gets the RDN from the specified DN For example uid = persona will be returned for given uid = persona cn = users dc = yourco dc = com . | 200 | 36 |
161,179 | static public LdapURL [ ] getLdapURLs ( Attribute attr ) throws WIMException { final String METHODNAME = "getLdapURLs" ; LdapURL [ ] ldapURLs = new LdapURL [ 0 ] ; if ( attr != null ) { List < LdapURL > ldapURLList = new ArrayList < LdapURL > ( attr . size ( ) ) ; try { for ( NamingEnumeration < ? > enu = attr . getAll... | Gets the LdapURL array from the given dynamic member attribute . | 350 | 15 |
161,180 | public static String getUniqueKey ( X509Certificate cert ) { // TBD - Would like to use public key instead of subject name, but // cert.getPublicKey().getEncoded() appears to return different // values for each call, using the same certificate?? StringBuffer key = new StringBuffer ( "subjectDN:" ) ; key . append ( cert... | Get a unique key for a certificate . | 149 | 8 |
161,181 | static String getDNSubField ( String varName , String DN ) throws CertificateMapperException { if ( varName . equals ( "DN" ) ) { return DN ; // return the whole DN } // Parse the DN looking for 'varName' StringTokenizer st = new StringTokenizer ( DN ) ; for ( ; ; ) { String name , value ; try { name = st . nextToken (... | Given input return the digest version . | 211 | 7 |
161,182 | public static short getMembershipScope ( String scope ) { if ( scope != null ) { scope = scope . trim ( ) ; if ( LdapConstants . LDAP_DIRECT_GROUP_MEMBERSHIP_STRING . equalsIgnoreCase ( scope ) ) { return LdapConstants . LDAP_DIRECT_GROUP_MEMBERSHIP ; } else if ( LdapConstants . LDAP_NESTED_GROUP_MEMBERSHIP_STRING . eq... | Gets the short form the scope from the string form of the scope | 255 | 14 |
161,183 | public static boolean inAttributes ( String attrName , Attributes attrs ) { for ( NamingEnumeration < String > neu = attrs . getIDs ( ) ; neu . hasMoreElements ( ) ; ) { String attrId = neu . nextElement ( ) ; if ( attrId . equalsIgnoreCase ( attrName ) ) { return true ; } } return false ; } | Whether the specified attribute name is contained in the attributes . | 88 | 11 |
161,184 | public static Attribute cloneAttribute ( String newAttrName , Attribute attr ) throws WIMSystemException { Attribute newAttr = new BasicAttribute ( newAttrName ) ; try { for ( NamingEnumeration < ? > neu = attr . getAll ( ) ; neu . hasMoreElements ( ) ; ) { newAttr . add ( neu . nextElement ( ) ) ; } } catch ( NamingEx... | Clone the specified attribute with a new name . | 168 | 10 |
161,185 | public static String convertToDashedString ( byte [ ] objectGUID ) { StringBuilder displayStr = new StringBuilder ( ) ; displayStr . append ( prefixZeros ( objectGUID [ 3 ] & 0xFF ) ) ; displayStr . append ( prefixZeros ( objectGUID [ 2 ] & 0xFF ) ) ; displayStr . append ( prefixZeros ( objectGUID [ 1 ] & 0xFF ) ) ; di... | Convert the byte array to Active Directory GUID format . | 426 | 12 |
161,186 | public static JsonValue serializeAsJson ( Object o ) throws IOException { try { return findFieldsToSerialize ( o ) . mainObject ; } catch ( IllegalStateException ise ) { // the reflective attempt to build the object failed. throw new IOException ( "Unable to build JSON for Object" , ise ) ; } catch ( JsonException e ) ... | Convert a POJO into a serialized JsonValue object | 102 | 13 |
161,187 | private static ClassAndMethod getClassForFieldName ( String fieldName , Class < ? > classToLookForFieldIn ) { return internalGetClassForFieldName ( fieldName , classToLookForFieldIn , false ) ; } | Gets a class for a JSON field name by looking in a given Class for an appropriate setter . The setter is assumed not to be a Collection . | 49 | 32 |
161,188 | private static ClassAndMethod getClassForCollectionOfFieldName ( String fieldName , Class < ? > classToLookForFieldIn ) { return internalGetClassForFieldName ( fieldName , classToLookForFieldIn , true ) ; } | Gets a class for a JSON field name by looking in a given Class for an appropriate setter . The setter is assumed to be a Collection . | 51 | 31 |
161,189 | private static ClassAndMethod internalGetClassForFieldName ( String fieldName , Class < ? > classToLookForFieldIn , boolean isForArray ) { Method found = null ; //precalc the field name as a setter to use for each method test. String fieldNameAsASetter = new StringBuilder ( "set" ) . append ( fieldName . substring ( 0 ... | Utility method given a JSON field name and an associated POJO it will hunt for the appropriate setter to use and if located return the type the setter expects along with a reflected reference to the method itself . | 403 | 43 |
161,190 | public static void addThreadIdentityService ( ThreadIdentityService tis ) { if ( tis != null ) { threadIdentityServices . add ( tis ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "A ThreadIdentityService implementation was added." , tis . getClass ( ) . getName ( ) ) ... | Add a ThreadIdentityService reference . This method is called by ThreadIdentityManagerConfigurator when a ThreadIdentityService shows up in the OSGI framework . | 92 | 34 |
161,191 | public static void addJ2CIdentityService ( J2CIdentityService j2cIdentityService ) { if ( j2cIdentityService != null ) { j2cIdentityServices . add ( j2cIdentityService ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "A J2CIdentityService implementation was added." , j2... | Add a J2CIdentityService reference . This method is called by ThreadIdentityManagerConfigurator when a J2CIdentityService shows up in the OSGI framework . | 116 | 38 |
161,192 | public static void removeThreadIdentityService ( ThreadIdentityService tis ) { if ( tis != null ) { threadIdentityServices . remove ( tis ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "A ThreadIdentityService implementation was removed." , tis . getClass ( ) . getNam... | Remove a ThreadIdentityService reference . This method is called by ThreadIdentityManagerConfigurator when a ThreadIdentityService leaves the OSGI framework . | 92 | 32 |
161,193 | public static void removeJ2CIdentityService ( J2CIdentityService j2cIdentityService ) { if ( j2cIdentityService != null ) { j2cIdentityServices . remove ( j2cIdentityService ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "A J2CIdentityService implementation was remove... | Remove a J2CIdentityService reference . This method is called by ThreadIdentityManagerConfigurator when a J2CIdentityService leaves the OSGI framework . | 116 | 36 |
161,194 | public static void removeAllThreadIdentityServices ( ) { threadIdentityServices . clear ( ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "All the ThreadIdentityService implementations were removed." ) ; } } | Remove all the ThreadIdentityService references . This method is called by ThreadIdentityManagerConfigurator when the ThreadIdentityService service tracker is closed . | 64 | 32 |
161,195 | public static void removeAllJ2CIdentityServices ( ) { j2cIdentityServices . clear ( ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "All the J2CIdentityService implementations were removed." ) ; } } | Remove all the J2CIdentityService references . This method is called by ThreadIdentityManagerConfigurator when the J2CIdentityService service tracker is closed . | 70 | 36 |
161,196 | private static boolean checkForRecursionAndSet ( ) { if ( recursionMarker . get ( ) == null ) { recursionMarker . set ( Boolean . TRUE ) ; return false ; } else { return true ; // recursion detected. } } | Check for recursion . | 54 | 5 |
161,197 | public static Object runAsServer ( ) { LinkedHashMap < ThreadIdentityService , Object > token = null ; if ( ! checkForRecursionAndSet ( ) ) { try { for ( int i = 0 , size = threadIdentityServices . size ( ) ; i < size ; ++ i ) { ThreadIdentityService tis = threadIdentityServices . get ( i ) ; if ( tis . isAppThreadIden... | Set the server s identity as the thread identity . | 170 | 10 |
161,198 | @ SuppressWarnings ( { "rawtypes" } ) private static void resetCheckedInternal ( Object token , Exception firstException ) throws ThreadIdentityException { Exception cachedException = firstException ; if ( threadIdentityServices . isEmpty ( ) == false || j2cIdentityServices . isEmpty ( ) == false ) { if ( ! checkForRec... | Reset the identity on the thread . | 378 | 8 |
161,199 | public static Subject getJ2CInvocationSubject ( ) { Subject j2cSubject = null ; for ( J2CIdentityService j2cIdentityService : j2cIdentityServices ) { if ( j2cIdentityService . isJ2CThreadIdentityEnabled ( ) ) { Subject subject = j2cIdentityService . getJ2CInvocationSubject ( ) ; if ( subject != null ) { j2cSubject = su... | Get a J2C subject based on the invocation subject . Use first subject that is not null . | 111 | 20 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.