signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class HyperionClient { /** * Build the URL for the specified request
* @ param request the data service request
* @ return The URL string */
protected String buildUrl ( Request request ) { } } | StringBuilder sb = new StringBuilder ( 512 ) ; sb . append ( baseUrl ) . append ( request . getEntityName ( ) ) . append ( "/" ) ; if ( request . getPath ( ) != null ) sb . append ( request . getPath ( ) ) ; String queryString = buildQueryString ( request ) ; if ( queryString . length ( ) > 0 ) { sb . append ( "?" ) . ... |
public class AttackProperty { /** * The array of < a > Contributor < / a > objects that includes the top five contributors to an attack .
* @ param topContributors
* The array of < a > Contributor < / a > objects that includes the top five contributors to an attack . */
public void setTopContributors ( java . util ... | if ( topContributors == null ) { this . topContributors = null ; return ; } this . topContributors = new java . util . ArrayList < Contributor > ( topContributors ) ; |
public class CountMap { /** * Get the count for the specified key . If the key is not present , 0 is returned . */
public int getCount ( K key ) { } } | CountEntry < K > entry = _backing . get ( key ) ; return ( entry == null ) ? 0 : entry . count ; |
public class Coordination { /** * setter for elliptical - sets
* @ generated
* @ param v value to set into the feature */
public void setElliptical ( boolean v ) { } } | if ( Coordination_Type . featOkTst && ( ( Coordination_Type ) jcasType ) . casFeat_elliptical == null ) jcasType . jcas . throwFeatMissing ( "elliptical" , "de.julielab.jules.types.Coordination" ) ; jcasType . ll_cas . ll_setBooleanValue ( addr , ( ( Coordination_Type ) jcasType ) . casFeatCode_elliptical , v ) ; |
public class JDBC4ClientConnection { /** * Used by the pool to indicate a thread / user has stopped using the connection ( and optionally
* close the underlying client if there are no more users against it ) . */
protected synchronized void dispose ( ) { } } | this . users -- ; if ( this . users == 0 ) { try { Client currentClient = this . client . get ( ) ; if ( currentClient != null ) { currentClient . close ( ) ; } } catch ( Exception x ) { // ignore
} } |
public class MapIndexConfig { /** * Validates index attribute content .
* @ param attribute attribute to validate
* @ return the attribute for fluent assignment */
public static String validateIndexAttribute ( String attribute ) { } } | checkHasText ( attribute , "Map index attribute must contain text" ) ; String keyPrefix = KEY_ATTRIBUTE_NAME . value ( ) ; if ( attribute . startsWith ( keyPrefix ) && attribute . length ( ) > keyPrefix . length ( ) ) { if ( attribute . charAt ( keyPrefix . length ( ) ) != '#' ) { LOG . warning ( KEY_ATTRIBUTE_NAME . v... |
public class PatternToken { /** * Checks whether an exception for a previous token matches ( in case the exception had scope = =
* " previous " ) .
* @ param token { @ link AnalyzedToken } to check matching against .
* @ return True if any of the exceptions matches . */
public boolean isMatchedByPreviousException... | if ( exceptionValidPrevious ) { for ( PatternToken testException : previousExceptionList ) { if ( ! testException . exceptionValidNext ) { if ( testException . isMatched ( token ) ) { return true ; } } } } return false ; |
public class HttpSender { /** * Sets the maximum number of redirects that will be followed before failing with an exception .
* The default maximum number of redirects is 100.
* @ param maxRedirects the maximum number of redirects
* @ throws IllegalArgumentException if { @ code maxRedirects } is negative .
* @ ... | if ( maxRedirects < 0 ) { throw new IllegalArgumentException ( "Parameter maxRedirects must be greater or equal to zero." ) ; } client . getParams ( ) . setIntParameter ( HttpClientParams . MAX_REDIRECTS , maxRedirects ) ; clientViaProxy . getParams ( ) . setIntParameter ( HttpClientParams . MAX_REDIRECTS , maxRedirect... |
public class ConnectionFactory { /** * Constructs a new database connection object per the database
* configuration .
* @ return a database connection object
* @ throws DatabaseException thrown if there is an exception loading the
* database connection */
public synchronized Connection getConnection ( ) throws ... | initialize ( ) ; Connection conn = null ; try { conn = DriverManager . getConnection ( connectionString , userName , password ) ; } catch ( SQLException ex ) { LOGGER . debug ( "" , ex ) ; throw new DatabaseException ( "Unable to connect to the database" , ex ) ; } return conn ; |
public class DRL6StrictParser { /** * lhsOr : = LEFT _ PAREN OR lhsAnd + RIGHT _ PAREN
* | lhsAnd ( OR lhsAnd ) *
* @ param ce
* @ param allowOr
* @ throws org . antlr . runtime . RecognitionException */
private BaseDescr lhsOr ( final CEDescrBuilder < ? , ? > ce , boolean allowOr ) throws RecognitionException ... | BaseDescr result = null ; if ( allowOr && input . LA ( 1 ) == DRL6Lexer . LEFT_PAREN && helper . validateLT ( 2 , DroolsSoftKeywords . OR ) ) { // prefixed OR
CEDescrBuilder < ? , OrDescr > or = null ; if ( state . backtracking == 0 ) { or = ce . or ( ) ; result = or . getDescr ( ) ; helper . start ( or , CEDescrBuilde... |
public class From { /** * Create and chain a WHERE component for specifying the WHERE clause of the query .
* @ param expression the WHERE clause expression .
* @ return the WHERE component . */
@ NonNull @ Override public Where where ( @ NonNull Expression expression ) { } } | if ( expression == null ) { throw new IllegalArgumentException ( "expression cannot be null." ) ; } return new Where ( this , expression ) ; |
public class CudaZeroHandler { /** * This method moves specific object from zero - copy memory to device memory
* PLEASE NOTE : DO NOT EVER USE THIS METHOD MANUALLY , UNLESS YOU 100 % HAVE TO
* @ return */
@ Override public boolean promoteObject ( DataBuffer buffer ) { } } | AllocationPoint dstPoint = AtomicAllocator . getInstance ( ) . getAllocationPoint ( buffer ) ; if ( dstPoint . getAllocationStatus ( ) != AllocationStatus . HOST ) return false ; if ( configuration . getMemoryModel ( ) == Configuration . MemoryModel . DELAYED && dstPoint . getAllocationStatus ( ) == AllocationStatus . ... |
public class ThreadProperty { /** * Set a string to share in other class .
* @ param key
* @ param value */
public static void set ( String key , String value ) { } } | PROPS . get ( ) . setProperty ( key , value ) ; |
public class JDBCPersistenceManagerImpl { /** * / * ( non - Javadoc )
* @ see com . ibm . jbatch . container . services . IPersistenceManagerService # updateStepExecution ( com . ibm . jbatch . container . context . impl . StepContextImpl ) */
@ Override public void updateStepExecution ( StepContextImpl stepContext )... | Metric [ ] metrics = stepContext . getMetrics ( ) ; long readCount = 0 ; long writeCount = 0 ; long commitCount = 0 ; long rollbackCount = 0 ; long readSkipCount = 0 ; long processSkipCount = 0 ; long filterCount = 0 ; long writeSkipCount = 0 ; for ( int i = 0 ; i < metrics . length ; i ++ ) { if ( metrics [ i ] . getT... |
public class lbpersistentsessions { /** * Use this API to fetch filtered set of lbpersistentsessions resources .
* filter string should be in JSON format . eg : " port : 80 , servicetype : HTTP " . */
public static lbpersistentsessions [ ] get_filtered ( nitro_service service , String filter ) throws Exception { } } | lbpersistentsessions obj = new lbpersistentsessions ( ) ; options option = new options ( ) ; option . set_filter ( filter ) ; lbpersistentsessions [ ] response = ( lbpersistentsessions [ ] ) obj . getfiltered ( service , option ) ; return response ; |
public class DocletSerializer { /** * Overrides the default implementation to set the language to " no - highlight " no
* language is specified . If highlighting is disabled or auto - highlighting is enabled ,
* this method just calls the default implementation .
* @ param node The AST node . */
@ Override public... | if ( options . isHighlightEnabled ( ) && ! options . isAutoHighlightEnabled ( ) && node . getType ( ) . isEmpty ( ) ) { VerbatimNode noHighlightNode = new VerbatimNode ( node . getText ( ) , "no-highlight" ) ; noHighlightNode . setStartIndex ( node . getStartIndex ( ) ) ; noHighlightNode . setEndIndex ( node . getEndIn... |
public class AmountFormats { /** * Formats a duration to a string in a localized word - based format .
* This returns a word - based format for the duration .
* The words are configured in a resource bundle text file -
* { @ code org . threeten . extra . wordbased . properties } - with overrides per language .
... | Objects . requireNonNull ( duration , "duration must not be null" ) ; Objects . requireNonNull ( locale , "locale must not be null" ) ; ResourceBundle bundle = ResourceBundle . getBundle ( BUNDLE_NAME , locale ) ; UnitFormat [ ] formats = { UnitFormat . of ( bundle , WORDBASED_HOUR ) , UnitFormat . of ( bundle , WORDBA... |
public class BugInstance { /** * Add a field annotation for a FieldVariable matched in a ByteCodePattern .
* @ param field
* the FieldVariable
* @ return this object */
@ Nonnull public BugInstance addField ( FieldVariable field ) { } } | return addField ( field . getClassName ( ) , field . getFieldName ( ) , field . getFieldSig ( ) , field . isStatic ( ) ) ; |
public class AbstractDefinitionDeployer { /** * per default we increment the latest definition version by one - but you
* might want to hook in some own logic here , e . g . to align definition
* versions with deployment / build versions . */
protected int getNextVersion ( DeploymentEntity deployment , DefinitionEn... | int result = 1 ; if ( latestDefinition != null ) { int latestVersion = latestDefinition . getVersion ( ) ; result = latestVersion + 1 ; } return result ; |
public class CmsVfsService { /** * Returns the preview info for the given resource . < p >
* @ param cms the CMS context
* @ param resource the resource
* @ param locale the requested locale
* @ return the preview info */
private CmsPreviewInfo getPreviewInfo ( CmsObject cms , CmsResource resource , Locale loca... | String title = "" ; try { CmsProperty titleProperty = cms . readPropertyObject ( resource , CmsPropertyDefinition . PROPERTY_TITLE , false ) ; title = titleProperty . getValue ( "" ) ; } catch ( CmsException e ) { LOG . warn ( e . getLocalizedMessage ( ) , e ) ; } String noPreviewReason = getNoPreviewReason ( cms , res... |
public class URLUtil { /** * 获得path部分 < br >
* @ param uriStr URI路径
* @ return path
* @ exception UtilException 包装URISyntaxException */
public static String getPath ( String uriStr ) { } } | URI uri = null ; try { uri = new URI ( uriStr ) ; } catch ( URISyntaxException e ) { throw new UtilException ( e ) ; } return uri . getPath ( ) ; |
public class AwsSecurityFindingFilters { /** * The destination IPv4 address of network - related information about a finding .
* @ param networkDestinationIpV4
* The destination IPv4 address of network - related information about a finding . */
public void setNetworkDestinationIpV4 ( java . util . Collection < IpFi... | if ( networkDestinationIpV4 == null ) { this . networkDestinationIpV4 = null ; return ; } this . networkDestinationIpV4 = new java . util . ArrayList < IpFilter > ( networkDestinationIpV4 ) ; |
public class MindMapPanel { /** * Try lock the panel if it is not disposed .
* @ return true if the panel is locked successfully , false if the panel has
* been disposed . */
public boolean lockIfNotDisposed ( ) { } } | boolean result = false ; if ( this . panelLocker != null ) { this . panelLocker . lock ( ) ; if ( this . disposed . get ( ) ) { this . panelLocker . unlock ( ) ; } else { result = true ; } } return result ; |
public class diff_match_patch { /** * Does a substring of shorttext exist within longtext such that the
* substring is at least half the length of longtext ?
* @ param longtext
* Longer string .
* @ param shorttext
* Shorter string .
* @ param i
* Start index of quarter length substring within longtext . ... | // Start with a 1/4 length substring at position i as a seed .
String seed = longtext . substring ( i , i + longtext . length ( ) / 4 ) ; int j = - 1 ; String best_common = "" ; String best_longtext_a = "" , best_longtext_b = "" ; String best_shorttext_a = "" , best_shorttext_b = "" ; while ( ( j = shorttext . indexOf ... |
public class PluginAdapterUtility { /** * Set instance field value for the given property , returns true if the field value was set , false otherwise */
private static boolean setValueForProperty ( final Property property , final Object value , final Object object ) { } } | final Field field = fieldForPropertyName ( property . getName ( ) , object ) ; if ( null == field ) { return false ; } final Property . Type type = property . getType ( ) ; final Property . Type ftype = propertyTypeFromFieldType ( field . getType ( ) ) ; if ( ftype != property . getType ( ) && ! ( ftype == Property . T... |
public class OptimizationRequestHandler { /** * Number of equalities . */
protected final int getMeq ( ) { } } | if ( meq < 0 ) { meq = ( this . request . getA ( ) == null ) ? 0 : this . request . getA ( ) . rows ( ) ; } return meq ; |
public class GeometrySerializer { /** * This method will return , for each of its dimension , the lowest value followed by its highest value .
* Suppose the dimension is 3 ( eg xyz ) , the method will return [ xmin , xmax , ymin , ymax , zmin , zmax ] in that order .
* < br >
* Since the presence of boundingbox c... | return envelopeToCoordinates ( shape . getEnvelope ( ) ) ; |
public class MolaDbClient { /** * The < i > GetItem < / i > operation returns a set of attributes for the item
* with the given primary key . If there is no matching item ,
* < i > GetItem < / i > does not return any data .
* < i > GetItem < / i > provides an eventually consistent read by default . If
* your ap... | checkNotNull ( request , "request should not be null." ) ; HttpMethodName method = HttpMethodName . GET ; InternalRequest httpRequest = createRequestUnderInstance ( method , MolaDbConstants . URI_TABLE , request . getTableName ( ) , MolaDbConstants . URI_ITEM ) ; buildGetItemRequest ( httpRequest , request ) ; GetItemR... |
public class AsciiSet { /** * Returns a set that matches ascii control characters . */
public static AsciiSet control ( ) { } } | final boolean [ ] members = new boolean [ 128 ] ; for ( char c = 0 ; c < members . length ; ++ c ) { members [ c ] = Character . isISOControl ( c ) ; } return new AsciiSet ( members ) ; |
public class XMLWikiPrinter { /** * Convert provided table into { @ link Attributes } to use in xml writer . */
private Attributes createAttributes ( String [ ] [ ] parameters ) { } } | AttributesImpl attributes = new AttributesImpl ( ) ; if ( parameters != null && parameters . length > 0 ) { for ( String [ ] entry : parameters ) { attributes . addAttribute ( null , null , entry [ 0 ] , null , entry [ 1 ] ) ; } } return attributes ; |
public class TimeZoneFormat { /** * Returns a < code > TimeZone < / code > for the given text .
* < b > Note < / b > : The behavior of this method is equivalent to { @ link # parse ( String , ParsePosition ) } .
* @ param text the time zone string
* @ return A < code > TimeZone < / code > .
* @ throws ParseExce... | ParsePosition pos = new ParsePosition ( 0 ) ; TimeZone tz = parse ( text , pos ) ; if ( pos . getErrorIndex ( ) >= 0 ) { throw new ParseException ( "Unparseable time zone: \"" + text + "\"" , 0 ) ; } assert ( tz != null ) ; return tz ; |
public class ActivityUtils { /** * Returns the current { @ code Activity } .
* @ param shouldSleepFirst whether to sleep a default pause first
* @ param waitForActivity whether to wait for the activity
* @ return the current { @ code Activity } */
public Activity getCurrentActivity ( boolean shouldSleepFirst , bo... | if ( shouldSleepFirst ) { sleeper . sleep ( ) ; } if ( ! config . trackActivities ) { return activity ; } if ( waitForActivity ) { waitForActivityIfNotAvailable ( ) ; } if ( ! activityStack . isEmpty ( ) ) { activity = activityStack . peek ( ) . get ( ) ; } return activity ; |
public class SSLComponent { /** * DS method to activate this component .
* @ param context
* @ param properties */
@ Activate protected synchronized void activate ( ComponentContext ctx , Map < String , Object > properties ) { } } | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEventEnabled ( ) ) { Tr . event ( tc , "Activated: " + properties ) ; } Set < String > installedFeatures = provisionerService . getInstalledFeatures ( ) ; if ( installedFeatures . contains ( "transportSecurity-1.0" ) ) { transportSecurityEnabled = true ; if ( Trac... |
public class LongStreamEx { /** * Returns the maximum element of this stream according to the provided key
* extractor function .
* This is a terminal operation .
* @ param keyExtractor a non - interfering , stateless function
* @ return an { @ code OptionalLong } describing the first element of this
* stream... | return collect ( PrimitiveBox :: new , ( box , l ) -> { double key = keyExtractor . applyAsDouble ( l ) ; if ( ! box . b || Double . compare ( box . d , key ) < 0 ) { box . b = true ; box . d = key ; box . l = l ; } } , PrimitiveBox . MAX_DOUBLE ) . asLong ( ) ; |
public class ColumnFamilyMetrics { /** * Creates a counter that will also have a global counter thats the sum of all counters across
* different column families */
protected Counter createColumnFamilyCounter ( final String name ) { } } | Counter cfCounter = Metrics . newCounter ( factory . createMetricName ( name ) ) ; if ( register ( name , cfCounter ) ) { Metrics . newGauge ( globalNameFactory . createMetricName ( name ) , new Gauge < Long > ( ) { public Long value ( ) { long total = 0 ; for ( Metric cfGauge : allColumnFamilyMetrics . get ( name ) ) ... |
public class StatFsHelper { /** * Gets the information about the free storage space , including reserved blocks ,
* either internal or external depends on the given input
* @ param storageType Internal or external storage type
* @ return available space in bytes , - 1 if no information is available */
@ SuppressL... | ensureInitialized ( ) ; maybeUpdateStats ( ) ; StatFs statFS = storageType == StorageType . INTERNAL ? mInternalStatFs : mExternalStatFs ; if ( statFS != null ) { long blockSize , availableBlocks ; if ( Build . VERSION . SDK_INT >= Build . VERSION_CODES . JELLY_BEAN_MR2 ) { blockSize = statFS . getBlockSizeLong ( ) ; a... |
public class CPFriendlyURLEntryPersistenceImpl { /** * Clears the cache for the cp friendly url entry .
* The { @ link EntityCache } and { @ link FinderCache } are both cleared by this method . */
@ Override public void clearCache ( CPFriendlyURLEntry cpFriendlyURLEntry ) { } } | entityCache . removeResult ( CPFriendlyURLEntryModelImpl . ENTITY_CACHE_ENABLED , CPFriendlyURLEntryImpl . class , cpFriendlyURLEntry . getPrimaryKey ( ) ) ; finderCache . clearCache ( FINDER_CLASS_NAME_LIST_WITH_PAGINATION ) ; finderCache . clearCache ( FINDER_CLASS_NAME_LIST_WITHOUT_PAGINATION ) ; clearUniqueFindersC... |
public class LogTable { /** * Update this record ( Always called from the record class ) .
* @ exception DBException File exception . */
public void set ( Rec fieldList ) throws DBException { } } | super . set ( fieldList ) ; this . logTrx ( ( FieldList ) fieldList , ProxyConstants . SET ) ; |
public class OCommandExecutorSQLAlterProperty { /** * Execute the ALTER PROPERTY . */
public Object execute ( final Map < Object , Object > iArgs ) { } } | if ( attribute == null ) throw new OCommandExecutionException ( "Cannot execute the command because it has not yet been parsed" ) ; final OClassImpl sourceClass = ( OClassImpl ) getDatabase ( ) . getMetadata ( ) . getSchema ( ) . getClass ( className ) ; if ( sourceClass == null ) throw new OCommandExecutionException (... |
public class CMAClient { /** * Configures CMA core endpoint . */
private Retrofit . Builder setEndpoint ( Retrofit . Builder retrofitBuilder , String endpoint ) { } } | if ( endpoint != null ) { return retrofitBuilder . baseUrl ( endpoint ) ; } return retrofitBuilder ; |
public class Ifc2x3tc1PackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public EClass getIfcRelConnectsPorts ( ) { } } | if ( ifcRelConnectsPortsEClass == null ) { ifcRelConnectsPortsEClass = ( EClass ) EPackage . Registry . INSTANCE . getEPackage ( Ifc2x3tc1Package . eNS_URI ) . getEClassifiers ( ) . get ( 460 ) ; } return ifcRelConnectsPortsEClass ; |
public class ContactsInterface { /** * Get the collection of public contacts for the specified user ID .
* This method does not require authentication .
* @ param userId
* The user ID
* @ return The Collection of Contact objects
* @ throws FlickrException */
public Collection < Contact > getPublicList ( Strin... | List < Contact > contacts = new ArrayList < Contact > ( ) ; Map < String , Object > parameters = new HashMap < String , Object > ( ) ; parameters . put ( "method" , METHOD_GET_PUBLIC_LIST ) ; parameters . put ( "user_id" , userId ) ; Response response = transportAPI . get ( transportAPI . getPath ( ) , parameters , api... |
public class Assistant { /** * Create intent .
* Create a new intent .
* This operation is limited to 2000 requests per 30 minutes . For more information , see * * Rate limiting * * .
* @ param createIntentOptions the { @ link CreateIntentOptions } containing the options for the call
* @ return a { @ link Servi... | Validator . notNull ( createIntentOptions , "createIntentOptions cannot be null" ) ; String [ ] pathSegments = { "v1/workspaces" , "intents" } ; String [ ] pathParameters = { createIntentOptions . workspaceId ( ) } ; RequestBuilder builder = RequestBuilder . post ( RequestBuilder . constructHttpUrl ( getEndPoint ( ) , ... |
public class CacheAwareServlet { /** * Check if the if - modified - since condition is satisfied .
* @ param request
* The servlet request we are processing
* @ param response
* The servlet response we are creating
* @ param resourceAttributes
* File object
* @ return boolean true if the resource meets th... | try { final long headerValue = request . getDateHeader ( "If-Modified-Since" ) ; final long lastModified = resourceAttributes . getLastModified ( ) ; if ( headerValue != - 1 ) { // If an If - None - Match header has been specified , if modified
// since
// is ignored .
if ( ( request . getHeader ( "If-None-Match" ) == ... |
public class ObjectOutputStream { /** * Dumps the parameter { @ code obj } only if it is { @ code null }
* or an object that has already been dumped previously .
* @ param obj
* Object to check if an instance previously dumped by this
* stream .
* @ return - 1 if it is an instance which has not been dumped ye... | // If the object has been saved already , save its handle only
int handle = objectsWritten . get ( obj ) ; if ( handle != - 1 ) { writeCyclicReference ( handle ) ; return handle ; } return - 1 ; |
public class TypeOfAddress { /** * Creates a TypeOfAddress from a GSM - encoded type of address byte .
* @ return */
public static TypeOfAddress valueOf ( byte b ) { } } | // bits 0-3 are the ton ( shift over 0 , then only the first 4 bits )
int ton = ( b & 0x0F ) ; // bits 4-7 are the npi ( shift over 4 , then only the first 3 bits )
int npi = ( ( b >> 4 ) & 0x07 ) ; // create our type of address now
return new TypeOfAddress ( Ton . fromInt ( ton ) , Npi . fromInt ( npi ) ) ; |
public class InventoryTargeting { /** * Sets the targetedAdUnits value for this InventoryTargeting .
* @ param targetedAdUnits * A list of targeted { @ link AdUnitTargeting } . */
public void setTargetedAdUnits ( com . google . api . ads . admanager . axis . v201808 . AdUnitTargeting [ ] targetedAdUnits ) { } } | this . targetedAdUnits = targetedAdUnits ; |
public class AppServiceEnvironmentsInner { /** * List all currently running operations on the App Service Environment .
* List all currently running operations on the App Service Environment .
* @ param resourceGroupName Name of the resource group to which the resource belongs .
* @ param name Name of the App Ser... | if ( resourceGroupName == null ) { throw new IllegalArgumentException ( "Parameter resourceGroupName is required and cannot be null." ) ; } if ( name == null ) { throw new IllegalArgumentException ( "Parameter name is required and cannot be null." ) ; } if ( this . client . subscriptionId ( ) == null ) { throw new Ille... |
public class RunsInner { /** * Gets the detailed information for a given run .
* @ param resourceGroupName The name of the resource group to which the container registry belongs .
* @ param registryName The name of the container registry .
* @ param runId The run ID .
* @ throws IllegalArgumentException thrown ... | return getWithServiceResponseAsync ( resourceGroupName , registryName , runId ) . map ( new Func1 < ServiceResponse < RunInner > , RunInner > ( ) { @ Override public RunInner call ( ServiceResponse < RunInner > response ) { return response . body ( ) ; } } ) ; |
public class JCellCalendarButton { /** * Creates new CalendarButton .
* @ param strDateParam The name of the date property ( defaults to " date " ) .
* @ param dateTarget The initial date for this button .
* @ param strLanguage The language to use . */
public void init ( Convert converter ) { } } | m_converter = converter ; Date dateTarget = ( Date ) m_converter . getData ( ) ; String strLanguage = null ; super . init ( JCalendarPopup . DATE_PARAM , dateTarget , strLanguage ) ; |
public class RedisClusterClient { /** * Returns { @ literal true } if { @ link ClusterTopologyRefreshOptions # useDynamicRefreshSources ( ) dynamic refresh sources } are
* enabled .
* Subclasses of { @ link RedisClusterClient } may override that method .
* @ return { @ literal true } if dynamic refresh sources ar... | if ( getClusterClientOptions ( ) != null ) { ClusterTopologyRefreshOptions topologyRefreshOptions = getClusterClientOptions ( ) . getTopologyRefreshOptions ( ) ; return topologyRefreshOptions . useDynamicRefreshSources ( ) ; } return true ; |
public class FrameworkManager { /** * Register core services and perform initial provisioning .
* Separate method to allow test to avoid / swap out the behavior . */
@ FFDCIgnore ( { } } | InvalidBundleContextException . class , LaunchException . class } ) protected void innerLaunchFramework ( boolean isClient ) { try { // Register services
registerInstrumentationService ( systemBundleCtx ) ; registerLibertyProcessService ( systemBundleCtx , config ) ; preRegisterMBeanServerPipelineService ( systemBundle... |
public class AbstractDataStore { /** * ( non - Javadoc )
* @ see net . timewalker . ffmq4 . utils . store . LinkedDataStore # isLocked ( int ) */
@ Override public final boolean isLocked ( int handle ) throws DataStoreException { } } | if ( SAFE_MODE ) checkHandle ( handle ) ; return locks . get ( handle ) ; |
public class OSecurityHelper { /** * Check that all required permissions present for specified { @ link OClass }
* @ param oClass { @ link OClass } to check security rights for
* @ param permissions { @ link OrientPermission } s to check
* @ return true of all permissions are allowable */
public static boolean is... | return isAllowed ( ORule . ResourceGeneric . CLASS , oClass . getName ( ) , permissions ) ; |
public class DocTreeScanner { /** * { @ inheritDoc } This implementation scans the children in left to right order .
* @ param node { @ inheritDoc }
* @ param p { @ inheritDoc }
* @ return the result of scanning */
@ Override public R visitThrows ( ThrowsTree node , P p ) { } } | R r = scan ( node . getExceptionName ( ) , p ) ; r = scanAndReduce ( node . getDescription ( ) , p , r ) ; return r ; |
public class DateTimeFormatterBuilder { /** * Appends all the elements of a formatter to the builder .
* This method has the same effect as appending each of the constituent
* parts of the formatter directly to this builder .
* @ param formatter the formatter to add , not null
* @ return this , for chaining , n... | Jdk8Methods . requireNonNull ( formatter , "formatter" ) ; appendInternal ( formatter . toPrinterParser ( false ) ) ; return this ; |
public class DoubleTuples { /** * Returns the harmonic mean of the given tuple
* @ param t The input tuple
* @ return The mean */
public static double harmonicMean ( DoubleTuple t ) { } } | double s = DoubleTupleFunctions . reduce ( t , 0.0 , ( a , b ) -> ( a + ( 1.0 / b ) ) ) ; return t . getSize ( ) / s ; |
public class DynamicMatrix { /** * Checks if the given col - key is already known and optionally generates a new key mapping . < br >
* @ param key Col - value of indexing type */
protected void ensureColKey ( E key ) { } } | if ( ! colKeys . containsKey ( key ) ) { colKeys . put ( key , colKeys . size ( ) ) ; addCol ( ) ; } |
public class AbstractRequestContext { /** * Resolves an IdMessage into an SimpleProxyId . */
SimpleProxyId < BaseProxy > getId ( final IdMessage op ) { } } | if ( Strength . SYNTHETIC . equals ( op . getStrength ( ) ) ) { return this . allocateSyntheticId ( op . getTypeToken ( ) , op . getSyntheticId ( ) ) ; } return this . state . requestFactory . getId ( op . getTypeToken ( ) , op . getServerId ( ) , op . getClientId ( ) ) ; |
public class DisassociateServiceActionFromProvisioningArtifactRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( DisassociateServiceActionFromProvisioningArtifactRequest disassociateServiceActionFromProvisioningArtifactRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( disassociateServiceActionFromProvisioningArtifactRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( disassociateServiceActionFromProvisioningArtifactRequest . getProductId ( ) , PRODUCTID_BINDING ) ; protocolMarshaller . marshal... |
public class AppConfiguration { /** * config local cache setting .
* @ param imFileDir
* @ param docDir
* @ param fileDir
* @ param queryResultDir
* @ param commandDir
* @ param analyticsDir
* @ param setting */
public static void configCacheSettings ( String imFileDir , String docDir , String fileDir , S... | importantFileDir = imFileDir ; if ( ! importantFileDir . endsWith ( "/" ) ) { importantFileDir += "/" ; } documentDir = docDir ; if ( ! documentDir . endsWith ( "/" ) ) { documentDir += "/" ; } fileCacheDir = fileDir ; if ( ! fileCacheDir . endsWith ( "/" ) ) { fileCacheDir += "/" ; } queryResultCacheDir = queryResultD... |
public class XSwitchExpressions { /** * Determine whether the given switch expression is valid for Java version 6 or lower . */
public boolean isJavaSwitchExpression ( final XSwitchExpression it ) { } } | boolean _xblockexpression = false ; { final LightweightTypeReference switchType = this . getSwitchVariableType ( it ) ; if ( ( switchType == null ) ) { return false ; } boolean _isSubtypeOf = switchType . isSubtypeOf ( Integer . TYPE ) ; if ( _isSubtypeOf ) { return true ; } boolean _isSubtypeOf_1 = switchType . isSubt... |
public class StateIdsBuilder { /** * Appends the specified state token and a zero - based document index range to this instance , returning { @ code this } .
* @ param stateToken The state token to append
* @ param start The start index of the range
* @ param end The end index of the range
* @ return { @ code t... | return doAppend ( Collections . singletonList ( new StateId ( stateToken , start , end ) ) ) ; |
public class EldaRouterRestletSupport { /** * Create a new Router initialised with the configs appropriate to the
* contextPath . */
public static Router createRouterFor ( ServletContext con ) { } } | String contextName = EldaRouterRestletSupport . flatContextPath ( con . getContextPath ( ) ) ; List < PrefixAndFilename > pfs = prefixAndFilenames ( con , contextName ) ; Router result = new DefaultRouter ( ) ; String baseFilePath = ServletUtils . withTrailingSlash ( con . getRealPath ( "/" ) ) ; AuthMap am = AuthMap .... |
public class Utf8 { /** * Tells whether the given byte array slice is a well - formed ,
* malformed , or incomplete UTF - 8 byte sequence . The range of bytes
* to be checked extends from index { @ code index } , inclusive , to
* { @ code limit } , exclusive .
* @ param state either { @ link Utf8 # COMPLETE } (... | if ( state != COMPLETE ) { // The previous decoding operation was incomplete ( or malformed ) .
// We look for a well - formed sequence consisting of bytes from
// the previous decoding operation ( stored in state ) together
// with bytes from the array slice .
// We expect such " straddler characters " to be rare .
if... |
public class Logger { /** * Log a warning message with a throwable . */
public void warn ( Throwable throwable , String msg , Object [ ] argArray ) { } } | logIfEnabled ( Level . WARNING , throwable , msg , UNKNOWN_ARG , UNKNOWN_ARG , UNKNOWN_ARG , argArray ) ; |
public class JsMessageFactoryImpl { /** * ( non - Javadoc )
* @ see com . ibm . ws . sib . mfp . JsMessageFactory # createInboundWebMessage ( String ) */
public JsMessage createInboundWebMessage ( String data ) throws MessageDecodeFailedException { } } | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createInboundWebMessage" , data ) ; JsMessage message = WebJsMessageFactoryImpl . createInboundWebMessage ( data ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "createInbo... |
public class TextInShEncoder { /** * Encodes a single character and returns its String representation
* or null if no modification is necessary . Implemented as
* < a href = " https : / / www . gnu . org / software / bash / manual / html _ node / ANSI _ 002dC - Quoting . html " > ANSI - C quoting < / a > .
* The ... | switch ( c ) { case '\\' : return "\\\\" ; case '\'' : return "\\'" ; case '"' : return "\\\"" ; case '?' : return "\\?" ; } if ( ( c >= 0x20 && c <= 0x7E ) // common case first
|| ( c >= 0xA0 && c <= 0xFFFD ) ) return null ; // 01 to 1F - control characters
if ( c >= 0x01 && c <= 0x1F ) return LOW_CONTROL [ c - 0x01 ]... |
public class PortletAppTypeImpl { /** * If not already created , a new < code > portlet < / code > element will be created and returned .
* Otherwise , the first existing < code > portlet < / code > element will be returned .
* @ return the instance defined for the element < code > portlet < / code > */
public Port... | List < Node > nodeList = childNode . get ( "portlet" ) ; if ( nodeList != null && nodeList . size ( ) > 0 ) { return new PortletTypeImpl < PortletAppType < T > > ( this , "portlet" , childNode , nodeList . get ( 0 ) ) ; } return createPortlet ( ) ; |
public class EipClient { /** * The method to generate a default Billing with default Reservation which default ReservationLength is 1.
* @ return The Billing object with default Reservation which default ReservationLength is 1 */
private Billing generateDefaultReservation ( ) { } } | Billing billing = new Billing ( ) ; Billing . Reservation reservation = new Billing . Reservation ( ) ; billing . setReservation ( reservation ) ; reservation . setReservationLength ( 1 ) ; return billing ; |
public class ApiOvhDedicatedCloud { /** * Get this object properties
* REST : GET / dedicatedCloud / { serviceName } / datacenter / { datacenterId } / vm / { vmId }
* @ param serviceName [ required ] Domain of the service
* @ param datacenterId [ required ]
* @ param vmId [ required ] Id of the virtual machine ... | String qPath = "/dedicatedCloud/{serviceName}/datacenter/{datacenterId}/vm/{vmId}" ; StringBuilder sb = path ( qPath , serviceName , datacenterId , vmId ) ; String resp = exec ( qPath , "GET" , sb . toString ( ) , null ) ; return convertTo ( resp , OvhVm . class ) ; |
public class AbstractBeanDefinition { /** * Obtains a bean definition for the field at the given index and the argument at the given index
* Warning : this method is used by internal generated code and should not be called by user code .
* @ param resolutionContext The resolution context
* @ param context The con... | return resolveBeanWithGenericsForField ( resolutionContext , injectionPoint , ( beanType , qualifier ) -> ( ( DefaultBeanContext ) context ) . getBeanProvider ( resolutionContext , beanType , qualifier ) ) ; |
public class ServerSentEvents { /** * Creates a new Server - Sent Events stream from the specified { @ link Stream } .
* @ param headers the HTTP headers supposed to send
* @ param contentStream the { @ link Stream } which publishes the objects supposed to send as contents
* @ param trailingHeaders the trailing H... | requireNonNull ( headers , "headers" ) ; requireNonNull ( contentStream , "contentStream" ) ; requireNonNull ( trailingHeaders , "trailingHeaders" ) ; requireNonNull ( executor , "executor" ) ; return streamingFrom ( contentStream , sanitizeHeaders ( headers ) , trailingHeaders , ServerSentEvents :: toHttpData , execut... |
public class TrieNode { /** * Gets debug token .
* @ return the debug token */
public String getDebugToken ( ) { } } | char asChar = getChar ( ) ; if ( asChar == NodewalkerCodec . FALLBACK ) return "<STOP>" ; if ( asChar == NodewalkerCodec . END_OF_STRING ) return "<NULL>" ; if ( asChar == NodewalkerCodec . ESCAPE ) return "<ESC>" ; if ( asChar == '\\' ) return "\\\\" ; if ( asChar == '\n' ) return "\\n" ; return new String ( new char ... |
public class P2sVpnGatewaysInner { /** * Creates a virtual wan p2s vpn gateway if it doesn ' t exist else updates the existing gateway .
* @ param resourceGroupName The resource group name of the P2SVpnGateway .
* @ param gatewayName The name of the gateway .
* @ param p2SVpnGatewayParameters Parameters supplied ... | return createOrUpdateWithServiceResponseAsync ( resourceGroupName , gatewayName , p2SVpnGatewayParameters ) . map ( new Func1 < ServiceResponse < P2SVpnGatewayInner > , P2SVpnGatewayInner > ( ) { @ Override public P2SVpnGatewayInner call ( ServiceResponse < P2SVpnGatewayInner > response ) { return response . body ( ) ;... |
public class KuduDBClient { /** * Adds the predicates to scanner builder .
* @ param scannerBuilder
* the scanner builder
* @ param embeddable
* the embeddable
* @ param fields
* the fields
* @ param metaModel
* the meta model
* @ param key
* the key */
private void addPredicatesToScannerBuilder ( K... | for ( Field f : fields ) { if ( ! ReflectUtils . isTransientOrStatic ( f ) ) { Object value = PropertyAccessorHelper . getObject ( key , f ) ; if ( f . getType ( ) . isAnnotationPresent ( Embeddable . class ) ) { // nested
addPredicatesToScannerBuilder ( scannerBuilder , ( EmbeddableType ) metaModel . embeddable ( f . ... |
public class BNFHeadersImpl { /** * Allocate a buffer according to the requested input size .
* @ param size
* @ return WsByteBuffer */
public WsByteBuffer allocateBuffer ( int size ) { } } | WsByteBufferPoolManager mgr = HttpDispatcher . getBufferManager ( ) ; WsByteBuffer wsbb = ( this . useDirectBuffer ) ? mgr . allocateDirect ( size ) : mgr . allocate ( size ) ; addToCreatedBuffer ( wsbb ) ; return wsbb ; |
public class LockingLazyVar { /** * Clears the variable , forcing the next call to { @ link # get ( ) } to re - calculate
* the value . */
public final T clear ( ) { } } | T hold ; _lock . lock ( ) ; try { hold = _val ; _val = null ; } finally { _lock . unlock ( ) ; } return hold ; |
public class MoreMath { /** * Returns numerical integral between x1 and x2
* @ param x1
* @ param x2
* @ param points
* @ return */
public static double integral ( DoubleUnaryOperator f , double x1 , double x2 , int points ) { } } | double delta = ( x2 - x1 ) / points ; double delta2 = delta / 2.0 ; double sum = 0 ; double y1 = f . applyAsDouble ( x1 ) ; double y2 ; for ( int ii = 1 ; ii <= points ; ii ++ ) { x1 += delta ; y2 = f . applyAsDouble ( x1 ) ; sum += ( y1 + y2 ) * delta2 ; y1 = y2 ; } return sum ; |
public class JmsDestinationImpl { /** * This method should be called by all setter methods if they alter the state
* information of this destination . Doing so will cause the string encoded version
* of this destination to be recreated when necessary . */
private void clearCachedEncodings ( ) { } } | cachedEncodedString = null ; cachedPartialEncodedString = null ; for ( int i = 0 ; i < cachedEncoding . length ; i ++ ) cachedEncoding [ i ] = null ; |
public class Constants { /** * Set urlPara separator . The default value is " - "
* @ param urlParaSeparator the urlPara separator */
public void setUrlParaSeparator ( String urlParaSeparator ) { } } | if ( StrKit . isBlank ( urlParaSeparator ) || urlParaSeparator . contains ( "/" ) ) { throw new IllegalArgumentException ( "urlParaSepartor can not be blank and can not contains \"/\"" ) ; } this . urlParaSeparator = urlParaSeparator ; |
public class CrsWktExtension { /** * Get the extension definition
* @ param srsId
* srs id
* @ return definition */
public String getDefinition ( long srsId ) { } } | String definition = connection . querySingleTypedResult ( "SELECT " + COLUMN_NAME + " FROM " + SpatialReferenceSystem . TABLE_NAME + " WHERE " + SpatialReferenceSystem . COLUMN_SRS_ID + " = ?" , new String [ ] { String . valueOf ( srsId ) } ) ; return definition ; |
public class HtmlDocletWriter { /** * According to
* < cite > The Java & trade ; Language Specification < / cite > ,
* all the outer classes and static nested classes are core classes . */
public boolean isCoreClass ( TypeElement typeElement ) { } } | return utils . getEnclosingTypeElement ( typeElement ) == null || utils . isStatic ( typeElement ) ; |
public class JavaReturnValueEvaluatorBuilder { /** * / * ( non - Javadoc )
* @ see org . drools . semantics . java . builder . ConsequenceBuilder # buildConsequence ( org . drools . semantics . java . builder . BuildContext , org . drools . semantics . java . builder . BuildUtils , RuleDescr ) */
public void build ( ... | final String className = getClassName ( context ) ; AnalysisResult analysis = getAnalysis ( context , descr ) ; if ( analysis == null ) { // not possible to get the analysis results
return ; } buildReturnValueEvaluator ( context , constraintNode , descr , contextResolver , className , analysis ) ; |
public class Char { /** * Decodes all backslash characters in the string */
public static String decodeBackslash ( String s ) { } } | if ( s == null || s . indexOf ( '\\' ) == - 1 ) return ( s ) ; StringBuilder result = new StringBuilder ( ) ; int [ ] eatLength = new int [ 1 ] ; while ( s . length ( ) != 0 ) { char c = eatBackslash ( s , eatLength ) ; if ( eatLength [ 0 ] > 1 ) { result . append ( c ) ; s = s . substring ( eatLength [ 0 ] ) ; } else ... |
public class ExposeLinearLayoutManagerEx { /** * Converts a focusDirection to orientation .
* @ param focusDirection One of { @ link View # FOCUS _ UP } , { @ link View # FOCUS _ DOWN } ,
* { @ link View # FOCUS _ LEFT } , { @ link View # FOCUS _ RIGHT } ,
* { @ link View # FOCUS _ BACKWARD } , { @ link View # FO... | int orientation = getOrientation ( ) ; switch ( focusDirection ) { case View . FOCUS_BACKWARD : return LayoutState . LAYOUT_START ; case View . FOCUS_FORWARD : return LayoutState . LAYOUT_END ; case View . FOCUS_UP : return orientation == VERTICAL ? LayoutState . LAYOUT_START : LayoutState . INVALID_LAYOUT ; case View ... |
public class GuildController { /** * Modifies the positional order of { @ link net . dv8tion . jda . core . entities . Category # getVoiceChannels ( ) Category # getVoiceChannels ( ) }
* using an extension of { @ link net . dv8tion . jda . core . requests . restaction . order . ChannelOrderAction ChannelOrderAction }... | Checks . notNull ( category , "Category" ) ; checkGuild ( category . getGuild ( ) , "Category" ) ; return new CategoryOrderAction < > ( category , ChannelType . VOICE ) ; |
public class RtmpClient { /** * Send a remote procedure call .
* @ param endpoint The endpoint of the call
* @ param service The service handling the call
* @ param method The method to call
* @ param args Optional args to the call
* @ return The id of the callback
* @ deprecated Due to method resolution am... | RemotingMessage message = createRemotingMessage ( endpoint , service , method , args ) ; Invoke invoke = createAmf3InvokeSkeleton ( null , message ) ; send ( invoke ) ; return invoke . getInvokeId ( ) ; |
public class CSVConfig { /** * Return a Credentials object if either tenant or user is set ( or both ) . If neither
* is set , null is returned .
* @ return Credentials to use with Client or null if there are no credentials to set . */
public Credentials getCredentials ( ) { } } | if ( ! Utils . isEmpty ( tenant ) || ! Utils . isEmpty ( user ) ) { return new Credentials ( tenant , user , password ) ; } return null ; |
public class BeanUtils { /** * 将sourceList中的对象与targetClass同名的字段从source中复制到targetClass的实例中 , 使用前请对参数进行非空校验
* @ param sourceList 被复制的源对象的数组
* @ param targetClass 要复制的目标对象的class对象
* @ param < S > 数组中数据的实际类型
* @ param < E > 目标对象的实际类型
* @ return targetClass的实例的数组 */
public static < E , S > List < E > copy ( List <... | if ( sourceList == null || sourceList . isEmpty ( ) ) { return Collections . emptyList ( ) ; } List < E > list = new ArrayList < > ( sourceList . size ( ) ) ; if ( ! ( sourceList instanceof ArrayList ) ) { sourceList = new ArrayList < > ( sourceList ) ; } for ( S source : sourceList ) { E e = copy ( source , targetClas... |
public class RocksDBOperationUtils { /** * Creates a state info from a new meta info to use with a k / v state .
* < p > Creates the column family for the state .
* Sets TTL compaction filter if { @ code ttlCompactFiltersManager } is not { @ code null } . */
public static RocksDBKeyedStateBackend . RocksDbKvStateIn... | ColumnFamilyDescriptor columnFamilyDescriptor = createColumnFamilyDescriptor ( metaInfoBase , columnFamilyOptionsFactory , ttlCompactFiltersManager ) ; return new RocksDBKeyedStateBackend . RocksDbKvStateInfo ( createColumnFamily ( columnFamilyDescriptor , db ) , metaInfoBase ) ; |
public class StringObservable { /** * Splits the { @ link Observable } of Strings by line ending characters in a platform independent way . It is equivalent to
* < pre > split ( src , " ( \ \ r \ \ n ) | \ \ n | \ \ r | \ \ u0085 | \ \ u2028 | \ \ u2029 " ) < / pre >
* < img width = " 640 " src = " https : / / raw ... | return split ( source , ByLinePatternHolder . BY_LINE ) ; |
public class AbstractOpenPgpStore { /** * OpenPgpMetadataStore */
@ Override public Map < OpenPgpV4Fingerprint , Date > getAnnouncedFingerprintsOf ( BareJid contact ) throws IOException { } } | return metadataStore . getAnnouncedFingerprintsOf ( contact ) ; |
public class GetRemoteAccessSessionRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( GetRemoteAccessSessionRequest getRemoteAccessSessionRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( getRemoteAccessSessionRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( getRemoteAccessSessionRequest . getArn ( ) , ARN_BINDING ) ; } catch ( Exception e ) { throw new SdkClientException ( "Unable to marshall request to JSON: ... |
public class SibRaEndpointInvokerImpl { /** * ( non - Javadoc )
* @ see com . ibm . ws . sib . ra . inbound . SibRaEndpointStrategy # getMdbMethod ( ) */
public Method getEndpointMethod ( ) throws ResourceAdapterInternalException { } } | final String methodName = "getEndpointMethod" ; if ( TRACE . isEntryEnabled ( ) ) { SibTr . entry ( this , TRACE , methodName ) ; } if ( ON_MESSAGE_METHOD == null ) { try { ON_MESSAGE_METHOD = SibRaMessageListener . class . getMethod ( "onMessage" , new Class [ ] { SIBusMessage . class , AbstractConsumerSession . class... |
public class ImportTerminologyRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( ImportTerminologyRequest importTerminologyRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( importTerminologyRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( importTerminologyRequest . getName ( ) , NAME_BINDING ) ; protocolMarshaller . marshall ( importTerminologyRequest . getMergeStrategy ( ) , MERGESTRATEGY_BINDIN... |
public class Futures { /** * Returns a { @ code Future } whose result is taken from the given primary { @ code input } or , if the
* primary input fails with the given { @ code exceptionType } , from the result provided by the
* { @ code fallback } . { @ link AsyncFunction # apply } is not invoked until the primary... | return AbstractCatchingFuture . create ( input , exceptionType , fallback ) ; |
public class FileBuffer { /** * Allocates a file buffer with the given initial capacity .
* If the underlying file is empty , the file count will expand dynamically as bytes are written to the file .
* The underlying { @ link FileBytes } will be initialized to the nearest power of { @ code 2 } .
* @ param file Th... | return allocate ( file , FileBytes . DEFAULT_MODE , initialCapacity , Long . MAX_VALUE ) ; |
public class JoinNode { /** * an inverted tree inverts the core relationship path , but leaves the dangling paths alone .
* Legend : S = start , E = end , D = dangling ( existence ) clause , M = middle join ( e . g . many - to - many )
* S E
* / becomes /
* E S
* S E
* / becomes /
* M M
* E S
* S E S ... | List < JoinNode > toInvert = new ArrayList ( ) ; JoinNode cur = this ; while ( ! cur . isEndNode ) { toInvert . add ( cur ) ; cur = cur . getFurtherJoins ( ) . get ( 0 ) ; } // cur is now the ultimate end node
JoinNode inverted = new JoinNode ( cur . left , true ) ; inverted . furtherJoins . addAll ( cur . furtherJoins... |
public class AbstractSelectableChannel { /** * Registers this channel with the given selector , returning a selection key .
* < p > This method first verifies that this channel is open and that the
* given initial interest set is valid .
* < p > If this channel is already registered with the given selector then
... | synchronized ( regLock ) { if ( ! isOpen ( ) ) throw new ClosedChannelException ( ) ; if ( ( ops & ~ validOps ( ) ) != 0 ) throw new IllegalArgumentException ( ) ; if ( blocking ) throw new IllegalBlockingModeException ( ) ; SelectionKey k = findKey ( sel ) ; if ( k != null ) { k . interestOps ( ops ) ; k . attach ( at... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.