signature
stringlengths
43
39.1k
implementation
stringlengths
0
450k
public class Session { /** * Synchronous call to save a session . * @ param fileName * @ throws Exception */ protected void save ( String fileName ) throws Exception { } }
configuration . save ( new File ( fileName ) ) ; if ( isNewState ( ) ) { model . moveSessionDb ( fileName ) ; } else { if ( ! this . fileName . equals ( fileName ) ) { // copy file to new fileName model . copySessionDb ( this . fileName , fileName ) ; } } this . fileName = fileName ; if ( ! Constant . isLowMemoryOption...
public class ReadWriteMultipleRequest { /** * setRegisters - Sets the registers to be written with this * < tt > ReadWriteMultipleRequest < / tt > . * @ param registers the registers to be written as < tt > Register [ ] < / tt > . */ public void setRegisters ( Register [ ] registers ) { } }
writeCount = registers != null ? registers . length : 0 ; this . registers = registers != null ? Arrays . copyOf ( registers , registers . length ) : null ;
public class OptionsUtil { /** * Retrieves the { @ link Point } object with the given wickedChartsId from the * given { @ link Options } object . Returns null if a Point with the given ID * does not exist . * @ param options Chartoptions * @ param wickedChartsId corresponding ID * @ return Point object */ pub...
for ( Series < ? > series : options . getSeries ( ) ) { for ( Object object : series . getData ( ) ) { if ( ! ( object instanceof Point ) ) { break ; } else { Point point = ( Point ) object ; if ( point . getWickedChartsId ( ) == wickedChartsId ) { return point ; } } } } return null ;
public class ConnectionImpl { /** * Checks to see if the destination is temporary and the connection * used to create the temp destination is the same as the one trying to * access it . * Checking skipped if this is a mqinterop request * @ param destination * @ param mqinterop * @ throws SITemporaryDestinat...
if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "checkTemporary" , new Object [ ] { destination , Boolean . valueOf ( mqinterop ) } ) ; // If a Temporary Destination , ensure it is on this connection unless mqinterop if ( destination . isTemporary ( ) && ! mqinterop && ( ...
public class KeyValueSelectBucketHandler { /** * Once the channel is marked as active , select bucket command is sent if the HELLO request has SELECT _ BUCKET feature * enabled . * @ param ctx the handler context . * @ throws Exception if something goes wrong during communicating to the server . */ @ Override pub...
this . ctx = ctx ; if ( selectBucketEnabled ) { byte [ ] key = bucket . getBytes ( ) ; short keyLength = ( short ) bucket . length ( ) ; BinaryMemcacheRequest request = new DefaultBinaryMemcacheRequest ( key ) ; request . setOpcode ( SELECT_BUCKET_OPCODE ) ; request . setKeyLength ( keyLength ) ; request . setTotalBody...
public class VoidParameterServer { /** * This method checks for designated role , according to local IP addresses and configuration passed into method * @ param voidConfiguration * @ param localIPs * @ return */ protected Pair < NodeRole , String > getRole ( @ NonNull VoidConfiguration voidConfiguration , @ NonNu...
NodeRole result = NodeRole . CLIENT ; for ( String ip : voidConfiguration . getShardAddresses ( ) ) { String cleansed = ip . replaceAll ( ":.*" , "" ) ; if ( localIPs . contains ( cleansed ) ) return Pair . create ( NodeRole . SHARD , ip ) ; } if ( voidConfiguration . getBackupAddresses ( ) != null ) for ( String ip : ...
public class SocketChannel { /** * Opens a socket channel and connects it to a remote address . * < p > This convenience method works as if by invoking the { @ link # open ( ) } * method , invoking the { @ link # connect ( SocketAddress ) connect } method upon * the resulting socket channel , passing it < tt > re...
SocketChannel sc = open ( ) ; try { sc . connect ( remote ) ; } catch ( Throwable x ) { try { sc . close ( ) ; } catch ( Throwable suppressed ) { x . addSuppressed ( suppressed ) ; } throw x ; } assert sc . isConnected ( ) ; return sc ;
public class VaultsInner { /** * The List operation gets information about the vaults associated with the subscription . * @ param top Maximum number of results to return . * @ throws IllegalArgumentException thrown if parameters fail the validation * @ throws CloudException thrown if the request is rejected by s...
ServiceResponse < Page < VaultInner > > response = listBySubscriptionSinglePageAsync ( top ) . toBlocking ( ) . single ( ) ; return new PagedList < VaultInner > ( response . body ( ) ) { @ Override public Page < VaultInner > nextPage ( String nextPageLink ) { return listBySubscriptionNextSinglePageAsync ( nextPageLink ...
public class Text { /** * Copies substring from the current line upto the end to the specified destination . * @ param other the destination object */ public void copyRemainder ( Text other ) { } }
other . chars = this . chars ; other . pos = this . linePointer + 1 ; other . len = this . len - this . linePointer - 1 ;
public class VirtualMachine { /** * Détachement du singleton . * @ throws Exception e */ public static synchronized void detach ( ) throws Exception { } }
// NOPMD if ( jvmVirtualMachine != null ) { final Class < ? > virtualMachineClass = jvmVirtualMachine . getClass ( ) ; final Method detachMethod = virtualMachineClass . getMethod ( "detach" ) ; jvmVirtualMachine = invoke ( detachMethod , jvmVirtualMachine ) ; jvmVirtualMachine = null ; }
public class BoundingBox { /** * Expand the bounding box max longitude above the max possible projection * value if needed to create a bounding box where the max longitude is * numerically larger than the min longitude . * @ param maxProjectionLongitude * max longitude of the world for the current bounding box ...
BoundingBox expanded = new BoundingBox ( this ) ; double minLongitude = getMinLongitude ( ) ; double maxLongitude = getMaxLongitude ( ) ; if ( minLongitude > maxLongitude ) { int worldWraps = 1 + ( int ) ( ( minLongitude - maxLongitude ) / ( 2 * maxProjectionLongitude ) ) ; maxLongitude += ( worldWraps * 2 * maxProject...
public class JmsConnectionImpl { /** * Returns the state . * @ return int */ protected int getState ( ) { } }
if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "getState" ) ; int tempState ; synchronized ( stateLock ) { tempState = state ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( this , tc , "getState" , state ) ; return tem...
public class URLUtils { /** * Create new URI with a given fragment . * @ param path URI to set fragment on * @ param fragment new fragment , { @ code null } for no fragment * @ return new URI instance with given fragment */ public static URI setFragment ( final URI path , final String fragment ) { } }
try { if ( path . getPath ( ) != null ) { return new URI ( path . getScheme ( ) , path . getUserInfo ( ) , path . getHost ( ) , path . getPort ( ) , path . getPath ( ) , path . getQuery ( ) , fragment ) ; } else { return new URI ( path . getScheme ( ) , path . getSchemeSpecificPart ( ) , fragment ) ; } } catch ( final ...
public class SourceLineAnnotation { /** * Create from Method and InstructionHandle in a visited class . * @ param classContext * ClassContext of visited class * @ param method * Method in visited class * @ param handle * InstructionHandle in visited class * @ return SourceLineAnnotation describing visited...
return fromVisitedInstruction ( classContext , method , handle . getPosition ( ) ) ;
public class XMLCaster { /** * casts a value to a XML Attribute Object * @ param doc XML Document * @ param o Object to cast * @ return XML Comment Object * @ throws PageException */ public static Attr toAttr ( Document doc , Object o ) throws PageException { } }
if ( o instanceof Attr ) return ( Attr ) o ; if ( o instanceof Struct && ( ( Struct ) o ) . size ( ) == 1 ) { Struct sct = ( Struct ) o ; Entry < Key , Object > e = sct . entryIterator ( ) . next ( ) ; Attr attr = doc . createAttribute ( e . getKey ( ) . getString ( ) ) ; attr . setValue ( Caster . toString ( e . getVa...
public class JwKRetriever { /** * Either kid or x5t will work . But not both */ public PublicKey getPublicKeyFromJwk ( String kid , String x5t , boolean useSystemPropertiesForHttpClientConnections ) throws PrivilegedActionException , IOException , KeyStoreException , InterruptedException { } }
return getPublicKeyFromJwk ( kid , x5t , null , useSystemPropertiesForHttpClientConnections ) ;
public class Example2 { /** * Uses the raw { @ link StateLocalInputSUL } to infer a ( potentially ) partial { @ link MealyMachine } . */ static void runPartialLearner ( boolean withCache ) { } }
// setup SULs and counters StateLocalInputSUL < Integer , Character > target = SUL ; ResetCounterStateLocalInputSUL < Integer , Character > resetCounter = new ResetCounterStateLocalInputSUL < > ( "Resets" , target ) ; SymbolCounterStateLocalInputSUL < Integer , Character > symbolCounter = new SymbolCounterStateLocalInp...
public class LocalClustererProcessor { /** * Update stats . * @ param event the event */ private void updateStats ( ContentEvent event ) { } }
Instance instance ; if ( event instanceof ClusteringContentEvent ) { // Local Clustering ClusteringContentEvent ev = ( ClusteringContentEvent ) event ; instance = ev . getInstance ( ) ; DataPoint point = new DataPoint ( instance , Integer . parseInt ( event . getKey ( ) ) ) ; model . trainOnInstance ( point ) ; instanc...
public class CompactSparseTypedEdgeSet { /** * Adds the edge to this set if one of the vertices is the root vertex and * if the non - root vertex has a greater index that this vertex . */ public boolean add ( TypedEdge < T > e ) { } }
if ( e . from ( ) == rootVertex ) return add ( edges , e . to ( ) , e . edgeType ( ) ) ; else if ( e . to ( ) == rootVertex ) return add ( edges , e . from ( ) , e . edgeType ( ) ) ; return false ;
public class TimelineModel { /** * Adds all given groups to the model . * @ param groups collection of groups to be added */ public void addAllGroups ( Collection < TimelineGroup > groups ) { } }
if ( groups == null ) { groups = new ArrayList < > ( ) ; } groups . addAll ( groups ) ;
public class DataSourceService { /** * Create unique ; if existing convert an existing { @ link DataSourceModel } if one exists . */ public synchronized DataSourceModel createUnique ( Set < ProjectModel > applications , String dataSourceName , String jndiName ) { } }
JNDIResourceModel jndiResourceModel = new JNDIResourceService ( getGraphContext ( ) ) . createUnique ( applications , jndiName ) ; final DataSourceModel dataSourceModel ; if ( jndiResourceModel instanceof DataSourceModel ) { dataSourceModel = ( DataSourceModel ) jndiResourceModel ; } else { dataSourceModel = addTypeToM...
public class BitArray { /** * Sets the bit at the given index . * @ param index The index of the bit to set . * @ return Indicates if the bit was changed . */ public boolean set ( long index ) { } }
if ( ! ( index < size ) ) throw new IndexOutOfBoundsException ( ) ; if ( ! get ( index ) ) { bytes . writeLong ( offset ( index ) , bytes . readLong ( offset ( index ) ) | ( 1l << position ( index ) ) ) ; count ++ ; return true ; } return false ;
public class BOCImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ @ Override public Object eGet ( int featureID , boolean resolve , boolean coreType ) { } }
switch ( featureID ) { case AfplibPackage . BOC__OBJ_CNAME : return getObjCName ( ) ; case AfplibPackage . BOC__TRIPLETS : return getTriplets ( ) ; } return super . eGet ( featureID , resolve , coreType ) ;
public class MainActivity { @ Override protected Class < ? extends MvcFragment > mapFragmentRouting ( Class < ? extends FragmentController > controllerClass ) { } }
String controllerPackage = controllerClass . getPackage ( ) . getName ( ) ; // Find the classes of fragment under package . view and named in form of xxxScreen // For example // a . b . c . CounterMasterController - > a . b . c . view . CounterMasterScreen String viewPkgName = controllerPackage . substring ( 0 , contro...
public class OmsLineSmootherMcMaster { /** * Checks if the given geometry is connected to any other line . * @ param geometryN the geometry to test . * @ return true if the geometry is alone in the space , i . e . not connected at * one of the ends to any other geometry . */ private boolean isAlone ( Geometry geo...
Coordinate [ ] coordinates = geometryN . getCoordinates ( ) ; if ( coordinates . length > 1 ) { Coordinate first = coordinates [ 0 ] ; Coordinate last = coordinates [ coordinates . length - 1 ] ; for ( SimpleFeature line : linesList ) { Geometry lineGeom = ( Geometry ) line . getDefaultGeometry ( ) ; int numGeometries ...
public class CmsJspNavBuilder { /** * This method builds a complete navigation tree with entries of all branches * from the specified folder . < p > * @ param folder folder the root folder of the navigation tree * @ param visibility controls whether entries hidden from navigation or not in navigation at all shoul...
folder = CmsFileUtil . addTrailingSeparator ( folder ) ; // check if a specific end level was given , if not , build the complete navigation boolean noLimit = false ; if ( endLevel < 0 ) { noLimit = true ; } List < CmsJspNavElement > list = new ArrayList < CmsJspNavElement > ( ) ; // get the navigation for this folder ...
public class OperandStack { /** * Remove amount elements from the operand stack , without using pop . * For example after a method invocation */ public void remove ( int amount ) { } }
int size = stack . size ( ) ; for ( int i = size - 1 ; i > size - 1 - amount ; i -- ) { popWithMessage ( i ) ; }
public class InternalSARLParser { /** * InternalSARL . g : 8745:1 : entryRuleXMultiplicativeExpression returns [ EObject current = null ] : iv _ ruleXMultiplicativeExpression = ruleXMultiplicativeExpression EOF ; */ public final EObject entryRuleXMultiplicativeExpression ( ) throws RecognitionException { } }
EObject current = null ; EObject iv_ruleXMultiplicativeExpression = null ; try { // InternalSARL . g : 8745:66 : ( iv _ ruleXMultiplicativeExpression = ruleXMultiplicativeExpression EOF ) // InternalSARL . g : 8746:2 : iv _ ruleXMultiplicativeExpression = ruleXMultiplicativeExpression EOF { if ( state . backtracking ==...
public class Object2IntHashMap { /** * Overloaded version of { @ link Map # remove ( Object ) } that takes a primitive int key . * Due to type erasure have to rename the method * @ param key for indexing the { @ link Map } * @ return the value if found otherwise missingValue */ public int removeKey ( final K key ...
@ DoNotSub final int mask = values . length - 1 ; @ DoNotSub int index = Hashing . hash ( key , mask ) ; int value ; while ( missingValue != ( value = values [ index ] ) ) { if ( key . equals ( keys [ index ] ) ) { keys [ index ] = null ; values [ index ] = missingValue ; -- size ; compactChain ( index ) ; break ; } in...
public class DBRestore { /** * { @ inheritDoc } */ public void restore ( ) throws BackupException { } }
try { for ( Entry < String , TableTransformationRule > entry : tables . entrySet ( ) ) { String tableName = entry . getKey ( ) ; TableTransformationRule restoreRule = entry . getValue ( ) ; restoreTable ( storageDir , jdbcConn , tableName , restoreRule ) ; } } catch ( IOException e ) { throw new BackupException ( e ) ;...
public class BusinessUtils { /** * Checks that classes satisfying a specification are assignable to a base class and return a * typed stream of it . */ @ SuppressWarnings ( "unchecked" ) public static < T > Stream < Class < ? extends T > > streamClasses ( Collection < Class < ? > > classes , Class < ? extends T > bas...
return classes . stream ( ) . filter ( ClassPredicates . classIsDescendantOf ( baseClass ) ) . map ( c -> ( Class < T > ) c ) ;
public class ErrorHandlerMixin { /** * { @ inheritDoc } */ @ Override public void setErrorHandlerType ( ErrorHandlerType type ) { } }
if ( errorHandler != null ) { errorHandler . cleanup ( ) ; } errorHandlerType = type == null ? ErrorHandlerType . DEFAULT : type ; switch ( errorHandlerType ) { case NONE : errorHandler = null ; break ; case DEFAULT : errorHandler = new DefaultErrorHandler ( inputWidget ) ; }
public class PubchemFingerprinter { /** * based on NCBI C implementation */ private static byte [ ] base64Decode ( String data ) { } }
int len = data . length ( ) ; byte [ ] b64 = new byte [ len * 3 / 4 ] ; byte [ ] buf = new byte [ 4 ] ; boolean done = false ; for ( int i = 0 , j , k = 0 ; i < len && ! done ; ) { buf [ 0 ] = buf [ 1 ] = buf [ 2 ] = buf [ 3 ] = 0 ; for ( j = 0 ; j < 4 && i < len ; ++ j ) { char c = data . charAt ( i ) ; if ( c >= 'A' ...
public class CmsExportParameters { /** * Sets the file path , should be a zip file . < p > * @ param path the file path */ public void setPath ( String path ) { } }
if ( CmsStringUtil . isEmpty ( path ) || ! path . trim ( ) . equals ( path ) ) { throw new CmsIllegalArgumentException ( Messages . get ( ) . container ( Messages . ERR_BAD_FILE_NAME_1 , path ) ) ; } m_path = path ;
public class InstanceTemplateClient { /** * Creates an instance template in the specified project using the data that is included in the * request . If you are creating a new template to update an existing instance group , your new * instance template must use the same network or , if applicable , the same subnetwo...
InsertInstanceTemplateHttpRequest request = InsertInstanceTemplateHttpRequest . newBuilder ( ) . setProject ( project ) . setInstanceTemplateResource ( instanceTemplateResource ) . build ( ) ; return insertInstanceTemplate ( request ) ;
public class ZooKeeperUtils { /** * Ensures the given { @ code path } exists in the ZK cluster accessed by { @ code zkClient } . If the * path already exists , nothing is done ; however if any portion of the path is missing , it will be * created with the given { @ code acl } as a persistent zookeeper node . The gi...
Objects . requireNonNull ( zkClient ) ; Objects . requireNonNull ( path ) ; if ( ! path . startsWith ( "/" ) ) { throw new IllegalArgumentException ( ) ; } ensurePathInternal ( zkClient , acl , path ) ;
public class ForeignDestination { /** * / * ( non - Javadoc ) * @ see com . ibm . ws . sib . admin . Controllable # getName ( ) */ public String getName ( ) { } }
if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "getName" ) ; String name = foreignDest . getName ( ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( tc , "getName" , name ) ; return name ;
public class SQSMessageConsumerPrefetch { /** * Helper that notifies PrefetchThread that message is dispatched and AutoAcknowledge */ private javax . jms . Message messageHandler ( MessageManager messageManager ) throws JMSException { } }
if ( messageManager == null ) { return null ; } javax . jms . Message message = messageManager . getMessage ( ) ; // Notify PrefetchThread that message is dispatched this . messageDispatched ( ) ; acknowledger . notifyMessageReceived ( ( SQSMessage ) message ) ; return message ;
public class TimeParametersImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ @ Override public void eSet ( int featureID , Object newValue ) { } }
switch ( featureID ) { case BpsimPackage . TIME_PARAMETERS__TRANSFER_TIME : setTransferTime ( ( Parameter ) newValue ) ; return ; case BpsimPackage . TIME_PARAMETERS__QUEUE_TIME : setQueueTime ( ( Parameter ) newValue ) ; return ; case BpsimPackage . TIME_PARAMETERS__WAIT_TIME : setWaitTime ( ( Parameter ) newValue ) ;...
public class GsonScriptModuleSpecSerializer { /** * Convert the input JSON String to a { @ link ScriptModuleSpec } */ @ Override public ScriptModuleSpec deserialize ( String json ) { } }
Objects . requireNonNull ( json , "json" ) ; ScriptModuleSpec moduleSpec = SERIALIZER . fromJson ( json , ScriptModuleSpec . class ) ; return moduleSpec ;
public class CheckBox { /** * Render the checkbox . * @ throws JspException if a JSP exception has occurred */ public int doEndTag ( ) throws JspException { } }
Tag parent = getParent ( ) ; if ( parent instanceof CheckBoxGroup ) registerTagError ( Bundle . getString ( "Tags_CheckBoxGroupChildError" ) , null ) ; Object val = evaluateDataSource ( ) ; if ( hasErrors ( ) ) return reportAndExit ( EVAL_PAGE ) ; ByRef ref = new ByRef ( ) ; nameHtmlControl ( _state , ref ) ; String hi...
public class ArrowConverter { /** * Create an ndarray vector that stores structs * of { @ link INDArray } * based on the { @ link org . apache . arrow . flatbuf . Tensor } * format * @ param allocator the allocator to use * @ param name the name of the vector * @ param length the number of vectors to store ...
VarBinaryVector ret = new VarBinaryVector ( name , allocator ) ; ret . allocateNewSafe ( ) ; ret . setValueCount ( length ) ; return ret ;
public class Ec2IaasHandler { /** * Parses the properties and saves them in a Java bean . * @ param targetProperties the IaaS properties * @ throws TargetException */ static void parseProperties ( Map < String , String > targetProperties ) throws TargetException { } }
// Quick check String [ ] properties = { Ec2Constants . EC2_ENDPOINT , Ec2Constants . EC2_ACCESS_KEY , Ec2Constants . EC2_SECRET_KEY , Ec2Constants . AMI_VM_NODE , Ec2Constants . VM_INSTANCE_TYPE , Ec2Constants . SSH_KEY_NAME , Ec2Constants . SECURITY_GROUP_NAME } ; for ( String property : properties ) { if ( StringUti...
public class NumberParser { /** * Parse an Integer from a String . If the String is not an integer < b > null < / b > is returned and * no exception is thrown . * @ param str the String to parse * @ return The Integer represented by the String , or null if it could not be parsed . */ public static Integer parseIn...
if ( null != str ) { try { return new Integer ( Integer . parseInt ( str . trim ( ) ) ) ; } catch ( final Exception e ) { // : IGNORE : } } return null ;
public class StringGroovyMethods { /** * Replaces the first occurrence of a captured group by the result of a closure call on that text . * For example ( with some replaceAll variants thrown in for comparison purposes ) , * < pre > * assert " hellO world " = = " hello world " . replaceFirst ( ~ " ( o ) " ) { it [...
"List<String>" , "String[]" } ) Closure closure ) { final String s = self . toString ( ) ; final Matcher matcher = pattern . matcher ( s ) ; if ( matcher . find ( ) ) { final StringBuffer sb = new StringBuffer ( s . length ( ) + 16 ) ; String replacement = getReplacement ( matcher , closure ) ; matcher . appendReplacem...
public class StoreDataflowFactory { /** * ( non - Javadoc ) * @ see * edu . umd . cs . findbugs . classfile . IAnalysisEngine # analyze ( edu . umd . cs . findbugs * . classfile . IAnalysisCache , java . lang . Object ) */ @ Override public StoreDataflow analyze ( IAnalysisCache analysisCache , MethodDescriptor d...
MethodGen methodGen = getMethodGen ( analysisCache , descriptor ) ; if ( methodGen == null ) { return null ; } StoreAnalysis analysis = new StoreAnalysis ( getDepthFirstSearch ( analysisCache , descriptor ) , getConstantPoolGen ( analysisCache , descriptor . getClassDescriptor ( ) ) ) ; StoreDataflow dataflow = new Sto...
public class SOARecord { /** * Convert to a String */ String rrToString ( ) { } }
StringBuffer sb = new StringBuffer ( ) ; sb . append ( host ) ; sb . append ( " " ) ; sb . append ( admin ) ; if ( Options . check ( "multiline" ) ) { sb . append ( " (\n\t\t\t\t\t" ) ; sb . append ( serial ) ; sb . append ( "\t; serial\n\t\t\t\t\t" ) ; sb . append ( refresh ) ; sb . append ( "\t; refresh\n\t\t\t\t\t" ...
public class ByteIOUtils { /** * Writes a specific integer value ( 4 bytes ) to the output byte array at the given offset . * @ param buf output byte array * @ param pos offset into the byte buffer to write * @ param v int value to write */ public static void writeInt ( byte [ ] buf , int pos , int v ) { } }
checkBoundary ( buf , pos , 4 ) ; buf [ pos ++ ] = ( byte ) ( 0xff & ( v >> 24 ) ) ; buf [ pos ++ ] = ( byte ) ( 0xff & ( v >> 16 ) ) ; buf [ pos ++ ] = ( byte ) ( 0xff & ( v >> 8 ) ) ; buf [ pos ] = ( byte ) ( 0xff & v ) ;
public class GeoPackageJavaProperties { /** * Get a property by key * @ param key * key * @ param required * required flag * @ return property value */ public static synchronized String getProperty ( String key , boolean required ) { } }
if ( mProperties == null ) { mProperties = initializeConfigurationProperties ( ) ; } String value = mProperties . getProperty ( key ) ; if ( value == null && required ) { throw new RuntimeException ( "Property not found: " + key ) ; } return value ;
public class SarlProcessorInstanceForJvmTypeProvider { /** * Filter the type in order to create the correct processor . * @ param type the type of the processor specified into the { @ code @ Active } annotation . * @ param services the type services of the framework . * @ return the real type of the processor to ...
if ( AccessorsProcessor . class . getName ( ) . equals ( type . getQualifiedName ( ) ) ) { return services . getTypeReferences ( ) . findDeclaredType ( SarlAccessorsProcessor . class , type ) ; } return type ;
public class Expressions { /** * Create a new Path expression * @ param type type of expression * @ param variable variable name * @ return path expression */ public static < T extends Comparable < ? > > DateTimePath < T > dateTimePath ( Class < ? extends T > type , String variable ) { } }
return new DateTimePath < T > ( type , PathMetadataFactory . forVariable ( variable ) ) ;
public class AbstractListenableFuture { /** * Notify a specific listener of completion . * @ param executor the executor to use . * @ param future the future to hand over . * @ param listener the listener to notify . */ protected void notifyListener ( final ExecutorService executor , final Future < ? > future , f...
executor . submit ( new Runnable ( ) { @ Override public void run ( ) { try { listener . onComplete ( future ) ; } catch ( Throwable t ) { getLogger ( ) . warn ( "Exception thrown wile executing " + listener . getClass ( ) . getName ( ) + ".operationComplete()" , t ) ; } } } ) ;
public class QueryBuilder { /** * Appends given fragment and arguments to this query . */ public @ NotNull QueryBuilder append ( @ NotNull String sql , @ NotNull Collection < ? > args ) { } }
query . append ( requireNonNull ( sql ) ) ; addArguments ( args ) ; return this ;
public class OstrichOwnerGroup { /** * Returns true if the Guava service entered the RUNNING state within the specified time period . */ private boolean awaitRunning ( Service service , long timeoutAt ) { } }
if ( service . isRunning ( ) ) { return true ; } long waitMillis = timeoutAt - System . currentTimeMillis ( ) ; if ( waitMillis <= 0 ) { return false ; } try { service . start ( ) . get ( waitMillis , TimeUnit . MILLISECONDS ) ; } catch ( Exception e ) { // Fall through } return service . isRunning ( ) ;
public class Rc4Utils { /** * Decrypt data bytes using RC4 * @ param data data bytes to be decrypted * @ param key rc4 key ( 40 . . 2048 bits ) * @ return decrypted data bytes */ public static byte [ ] decrypt ( byte [ ] data , byte [ ] key ) { } }
checkNotNull ( data ) ; checkNotNull ( key ) ; checkArgument ( key . length >= 5 && key . length <= 256 ) ; StreamCipher rc4 = new RC4Engine ( ) ; rc4 . init ( false , new KeyParameter ( key ) ) ; byte [ ] decrypted = new byte [ data . length ] ; rc4 . processBytes ( data , 0 , data . length , decrypted , 0 ) ; return ...
public class GeoDB { /** * Returns any GeoLocation which matches all tests and is unique in deltaNM * range . * @ param deltaNM * @ param searches * @ return */ public GeoLocation search ( double deltaNM , GeoSearch ... searches ) { } }
List < GeoLocation > list = search ( false , searches ) ; if ( ! list . isEmpty ( ) && GeoDB . isUnique ( list , deltaNM ) ) { return list . get ( 0 ) ; } else { list . removeIf ( ( gl ) -> ! gl . match ( true , searches ) ) ; if ( ! list . isEmpty ( ) && GeoDB . isUnique ( list , deltaNM ) ) { return list . get ( 0 ) ...
public class ServerConfiguration { /** * Sets the value for the appropriate key in the { @ link Properties } . * @ param key the key to set * @ param value the value for the key */ public static void set ( PropertyKey key , Object value ) { } }
set ( key , String . valueOf ( value ) , Source . RUNTIME ) ;
public class CmsMailSettings { /** * Adds a new mail host to the internal list of mail hosts with default port 25 . < p > * @ param hostname the name of the mail host * @ param order the order in which the host is tried * @ param protocol the protocol to use ( default " smtp " ) * @ param username the user name...
addMailHost ( hostname , "25" , order , protocol , null , username , password ) ;
public class StorageBatch { /** * Adds a request representing the " get blob " operation to this batch . The { @ code options } can be * used in the same way as for { @ link Storage # get ( BlobId , BlobGetOption . . . ) } . Calling { @ link * StorageBatchResult # get ( ) } on the return value yields the requested ...
StorageBatchResult < Blob > result = new StorageBatchResult < > ( ) ; RpcBatch . Callback < StorageObject > callback = createGetCallback ( this . options , result ) ; Map < StorageRpc . Option , ? > optionMap = StorageImpl . optionMap ( blob , options ) ; batch . addGet ( blob . toPb ( ) , callback , optionMap ) ; retu...
public class ParallelUniverseCompat { @ Override public void resetStaticState ( Config config ) { } }
Robolectric . reset ( ) ; if ( ! loggingInitialized ) { ShadowLog . setupLogging ( ) ; loggingInitialized = true ; }
public class CoreV1Api { /** * ( asynchronously ) * connect PUT requests to proxy of Pod * @ param name name of the PodProxyOptions ( required ) * @ param namespace object name and auth scope , such as for teams and projects ( required ) * @ param path Path is the URL path to use for the current proxy request t...
ProgressResponseBody . ProgressListener progressListener = null ; ProgressRequestBody . ProgressRequestListener progressRequestListener = null ; if ( callback != null ) { progressListener = new ProgressResponseBody . ProgressListener ( ) { @ Override public void update ( long bytesRead , long contentLength , boolean do...
public class DebugHelper { /** * When in debugging mode , adds a border to the image and calls { @ link VectorPrintDocument # addHook ( com . vectorprint . report . itext . VectorPrintDocument . AddElementHook ) * } to be able to print debugging info and link for the image * @ param canvas * @ param img * @ par...
if ( null != img ) { img . setBorder ( Rectangle . BOX ) ; img . setBorderWidth ( 0.3f ) ; img . setBorderColor ( itextHelper . fromColor ( bordercolor ) ) ; if ( styleClass == null ) { log . warning ( "not showing link to styleClass because there is no styleClass" ) ; return ; } img . setAnnotation ( new Annotation ( ...
import java . io . * ; import java . lang . * ; class SumSquaresOddNumbers { /** * The function calculates the sum of squares of the first ' order ' odd natural numbers . * Args : * order : The number of first odd natural numbers to consider * Returns : * An integer value sum of squares of the first ' order ' o...
return ( order * ( ( 4 * order * order ) - 1 ) ) / 3 ;
public class FastAdapter { /** * deselects an item and removes its position in the selections list * also takes an iterator to remove items from the map * @ param position the global position * @ param entries the iterator which is used to deselect all * @ deprecated deprecated in favor of { @ link SelectExtens...
mSelectExtension . deselect ( position , entries ) ;
public class WebStatFilter { /** * < p > getRemoteAddress . < / p > * @ param request a { @ link javax . ws . rs . container . ContainerRequestContext } object . * @ return a { @ link java . lang . String } object . */ protected String getRemoteAddress ( ContainerRequestContext request ) { } }
String ip = null ; if ( realIpHeader != null && realIpHeader . length ( ) != 0 ) { ip = request . getHeaderString ( realIpHeader ) ; } if ( StringUtils . isBlank ( ip ) ) { ip = request . getHeaderString ( "x-forwarded-for" ) ; if ( StringUtils . isBlank ( ip ) || "unknown" . equalsIgnoreCase ( ip ) ) { ip = request . ...
public class ValueFileIOHelper { /** * Write streamed value to a file . * @ param file * File * @ param value * ValueData * @ return size of wrote content * @ throws IOException * if error occurs */ protected long writeStreamedValue ( File file , ValueData value ) throws IOException { } }
long size ; // stream Value if ( value instanceof StreamPersistedValueData ) { StreamPersistedValueData streamed = ( StreamPersistedValueData ) value ; if ( streamed . isPersisted ( ) ) { // already persisted in another Value , copy it to this Value size = copyClose ( streamed . getAsStream ( ) , new FileOutputStream (...
public class DeleteScheduledActionRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( DeleteScheduledActionRequest deleteScheduledActionRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( deleteScheduledActionRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( deleteScheduledActionRequest . getServiceNamespace ( ) , SERVICENAMESPACE_BINDING ) ; protocolMarshaller . marshall ( deleteScheduledActionRequest . getSche...
public class CppUtil { /** * Uppercase the first character of a given String . * @ param str to have the first character upper cased . * @ return a new String with the first character in uppercase . */ public static String toUpperFirstChar ( final String str ) { } }
return Character . toUpperCase ( str . charAt ( 0 ) ) + str . substring ( 1 ) ;
public class CmsExportPointDriver { /** * Writes file data to the RFS . < p > * @ param file the RFS file location * @ param content the file content */ protected void writeResource ( File file , byte [ ] content ) { } }
try { File folder ; if ( content == null ) { // a folder is to be created folder = file ; } else { // a file is to be written folder = file . getParentFile ( ) ; } // make sure the parent folder exists if ( ! folder . exists ( ) ) { boolean success = folder . mkdirs ( ) ; if ( ! success ) { LOG . error ( Messages . get...
public class ServerSentEventService { /** * Closes all connections for a given URI resource * @ param uri The URI resource for the connection */ public void close ( String uri ) { } }
Objects . requireNonNull ( uri , Required . URI . toString ( ) ) ; final Set < ServerSentEventConnection > uriConnections = getConnections ( uri ) ; if ( uriConnections != null ) { uriConnections . forEach ( ( ServerSentEventConnection connection ) -> { if ( connection . isOpen ( ) ) { MangooUtils . closeQuietly ( conn...
public class DubiousListCollection { /** * overrides the visitor to record all method calls on List fields . If a method * is not a set based method , remove it from further consideration * @ param seen the current opcode parsed . */ @ Override public void sawOpcode ( final int seen ) { } }
try { stack . precomputation ( this ) ; if ( seen == Const . INVOKEINTERFACE ) { processInvokeInterface ( ) ; } else if ( seen == Const . INVOKEVIRTUAL ) { processInvokeVirtual ( ) ; } else if ( ( seen == Const . ARETURN ) && ( stack . getStackDepth ( ) > 0 ) ) { OpcodeStack . Item item = stack . getStackItem ( 0 ) ; X...
public class DiagnosticOrder { /** * syntactic sugar */ public DiagnosticOrder addEvent ( DiagnosticOrderEventComponent t ) { } }
if ( t == null ) return this ; if ( this . event == null ) this . event = new ArrayList < DiagnosticOrderEventComponent > ( ) ; this . event . add ( t ) ; return this ;
public class ErrorStatsServiceClient { /** * Lists the specified events . * < p > Sample code : * < pre > < code > * try ( ErrorStatsServiceClient errorStatsServiceClient = ErrorStatsServiceClient . create ( ) ) { * ProjectName projectName = ProjectName . of ( " [ PROJECT ] " ) ; * String groupId = " " ; * ...
ListEventsRequest request = ListEventsRequest . newBuilder ( ) . setProjectName ( projectName == null ? null : projectName . toString ( ) ) . setGroupId ( groupId ) . build ( ) ; return listEvents ( request ) ;
public class JsonArray { /** * see { @ link List # add ( Object ) } . * this method is alternative of { @ link # add ( Object , Type ) } call with { @ link Type # BOOLEAN } . * @ param value * @ return see { @ link List # add ( Object ) } * @ since 1.4.12 * @ author vvakame */ public boolean add ( Boolean val...
if ( value == null ) { stateList . add ( Type . NULL ) ; } else { stateList . add ( Type . BOOLEAN ) ; } return super . add ( value ) ;
public class UcsApi { /** * Assign the interaction to a contact * @ param id id of the Interaction ( required ) * @ param assignInteractionToContactData ( required ) * @ return ApiResponse & lt ; ApiSuccessResponse & gt ; * @ throws ApiException If fail to call the API , e . g . server error or cannot deseriali...
com . squareup . okhttp . Call call = assignInteractionToContactValidateBeforeCall ( id , assignInteractionToContactData , null , null ) ; Type localVarReturnType = new TypeToken < ApiSuccessResponse > ( ) { } . getType ( ) ; return apiClient . execute ( call , localVarReturnType ) ;
public class CodedOutputStream { /** * Write a { @ code string } field to the stream . */ public void writeStringNoTag ( final String value ) throws IOException { } }
// Unfortunately there does not appear to be any way to tell Java to encode // UTF - 8 directly into our buffer , so we have to let it create its own byte // array and then copy . final byte [ ] bytes = value . getBytes ( "UTF-8" ) ; writeRawVarint32 ( bytes . length ) ; writeRawBytes ( bytes ) ;
public class Matrix4d { /** * Pre - multiply a translation to this matrix by translating by the given number of * units in x , y and z and store the result in < code > dest < / code > . * If < code > M < / code > is < code > this < / code > matrix and < code > T < / code > the translation * matrix , then the new ...
if ( ( properties & PROPERTY_IDENTITY ) != 0 ) return dest . translation ( x , y , z ) ; return translateLocalGeneric ( x , y , z , dest ) ;
public class RoleAliasDescriptionMarshaller { /** * Marshall the given parameter object . */ public void marshall ( RoleAliasDescription roleAliasDescription , ProtocolMarshaller protocolMarshaller ) { } }
if ( roleAliasDescription == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( roleAliasDescription . getRoleAlias ( ) , ROLEALIAS_BINDING ) ; protocolMarshaller . marshall ( roleAliasDescription . getRoleAliasArn ( ) , ROLEALIASARN_BINDING ) ...
public class DeleteRuleGroupRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( DeleteRuleGroupRequest deleteRuleGroupRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( deleteRuleGroupRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( deleteRuleGroupRequest . getRuleGroupId ( ) , RULEGROUPID_BINDING ) ; protocolMarshaller . marshall ( deleteRuleGroupRequest . getChangeToken ( ) , CHANGETOKEN_BI...
public class SpiFactory { /** * Create new SpiDevice instance * @ param channel * spi channel to use * @ param mode * spi mode ( see http : / / en . wikipedia . org / wiki / Serial _ Peripheral _ Interface _ Bus # Mode _ numbers ) * @ return Return a new SpiDevice impl instance . * @ throws java . io . IOEx...
return new SpiDeviceImpl ( channel , mode ) ;
public class TemplateElasticsearchUpdater { /** * Create a new template in Elasticsearch * @ param client Elasticsearch client * @ param template Template name * @ param json JSon content for the template * @ param force set it to true if you want to force cleaning template before adding it * @ throws Excepti...
if ( isTemplateExist ( client , template ) ) { if ( force ) { logger . debug ( "Template [{}] already exists. Force is set. Removing it." , template ) ; removeTemplate ( client , template ) ; } else { logger . debug ( "Template [{}] already exists." , template ) ; } } if ( ! isTemplateExist ( client , template ) ) { lo...
public class NavigationPreference { /** * Obtains the color state list to tint the preference ' s icon from a specific typed array . * @ param typedArray * The typed array , the color state list should be obtained from , as an instance of the * class { @ link TypedArray } . The typed array may not be null */ priv...
setIconTintList ( typedArray . getColorStateList ( R . styleable . NavigationPreference_android_tint ) ) ;
public class DocumentCrossValidationIterator { /** * Shuffles the elements of this list among several smaller lists . * @ param fraction * A list of numbers ( not necessarily summing to 1 ) which , when * normalized , correspond to the proportion of elements in each * returned sublist . This method ( and all th...
List < Integer > articleIds = newArrayList ( instanceArticles . keySet ( ) ) ; Collections . shuffle ( articleIds , r ) ; final int nrSentences = instanceArticles . size ( ) ; final int nrSentencesPerSplit = ( int ) ( nrSentences / ( double ) _nfolds ) ; int runningSplitId = 0 ; int runningSentencesPerSplit = 0 ; Insta...
public class SendingEntityBody { /** * Increment the next expected sequence number and trigger the pipelining logic . * @ param outboundResponseMsg Represent the outbound response */ private void triggerPipeliningLogic ( HttpCarbonMessage outboundResponseMsg ) { } }
String httpVersion = ( String ) inboundRequestMsg . getProperty ( Constants . HTTP_VERSION ) ; if ( outboundResponseMsg . isPipeliningEnabled ( ) && Constants . HTTP_1_1_VERSION . equalsIgnoreCase ( httpVersion ) ) { Queue responseQueue ; synchronized ( sourceContext . channel ( ) . attr ( Constants . RESPONSE_QUEUE ) ...
public class Converters { /** * 获取属性设置属性 * @ param clazz * @ param field * @ return */ private static < T > Method tryGetSetMethod ( Class < T > clazz , Field field , String methodName ) { } }
try { return clazz . getDeclaredMethod ( methodName , field . getType ( ) ) ; } catch ( Exception e ) { return null ; }
public class Util { /** * Mix multiple hashcodes into one . * @ param hash1 First hashcode to mix * @ param hash2 Second hashcode to mix * @ param hash3 Third hashcode to mix * @ return Mixed hash code */ public static int mixHashCodes ( int hash1 , int hash2 , int hash3 ) { } }
long result = hash1 * HASHPRIME + hash2 ; return ( int ) ( result * HASHPRIME + hash3 ) ;
public class Net { /** * Drop membership of IPv6 multicast group */ static void drop6 ( FileDescriptor fd , byte [ ] group , int index , byte [ ] source ) throws IOException { } }
joinOrDrop6 ( false , fd , group , index , source ) ;
public class AfplibFactoryImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ public String convertGBARFLAGSToString ( EDataType eDataType , Object instanceValue ) { } }
return instanceValue == null ? null : instanceValue . toString ( ) ;
public class AggregateEventAnalysisEngine { /** * Determines the time between the { @ link Event } at the head of the queue and the * { @ link Event } at the tail of the queue . * @ param queue a queue of { @ link Event } s * @ param tailEvent the { @ link Event } at the tail of the queue * @ return the duratio...
DateTime endTime = DateUtils . fromString ( tailEvent . getTimestamp ( ) ) ; DateTime startTime = DateUtils . fromString ( queue . peek ( ) . getTimestamp ( ) ) ; return new Interval ( ( int ) endTime . minus ( startTime . getMillis ( ) ) . getMillis ( ) , "milliseconds" ) ;
public class TranslationsResourceIT { /** * Checks the outdated scenario . * 1 ) A key is added * 2 ) Add fr translation * 3 ) Update default translation = > key become outdated * 4 ) Update en translation = > key is still outdated * 5 ) Update fr translation = > key is no longer outdated */ @ Test public voi...
httpPost ( "keys" , jsonKey . toString ( ) , 201 ) ; try { // Add two outdated translations sendTranslationUpdate ( "zztranslation" , EN , true ) ; sendTranslationUpdate ( "translation" , FR , true ) ; // Update the default translation jsonKey . put ( "translation" , "updated translation" ) ; httpPut ( "keys/" + keyNam...
public class JmsDestinationImpl { /** * Utility method update a property . * Checks that the value is different to the existing value and clears the cache if necessary . * Needs package / protected access as also used by subclasses ( in the same package ) . * @ param key The name of the property * @ param value...
if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "updateProperty" , new Object [ ] { key , value } ) ; // check the value is different to the existing one if ( isDifferent ( key , value ) ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) )...
public class ForwardingRuleClient { /** * Retrieves an aggregated list of forwarding rules . * < p > Sample code : * < pre > < code > * try ( ForwardingRuleClient forwardingRuleClient = ForwardingRuleClient . create ( ) ) { * ProjectName project = ProjectName . of ( " [ PROJECT ] " ) ; * for ( ForwardingRules...
AggregatedListForwardingRulesHttpRequest request = AggregatedListForwardingRulesHttpRequest . newBuilder ( ) . setProject ( project ) . build ( ) ; return aggregatedListForwardingRules ( request ) ;
public class OrganizationResourceImpl { /** * Does the same thing as getClientVersion ( ) but accepts the ' hasPermission ' param , * which lets callers dictate whether the user has clientView permission for the org . * @ param organizationId * @ param clientId * @ param version * @ param hasPermission */ pro...
try { storage . beginTx ( ) ; ClientVersionBean clientVersion = storage . getClientVersion ( organizationId , clientId , version ) ; if ( clientVersion == null ) { throw ExceptionFactory . clientVersionNotFoundException ( clientId , version ) ; } // Hide some data if the user doesn ' t have the clientView permission if...
public class Aggregations { /** * Returns an aggregation to calculate the integer sum of all supplied values . < br / > * This aggregation is similar to : < pre > SELECT SUM ( value ) FROM x < / pre > * @ param < Key > the input key type * @ param < Value > the supplied value type * @ return the sum over all su...
return new AggregationAdapter ( new IntegerSumAggregation < Key , Value > ( ) ) ;
public class User { /** * Activates a user if a given token matches the one stored . * @ param token the email confirmation token . see { @ link # generateEmailConfirmationToken ( ) } * @ return true if successful */ public final boolean activateWithEmailToken ( String token ) { } }
Sysprop s = CoreUtils . getInstance ( ) . getDao ( ) . read ( getAppid ( ) , identifier ) ; if ( isValidToken ( s , Config . _EMAIL_TOKEN , token ) ) { s . removeProperty ( Config . _EMAIL_TOKEN ) ; CoreUtils . getInstance ( ) . getDao ( ) . update ( getAppid ( ) , s ) ; setActive ( true ) ; update ( ) ; return true ; ...
public class DigitPickerPreference { /** * Obtains the number of digits of the numbers , the preference allows to choose , from a specific * typed array . * @ param typedArray * The typed array , the number of digits should be obtained from , as an instance of the * class { @ link TypedArray } . The typed array...
int defaultValue = getContext ( ) . getResources ( ) . getInteger ( R . integer . digit_picker_preference_default_number_of_digits ) ; setNumberOfDigits ( typedArray . getInteger ( R . styleable . DigitPickerPreference_numberOfDigits , defaultValue ) ) ;
public class ApiOvhPrice { /** * Get the monthly price for an office license * REST : GET / price / license / office / { officeName } * @ param officeName [ required ] Office */ public OvhPrice license_office_officeName_GET ( net . minidev . ovh . api . price . license . OvhOfficeEnum officeName ) throws IOExceptio...
String qPath = "/price/license/office/{officeName}" ; StringBuilder sb = path ( qPath , officeName ) ; String resp = exec ( qPath , "GET" , sb . toString ( ) , null ) ; return convertTo ( resp , OvhPrice . class ) ;
public class CmsHtmlConverterJTidy { /** * Converts the given HTML code according to the settings of this converter . < p > * @ param htmlInput HTML input stored in a string * @ return string containing the converted HTML * @ throws UnsupportedEncodingException if the encoding set for the conversion is not suppor...
// initialize the modes initModes ( ) ; // only do parsing if the mode is not set to disabled if ( m_modeEnabled ) { // do a maximum of 10 loops int max = m_modeWord ? 10 : 1 ; int count = 0 ; // we may have to do several parsing runs until all tags are removed int oldSize = htmlInput . length ( ) ; String workHtml = r...
public class Credential { /** * { @ inheritDoc } * Default implementation checks if { @ code WWW - Authenticate } exists and contains a " Bearer " value * ( see < a href = " http : / / tools . ietf . org / html / rfc6750 # section - 3.1 " > rfc6750 section 3.1 < / a > for more * details ) . If so , it calls { @ l...
boolean refreshToken = false ; boolean bearer = false ; List < String > authenticateList = response . getHeaders ( ) . getAuthenticateAsList ( ) ; // TODO ( peleyal ) : this logic should be implemented as a pluggable interface , in the same way we // implement different AccessMethods // if authenticate list is not null...
public class CacheControl { /** * This creates a cache control hint for the specified path * @ param path the path to the field that has the cache control hint * @ param scope the scope of the cache control hint * @ return this object builder style */ public CacheControl hint ( ExecutionPath path , Scope scope ) ...
return hint ( path , null , scope ) ;