signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class DatabaseUtils { /** * Reads a Long out of a field in a Cursor and writes it to a Map .
* @ param cursor The cursor to read from
* @ param field The INTEGER field to read
* @ param values The { @ link ContentValues } to put the value into
* @ param key The key to store the value with in the map */
p... | int colIndex = cursor . getColumnIndex ( field ) ; if ( ! cursor . isNull ( colIndex ) ) { Long value = Long . valueOf ( cursor . getLong ( colIndex ) ) ; values . put ( key , value ) ; } else { values . put ( key , ( Long ) null ) ; } |
public class SeleniumBrowser { /** * Creates temporary storage .
* @ return */
private Path createTemporaryStorage ( ) { } } | try { Path tempDir = Files . createTempDirectory ( "selenium" ) ; tempDir . toFile ( ) . deleteOnExit ( ) ; log . info ( "Download storage location is: " + tempDir . toString ( ) ) ; return tempDir ; } catch ( IOException e ) { throw new CitrusRuntimeException ( "Could not create temporary storage" , e ) ; } |
public class CoordinatesUtils { /** * Find the furthest coordinate in a geometry from a base coordinate
* @ param base
* @ param coords
* @ return the base coordinate and the target coordinate */
public static Coordinate [ ] getFurthestCoordinate ( Coordinate base , Coordinate [ ] coords ) { } } | double distanceMax = Double . MIN_VALUE ; Coordinate farCoordinate = null ; for ( Coordinate coord : coords ) { double distance = coord . distance ( base ) ; if ( distance > distanceMax ) { distanceMax = distance ; farCoordinate = coord ; } } if ( farCoordinate != null ) { return new Coordinate [ ] { base , farCoordina... |
public class DateTimeUtils { /** * Gets the default map of time zone names .
* This can be changed by { @ link # setDefaultTimeZoneNames } .
* The default set of short time zone names is as follows :
* < ul >
* < li > UT - UTC
* < li > UTC - UTC
* < li > GMT - UTC
* < li > EST - America / New _ York
* <... | Map < String , DateTimeZone > names = cZoneNames . get ( ) ; if ( names == null ) { names = buildDefaultTimeZoneNames ( ) ; if ( ! cZoneNames . compareAndSet ( null , names ) ) { names = cZoneNames . get ( ) ; } } return names ; |
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } { @ link PixelInCellType } { @ code > }
* @ param value
* Java instance representing xml element ' s value .
* @ return
* the new instance of { @ link JAXBElement } { @ code < } { @ link PixelInCellType } { @ code > } *... | return new JAXBElement < PixelInCellType > ( _PixelInCell_QNAME , PixelInCellType . class , null , value ) ; |
public class WebMBeanServerAdapter { /** * Get the { @ link Set } of MBean names from the { @ link MBeanServer } . The names are HTML sanitized .
* @ return the { @ link Set } of HTML sanitized MBean names . */
public Set < String > getMBeanNames ( ) { } } | Set < String > nameSet = new TreeSet < String > ( ) ; for ( ObjectInstance instance : mBeanServer . queryMBeans ( null , null ) ) { nameSet . add ( sanitizer . escapeValue ( instance . getObjectName ( ) . getCanonicalName ( ) ) ) ; } return nameSet ; |
public class ApiOvhEmaildomain { /** * Change mailing list options
* REST : POST / email / domain / { domain } / mailingList / { name } / changeOptions
* @ param options [ required ] Options of mailing list
* @ param domain [ required ] Name of your domain name
* @ param name [ required ] Name of mailing list *... | String qPath = "/email/domain/{domain}/mailingList/{name}/changeOptions" ; StringBuilder sb = path ( qPath , domain , name ) ; HashMap < String , Object > o = new HashMap < String , Object > ( ) ; addBody ( o , "options" , options ) ; String resp = exec ( qPath , "POST" , sb . toString ( ) , o ) ; return convertTo ( re... |
public class PersonIdentifierTypeBuilder { /** * { @ inheritDoc } */
@ Override public PersonIdentifierType buildObject ( String namespaceURI , String localName , String namespacePrefix ) { } } | return new PersonIdentifierTypeImpl ( namespaceURI , localName , namespacePrefix ) ; |
public class CurrentGpsInfo { /** * Method to add a new { @ link GLLSentence } .
* @ param gll the sentence to add . */
public void addGLL ( GLLSentence gll ) { } } | try { if ( gll . isValid ( ) ) position = gll . getPosition ( ) ; } catch ( Exception e ) { // ignore it , this should be handled in the isValid ,
// if an exception is thrown , we can ' t deal with it here .
} |
public class FactoryDetectPoint { /** * Detects Kitchen and Rosenfeld corners .
* @ param configDetector Configuration for feature detector .
* @ param derivType Type of derivative image .
* @ see boofcv . alg . feature . detect . intensity . KitRosCornerIntensity */
public static < T extends ImageGray < T > , D ... | if ( configDetector == null ) configDetector = new ConfigGeneralDetector ( ) ; GeneralFeatureIntensity < T , D > intensity = new WrapperKitRosCornerIntensity < > ( derivType ) ; return createGeneral ( intensity , configDetector ) ; |
public class ApacheHTTPClient { /** * This function appends the parameters text to the base URL .
* @ param buffer
* The buffer to update
* @ param parameters
* The parameters line */
protected void appendParameters ( StringBuilder buffer , String parameters ) { } } | if ( ( parameters != null ) && ( parameters . length ( ) > 0 ) ) { String updatedParameters = parameters ; if ( parameters . startsWith ( "?" ) ) { updatedParameters = parameters . substring ( 1 ) ; } if ( updatedParameters . length ( ) > 0 ) { int currentLength = buffer . length ( ) ; if ( ( currentLength > 0 ) && ( b... |
public class MetricRegistry { /** * Given a metric set , registers them with the given prefix prepended to their names .
* @ param prefix a name prefix
* @ param metrics a set of metrics
* @ throws IllegalArgumentException if any of the names are already registered */
public void registerAll ( String prefix , Met... | for ( Map . Entry < String , Metric > entry : metrics . getMetrics ( ) . entrySet ( ) ) { if ( entry . getValue ( ) instanceof MetricSet ) { registerAll ( name ( prefix , entry . getKey ( ) ) , ( MetricSet ) entry . getValue ( ) ) ; } else { register ( name ( prefix , entry . getKey ( ) ) , entry . getValue ( ) ) ; } } |
public class ProductPartitionNode { /** * Removes the specified key from the custom parameters map . The key < em > must < / em > be present in
* the map .
* < p > Since this method follows the standard builder pattern and returns { @ code this } , there is no
* way to indicate if the remove operation failed besi... | if ( ! nodeState . supportsCustomParameters ( ) ) { throw new IllegalStateException ( String . format ( "Cannot remove custom parameters on a %s node" , nodeState . getNodeType ( ) ) ) ; } Preconditions . checkNotNull ( key , "Null key" ) ; if ( ! nodeState . getCustomParams ( ) . containsKey ( key ) ) { throw new Ille... |
public class TypeRefFactory { /** * Wraps the actual class with a proxy . */
@ Override public ITypeRef create ( IType type ) { } } | // already a proxy ? return as is then
if ( type instanceof ITypeRef ) { return ( ITypeRef ) type ; } if ( type instanceof INonLoadableType ) { throw new UnsupportedOperationException ( "Type references are not supported for nonloadable types: " + type . getName ( ) ) ; } String strTypeName = TypeLord . getNameWithQual... |
public class CollectionUtil { /** * Creates an array containing a subset of the original array .
* If the { @ code pLength } parameter is negative , it will be ignored .
* If there are not { @ code pLength } elements in the original array
* after { @ code pStart } , the { @ code pLength } parameter will be
* ig... | "SuspiciousSystemArraycopy" } ) public static Object subArray ( Object pArray , int pStart , int pLength ) { Validate . notNull ( pArray , "array" ) ; // Get component type
Class type ; // Sanity check start index
if ( pStart < 0 ) { throw new ArrayIndexOutOfBoundsException ( pStart + " < 0" ) ; } // Check if argument ... |
public class SRTServletRequest { /** * verify the InputStreamData Map object contains required value .
* throws IllegalStateException if there is any missing values . */
@ SuppressWarnings ( "rawtypes" ) protected void validateInputStreamData ( Map isd ) throws IllegalStateException { } } | String message = null ; if ( isd != null ) { if ( isd . size ( ) <= 3 ) { boolean type = isd . containsKey ( INPUT_STREAM_CONTENT_TYPE ) ; boolean length = isd . containsKey ( INPUT_STREAM_CONTENT_DATA_LENGTH ) ; boolean data = isd . containsKey ( INPUT_STREAM_CONTENT_DATA ) ; if ( type && length && data ) { // valid .... |
public class CmsRequestContext { /** * Returns the adjusted site root for a resource using the provided site root as a base . < p >
* Usually , this would be the site root for the current site .
* However , if a resource from the < code > / system / < / code > folder is requested ,
* this will be the empty String... | if ( resourcename . startsWith ( CmsWorkplace . VFS_PATH_SYSTEM ) || OpenCms . getSiteManager ( ) . startsWithShared ( resourcename ) || ( resourcename . startsWith ( CmsWorkplace . VFS_PATH_SITES ) && ! resourcename . startsWith ( siteRoot ) ) ) { return "" ; } else { return siteRoot ; } |
public class SARLValidator { /** * Check the container for the SARL capacities .
* @ param capacity the capacity . */
@ Check public void checkContainerType ( SarlCapacity capacity ) { } } | final XtendTypeDeclaration declaringType = capacity . getDeclaringType ( ) ; if ( declaringType != null ) { final String name = canonicalName ( declaringType ) ; assert name != null ; error ( MessageFormat . format ( Messages . SARLValidator_30 , name ) , capacity , null , INVALID_NESTED_DEFINITION ) ; } |
public class ProxySelectorImpl { /** * Returns the proxy identified by the { @ code hostKey } system property , or
* null . */
private Proxy lookupProxy ( String hostKey , String portKey , Proxy . Type type , int defaultPort ) { } } | String host = System . getProperty ( hostKey ) ; if ( host == null || host . isEmpty ( ) ) { return null ; } int port = getSystemPropertyInt ( portKey , defaultPort ) ; return new Proxy ( type , InetSocketAddress . createUnresolved ( host , port ) ) ; |
public class MPP12Reader { /** * This method extracts and collates resource assignment data .
* @ throws IOException */
private void processAssignmentData ( ) throws IOException { } } | FieldMap fieldMap = new FieldMap12 ( m_file . getProjectProperties ( ) , m_file . getCustomFields ( ) ) ; fieldMap . createAssignmentFieldMap ( m_projectProps ) ; FieldMap enterpriseCustomFieldMap = new FieldMap12 ( m_file . getProjectProperties ( ) , m_file . getCustomFields ( ) ) ; enterpriseCustomFieldMap . createEn... |
public class MessageValidatorRegistryParser { /** * Parses all variable definitions and adds those to the bean definition
* builder as property value .
* @ param builder the target bean definition builder .
* @ param element the source element . */
private void parseValidators ( BeanDefinitionBuilder builder , El... | ManagedList validators = new ManagedList ( ) ; for ( Element validator : DomUtils . getChildElementsByTagName ( element , "validator" ) ) { if ( validator . hasAttribute ( "ref" ) ) { validators . add ( new RuntimeBeanReference ( validator . getAttribute ( "ref" ) ) ) ; } else { validators . add ( BeanDefinitionBuilder... |
public class OptionsScannerPanel { /** * This method initializes sliderHostPerScan
* @ return javax . swing . JSlider */
private JSlider getSliderHostPerScan ( ) { } } | if ( sliderHostPerScan == null ) { sliderHostPerScan = new JSlider ( ) ; sliderHostPerScan . setMaximum ( 5 ) ; sliderHostPerScan . setMinimum ( 1 ) ; sliderHostPerScan . setMinorTickSpacing ( 1 ) ; sliderHostPerScan . setPaintTicks ( true ) ; sliderHostPerScan . setPaintLabels ( true ) ; sliderHostPerScan . setName ( ... |
public class AntiAffinityService { /** * Update Anti - affinity policy
* @ param policyRef policy reference
* @ param modifyConfig update policy config
* @ return OperationFuture wrapper for AntiAffinityPolicy */
public OperationFuture < AntiAffinityPolicy > modify ( AntiAffinityPolicy policyRef , AntiAffinityPol... | client . modifyAntiAffinityPolicy ( findByRef ( policyRef ) . getId ( ) , new AntiAffinityPolicyRequest ( ) . name ( modifyConfig . getName ( ) ) ) ; return new OperationFuture < > ( policyRef , new NoWaitingJobFuture ( ) ) ; |
public class PrimitiveUtils { /** * Read integer .
* @ param value the value
* @ param defaultValue the default value
* @ return the integer */
public static Integer readInteger ( String value , Integer defaultValue ) { } } | if ( ! StringUtils . hasText ( value ) ) return defaultValue ; return Integer . valueOf ( value ) ; |
public class TFileDumper { /** * Dump information about TFile .
* @ param file
* Path string of the TFile
* @ param out
* PrintStream to output the information .
* @ param conf
* The configuration object .
* @ throws IOException */
static public void dumpInfo ( String file , PrintStream out , Configuratio... | final int maxKeySampleLen = 16 ; Path path = new Path ( file ) ; FileSystem fs = path . getFileSystem ( conf ) ; long length = fs . getFileStatus ( path ) . getLen ( ) ; FSDataInputStream fsdis = fs . open ( path ) ; TFile . Reader reader = new TFile . Reader ( fsdis , length , conf ) ; try { LinkedHashMap < String , S... |
public class GeneratorParameter { /** * Add a preference .
* @ param preference The preference to add .
* @ return The generator parameter itself . */
public GeneratorParameter add ( Preference preference ) { } } | preferences . add ( preference ) ; Collections . sort ( preferences ) ; return this ; |
public class StringUtil { /** * this is the public entry point for the replaceMap ( ) method
* @ param input - the string on which the replacements should be performed .
* @ param map - a java . util . Map with key / value pairs where the key is the substring to find and the
* value is the substring with which to... | return replaceMap ( input , map , ignoreCase , true ) ; |
public class HttpClientMockBuilder { /** * Adds parameter condition . Parameter value must match .
* @ param name parameter name
* @ param matcher parameter value matcher
* @ return condition builder */
public HttpClientMockBuilder withParameter ( String name , Matcher < String > matcher ) { } } | ruleBuilder . addParameterCondition ( name , matcher ) ; return this ; |
public class MicroProfileClientProxyImpl { /** * Liberty change start */
private void init ( ExecutorService executorService , Configuration configuration ) { } } | cfg . getRequestContext ( ) . put ( EXECUTOR_SERVICE_PROPERTY , executorService ) ; cfg . getRequestContext ( ) . putAll ( configuration . getProperties ( ) ) ; List < Interceptor < ? extends Message > > inboundChain = cfg . getInInterceptors ( ) ; inboundChain . add ( new MPAsyncInvocationInterceptorPostAsyncImpl ( ) ... |
public class DataNode { /** * { @ inheritDoc } */
@ Override public List < String > getReconfigurableProperties ( ) { } } | List < String > changeable = Arrays . asList ( "dfs.data.dir" ) ; return changeable ; |
public class OfferService { /** * Remove an offer .
* @ param offer the { @ link Offer } .
* @ param removeWithSubscriptions if true , the plan and all subscriptions associated with it will be deleted . If
* false , only the plan will be deleted . */
public void delete ( Offer offer , boolean removeWithSubscripti... | ParameterMap < String , String > params = new ParameterMap < String , String > ( ) ; params . add ( "remove_with_subscriptions" , String . valueOf ( removeWithSubscriptions ) ) ; RestfulUtils . delete ( OfferService . PATH , offer , params , Offer . class , super . httpClient ) ; |
public class ImageInserter { /** * Specify the images that you want to overlay on your video . The images must be PNG or TGA files .
* @ param insertableImages
* Specify the images that you want to overlay on your video . The images must be PNG or TGA files . */
public void setInsertableImages ( java . util . Colle... | if ( insertableImages == null ) { this . insertableImages = null ; return ; } this . insertableImages = new java . util . ArrayList < InsertableImage > ( insertableImages ) ; |
public class ContinuousDistributions { /** * Calculates the probability from 0 to X under Exponential Distribution
* @ param x
* @ param lamda
* @ return */
public static double exponentialCdf ( double x , double lamda ) { } } | if ( x < 0 || lamda <= 0 ) { throw new IllegalArgumentException ( "All the parameters must be positive." ) ; } double probability = 1.0 - Math . exp ( - lamda * x ) ; return probability ; |
public class CoreBiGramTableDictionary { /** * 获取共现频次
* @ param idA 第一个词的id
* @ param idB 第二个词的id
* @ return 共现频次 */
public static int getBiFrequency ( int idA , int idB ) { } } | // 负数id表示来自用户词典的词语的词频 ( 用户自定义词语没有id ) , 返回正值增加其亲和度
if ( idA < 0 ) { return - idA ; } if ( idB < 0 ) { return - idB ; } int index = binarySearch ( pair , start [ idA ] , start [ idA + 1 ] - start [ idA ] , idB ) ; if ( index < 0 ) return 0 ; index <<= 1 ; return pair [ index + 1 ] ; |
public class IntBitSet { /** * Changes data to have data . length > = s components . All data
* components that fit into the new size are preserved .
* @ param s new data size wanted */
private void resize ( int s ) { } } | int [ ] n ; int count ; n = new int [ s ] ; count = ( s < data . length ) ? s : data . length ; System . arraycopy ( data , 0 , n , 0 , count ) ; data = n ; |
public class Navigator { /** * Check the app is exiting
* @ param sender The sender */
private void checkAppExit ( Object sender ) { } } | NavLocation curLocation = navigationManager . getModel ( ) . getCurrentLocation ( ) ; if ( curLocation == null ) { navigationManager . postEvent2C ( new NavigationManager . Event . OnAppExit ( sender ) ) ; } |
public class PagedStorage { /** * - - - - - Non - Contiguous API ( tiling required ) - - - - - */
void initAndSplit ( int leadingNulls , @ NonNull List < T > multiPageList , int trailingNulls , int positionOffset , int pageSize , @ NonNull Callback callback ) { } } | int pageCount = ( multiPageList . size ( ) + ( pageSize - 1 ) ) / pageSize ; for ( int i = 0 ; i < pageCount ; i ++ ) { int beginInclusive = i * pageSize ; int endExclusive = Math . min ( multiPageList . size ( ) , ( i + 1 ) * pageSize ) ; List < T > sublist = multiPageList . subList ( beginInclusive , endExclusive ) ;... |
public class URLImpl { /** * check if this url can serve the refUrl .
* @ param refUrl a URL object
* @ return boolean true can serve */
@ Override public boolean canServe ( URL refUrl ) { } } | if ( refUrl == null || ! this . getPath ( ) . equals ( refUrl . getPath ( ) ) ) { return false ; } if ( ! protocol . equals ( refUrl . getProtocol ( ) ) ) { return false ; } if ( ! Constants . NODE_TYPE_SERVICE . equals ( this . getParameter ( URLParamType . nodeType . getName ( ) ) ) ) { return false ; } String versio... |
public class Utils { /** * リストに要素のインデックスを指定して追加します 。
* < p > リストのサイズが足りない場合は 、 サイズを自動的に変更します 。 < / p >
* @ since 2.0
* @ param list リスト
* @ param element 追加する要素 。 値はnullでもよい 。
* @ param index 追加する要素のインデックス番号 ( 0以上 )
* @ throws IllegalArgumentException { @ literal list = = null . }
* @ throws Illegal... | ArgUtils . notNull ( list , "list" ) ; ArgUtils . notMin ( index , 0 , "index" ) ; final int listSize = list . size ( ) ; if ( listSize < index ) { // 足りない場合は 、 要素を追加する 。
final int lackSize = index - listSize ; for ( int i = 0 ; i < lackSize ; i ++ ) { list . add ( null ) ; } list . add ( element ) ; } else if ( listSi... |
public class ElementEditor { /** * Sets as an Document created from a String .
* @ throws IllegalArgumentException A parse exception occured */
@ Override public void setAsText ( String text ) { } } | if ( BeanUtils . isNull ( text ) ) { setValue ( null ) ; return ; } setValue ( getAsDocument ( text ) . getDocumentElement ( ) ) ; |
public class MongoDBClientFactory { /** * ( non - Javadoc )
* @ see
* com . impetus . kundera . loader . GenericClientFactory # instantiateClient ( java
* . lang . String ) */
@ Override protected Client instantiateClient ( String persistenceUnit ) { } } | return new MongoDBClient ( mongoDB , indexManager , reader , persistenceUnit , externalProperties , clientMetadata , kunderaMetadata ) ; |
public class hqlParser { /** * hql . g : 295:1 : fromClassOrOuterQueryPath : path ( asAlias ) ? ( propertyFetch ) ? - > ^ ( RANGE path ( asAlias ) ? ( propertyFetch ) ? ) ; */
public final hqlParser . fromClassOrOuterQueryPath_return fromClassOrOuterQueryPath ( ) throws RecognitionException { } } | hqlParser . fromClassOrOuterQueryPath_return retval = new hqlParser . fromClassOrOuterQueryPath_return ( ) ; retval . start = input . LT ( 1 ) ; CommonTree root_0 = null ; ParserRuleReturnScope path92 = null ; ParserRuleReturnScope asAlias93 = null ; ParserRuleReturnScope propertyFetch94 = null ; RewriteRuleSubtreeStre... |
public class Element { /** * ( non - Javadoc )
* @ see qc . automation . framework . widget . IElement # isElementVisible ( ) */
@ Override public boolean isElementVisible ( ) throws WidgetException { } } | try { return isVisible ( ) && ( getLocationX ( ) > 0 ) && ( getLocationY ( ) > 0 ) ; } catch ( Exception e ) { throw new WidgetException ( "Error while determining whether element is visible" , locator , e ) ; } |
public class DdlGenerator { /** * get component class by component property string
* @ param pc
* @ param propertyString
* @ return */
private Class < ? > getPropertyType ( PersistentClass pc , String propertyString ) { } } | String [ ] properties = split ( propertyString , '.' ) ; Property p = pc . getProperty ( properties [ 0 ] ) ; Component cp = ( ( Component ) p . getValue ( ) ) ; int i = 1 ; for ( ; i < properties . length ; i ++ ) { p = cp . getProperty ( properties [ i ] ) ; cp = ( ( Component ) p . getValue ( ) ) ; } return cp . get... |
public class ResourcePendingMaintenanceActionsMarshaller { /** * Marshall the given parameter object . */
public void marshall ( ResourcePendingMaintenanceActions resourcePendingMaintenanceActions , ProtocolMarshaller protocolMarshaller ) { } } | if ( resourcePendingMaintenanceActions == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( resourcePendingMaintenanceActions . getResourceIdentifier ( ) , RESOURCEIDENTIFIER_BINDING ) ; protocolMarshaller . marshall ( resourcePendingMaintenan... |
public class FieldErrorAttributeProcessor { /** * If Type - Convertion Error found at Struts2 , overwrite request -
* parameter same name .
* @ param fieldname parameter - name
* @ return request - parameter - value ( if convertion error occurs , return from struts2 , not else thymeleaf . ) */
protected String ge... | ActionContext ctx = ServletActionContext . getContext ( ) ; ValueStack stack = ctx . getValueStack ( ) ; Map < Object , Object > overrideMap = stack . getExprOverrides ( ) ; // If convertion error has not , do nothing .
if ( overrideMap == null || overrideMap . isEmpty ( ) ) { return null ; } if ( ! overrideMap . conta... |
public class Aggregated { /** * Returns the parameters of the term
* @ return ` " aggregation minimum maximum terms " ` */
@ Override public String parameters ( ) { } } | FllExporter exporter = new FllExporter ( ) ; StringBuilder result = new StringBuilder ( ) ; result . append ( String . format ( "%s %s %s" , Op . str ( minimum ) , Op . str ( maximum ) , exporter . toString ( aggregation ) ) ) ; for ( Term term : terms ) { result . append ( " " ) . append ( exporter . toString ( term )... |
public class ResourceType { /** * Converts the resource type to an absolute path . If it does not start with " / " the resource is resolved
* via search paths using resource resolver . If not matching resource is found it is returned unchanged .
* @ param resourceType Resource type
* @ param resourceResolver Reso... | if ( StringUtils . isEmpty ( resourceType ) || StringUtils . startsWith ( resourceType , "/" ) ) { return resourceType ; } // first try to resolve path via component manager - because on publish instance the original resource may not accessible
ComponentManager componentManager = resourceResolver . adaptTo ( ComponentM... |
public class GISTreeSetUtil { /** * Replies if the given region contains the given point .
* @ param region is the index of the region .
* @ param cutX is the cut line of the region parent .
* @ param cutY is the cut line of the region parent .
* @ param pointX is the coordinate of the point to classify .
* @... | switch ( IcosepQuadTreeZone . values ( ) [ region ] ) { case SOUTH_WEST : return pointX <= cutX && pointY <= cutY ; case SOUTH_EAST : return pointX >= cutX && pointY <= cutY ; case NORTH_WEST : return pointX <= cutX && pointY >= cutY ; case NORTH_EAST : return pointX >= cutX && pointY >= cutY ; case ICOSEP : return tru... |
public class HFCACertificateRequest { /** * Get certificates that have been revoked after this date
* @ param revokedStart Revoked after date
* @ throws InvalidArgumentException Date can ' t be null */
public void setRevokedStart ( Date revokedStart ) throws InvalidArgumentException { } } | if ( revokedStart == null ) { throw new InvalidArgumentException ( "Date can't be null" ) ; } queryParms . put ( "revoked_start" , Util . dateToString ( revokedStart ) ) ; |
public class ArrivalsThreadGroup { /** * Graceful shutdown of test calls this , then # verifyThreadsStopped */
@ Override public void tellThreadsToStop ( ) { } } | super . tellThreadsToStop ( ) ; for ( DynamicThread thread : poolThreads ) { stopThread ( thread . getThreadName ( ) , true ) ; } |
public class DescribeStacksResult { /** * An array of < code > Stack < / code > objects that describe the stacks .
* @ param stacks
* An array of < code > Stack < / code > objects that describe the stacks . */
public void setStacks ( java . util . Collection < Stack > stacks ) { } } | if ( stacks == null ) { this . stacks = null ; return ; } this . stacks = new com . amazonaws . internal . SdkInternalList < Stack > ( stacks ) ; |
public class UserControl { /** * Set up the screen input fields . */
public void setupFields ( ) { } } | FieldInfo field = null ; field = new FieldInfo ( this , ID , Constants . DEFAULT_FIELD_LENGTH , null , null ) ; field . setDataClass ( Integer . class ) ; field . setHidden ( true ) ; field = new FieldInfo ( this , LAST_CHANGED , Constants . DEFAULT_FIELD_LENGTH , null , null ) ; field . setDataClass ( Date . class ) ;... |
public class AnnotationAttribute { /** * Reads the { @ link Annotation } attribute ' s value from the given { @ link AnnotatedElement } .
* @ param annotatedElement must not be { @ literal null } .
* @ return */
@ Nullable public String getValueFrom ( AnnotatedElement annotatedElement ) { } } | Assert . notNull ( annotatedElement , "Annotated element must not be null!" ) ; Annotation annotation = annotatedElement . getAnnotation ( annotationType ) ; return annotation == null ? null : getValueFrom ( annotation ) ; |
public class ActionDefinition { /** * syntactic sugar */
public ActionDefinitionCustomizationComponent addCustomization ( ) { } } | ActionDefinitionCustomizationComponent t = new ActionDefinitionCustomizationComponent ( ) ; if ( this . customization == null ) this . customization = new ArrayList < ActionDefinitionCustomizationComponent > ( ) ; this . customization . add ( t ) ; return t ; |
public class ParameterizedSpecRunner { /** * - 1 = > unknown */
private int estimateNumIterations ( Object [ ] dataProviders ) { } } | if ( runStatus != OK ) return - 1 ; if ( dataProviders . length == 0 ) return 1 ; int result = Integer . MAX_VALUE ; for ( Object prov : dataProviders ) { if ( prov instanceof Iterator ) // unbelievably , DGM provides a size ( ) method for Iterators ,
// although it is of course destructive ( i . e . it exhausts the It... |
public class DataFlowAnalysis { /** * Finds a fixed - point solution . The function has the side effect of replacing
* the existing node annotations with the computed solutions using { @ link
* com . google . javascript . jscomp . graph . GraphNode # setAnnotation ( Annotation ) } .
* < p > Initially , each node ... | initialize ( ) ; int step = 0 ; while ( ! orderedWorkSet . isEmpty ( ) ) { if ( step > maxSteps ) { throw new MaxIterationsExceededException ( "Analysis did not terminate after " + maxSteps + " iterations" ) ; } DiGraphNode < N , Branch > curNode = orderedWorkSet . iterator ( ) . next ( ) ; orderedWorkSet . remove ( cu... |
public class COSInputStream { /** * Perform lazy seek and adjust stream to correct position for reading .
* @ param targetPos position from where data should be read
* @ param len length of the content that needs to be read */
private void lazySeek ( long targetPos , long len ) throws IOException { } } | // For lazy seek
seekInStream ( targetPos , len ) ; // re - open at specific location if needed
if ( wrappedStream == null ) { reopen ( "read from new offset" , targetPos , len ) ; } |
public class JdbcKAMLoaderImpl { /** * { @ inheritDoc } */
@ Override public void loadStatementAnnotationMap ( StatementAnnotationMapTable samt ) throws SQLException { } } | Map < Integer , Set < AnnotationPair > > sidAnnotationIndex = samt . getStatementAnnotationPairsIndex ( ) ; PreparedStatement saps = getPreparedStatement ( STATEMENT_ANNOTATION_SQL ) ; final Set < Entry < Integer , Set < AnnotationPair > > > entries = sidAnnotationIndex . entrySet ( ) ; for ( final Entry < Integer , Se... |
public class LoadBalancerManager { /** * Get the ServiceQueryRRLoadBalancer .
* @ param serviceName
* the service name .
* @ param query
* the ServiceInstanceQuery .
* @ return
* the ServiceQueryRRLoadBalancer . */
public ServiceQueryRRLoadBalancer getServiceQueryRRLoadBalancer ( String serviceName , Servic... | for ( ServiceQueryRRLoadBalancer lb : svcQueryLBList ) { if ( lb . getServiceName ( ) . equals ( serviceName ) && lb . getServiceInstanceQuery ( ) . equals ( query ) ) { return lb ; } } ServiceQueryRRLoadBalancer lb = new ServiceQueryRRLoadBalancer ( lookupService , serviceName , query ) ; svcQueryLBList . add ( lb ) ;... |
public class Validator { /** * Reverses a set of properties mapped using the description ' s configuration to property mapping , or the same input
* if the description has no mapping
* @ param input input map
* @ param desc plugin description
* @ return mapped values */
public static Map < String , String > dem... | final Map < String , String > mapping = desc . getPropertiesMapping ( ) ; return demapProperties ( input , mapping , true ) ; |
public class Cache { /** * / / / / / Op handling / / / / / */
private Object handleOpGet ( CacheLine line , Op . Type type , Object data , short nodeHint , Transaction txn , int change ) { } } | if ( ( change & ( LINE_STATE_CHANGED | LINE_OWNER_CHANGED | ( synchronous ? LINE_MODIFIED_CHANGED : 0 ) ) ) == 0 ) return PENDING ; if ( line . is ( CacheLine . DELETED ) ) handleDeleted ( line ) ; if ( ! transitionToS ( line , nodeHint ) ) { if ( type != Op . Type . GETS && line . version > 0 && ! isPossibleInconsiste... |
public class PathUtil { /** * create a path from an array of components
* @ param components path components strings
* @ return a path */
public static Path pathFromComponents ( String [ ] components ) { } } | if ( null == components || components . length == 0 ) { return null ; } return new PathImpl ( pathStringFromComponents ( components ) ) ; |
public class RestCall { /** * Fixme : Need refactoring to remove code duplication . */
protected HttpClient getHttpClient ( ) { } } | HttpClient client = new HttpClient ( ) ; if ( Jenkins . getInstance ( ) != null ) { ProxyConfiguration proxy = Jenkins . getInstance ( ) . proxy ; if ( useProxy && ( proxy != null ) ) { client . getHostConfiguration ( ) . setProxy ( proxy . name , proxy . port ) ; String username = proxy . getUserName ( ) ; String pass... |
public class TernaryTreeNode { /** * Set the left child of this node .
* @ param newChild the new child .
* @ return < code > true < / code > on success , otherwise < code > false < / code > */
public boolean setLeftChild ( N newChild ) { } } | final N oldChild = this . left ; if ( oldChild == newChild ) { return false ; } if ( oldChild != null ) { oldChild . setParentNodeReference ( null , true ) ; -- this . notNullChildCount ; firePropertyChildRemoved ( 0 , oldChild ) ; } if ( newChild != null ) { final N oldParent = newChild . getParentNode ( ) ; if ( oldP... |
public class Crawler { /** * This method calls the index state . It should be called once per crawl in order to setup the
* crawl .
* @ return The initial state . */
public StateVertex crawlIndex ( ) { } } | LOG . debug ( "Setting up vertex of the index page" ) ; if ( basicAuthUrl != null ) { browser . goToUrl ( basicAuthUrl ) ; } browser . goToUrl ( url ) ; // Run url first load plugin to clear the application state
plugins . runOnUrlFirstLoadPlugins ( context ) ; plugins . runOnUrlLoadPlugins ( context ) ; StateVertex in... |
public class FlowUtils { /** * Generates a queue consumer groupId for the given flowlet in the given program id . */
public static long generateConsumerGroupId ( String flowId , String flowletId ) { } } | return Hashing . md5 ( ) . newHasher ( ) . putString ( flowId ) . putString ( flowletId ) . hash ( ) . asLong ( ) ; |
public class CmsAreaSelectPanel { /** * Sets the selection area . < p >
* @ param relative < code > true < / code > if provided position is relative to the select area , not absolute to the page
* @ param pos the area position to select */
public void setAreaPosition ( boolean relative , CmsPositionBean pos ) { } } | if ( pos == null ) { return ; } m_state = State . SELECTED ; showSelect ( true ) ; m_currentSelection = new CmsPositionBean ( ) ; m_firstX = pos . getLeft ( ) ; m_firstY = pos . getTop ( ) ; if ( ! relative ) { m_firstX -= getElement ( ) . getAbsoluteLeft ( ) ; m_firstY -= getElement ( ) . getAbsoluteTop ( ) ; } // set... |
public class CommerceNotificationTemplateLocalServiceUtil { /** * Returns the commerce notification template matching the UUID and group .
* @ param uuid the commerce notification template ' s UUID
* @ param groupId the primary key of the group
* @ return the matching commerce notification template , or < code > ... | return getService ( ) . fetchCommerceNotificationTemplateByUuidAndGroupId ( uuid , groupId ) ; |
public class HttpStreamWrapper { /** * Read data from the connection . If the request hasn ' t yet been sent
* to the server , send it . */
public int read ( byte [ ] buf , int offset , int length ) throws IOException { } } | if ( _stream != null ) return _stream . read ( buf , offset , length ) ; else return - 1 ; |
public class Annotation { /** * Serializes the object in a uniform matter for storage . Needed for
* successful CAS calls
* @ return The serialized object as a byte array */
@ VisibleForTesting byte [ ] getStorageJSON ( ) { } } | // TODO - precalculate size
final ByteArrayOutputStream output = new ByteArrayOutputStream ( ) ; try { final JsonGenerator json = JSON . getFactory ( ) . createGenerator ( output ) ; json . writeStartObject ( ) ; if ( tsuid != null && ! tsuid . isEmpty ( ) ) { json . writeStringField ( "tsuid" , tsuid ) ; } json . writ... |
public class Path { /** * Calculates the distance and time of the specified edgeId . Also it adds the edgeId to the path list .
* @ param prevEdgeId here the edge that comes before edgeId is necessary . I . e . for the reverse search we need the
* next edge . */
protected void processEdge ( int edgeId , int adjNode... | EdgeIteratorState iter = graph . getEdgeIteratorState ( edgeId , adjNode ) ; distance += iter . getDistance ( ) ; time += weighting . calcMillis ( iter , false , prevEdgeId ) ; addEdge ( edgeId ) ; |
public class InternalLogger { /** * Logs a caught exception with a custom text message .
* @ param level
* Severity level
* @ param message
* Plain text message
* @ param exception
* Caught exception */
public static void log ( final Level level , final Throwable exception , final String message ) { } } | String nameOfException = exception . getClass ( ) . getName ( ) ; String messageOfException = exception . getMessage ( ) ; StringBuilder builder = new StringBuilder ( BUFFER_SIZE ) ; builder . append ( level ) ; builder . append ( ": " ) ; builder . append ( message ) ; builder . append ( " (" ) ; builder . append ( na... |
public class ExceptionUtil { /** * Finds the root cause of a Throwable that occured . This routine will continue to
* look through chained Throwables until it cannot find another chained Throwable
* and return the last one in the chain as the root cause .
* @ param throwable must be a non - null reference of a Th... | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "findRootCause: " + throwable ) ; } Throwable root = throwable ; Throwable next = root ; while ( next != null ) { root = next ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "f... |
public class DefaultEndpoint { /** * Drain commands from a queue and return only active commands .
* @ param source the source queue .
* @ return List of commands . */
private static List < RedisCommand < ? , ? , ? > > drainCommands ( Queue < ? extends RedisCommand < ? , ? , ? > > source ) { } } | List < RedisCommand < ? , ? , ? > > target = new ArrayList < > ( source . size ( ) ) ; RedisCommand < ? , ? , ? > cmd ; while ( ( cmd = source . poll ( ) ) != null ) { if ( ! cmd . isDone ( ) ) { target . add ( cmd ) ; } } return target ; |
public class Parser { /** * < p > Parses the given resource and evaluates it with the given evaluator . Requires that the parse result in a single
* expression . < / p >
* @ param < O > the return type of the evaluator
* @ param resource the resource to evaluate
* @ param evaluator the evaluator to use for tran... | ExpressionIterator iterator = parse ( resource ) ; Expression expression = iterator . next ( ) ; if ( iterator . hasNext ( ) ) { throw new ParseException ( "Did not fully parse token stream" ) ; } try { return evaluator . eval ( expression ) ; } catch ( Exception e ) { throw new ParseException ( e ) ; } |
public class ExpressRouteCircuitConnectionsInner { /** * Creates or updates a Express Route Circuit Connection in the specified express route circuits .
* @ param resourceGroupName The name of the resource group .
* @ param circuitName The name of the express route circuit .
* @ param peeringName The name of the ... | return ServiceFuture . fromResponse ( beginCreateOrUpdateWithServiceResponseAsync ( resourceGroupName , circuitName , peeringName , connectionName , expressRouteCircuitConnectionParameters ) , serviceCallback ) ; |
public class PathManagerService { /** * Adds an entry for a path and sends an { @ link org . jboss . as . controller . services . path . PathManager . Event # ADDED }
* notification to any registered { @ linkplain org . jboss . as . controller . services . path . PathManager . Callback callbacks } .
* @ param pathN... | PathEntry pathEntry ; synchronized ( pathEntries ) { if ( pathEntries . containsKey ( pathName ) ) { throw ControllerLogger . ROOT_LOGGER . pathEntryAlreadyExists ( pathName ) ; } pathEntry = new PathEntry ( pathName , path , relativeTo , readOnly , relativeTo == null ? absoluteResolver : relativeResolver ) ; pathEntri... |
public class ListDocumentsRequest { /** * One or more filters . Use a filter to return a more specific list of results .
* @ param filters
* One or more filters . Use a filter to return a more specific list of results . */
public void setFilters ( java . util . Collection < DocumentKeyValuesFilter > filters ) { } } | if ( filters == null ) { this . filters = null ; return ; } this . filters = new com . amazonaws . internal . SdkInternalList < DocumentKeyValuesFilter > ( filters ) ; |
public class SummernoteKeyUpEvent { /** * Fires a summernote key up event on all registered handlers in the handler
* manager . If no such handlers exist , this method will do nothing .
* @ param source the source of the handlers
* @ param keyUpEvent native key up event */
public static void fire ( final HasSumme... | if ( TYPE != null ) { SummernoteKeyUpEvent event = new SummernoteKeyUpEvent ( nativeEvent ) ; source . fireEvent ( event ) ; } |
public class TextLoader { /** * Load a text from the specified reader and put it in the provided StringBuffer .
* @ param source source reader .
* @ param buffer buffer to load text into .
* @ return the buffer
* @ throws IOException if there is a problem to deal with . */
public StringBuffer append ( Reader so... | BufferedReader _bufferedReader = new BufferedReader ( source ) ; char [ ] _buffer = new char [ getBufferSize ( ) ] ; // load by chunk of 4 ko
try { for ( int _countReadChars = 0 ; _countReadChars >= 0 ; ) { buffer . append ( _buffer , 0 , _countReadChars ) ; _countReadChars = _bufferedReader . read ( _buffer ) ; } } fi... |
public class CPFriendlyURLEntryUtil { /** * Returns the first cp friendly url entry in the ordered set where groupId = & # 63 ; and classNameId = & # 63 ; and classPK = & # 63 ; .
* @ param groupId the group ID
* @ param classNameId the class name ID
* @ param classPK the class pk
* @ param orderByComparator th... | return getPersistence ( ) . fetchByG_C_C_First ( groupId , classNameId , classPK , orderByComparator ) ; |
public class CacheHashMap { /** * Loads all the session attributes .
* Copied from DatabaseHashMapMR . */
@ Trivial // return value contains customer data
@ FFDCIgnore ( Exception . class ) // manually logged
Object getAllValues ( BackedSession sess ) { } } | @ SuppressWarnings ( "static-access" ) final boolean hideValues = _smc . isHideSessionValues ( ) ; final boolean trace = TraceComponent . isAnyTracingEnabled ( ) ; if ( trace && tc . isEntryEnabled ( ) ) Tr . entry ( this , tc , "getAllValues" , sess ) ; String id = sess . getId ( ) ; long startTime = System . nanoTime... |
public class QueryController { /** * Get the current query as it is defined by the current { @ link QueryUIState } .
* @ return */
public DisplayedResultQuery getSearchQuery ( ) { } } | return QueryGenerator . displayed ( ) . query ( state . getAql ( ) . getValue ( ) ) . corpora ( state . getSelectedCorpora ( ) . getValue ( ) ) . left ( state . getLeftContext ( ) . getValue ( ) ) . right ( state . getRightContext ( ) . getValue ( ) ) . segmentation ( state . getContextSegmentation ( ) . getValue ( ) )... |
public class UtilImpl_InternMap { /** * Validate a string against a value type . Answer null if the string is
* valid . Answer a message ID describing the validation failure if the
* string is not valid for the value type .
* @ return Null for a valid value ; a non - null message ID for a non - valid value . */
@... | String vMsg = null ; switch ( valueType ) { case VT_CLASS_RESOURCE : if ( value . contains ( "\\" ) ) { vMsg = "ANNO_UTIL_UNEXPECTED_BACKSLASH" ; } else if ( ! value . endsWith ( ".class" ) ) { vMsg = "ANNO_UTIL_EXPECTED_CLASS" ; } break ; case VT_CLASS_REFERENCE : if ( value . contains ( "\\" ) ) { vMsg = "ANNO_UTIL_U... |
public class DBFUtils { /** * Test if the data in the array is pure ASCII
* @ param data data to check
* @ return true if there are only ASCII characters */
public static boolean isPureAscii ( byte [ ] data ) { } } | if ( data == null ) { return false ; } for ( byte b : data ) { if ( b < 0x20 ) { return false ; } } return true ; |
public class ModbusSlaveFactory { /** * Returns the running slave listening on the given serial port
* @ param port Port to check for running slave
* @ return Null or ModbusSlave */
public static ModbusSlave getSlave ( String port ) { } } | return ModbusUtil . isBlank ( port ) ? null : slaves . get ( port ) ; |
public class RPUtils { /** * Get the search candidates as indices given the input
* and similarity function
* @ param x the input data to search with
* @ param trees the trees to search
* @ param similarityFunction the function to use for similarity
* @ return the list of indices as the search results */
publ... | List < Integer > candidates = getCandidates ( x , trees , similarityFunction ) ; Collections . sort ( candidates ) ; int prevIdx = - 1 ; int idxCount = 0 ; List < Pair < Integer , Integer > > scores = new ArrayList < > ( ) ; for ( int i = 0 ; i < candidates . size ( ) ; i ++ ) { if ( candidates . get ( i ) == prevIdx )... |
public class DescribeImageBuildersRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( DescribeImageBuildersRequest describeImageBuildersRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( describeImageBuildersRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( describeImageBuildersRequest . getNames ( ) , NAMES_BINDING ) ; protocolMarshaller . marshall ( describeImageBuildersRequest . getMaxResults ( ) , MAXRESULT... |
public class ByteBuddy { /** * Creates a new { @ link Annotation } type . Annotation properties are implemented as non - static , public methods with the
* property type being defined as the return type .
* < b > Note < / b > : Byte Buddy does not cache previous subclasses but will attempt the generation of a new s... | return new SubclassDynamicTypeBuilder < Annotation > ( instrumentedTypeFactory . subclass ( namingStrategy . subclass ( TypeDescription . Generic . ANNOTATION ) , ModifierContributor . Resolver . of ( Visibility . PUBLIC , TypeManifestation . ANNOTATION ) . resolve ( ) , TypeDescription . Generic . OBJECT ) . withInter... |
public class NotificationManager { /** * Build the notification with the internal { @ link android . app . Notification . Builder }
* @ return notification ready to be displayed . */
private Notification buildNotification ( ) { } } | Notification notification = mNotificationBuilder . build ( ) ; if ( Build . VERSION . SDK_INT >= Build . VERSION_CODES . JELLY_BEAN ) { notification . bigContentView = mNotificationExpandedView ; } return notification ; |
public class ClassInfo { /** * Get ClassInfo by type .
* It search from cache , when failure build it and put it into cache . */
public static final ClassInfo get ( Class < ? > type ) { } } | ClassInfo exist = cache . get ( type ) ; if ( null != exist ) return exist ; synchronized ( cache ) { exist = cache . get ( type ) ; if ( null != exist ) return exist ; Set < MethodInfo > methods = CollectUtils . newHashSet ( ) ; Class < ? > nextClass = type ; int index = 0 ; Map < String , Class < ? > > nextParamTypes... |
public class BugsnagSpringConfiguration { /** * If using Logback , stop any configured appender from creating Bugsnag reports for Spring log
* messages as they effectively duplicate error reports for unhandled exceptions . */
@ PostConstruct @ SuppressWarnings ( "checkstyle:emptycatchblock" ) void excludeLoggers ( ) ... | try { // Exclude Tomcat logger when processing HTTP requests via a servlet .
// Regex specified to match the servlet variable parts of the logger name , e . g .
// the Spring Boot default is :
// [ Tomcat ] . [ localhost ] . [ / ] . [ dispatcherServlet ]
// but could be something like :
// [ Tomcat - 1 ] . [ 127.0.0.1 ... |
public class AvroUtils { /** * Given an avro Schema . Field instance , make a clone of it .
* @ param field
* The field to clone .
* @ return The cloned field . */
public static Field cloneField ( Field field ) { } } | return new Field ( field . name ( ) , field . schema ( ) , field . doc ( ) , field . defaultValue ( ) ) ; |
public class RepeatedRecordHandler { /** * { @ inheritDoc } */
@ Override public List < Record > signalShutdown ( ) { } } | List < Record > willReturn = new ArrayList < Record > ( ) ; flush ( current , willReturn ) ; return willReturn ; |
public class ManageTagsDialog { /** * This method initializes jPanel
* @ return javax . swing . JPanel */
private JPanel getJPanel ( ) { } } | if ( jPanel == null ) { GridBagConstraints gridBagConstraints00 = new GridBagConstraints ( ) ; GridBagConstraints gridBagConstraints10 = new GridBagConstraints ( ) ; GridBagConstraints gridBagConstraints11 = new GridBagConstraints ( ) ; GridBagConstraints gridBagConstraints20 = new GridBagConstraints ( ) ; GridBagConst... |
public class DeviceImpl { public AttributeConfig_2 [ ] get_attribute_config_2 ( final String [ ] names ) throws DevFailed , SystemException { } } | Util . out4 . println ( "Device_2Impl.get_attribute_config_2 arrived" ) ; // Allocate memory for the AttributeConfig structures
int nb_attr = names . length ; boolean all_attr = false ; // Record operation request in black box
blackbox . insert_op ( Op_Get_Attr_Config_2 ) ; // Get attribute number
final int nb_dev_attr... |
public class ElmBaseClinicalVisitor { /** * Visit a BinaryExpression . This method will be called for
* every node in the tree that is a BinaryExpression .
* @ param elm the ELM tree
* @ param context the context passed to the visitor
* @ return the visitor result */
@ Override public T visitBinaryExpression ( ... | if ( elm instanceof CalculateAgeAt ) return visitCalculateAgeAt ( ( CalculateAgeAt ) elm , context ) ; else return super . visitBinaryExpression ( elm , context ) ; |
public class ExecuteMethodValidatorChecker { public void checkLonelyValidatorAnnotation ( Field field , Map < String , Class < ? > > genericMap ) { } } | doCheckLonelyValidatorAnnotation ( field , deriveFieldType ( field , genericMap ) ) ; |
public class StreamingGeometryGenerator { /** * TODO add color ? ? */
int hash ( ByteBuffer indices , ByteBuffer vertices , ByteBuffer normals , ByteBuffer colors ) { } } | int hashCode = 0 ; hashCode += indices . hashCode ( ) ; hashCode += vertices . hashCode ( ) ; hashCode += normals . hashCode ( ) ; hashCode += colors . hashCode ( ) ; return hashCode ; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.