idx int64 0 165k | question stringlengths 73 4.15k | target stringlengths 5 918 | len_question int64 21 890 | len_target int64 3 255 |
|---|---|---|---|---|
162,300 | public static boolean waitForPageResponse ( HtmlPage page , String responseMessage ) throws InterruptedException { int i = 0 ; boolean isTextFound = false ; while ( ! isTextFound && i < 5 ) { isTextFound = page . asText ( ) . contains ( responseMessage ) ; i ++ ; Thread . sleep ( 1000 ) ; Log . info ( c , "waitForPageR... | Create a custom wait mechanism that waits for any background JavaScript to finish and verifies a message in the page response . | 122 | 23 |
162,301 | @ FFDCIgnore ( InvocationTargetException . class ) @ Override public Object invoke ( Object proxy , Method method , Object [ ] args ) throws Throwable { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "invoke" , method . toGenericString ( ) ) ; if ( actualMessageOb... | While Async send operation is in progress do not allow application to access message object | 339 | 16 |
162,302 | public static boolean hasClientBehavior ( String eventName , Map < String , List < ClientBehavior > > behaviors , FacesContext facesContext ) { if ( behaviors == null ) { return false ; } return ( behaviors . get ( eventName ) != null ) ; } | Checks if the given component has a behavior attachment with a given name . | 56 | 15 |
162,303 | public static boolean renderBehaviorizedAttribute ( FacesContext facesContext , ResponseWriter writer , String componentProperty , UIComponent component , String eventName , Collection < ClientBehaviorContext . Parameter > eventParameters , Map < String , List < ClientBehavior > > clientBehaviors , String htmlAttrName ... | Render an attribute taking into account the passed event the component property and the passed attribute value for the component property . The event will be rendered on the selected htmlAttrName . | 123 | 35 |
162,304 | public static boolean isHideNoSelectionOption ( UIComponent component ) { // check hideNoSelectionOption for literal value (String) or ValueExpression (Boolean) Object hideNoSelectionOptionAttr = component . getAttributes ( ) . get ( JSFAttr . HIDE_NO_SELECTION_OPTION_ATTR ) ; return ( ( hideNoSelectionOptionAttr insta... | Returns the value of the hideNoSelectionOption attribute of the given UIComponent | 140 | 18 |
162,305 | public static void renderUnhandledFacesMessages ( FacesContext facesContext ) throws IOException { // create and configure HtmlMessages component HtmlMessages messages = ( HtmlMessages ) facesContext . getApplication ( ) . createComponent ( HtmlMessages . COMPONENT_TYPE ) ; messages . setId ( "javax_faces_developmentst... | Renders all FacesMessages which have not been rendered yet with the help of a HtmlMessages component . | 137 | 23 |
162,306 | protected void deactivate ( ComponentContext compcontext ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Deactivating " + this ) ; } INSTANCE . compareAndSet ( this , null ) ; } | DS method to deactivate this component | 62 | 7 |
162,307 | protected void updateConfiguration ( Map < String , Object > properties ) { if ( properties != null ) { this . properties . clear ( ) ; this . properties . putAll ( properties ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Current Properties: " + this . properties ... | Updates the current configuration properties | 81 | 6 |
162,308 | @ Override public boolean isImplicitBeanArchivesScanningDisabled ( ) { boolean enableImplicitBeanArchivesValue = ( Boolean ) this . properties . get ( "enableImplicitBeanArchives" ) ; if ( tc . isWarningEnabled ( ) && ! hasLoggedNoImplicitMsg && ! enableImplicitBeanArchivesValue ) { hasLoggedNoImplicitMsg = true ; Tr .... | Get the Container level configuration about whether to disable the scanning for implicit bean archives . If the value is true it means CDI Container will not scan archives without beans . xml to see whether they are implicit archives . | 128 | 42 |
162,309 | @ FFDCIgnore ( InjectionException . class ) private void processPostConstruct ( ) { ApplicationClient appClient = ( ( ClientModuleMetaData ) cmd . getModuleMetaData ( ) ) . getAppClient ( ) ; boolean isMetadataComplete = appClient . isMetadataComplete ( ) ; LifecycleCallbackHelper helper = new LifecycleCallbackHelper (... | Process PostContruct annotation or metadata for Main class or Login Callback class . | 205 | 16 |
162,310 | @ FFDCIgnore ( InjectionException . class ) private void processPreDestroy ( ) { ApplicationClient appClient = ( ( ClientModuleMetaData ) cmd . getModuleMetaData ( ) ) . getAppClient ( ) ; boolean isMetadataComplete = appClient . isMetadataComplete ( ) ; LifecycleCallbackHelper helper = new LifecycleCallbackHelper ( is... | Process PreDestroy annotation or metadata for Login Callback class . | 194 | 12 |
162,311 | @ Override public void introspect ( final PrintWriter writer ) throws Exception { // Put out a header before the information writer . println ( "Network Interface Information" ) ; writer . println ( "-----------------------------" ) ; // Extract the interface information inside a doPriv try { AccessController . doPrivi... | Introspect all network interfaces for diagnostic information . | 172 | 10 |
162,312 | private void getInterfaceInfo ( NetworkInterface networkInterface , PrintWriter out ) throws IOException { final String indent = " " ; // Basic information from the interface out . println ( ) ; out . append ( "Interface: " ) . append ( networkInterface . getDisplayName ( ) ) . println ( ) ; out . append ( indent ) . a... | Capture interface specific information and write it to the provided writer . | 625 | 12 |
162,313 | private Object invoke ( Method method , Object [ ] args ) throws IllegalAccessException , InvocationTargetException { ArrayList < ThreadContext > contextAppliedToThread = threadContextDescriptor . taskStarting ( ) ; try { return method . invoke ( object , args ) ; } finally { threadContextDescriptor . taskStopping ( co... | Apply context invoke the method then remove the context from the thread . | 79 | 13 |
162,314 | private synchronized void initialize ( ) { if ( ! _initialized ) { FacesContext context = FacesContext . getCurrentInstance ( ) ; if ( isFacelets2Enabled ( context ) ) { logWarningIfLegacyFaceletViewHandlerIsPresent ( context ) ; if ( MyfacesConfig . getCurrentInstance ( context . getExternalContext ( ) ) . isSupportJS... | Initialize the supported view declaration languages . | 233 | 8 |
162,315 | private boolean isFacelets2Enabled ( FacesContext context ) { String param = context . getExternalContext ( ) . getInitParameter ( PARAM_DISABLE_JSF_FACELET ) ; boolean facelets2ParamDisabled = ( param != null && Boolean . parseBoolean ( param . toLowerCase ( ) ) ) ; return ! facelets2ParamDisabled ; } | Determines if the current application uses Facelets - 2 . To accomplish that it looks at the init param javax . faces . DISABLE_FACELET_JSF_VIEWHANDLER | 80 | 41 |
162,316 | @ FFDCIgnore ( { MissingResourceException . class , IllegalArgumentException . class } ) protected static Logger createLogger ( final Class < ? > cls , String name , String loggerName ) { ClassLoader orig = getContextClassLoader ( ) ; ClassLoader n = getClassLoader ( cls ) ; if ( n != null ) { setContextClassLoader ( n... | Create a logger | 596 | 3 |
162,317 | public static void log ( Logger logger , Level level , String message , Throwable throwable , Object parameter ) { if ( logger . isLoggable ( level ) ) { final String formattedMessage = MessageFormat . format ( localize ( logger , message ) , parameter ) ; doLog ( logger , level , formattedMessage , throwable ) ; } } | Allows both parameter substitution and a typed Throwable to be logged . | 74 | 13 |
162,318 | private static String localize ( Logger logger , String message ) { ResourceBundle bundle = logger . getResourceBundle ( ) ; try { return bundle != null ? bundle . getString ( message ) : message ; } catch ( MissingResourceException ex ) { //string not in the bundle return message ; } } | Retrieve localized message retrieved from a logger s resource bundle . | 65 | 12 |
162,319 | public synchronized int add ( Object value ) throws IdTableFullException { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "add" , value ) ; if ( value == null ) throw new SIErrorException ( nls . getFormattedMessage ( "IDTABLE_INTERNAL_SICJ0050" , null , "IDTABLE_INTERNAL_SICJ0050" ) ) ; // D226232 int id =... | Adds an object to the table and returns the ID associated with the object in the table . The object will never be assigned an ID which clashes with another object . | 414 | 32 |
162,320 | public synchronized Object remove ( int id ) throws IllegalArgumentException { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "remove" , "" + id ) ; Object returnValue = get ( id ) ; if ( returnValue != null ) table [ id ] = null ; if ( id < lowestPossibleFree ) lowestPossibleFree = id ; // If the ID remove... | Removes an object from the table . | 191 | 8 |
162,321 | public synchronized Object get ( int id ) throws IllegalArgumentException { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "get" , "" + id ) ; if ( ( id < 1 ) || ( id > maxSize ) ) throw new SIErrorException ( nls . getFormattedMessage ( "IDTABLE_INTERNAL_SICJ0050" , null , "IDTABLE_INTERNAL_SICJ0050" ) ) ;... | Gets an object from the table by ID . Returns the object associated with the specified ID . It is valid to specify an ID which does not have an object associated with it . In this case a value of null is returned . | 167 | 46 |
162,322 | private void growTable ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "growTable" ) ; int newSize = Math . min ( table . length + TABLE_GROWTH_INCREMENT , maxSize ) ; if ( tc . isDebugEnabled ( ) ) SibTr . debug ( this , tc , "existing size=" + table . length + " new size=" + newSize ) ; Object [ ] ne... | Helper method which increases the size of the table by a factor of TABLE_GROWTH_INCREMENT until the maximum size for the table is achieved . | 163 | 32 |
162,323 | private int findFreeSlot ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "findFreeSlot" ) ; boolean foundFreeSlot = false ; int index = lowestPossibleFree ; int largestIndex = Math . min ( highWaterMark , table . length - 1 ) ; while ( ( ! foundFreeSlot ) && ( index <= largestIndex ) ) { foundFreeSlot ... | Helper method which attempts to locate a free slot in the table . The algorithm used is to scan from the lowest possible free value looking for an entry with a null value . If more than half the table is scanned before a free slot is found then the code also attempts to move the high watermark back towards the beginnin... | 261 | 76 |
162,324 | public void init ( HttpInboundConnection conn , SessionManager sessMgr ) { this . connection = conn ; this . request = conn . getRequest ( ) ; this . sessionData = new SessionInfo ( this , sessMgr ) ; } | Initialize this request with the input link . | 54 | 9 |
162,325 | public void clear ( ) { this . attributes . clear ( ) ; this . queryParameters = null ; this . inReader = null ; this . streamActive = false ; this . inStream = null ; this . encoding = null ; this . sessionData = null ; this . strippedURI = null ; this . srvContext = null ; this . srvPath = null ; this . pathInfo = nu... | Clear all the temporary variables of this request . | 101 | 9 |
162,326 | private void parseQueryFormData ( ) throws IOException { int size = getContentLength ( ) ; if ( 0 == size ) { // no body present this . queryParameters = new HashMap < String , String [ ] > ( ) ; return ; } else if ( - 1 == size ) { // chunked encoded perhaps size = 1024 ; } StringBuilder sb = new StringBuilder ( size ... | Read and parse the POST body data that represents query data . | 164 | 12 |
162,327 | private Map < String , String [ ] > parseQueryString ( String data ) { Map < String , String [ ] > map = new Hashtable < String , String [ ] > ( ) ; if ( null == data ) { return map ; } String valArray [ ] = null ; char [ ] chars = data . toCharArray ( ) ; int key_start = 0 ; for ( int i = 0 ; i < chars . length ; i ++... | Parse a string of query parameters into a Map representing the values stored using the name as the key . | 352 | 21 |
162,328 | private void mergeQueryParams ( Map < String , String [ ] > urlParams ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "mergeQueryParams: " + urlParams ) ; } for ( Entry < String , String [ ] > entry : urlParams . entrySet ( ) ) { String key = entry . getKey ( ) ; // pr... | In certain cases the URL will contain query string information and the POST body will as well . This method merges the two maps together . | 312 | 27 |
162,329 | private String getCipherSuite ( ) { String suite = null ; SSLContext ssl = this . connection . getSSLContext ( ) ; if ( null != ssl ) { suite = ssl . getSession ( ) . getCipherSuite ( ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "getCipherSuite [" + suite + "]" ) ... | Access the SSL cipher suite used in this connection . | 104 | 10 |
162,330 | private X509Certificate [ ] getPeerCertificates ( ) { X509Certificate [ ] rc = null ; SSLContext ssl = this . connection . getSSLContext ( ) ; if ( null != ssl && ( ssl . getNeedClientAuth ( ) || ssl . getWantClientAuth ( ) ) ) { try { Object [ ] objs = ssl . getSession ( ) . getPeerCertificates ( ) ; if ( null != objs... | Access any client SSL certificates for this connection . | 283 | 9 |
162,331 | public void removeTarget ( Object key ) throws MatchingException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removeTarget" , new Object [ ] { key } ) ; // Remove from the HashMap, with synch, there may be other accessors synchronized ( _targets ) { Target targ = ( ... | Remove a target from the MatchSpace | 283 | 7 |
162,332 | public void removeConsumerPointMatchTarget ( DispatchableKey consumerPointData ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removeConsumerPointMatchTarget" , consumerPointData ) ; // Remove the consumer point from the matchspace try { removeTarget ( consumerPointD... | Method removeConsumerPointMatchTarget Used to remove a ConsumerPoint from the MatchSpace . | 399 | 17 |
162,333 | public ControllableProxySubscription addPubSubOutputHandlerMatchTarget ( PubSubOutputHandler handler , SIBUuid12 topicSpace , String discriminator , boolean foreignSecuredProxy , String MESubUserId ) throws SIDiscriminatorSyntaxException , SISelectorSyntaxException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc ... | Used to add a PubSubOutputHandler for ME - ME comms to the MatchSpace . | 827 | 19 |
162,334 | public void removeConsumerDispatcherMatchTarget ( ConsumerDispatcher consumerDispatcher , SelectionCriteria selectionCriteria ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removeConsumerDispatcherMatchTarget" , new Object [ ] { consumerDispatcher , selectionCriteri... | Method removeConsumerDispatcherMatchTarget Used to remove a ConsumerDispatcher from the MatchSpace . | 504 | 21 |
162,335 | public void removePubSubOutputHandlerMatchTarget ( ControllableProxySubscription sub ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removePubSubOutputHandlerMatchTarget" , sub ) ; // Remove the PubSub OutputHandler from the matchspace try { removeTarget ( sub ) ; } ... | Method removePubSubOutputHandlerMatchTarget Used to remove a PubSubOutputHandler from the MatchSpace . | 406 | 21 |
162,336 | private String buildSendTopicExpression ( String destName , String discriminator ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "buildSendTopicExpression" , new Object [ ] { destName , discriminator } ) ; String combo = null ; if ( discriminator == null || discrimina... | Concatenates topicspace and a topic expression with a level separator between | 163 | 16 |
162,337 | public String buildAddTopicExpression ( String destName , String discriminator ) throws SIDiscriminatorSyntaxException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "buildAddTopicExpression" , new Object [ ] { destName , discriminator } ) ; String combo = null ; if ( ... | Concatenates topicspace and a topic expression with a level separator between . | 361 | 17 |
162,338 | public ArrayList getAllCDMatchTargets ( ) { ArrayList consumerDispatcherList ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getAllCDMatchTargets" ) ; // Get from the HashMap, with synch, there may be other accessors synchronized ( _targets ) { consumerDispatcherList =... | Method getAllCDMatchTargets Used to return a list of all ConsumerDispatchers stored in the matchspace | 247 | 24 |
162,339 | public ArrayList getAllCDMatchTargetsForTopicSpace ( String tSpace ) { ArrayList consumerDispatcherList ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getAllCDMatchTargetsForTopicSpace" ) ; // Get from the HashMap, with synch, there may be other accessors synchronized... | Method getAllCDMatchTargetsForTopicSpace Used to return a list of all ConsumerDispatchers stored in the matchspace for a specific topicspace . | 299 | 33 |
162,340 | public ArrayList getAllPubSubOutputHandlerMatchTargets ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getAllPubSubOutputHandlerMatchTargets" ) ; ArrayList outputHandlerList ; // Get from the HashMap, with synch, there may be other accessors synchronized ( _targets... | Method getAllPubSubOutputHandlerMatchTargets Used to return a list of all PubSubOutputHandlers stored in the matchspace | 240 | 28 |
162,341 | public void addTopicAcl ( SIBUuid12 destName , TopicAcl acl ) throws SIDiscriminatorSyntaxException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "addTopicAcl" , new Object [ ] { destName , acl } ) ; String discriminator = null ; // Postpend # wildcard to the fully qu... | Method addTopicAcl Used to add a TopicAcl to the MatchSpace . | 720 | 17 |
162,342 | public void removeAllTopicAcls ( ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removeAllTopicAcls" ) ; ArrayList topicAclList = null ; try { // Remove from the HashMap, with synch, there may be other accessors synchronized ( _targets ) { // Build a list of the exis... | Method removeAllTopicAcls Used to remove all TopicAcls stored in the matchspace | 555 | 20 |
162,343 | public void removeApplicationSignatureMatchTarget ( ApplicationSignature appSignature ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "removeApplicationSignatureMatchTarget" , appSignature ) ; // Remove the consumer point from the matchspace try { removeTarget ( appSi... | Method removeApplicationSignatureMatchTarget Used to remove a ApplicationSignature from the MatchSpace . | 405 | 19 |
162,344 | @ Reference ( policy = DYNAMIC , policyOption = GREEDY , cardinality = MANDATORY ) protected void setProvider ( MetricRecorderProvider provider ) { metricProvider = provider ; } | Require a provider update dynamically if a new one becomes available | 44 | 12 |
162,345 | @ Override public void commit ( ) throws RollbackException , HeuristicMixedException , HeuristicRollbackException , SecurityException , IllegalStateException , SystemException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "commit (SPI)" ) ; try { processCommit ( ) ; } catch ( HeuristicHazardException hhe ) { // On... | Commit the transation associated with the target Transaction object | 228 | 11 |
162,346 | public void commit_one_phase ( ) throws RollbackException , HeuristicMixedException , HeuristicHazardException , HeuristicRollbackException , SecurityException , IllegalStateException , SystemException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "commit_one_phase" ) ; // This call is only valid for a single subo... | Commit the transation associated with a subordinate which received a commit_one_phase request from the superior . Any other subordinate requests should call the internal methods directly . | 129 | 33 |
162,347 | @ Override public void rollback ( ) throws IllegalStateException , SystemException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "rollback (SPI)" ) ; final int state = _status . getState ( ) ; // // We are only called in this method for superiors. // if ( state == TransactionState . STATE_ACTIVE ) { // // Cancel t... | Rollback the transaction associated with the target Transaction Object | 833 | 10 |
162,348 | protected void setPrepareXAFailed ( ) // d266464A { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "setPrepareXAFailed" ) ; setRBO ( ) ; // Ensure native context is informed if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "setPrepareXAFailed" ) ; } | Indicate that the prepare XA phase failed . | 82 | 10 |
162,349 | protected boolean prePrepare ( ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "prePrepare" ) ; // // Cancel timeout prior to completion phase // cancelAlarms ( ) ; // // Inform the Synchronisations we are about to complete // if ( ! _rollbackOnly ) { if ( _syncs != null ) { _syncs . distributeBefore ( ) ; } } if ... | Drive beforeCompletion against sync objects registered with this transaction . | 125 | 12 |
162,350 | protected boolean distributeEnd ( ) throws SystemException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "distributeEnd" ) ; if ( ! getResources ( ) . distributeEnd ( XAResource . TMSUCCESS ) ) { setRBO ( ) ; } if ( _rollbackOnly ) { try { _status . setState ( TransactionState . STATE_ROLLING_BACK ) ; } catch ( Sy... | Distribute end to all XA resources | 203 | 8 |
162,351 | public Throwable getOriginalException ( ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getOriginalException" ) ; if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "getOriginalException" , _originalException ) ; return _originalException ; } | returns the exception stored by RegisteredSyncs | 65 | 9 |
162,352 | @ Override public void setRollbackOnly ( ) throws IllegalStateException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "setRollbackOnly (SPI)" ) ; final int state = _status . getState ( ) ; if ( state == TransactionState . STATE_NONE || state == TransactionState . STATE_COMMITTED || state == TransactionState . STAT... | Modify the transaction such that the only possible outcome of the transaction is to rollback . | 168 | 18 |
162,353 | public void enlistResource ( JTAResource remoteRes ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "enlistResource (SPI): args: " , remoteRes ) ; getResources ( ) . addRes ( remoteRes ) ; if ( tc . isEntryEnabled ( ) ) Tr . exit ( tc , "enlistResource (SPI)" ) ; } | Enlist a remote resouce with the transaction associated with the target TransactionImpl object . Typically this remote resource represents a downstream suborindate server . | 85 | 31 |
162,354 | protected void logHeuristic ( boolean commit ) throws SystemException { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "logHeuristic" , commit ) ; if ( _subordinate && _status . getState ( ) != TransactionState . STATE_PREPARING ) { getResources ( ) . logHeuristic ( commit ) ; } if ( tc . isEntryEnabled ( ) ) Tr . ex... | Log the fact that we have encountered a heuristic outcome . | 99 | 12 |
162,355 | @ Override public int getStatus ( ) { int state = Status . STATUS_UNKNOWN ; switch ( _status . getState ( ) ) { case TransactionState . STATE_NONE : state = Status . STATUS_NO_TRANSACTION ; break ; case TransactionState . STATE_ACTIVE : if ( _rollbackOnly ) state = Status . STATUS_MARKED_ROLLBACK ; else state = Status ... | Obtain the status of the transaction associated with the target object | 351 | 12 |
162,356 | public XidImpl getXidImpl ( boolean createIfAbsent ) { if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getXidImpl" , new Object [ ] { this , createIfAbsent } ) ; if ( createIfAbsent && ( _xid == null ) ) { // Create an XID as this transaction identifier. _xid = new XidImpl ( new TxPrimaryKey ( _localTID , Configurati... | Returns a global identifier that represents the TransactionImpl s transaction . | 150 | 12 |
162,357 | public void setXidImpl ( XidImpl xid ) { if ( tc . isDebugEnabled ( ) ) Tr . debug ( tc , "setXidImpl" , new Object [ ] { xid , this } ) ; _xid = xid ; } | For recovery only | 57 | 3 |
162,358 | public boolean isJCAImportedAndPrepared ( String providerId ) { return _JCARecoveryData != null && _status . getState ( ) == TransactionState . STATE_PREPARED && _JCARecoveryData . getWrapper ( ) . getProviderId ( ) . equals ( providerId ) ; } | Returns true if this tx was imported by the given RA and is prepared | 69 | 14 |
162,359 | public void loadKeyStores ( Map < String , WSKeyStore > config ) { // now process each keystore in the provided config for ( Entry < String , WSKeyStore > current : config . entrySet ( ) ) { try { String name = current . getKey ( ) ; WSKeyStore keystore = current . getValue ( ) ; addKeyStoreToMap ( name , keystore ) ; ... | Load the provided list of keystores from the configuration . | 182 | 11 |
162,360 | public InputStream getInputStream ( String fileName , boolean create ) throws MalformedURLException , IOException { try { GetKeyStoreInputStreamAction action = new GetKeyStoreInputStreamAction ( fileName , create ) ; return AccessController . doPrivileged ( action ) ; } catch ( PrivilegedActionException e ) { Exception... | Open the provided filename as a keystore creating if it doesn t exist and the input create flag is true . | 217 | 22 |
162,361 | public OutputStream getOutputStream ( String fileName ) throws MalformedURLException , IOException { try { GetKeyStoreOutputStreamAction action = new GetKeyStoreOutputStreamAction ( fileName ) ; return AccessController . doPrivileged ( action ) ; } catch ( PrivilegedActionException e ) { Exception ex = e . getException... | Open the provided filename as an outputstream . | 204 | 9 |
162,362 | public static String stripLastSlash ( String inputString ) { if ( null == inputString ) { return null ; } String rc = inputString . trim ( ) ; int len = rc . length ( ) ; if ( 0 < len ) { char lastChar = rc . charAt ( len - 1 ) ; if ( ' ' == lastChar || ' ' == lastChar ) { rc = rc . substring ( 0 , len - 1 ) ; } } retu... | Remove the last slash if present from the input string and return the result . | 100 | 15 |
162,363 | public KeyStore getJavaKeyStore ( String keyStoreName ) throws Exception { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getJavaKeyStore: " + keyStoreName ) ; if ( keyStoreName == null || keyStoreName . trim ( ) . isEmpty ( ) ) { throw new SSLException ( "No keystore name... | Returns the java keystore object based on the keystore name passed in . | 191 | 15 |
162,364 | public WSKeyStore getWSKeyStore ( String keyStoreName ) throws SSLException { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getWSKeyStore: " + keyStoreName ) ; if ( keyStoreName == null ) { throw new SSLException ( "No keystore name provided." ) ; } WSKeyStore ks = keySto... | Returns the java keystore object based on the keystore name passed in . A null value is returned if no existing store matchs the provided name . | 147 | 30 |
162,365 | @ Override public Set < String > getDependentApplications ( ) { Set < String > appsToStop = new HashSet < String > ( applications ) ; applications . clear ( ) ; return appsToStop ; } | Returns the list of applications that have used this resource so that the applications can be stopped by the application recycle code in response to a configuration change . | 45 | 29 |
162,366 | @ Trivial // do our own trace in order to selectively include the value private < T extends Object > void set ( Class < ? > clazz , Object clientBuilder , String name , Class < T > type , T value ) throws Exception { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( this , tc , nam... | Method to reflectively invoke setters on the cloudant client builder | 223 | 13 |
162,367 | @ Override public void libraryNotification ( ) { // Notify the application recycle coordinator of an incompatible change that requires restarting the application if ( ! applications . isEmpty ( ) ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) Tr . debug ( this , tc , "recycle application... | Received when library is changed for example by altering the files in the library . | 151 | 16 |
162,368 | public Object getCloudantClient ( int resAuth , List < ? extends ResourceInfo . Property > loginPropertyList ) throws Exception { AuthData containerAuthData = null ; if ( resAuth == ResourceInfo . AUTH_CONTAINER ) { containerAuthData = getContainerAuthData ( loginPropertyList ) ; } String userName = containerAuthData =... | Return the cloudant client object used for a particular username and password | 237 | 13 |
162,369 | public synchronized void waitOn ( ) throws InterruptedException { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "waitOn" , "" + count ) ; ++ count ; if ( count > 0 ) { try { wait ( ) ; } catch ( InterruptedException e ) { // No FFDC code needed -- count ; throw e ; } } if ( tc . isEntryEnabled ( ) ) SibTr . exit ... | Wait for the semaphore to be posted | 104 | 9 |
162,370 | public synchronized void post ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "post" , "" + count ) ; -- count ; if ( count >= 0 ) notify ( ) ; if ( tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "post" ) ; } | Post the semaphore waking up at most one waiter . If there are no waiters then the next thread issuing a waitOn call will not be suspended . In fact if post is invoked n times then the next n waitOn calls will not block . | 71 | 51 |
162,371 | public synchronized void waitOnIgnoringInterruptions ( ) { if ( tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "waitOnIgnoringInterruptions" ) ; boolean interrupted ; do { interrupted = false ; try { waitOn ( ) ; } catch ( InterruptedException e ) { // No FFDC code needed interrupted = true ; } } while ( interrupted ) ... | Wait on the semaphore ignoring any attempt to interrupt the thread . | 114 | 14 |
162,372 | protected void setMemberFactories ( FaceletCache . MemberFactory < V > faceletFactory , FaceletCache . MemberFactory < V > viewMetadataFaceletFactory , FaceletCache . MemberFactory < V > compositeComponentMetadataFaceletFactory ) { if ( compositeComponentMetadataFaceletFactory == null ) { throw new NullPointerException... | Set the factories used for create Facelet instances . | 124 | 10 |
162,373 | @ Override public void close ( ) throws IOException { if ( this . in != null && this . inStream != null ) { if ( TraceComponent . isAnyTracingEnabled ( ) && logger . isLoggable ( Level . FINE ) ) { logger . logp ( Level . FINE , CLASS_NAME , "close" , "close called->" + this ) ; } this . in . close ( ) ; } else { super... | Following needed to support MultiRead | 102 | 6 |
162,374 | @ Override public ArtifactContainer createContainer ( File cacheDir , Object containerData ) { if ( ! ( containerData instanceof File ) ) { return null ; } File fileContainerData = ( File ) containerData ; if ( ! FileUtils . fileIsFile ( fileContainerData ) ) { return null ; } if ( ! isZip ( fileContainerData ) ) { ret... | Attempt to create a root - of - roots zip file type container . | 99 | 14 |
162,375 | @ Override public ArtifactContainer createContainer ( File cacheDir , ArtifactContainer enclosingContainer , ArtifactEntry entryInEnclosingContainer , Object containerData ) { if ( ( containerData instanceof File ) && FileUtils . fileIsFile ( ( File ) containerData ) ) { File fileContainerData = ( File ) containerData ... | Attempt to create an enclosed root zip file type container . | 166 | 11 |
162,376 | private static boolean hasZipExtension ( String name ) { int nameLen = name . length ( ) ; // Need '.' plus at least three characters. if ( nameLen < 4 ) { return false ; } // Need '.' plus at least six characters for ".spring". if ( nameLen >= 7 ) { if ( ( name . charAt ( nameLen - 7 ) == ' ' ) && name . regionMatches... | Tell if a file name has a zip file type extension . | 232 | 12 |
162,377 | private static boolean isZip ( ArtifactEntry artifactEntry ) { if ( ! hasZipExtension ( artifactEntry . getName ( ) ) ) { return false ; } boolean validZip = false ; InputStream entryInputStream = null ; try { entryInputStream = artifactEntry . getInputStream ( ) ; if ( entryInputStream == null ) { return false ; } Zip... | Tell if an artifact entry is valid to be interpreted as a zip file container . | 247 | 16 |
162,378 | @ SuppressWarnings ( "deprecation" ) private static String getPhysicalPath ( ArtifactEntry artifactEntry ) { String physicalPath = artifactEntry . getPhysicalPath ( ) ; if ( physicalPath != null ) { return physicalPath ; } String entryPath = artifactEntry . getPath ( ) ; String rootPath = artifactEntry . getRoot ( ) . ... | Answer they physical path of an artifact entry . | 187 | 9 |
162,379 | @ FFDCIgnore ( { IOException . class , FileNotFoundException . class } ) private static boolean isZip ( File file ) { if ( ! hasZipExtension ( file . getName ( ) ) ) { return false ; } InputStream inputStream = null ; try { inputStream = new FileInputStream ( file ) ; // throws FileNotFoundException ZipInputStream zipI... | Tell if a file is valid to used to create a zip file container . | 257 | 15 |
162,380 | public static UpdatedFile fromNode ( Node n ) { String id = n . getAttributes ( ) . getNamedItem ( "id" ) == null ? null : n . getAttributes ( ) . getNamedItem ( "id" ) . getNodeValue ( ) ; long size = n . getAttributes ( ) . getNamedItem ( "size" ) == null ? null : Long . parseLong ( n . getAttributes ( ) . getNamedIt... | needs to support both hash and MD5hash as attributes | 266 | 11 |
162,381 | @ Override public void serverStopping ( ) { BundleContext bundleContext = componentContext . getBundleContext ( ) ; Collection < ServiceReference < EndpointActivationService > > refs ; try { refs = bundleContext . getServiceReferences ( EndpointActivationService . class , null ) ; } catch ( InvalidSyntaxException x ) {... | Invoked when server is quiescing . Deactivate all endpoints . | 248 | 15 |
162,382 | public boolean filterMatches ( AbstractItem item ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "filterMatches" , item ) ; /* Cast the incoming item to a PersistentStoreReferenceStream object. if it is not, an * exception will be thrown and the match will fail */ SIM... | Filter method . Checks whether the given item is a consumerDispatcher and matches the one associated with this filter | 226 | 22 |
162,383 | private ValidatorFactory createValidatorFactory ( FacesContext context ) { Map < String , Object > applicationMap = context . getExternalContext ( ) . getApplicationMap ( ) ; Object attr = applicationMap . get ( VALIDATOR_FACTORY_KEY ) ; if ( attr instanceof ValidatorFactory ) { return ( ValidatorFactory ) attr ; } els... | This method creates ValidatorFactory instances or retrieves them from the container . | 162 | 15 |
162,384 | private void postSetValidationGroups ( ) { if ( this . validationGroups == null || this . validationGroups . matches ( EMPTY_VALIDATION_GROUPS_PATTERN ) ) { this . validationGroupsArray = DEFAULT_VALIDATION_GROUPS_ARRAY ; } else { String [ ] classes = this . validationGroups . split ( VALIDATION_GROUPS_DELIMITER ) ; Li... | Fully initialize the validation groups if needed . If no validation groups are specified the Default validation group is used . | 442 | 22 |
162,385 | public void setEnumerators ( String [ ] val ) { enumerators = val ; enumeratorCount = ( enumerators != null ) ? enumerators . length : 0 ; } | Set the enumerators in the order of their assigned codes | 37 | 11 |
162,386 | public void encodeType ( byte [ ] frame , int [ ] limits ) { setByte ( frame , limits , ( byte ) ENUM ) ; setCount ( frame , limits , enumeratorCount ) ; } | propagate the enumeratorCount . | 43 | 7 |
162,387 | public void format ( StringBuffer fmt , Set done , Set todo , int indent ) { formatName ( fmt , indent ) ; fmt . append ( "Enum" ) ; if ( enumerators != null ) { fmt . append ( "{{" ) ; String delim = "" ; for ( int i = 0 ; i < enumerators . length ; i ++ ) { fmt . append ( delim ) . append ( enumerators [ i ] ) ; deli... | Format for printing . | 109 | 4 |
162,388 | public static _ValueReferenceWrapper resolve ( ValueExpression valueExpression , final ELContext elCtx ) { _ValueReferenceResolver resolver = new _ValueReferenceResolver ( elCtx . getELResolver ( ) ) ; ELContext elCtxDecorator = new _ELContextDecorator ( elCtx , resolver ) ; valueExpression . getValue ( elCtxDecorator ... | This method can be used to extract the ValueReferenceWrapper from the given ValueExpression . | 181 | 19 |
162,389 | @ Override public Object getValue ( final ELContext context , final Object base , final Object property ) { lastObject = new _ValueReferenceWrapper ( base , property ) ; return resolver . getValue ( context , base , property ) ; } | This method is the only one that matters . It keeps track of the objects in the EL expression . | 52 | 20 |
162,390 | private boolean isApplicationException ( Throwable ex , EJBMethodInfoImpl methodInfo ) { final boolean isTraceOn = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "isApplicationException : " + ex . getClass ( ) . getName ( ) + ", " + methodInfo ) ; // d660332 if ... | F743 - 761 | 523 | 6 |
162,391 | synchronized protected void addMessagingEngine ( final JsMessagingEngine messagingEngine ) { final String methodName = "addMessagingEngine" ; if ( TraceComponent . isAnyTracingEnabled ( ) && TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName , messagingEngine ) ; } SibRaMessagingEngineConnection c... | Connects to the given messaging engine . Registers a destination listener and creates listeners for each of the current destinations . | 629 | 23 |
162,392 | public void addNotfication ( Notification notification ) { Object source = notification . getSource ( ) ; NotificationRecord nr ; if ( source instanceof ObjectName ) { nr = new NotificationRecord ( notification , ( ObjectName ) source ) ; } else { nr = new NotificationRecord ( notification , ( source != null ) ? source... | This method will be called by the NotificationListener once the MBeanServer pushes a notification . | 91 | 19 |
162,393 | public void addClientNotificationListener ( RESTRequest request , NotificationRegistration notificationRegistration , JSONConverter converter ) { String objectNameStr = notificationRegistration . objectName . getCanonicalName ( ) ; NotificationTargetInformation nti = toNotificationTargetInformation ( request , objectNa... | Fetch or create a new listener for the given object name | 313 | 12 |
162,394 | public void updateClientNotificationListener ( RESTRequest request , String objectNameStr , NotificationFilter [ ] filters , JSONConverter converter ) { NotificationTargetInformation nti = toNotificationTargetInformation ( request , objectNameStr ) ; ClientNotificationListener listener = listeners . get ( nti ) ; if ( ... | Update the listener for the given object name with the provided filters | 134 | 12 |
162,395 | private Object removeObject ( Integer key ) { if ( key == null ) { return null ; } return objectLibrary . remove ( key ) ; } | Only to be used by removal coming from direct - http calls because calls from the jmx client can still reference this key for other notifications . | 30 | 28 |
162,396 | public void removeClientNotificationListener ( RESTRequest request , ObjectName name ) { NotificationTargetInformation nti = toNotificationTargetInformation ( request , name . getCanonicalName ( ) ) ; // Remove locally ClientNotificationListener listener = listeners . remove ( nti ) ; // Check whether the producer of t... | Remove the given NotificationListener | 178 | 5 |
162,397 | public void addServerNotificationListener ( RESTRequest request , ServerNotificationRegistration serverNotificationRegistration , JSONConverter converter ) { NotificationTargetInformation nti = toNotificationTargetInformation ( request , serverNotificationRegistration . objectName . getCanonicalName ( ) ) ; //Fetch the... | Add the server notification to our internal list so we can cleanup afterwards | 444 | 13 |
162,398 | public synchronized void remoteClientRegistrations ( RESTRequest request ) { Iterator < Entry < NotificationTargetInformation , ClientNotificationListener > > clientListeners = listeners . entrySet ( ) . iterator ( ) ; try { while ( clientListeners . hasNext ( ) ) { Entry < NotificationTargetInformation , ClientNotific... | Remove all the client notifications | 404 | 5 |
162,399 | public synchronized void remoteServerRegistrations ( RESTRequest request ) { Iterator < Entry < NotificationTargetInformation , List < ServerNotification > > > serverNotificationsIter = serverNotifications . entrySet ( ) . iterator ( ) ; while ( serverNotificationsIter . hasNext ( ) ) { Entry < NotificationTargetInform... | Remove all the server notifications | 449 | 5 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.