signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class Misc { /** * Returns the URL for file on the classpath as a String */
public static String getResourceURL ( String resource ) { } } | ClassLoader cl = Thread . currentThread ( ) . getContextClassLoader ( ) ; return cl . getResource ( resource ) . toString ( ) ; |
public class druidGLexer { /** * $ ANTLR start " DROP " */
public final void mDROP ( ) throws RecognitionException { } } | try { int _type = DROP ; int _channel = DEFAULT_TOKEN_CHANNEL ; // druidG . g : 594:17 : ( ( ' DROP ' | ' drop ' ) )
// druidG . g : 594:18 : ( ' DROP ' | ' drop ' )
{ // druidG . g : 594:18 : ( ' DROP ' | ' drop ' )
int alt10 = 2 ; int LA10_0 = input . LA ( 1 ) ; if ( ( LA10_0 == 'D' ) ) { alt10 = 1 ; } else if ( ( LA10_0 == 'd' ) ) { alt10 = 2 ; } else { NoViableAltException nvae = new NoViableAltException ( "" , 10 , 0 , input ) ; throw nvae ; } switch ( alt10 ) { case 1 : // druidG . g : 594:19 : ' DROP '
{ match ( "DROP" ) ; } break ; case 2 : // druidG . g : 594:26 : ' drop '
{ match ( "drop" ) ; } break ; } } state . type = _type ; state . channel = _channel ; } finally { // do for sure before leaving
} |
public class QueryCountLoggerBuilder { /** * Build { @ link net . ttddyy . dsproxy . support . SLF4JQueryCountLoggingServletFilter } .
* @ param logLevel slf4j log level
* @ return query - count - logger using slf4j */
public SLF4JQueryCountLoggingServletFilter buildSlf4jFilter ( SLF4JLogLevel logLevel ) { } } | if ( logLevel != null ) { this . slf4jLogLevel = logLevel ; } SLF4JQueryCountLoggingServletFilter filter = new SLF4JQueryCountLoggingServletFilter ( ) ; if ( this . slf4jLogLevel != null ) { filter . setLogLevel ( this . slf4jLogLevel ) ; } filter . setWriteAsJson ( this . writeAsJson ) ; return filter ; |
public class vpntrafficaction { /** * Use this API to fetch vpntrafficaction resource of given name . */
public static vpntrafficaction get ( nitro_service service , String name ) throws Exception { } } | vpntrafficaction obj = new vpntrafficaction ( ) ; obj . set_name ( name ) ; vpntrafficaction response = ( vpntrafficaction ) obj . get_resource ( service ) ; return response ; |
public class JSONObject { /** * Appends values to the array mapped to { @ code name } . A new { @ link JSONArray }
* mapping for { @ code name } will be inserted if no mapping exists . If the existing
* mapping for { @ code name } is not a { @ link JSONArray } , a { @ link JSONException }
* will be thrown .
* @ throws JSONException if { @ code name } is { @ code null } or if the mapping for
* { @ code name } is non - null and is not a { @ link JSONArray } .
* @ hide */
public JSONObject append ( String name , Object value ) throws JSONException { } } | Object current = nameValuePairs . get ( checkName ( name ) ) ; final JSONArray array ; if ( current instanceof JSONArray ) { array = ( JSONArray ) current ; } else if ( current == null ) { JSONArray newArray = new JSONArray ( ) ; nameValuePairs . put ( name , newArray ) ; array = newArray ; } else { throw new JSONException ( "Key " + name + " is not a JSONArray" ) ; } array . checkedPut ( value ) ; return this ; |
public class VirtualCdj { /** * Send a device update to all registered update listeners .
* @ param update the device update that has just arrived */
private void deliverDeviceUpdate ( final DeviceUpdate update ) { } } | for ( DeviceUpdateListener listener : getUpdateListeners ( ) ) { try { listener . received ( update ) ; } catch ( Throwable t ) { logger . warn ( "Problem delivering device update to listener" , t ) ; } } |
public class TCAPProviderImpl { /** * get next Seq Control value available */
protected int getNextSeqControl ( ) { } } | int res = seqControl . getAndIncrement ( ) ; // if ( ! seqControl . compareAndSet ( 256 , 1 ) ) {
// return seqControl . getAndIncrement ( ) ;
// } else {
// return 0;
// seqControl + + ;
// if ( seqControl > 255 ) {
// seqControl = 0;
// return seqControl ;
if ( this . stack . getSlsRangeType ( ) == SlsRangeType . Odd ) { if ( res % 2 == 0 ) res ++ ; } else if ( this . stack . getSlsRangeType ( ) == SlsRangeType . Even ) { if ( res % 2 != 0 ) res ++ ; } res = res & 0xFF ; return res ; |
public class Era { /** * 指定した日時に該当する期間情報を取得する 。
* @ param date 判定対象の日時 。 タイムゾーンは 、 { @ literal GMT - 00:00 } である必要がある 。
* @ return 見つからない場合は 、 存在しない期間を示すクラス { @ link EraPeriod # UNKNOWN _ PERIOD } のインスタンスを返す 。
* @ throws IllegalArgumentException { @ literal date = = null . } */
public EraPeriod getTargetPeriod ( final Date date ) { } } | ArgUtils . notNull ( date , "date" ) ; for ( EraPeriod period : periods ) { if ( period . contains ( date ) ) { return period ; } } return EraPeriod . UNKNOWN_PERIOD ; |
public class A_CmsListResourceCollector { /** * Returns the state of the parameter map . < p >
* @ param params the parameter map
* @ return the state of the list from the parameter map */
protected CmsListState getState ( Map < String , String > params ) { } } | CmsListState state = new CmsListState ( ) ; try { state . setPage ( Integer . parseInt ( params . get ( I_CmsListResourceCollector . PARAM_PAGE ) ) ) ; } catch ( Throwable e ) { // ignore
} try { state . setOrder ( CmsListOrderEnum . valueOf ( params . get ( I_CmsListResourceCollector . PARAM_ORDER ) ) ) ; } catch ( Throwable e ) { // ignore
} try { state . setFilter ( params . get ( I_CmsListResourceCollector . PARAM_FILTER ) ) ; } catch ( Throwable e ) { // ignore
} try { state . setColumn ( params . get ( I_CmsListResourceCollector . PARAM_SORTBY ) ) ; } catch ( Throwable e ) { // ignore
} return state ; |
public class BeanContextServicesSupport { /** * The implementation goes through following steps :
* < ol >
* < li > Calls < code > defaultReadObject ( ) < / code > . < / li >
* < li > Reads serializable service listeners . < / li >
* < / ol >
* @ param ois
* the object input stream
* @ throws IOException
* if I / O error occurs
* @ throws ClassNotFoundException
* if class of read object is not found */
private void readObject ( ObjectInputStream ois ) throws IOException , ClassNotFoundException { } } | ois . defaultReadObject ( ) ; deserialize ( ois , bcsListeners ) ; |
public class PackratParser { /** * After finding a recursion or a seed grow in process , this method puts all
* information in place for seed grow . This might be the start information for
* the growth or the current result in the growing , which means the current
* result .
* @ param production
* @ param l
* @ throws ParserException */
private void setupLR ( String production , final LR l ) throws ParserException { } } | /* * If the lr object does not contain a head , we found a new recursion
* production . Otherwise we already know the production , but we found another
* production which is involved in the recursion . */
if ( l . getHead ( ) == null ) l . setHead ( new Head ( production ) ) ; /* * Go over all heads and . . . ! ? */
RuleInvocation s = ruleInvocationStack ; while ( ! l . getHead ( ) . getProduction ( ) . equals ( s . getProduction ( ) ) ) { s . setHead ( l . getHead ( ) ) ; l . getHead ( ) . addInvolved ( s . getProduction ( ) ) ; s = s . getNext ( ) ; if ( s == null ) throw new RuntimeException ( "We should find the head again, when we search the stack.\n" + "We found a recursion and the rule should be there again." ) ; } |
public class Locale { /** * Returns a three - letter abbreviation of this locale ' s language .
* If the language matches an ISO 639-1 two - letter code , the
* corresponding ISO 639-2 / T three - letter lowercase code is
* returned . The ISO 639-2 language codes can be found on - line ,
* see " Codes for the Representation of Names of Languages Part 2:
* Alpha - 3 Code " . If the locale specifies a three - letter
* language , the language is returned as is . If the locale does
* not specify a language the empty string is returned .
* @ return A three - letter abbreviation of this locale ' s language .
* @ exception MissingResourceException Throws MissingResourceException if
* three - letter language abbreviation is not available for this locale . */
public String getISO3Language ( ) throws MissingResourceException { } } | // Android - changed : Use ICU . getIso3Language . Also return " " for empty languages
// for the sake of backwards compatibility .
String lang = baseLocale . getLanguage ( ) ; if ( lang . length ( ) == 3 ) { return lang ; } else if ( lang . isEmpty ( ) ) { return "" ; } String language3 = ICU . getISO3Language ( lang ) ; if ( ! lang . isEmpty ( ) && language3 . isEmpty ( ) ) { throw new MissingResourceException ( "Couldn't find 3-letter language code for " + lang , "FormatData_" + toString ( ) , "ShortLanguage" ) ; } return language3 ; |
public class ListTaskExecutionsResult { /** * A list of executed tasks .
* < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use
* { @ link # setTaskExecutions ( java . util . Collection ) } or { @ link # withTaskExecutions ( java . util . Collection ) } if you want
* to override the existing values .
* @ param taskExecutions
* A list of executed tasks .
* @ return Returns a reference to this object so that method calls can be chained together . */
public ListTaskExecutionsResult withTaskExecutions ( TaskExecutionListEntry ... taskExecutions ) { } } | if ( this . taskExecutions == null ) { setTaskExecutions ( new java . util . ArrayList < TaskExecutionListEntry > ( taskExecutions . length ) ) ; } for ( TaskExecutionListEntry ele : taskExecutions ) { this . taskExecutions . add ( ele ) ; } return this ; |
public class DeviceList { /** * Start device discover with the BluetoothAdapter */
private void doDiscovery ( ) { } } | if ( D ) Log . d ( TAG , "doDiscovery()" ) ; // Remove all element from the list
mPairedDevicesArrayAdapter . clear ( ) ; // If there are paired devices , add each one to the ArrayAdapter
if ( pairedDevices . size ( ) > 0 ) { for ( BluetoothDevice device : pairedDevices ) { mPairedDevicesArrayAdapter . add ( device . getName ( ) + "\n" + device . getAddress ( ) ) ; } } else { String strNoFound = getIntent ( ) . getStringExtra ( "no_devices_found" ) ; if ( strNoFound == null ) strNoFound = "No devices found" ; mPairedDevicesArrayAdapter . add ( strNoFound ) ; } // Indicate scanning in the title
String strScanning = getIntent ( ) . getStringExtra ( "scanning" ) ; if ( strScanning == null ) strScanning = "Scanning for devices..." ; setProgressBarIndeterminateVisibility ( true ) ; setTitle ( strScanning ) ; // Turn on sub - title for new devices
// findViewById ( R . id . title _ new _ devices ) . setVisibility ( View . VISIBLE ) ;
// If we ' re already discovering , stop it
if ( mBtAdapter . isDiscovering ( ) ) { mBtAdapter . cancelDiscovery ( ) ; } // Request discover from BluetoothAdapter
mBtAdapter . startDiscovery ( ) ; |
public class CmsShellCommands { /** * Returns the owner of a project . < p >
* @ param project the id of the project
* @ return the owner of the project
* @ throws Exception if something goes wrong */
public CmsUser readOwnerOfProject ( CmsUUID project ) throws Exception { } } | return m_cms . readOwner ( m_cms . readProject ( project ) ) ; |
public class SpatialJoinUtils { /** * Returns a subset of conjuncts matching one of the following shapes :
* - ST _ Contains ( . . . )
* - ST _ Within ( . . . )
* - ST _ Intersects ( . . . )
* Doesn ' t check or guarantee anything about function arguments . */
public static List < FunctionCall > extractSupportedSpatialFunctions ( Expression filterExpression ) { } } | return extractConjuncts ( filterExpression ) . stream ( ) . filter ( FunctionCall . class :: isInstance ) . map ( FunctionCall . class :: cast ) . filter ( SpatialJoinUtils :: isSupportedSpatialFunction ) . collect ( toImmutableList ( ) ) ; |
public class AbcGrammar { /** * grace notes can have length
* grace - notes : : = " { " acciaccatura 1 * ( grace - note - stem ) " } " */
Rule GraceNotes ( ) { } } | return Sequence ( String ( "{" ) , OptionalS ( Acciaccatura ( ) ) , ZeroOrMoreS ( GraceNoteStem ( ) ) , String ( "}" ) ) . label ( GraceNotes ) ; |
public class FileSystemUtilities { /** * Filters files found either in the sources paths ( or in the standardDirectory if no explicit sources are given ) ,
* and retrieves a List holding those files that do not match any of the supplied Java Regular Expression
* excludePatterns .
* @ param baseDir The non - null basedir Directory .
* @ param sources The sources which should be either absolute or relative ( to the given baseDir )
* paths to files or to directories that should be searched recursively for files .
* @ param standardDirectory If no sources are given , revert to searching all files under this standard directory .
* This is the path appended to the baseDir to reach a directory .
* @ param log A non - null Maven Log for logging any operations performed .
* @ param fileTypeDescription A human - readable short description of what kind of files are searched for , such as
* " xsdSources " or " xjbSources " .
* @ param excludeFilters An optional List of Filters used to identify files which should be excluded from
* the result .
* @ return All files under the supplied sources ( or standardDirectory , if no explicit sources are given ) which
* do not match the supplied Java Regular excludePatterns . */
@ SuppressWarnings ( "CheckStyle" ) public static List < File > filterFiles ( final File baseDir , final List < String > sources , final String standardDirectory , final Log log , final String fileTypeDescription , final List < Filter < File > > excludeFilters ) { } } | // Check sanity
Validate . notNull ( baseDir , "baseDir" ) ; Validate . notNull ( log , "log" ) ; Validate . notEmpty ( standardDirectory , "standardDirectory" ) ; Validate . notEmpty ( fileTypeDescription , "fileTypeDescription" ) ; // No sources provided ? Fallback to the standard ( which should be a relative path ) .
List < String > effectiveSources = sources ; if ( sources == null || sources . isEmpty ( ) ) { effectiveSources = new ArrayList < String > ( ) ; final File tmp = new File ( standardDirectory ) ; final File rootDirectory = tmp . isAbsolute ( ) ? tmp : new File ( baseDir , standardDirectory ) ; effectiveSources . add ( FileSystemUtilities . getCanonicalPath ( rootDirectory ) ) ; } // First , remove the non - existent sources .
List < File > existingSources = new ArrayList < File > ( ) ; for ( String current : effectiveSources ) { final File existingFile = FileSystemUtilities . getExistingFile ( current , baseDir ) ; if ( existingFile != null ) { existingSources . add ( existingFile ) ; if ( log . isDebugEnabled ( ) ) { log . debug ( "Accepted configured " + fileTypeDescription + " [" + FileSystemUtilities . getCanonicalFile ( existingFile ) + "]" ) ; } } else { if ( log . isInfoEnabled ( ) ) { log . info ( "Ignored given or default " + fileTypeDescription + " [" + current + "], since it is not an existent file or directory." ) ; } } } if ( log . isDebugEnabled ( ) && existingSources . size ( ) > 0 ) { final int size = existingSources . size ( ) ; log . debug ( " [" + size + " existing " + fileTypeDescription + "] ..." ) ; for ( int i = 0 ; i < size ; i ++ ) { log . debug ( " " + ( i + 1 ) + "/" + size + ": " + existingSources . get ( i ) ) ; } log . debug ( " ... End [" + size + " existing " + fileTypeDescription + "]" ) ; } // All Done .
return FileSystemUtilities . resolveRecursively ( existingSources , excludeFilters , log ) ; |
public class ArrayMath { /** * OPERATIONS ON AN ARRAY - NONDESTRUCTIVE */
public static double [ ] exp ( double [ ] a ) { } } | double [ ] result = new double [ a . length ] ; for ( int i = 0 ; i < a . length ; i ++ ) { result [ i ] = Math . exp ( a [ i ] ) ; } return result ; |
public class BasicStreamReader { /** * Method that will skip any white space from input source ( s )
* @ return true If at least one white space was skipped ; false
* if not ( character passed was not white space ) */
protected final boolean skipWS ( char c ) throws XMLStreamException { } } | if ( c > CHAR_SPACE ) { return false ; } while ( true ) { // Linefeed ?
if ( c == '\n' || c == '\r' ) { skipCRLF ( c ) ; } else if ( c != CHAR_SPACE && c != '\t' ) { throwInvalidSpace ( c ) ; } if ( mInputPtr >= mInputEnd ) { // Let ' s see if current source has more
if ( ! loadMoreFromCurrent ( ) ) { return true ; } } c = mInputBuffer [ mInputPtr ] ; if ( c > CHAR_SPACE ) { // not WS ? Need to return
return true ; } ++ mInputPtr ; } |
public class AWSBatchClient { /** * Cancels a job in an AWS Batch job queue . Jobs that are in the < code > SUBMITTED < / code > , < code > PENDING < / code > , or
* < code > RUNNABLE < / code > state are cancelled . Jobs that have progressed to < code > STARTING < / code > or
* < code > RUNNING < / code > are not cancelled ( but the API operation still succeeds , even if no job is cancelled ) ; these
* jobs must be terminated with the < a > TerminateJob < / a > operation .
* @ param cancelJobRequest
* @ return Result of the CancelJob operation returned by the service .
* @ throws ClientException
* These errors are usually caused by a client action , such as using an action or resource on behalf of a
* user that doesn ' t have permissions to use the action or resource , or specifying an identifier that is not
* valid .
* @ throws ServerException
* These errors are usually caused by a server issue .
* @ sample AWSBatch . CancelJob
* @ see < a href = " http : / / docs . aws . amazon . com / goto / WebAPI / batch - 2016-08-10 / CancelJob " target = " _ top " > AWS API
* Documentation < / a > */
@ Override public CancelJobResult cancelJob ( CancelJobRequest request ) { } } | request = beforeClientExecution ( request ) ; return executeCancelJob ( request ) ; |
public class MetricsManager { /** * Get MetricsLogger to start collecting metrics . MetricsLogger can be used to collect Counter , Timer or Recorder
* @ param dimensions , key - value pairs aka dimensions for example " api = Upload , region = DUB "
* @ return metrics logger */
public static MetricsLogger getMetricsLogger ( final String dimensions ) { } } | if ( MetricsManager . instance != null ) { final Map < String , String > dimensionsMap = DimensionsUtils . parseDimensions ( dimensions ) ; if ( ! dimensionsMap . isEmpty ( ) ) { dimensionsMap . put ( "service" , MetricsManager . instance . serviceName ) ; if ( MetricsManager . instance . env . length ( ) > 0 ) { dimensionsMap . put ( "env" , MetricsManager . instance . env ) ; } return MetricsManager . instance . metricsLoggers . computeIfAbsent ( DimensionsUtils . serializeDimensionsToString ( dimensionsMap ) , key -> new MetricsLogger ( dimensionsMap ) ) ; } else { throw new IllegalArgumentException ( "Dimensions must be valid and non-empty" ) ; } } return dummyLogger ; |
public class CmsScrollPanel { /** * Sets the start parameters of the resize event . < p >
* @ param event the mouse event */
protected void setStartParameters ( MouseDownEvent event ) { } } | m_oldheight = Double . parseDouble ( getElement ( ) . getStyle ( ) . getHeight ( ) . replace ( "px" , "" ) ) ; m_clientY = event . getClientY ( ) ; |
public class KeyInfo { /** * { @ inheritDoc } */
@ Override public int compareTo ( final KeyInfo other ) { } } | int retVal = 1 ; if ( other != null ) { if ( this . name != null && other . name != null ) { retVal = this . name . compareTo ( other . name ) ; } else if ( this . name == null ) { retVal = ( other . name == null ) ? 0 : - 1 ; } } return retVal ; |
public class CQLSSTableWriter { /** * Adds a new row to the writer .
* This is a shortcut for { @ code addRow ( Arrays . asList ( values ) ) } .
* @ param values the row values ( corresponding to the bind variables of the
* insertion statement used when creating by this writer ) .
* @ return this writer . */
public CQLSSTableWriter addRow ( Object ... values ) throws InvalidRequestException , IOException { } } | return addRow ( Arrays . asList ( values ) ) ; |
public class ClobStreamingProcess { /** * { @ inheritDoc } */
@ Override public long length ( Clob entity ) throws IOException { } } | try { return entity . length ( ) ; } catch ( SQLException e ) { throw new IOException ( e ) ; } |
public class Logic { /** * Negates the given predicate .
* @ param < T > the element type parameter
* @ param predicate the predicate to be negated
* @ return the negated predicate */
public static < T > Predicate < T > not ( Predicate < T > predicate ) { } } | dbc . precondition ( predicate != null , "cannot negate a null predicate" ) ; return predicate . negate ( ) ; |
public class Annotate { /** * Tokenizes and segments input text . Outputs tokenized text in conll format :
* one token per sentence and two newlines to divide sentences plus offsets
* and lenght information about tokens .
* @ return String tokenized text */
public String tokenizeToCoNLLOffsets ( ) { } } | final StringBuilder sb = new StringBuilder ( ) ; final String [ ] sentences = segmenter . segmentSentence ( ) ; final List < List < Token > > tokens = tokenizer . tokenize ( sentences ) ; for ( final List < Token > tokSentence : tokens ) { for ( final Token token : tokSentence ) { String tokenValue = token . getTokenValue ( ) ; if ( tokenValue . equals ( RuleBasedSegmenter . PARAGRAPH ) ) { tokenValue = DEFAULT_TOKEN_VALUE ; } sb . append ( tokenValue . trim ( ) ) . append ( DELIMITER ) . append ( token . startOffset ( ) ) . append ( DELIMITER ) . append ( token . tokenLength ( ) ) . append ( LINE_BREAK ) ; } sb . append ( LINE_BREAK ) ; } return sb . toString ( ) ; |
public class JDBCResultSet { /** * < ! - - start generic documentation - - >
* ( JDBC4 clarification : )
* Updates the designated column with a binary stream value , which will have
* the specified number of bytes .
* The updater methods are used to update column values in the
* current row or the insert row . The updater methods do not
* update the underlying database ; instead the < code > updateRow < / code > or
* < code > insertRow < / code > methods are called to update the database .
* < ! - - end generic documentation - - >
* < ! - - start release - specific documentation - - >
* < div class = " ReleaseSpecificDocumentation " >
* < h3 > HSQLDB - Specific Information : < / h3 > < p >
* HSQLDB supports this feature . < p >
* < / div >
* < ! - - end release - specific documentation - - >
* @ param columnIndex the first column is 1 , the second is 2 , . . .
* @ param x the new column value
* @ param length the length of the stream
* @ exception SQLException if a database access error occurs ,
* the result set concurrency is < code > CONCUR _ READ _ ONLY < / code >
* or this method is called on a closed result set
* @ exception SQLFeatureNotSupportedException if the JDBC driver does not support
* this method
* @ since JDK 1.2 ( JDK 1.1 . x developers : read the overview for
* JDBCResultSet ) */
public void updateBinaryStream ( int columnIndex , java . io . InputStream x , int length ) throws SQLException { } } | startUpdate ( columnIndex ) ; preparedStatement . setBinaryStream ( columnIndex , x , length ) ; |
public class Cipher { /** * Tries to find the correct { @ code Cipher } transform to use . Returns a
* { @ link org . apache . harmony . security . fortress . Engine . SpiAndProvider } , throws the first exception that was
* encountered during attempted initialization , or { @ code null } if there are
* no providers that support the { @ code initParams } .
* { @ code tokenizedTransformation } must be in the format returned by
* { @ link Cipher # checkTransformation ( String ) } . The combinations of mode strings
* tried are as follows :
* < ul >
* < li > < code > [ cipher ] / [ mode ] / [ padding ] < / code >
* < li > < code > [ cipher ] / [ mode ] < / code >
* < li > < code > [ cipher ] / / [ padding ] < / code >
* < li > < code > [ cipher ] < / code >
* < / ul >
* { @ code services } is a list of cipher services . Needs to be non - null only if
* { @ code provider ! = null } */
static CipherSpiAndProvider tryCombinations ( InitParams initParams , Provider provider , String [ ] tokenizedTransformation ) throws InvalidKeyException , InvalidAlgorithmParameterException { } } | // Enumerate all the transforms we need to try
ArrayList < Transform > transforms = new ArrayList < Transform > ( ) ; if ( tokenizedTransformation [ 1 ] != null && tokenizedTransformation [ 2 ] != null ) { transforms . add ( new Transform ( tokenizedTransformation [ 0 ] + "/" + tokenizedTransformation [ 1 ] + "/" + tokenizedTransformation [ 2 ] , NeedToSet . NONE ) ) ; } if ( tokenizedTransformation [ 1 ] != null ) { transforms . add ( new Transform ( tokenizedTransformation [ 0 ] + "/" + tokenizedTransformation [ 1 ] , NeedToSet . PADDING ) ) ; } if ( tokenizedTransformation [ 2 ] != null ) { transforms . add ( new Transform ( tokenizedTransformation [ 0 ] + "//" + tokenizedTransformation [ 2 ] , NeedToSet . MODE ) ) ; } transforms . add ( new Transform ( tokenizedTransformation [ 0 ] , NeedToSet . BOTH ) ) ; // Try each of the transforms and keep track of the first exception
// encountered .
Exception cause = null ; if ( provider != null ) { for ( Transform transform : transforms ) { Provider . Service service = provider . getService ( "Cipher" , transform . name ) ; if ( service == null ) { continue ; } return tryTransformWithProvider ( initParams , tokenizedTransformation , transform . needToSet , service ) ; } } else { for ( Provider prov : Security . getProviders ( ) ) { for ( Transform transform : transforms ) { Provider . Service service = prov . getService ( "Cipher" , transform . name ) ; if ( service == null ) { continue ; } if ( initParams == null || initParams . key == null || service . supportsParameter ( initParams . key ) ) { try { CipherSpiAndProvider sap = tryTransformWithProvider ( initParams , tokenizedTransformation , transform . needToSet , service ) ; if ( sap != null ) { return sap ; } } catch ( Exception e ) { if ( cause == null ) { cause = e ; } } } } } } if ( cause instanceof InvalidKeyException ) { throw ( InvalidKeyException ) cause ; } else if ( cause instanceof InvalidAlgorithmParameterException ) { throw ( InvalidAlgorithmParameterException ) cause ; } else if ( cause instanceof RuntimeException ) { throw ( RuntimeException ) cause ; } else if ( cause != null ) { throw new InvalidKeyException ( "No provider can be initialized with given key" , cause ) ; } else if ( initParams == null || initParams . key == null ) { return null ; } else { // Since the key is not null , a suitable provider exists ,
// and it is an InvalidKeyException .
throw new InvalidKeyException ( "No provider offers " + Arrays . toString ( tokenizedTransformation ) + " for " + initParams . key . getAlgorithm ( ) + " key of class " + initParams . key . getClass ( ) . getName ( ) + " and export format " + initParams . key . getFormat ( ) ) ; } |
public class DsParser { /** * Store recovery
* @ param r The recovery
* @ param writer The writer
* @ exception Exception Thrown if an error occurs */
@ Override protected void storeRecovery ( Recovery r , XMLStreamWriter writer ) throws Exception { } } | writer . writeStartElement ( XML . ELEMENT_RECOVERY ) ; if ( r . isNoRecovery ( ) != null ) writer . writeAttribute ( XML . ATTRIBUTE_NO_RECOVERY , r . getValue ( XML . ATTRIBUTE_NO_RECOVERY , r . isNoRecovery ( ) . toString ( ) ) ) ; if ( r . getCredential ( ) != null ) { writer . writeStartElement ( XML . ELEMENT_RECOVERY_CREDENTIAL ) ; Credential c = ( Credential ) r . getCredential ( ) ; if ( c . getUserName ( ) != null ) { writer . writeStartElement ( XML . ELEMENT_USER_NAME ) ; writer . writeCharacters ( c . getValue ( XML . ELEMENT_USER_NAME , c . getUserName ( ) ) ) ; writer . writeEndElement ( ) ; writer . writeStartElement ( XML . ELEMENT_PASSWORD ) ; writer . writeCharacters ( c . getValue ( XML . ELEMENT_PASSWORD , c . getPassword ( ) ) ) ; writer . writeEndElement ( ) ; } else { writer . writeStartElement ( XML . ELEMENT_SECURITY_DOMAIN ) ; writer . writeCharacters ( c . getValue ( XML . ELEMENT_SECURITY_DOMAIN , c . getSecurityDomain ( ) ) ) ; writer . writeEndElement ( ) ; } writer . writeEndElement ( ) ; } if ( r . getPlugin ( ) != null ) { storeExtension ( r . getPlugin ( ) , writer , CommonXML . ELEMENT_RECOVERY_PLUGIN ) ; } writer . writeEndElement ( ) ; |
public class Requests { /** * Create a { @ link SubscribeRequest } with a list of { @ link SubscribeElement }
* instances .
* @ param list the list of { @ link SubscribeElement } instances that are added
* to the new { @ link SubscribeRequest } . The { @ link SubscribeElement } instances
* are either { @ link SubscribeUpdate } or { @ link SubscribeDelete } instances .
* @ return the new { @ link SubscribeRequest } */
public static SubscribeRequest createSubscribeReq ( List < SubscribeElement > list ) { } } | if ( list == null ) { throw new NullPointerException ( "list is not allowed to be null" ) ; } SubscribeRequest ret = createSubscribeReq ( ) ; for ( SubscribeElement el : list ) { ret . addSubscribeElement ( el ) ; } return ret ; |
public class InjectorBuilder { /** * Call the provided visitor for all elements of the current module .
* This call will not modify any bindings
* @ param visitor */
public < T > InjectorBuilder forEachElement ( ElementVisitor < T > visitor ) { } } | Elements . getElements ( module ) . forEach ( element -> element . acceptVisitor ( visitor ) ) ; return this ; |
public class StyleUtils { /** * Set the feature row style ( icon or style ) into the marker options
* @ param markerOptions marker options
* @ param featureStyleExtension feature style extension
* @ param featureRow feature row
* @ param density display density : { @ link android . util . DisplayMetrics # density }
* @ param iconCache icon cache
* @ return true if icon or style was set into the marker options */
public static boolean setFeatureStyle ( MarkerOptions markerOptions , FeatureStyleExtension featureStyleExtension , FeatureRow featureRow , float density , IconCache iconCache ) { } } | FeatureStyle featureStyle = featureStyleExtension . getFeatureStyle ( featureRow ) ; return setFeatureStyle ( markerOptions , featureStyle , density , iconCache ) ; |
public class MetadataManager { /** * Reads a row data from storage ( cache supported ) .
* @ param rowKey
* @ return */
private String getRow ( String rowKey ) { } } | try { return cache . get ( rowKey ) ; } catch ( Exception e ) { if ( e . getCause ( ) instanceof RowNotFoundException ) { return null ; } throw new RuntimeException ( e ) ; } |
public class PrcHasSeSellerSave { /** * < p > Process entity request . < / p >
* @ param pReqVars additional request scoped parameters
* @ param pRequestData Request Data
* @ param pEntity Entity to process
* @ return Entity processed for farther process or null
* @ throws Exception - an exception */
@ Override public final T process ( final Map < String , Object > pReqVars , final T pEntity , final IRequestData pRequestData ) throws Exception { } } | SeSeller ses = findSeSeller . find ( pReqVars , pRequestData . getUserName ( ) ) ; pEntity . setSeller ( ses ) ; if ( pEntity . getIsNew ( ) ) { this . srvOrm . insertEntity ( pReqVars , pEntity ) ; pEntity . setIsNew ( false ) ; } else { T entOld = this . srvOrm . retrieveEntity ( pReqVars , pEntity ) ; if ( ! entOld . getSeller ( ) . getItsId ( ) . getItsId ( ) . equals ( pEntity . getSeller ( ) . getItsId ( ) . getItsId ( ) ) ) { throw new ExceptionWithCode ( ExceptionWithCode . FORBIDDEN , "Attempt to update smb. else's entity: user/entity/EID/SEOLDID/SEID - " + pRequestData . getUserName ( ) + "/" + pEntity . getClass ( ) . getSimpleName ( ) + "/" + pEntity . getItsId ( ) + "/" + entOld . getSeller ( ) . getItsId ( ) . getItsId ( ) + "/" + pEntity . getSeller ( ) . getItsId ( ) . getItsId ( ) ) ; } this . srvOrm . updateEntity ( pReqVars , pEntity ) ; } return pEntity ; |
public class Revision { /** * Sets the timestamp information .
* The input is expected to be the wikipedia version of the timestamp as
* String ( YYYY - MM - DDThh - mm - ssZ ) . T and Z will be replaced with spaces .
* @ param timeStamp
* timestamp ( wikipedia version ) */
public void setTimeStamp ( final String timeStamp ) { } } | String time = timeStamp . replace ( 'T' , ' ' ) ; time = time . replace ( 'Z' , ' ' ) ; this . timeStamp = Timestamp . valueOf ( time ) ; |
public class MessageFormat { /** * Returns the applied pattern string .
* @ return the pattern string
* @ throws IllegalStateException after custom Format objects have been set
* via setFormat ( ) or similar APIs */
public String toPattern ( ) { } } | // Return the original , applied pattern string , or else " " .
// Note : This does not take into account
// - changes from setFormat ( ) and similar methods , or
// - normalization of apostrophes and arguments , for example ,
// whether some date / time / number formatter was created via a pattern
// but is equivalent to the " medium " default format .
if ( customFormatArgStarts != null ) { throw new IllegalStateException ( "toPattern() is not supported after custom Format objects " + "have been set via setFormat() or similar APIs" ) ; } if ( msgPattern == null ) { return "" ; } String originalPattern = msgPattern . getPatternString ( ) ; return originalPattern == null ? "" : originalPattern ; |
public class ClassReader { /** * Read module _ flags . */
Set < ModuleFlags > readModuleFlags ( int flags ) { } } | Set < ModuleFlags > set = EnumSet . noneOf ( ModuleFlags . class ) ; for ( ModuleFlags f : ModuleFlags . values ( ) ) { if ( ( flags & f . value ) != 0 ) set . add ( f ) ; } return set ; |
public class ActiveMqQueue { /** * Get the { @ link Session } dedicated for sending messages .
* @ return
* @ throws JMSException */
protected Session getProducerSession ( ) throws JMSException { } } | if ( producerSession == null ) { synchronized ( this ) { if ( producerSession == null ) { producerSession = createSession ( Session . AUTO_ACKNOWLEDGE ) ; } } } return producerSession ; |
public class Options { /** * Put an boolean value for the given option name .
* @ param key
* the option name .
* @ param value
* the boolean value . */
public Options putBoolean ( String key , IModel < Boolean > value ) { } } | putOption ( key , new BooleanOption ( value ) ) ; return this ; |
public class ZaurusConnectionDialog { /** * Method declaration
* @ param owner
* @ param title */
public static Connection createConnection ( Frame owner , String title , Insets defInsets ) { } } | ZaurusConnectionDialog dialog = new ZaurusConnectionDialog ( owner , title ) ; dialog . create ( defInsets ) ; return dialog . mConnection ; |
public class AmazonApiGatewayClient { /** * Deletes an existing < a > VpcLink < / a > of a specified identifier .
* @ param deleteVpcLinkRequest
* Deletes an existing < a > VpcLink < / a > of a specified identifier .
* @ return Result of the DeleteVpcLink operation returned by the service .
* @ throws UnauthorizedException
* The request is denied because the caller has insufficient permissions .
* @ throws NotFoundException
* The requested resource is not found . Make sure that the request URI is correct .
* @ throws TooManyRequestsException
* The request has reached its throttling limit . Retry after the specified time period .
* @ throws BadRequestException
* The submitted request is not valid , for example , the input is incomplete or incorrect . See the
* accompanying error message for details .
* @ sample AmazonApiGateway . DeleteVpcLink */
@ Override public DeleteVpcLinkResult deleteVpcLink ( DeleteVpcLinkRequest request ) { } } | request = beforeClientExecution ( request ) ; return executeDeleteVpcLink ( request ) ; |
public class UserHandlerImpl { /** * { @ inheritDoc } */
public boolean authenticate ( String username , String password ) throws Exception { } } | Session session = service . getStorageSession ( ) ; try { return authenticate ( session , username , password , null ) ; } finally { session . logout ( ) ; } |
public class TimeZone { /** * Returns a frozen ICU type TimeZone object given a time zone ID .
* @ param id the time zone ID
* @ param trySystem if true tries the system time zones first otherwise skip to the
* custom time zones .
* @ return the frozen ICU TimeZone or null if one could not be created . */
static BasicTimeZone getFrozenICUTimeZone ( String id , boolean trySystem ) { } } | BasicTimeZone result = null ; if ( trySystem ) { result = ZoneMeta . getSystemTimeZone ( id ) ; } if ( result == null ) { result = ZoneMeta . getCustomTimeZone ( id ) ; } return result ; |
public class FiredRuleCounter { /** * Results */
public int getRuleNameFireCount ( String ruleName ) { } } | Integer fireCount = ruleNameToFireCountMap . get ( ruleName ) ; return fireCount == null ? 0 : fireCount ; |
public class OSGiConfigUtils { /** * Get the filter string which will extract < appProperties > elements for the given application
* @ param applicationPid The pid of the application in the config
* @ return A filter string to be used by the OSGi ConfigurationAdmin service */
public static String getApplicationPropertiesConfigFilter ( String applicationPid ) { } } | String applicationConfigFilter = null ; StringBuilder applicationFilter = new StringBuilder ( 200 ) ; applicationFilter . append ( "(&" ) ; applicationFilter . append ( FilterUtils . createPropertyFilter ( CFG_SERVICE_FACTORY_PID , CFG_APP_PROPERTIES ) ) ; applicationFilter . append ( FilterUtils . createPropertyFilter ( CFG_CONFIG_PARENT_PID , applicationPid ) ) ; applicationFilter . append ( ')' ) ; applicationConfigFilter = applicationFilter . toString ( ) ; return applicationConfigFilter ; |
public class OptionalUtils { /** * Throws an { @ link IllegalArgumentException } if both passed { @ link Optional } s are present or neither is . */
public static void exactlyOnePresentOrIllegalArgument ( final Optional < ? > x , final Optional < ? > y , final String msg ) { } } | if ( x . isPresent ( ) == y . isPresent ( ) ) { throw new IllegalArgumentException ( msg ) ; } |
public class LolChat { /** * Get all your friends who are online .
* @ return A list of all your online Friends */
public List < Friend > getOnlineFriends ( ) { } } | return getFriends ( new Filter < Friend > ( ) { public boolean accept ( Friend friend ) { return friend . isOnline ( ) ; } } ) ; |
public class KinesisVideoStreamMarshaller { /** * Marshall the given parameter object . */
public void marshall ( KinesisVideoStream kinesisVideoStream , ProtocolMarshaller protocolMarshaller ) { } } | if ( kinesisVideoStream == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( kinesisVideoStream . getArn ( ) , ARN_BINDING ) ; } catch ( Exception e ) { throw new SdkClientException ( "Unable to marshall request to JSON: " + e . getMessage ( ) , e ) ; } |
public class BoxLegalHoldPolicy { /** * Retrieves a list of Legal Hold Policies that belong to your Enterprise as an Iterable .
* @ param api api the API connection to be used by the resource .
* @ param policyName case insensitive prefix - match filter on Policy name .
* @ param limit the limit of retrieved entries per page .
* @ param fields the optional fields to retrieve .
* @ return the Iterable of Legal Hold Policies in your Enterprise that match the filter parameters . */
public static Iterable < BoxLegalHoldPolicy . Info > getAll ( final BoxAPIConnection api , String policyName , int limit , String ... fields ) { } } | QueryStringBuilder builder = new QueryStringBuilder ( ) ; if ( policyName != null ) { builder . appendParam ( "policy_name" , policyName ) ; } if ( fields . length > 0 ) { builder . appendParam ( "fields" , fields ) ; } return new BoxResourceIterable < BoxLegalHoldPolicy . Info > ( api , ALL_LEGAL_HOLD_URL_TEMPLATE . buildWithQuery ( api . getBaseURL ( ) , builder . toString ( ) ) , limit ) { @ Override protected BoxLegalHoldPolicy . Info factory ( JsonObject jsonObject ) { BoxLegalHoldPolicy policy = new BoxLegalHoldPolicy ( api , jsonObject . get ( "id" ) . asString ( ) ) ; return policy . new Info ( jsonObject ) ; } } ; |
public class FoldableItemLayout { /** * Translation preserving middle line splitting . */
public void setRollingDistance ( float distance ) { } } | final float scaleY = scale * scaleFactor * scaleFactorY ; topPart . applyRollingDistance ( distance , scaleY ) ; bottomPart . applyRollingDistance ( distance , scaleY ) ; |
public class GenericUrl { /** * Returns the URI for the given encoded URL .
* < p > Any { @ link MalformedURLException } is wrapped in an { @ link IllegalArgumentException } .
* @ param encodedUrl encoded URL
* @ return URL */
private static URL parseURL ( String encodedUrl ) { } } | try { return new URL ( encodedUrl ) ; } catch ( MalformedURLException e ) { throw new IllegalArgumentException ( e ) ; } |
public class PersistUtils { /** * DBOpenHelper */
public static boolean executeStatements ( final SQLiteDatabase db , final ArrayList < String > statements ) throws Exception { } } | Callable < Boolean > task = new Callable < Boolean > ( ) { @ Override public Boolean call ( ) throws Exception { for ( String statement : statements ) { L . i ( statement ) ; db . execSQL ( statement ) ; } return Boolean . TRUE ; } } ; Boolean result = executeInTransaction ( db , task ) ; return ( result != null ) ; |
public class FraggleManager { /** * Processes the custom animations element , adding them as required
* @ param animation Animation object to process
* @ param ft Fragment transaction to add to the transition */
protected void processAnimations ( FragmentAnimation animation , FragmentTransaction ft ) { } } | if ( animation != null ) { if ( animation . isCompletedAnimation ( ) ) { ft . setCustomAnimations ( animation . getEnterAnim ( ) , animation . getExitAnim ( ) , animation . getPushInAnim ( ) , animation . getPopOutAnim ( ) ) ; } else { ft . setCustomAnimations ( animation . getEnterAnim ( ) , animation . getExitAnim ( ) ) ; } if ( Build . VERSION . SDK_INT >= Build . VERSION_CODES . LOLLIPOP ) for ( LollipopAnim sharedElement : animation . getSharedViews ( ) ) { ft . addSharedElement ( sharedElement . view , sharedElement . name ) ; } } |
public class SyncProcessEvent { /** * get worker heartbeat by workerId
* @ param conf conf
* @ param workerId worker id
* @ return WorkerHeartbeat */
public WorkerHeartbeat readWorkerHeartbeat ( Map conf , String workerId ) throws Exception { } } | try { LocalState ls = StormConfig . worker_state ( conf , workerId ) ; return ( WorkerHeartbeat ) ls . get ( Common . LS_WORKER_HEARTBEAT ) ; } catch ( Exception e ) { LOG . error ( "Failed to get heartbeat for worker:{}" , workerId , e ) ; return null ; } |
public class Image { /** * Draw this image at the specified location
* @ param x The x location to draw the image at
* @ param y The y location to draw the image at */
@ Override public void draw ( float x , float y ) { } } | init ( ) ; draw ( x , y , width , height ) ; |
public class QueuedKeyedResourcePool { /** * A safe wrapper to destroy the given resource request . */
protected void destroyRequest ( AsyncResourceRequest < V > resourceRequest ) { } } | if ( resourceRequest != null ) { try { // To hand control back to the owner of the
// AsyncResourceRequest , treat " destroy " as an exception since
// there is no resource to pass into useResource , and the
// timeout has not expired .
Exception e = new UnreachableStoreException ( "Client request was terminated while waiting in the queue." ) ; resourceRequest . handleException ( e ) ; } catch ( Exception ex ) { logger . error ( "Exception while destroying resource request:" , ex ) ; } } |
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } { @ link Boolean } { @ code > } */
@ XmlElementDecl ( namespace = "http://docs.oasis-open.org/ns/cmis/messaging/200908/" , name = "includePolicyIds" , scope = GetObject . class ) public JAXBElement < Boolean > createGetObjectIncludePolicyIds ( Boolean value ) { } } | return new JAXBElement < Boolean > ( _GetObjectOfLatestVersionIncludePolicyIds_QNAME , Boolean . class , GetObject . class , value ) ; |
public class MethodDescriptor { /** * Extract the fully qualified service name out of a fully qualified method name . May return
* { @ code null } if the input is malformed , but you cannot rely on it for the validity of the
* input .
* @ since 1.0.0 */
@ Nullable public static String extractFullServiceName ( String fullMethodName ) { } } | int index = checkNotNull ( fullMethodName , "fullMethodName" ) . lastIndexOf ( '/' ) ; if ( index == - 1 ) { return null ; } return fullMethodName . substring ( 0 , index ) ; |
public class Ifc2x3tc1PackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public EClass getIfcCoveringType ( ) { } } | if ( ifcCoveringTypeEClass == null ) { ifcCoveringTypeEClass = ( EClass ) EPackage . Registry . INSTANCE . getEPackage ( Ifc2x3tc1Package . eNS_URI ) . getEClassifiers ( ) . get ( 126 ) ; } return ifcCoveringTypeEClass ; |
public class CmsObject { /** * Copies a resource . < p >
* The copied resource will always be locked to the current user
* after the copy operation . < p >
* The < code > siblingMode < / code > parameter controls how to handle siblings
* during the copy operation . < br >
* Possible values for this parameter are : < br >
* < ul >
* < li > < code > { @ link CmsResource # COPY _ AS _ NEW } < / code > < / li >
* < li > < code > { @ link CmsResource # COPY _ AS _ SIBLING } < / code > < / li >
* < li > < code > { @ link CmsResource # COPY _ PRESERVE _ SIBLING } < / code > < / li >
* < / ul > < p >
* @ param source the name of the resource to copy ( full current site relative path )
* @ param destination the name of the copy destination ( full current site relative path )
* @ param siblingMode indicates how to handle siblings during copy
* @ throws CmsException if something goes wrong
* @ throws CmsIllegalArgumentException if the < code > destination < / code > argument is null or of length 0 */
public void copyResource ( String source , String destination , CmsResource . CmsResourceCopyMode siblingMode ) throws CmsException , CmsIllegalArgumentException { } } | CmsResource resource = readResource ( source , CmsResourceFilter . IGNORE_EXPIRATION ) ; getResourceType ( resource ) . copyResource ( this , m_securityManager , resource , destination , siblingMode ) ; |
public class ContentElement { /** * Flush the rows from the last position to the current position
* @ param util the XML util
* @ param writer the destination
* @ param settingsElement the settings . xml representation
* @ throws IOException if the rows were not flushed */
public void flushRows ( final XMLUtil util , final ZipUTF8Writer writer , final SettingsElement settingsElement ) throws IOException { } } | this . ensureContentBegin ( util , writer ) ; final int lastTableIndex = this . tables . size ( ) - 1 ; if ( lastTableIndex == - 1 ) return ; int tableIndex = this . flushPosition . getTableIndex ( ) ; Table table = this . tables . get ( tableIndex ) ; if ( tableIndex < lastTableIndex ) { table . flushRemainingRowsFrom ( util , writer , this . flushPosition . getLastRowIndex ( ) + 1 ) ; settingsElement . addTableConfig ( table . getConfigEntry ( ) ) ; tableIndex ++ ; while ( tableIndex < lastTableIndex ) { table = this . tables . get ( tableIndex ) ; table . appendXMLToContentEntry ( util , writer ) ; settingsElement . addTableConfig ( table . getConfigEntry ( ) ) ; tableIndex ++ ; } table = this . tables . get ( lastTableIndex ) ; table . flushAllAvailableRows ( util , writer ) ; } else { table . flushSomeAvailableRowsFrom ( util , writer , this . flushPosition . getLastRowIndex ( ) + 1 ) ; } this . flushPosition . set ( lastTableIndex , this . tables . get ( lastTableIndex ) . getLastRowNumber ( ) ) ; |
public class VertxCompletableFuture { /** * Returns a new CompletableFuture that is asynchronously completed by a action running in the provided
* Vert . x worker thread pool .
* This method is different from { @ link CompletableFuture # runAsync ( Runnable ) } as it does not use a fork join
* executor , but the worker thread pool .
* @ param vertx the Vert . x instance
* @ param worker the WorkerExecution on which the runnable is to be executed
* @ param runnable the action , when its execution completes , it completes the returned CompletableFuture . If the
* execution throws an exception , the returned CompletableFuture is completed exceptionally .
* @ return the new CompletableFuture */
public static VertxCompletableFuture < Void > runBlockingAsyncOn ( Vertx vertx , WorkerExecutor worker , Runnable runnable ) { } } | return runBlockingAsyncOn ( Objects . requireNonNull ( vertx ) . getOrCreateContext ( ) , worker , runnable ) ; |
public class CmsTemplateMapperConfiguration { /** * Gets the mapped formatter configuration structure id string for another formatter configuration structure id string . < p >
* @ param id the structure id of a formatter configuration as a string
* @ return the mapped formatter configuration structure id of a string */
public String getMappedFormatterConfiguration ( String id ) { } } | CmsUUID resultId = m_formatterConfigMap . get ( new CmsUUID ( id ) ) ; if ( resultId == null ) { return null ; } return resultId . toString ( ) ; |
public class Server { /** * Uses autogenerated selfsigned certificate . */
public Server jdkSsl ( ) throws SSLException , CertificateException { } } | SelfSignedCertificate cert = new SelfSignedCertificate ( ) ; sslContext = SslContextBuilder . forServer ( cert . certificate ( ) , cert . privateKey ( ) ) . sslProvider ( SslProvider . JDK ) . build ( ) ; return this ; |
public class InstanceImpl { /** * Class index .
* @ return the int */
@ Override public int classIndex ( ) { } } | int classIndex = instanceHeader . classIndex ( ) ; // return ? classIndex : 0;
if ( classIndex == Integer . MAX_VALUE ) if ( this . instanceHeader . instanceInformation . range != null ) classIndex = instanceHeader . instanceInformation . range . getStart ( ) ; else classIndex = 0 ; return classIndex ; |
public class BaseXmlTrxMessageIn { /** * Get the unmarshaller .
* @ return */
public BaseConvertToMessage getConvertToMessage ( ) { } } | if ( m_convertToMessage == null ) { BaseMessageHeader trxMessageHeader = this . getMessage ( ) . getMessageHeader ( ) ; String strMessageClass = ( String ) trxMessageHeader . get ( TrxMessageHeader . MESSAGE_MARSHALLER_CLASS ) ; String strPackage = ( String ) trxMessageHeader . get ( TrxMessageHeader . BASE_PACKAGE ) ; strMessageClass = ClassServiceUtility . getFullClassName ( strPackage , strMessageClass ) ; m_convertToMessage = ( BaseConvertToMessage ) ClassServiceUtility . getClassService ( ) . makeObjectFromClassName ( strMessageClass ) ; if ( m_convertToMessage != null ) m_convertToMessage . init ( this ) ; } return m_convertToMessage ; |
public class StreamPersistedValueData { /** * { @ inheritDoc } */
public PersistedValueData createPersistedCopy ( int orderNumber ) throws IOException { } } | if ( url != null ) return new StreamPersistedValueData ( orderNumber , url , tempFile , spoolConfig ) ; return super . createPersistedCopy ( orderNumber ) ; |
public class HttpClientResourceAdaptor { /** * ( non - Javadoc )
* @ see
* javax . slee . resource . ResourceAdaptor # eventUnreferenced ( javax . slee . resource
* . ActivityHandle , javax . slee . resource . FireableEventType , java . lang . Object ,
* javax . slee . Address , javax . slee . resource . ReceivableService , int ) */
public void eventUnreferenced ( ActivityHandle arg0 , FireableEventType arg1 , Object arg2 , Address arg3 , ReceivableService arg4 , int arg5 ) { } } | if ( tracer . isFineEnabled ( ) ) { tracer . fine ( String . format ( "Event=%s unreferenced" , arg2 ) ) ; } if ( arg2 instanceof ResponseEvent ) { ResponseEvent event = ( ResponseEvent ) arg2 ; HttpResponse response = event . getHttpResponse ( ) ; // May be this event is carrying Exception and not actual Response
// in which case
// skip housekeeping
if ( response != null ) { try { EntityUtils . consume ( response . getEntity ( ) ) ; } catch ( IOException e ) { this . tracer . severe ( "Exception while housekeeping. Event unreferenced" , e ) ; } } } |
public class InternalWikiScannerContext { /** * Waiting for following events to know if the macro is inline or not . */
public void onMacro ( String name , WikiParameters params , String content ) { } } | checkBlockContainer ( ) ; fMacroName = name ; fMacroParameters = params ; fMacroContent = content ; |
public class Preconditions { /** * A { @ code double } specialized version of { @ link # checkPreconditions ( Object ,
* ContractConditionType [ ] ) }
* @ param value The value
* @ param conditions The conditions the value must obey
* @ return value
* @ throws PreconditionViolationException If any of the conditions are false */
public static double checkPreconditionsD ( final double value , final ContractDoubleConditionType ... conditions ) throws PreconditionViolationException { } } | final Violations violations = innerCheckAllDouble ( value , conditions ) ; if ( violations != null ) { throw new PreconditionViolationException ( failedMessage ( Double . valueOf ( value ) , violations ) , null , violations . count ( ) ) ; } return value ; |
public class FlowController { /** * Return the user ' s currently selected Locale .
* @ param request the current request .
* @ return the user ' s currently selected Locale , stored in the session .
* @ deprecated Use { @ link # getLocale } or { @ link # retrieveUserLocale } . */
protected Locale getLocale ( HttpServletRequest request ) { } } | HttpSession session = request . getSession ( ) ; Locale locale = ( Locale ) session . getAttribute ( Globals . LOCALE_KEY ) ; return locale != null ? locale : DEFAULT_LOCALE ; |
public class AssociateTeamMemberRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( AssociateTeamMemberRequest associateTeamMemberRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( associateTeamMemberRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( associateTeamMemberRequest . getProjectId ( ) , PROJECTID_BINDING ) ; protocolMarshaller . marshall ( associateTeamMemberRequest . getClientRequestToken ( ) , CLIENTREQUESTTOKEN_BINDING ) ; protocolMarshaller . marshall ( associateTeamMemberRequest . getUserArn ( ) , USERARN_BINDING ) ; protocolMarshaller . marshall ( associateTeamMemberRequest . getProjectRole ( ) , PROJECTROLE_BINDING ) ; protocolMarshaller . marshall ( associateTeamMemberRequest . getRemoteAccessAllowed ( ) , REMOTEACCESSALLOWED_BINDING ) ; } catch ( Exception e ) { throw new SdkClientException ( "Unable to marshall request to JSON: " + e . getMessage ( ) , e ) ; } |
public class BatchGetItemResult { /** * Table names and the respective item attributes from the tables .
* Returns a reference to this object so that method calls can be chained together .
* @ param responses Table names and the respective item attributes from the tables .
* @ return A reference to this updated object so that method calls can be chained
* together . */
public BatchGetItemResult withResponses ( java . util . Map < String , BatchResponse > responses ) { } } | setResponses ( responses ) ; return this ; |
public class PdfUtilities { /** * Converts PDF to TIFF format .
* @ param inputPdfFile input file
* @ return a multi - page TIFF image
* @ throws IOException */
public static File convertPdf2Tiff ( File inputPdfFile ) throws IOException { } } | if ( PDFBOX . equals ( System . getProperty ( PDF_LIBRARY ) ) ) { return PdfBoxUtilities . convertPdf2Tiff ( inputPdfFile ) ; } else { try { return PdfGsUtilities . convertPdf2Tiff ( inputPdfFile ) ; } catch ( Exception e ) { System . setProperty ( PDF_LIBRARY , PDFBOX ) ; return convertPdf2Tiff ( inputPdfFile ) ; } } |
public class Ifc4PackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public EClass getIfcSpecularHighlightSelect ( ) { } } | if ( ifcSpecularHighlightSelectEClass == null ) { ifcSpecularHighlightSelectEClass = ( EClass ) EPackage . Registry . INSTANCE . getEPackage ( Ifc4Package . eNS_URI ) . getEClassifiers ( ) . get ( 1162 ) ; } return ifcSpecularHighlightSelectEClass ; |
public class CommitsApi { /** * Get the comments of a commit in a project .
* < pre > < code > GitLab Endpoint : GET / projects / : id / repository / commits / : sha / comments < / code > < / pre >
* @ param projectIdOrPath the project in the form of an Integer ( ID ) , String ( path ) , or Project instance
* @ param sha a commit hash or name of a branch or tag
* @ return a List of Comment instances for the specified project ID / sha pair
* @ throws GitLabApiException GitLabApiException if any exception occurs during execution */
public List < Comment > getComments ( Object projectIdOrPath , String sha ) throws GitLabApiException { } } | return ( getComments ( projectIdOrPath , sha , getDefaultPerPage ( ) ) . all ( ) ) ; |
public class CollisionConfig { /** * Create an collision from its node .
* @ param node The collision node ( must not be < code > null < / code > ) .
* @ return The collision instance .
* @ throws LionEngineException If error when reading collision data . */
public static Collision createCollision ( XmlReader node ) { } } | Check . notNull ( node ) ; final String name = node . readString ( ATT_NAME ) ; final int offsetX = node . readInteger ( ATT_OFFSETX ) ; final int offsetY = node . readInteger ( ATT_OFFSETY ) ; final int width = node . readInteger ( ATT_WIDTH ) ; final int height = node . readInteger ( ATT_HEIGHT ) ; final boolean mirror = node . readBoolean ( ATT_MIRROR ) ; return new Collision ( name , offsetX , offsetY , width , height , mirror ) ; |
public class AttachmentVersioningResourcesImpl { /** * Get all versions of an attachment .
* It mirrors to the following Smartsheet REST API method : GET / sheets / { sheetId } / attachments / { attachmentId } / versions
* @ param sheetId the id
* @ param attachmentId the attachment id
* @ param parameters the pagination paramaters
* @ return the attachment ( note that if there is no such resource , this method will throw ResourceNotFoundException
* rather than returning null ) .
* @ throws IllegalArgumentException if any argument is null or empty string
* @ throws InvalidRequestException if there is any problem with the REST API request
* @ throws AuthorizationException if there is any problem with the REST API authorization ( access token )
* @ throws ResourceNotFoundException if the resource cannot be found
* @ throws ServiceUnavailableException if the REST API service is not available ( possibly due to rate limiting )
* @ throws SmartsheetException if there is any other error during the operation */
public PagedResult < Attachment > listAllVersions ( long sheetId , long attachmentId , PaginationParameters parameters ) throws SmartsheetException { } } | String path = "sheets/" + sheetId + "/attachments/" + attachmentId + "/versions" ; if ( parameters != null ) { path += parameters . toQueryString ( ) ; } return this . listResourcesWithWrapper ( path , Attachment . class ) ; |
public class ImmutableRoaringBitmap { /** * Bitwise ANDNOT ( difference ) operation for the given range , rangeStart ( inclusive ) and rangeEnd
* ( exclusive ) . The provided bitmaps are * not * modified . This operation is thread - safe as long as
* the provided bitmaps remain unchanged .
* @ param x1 first bitmap
* @ param x2 other bitmap
* @ param rangeStart beginning of the range ( inclusive )
* @ param rangeEnd end of range ( exclusive )
* @ return result of the operation */
public static MutableRoaringBitmap andNot ( final ImmutableRoaringBitmap x1 , final ImmutableRoaringBitmap x2 , long rangeStart , long rangeEnd ) { } } | MutableRoaringBitmap . rangeSanityCheck ( rangeStart , rangeEnd ) ; MutableRoaringBitmap rb1 = selectRangeWithoutCopy ( x1 , rangeStart , rangeEnd ) ; MutableRoaringBitmap rb2 = selectRangeWithoutCopy ( x2 , rangeStart , rangeEnd ) ; return andNot ( rb1 , rb2 ) ; |
public class LongMultiset { /** * Remove the specified occurrences from the specified elements .
* The elements will be removed from this set if the occurrences equals to or less than 0 after the operation .
* @ param c
* @ param occurrences
* the occurrences to remove if the element is in the specified collection < code > c < / code > .
* @ return < tt > true < / tt > if this set changed as a result of the call */
public boolean removeAll ( final Collection < ? > c , final long occurrences ) { } } | checkOccurrences ( occurrences ) ; if ( N . isNullOrEmpty ( c ) || occurrences == 0 ) { return false ; } boolean result = false ; for ( Object e : c ) { if ( result == false ) { result = remove ( e , occurrences ) ; } else { remove ( e , occurrences ) ; } } return result ; |
public class ListPullRequestsRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( ListPullRequestsRequest listPullRequestsRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( listPullRequestsRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( listPullRequestsRequest . getRepositoryName ( ) , REPOSITORYNAME_BINDING ) ; protocolMarshaller . marshall ( listPullRequestsRequest . getAuthorArn ( ) , AUTHORARN_BINDING ) ; protocolMarshaller . marshall ( listPullRequestsRequest . getPullRequestStatus ( ) , PULLREQUESTSTATUS_BINDING ) ; protocolMarshaller . marshall ( listPullRequestsRequest . getNextToken ( ) , NEXTTOKEN_BINDING ) ; protocolMarshaller . marshall ( listPullRequestsRequest . getMaxResults ( ) , MAXRESULTS_BINDING ) ; } catch ( Exception e ) { throw new SdkClientException ( "Unable to marshall request to JSON: " + e . getMessage ( ) , e ) ; } |
public class ObjectMapper { /** * Creates a SQL query string to get objects for this ObjectMapper . */
public String buildSQL ( ) { } } | mTables = new Hashtable ( ) ; mColumns = new Vector ( ) ; String key = null ; for ( Enumeration keys = mPropertiesMap . keys ( ) ; keys . hasMoreElements ( ) ; ) { key = ( String ) keys . nextElement ( ) ; // Get columns to select
String column = ( String ) mPropertiesMap . get ( key ) ; mColumns . addElement ( column ) ; tableJoins ( column , false ) ; } // All data read , build SQL query string
return buildSelectClause ( ) + buildFromClause ( ) + buildWhereClause ( ) ; |
public class StringParser { /** * Parse the given { @ link String } as boolean value . All values that are equal
* to " true " ( ignoring case ) will result in < code > true < / code > return values .
* All values that are equal to " false " ( ignoring case ) will result in
* < code > false < / code > return values . All other values will return the default .
* @ param sStr
* The string to be interpreted . May be < code > null < / code > .
* @ param bDefault
* The default value to be returned if the passed string is neither
* " true " nor " false " .
* @ return < code > true < / code > or < code > false < / code > : ) */
public static boolean parseBool ( @ Nullable final String sStr , final boolean bDefault ) { } } | // Do we need to start thinking at all ?
if ( sStr != null && sStr . length ( ) > 0 ) { // Is it true ?
if ( sStr . equalsIgnoreCase ( "true" ) ) return true ; // Is it false ?
if ( sStr . equalsIgnoreCase ( "false" ) ) return false ; } // Neither true nor false
return bDefault ; |
public class Utilities { /** * Samples a set of m integers without replacement from the range [ 0 , . . . , n - 1 ] .
* @ param m The number of integers to return .
* @ param n The number of integers from which to sample .
* @ return The sample as an unsorted integer array . */
public static int [ ] sampleWithoutReplacement ( int m , int n ) { } } | // This implements a modified form of the genshuf ( ) function from
// Programming Pearls pg . 129.
// TODO : Design a faster method that only generates min ( m , n - m ) integers .
int [ ] array = getIndexArray ( n ) ; for ( int i = 0 ; i < m ; i ++ ) { int j = Prng . nextInt ( n - i ) + i ; // Swap array [ i ] and array [ j ]
int tmp = array [ i ] ; array [ i ] = array [ j ] ; array [ j ] = tmp ; } return Arrays . copyOf ( array , m ) ; |
public class ZealotKhala { /** * 生成 " IS NOT NULL " 的SQL片段 .
* < p > 示例 : 传入 { " a . name " } 参数 , 生成的SQL片段为 : " a . name IS NOT NULL " < / p >
* @ param field 数据库字段
* @ return ZealotKhala实例 */
public ZealotKhala isNotNull ( String field ) { } } | return this . doIsNull ( ZealotConst . ONE_SPACE , field , true , false ) ; |
public class DoradusClient { /** * Convenient method to lookup storageService of the application
* @ param restClient
* @ param applicationName
* @ return storage service name */
private static String lookupStorageServiceByApp ( RESTClient restClient , String applicationName ) { } } | Utils . require ( applicationName != null , "Missing application name" ) ; if ( applicationName != null ) { ApplicationDefinition appDef = Command . getAppDef ( restClient , applicationName ) ; Utils . require ( appDef != null , "Unknown application: %s" , applicationName ) ; return appDef . getStorageService ( ) ; } return null ; |
public class MethodCompiler { /** * Set field in this class
* < p > Stack : . . . , value = & gt ; . . .
* @ param name
* @ throws IOException */
public void putField ( String name ) throws IOException { } } | VariableElement field = El . getField ( subClass , name ) ; if ( field == null ) { throw new IllegalArgumentException ( "field " + name + " not found" ) ; } putField ( field ) ; |
public class DayOpeningHours { /** * Determines of the hours of both days overlap . The day is ignored for this comparison .
* @ param other
* Other day to compare the hours with .
* @ return { @ literal true } if at least one minute is the same for both days . */
public final boolean overlaps ( @ NotNull final DayOpeningHours other ) { } } | Contract . requireArgNotNull ( "other" , other ) ; return hourRanges . overlaps ( other . hourRanges ) ; |
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } { @ link SecondDefiningParameterType } { @ code > }
* @ param value
* Java instance representing xml element ' s value .
* @ return
* the new instance of { @ link JAXBElement } { @ code < } { @ link SecondDefiningParameterType } { @ code > } */
@ XmlElementDecl ( namespace = "http://www.opengis.net/gml" , name = "secondDefiningParameter" ) public JAXBElement < SecondDefiningParameterType > createSecondDefiningParameter ( SecondDefiningParameterType value ) { } } | return new JAXBElement < SecondDefiningParameterType > ( _SecondDefiningParameter_QNAME , SecondDefiningParameterType . class , null , value ) ; |
public class FessMessages { /** * Add the created action message for the key ' success . upload _ mapping _ file ' with parameters .
* < pre >
* message : Uploaded Mapping file .
* < / pre >
* @ param property The property name for the message . ( NotNull )
* @ return this . ( NotNull ) */
public FessMessages addSuccessUploadMappingFile ( String property ) { } } | assertPropertyNotNull ( property ) ; add ( property , new UserMessage ( SUCCESS_upload_mapping_file ) ) ; return this ; |
public class WsByteBufferUtils { /** * Convert a list of buffers to an int using the starting positions and ending
* limits .
* @ param list
* @ param positions
* @ param limits
* @ return int */
public static final int asInt ( WsByteBuffer [ ] list , int [ ] positions , int [ ] limits ) { } } | return asInt ( asByteArray ( list , positions , limits ) ) ; |
public class DescribeGlobalTableSettingsResult { /** * The region specific settings for the global table .
* @ param replicaSettings
* The region specific settings for the global table . */
public void setReplicaSettings ( java . util . Collection < ReplicaSettingsDescription > replicaSettings ) { } } | if ( replicaSettings == null ) { this . replicaSettings = null ; return ; } this . replicaSettings = new java . util . ArrayList < ReplicaSettingsDescription > ( replicaSettings ) ; |
public class RetryPolicy { /** * Execute the given { @ link GenomicsRequest } and return the response .
* This method begins by creating an { @ code RetryPolicy . Instance } and then attempts to execute the
* request by invoking { @ link GenomicsRequest # execute } . If the request fails with an
* { @ link IOException } , the { @ link RetryPolicy . Instance # shouldRetry } method is consulted to
* determine if the request should be retried .
* @ param request The { @ code GenomicsRequest } to execute .
* @ return The response from executing the request .
* @ throws IOException if executing the request fails and { @ code this } RetryPolicy decides not to
* retry the request . */
public final < C extends GenomicsRequest < D > , D > D execute ( C request ) throws IOException { } } | for ( Instance instance = createInstance ( ) ; true ; ) { try { return request . execute ( ) ; } catch ( IOException e ) { if ( ! instance . shouldRetry ( request , e ) ) { throw e ; } } } |
public class AfplibPackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public EEnum getObjectAreaSizeSizeType ( ) { } } | if ( objectAreaSizeSizeTypeEEnum == null ) { objectAreaSizeSizeTypeEEnum = ( EEnum ) EPackage . Registry . INSTANCE . getEPackage ( AfplibPackage . eNS_URI ) . getEClassifiers ( ) . get ( 99 ) ; } return objectAreaSizeSizeTypeEEnum ; |
public class ArrayOfDoublesSketch { /** * Heapify the given Memory and seed as a ArrayOfDoublesSketch
* @ param mem the given Memory
* @ param seed the given seed
* @ return an ArrayOfDoublesSketch */
public static ArrayOfDoublesSketch heapify ( final Memory mem , final long seed ) { } } | final SerializerDeserializer . SketchType sketchType = SerializerDeserializer . getSketchType ( mem ) ; if ( sketchType == SerializerDeserializer . SketchType . ArrayOfDoublesQuickSelectSketch ) { return new HeapArrayOfDoublesQuickSelectSketch ( mem , seed ) ; } return new HeapArrayOfDoublesCompactSketch ( mem , seed ) ; |
public class FileDescriptorEx { /** * very consuming and problematic ! */
private boolean isCanonical ( final FileDescriptor file ) { } } | final FileDescriptorProto proto = file . toProto ( ) ; if ( proto . hasOptions ( ) && proto . getOptions ( ) . getUninterpretedOptionCount ( ) > 0 ) { return false ; } for ( final FieldDescriptorProto field : proto . getExtensionList ( ) ) { if ( ! isFieldCanonical ( field ) ) { return false ; } } for ( final ServiceDescriptorProto serviceProto : proto . getServiceList ( ) ) { if ( ! isCanonical ( serviceProto ) ) { return false ; } } for ( final EnumDescriptorProto enumProto : proto . getEnumTypeList ( ) ) { if ( ! isCanonical ( enumProto ) ) { return false ; } } for ( final DescriptorProto message : proto . getMessageTypeList ( ) ) { if ( ! isMessageRefsCanonical ( message ) ) { return false ; } } return true ; |
public class CombinedDownloadTask { /** * Creates a CombinedDownloadTask from a DownloadTask .
* @ param task the download task
* @ param < T > the type of the DownloadTask
* @ return the CombinedDownloadTask
* @ throws NullPointerException if < code > task = = null < / code > */
public static < T > CombinedDownloadTask < T > single ( DownloadTask < T > task ) { } } | Objects . requireNonNull ( task ) ; return new SingleCombinedTask < T > ( task ) ; |
public class ProgressiveRendering { /** * Copies important fields from the current HTTP request and makes them available during { @ link # compute } .
* This is necessary because some model methods such as { @ link AbstractItem # getUrl } behave differently when called from a request . */
@ java . lang . SuppressWarnings ( { } } | "rawtypes" , "unchecked" } ) // public RequestImpl ctor requires List < AncestorImpl > yet AncestorImpl is not public ! API design flaw
private static RequestImpl createMockRequest ( ) { RequestImpl currentRequest = ( RequestImpl ) Stapler . getCurrentRequest ( ) ; HttpServletRequest original = ( HttpServletRequest ) currentRequest . getRequest ( ) ; final Map < String , Object > getters = new HashMap < > ( ) ; for ( Method method : HttpServletRequest . class . getMethods ( ) ) { String m = method . getName ( ) ; if ( ( m . startsWith ( "get" ) || m . startsWith ( "is" ) ) && method . getParameterTypes ( ) . length == 0 ) { Class < ? > type = method . getReturnType ( ) ; // TODO could add other types which are known to be safe to copy : Cookie [ ] , Principal , HttpSession , etc .
if ( type . isPrimitive ( ) || type == String . class || type == Locale . class ) { try { getters . put ( m , method . invoke ( original ) ) ; } catch ( Exception x ) { LOG . log ( Level . WARNING , "cannot mock Stapler request " + method , x ) ; } } } } List /* < AncestorImpl > */
ancestors = currentRequest . ancestors ; LOG . log ( Level . FINER , "mocking ancestors {0} using {1}" , new Object [ ] { ancestors , getters } ) ; TokenList tokens = currentRequest . tokens ; return new RequestImpl ( Stapler . getCurrent ( ) , ( HttpServletRequest ) Proxy . newProxyInstance ( ProgressiveRendering . class . getClassLoader ( ) , new Class < ? > [ ] { HttpServletRequest . class } , new InvocationHandler ( ) { @ Override public Object invoke ( Object proxy , Method method , Object [ ] args ) throws Throwable { String m = method . getName ( ) ; if ( getters . containsKey ( m ) ) { return getters . get ( m ) ; } else { // TODO implement other methods as needed
throw new UnsupportedOperationException ( m ) ; } } } ) , ancestors , tokens ) ; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.