signature
stringlengths
43
39.1k
implementation
stringlengths
0
450k
public class Ifc4PackageImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ @ Override public EClass getIfcPipeFittingType ( ) { } }
if ( ifcPipeFittingTypeEClass == null ) { ifcPipeFittingTypeEClass = ( EClass ) EPackage . Registry . INSTANCE . getEPackage ( Ifc4Package . eNS_URI ) . getEClassifiers ( ) . get ( 420 ) ; } return ifcPipeFittingTypeEClass ;
public class CoreNaviRpcProcessor { /** * 验证appId和token是否有权限访问方法 * @ param desc * 方法描述 * @ param appId * appId * @ param token * token * @ return 是否有权限访问 */ private boolean isAuthoriedAccess ( MethodDescriptor < String > desc , String appId , String token ) { } }
if ( CollectionUtil . isNotEmpty ( desc . getAppIdTokens ( ) ) ) { for ( AppIdToken appIdToken : desc . getAppIdTokens ( ) ) { if ( AppIdToken . isValid ( appIdToken , appId , token ) ) { return true ; } } return false ; } return true ;
public class NaiveBayesModel { /** * Note : For small probabilities , product may end up zero due to underflow error . Can circumvent by taking logs . */ @ Override protected double [ ] score0 ( double [ ] data , double [ ] preds ) { } }
double [ ] nums = new double [ _output . _levels . length ] ; // log ( p ( x , y ) ) for all levels of y assert preds . length >= ( _output . _levels . length + 1 ) ; // Note : First column of preds is predicted response class // Compute joint probability of predictors for every response class for ( int rlevel = 0 ; rl...
public class AbstractContainerHelper { /** * Call this method to simulate what would happen if the UIContext was serialized due to clustering of servers . */ protected void cycleUIContext ( ) { } }
boolean cycleIt = ConfigurationProperties . getDeveloperClusterEmulation ( ) ; if ( cycleIt ) { UIContext uic = getUIContext ( ) ; if ( uic instanceof UIContextWrap ) { LOG . info ( "Cycling the UIContext to simulate clustering" ) ; ( ( UIContextWrap ) uic ) . cycle ( ) ; } }
public class CmsUserSelectionList { /** * Gets the sort key to use . < p > * @ param column the list column id * @ return the sort key */ protected SortKey getSortKey ( String column ) { } }
if ( column == null ) { return null ; } if ( column . equals ( LIST_COLUMN_FULLNAME ) ) { return SortKey . fullName ; } else if ( column . equals ( LIST_COLUMN_LOGIN ) ) { return SortKey . loginName ; } return null ;
public class AbstractCommandBuilder { /** * Adds the arguments to the collection of arguments that will be passed to the server ignoring any { @ code null } * arguments . * @ param args the arguments to add * @ return the builder */ public T addServerArguments ( final String ... args ) { } }
if ( args != null ) { for ( String arg : args ) { addServerArgument ( arg ) ; } } return getThis ( ) ;
public class CloseGuard { /** * If CloseGuard is enabled , { @ code open } initializes the instance * with a warning that the caller should have explicitly called the * { @ code closer } method instead of relying on finalization . * @ param closer non - null name of explicit termination method * @ throws NullPo...
// always perform the check for valid API usage . . . if ( closer == null ) { throw new NullPointerException ( "closer == null" ) ; } // . . . but avoid allocating an allocationSite if disabled if ( this == NOOP || ! ENABLED ) { return ; } String message = "Explicit termination method '" + closer + "' not called" ; all...
public class SolrIndexer { /** * To put events to subscriber queue * @ param oid * Object id * @ param eventType * type of events happened * @ param context * where the event happened * @ param jsonFile * Configuration file */ private void sendToIndex ( String message ) { } }
try { getMessaging ( ) . queueMessage ( SolrWrapperQueueConsumer . QUEUE_ID , message ) ; } catch ( MessagingException ex ) { log . error ( "Unable to send message: " , ex ) ; }
public class CmsObjectWrapper { /** * Locks a resource temporarily . < p > * @ param resourceName the name of the resource to lock * @ throws CmsException if something goes wrong */ public void lockResourceTemporary ( String resourceName ) throws CmsException { } }
boolean exec = false ; // iterate through all wrappers and call " lockResource " till one does not return false List < I_CmsResourceWrapper > wrappers = getWrappers ( ) ; for ( I_CmsResourceWrapper wrapper : wrappers ) { exec = wrapper . lockResource ( m_cms , resourceName , true ) ; if ( exec ) { break ; } } // delega...
public class MetaKeywords { /** * Get the current class for a meta tag keyword , as the first * and only element of an array list . */ protected List < String > getClassKeyword ( TypeElement typeElement ) { } }
ArrayList < String > metakeywords = new ArrayList < > ( 1 ) ; String cltypelower = config . utils . isInterface ( typeElement ) ? "interface" : "class" ; metakeywords . add ( config . utils . getFullyQualifiedName ( typeElement ) + " " + cltypelower ) ; return metakeywords ;
public class MinioClient { /** * Executes put object . If size of object data is < = 5MiB , single put object is used * else multipart put object is used . * @ param bucketName * Bucket name . * @ param objectName * Object name in the bucket . * @ param size * Size of object data . * @ param data * Ob...
boolean unknownSize = false ; // Add content type if not already set if ( headerMap . get ( "Content-Type" ) == null ) { headerMap . put ( "Content-Type" , "application/octet-stream" ) ; } if ( size == null ) { unknownSize = true ; size = MAX_OBJECT_SIZE ; } if ( size <= MIN_MULTIPART_SIZE ) { // Single put object . if...
public class Selector { /** * Helper method to transform the given arguments , consisting of the receiver * and the actual arguments in an Object [ ] , into a new Object [ ] consisting * of the receiver and the arguments directly . Before the size of args was * always 2 , the returned Object [ ] will have a size ...
if ( ! spreadCall ) return args ; Object [ ] normalArguments = ( Object [ ] ) args [ 1 ] ; Object [ ] ret = new Object [ normalArguments . length + 1 ] ; ret [ 0 ] = args [ 0 ] ; System . arraycopy ( normalArguments , 0 , ret , 1 , ret . length - 1 ) ; return ret ;
public class VaultNotificationConfig { /** * A list of one or more events for which Amazon Glacier will send a notification to the specified Amazon SNS topic . * @ param events * A list of one or more events for which Amazon Glacier will send a notification to the specified Amazon SNS * topic . */ public void set...
if ( events == null ) { this . events = null ; return ; } this . events = new java . util . ArrayList < String > ( events ) ;
public class KeyVaultClientBaseImpl { /** * Deletes the certificate contacts for a specified key vault . * Deletes the certificate contacts for a specified key vault certificate . This operation requires the certificates / managecontacts permission . * @ param vaultBaseUrl The vault name , for example https : / / m...
if ( vaultBaseUrl == null ) { throw new IllegalArgumentException ( "Parameter vaultBaseUrl is required and cannot be null." ) ; } if ( this . apiVersion ( ) == null ) { throw new IllegalArgumentException ( "Parameter this.apiVersion() is required and cannot be null." ) ; } String parameterizedHost = Joiner . on ( ", " ...
public class UEL { /** * Join expressions using the trigger character , if any ( { @ link # DEFAULT _ TRIGGER } if absent ) , of the first . * @ param expressions * @ return String */ public static String join ( final String ... expressions ) { } }
Validate . notEmpty ( expressions ) ; final char trigger = isDelimited ( expressions [ 0 ] ) ? getTrigger ( expressions [ 0 ] ) : DEFAULT_TRIGGER ; return join ( trigger , expressions ) ;
public class DetectorsExtensionHelper { /** * key is the plugin id , value is the plugin library path */ public static synchronized SortedMap < String , String > getContributedDetectors ( ) { } }
if ( contributedDetectors != null ) { return new TreeMap < > ( contributedDetectors ) ; } TreeMap < String , String > set = new TreeMap < > ( ) ; IExtensionRegistry registry = Platform . getExtensionRegistry ( ) ; for ( IConfigurationElement configElt : registry . getConfigurationElementsFor ( EXTENSION_POINT_ID ) ) { ...
public class Configuration { /** * Get the value of the < code > name < / code > property as a < code > Pattern < / code > . * If no such property is specified , or if the specified value is not a valid * < code > Pattern < / code > , then an exception is thrown . * @ param name property name * @ throws NullPoi...
String valString = get ( name ) ; Preconditions . checkNotNull ( valString ) ; return Pattern . compile ( valString ) ;
public class Duration { /** * Add the supplied duration to this duration , and return the result . * @ param duration the duration to add to this object * @ param unit the unit of the duration being added ; may not be null * @ return the total duration */ public Duration add ( long duration , TimeUnit unit ) { } ...
long durationInNanos = TimeUnit . NANOSECONDS . convert ( duration , unit ) ; return new Duration ( this . durationInNanos + durationInNanos ) ;
public class Elements { /** * Get the elements in the array that are at the indexes . * @ since 1.4.0 */ public static < T > T [ ] slice ( T [ ] array , int ... indexes ) { } }
int length = indexes . length ; T [ ] slice = ObjectArrays . newArray ( array , length ) ; for ( int i = 0 ; i < length ; i ++ ) { slice [ i ] = array [ indexes [ i ] ] ; } return slice ;
public class CommerceCurrencyPersistenceImpl { /** * Removes all the commerce currencies where groupId = & # 63 ; and primary = & # 63 ; from the database . * @ param groupId the group ID * @ param primary the primary */ @ Override public void removeByG_P ( long groupId , boolean primary ) { } }
for ( CommerceCurrency commerceCurrency : findByG_P ( groupId , primary , QueryUtil . ALL_POS , QueryUtil . ALL_POS , null ) ) { remove ( commerceCurrency ) ; }
public class LBiObjLongFunctionBuilder { /** * One of ways of creating builder . This is possibly the least verbose way where compiler should be able to guess the generic parameters . */ @ Nonnull public static < T1 , T2 , R > LBiObjLongFunction < T1 , T2 , R > biObjLongFunctionFrom ( Consumer < LBiObjLongFunctionBuild...
LBiObjLongFunctionBuilder builder = new LBiObjLongFunctionBuilder ( ) ; buildingFunction . accept ( builder ) ; return builder . build ( ) ;
public class RequestProgressManager { /** * Disable request listeners notifications for a specific request . < br / > * All listeners associated to this request won ' t be called when request * will finish . < br / > * @ param request * Request on which you want to disable listeners * @ param listRequestListe...
final Set < RequestListener < ? > > setRequestListener = mapRequestToRequestListener . get ( request ) ; requestListenerNotifier . clearNotificationsForRequest ( request , setRequestListener ) ; if ( setRequestListener != null && listRequestListener != null ) { Ln . d ( "Removing listeners of request : " + request . to...
public class TypeScriptCompilerMojo { /** * Process all typescripts file from the given directory . Output files are generated in the given destination . * @ param input the input directory * @ param destination the output directory * @ throws WatchingException if the compilation failed */ protected void processD...
if ( ! input . isDirectory ( ) ) { return ; } if ( ! destination . isDirectory ( ) ) { destination . mkdirs ( ) ; } // Now execute the compiler // We compute the set of argument according to the Mojo ' s configuration . try { Collection < File > files = FileUtils . listFiles ( input , new String [ ] { "ts" } , true ) ;...
public class Replication { /** * Set OAuth 1 authentication credentials for the replication target * @ param consumerSecret client secret * @ param consumerKey client identifier * @ param tokenSecret OAuth server token secret * @ param token OAuth server issued token * @ return this Replication instance to se...
this . replication = replication . targetOauth ( consumerSecret , consumerKey , tokenSecret , token ) ; return this ;
public class ConcurrentServiceReferenceMap { /** * Iterate over all services in the map in no specific order . The iterator * will return the service associated with each ServiceReference as it progresses . * Creation of the iterator does not eagerly resolve services : resolution * is done only once per service r...
final List < V > empty = Collections . emptyList ( ) ; if ( context == null ) { return empty . iterator ( ) ; } return new ValueIterator ( elementMap . values ( ) . iterator ( ) ) ;
public class PackagedProgram { /** * Takes all JAR files that are contained in this program ' s JAR file and extracts them * to the system ' s temp directory . * @ return The file names of the extracted temporary files . * @ throws ProgramInvocationException Thrown , if the extraction process failed . */ public s...
Random rnd = new Random ( ) ; JarFile jar = null ; try { jar = new JarFile ( new File ( jarFile . toURI ( ) ) ) ; final List < JarEntry > containedJarFileEntries = new ArrayList < JarEntry > ( ) ; Enumeration < JarEntry > entries = jar . entries ( ) ; while ( entries . hasMoreElements ( ) ) { JarEntry entry = entries ....
public class BELDataHeaderParser { /** * Parse the BEL Data header { @ link File } to a { @ link Map } of block name * to block properties held in a { @ link Properties } object . * @ param belDataFile { @ link File } , the BEL data document file to parse * @ return { @ link Map } of { @ link String } to { @ link...
RandomAccessFile raf = null ; try { raf = new RandomAccessFile ( belDataFile , "r" ) ; Map < String , Properties > blockProperties = new LinkedHashMap < String , Properties > ( ) ; String line ; String currentBlock = null ; boolean aborted = false ; while ( ! aborted && ( line = raf . readLine ( ) ) != null ) { line = ...
public class BasicDao { /** * Updates entry / entries of table by provided values & amp ; conditions * @ param tableName table name to update values of * @ param entry entry to update by * @ param entryMapper a mapper between the the value object to the map key * @ param idMapper a mapper between the condition ...
return execute ( createUpdateCommand ( tableName , entry , entryMapper , idMapper ) ) ;
public class ConfigurationInfo { /** * Used to query items of all configuration types . May be useful to build configuration tree ( e . g . to search * all items configured by bundle or by classpath scan ) . Some common filters are * predefined in { @ link Filters } . Use { @ link Predicate # and ( Predicate ) } , ...
final List < Class < Object > > items = ( List ) Lists . newArrayList ( itemsHolder . values ( ) ) ; return filter ( items , filter ) ;
public class CmsDefaultXmlContentHandler { /** * Initializes the layout for this content handler . < p > * Unless otherwise instructed , the editor uses one specific GUI widget for each * XML value schema type . For example , for a { @ link org . opencms . xml . types . CmsXmlStringValue } * the default widget is...
m_useAcacia = safeParseBoolean ( root . attributeValue ( ATTR_USE_ACACIA ) , true ) ; Iterator < Element > i = CmsXmlGenericWrapper . elementIterator ( root , APPINFO_LAYOUT ) ; while ( i . hasNext ( ) ) { // iterate all " layout " elements in the " layouts " node Element element = i . next ( ) ; String elementName = e...
public class C4BlobStore { /** * Opens a blob for reading , as a random - access byte stream . */ public C4BlobReadStream openReadStream ( C4BlobKey blobKey ) throws LiteCoreException { } }
return new C4BlobReadStream ( openReadStream ( handle , blobKey . getHandle ( ) ) ) ;
public class NFVORequestor { /** * Returns a UserAgent with which requests regarding Users can be sent to the NFVO . * @ return a UserAgent */ public synchronized UserAgent getUserAgent ( ) { } }
if ( this . userAgent == null ) { if ( isService ) { this . userAgent = new UserAgent ( this . serviceName , this . projectId , this . sslEnabled , this . nfvoIp , this . nfvoPort , this . version , this . serviceKey ) ; } else { this . userAgent = new UserAgent ( this . username , this . password , this . projectId , ...
public class JaxRxResource { /** * This method will be called when a HTTP client sends a POST request to an * existing resource with ' application / query + xml ' as Content - Type . * @ param system * The implementation system . * @ param input * The input stream . * @ param headers * HTTP header attribu...
return postQuery ( system , input , "" , headers ) ;
public class FlyWeightFlatXmlProducer { /** * merges the existing columns with the potentially new ones . * @ param columnsToMerge List of extra columns found , which need to be merge back into the metadata . * @ return ITableMetaData The merged metadata object containing the new columns * @ throws DataSetExcepti...
Column [ ] columns = new Column [ originalMetaData . getColumns ( ) . length + columnsToMerge . size ( ) ] ; System . arraycopy ( originalMetaData . getColumns ( ) , 0 , columns , 0 , originalMetaData . getColumns ( ) . length ) ; for ( int i = 0 ; i < columnsToMerge . size ( ) ; i ++ ) { Column column = columnsToMerge...
public class StorageUtil { /** * reads a XML Element Attribute ans cast it to a DateTime Object * @ param config * @ param el XML Element to read Attribute from it * @ param attributeName Name of the Attribute to read * @ return Attribute Value */ public DateTime toDateTime ( Config config , Element el , String...
String str = el . getAttribute ( attributeName ) ; if ( str == null ) return null ; return DateCaster . toDateAdvanced ( str , ThreadLocalPageContext . getTimeZone ( config ) , null ) ;
public class Cob2JaxbConverter { /** * Convert host data to a JAXB instance . * @ param hostData the buffer of host data * @ param start where to start in the buffer of host data * @ param length How many bytes of hostData contains actual data to process * @ return a result object containing the JAXB instance c...
Cob2JaxbVisitor visitor = new Cob2JaxbVisitor ( getCobolContext ( ) , hostData , start , length , jaxbWrapperFactory ) ; visitor . visit ( getCobolComplexType ( ) ) ; JaxbWrapper < ? > jaxbWrapper = visitor . getLastObject ( JaxbWrapper . class ) ; return new FromHostResult < J > ( visitor . getLastPos ( ) , jaxbClass ...
public class KnowledgeOperations { /** * Gets an input - output map . * @ param message the message * @ param operation the operation * @ param runtime the runtime engine * @ return the input - output map */ public static Map < String , Object > getInputOutputMap ( Message message , KnowledgeOperation operation...
Map < String , Object > map = new LinkedHashMap < String , Object > ( ) ; Map < String , ExpressionMapping > inputs = operation . getInputOutputExpressionMappings ( ) ; for ( Entry < String , ExpressionMapping > entry : inputs . entrySet ( ) ) { List < Object > list = getList ( message , Collections . singletonList ( e...
public class SingleLockedMessageEnumerationImpl { /** * / * ( non - Javadoc ) * @ see com . ibm . wsspi . sib . core . LockedMessageEnumeration # getConsumerSession ( ) */ public ConsumerSession getConsumerSession ( ) throws SISessionUnavailableException , SISessionDroppedException , SIIncorrectCallException { } }
if ( TraceComponent . isAnyTracingEnabled ( ) && CoreSPILockedMessageEnumeration . tc . isEntryEnabled ( ) ) SibTr . entry ( CoreSPILockedMessageEnumeration . tc , "getConsumerSession" , this ) ; checkValidState ( "getConsumerSession" ) ; _localConsumerPoint . checkNotClosed ( ) ; if ( TraceComponent . isAnyTracingEnab...
public class LoadBalancerContext { /** * Derive the host and port from virtual address if virtual address is indeed contains the actual host * and port of the server . This is the final resort to compute the final URI in { @ link # getServerFromLoadBalancer ( java . net . URI , Object ) } * if there is no load bala...
Pair < String , Integer > hostAndPort = new Pair < String , Integer > ( null , - 1 ) ; URI uri = new URI ( vipAddress ) ; String scheme = uri . getScheme ( ) ; if ( scheme == null ) { uri = new URI ( "http://" + vipAddress ) ; } String host = uri . getHost ( ) ; if ( host == null ) { throw new ClientException ( "Unable...
public class CmsMessageBundleEditorModel { /** * Creates all propertyvfsbundle files for the currently loaded translations . * The method is used to convert xmlvfsbundle files into propertyvfsbundle files . * @ throws CmsIllegalArgumentException thrown if resource creation fails . * @ throws CmsLoaderException th...
String bundleFileBasePath = m_sitepath + m_basename + "_" ; for ( Locale l : m_localizations . keySet ( ) ) { CmsResource res = m_cms . createResource ( bundleFileBasePath + l . toString ( ) , OpenCms . getResourceManager ( ) . getResourceType ( CmsMessageBundleEditorTypes . BundleType . PROPERTY . toString ( ) ) ) ; m...
public class HeapAlphaSketch { /** * Computes whether there have been 0 , 1 , or 2 or more actual insertions into the cache in a * numerically safe way . * @ param theta < a href = " { @ docRoot } / resources / dictionary . html # theta " > See Theta < / a > . * @ param alpha internal computed value alpha . * @...
final double split1 = ( p * ( alpha + 1.0 ) ) / 2.0 ; if ( theta > split1 ) { return 0 ; } if ( theta > ( alpha * split1 ) ) { return 1 ; } return 2 ;
public class Graph { /** * Print readable circular graph * @ throws CircularDependenciesException */ private void throwCircularDependenciesException ( ) throws CircularDependenciesException { } }
String msg = "Circular dependencies found. Check the circular graph below:\n" ; boolean firstNode = true ; String tab = " " ; for ( String visit : visitedInjectNodes ) { if ( ! firstNode ) { msg += tab + "->" ; tab += tab ; } msg += visit + "\n" ; firstNode = false ; } msg += tab . substring ( 2 ) + "->" + revisitedNo...
public class AliasSensitiveX509KeyManager { /** * / * ( non - Javadoc ) * @ see javax . net . ssl . X509KeyManager # chooseClientAlias ( java . lang . String [ ] , java . security . Principal [ ] , java . net . Socket ) */ public String chooseClientAlias ( String [ ] keyType , Principal [ ] issuers , Socket socket ) ...
// If not security domain is available , or the preferred alias is NULL , // then default to the nested key manager ' s process for selecting the keystore if ( null == domain || domain . getPreferredKeyAlias ( ) == null ) { if ( LOGGER . isInfoEnabled ( ) ) { LOGGER . info ( "No preferred key alias defined. Defaulting...
public class FromCobolVisitor { /** * Visit a primitive type performing the actual conversion to a java object . * If there is an extra offset left over by a previous item , adjust the * position accordingly . * @ param type the primitive type * @ param callback a function that is invoked after the primitive ty...
if ( extraOffset > 0 ) { lastPos += extraOffset ; extraOffset = 0 ; } if ( lastPos >= length ) { if ( isDebugEnabled ) { log . debug ( getCurFieldFullCobolName ( ) + " past maximum length" ) ; } return ; } cobolNamesStack . push ( type . getCobolName ( ) ) ; callback . preVisit ( type ) ; FromHostPrimitiveResult < ? > ...
public class ResponseBuilder { /** * Adds a Dialog { @ link ElicitSlotDirective } to the response . * @ param slotName name of slot to elicit * @ param updatedIntent updated intent * @ return response builder */ public ResponseBuilder addElicitSlotDirective ( String slotName , Intent updatedIntent ) { } }
ElicitSlotDirective elicitSlotDirective = ElicitSlotDirective . builder ( ) . withUpdatedIntent ( updatedIntent ) . withSlotToElicit ( slotName ) . build ( ) ; return addDirective ( elicitSlotDirective ) ;
public class AsyncMutateInBuilder { /** * Insert a fragment , replacing the old value if the path exists . * @ param path the path where to insert ( or replace ) a dictionary value . * @ param fragment the new dictionary value to be applied . */ public < T > AsyncMutateInBuilder upsert ( String path , T fragment ) ...
if ( StringUtil . isNullOrEmpty ( path ) ) { throw new IllegalArgumentException ( "Path must not be empty for upsert" ) ; } this . mutationSpecs . add ( new MutationSpec ( Mutation . DICT_UPSERT , path , fragment ) ) ; return this ;
public class SipSession { /** * This basic method sends out a request message as part of a transaction . A test program should * use this method when a response to a request is expected . A Request object is constructed from * the string passed in . * This method returns when the request message has been sent out...
Request request = parent . getMessageFactory ( ) . createRequest ( reqMessage ) ; return sendRequestWithTransaction ( request , viaProxy , dialog ) ;
public class IteratedGatheringModelProcessable { /** * Creates , from the iterated object ( e . g . right part of a th : each expression ) , the iterator that will be used . */ private static Iterator < ? > computeIteratedObjectIterator ( final Object iteratedObject ) { } }
if ( iteratedObject == null ) { return Collections . EMPTY_LIST . iterator ( ) ; } if ( iteratedObject instanceof Collection < ? > ) { return ( ( Collection < ? > ) iteratedObject ) . iterator ( ) ; } if ( iteratedObject instanceof Map < ? , ? > ) { return ( ( Map < ? , ? > ) iteratedObject ) . entrySet ( ) . iterator ...
public class FreeTextSearch { /** * Search in the specified index for nodes matching the the given value . * Any indexed property is searched . * @ param index The name of the index to search in . * @ param query The query specifying what to search for . * @ param maxNumberOfresults maximum number of results to...
if ( ! db . index ( ) . existsForNodes ( index ) ) { return Stream . empty ( ) ; } QueryContext queryParam = new QueryContext ( parseFreeTextQuery ( query ) ) . sort ( Sort . RELEVANCE ) ; if ( maxNumberOfresults != - 1 ) { queryParam = queryParam . top ( ( int ) maxNumberOfresults ) ; } return toWeightedNodeResult ( d...
public class DownloadChemCompProvider { /** * Get this provider ' s cache path * @ return */ public static File getPath ( ) { } }
if ( path == null ) { UserConfiguration config = new UserConfiguration ( ) ; path = new File ( config . getCacheFilePath ( ) ) ; } return path ;
public class ListUtil { /** * finds a value inside a list , ignore case , ignore empty items * @ param list list to search * @ param value value to find * @ param delimiter delimiter of the list * @ return position in list or 0 */ public static int listFindNoCaseIgnoreEmpty ( String list , String value , char d...
if ( list == null ) return - 1 ; int len = list . length ( ) ; if ( len == 0 ) return - 1 ; int last = 0 ; int count = 0 ; for ( int i = 0 ; i < len ; i ++ ) { if ( list . charAt ( i ) == delimiter ) { if ( last < i ) { if ( list . substring ( last , i ) . equalsIgnoreCase ( value ) ) return count ; count ++ ; } last =...
public class SparseWeightedDirectedTypedEdgeSet { /** * { @ inheritDoc } */ public boolean connects ( int vertex , T type ) { } }
if ( inEdges . containsKey ( vertex ) ) { for ( WeightedDirectedTypedEdge < T > e : inEdges . get ( vertex ) ) { if ( e . edgeType ( ) . equals ( type ) ) return true ; } } else if ( outEdges . containsKey ( vertex ) ) { for ( WeightedDirectedTypedEdge < T > e : outEdges . get ( vertex ) ) { if ( e . edgeType ( ) . equ...
public class Watch { /** * Applies the mutations in changeMap to the document tree . Modified ' documentSet ' in - place and * returns the changed documents . * @ param readTime The time at which this snapshot was obtained . */ private List < DocumentChange > computeSnapshot ( Timestamp readTime ) { } }
List < DocumentChange > appliedChanges = new ArrayList < > ( ) ; ChangeSet changeSet = extractChanges ( readTime ) ; // Process the sorted changes in the order that is expected by our clients ( removals , additions , // and then modifications ) . We also need to sort the individual changes to assure that // oldIndex / ...
public class BenchmarkMatrixMultAccessors { /** * Only sets and gets that are by row and column are used . */ public static long access2d ( DMatrixRMaj a , DMatrixRMaj b , DMatrixRMaj c ) { } }
long timeBefore = System . currentTimeMillis ( ) ; for ( int i = 0 ; i < a . numRows ; i ++ ) { for ( int j = 0 ; j < b . numCols ; j ++ ) { c . set ( i , j , a . get ( i , 0 ) * b . get ( 0 , j ) ) ; } for ( int k = 1 ; k < b . numRows ; k ++ ) { for ( int j = 0 ; j < b . numCols ; j ++ ) { // c . set ( i , j , c . ge...
public class CmsObject { /** * Writes a resource to the OpenCms VFS , including it ' s content . < p > * Applies only to resources of type < code > { @ link CmsFile } < / code > * i . e . resources that have a binary content attached . < p > * Certain resource types might apply content validation or transformatio...
return getResourceType ( resource ) . writeFile ( this , m_securityManager , resource ) ;
public class ISUPMessageFactoryImpl { /** * ( non - Javadoc ) * @ see org . restcomm . protocols . ss7 . isup . ISUPMessageFactory # createACM ( int ) */ @ Override public AddressCompleteMessage createACM ( int cic ) { } }
AddressCompleteMessage acm = createACM ( ) ; CircuitIdentificationCode code = this . parameterFactory . createCircuitIdentificationCode ( ) ; code . setCIC ( cic ) ; acm . setCircuitIdentificationCode ( code ) ; return acm ;
public class AbstractParamDialog { /** * This method initializes jSplitPane * @ return javax . swing . JSplitPane */ private AbstractParamContainerPanel getJSplitPane ( ) { } }
if ( jSplitPane == null ) { jSplitPane = new AbstractParamContainerPanel ( ) ; jSplitPane . setVisible ( true ) ; if ( this . rootName != null ) { jSplitPane . getRootNode ( ) . setUserObject ( rootName ) ; } } return jSplitPane ;
public class DataSet { /** * Groups a { @ link DataSet } using a { @ link KeySelector } function . * The KeySelector function is called for each element of the DataSet and extracts a single * key value on which the DataSet is grouped . < / br > * This method returns an { @ link UnsortedGrouping } on which one of ...
return new UnsortedGrouping < T > ( this , new Keys . SelectorFunctionKeys < T , K > ( keyExtractor , getType ( ) ) ) ;
public class VariableTranslator { /** * If pkg is null then will use any available bundle to provide the translator . */ public static boolean isDocumentReferenceVariable ( Package pkg , String type ) { } }
com . centurylink . mdw . variable . VariableTranslator trans = getTranslator ( pkg , type ) ; return ( trans instanceof DocumentReferenceTranslator ) ;
public class ByteSequence { /** * Compares this byte sequence to another . * @ param obs byte sequence to compare * @ return comparison result * @ see # compareBytes ( ByteSequence , ByteSequence ) */ public int compareTo ( ByteSequence obs ) { } }
if ( isBackedByArray ( ) && obs . isBackedByArray ( ) ) { return WritableComparator . compareBytes ( getBackingArray ( ) , offset ( ) , length ( ) , obs . getBackingArray ( ) , obs . offset ( ) , obs . length ( ) ) ; } return compareBytes ( this , obs ) ;
public class ClassWriterImpl { /** * { @ inheritDoc } */ @ Override public void addClassSignature ( String modifiers , Content classInfoTree ) { } }
classInfoTree . addContent ( new HtmlTree ( HtmlTag . BR ) ) ; Content pre = new HtmlTree ( HtmlTag . PRE ) ; addAnnotationInfo ( typeElement , pre ) ; pre . addContent ( modifiers ) ; LinkInfoImpl linkInfo = new LinkInfoImpl ( configuration , LinkInfoImpl . Kind . CLASS_SIGNATURE , typeElement ) ; // Let ' s not link ...
public class DeleteCodeRepositoryRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( DeleteCodeRepositoryRequest deleteCodeRepositoryRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( deleteCodeRepositoryRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( deleteCodeRepositoryRequest . getCodeRepositoryName ( ) , CODEREPOSITORYNAME_BINDING ) ; } catch ( Exception e ) { throw new SdkClientException ( "Unable to ...
public class CSSNumberHelper { /** * Try to find the unit that is used in the specified values . This check is * done using " endsWith " so you have to make sure , that no trailing spaces are * contained in the passed value . This check includes a check for percentage * values ( e . g . < code > 10 % < / code > )...
ValueEnforcer . notNull ( sCSSValue , "CSSValue" ) ; // Search units , the ones with the longest names come first return s_aNameToUnitMap . findFirstValue ( aEntry -> sCSSValue . endsWith ( aEntry . getKey ( ) ) ) ;
public class Provider { /** * Remove a service previously added using * { @ link # putService putService ( ) } . The specified service is removed from * this provider . It will no longer be returned by * { @ link # getService getService ( ) } and its information will be removed * from this provider ' s Hashtabl...
check ( "removeProviderProperty." + name ) ; // if ( debug ! = null ) { // debug . println ( name + " . removeService ( ) : " + s ) ; if ( s == null ) { throw new NullPointerException ( ) ; } implRemoveService ( s ) ;
public class SchemaBuilder { /** * Shortcut for { @ link # createMaterializedView ( CqlIdentifier ) * createMaterializedView ( CqlIdentifier . fromCql ( viewName ) } */ @ NonNull public static CreateMaterializedViewStart createMaterializedView ( @ NonNull String viewName ) { } }
return createMaterializedView ( CqlIdentifier . fromCql ( viewName ) ) ;
public class SeaGlassLookAndFeel { /** * Initialize the progress bar settings . * @ param d the UI defaults map . */ private void defineProgressBars ( UIDefaults d ) { } }
// Copied from nimbus // Initialize ProgressBar d . put ( "ProgressBar.contentMargins" , new InsetsUIResource ( 0 , 0 , 0 , 0 ) ) ; d . put ( "ProgressBar.States" , "Enabled,Disabled,Indeterminate,Finished" ) ; d . put ( "ProgressBar.tileWhenIndeterminate" , Boolean . TRUE ) ; d . put ( "ProgressBar.paintOutsideClip" ,...
public class Flow { /** * Returns the Flow instance for the { @ link Activity } that owns the given context . * Note that it is not safe to call this method before the first call to that * Activity ' s { @ link Activity # onResume ( ) } method in the current Android task . In practice * this boils down to two rul...
Flow flow = InternalContextWrapper . getFlow ( context ) ; if ( null == flow ) { throw new IllegalStateException ( "Context was not wrapped with flow. " + "Make sure attachBaseContext was overridden in your main activity" ) ; } return flow ;
public class ByteArrayBuffer { /** * Ensures that the capacity is at least equal to the specified minimum . * If the current capacity is less than the argument , then a new internal * array is allocated with greater capacity . If the { @ code required } * argument is non - positive , this method takes no action ....
if ( required <= 0 ) { return ; } final int available = this . array . length - this . len ; if ( required > available ) { expand ( this . len + required ) ; }
public class FileSystem { /** * The src file is under FS , and the dst is on the local disk . * Copy it from FS control to the local dst name . * Remove the source afterwards */ public void moveToLocalFile ( Path src , Path dst ) throws IOException { } }
copyToLocalFile ( true , false , src , dst ) ;
public class TimingInfo { /** * Returns a { @ link TimingInfoFullSupport } based on the given * start time since epoch in millisecond , * and the given start and end time in nanosecond . * @ param startEpochTimeMilli start time since epoch in millisecond * @ param startTimeNano start time in nanosecond * @ pa...
return new TimingInfoFullSupport ( Long . valueOf ( startEpochTimeMilli ) , startTimeNano , Long . valueOf ( endTimeNano ) ) ;
public class NDArrayFragmentHandler { /** * Callback for handling * fragments of data being read from a log . * @ param buffer containing the data . * @ param offset at which the data begins . * @ param length of the data in bytes . * @ param header representing the meta data for the data . */ @ Override publ...
ByteBuffer byteBuffer = buffer . byteBuffer ( ) ; boolean byteArrayInput = false ; if ( byteBuffer == null ) { byteArrayInput = true ; byte [ ] destination = new byte [ length ] ; ByteBuffer wrap = ByteBuffer . wrap ( buffer . byteArray ( ) ) ; wrap . get ( destination , offset , length ) ; byteBuffer = ByteBuffer . wr...
public class CodecInfo { /** * Gets the next doc . * @ param field * the field * @ param previousDocId * the previous doc id * @ return the next doc */ public IndexDoc getNextDoc ( String field , int previousDocId ) { } }
if ( fieldReferences . containsKey ( field ) ) { FieldReferences fr = fieldReferences . get ( field ) ; try { if ( previousDocId < 0 ) { return new IndexDoc ( fr . refIndexDoc ) ; } else { int nextDocId = previousDocId + 1 ; IndexInput inIndexDocId = indexInputList . get ( "indexDocId" ) ; ArrayList < MtasTreeHit < ? >...
public class FileService { /** * returns the list of files found in a folder . Does not return hidden files * , unreadable , folder ' . git ' * @ param sourceFolder * the source folder to search content * @ param baseFile * sub directory from source folder * @ return file set */ private static Set < String ...
Set < String > retval = new HashSet < String > ( ) ; if ( ! sourceFolder . exists ( ) || sourceFolder . isHidden ( ) || ! sourceFolder . isDirectory ( ) || ! sourceFolder . canRead ( ) || isGitMetaDataFolder ( sourceFolder ) ) { return retval ; } for ( File file : sourceFolder . listFiles ( ) ) { if ( file . isDirector...
public class JdbcRepositories { /** * Initializes the repository definitions . * @ throws JSONException JSONException */ private static void initRepositoryDefinitions ( ) throws JSONException { } }
final JSONObject jsonObject = Repositories . getRepositoriesDescription ( ) ; if ( null == jsonObject ) { LOGGER . warn ( "Loads repository description [repository.json] failed" ) ; return ; } repositoryDefinitions = new ArrayList < > ( ) ; final JSONArray repositoritArray = jsonObject . getJSONArray ( REPOSITORIES ) ;...
public class Mixin { /** * Creates a method lookup that is capable of accessing private members of declaring classes this Mixin factory has * usually no access to . * @ param declaringClass * @ return * @ throws NoSuchMethodException * @ throws IllegalAccessException * @ throws InvocationTargetException *...
try { final Constructor < MethodHandles . Lookup > constructor = MethodHandles . Lookup . class . getDeclaredConstructor ( Class . class , int . class ) ; constructor . setAccessible ( true ) ; return constructor . newInstance ( declaringClass , MethodHandles . Lookup . PRIVATE ) ; } catch ( NoSuchMethodException | Inv...
public class IncludeTag { /** * This is the method called when the JSP interpreter first hits the tag * associated with this class . This method will firstly determine whether * the page referenced by the { @ code page } attribute exists . If the * page doesn ' t exist , this method will throw a { @ code JspExcep...
oldParameters = new HashMap < String , Object > ( ) ; parameterNames = new ArrayList < String > ( ) ; return EVAL_BODY_INCLUDE ;
public class CompactionJobConfigurator { /** * Converts a top level input path to a group of sub - paths according to user defined granularity . * This may be required because if upstream application generates many sub - paths but the map - reduce * job only keeps track of the top level path , after the job is done...
boolean appendDelta = this . state . getPropAsBoolean ( MRCompactor . COMPACTION_RENAME_SOURCE_DIR_ENABLED , MRCompactor . DEFAULT_COMPACTION_RENAME_SOURCE_DIR_ENABLED ) ; Set < Path > uncompacted = Sets . newHashSet ( ) ; Set < Path > total = Sets . newHashSet ( ) ; for ( FileStatus fileStatus : FileListUtils . listFi...
public class StatementManager { /** * return a generic Statement for the given ClassDescriptor . * Never use this method for UPDATE / INSERT / DELETE if you want to use the batch mode . */ public Statement getGenericStatement ( ClassDescriptor cds , boolean scrollable ) throws PersistenceBrokerException { } }
try { return cds . getStatementsForClass ( m_conMan ) . getGenericStmt ( m_conMan . getConnection ( ) , scrollable ) ; } catch ( LookupException e ) { throw new PersistenceBrokerException ( "Used ConnectionManager instance could not obtain a connection" , e ) ; }
public class DatatypeConverter { /** * Print a date time value . * @ param value date time value * @ return string representation */ public static final String printDateTime ( Date value ) { } }
return ( value == null ? null : DATE_FORMAT . get ( ) . format ( value ) ) ;
public class DefaultAliasedCumulatives { /** * Get the generated constraints . * @ return a list of constraint that may be empty . */ @ Override public boolean beforeSolve ( ReconfigurationProblem r ) { } }
super . beforeSolve ( r ) ; for ( int i = 0 ; i < aliases . size ( ) ; i ++ ) { int capa = capacities . get ( i ) ; int [ ] alias = aliases . get ( i ) ; int [ ] cUse = cUsages . get ( i ) ; int [ ] dUses = new int [ dUsages . get ( i ) . length ] ; for ( IntVar dUseDim : dUsages . get ( i ) ) { dUses [ i ++ ] = dUseDi...
public class CmsUserDataDialog { /** * Submits the dialog . < p > */ void submit ( ) { } }
try { // Special user info attributes may have been set since the time the dialog was instantiated , // and we don ' t want to overwrite them , so we read the user again . m_user = m_context . getCms ( ) . readUser ( m_user . getId ( ) ) ; m_form . submit ( m_user , m_context . getCms ( ) , new Runnable ( ) { public vo...
public class UserPreferences { /** * Enable or disable all known Detectors . * @ param enable * true if all detectors should be enabled , false if they should * all be disabled */ public void enableAllDetectors ( boolean enable ) { } }
detectorEnablementMap . clear ( ) ; Collection < Plugin > allPlugins = Plugin . getAllPlugins ( ) ; for ( Plugin plugin : allPlugins ) { for ( DetectorFactory factory : plugin . getDetectorFactories ( ) ) { detectorEnablementMap . put ( factory . getShortName ( ) , enable ) ; } }
public class AWSCognitoIdentityProviderClient { /** * Gets the user attributes and metadata for a user . * @ param getUserRequest * Represents the request to get information about the user . * @ return Result of the GetUser operation returned by the service . * @ throws ResourceNotFoundException * This except...
request = beforeClientExecution ( request ) ; return executeGetUser ( request ) ;
public class AbstractUnitConverter { /** * Returns the components screen resolution or the default screen resolution if the component is * null or has no toolkit assigned yet . * @ param c the component to ask for a toolkit * @ return the component ' s screen resolution */ protected int getScreenResolution ( Comp...
if ( c == null ) { return getDefaultScreenResolution ( ) ; } Toolkit toolkit = c . getToolkit ( ) ; return toolkit != null ? toolkit . getScreenResolution ( ) : getDefaultScreenResolution ( ) ;
public class BitMatrix { /** * < p > Sets a square region of the bit matrix to true . < / p > * @ param left The horizontal position to begin at ( inclusive ) * @ param top The vertical position to begin at ( inclusive ) * @ param width The width of the region * @ param height The height of the region */ public...
if ( top < 0 || left < 0 ) { throw new IllegalArgumentException ( "Left and top must be nonnegative" ) ; } if ( height < 1 || width < 1 ) { throw new IllegalArgumentException ( "Height and width must be at least 1" ) ; } int right = left + width ; int bottom = top + height ; if ( bottom > this . height || right > this ...
public class AssetsFeature { /** * < p > lookupAsset . < / p > * @ param name a { @ link java . lang . String } object . * @ param file a { @ link java . lang . String } object . * @ return a { @ link java . net . URL } object . */ public static URL lookupAsset ( String name , String file ) { } }
URL url = null ; if ( name . startsWith ( "/" ) ) { name = name . substring ( 1 ) ; } if ( name . endsWith ( "/" ) ) { name = name . substring ( 0 , name . lastIndexOf ( "/" ) ) ; } if ( name . equals ( "" ) ) { name = ROOT_MAPPING_PATH ; } if ( file . startsWith ( "/" ) ) { file = file . substring ( 1 ) ; } String [ ]...
public class ConcurrentNodeMemories { /** * Checks if a memory does not exists for the given node and * creates it . */ private Memory createNodeMemory ( MemoryFactory node , InternalWorkingMemory wm ) { } }
try { this . lock . lock ( ) ; // need to try again in a synchronized code block to make sure // it was not created yet Memory memory = this . memories . get ( node . getMemoryId ( ) ) ; if ( memory == null ) { memory = node . createMemory ( this . kBase . getConfiguration ( ) , wm ) ; if ( ! this . memories . compareA...
public class Store { /** * { @ inheritDoc } */ @ Override protected void setLinkProperty ( final UUID _linkTypeUUID , final long _toId , final UUID _toTypeUUID , final String _toName ) throws EFapsException { } }
if ( _linkTypeUUID . equals ( CIDB . Store2Resource . uuid ) ) { this . resource = _toName ; loadResourceProperties ( _toId ) ; } super . setLinkProperty ( _linkTypeUUID , _toId , _toTypeUUID , _toName ) ;
public class CmsPrincipal { /** * Utility function to read a principal by its id from the OpenCms database using the * provided OpenCms user context . < p > * @ param cms the OpenCms user context to use when reading the principal * @ param name the name of the principal to read * @ return the principal read fro...
try { // first try to read the principal as a user return cms . readUser ( name ) ; } catch ( CmsException exc ) { // assume user does not exist } try { // now try to read the principal as a group return cms . readGroup ( name ) ; } catch ( CmsException exc ) { // assume group does not exist } // invalid principal name...
public class SuggestionsAdapter { /** * Gets the activity or application icon for an activity . * @ param component Name of an activity . * @ return A drawable , or { @ code null } if neither the acitivy or the application * have an icon set . */ private Drawable getActivityIcon ( ComponentName component ) { } }
PackageManager pm = mContext . getPackageManager ( ) ; final ActivityInfo activityInfo ; try { activityInfo = pm . getActivityInfo ( component , PackageManager . GET_META_DATA ) ; } catch ( NameNotFoundException ex ) { Log . w ( LOG_TAG , ex . toString ( ) ) ; return null ; } int iconId = activityInfo . getIconResource...
public class InboundCookiesHandler { /** * Retrieves the value of a cookie with a given name from a HttpServerExchange * @ param exchange The exchange containing the cookie * @ param cookieName The name of the cookie * @ return The value of the cookie or null if none found */ private String getCookieValue ( HttpS...
String value = null ; Map < String , Cookie > requestCookies = exchange . getRequestCookies ( ) ; if ( requestCookies != null ) { Cookie cookie = exchange . getRequestCookies ( ) . get ( cookieName ) ; if ( cookie != null ) { value = cookie . getValue ( ) ; } } return value ;
public class LaJobRunner { protected long showRunning ( LaJobRuntime runtime ) { } }
JobNoticeLog . log ( runtime . getNoticeLogLevel ( ) , ( ) -> buildRunningJobLogMessage ( runtime ) ) ; if ( noticeLogHook != null ) { noticeLogHook . hookRunning ( runtime , buildRunningJobLogMessage ( runtime ) ) ; } return System . currentTimeMillis ( ) ;
public class CSVParserBuilder { /** * Construct parser using current setting * @ return CSV Parser */ public CSVParser < T > build ( ) { } }
return subsetView == null ? new QuickCSVParser < T , K > ( bufferSize , metadata , recordMapper , charset ) : new QuickCSVParser < T , K > ( bufferSize , metadata , recordWithHeaderMapper , subsetView , charset ) ;
public class ST_Expand { /** * Expands a geometry ' s envelope by the given delta X and delta Y . Both * positive and negative distances are supported . * @ param geometry the input geometry * @ param deltaX the distance to expand the envelope along the X axis * @ param deltaY the distance to expand the envelop...
if ( geometry == null ) { return null ; } Envelope env = geometry . getEnvelopeInternal ( ) ; // As the time of writing Envelope . expand is buggy with negative parameters double minX = env . getMinX ( ) - deltaX ; double maxX = env . getMaxX ( ) + deltaX ; double minY = env . getMinY ( ) - deltaY ; double maxY = env ....
public class HttpContextManager { /** * Initialize the Http Context . This will set up current context for * request , response , session ( resolved from cookie ) and flash ( resolved * from cookie ) * @ param request the http request * @ param response the http response */ public static void init ( H . Request...
H . Request . current ( request ) ; H . Response . current ( response ) ; resolveSession ( request ) ; resolveFlash ( request ) ;
public class PacketCapturesInner { /** * Query the status of a running packet capture session . * @ param resourceGroupName The name of the resource group . * @ param networkWatcherName The name of the Network Watcher resource . * @ param packetCaptureName The name given to the packet capture session . * @ thro...
return getStatusWithServiceResponseAsync ( resourceGroupName , networkWatcherName , packetCaptureName ) . map ( new Func1 < ServiceResponse < PacketCaptureQueryStatusResultInner > , PacketCaptureQueryStatusResultInner > ( ) { @ Override public PacketCaptureQueryStatusResultInner call ( ServiceResponse < PacketCaptureQu...
public class StringUtil { /** * Converts the specified byte array into a hexadecimal value . */ public static String toHexString ( byte [ ] src , int offset , int length ) { } }
return toHexString ( new StringBuilder ( length << 1 ) , src , offset , length ) . toString ( ) ;
public class BeanHelperCache { /** * Creates a BeanHelper and writes an interface containing its instance . Also , recursively creates * any BeanHelpers on its constrained properties . ( Public for testing . ) * @ param clazz class type * @ param logger tree logger to use * @ param context generator context *...
final JClassType beanType = context . getTypeOracle ( ) . findType ( clazz . getCanonicalName ( ) ) ; return doCreateHelper ( clazz , beanType , logger , context ) ;
public class Base64VLQ { /** * Writes a VLQ encoded value to the provide appendable . * @ throws IOException */ public static void encode ( Appendable out , int value ) throws IOException { } }
value = toVLQSigned ( value ) ; do { int digit = value & VLQ_BASE_MASK ; value >>>= VLQ_BASE_SHIFT ; if ( value > 0 ) { digit |= VLQ_CONTINUATION_BIT ; } out . append ( Base64 . toBase64 ( digit ) ) ; } while ( value > 0 ) ;
public class Stream { /** * Creates a concatenated stream whose elements are all the elements of the first stream followed by all the elements of the second stream . * @ param a first stream * @ param b second stream * @ param < T > type of elements * @ return a stream concatenating first and second */ @ Suppre...
return new Stream ( Iterators . concat ( a . iterator , b . iterator ) ) ;