signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class SipApplicationSessionImpl { /** * ( non - Javadoc )
* @ see javax . servlet . sip . SipApplicationSession # getSessions ( java . lang . String ) */
public Iterator < ? > getSessions ( String protocol ) { } } | if ( ! isValid ( ) ) { throw new IllegalStateException ( "SipApplicationSession already invalidated !" ) ; } if ( protocol == null ) { throw new NullPointerException ( "protocol given in argument is null" ) ; } if ( "SIP" . equalsIgnoreCase ( protocol ) ) { return getSipSessions ( false ) . iterator ( ) ; } else if ( "... |
public class ExperimentHelper { /** * This function will calculate the planting date which is the first date
* within the planting window that has an accumulated rainfall amount
* ( P ) in the previous n days .
* @ param data The HashMap of experiment ( including weather data )
* @ param eDate Earliest planting... | Map wthData ; ArrayList < Map > dailyData ; ArrayList < HashMap < String , String > > eventData ; Event event ; Calendar eDateCal = Calendar . getInstance ( ) ; Calendar lDateCal = Calendar . getInstance ( ) ; int intDays ; int duration ; double accRainAmtTotal ; double accRainAmt ; int expDur ; int startYear = 0 ; Win... |
public class SimpleFileIO { /** * Get the content of the passed file as a string using the system line
* separator . Note : the last line does not end with the passed line separator .
* @ param aFile
* The file to read . May be < code > null < / code > .
* @ param aCharset
* The character set to use . May not... | return aFile == null ? null : StreamHelper . getAllBytesAsString ( FileHelper . getInputStream ( aFile ) , aCharset ) ; |
public class TypedStreamReader { /** * Method called to wrap or convert given conversion - fail exception
* into a full { @ link TypedXMLStreamException } ,
* @ param iae Problem as reported by converter
* @ param lexicalValue Lexical value ( element content , attribute value )
* that could not be converted suc... | return new TypedXMLStreamException ( lexicalValue , iae . getMessage ( ) , getStartLocation ( ) , iae ) ; |
public class FloatList { /** * Add a new array to the list .
* @ param values values
* @ return was able to add . */
public boolean addArray ( float ... values ) { } } | if ( end + values . length >= this . values . length ) { this . values = grow ( this . values , ( this . values . length + values . length ) * 2 ) ; } System . arraycopy ( values , 0 , this . values , end , values . length ) ; end += values . length ; return true ; |
public class UpgradableLock { /** * Attempt to immediately acquire an exclusive lock .
* @ param locker object trying to become lock owner
* @ return true if acquired */
public final boolean tryLockForWrite ( L locker ) { } } | int state = mState ; if ( state == 0 ) { // no locks are held
if ( isUpgradeOrReadWriteFirst ( ) && setWriteLock ( state ) ) { // keep upgrade state bit clear to indicate automatic upgrade
mOwner = locker ; incrementUpgradeCount ( ) ; incrementWriteCount ( ) ; return true ; } } else if ( state == LOCK_STATE_UPGRADE ) {... |
public class DefaultPDUSender { /** * ( non - Javadoc )
* @ see org . jsmpp . PDUSender # sendQuerySm ( java . io . OutputStream , int ,
* java . lang . String , org . jsmpp . TypeOfNumber ,
* org . jsmpp . NumberingPlanIndicator , java . lang . String ) */
public byte [ ] sendQuerySm ( OutputStream os , int sequ... | byte [ ] b = pduComposer . querySm ( sequenceNumber , messageId , sourceAddrTon . value ( ) , sourceAddrNpi . value ( ) , sourceAddr ) ; writeAndFlush ( os , b ) ; return b ; |
public class ElementMatchers { /** * Exactly matches a given annotation as an { @ link AnnotationDescription } .
* @ param annotation The annotation to match by its description .
* @ param < T > The type of the matched object .
* @ return An element matcher that exactly matches the given annotation . */
public st... | return is ( AnnotationDescription . ForLoadedAnnotation . of ( annotation ) ) ; |
public class BinaryHeapPriorityQueue { /** * Get the priority of a key - - if the key is not in the queue , Double . NEGATIVE _ INFINITY is returned . */
public double getPriority ( E key ) { } } | Entry < E > entry = getEntry ( key ) ; if ( entry == null ) { return Double . NEGATIVE_INFINITY ; } return entry . priority ; |
public class FSImageCompression { /** * Create a compression instance based on the user ' s configuration in the given
* Configuration object .
* @ throws IOException if the specified codec is not available . */
static FSImageCompression createCompression ( Configuration conf , boolean forceUncompressed ) throws IO... | boolean compressImage = ( ! forceUncompressed ) && conf . getBoolean ( HdfsConstants . DFS_IMAGE_COMPRESS_KEY , HdfsConstants . DFS_IMAGE_COMPRESS_DEFAULT ) ; if ( ! compressImage ) { return createNoopCompression ( ) ; } String codecClassName = conf . get ( HdfsConstants . DFS_IMAGE_COMPRESSION_CODEC_KEY , HdfsConstant... |
public class BatchGetCrawlersResult { /** * A list of names of crawlers not found .
* < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use
* { @ link # setCrawlersNotFound ( java . util . Collection ) } or { @ link # withCrawlersNotFound ( java . util . Collection ) } if you
*... | if ( this . crawlersNotFound == null ) { setCrawlersNotFound ( new java . util . ArrayList < String > ( crawlersNotFound . length ) ) ; } for ( String ele : crawlersNotFound ) { this . crawlersNotFound . add ( ele ) ; } return this ; |
public class VirtualFile { /** * called after writing to commit that writing succeeded up to position .
* If position > size the size is updated .
* @ param pos */
void commit ( ByteBuffer bb ) { } } | content . limit ( Math . max ( content . limit ( ) , bb . position ( ) ) ) ; boolean removed = refSet . removeItem ( content , bb ) ; assert removed ; |
public class BitWriter { /** * Writes a single bit to the buffer .
* @ param bit
* 0 or 1
* @ throws EncodingException
* if the input is neither 0 nor 1. */
public void writeBit ( final int bit ) throws EncodingException { } } | if ( bit != 0 && bit != 1 ) { throw ErrorFactory . createEncodingException ( ErrorKeys . DIFFTOOL_ENCODING_VALUE_OUT_OF_RANGE , "bit value out of range: " + bit ) ; } this . buffer |= bit << ( 7 - this . bufferLength ) ; this . bufferLength ++ ; if ( bufferLength == 8 ) { write ( buffer ) ; this . bufferLength = 0 ; th... |
public class Multimaps2 { /** * Constructs an empty { @ code ListMultimap } with enough capacity to hold the specified numbers of keys and values
* without resizing . It uses a linked map internally .
* @ param expectedKeys
* the expected number of distinct keys
* @ param expectedValuesPerKey
* the expected a... | return Multimaps . newListMultimap ( new LinkedHashMap < K , Collection < V > > ( expectedKeys ) , new Supplier < List < V > > ( ) { @ Override public List < V > get ( ) { return Lists . newArrayListWithCapacity ( expectedValuesPerKey ) ; } } ) ; |
public class Main { /** * Compile JavaScript source . */
public void processSource ( String [ ] filenames ) { } } | for ( int i = 0 ; i != filenames . length ; ++ i ) { String filename = filenames [ i ] ; if ( ! filename . endsWith ( ".js" ) ) { addError ( "msg.extension.not.js" , filename ) ; return ; } File f = new File ( filename ) ; String source = readSource ( f ) ; if ( source == null ) return ; String mainClassName = targetNa... |
public class BounceProxyRecord { /** * Sets the status of the bounce proxy .
* @ param status the status of the bounce proxy
* @ throws IllegalStateException
* if setting this status is not possible for the current bounce
* proxy status . */
public void setStatus ( BounceProxyStatus status ) throws IllegalState... | // this checks if the transition is valid
if ( this . status . isValidTransition ( status ) ) { this . status = status ; } else { throw new IllegalStateException ( "Illegal status transition from " + this . status + " to " + status ) ; } |
public class Futures { /** * Gets a future result with a default timeout .
* @ param future the future to block
* @ param timeout the future timeout
* @ param timeUnit the future timeout time unit
* @ param < T > the future result type
* @ return the future result
* @ throws RuntimeException if a future exc... | try { return future . get ( timeout , timeUnit ) ; } catch ( InterruptedException | ExecutionException | TimeoutException e ) { throw new RuntimeException ( e ) ; } |
public class IntArrayList { /** * Increases the capacity of this < tt > ArrayList < / tt > instance , if
* necessary , to ensure that it can hold at least the number of elements
* specified by the minimum capacity argument .
* @ param minCapacity the desired minimum capacity . */
public void ensureCapacity ( int ... | modCount ++ ; int oldCapacity = elementData . length ; if ( minCapacity > oldCapacity ) { int oldData [ ] = elementData ; int newCapacity = ( oldCapacity * 3 ) / 2 + 1 ; if ( newCapacity < minCapacity ) newCapacity = minCapacity ; elementData = new int [ newCapacity ] ; System . arraycopy ( oldData , 0 , elementData , ... |
public class AndroidMobileCommandHelper { /** * This method forms a { @ link Map } of parameters for the setting of device network connection .
* @ param bitMask The bitmask of the desired connection
* @ return a key - value pair . The key is the command name . The value is a { @ link Map } command arguments . */
p... | String [ ] parameters = new String [ ] { "name" , "parameters" } ; Object [ ] values = new Object [ ] { "network_connection" , ImmutableMap . of ( "type" , bitMask ) } ; return new AbstractMap . SimpleEntry < > ( SET_NETWORK_CONNECTION , prepareArguments ( parameters , values ) ) ; |
public class SoftTFIDFDictionary { /** * Insert a string into the dictionary , and associate it with the
* given value . */
public void put ( String string , Object value ) { } } | if ( frozen ) throw new IllegalStateException ( "can't add new values to a frozen dictionary" ) ; Set valset = ( Set ) valueMap . get ( string ) ; if ( valset == null ) valueMap . put ( string , ( valset = new HashSet ( ) ) ) ; valset . add ( value ) ; |
public class VirtualMachineScaleSetsInner { /** * Starts one or more virtual machines in a VM scale set .
* @ param resourceGroupName The name of the resource group .
* @ param vmScaleSetName The name of the VM scale set .
* @ throws IllegalArgumentException thrown if parameters fail the validation
* @ return t... | return beginStartWithServiceResponseAsync ( resourceGroupName , vmScaleSetName ) . map ( new Func1 < ServiceResponse < OperationStatusResponseInner > , OperationStatusResponseInner > ( ) { @ Override public OperationStatusResponseInner call ( ServiceResponse < OperationStatusResponseInner > response ) { return response... |
public class SarlFactoryImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public EObject create ( EClass eClass ) { } } | switch ( eClass . getClassifierID ( ) ) { case SarlPackage . SARL_SCRIPT : return createSarlScript ( ) ; case SarlPackage . SARL_FIELD : return createSarlField ( ) ; case SarlPackage . SARL_BREAK_EXPRESSION : return createSarlBreakExpression ( ) ; case SarlPackage . SARL_CONTINUE_EXPRESSION : return createSarlContinueE... |
public class StaticLog { /** * 打印日志 < br >
* @ param level 日志级别
* @ param t 需在日志中堆栈打印的异常
* @ param format 格式文本 , { } 代表变量
* @ param arguments 变量对应的参数
* @ return 是否为LocationAwareLog日志 */
public static boolean log ( Level level , Throwable t , String format , Object ... arguments ) { } } | return log ( LogFactory . get ( CallerUtil . getCallerCaller ( ) ) , level , t , format , arguments ) ; |
public class EmbeddableUOWManagerImpl { /** * ( non - Javadoc )
* @ see com . ibm . wsspi . uow . UOWManager # getUOWTimeout ( ) */
@ Override public int getUOWTimeout ( ) throws IllegalStateException { } } | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getUOWTimeout" , this ) ; final int timeout ; final int uowType = getUOWType ( ) ; switch ( uowType ) { case UOWSynchronizationRegistry . UOW_TYPE_GLOBAL_TRANSACTION : try { timeout = ( ( EmbeddableTransactionImpl ) getUOWScop... |
public class RestProxy { /** * Create a proxy implementation of the provided Swagger interface .
* @ param swaggerInterface the Swagger interface to provide a proxy implementation for
* @ param serviceClient the ServiceClient that contains the details to use to create the
* RestProxy implementation of the swagger... | return create ( swaggerInterface , serviceClient . httpPipeline ( ) , serviceClient . serializerAdapter ( ) ) ; |
public class QueryImpl { /** * This method simply forwards the < code > execute < / code > call to the
* { @ link ExecutableQuery } object returned by
* { @ link QueryHandler # createExecutableQuery } .
* { @ inheritDoc } */
public QueryResult execute ( ) throws RepositoryException { } } | checkInitialized ( ) ; long time = 0 ; if ( log . isDebugEnabled ( ) ) { time = System . currentTimeMillis ( ) ; } QueryResult result = query . execute ( offset , limit , caseInsensitiveOrder ) ; if ( log . isDebugEnabled ( ) ) { time = System . currentTimeMillis ( ) - time ; NumberFormat format = NumberFormat . getNum... |
public class Base64 { /** * Convenience method for reading a base64 - encoded file and decoding it .
* @ param filename
* Filename for reading encoded data
* @ return decoded byte array or null if unsuccessful
* @ since 2.1 */
public static byte [ ] decodeFromFile ( String filename ) { } } | byte [ ] decodedData = null ; Base64 . InputStream bis = null ; try { // Set up some useful variables
java . io . File file = new java . io . File ( filename ) ; byte [ ] buffer = null ; int length = 0 ; int numBytes = 0 ; // Check for size of file
if ( file . length ( ) > Integer . MAX_VALUE ) { return null ; } // end... |
public class BS { /** * Returns an < code > IfNotExistsFunction < / code > object which represents an < a href =
* " http : / / docs . aws . amazon . com / amazondynamodb / latest / developerguide / Expressions . Modifying . html "
* > if _ not _ exists ( path , operand ) < / a > function call where path refers to ... | return new IfNotExistsFunction < BS > ( this , new LiteralOperand ( new LinkedHashSet < byte [ ] > ( Arrays . asList ( defaultValue ) ) ) ) ; |
public class CommerceDiscountPersistenceImpl { /** * Removes all the commerce discounts where uuid = & # 63 ; and companyId = & # 63 ; from the database .
* @ param uuid the uuid
* @ param companyId the company ID */
@ Override public void removeByUuid_C ( String uuid , long companyId ) { } } | for ( CommerceDiscount commerceDiscount : findByUuid_C ( uuid , companyId , QueryUtil . ALL_POS , QueryUtil . ALL_POS , null ) ) { remove ( commerceDiscount ) ; } |
public class CommerceTierPriceEntryPersistenceImpl { /** * Returns the last commerce tier price entry in the ordered set where companyId = & # 63 ; .
* @ param companyId the company ID
* @ param orderByComparator the comparator to order the set by ( optionally < code > null < / code > )
* @ return the last matchi... | CommerceTierPriceEntry commerceTierPriceEntry = fetchByCompanyId_Last ( companyId , orderByComparator ) ; if ( commerceTierPriceEntry != null ) { return commerceTierPriceEntry ; } StringBundler msg = new StringBundler ( 4 ) ; msg . append ( _NO_SUCH_ENTITY_WITH_KEY ) ; msg . append ( "companyId=" ) ; msg . append ( com... |
public class SideEffectAnalysis { /** * Tries to establish whether { @ code expression } is side - effect free . The heuristics here are very
* conservative . */
public static boolean hasSideEffect ( ExpressionTree expression ) { } } | if ( expression == null ) { return false ; } SideEffectAnalysis analyzer = new SideEffectAnalysis ( ) ; expression . accept ( analyzer , null ) ; return analyzer . hasSideEffect ; |
public class JobGraph { /** * Checks if the job vertex with the given ID is registered with the job graph .
* @ param id
* the ID of the vertex to search for
* @ return < code > true < / code > if a vertex with the given ID is registered with the job graph , < code > false < / code >
* otherwise . */
private bo... | if ( this . inputVertices . containsKey ( id ) ) { return true ; } if ( this . outputVertices . containsKey ( id ) ) { return true ; } if ( this . taskVertices . containsKey ( id ) ) { return true ; } return false ; |
public class JvmComponentTypeImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public boolean eIsSet ( int featureID ) { } } | switch ( featureID ) { case TypesPackage . JVM_COMPONENT_TYPE__ARRAY_TYPE : return arrayType != null ; } return super . eIsSet ( featureID ) ; |
public class PropertySheetTableModel { /** * Convenience method to get all the properties of one category . */
private List < Property > getPropertiesForCategory ( List < Property > localProperties , String category ) { } } | List < Property > categoryProperties = new ArrayList < Property > ( ) ; for ( Property property : localProperties ) { if ( property . getCategory ( ) != null && property . getCategory ( ) . equals ( category ) ) { categoryProperties . add ( property ) ; } } return categoryProperties ; |
public class SerializerBase { /** * Adds the given attribute to the set of attributes , even if there is
* no currently open element . This is useful if a SAX startPrefixMapping ( )
* should need to add an attribute before the element name is seen .
* @ param uri the URI of the attribute
* @ param localName the... | boolean was_added ; // final int index =
// ( localName = = null | | uri = = null ) ?
// m _ attributes . getIndex ( rawName ) : m _ attributes . getIndex ( uri , localName ) ;
int index ; // if ( localName = = null | | uri = = null ) {
// index = m _ attributes . getIndex ( rawName ) ;
// else {
// index = m _ attribu... |
public class HtmlUtils { /** * Get a relative URI for { @ code file } from { @ code output } folder . */
static String createRelativeUri ( File file , File output ) { } } | if ( file == null ) { return null ; } try { file = file . getCanonicalFile ( ) ; output = output . getCanonicalFile ( ) ; if ( file . equals ( output ) ) { throw new IllegalArgumentException ( "File path and output folder are the same." ) ; } StringBuilder builder = new StringBuilder ( ) ; while ( ! file . equals ( out... |
public class TcpConnecter { /** * null if the connection was unsuccessful . */
private SocketChannel connect ( ) { } } | try { // Async connect has finished . Check whether an error occurred
boolean finished = fd . finishConnect ( ) ; assert ( finished ) ; return fd ; } catch ( IOException e ) { return null ; } |
public class AfplibFactoryImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public String convertSFNameToString ( EDataType eDataType , Object instanceValue ) { } } | return instanceValue == null ? null : instanceValue . toString ( ) ; |
public class ValidationAssert { /** * Verifies that actual value is not valid against given schema
* @ throws AssertionError if the actual value is valid against schema */
public void isInvalid ( ) { } } | ValidationResult validateResult = validate ( ) ; if ( validateResult . isValid ( ) ) { throwAssertionError ( shouldBeInvalid ( actual . getSystemId ( ) ) ) ; } |
public class AWSIotClient { /** * Updates a role alias .
* @ param updateRoleAliasRequest
* @ return Result of the UpdateRoleAlias operation returned by the service .
* @ throws ResourceNotFoundException
* The specified resource does not exist .
* @ throws InvalidRequestException
* The request is not valid ... | request = beforeClientExecution ( request ) ; return executeUpdateRoleAlias ( request ) ; |
public class Clique { /** * This version assumes relativeIndices array no longer needs to
* be copied . Further it is assumed that it has already been
* checked or assured by construction that relativeIndices
* is sorted . */
private static Clique valueOfHelper ( int [ ] relativeIndices ) { } } | // if clique already exists , return that one
Clique c = new Clique ( ) ; c . relativeIndices = relativeIndices ; return intern ( c ) ; |
public class Ifc4PackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public EClass getIfcTextFontSelect ( ) { } } | if ( ifcTextFontSelectEClass == null ) { ifcTextFontSelectEClass = ( EClass ) EPackage . Registry . INSTANCE . getEPackage ( Ifc4Package . eNS_URI ) . getEClassifiers ( ) . get ( 1167 ) ; } return ifcTextFontSelectEClass ; |
public class Bindings { /** * Creates the value to be injected .
* @ param argument the argument
* @ param context the context
* @ param engine the engine
* @ return the created object */
public static Object create ( ActionParameter argument , Context context , ParameterFactories engine ) { } } | RouteParameterHandler handler = BINDINGS . get ( argument . getSource ( ) ) ; if ( handler != null ) { return handler . create ( argument , context , engine ) ; } else { LoggerFactory . getLogger ( Bindings . class ) . warn ( "Unsupported route parameter in method : {}" , argument . getSource ( ) . name ( ) ) ; return ... |
public class AbstractFunctionalityGrounding { /** * Asks the channelProducersHelper for a channel with the given parameters ,
* and creates one when there is none available yet . */
public IChannelProducer getProviderChannelFor ( String functionalityName , String clientName , String conversationID ) throws ServiceGro... | IChannelProducer channel = this . channelProducersHelper . getChannel ( functionalityName , clientName , conversationID ) ; if ( null != channel && ! ( channel instanceof InternalChannel ) ) { return channel ; } IChannelProducer newChannel = createProviderChannelFor ( functionalityName , clientName , conversationID ) ;... |
public class VStack { /** * ( non - Javadoc )
* @ see java . util . Collection # isEmpty ( )
* Runtime : 1 voldemort get operation */
public boolean isEmpty ( ) { } } | VListKey < K > newKey = new VListKey < K > ( _key , 0 ) ; Versioned < Map < String , Object > > firstNode = _storeClient . get ( newKey . mapValue ( ) ) ; return firstNode == null ; |
public class StringMessage { /** * UTF - 8 decodes the message . */
public static StringMessage decode ( ByteArray encodedMessage ) { } } | if ( encodedMessage . size == 0 ) return EMPTY_STRING_MESSAGE ; return new StringMessage ( new String ( encodedMessage . array , 0 , encodedMessage . size , CHARSET ) ) ; |
public class MtasToken { /** * Check real offset .
* @ return the boolean */
final public Boolean checkRealOffset ( ) { } } | if ( ( tokenRealOffset == null ) || ! provideRealOffset ) { return false ; } else if ( tokenOffset == null ) { return true ; } else if ( tokenOffset . getStart ( ) == tokenRealOffset . getStart ( ) && tokenOffset . getEnd ( ) == tokenRealOffset . getEnd ( ) ) { return false ; } else { return true ; } |
public class Call { /** * Abbreviation for { { @ link # methodForArrayOf ( Type , String , Object . . . ) } .
* @ since 1.1
* @ param methodName the name of the method
* @ param optionalParameters the ( optional ) parameters of the method .
* @ return the result of the method execution */
public static < R > Fu... | return methodForArrayOf ( resultType , methodName , optionalParameters ) ; |
public class Pattern { /** * Appends a new pattern to the existing one . The new pattern enforces that there is no event matching this pattern
* between the preceding pattern and succeeding this one .
* < p > < b > NOTE : < / b > There has to be other pattern after this one .
* @ param name Name of the new patter... | if ( quantifier . hasProperty ( Quantifier . QuantifierProperty . OPTIONAL ) ) { throw new UnsupportedOperationException ( "Specifying a pattern with an optional path to NOT condition is not supported yet. " + "You can simulate such pattern with two independent patterns, one with and the other without " + "the optional... |
public class FunctionGenerator { /** * Creates a function whose body goes from the child of parentExpr
* up to ( and including ) the functionBodyEndExpr .
* @ param parentExpr */
private void createFunctionIfNeeded ( AbstractFunctionExpression parentExpr ) { } } | GroovyExpression potentialFunctionBody = parentExpr . getCaller ( ) ; if ( creatingFunctionShortensGremlin ( potentialFunctionBody ) ) { GroovyExpression functionCall = null ; if ( nextFunctionBodyStart instanceof AbstractFunctionExpression ) { // The function body start is a a function call . In this
// case , we gene... |
public class VarSet { /** * Gets the subset of vars with the specified type . */
public static List < Var > getVarsOfType ( List < Var > vars , VarType type ) { } } | ArrayList < Var > subset = new ArrayList < Var > ( ) ; for ( Var v : vars ) { if ( v . getType ( ) == type ) { subset . add ( v ) ; } } return subset ; |
public class CipherLiteInputStream { /** * Reads and process the next chunk of data into memory .
* @ return the length of the data chunk read and processed , or - 1 if end of
* stream .
* @ throws IOException
* if there is an IO exception from the underlying input stream
* @ throws SecurityException
* if t... | abortIfNeeded ( ) ; if ( eof ) return - 1 ; bufout = null ; int len = in . read ( bufin ) ; if ( len == - 1 ) { eof = true ; // Skip doFinal if it ' s a multi - part upload but not the last part
if ( ! multipart || lastMultiPart ) { try { bufout = cipherLite . doFinal ( ) ; if ( bufout == null ) { // bufout can be null... |
public class CssSmartSpritesResourceReader { /** * Returns the file of the generated CSS
* @ param path
* the path of the CSS
* @ return the file of the generated CSS */
public File getGeneratedCssFile ( String path ) { } } | String rootDir = tempDir + JawrConstant . CSS_SMARTSPRITES_TMP_DIR ; String fPath = null ; if ( jawrConfig . isWorkingDirectoryInWebApp ( ) ) { fPath = jawrConfig . getContext ( ) . getRealPath ( rootDir + getCssPath ( path ) ) ; } else { fPath = rootDir + getCssPath ( path ) ; } return new File ( fPath ) ; |
public class JobRescheduleService { /** * / * package */
int rescheduleJobs ( JobManager manager , Collection < JobRequest > requests ) { } } | int rescheduledCount = 0 ; boolean exceptionThrown = false ; for ( JobRequest request : requests ) { boolean reschedule ; if ( request . isStarted ( ) ) { Job job = manager . getJob ( request . getJobId ( ) ) ; reschedule = job == null ; } else { reschedule = ! manager . getJobProxy ( request . getJobApi ( ) ) . isPlat... |
public class TokenMapperGeneric { /** * Returns the Lucene { @ link BytesRef } represented by the specified Cassandra { @ link Token } .
* @ param token A Cassandra { @ link Token } .
* @ return The Lucene { @ link BytesRef } represented by the specified Cassandra { @ link Token } . */
@ SuppressWarnings ( "uncheck... | ByteBuffer bb = factory . toByteArray ( token ) ; byte [ ] bytes = ByteBufferUtils . asArray ( bb ) ; return new BytesRef ( bytes ) ; |
public class IR { /** * literals */
public static Node objectlit ( Node ... propdefs ) { } } | Node objectlit = new Node ( Token . OBJECTLIT ) ; for ( Node propdef : propdefs ) { switch ( propdef . getToken ( ) ) { case STRING_KEY : case MEMBER_FUNCTION_DEF : case GETTER_DEF : case SETTER_DEF : case SPREAD : case COMPUTED_PROP : break ; default : throw new IllegalStateException ( "Unexpected OBJECTLIT child: " +... |
public class HttpStatusCodeException { /** * Return the response body as a string .
* @ since 3.0.5 */
public String getResponseBodyAsString ( ) { } } | final ByteBuf bodyByteBuf = httpInputMessage . getBody ( ) ; final String contentEncoding = httpInputMessage . getHeaders ( ) . get ( HttpHeaders . CONTENT_ENCODING ) ; byte [ ] bytes = new byte [ bodyByteBuf . readableBytes ( ) ] ; bodyByteBuf . readBytes ( bytes ) ; return new String ( bytes , contentEncoding != null... |
public class ControlBeanContextSupport { /** * This method instructs the bean that it is OK to use the Gui . */
public void okToUseGui ( ) { } } | if ( _mayUseGui ) return ; _mayUseGui = true ; for ( Object o : _children . keySet ( ) ) { if ( o instanceof Visibility ) { ( ( Visibility ) o ) . okToUseGui ( ) ; } } |
public class JDBC4ResultSet { /** * ResultSet object as an int in the Java programming language . */
@ Override public int getInt ( int columnIndex ) throws SQLException { } } | checkColumnBounds ( columnIndex ) ; try { Long longValue = getPrivateInteger ( columnIndex ) ; if ( longValue > Integer . MAX_VALUE || longValue < Integer . MIN_VALUE ) { throw new SQLException ( "Value out of int range" ) ; } return longValue . intValue ( ) ; } catch ( Exception x ) { throw SQLError . get ( x ) ; } |
public class PartialResponseChangesTypeImpl { /** * If not already created , a new < code > attributes < / code > element will be created and returned .
* Otherwise , the first existing < code > attributes < / code > element will be returned .
* @ return the instance defined for the element < code > attributes < / ... | List < Node > nodeList = childNode . get ( "attributes" ) ; if ( nodeList != null && nodeList . size ( ) > 0 ) { return new PartialResponseAttributesTypeImpl < PartialResponseChangesType < T > > ( this , "attributes" , childNode , nodeList . get ( 0 ) ) ; } return createAttributes ( ) ; |
public class BaseMessageProcessor { /** * Get the message queue registry ID from this message .
* @ param internalMessage The message to get the registry ID from .
* @ return Integer The registry ID . */
public Integer getRegistryID ( BaseMessage internalMessageReply ) { } } | Integer intRegistryID = null ; Object objRegistryID = null ; if ( internalMessageReply . getMessageHeader ( ) instanceof TrxMessageHeader ) // Always
objRegistryID = ( ( TrxMessageHeader ) internalMessageReply . getMessageHeader ( ) ) . getMessageHeaderMap ( ) . get ( TrxMessageHeader . REGISTRY_ID ) ; if ( objRegistry... |
public class Socks4ClientBootstrap { /** * Hijack super class ' s pipelineFactory and return our own that
* does the connect to SOCKS proxy and does the handshake . */
@ Override public ChannelPipelineFactory getPipelineFactory ( ) { } } | return new ChannelPipelineFactory ( ) { @ Override public ChannelPipeline getPipeline ( ) throws Exception { final ChannelPipeline cp = Channels . pipeline ( ) ; cp . addLast ( FRAME_DECODER , new FixedLengthFrameDecoder ( 8 ) ) ; cp . addLast ( HANDSHAKE , new Socks4HandshakeHandler ( Socks4ClientBootstrap . super . g... |
public class SteadyStateEvolutionEngine { /** * { @ inheritDoc } */
@ Override protected List < EvaluatedCandidate < T > > nextEvolutionStep ( List < EvaluatedCandidate < T > > evaluatedPopulation , int eliteCount , Random rng ) { } } | EvolutionUtils . sortEvaluatedPopulation ( evaluatedPopulation , fitnessEvaluator . isNatural ( ) ) ; List < T > selectedCandidates = selectionStrategy . select ( evaluatedPopulation , fitnessEvaluator . isNatural ( ) , selectionSize , rng ) ; List < EvaluatedCandidate < T > > offspring = evaluatePopulation ( evolution... |
public class JSONWriter { /** * value .
* @ param value value .
* @ return this .
* @ throws IOException */
public JSONWriter valueInt ( int value ) throws IOException { } } | beforeValue ( ) ; writer . write ( String . valueOf ( value ) ) ; return this ; |
public class ElementMatchers { /** * Matches a { @ link ModifierReviewable } that is { @ code static } .
* @ param < T > The type of the matched object .
* @ return A matcher for a { @ code static } modifier reviewable . */
public static < T extends ModifierReviewable . OfByteCodeElement > ElementMatcher . Junction... | return new ModifierMatcher < T > ( ModifierMatcher . Mode . STATIC ) ; |
public class StringHelper { /** * Get a concatenated String from all elements of the passed array , separated by
* the specified separator char .
* @ param cSep
* The separator to use .
* @ param aElements
* The container to convert . May be < code > null < / code > or empty .
* @ param nOfs
* The offset ... | return getImplodedMapped ( Character . toString ( cSep ) , aElements , nOfs , nLen , String :: valueOf ) ; |
public class CmsAccountsApp { /** * Gets list of users for organizational unit . < p >
* @ param cms the CMS context
* @ param ou the OU path
* @ param recursive true if users from other OUs should be retrieved
* @ return the list of users , without their additional info
* @ throws CmsException if something g... | return CmsPrincipal . filterCoreUsers ( OpenCms . getOrgUnitManager ( ) . getUsersWithoutAdditionalInfo ( cms , ou , recursive ) ) ; |
public class UsersTableModel { /** * Adds a new user to this model
* @ param user the user */
public void addUser ( User user ) { } } | this . users . add ( user ) ; this . fireTableRowsInserted ( this . users . size ( ) - 1 , this . users . size ( ) - 1 ) ; |
public class AptUtil { /** * Returns the package name of the given { @ link TypeMirror } .
* @ param elementUtils
* @ param typeUtils
* @ param type
* @ return the package name
* @ author backpaper0
* @ author vvakame */
public static String getPackageName ( Elements elementUtils , Types typeUtils , TypeMir... | TypeVisitor < DeclaredType , Object > tv = new SimpleTypeVisitor6 < DeclaredType , Object > ( ) { @ Override public DeclaredType visitDeclared ( DeclaredType t , Object p ) { return t ; } } ; DeclaredType dt = type . accept ( tv , null ) ; if ( dt != null ) { ElementVisitor < TypeElement , Object > ev = new SimpleEleme... |
public class BuildTasksInner { /** * Get the source control properties for a build task .
* @ param resourceGroupName The name of the resource group to which the container registry belongs .
* @ param registryName The name of the container registry .
* @ param buildTaskName The name of the container registry buil... | return listSourceRepositoryPropertiesWithServiceResponseAsync ( resourceGroupName , registryName , buildTaskName ) . map ( new Func1 < ServiceResponse < SourceRepositoryPropertiesInner > , SourceRepositoryPropertiesInner > ( ) { @ Override public SourceRepositoryPropertiesInner call ( ServiceResponse < SourceRepository... |
public class AmazonEC2Client { /** * Describes the ClassicLink status of one or more VPCs .
* @ param describeVpcClassicLinkRequest
* @ return Result of the DescribeVpcClassicLink operation returned by the service .
* @ sample AmazonEC2 . DescribeVpcClassicLink
* @ see < a href = " http : / / docs . aws . amazo... | request = beforeClientExecution ( request ) ; return executeDescribeVpcClassicLink ( request ) ; |
public class Jar { /** * Adds an entry to this JAR .
* @ param path the entry ' s path within the JAR
* @ param file the path of the file to add as an entry
* @ return { @ code this } */
public Jar addEntry ( Path path , String file ) throws IOException { } } | return addEntry ( path , Paths . get ( file ) ) ; |
public class SARLJvmModelInferrer { /** * Remove the type parameters from the given type .
* < p > < table >
* < thead > < tr > < th > Referenced type < / th > < th > Input < / th > < th > Replied referenced type < / th > < th > Output < / th > < / tr > < / thead >
* < tbody >
* < tr > < td > Type with generic ... | final LightweightTypeReference ltr = Utils . toLightweightTypeReference ( type , this . services ) ; return ltr . getRawTypeReference ( ) . toJavaCompliantTypeReference ( ) ; |
public class Strings { /** * Check whether the given String is an identifier according to the EJB - QL definition . See The EJB 2.0 Documentation
* Section 11.2.6.1.
* @ param s String to check
* @ return < code > true < / code > if the given String is a reserved identifier in EJB - QL , < code > false < / code >... | if ( s == null || s . length ( ) == 0 ) { return false ; } for ( int i = 0 ; i < ejbQlIdentifiers . length ; i ++ ) { if ( ejbQlIdentifiers [ i ] . equalsIgnoreCase ( s ) ) { return true ; } } return false ; |
public class Deferrers { /** * Defer some action .
* @ param deferred action to be defer .
* @ return the same object from arguments
* @ since 1.0 */
@ Weight ( Weight . Unit . NORMAL ) public static Deferred defer ( @ Nonnull final Deferred deferred ) { } } | REGISTRY . get ( ) . add ( assertNotNull ( deferred ) ) ; return deferred ; |
public class SubQuery { /** * Fills the table with a result set */
public void materialise ( Session session ) { } } | PersistentStore store ; // table constructors
if ( isDataExpression ) { store = session . sessionData . getSubqueryRowStore ( table ) ; dataExpression . insertValuesIntoSubqueryTable ( session , store ) ; return ; } Result result = queryExpression . getResult ( session , isExistsPredicate ? 1 : 0 ) ; RowSetNavigatorDat... |
public class BufferedByteInputOutput { /** * Write buf to the buffer , will block until it can write len bytes .
* Will fail if buffer is closed . */
public void write ( byte [ ] buf , int off , int len ) throws IOException { } } | while ( true ) { lockW . lock ( ) ; try { // fail if closed
checkClosed ( ) ; final int lenToWrite = Math . min ( len , length - availableCount . get ( ) ) ; final int lenForward = Math . min ( lenToWrite , length - writeCursor ) ; final int lenRemaining = lenToWrite - lenForward ; // after writeCursor
if ( lenForward ... |
public class TrialScopes { /** * Makes a new TrialContext that can be used to invoke */
static TrialContext makeContext ( UUID trialId , int trialNumber , Experiment experiment ) { } } | return new TrialContext ( trialId , trialNumber , experiment ) ; |
public class Maths { /** * Get the value if it is between min and max , min if the value is less than min , or max if the
* value is greater than max . */
public static int clamp ( int value , int min , int max ) { } } | return Math . min ( Math . max ( min , value ) , max ) ; |
public class SeleniumHelper { /** * Takes screenshot of current page ( as . png ) .
* @ param baseName name for file created ( without extension ) ,
* if a file already exists with the supplied name an
* ' _ index ' will be added .
* @ return absolute path of file created . */
public String takeScreenshot ( Str... | String result = null ; WebDriver d = driver ( ) ; if ( ! ( d instanceof TakesScreenshot ) ) { d = new Augmenter ( ) . augment ( d ) ; } if ( d instanceof TakesScreenshot ) { TakesScreenshot ts = ( TakesScreenshot ) d ; byte [ ] png = ts . getScreenshotAs ( OutputType . BYTES ) ; result = writeScreenshot ( baseName , pn... |
public class ZKBrokerPartitionInfo { /** * Generate a sequence of ( brokerId , numPartitions ) for all topics registered in zookeeper
* @ param allBrokers all register brokers
* @ return a mapping from topic to sequence of ( brokerId , numPartitions ) */
private Map < String , SortedSet < Partition > > getZKTopicPa... | final Map < String , SortedSet < Partition > > brokerPartitionsPerTopic = new HashMap < String , SortedSet < Partition > > ( ) ; ZkUtils . makeSurePersistentPathExists ( zkClient , ZkUtils . BrokerTopicsPath ) ; List < String > topics = ZkUtils . getChildrenParentMayNotExist ( zkClient , ZkUtils . BrokerTopicsPath ) ; ... |
public class InternalPureXbaseParser { /** * InternalPureXbase . g : 2991:1 : ruleXSetLiteral returns [ EObject current = null ] : ( ( ) otherlv _ 1 = ' # ' otherlv _ 2 = ' { ' ( ( ( lv _ elements _ 3_0 = ruleXExpression ) ) ( otherlv _ 4 = ' , ' ( ( lv _ elements _ 5_0 = ruleXExpression ) ) ) * ) ? otherlv _ 6 = ' } '... | EObject current = null ; Token otherlv_1 = null ; Token otherlv_2 = null ; Token otherlv_4 = null ; Token otherlv_6 = null ; EObject lv_elements_3_0 = null ; EObject lv_elements_5_0 = null ; enterRule ( ) ; try { // InternalPureXbase . g : 2997:2 : ( ( ( ) otherlv _ 1 = ' # ' otherlv _ 2 = ' { ' ( ( ( lv _ elements _ 3... |
public class ContainerAwareExecutionVenue { /** * In the case of ContextRefreshedEvent ( that is , once all Spring configuration is loaded ) , the following actions
* will be taken :
* < list >
* < li > the superclass ' s onAppEvent will initialise all services < / li >
* < li > The JMXControl will be retrieved... | if ( event instanceof ContextRefreshedEvent ) { super . onApplicationEvent ( event ) ; try { final ApplicationContext ctx = ( ( ContextRefreshedEvent ) event ) . getApplicationContext ( ) ; // Check that the JMXControl exists before registering all exportables
// see JMXControl javadocs for why we have to do it this wa... |
public class PhoneNumberUtil { /** * format phone number in DIN 5008 format with cursor position handling .
* @ param pphoneNumber phone number as String to format with cursor position
* @ param pcountryCode iso code of country
* @ return formated phone number as String with new cursor position */
public final Va... | return valueWithPosDefaults ( this . formatDin5008WithPos ( this . parsePhoneNumber ( pphoneNumber , pcountryCode ) , CreatePhoneCountryConstantsClass . create ( ) . countryMap ( ) . get ( StringUtils . defaultString ( pcountryCode ) ) ) , pphoneNumber ) ; |
public class LoadBalancerTlsCertificate { /** * An array of LoadBalancerTlsCertificateDomainValidationRecord objects describing the records .
* @ param domainValidationRecords
* An array of LoadBalancerTlsCertificateDomainValidationRecord objects describing the records . */
public void setDomainValidationRecords ( ... | if ( domainValidationRecords == null ) { this . domainValidationRecords = null ; return ; } this . domainValidationRecords = new java . util . ArrayList < LoadBalancerTlsCertificateDomainValidationRecord > ( domainValidationRecords ) ; |
public class SerializationUtil { /** * Reads a list from the given { @ link ObjectDataInput } . It is expected that
* the next int read from the data input is the list ' s size , then that
* many objects are read from the data input and returned as a list .
* @ param in data input to read from
* @ param < T > t... | int size = in . readInt ( ) ; if ( size == 0 ) { return Collections . emptyList ( ) ; } List < T > list = new ArrayList < > ( size ) ; for ( int i = 0 ; i < size ; i ++ ) { T item = in . readObject ( ) ; list . add ( item ) ; } return list ; |
public class Entry { /** * A read - only property used for retrieving the start time of the entry . The
* property gets updated whenever the start time inside the entry interval
* changes ( see { @ link # intervalProperty ( ) } ) .
* @ return the start time of the entry */
public final ReadOnlyObjectProperty < Lo... | if ( startTime == null ) { startTime = new ReadOnlyObjectWrapper < > ( this , "startTime" , getInterval ( ) . getStartTime ( ) ) ; // $ NON - NLS - 1 $
} return startTime . getReadOnlyProperty ( ) ; |
public class nsip6 { /** * Use this API to delete nsip6 resources . */
public static base_responses delete ( nitro_service client , nsip6 resources [ ] ) throws Exception { } } | base_responses result = null ; if ( resources != null && resources . length > 0 ) { nsip6 deleteresources [ ] = new nsip6 [ resources . length ] ; for ( int i = 0 ; i < resources . length ; i ++ ) { deleteresources [ i ] = new nsip6 ( ) ; deleteresources [ i ] . ipv6address = resources [ i ] . ipv6address ; deleteresou... |
public class DateBetween { /** * 计算两个日期相差年数 < br >
* 在非重置情况下 , 如果起始日期的月小于结束日期的月 , 年数要少算1 ( 不足1年 )
* @ param isReset 是否重置时间为起始时间 ( 重置月天时分秒 )
* @ return 相差年数
* @ since 3.0.8 */
public long betweenYear ( boolean isReset ) { } } | final Calendar beginCal = DateUtil . calendar ( begin ) ; final Calendar endCal = DateUtil . calendar ( end ) ; int result = endCal . get ( Calendar . YEAR ) - beginCal . get ( Calendar . YEAR ) ; if ( false == isReset ) { endCal . set ( Calendar . YEAR , beginCal . get ( Calendar . YEAR ) ) ; long between = endCal . g... |
public class MessageStoreImpl { /** * Initalizes the message store using the given JetStream configuration . Copies the relevant
* pieces of data into a MessageStoreConfiguration object which is then used to initialize
* the message store . Will only initialize PMI if this is not a reload .
* @ param engineConfig... | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "initialize" , new Object [ ] { "isReload=" + isReload , "Config=" + engineConfiguration } ) ; _messagingEngine = engineConfiguration ; final WASConfiguration configuration = WASConfiguration . getDefaultWasConfigurat... |
public class HTMLExtractor { /** * Checks if any of the elements matched by the { @ code selector } contain the attribute { @ code attributeName } . The { @ code url } is used
* only for caching purposes , to avoid parsing multiple times the markup returned for the same resource .
* @ param url the url that identif... | ensureMarkup ( url , markup ) ; Document document = documents . get ( url ) ; Elements elements = document . select ( selector ) ; return ! elements . isEmpty ( ) && elements . hasAttr ( attributeName ) ; |
public class CacheHandler { /** * 从数据源中获取最新数据 , 并写入缓存 。 注意 : 这里不使用 “ 拿来主义 ” 机制 , 是因为当前可能是更新数据的方法 。
* @ param pjp CacheAopProxyChain
* @ param cache Cache注解
* @ return 最新数据
* @ throws Throwable 异常 */
private Object writeOnly ( CacheAopProxyChain pjp , Cache cache ) throws Throwable { } } | DataLoaderFactory factory = DataLoaderFactory . getInstance ( ) ; DataLoader dataLoader = factory . getDataLoader ( ) ; CacheWrapper < Object > cacheWrapper ; try { cacheWrapper = dataLoader . init ( pjp , cache , this ) . getData ( ) . getCacheWrapper ( ) ; } catch ( Throwable e ) { throw e ; } finally { factory . ret... |
public class GeoTarget { /** * Parent IDs are legacy , and some records are inconsistent , so we following AdX ' s docs
* and build hierarchy by the canonical names . Notice canonical names are not always
* unique for leaf records , e . g . " New York , New York , United States " can be either the
* City ( 102319... | int pos = name . indexOf ( ',' ) ; if ( pos == - 1 ) { int canonPos = key . canonicalName . indexOf ( ',' ) ; return canonPos == - 1 ? null : key . canonicalName . substring ( canonPos + 1 ) ; } else { int commas = 1 ; for ( int i = pos + 1 ; i < name . length ( ) ; ++ i ) { if ( name . charAt ( i ) == ',' ) { ++ comma... |
public class GetCurrentMetricDataRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( GetCurrentMetricDataRequest getCurrentMetricDataRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( getCurrentMetricDataRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( getCurrentMetricDataRequest . getInstanceId ( ) , INSTANCEID_BINDING ) ; protocolMarshaller . marshall ( getCurrentMetricDataRequest . getFilters ( ) , FILTE... |
public class ApiOvhMe { /** * Get this object properties
* REST : GET / me / deposit / { depositId } / details / { depositDetailId }
* @ param depositId [ required ]
* @ param depositDetailId [ required ] */
public OvhDepositDetail deposit_depositId_details_depositDetailId_GET ( String depositId , String depositD... | String qPath = "/me/deposit/{depositId}/details/{depositDetailId}" ; StringBuilder sb = path ( qPath , depositId , depositDetailId ) ; String resp = exec ( qPath , "GET" , sb . toString ( ) , null ) ; return convertTo ( resp , OvhDepositDetail . class ) ; |
public class SyncMembersInner { /** * Gets a sync member database schema .
* @ param resourceGroupName The name of the resource group that contains the resource . You can obtain this value from the Azure Resource Manager API or the portal .
* @ param serverName The name of the server .
* @ param databaseName The ... | return AzureServiceFuture . fromPageResponse ( listMemberSchemasSinglePageAsync ( resourceGroupName , serverName , databaseName , syncGroupName , syncMemberName ) , new Func1 < String , Observable < ServiceResponse < Page < SyncFullSchemaPropertiesInner > > > > ( ) { @ Override public Observable < ServiceResponse < Pag... |
public class MicrochipPotentiometerDeviceController { /** * Enables or disables a wiper ' s lock .
* Hint : This will only work using the & quot ; High Volate Command & quot ; ( see 3.1 ) .
* @ param channel Which wiper
* @ param locked Whether to enable the wiper ' s lock
* @ throws IOException Thrown if commu... | if ( channel == null ) { throw new RuntimeException ( "null-channel is not allowed. For devices " + "knowing just one wiper Channel.A is mandatory for " + "parameter 'channel'" ) ; } byte memAddr = channel . getNonVolatileMemoryAddress ( ) ; // increasing or decreasing on non - volatile wipers
// enables or disables Wi... |
public class GISTrainer { /** * / * Compute one iteration of GIS and return log - likelihood . */
private double nextIteration ( double correctionConstant ) { } } | // compute contribution of p ( a | b _ i ) for each feature and the new
// correction parameter
double loglikelihood = 0.0 ; int numEvents = 0 ; int numCorrect = 0 ; int numberOfThreads = modelExpects . length ; ExecutorService executor = Executors . newFixedThreadPool ( numberOfThreads ) ; int taskSize = numUniqueEven... |
public class CPDefinitionSpecificationOptionValuePersistenceImpl { /** * Returns the last cp definition specification option value in the ordered set where CPSpecificationOptionId = & # 63 ; .
* @ param CPSpecificationOptionId the cp specification option ID
* @ param orderByComparator the comparator to order the se... | CPDefinitionSpecificationOptionValue cpDefinitionSpecificationOptionValue = fetchByCPSpecificationOptionId_Last ( CPSpecificationOptionId , orderByComparator ) ; if ( cpDefinitionSpecificationOptionValue != null ) { return cpDefinitionSpecificationOptionValue ; } StringBundler msg = new StringBundler ( 4 ) ; msg . appe... |
public class InternationalizationServiceSingleton { /** * Retrieves the set of resource bundles handled by the system providing messages for the given locale .
* @ param locale the locale
* @ return the set of resource bundle , empty if none . */
@ Override public Collection < ResourceBundle > bundles ( Locale loca... | Set < ResourceBundle > bundles = new LinkedHashSet < > ( ) ; for ( I18nExtension extension : extensions ) { if ( extension . locale ( ) . equals ( locale ) ) { bundles . add ( extension . bundle ( ) ) ; } } return bundles ; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.