signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class Replacement { /** * this method returns the pointer to the loser in the competition for survival ; */
public static Program compete ( List < Program > programs , Program current , Program candidate , LGP manager , RandEngine randEngine ) { } } | if ( manager . getReplacementStrategy ( ) == LGPReplacementStrategy . DirectCompetition ) { if ( CollectionUtils . isBetterThan ( candidate , current ) ) { int index = programs . indexOf ( current ) ; programs . set ( index , candidate ) ; return current ; } else { return candidate ; } } else { if ( randEngine . unifor... |
public class TextSerdes { /** * Serialize a collection of strings separating them with the modifiable TextDeserializer # SEPARATOR string .
* @ param c The collection of the object to be serialized
* @ param context Context of the serialization
* @ return The serialized string */
@ Override public String serializ... | StringBuilder sb = new StringBuilder ( ) ; for ( String s : c ) { sb . append ( s ) ; sb . append ( SEPARATOR ) ; } sb . setLength ( sb . length ( ) - SEPARATOR . length ( ) ) ; return sb . toString ( ) ; |
public class RecoveryDirectorImpl { /** * Invoked by a client service to indicate recovery processing for the identified
* FailureScope ceased . The client service supplies its RecoveryAgent reference to
* identify itself .
* The RecoveryDirector will then pass the termination request on to other registered
* c... | if ( tc . isEntryEnabled ( ) ) Tr . entry ( tc , "terminationComplete" , new Object [ ] { recoveryAgent , failureScope , this } ) ; final boolean removed = removeTerminationRecord ( recoveryAgent , failureScope ) ; if ( ! removed ) { if ( tc . isEventEnabled ( ) ) Tr . event ( tc , "The supplied FailureScope was not re... |
public class LruCache { /** * Logs a warning if a threshold number of evictions has occurred since the
* last warning . */
private void evictionWarningIfNeeded ( ) { } } | // If not logging eviction warnings , just return .
if ( evictionWarningThrottle <= 0 ) { return ; } evictionsSinceWarning ++ ; if ( evictionsSinceWarning >= evictionWarningThrottle ) { DateFormat dateFormat = DateFormat . getDateTimeInstance ( ) ; if ( LOGGER . isInfoEnabled ( ) ) { LOGGER . info ( "There have been " ... |
public class WSFederationMetadataWriter { /** * Produce metadata document .
* @ param config the config
* @ return the document */
public static Document produceMetadataDocument ( final CasConfigurationProperties config ) { } } | try { val wsfedIdp = config . getAuthn ( ) . getWsfedIdp ( ) ; val sts = wsfedIdp . getSts ( ) ; val prop = CryptoUtils . getSecurityProperties ( sts . getRealm ( ) . getKeystoreFile ( ) , sts . getRealm ( ) . getKeystorePassword ( ) , sts . getRealm ( ) . getKeystoreAlias ( ) ) ; val crypto = CryptoFactory . getInstan... |
public class XBELValidator { /** * { @ inheritDoc } */
@ Override public boolean isValid ( final String s ) { } } | try { validate ( s ) ; } catch ( SAXException e ) { return false ; } catch ( IOException e ) { return false ; } return true ; |
public class L3ToSBGNPDConverter { /** * Initially , we don ' t want to represent every PhysicalEntity or Gene node .
* For example , if a Complex is nested under another Complex ,
* and if it is not a participant of any interaction ,
* then we don ' t want to draw it separately ; also skip for dangling entities ... | boolean create = false ; if ( ent instanceof PhysicalEntity || ent instanceof Gene ) { if ( ubiqueDet != null && ubiqueDet . isUbique ( ent ) ) create = false ; // ubiques will be created where they are actually used .
else if ( ! ent . getParticipantOf ( ) . isEmpty ( ) ) create = true ; else if ( ent instanceof Compl... |
public class GetAdUnitHierarchy { /** * Helper for displaying inventory units .
* @ param root the root inventory unit
* @ param treeMap the map of id to { @ code List } of inventory units
* @ param depth the depth the tree has reached */
private static void displayInventoryTreeHelper ( AdUnit root , Map < String... | System . out . println ( generateTab ( depth ) + root . getName ( ) + " (" + root . getId ( ) + ")" ) ; if ( treeMap . get ( root . getId ( ) ) != null ) { for ( AdUnit child : treeMap . get ( root . getId ( ) ) ) { displayInventoryTreeHelper ( child , treeMap , depth + 1 ) ; } } |
public class OneShotSQLGeneratorEngine { /** * produces the select clause of the sql query for the given CQIE
* @ return the sql select clause */
private String getSelectClauseFragment ( SignatureVariable var , Term term , Optional < TermType > termType , AliasIndex index ) { } } | /* * Datatype for the main column ( to which it is cast ) .
* Beware , it may defer the RDF datatype ( the one of the type column ) .
* Why ? Because most DBs ( if not all ) require the result table to have
* one datatype per column . If the sub - queries are producing results of different types ,
* them there ... |
public class IntStreamEx { /** * Returns a sequential ordered { @ code IntStreamEx } containing all the
* indices of the supplied array elements which match given predicate .
* @ param < T > array element type
* @ param array array to get the stream of its indices
* @ param predicate a predicate to test array e... | return seq ( IntStream . range ( 0 , array . length ) . filter ( i -> predicate . test ( array [ i ] ) ) ) ; |
public class OrderAnalyzer { /** * < p > Check for post death events , burial , cremation , funeral , head
* stone unveiling come to mind . < / p >
* < p > Only public for testability . < / p >
* @ param event the attribute to check if it ' s a post death event
* @ return true if this is a death event */
public... | if ( "Burial" . equals ( event . getString ( ) ) ) { return true ; } if ( "Cremation" . equals ( event . getString ( ) ) ) { return true ; } if ( "Funeral" . equals ( event . getString ( ) ) ) { return true ; } return "Headstone unveiling" . equals ( event . getString ( ) ) ; |
public class BridgeUtils { /** * Create a DataObject for the property request .
* @ param inputRootDataObject The root DataObject .
* @ param inputProperty The property to request
* @ pre inputRootDataObject ! = null
* @ pre inputProperty ! = null
* @ pre inputProperty ! = " " */
protected void createProperty... | // use the root DataGraph to create a PropertyControl DataGraph
List < Control > propertyControls = inputRootDataObject . getControls ( ) ; PropertyControl propCtrl = null ; if ( propertyControls != null ) { propCtrl = new PropertyControl ( ) ; propertyControls . add ( propCtrl ) ; } // add the requested property to th... |
public class RtfSection { /** * Updates the left , right and content indentation of all RtfParagraph and RtfSection
* elements that this RtfSection contains .
* @ param indentLeft The left indentation to add .
* @ param indentRight The right indentation to add .
* @ param indentContent The content indentation t... | if ( this . title != null ) { this . title . setIndentLeft ( ( int ) ( this . title . getIndentLeft ( ) + indentLeft * RtfElement . TWIPS_FACTOR ) ) ; this . title . setIndentRight ( ( int ) ( this . title . getIndentRight ( ) + indentRight * RtfElement . TWIPS_FACTOR ) ) ; } for ( int i = 0 ; i < this . items . size (... |
public class RESTClient { /** * Performs POST request , while expected response entity is a list of specified type .
* @ param entityClass Class , which contains expected response entity fields .
* @ param path Request path .
* @ param payload Entity , which will be used as request payload .
* @ param headers M... | return postWithListResultInternal ( entityClass , payload , new HttpPost ( baseUrl + path ) , headers ) ; |
public class Bindings { /** * Creates a wildcard condition for the given type . Note that this method is meant to be
* used as a base for specialized factory methods , e . g . like { @ link # anyStatus ( ) } .
* @ param type attribute type
* @ param < A > generic attribute type
* @ return an any condition on th... | return new PartialBinding < > ( null ) ; |
public class AbstractAmazonDynamoDBAsync { /** * Simplified method form for invoking the ListTables operation .
* @ see # listTablesAsync ( ListTablesRequest ) */
@ Override public java . util . concurrent . Future < ListTablesResult > listTablesAsync ( String exclusiveStartTableName ) { } } | return listTablesAsync ( new ListTablesRequest ( ) . withExclusiveStartTableName ( exclusiveStartTableName ) ) ; |
public class HashUtils { /** * generate hash code by using SHA - 256
* If there is some error , log the error . */
@ Sensitive @ Trivial public static String digest ( @ Sensitive String input ) { } } | if ( input == null || input . isEmpty ( ) ) return null ; return digest ( input , DEFAULT_ALGORITHM , DEFAULT_CHARSET ) ; |
public class IdcardUtil { /** * 将身份证的每位和对应位的加权因子相乘之后 , 再得到和值
* @ param iArr
* @ return 身份证编码 。 */
private static int getPowerSum ( char [ ] iArr ) { } } | int iSum = 0 ; if ( power . length == iArr . length ) { for ( int i = 0 ; i < iArr . length ; i ++ ) { iSum += Integer . valueOf ( String . valueOf ( iArr [ i ] ) ) * power [ i ] ; } } return iSum ; |
public class Cache { /** * Replace the content in the cache completely .
* @ param list the list
* @ param resourceVersion the resource version */
@ Override public void replace ( List < ApiType > list , String resourceVersion ) { } } | lock . lock ( ) ; try { Map < String , ApiType > newItems = new HashMap < > ( ) ; for ( ApiType item : list ) { String key = keyFunc . apply ( item ) ; newItems . put ( key , item ) ; } this . items = newItems ; // rebuild any index
this . indices = new HashMap < > ( ) ; for ( Map . Entry < String , ApiType > itemEntry... |
public class ServerNetwork { /** * Starts the server . */
public void stopServer ( ) { } } | // _ heartbeatState . notifyHeartbeatStop ( ) ;
SocketPool pool = _clusterSocketPool . get ( ) ; if ( pool != null ) { pool . getFactory ( ) . notifyHeartbeatStop ( ) ; } |
public class RiakNode { /** * End ConnectionPool stuff */
@ Override public void onSuccess ( Channel channel , final RiakMessage response ) { } } | logger . debug ( "Operation onSuccess() channel: id:{} {}:{}" , channel . hashCode ( ) , remoteAddress , port ) ; consecutiveFailedOperations . set ( 0 ) ; final FutureOperation inProgress = inProgressMap . get ( channel ) ; // Especially with a streaming op , the close listener may trigger causing
// a race . This che... |
public class FGauge { /** * * * * * * Initialization * * * * * */
private void init ( ) { } } | if ( Double . compare ( getWidth ( ) , 0 ) <= 0 || Double . compare ( getHeight ( ) , 0 ) <= 0 || Double . compare ( getPrefWidth ( ) , 0 ) <= 0 || Double . compare ( getPrefHeight ( ) , 0 ) <= 0 ) { setPrefSize ( PREFERRED_WIDTH , PREFERRED_HEIGHT ) ; } if ( Double . compare ( getMinWidth ( ) , 0 ) <= 0 || Double . co... |
public class MainActivity { public void onSingleClick ( final View view ) { } } | final String name = "LicensesDialog" ; final String url = "http://psdev.de" ; final String copyright = "Copyright 2013 Philip Schiffer <admin@psdev.de>" ; final License license = new ApacheSoftwareLicense20 ( ) ; final Notice notice = new Notice ( name , url , copyright , license ) ; new LicensesDialog . Builder ( this... |
public class CasConfigurationMetadataRepositoryJsonBuilder { /** * Add the content of a { @ link ConfigurationMetadataRepository } defined by the
* specified { @ link InputStream } json document using the specified { @ link Charset } . If
* this metadata repository holds items that were loaded previously , these ar... | if ( inputStream == null ) { throw new IllegalArgumentException ( "InputStream must not be null." ) ; } this . repositories . add ( add ( inputStream , charset ) ) ; return this ; |
public class MatrixToImageWriter { /** * As { @ link # writeToStream ( BitMatrix , String , OutputStream ) } , but allows customization of the output .
* @ param matrix { @ link BitMatrix } to write
* @ param format image format
* @ param stream { @ link OutputStream } to write image to
* @ param config output ... | BufferedImage image = toBufferedImage ( matrix , config ) ; if ( ! ImageIO . write ( image , format , stream ) ) { throw new IOException ( "Could not write an image of format " + format ) ; } |
public class XMLOutputter { /** * Adds an attribute to the current element , with a < code > char < / code > value . There must
* currently be an open element .
* The attribute value is surrounded by the quotation mark character ( see
* { @ link # getQuotationMark ( ) } ) .
* @ param name the name of the attrib... | attribute ( name , Character . toString ( c ) ) ; |
public class RandomProjection { /** * Find a safe number of components to project this to , through
* the Johnson - Lindenstrauss lemma
* The minimum number n ' of components to guarantee the eps - embedding is
* given by :
* n ' > = 4 log ( n ) / ( eps2 / 2 - eps3 / 3)
* see http : / / cseweb . ucsd . edu / ... | Boolean basicCheck = n == null || n . length == 0 || eps == null || eps . length == 0 ; if ( basicCheck ) throw new IllegalArgumentException ( "Johnson-Lindenstrauss dimension estimation requires > 0 components and at least a relative error" ) ; for ( double epsilon : eps ) { if ( epsilon <= 0 || epsilon >= 1 ) { throw... |
public class SOAPFactory { /** * Creates a new < code > SOAPFactory < / code > object that is an instance of
* the default implementation ( SOAP 1.1 ) ,
* This method uses the following ordered lookup procedure to determine the SOAPFactory implementation class to load :
* < UL >
* < LI > Use the javax . xml . s... | try { SOAPFactory factory = ( SOAPFactory ) FactoryFinder . find ( SOAP_FACTORY_PROPERTY ) ; if ( factory != null ) return factory ; return newInstance ( SOAPConstants . SOAP_1_1_PROTOCOL ) ; } catch ( Exception ex ) { throw new SOAPException ( "Unable to create SOAP Factory: " + ex . getMessage ( ) ) ; } |
public class StreamTransfer { /** * Transfers the specified number of bytes from the source to the target .
* Fewer bytes may be transferred if an end - of - stream condition occurs in
* either the source or the target .
* @ param count
* the number of bytes to be transferred
* @ return the result of the tran... | if ( count < 0L ) throw new IllegalArgumentException ( "negative count" ) ; return buffer == null ? transferNoBuffer ( count ) : transferBuffered ( count ) ; |
public class ProtoLexer { /** * $ ANTLR start " LEFTSQUARE " */
public final void mLEFTSQUARE ( ) throws RecognitionException { } } | try { int _type = LEFTSQUARE ; int _channel = DEFAULT_TOKEN_CHANNEL ; // com / dyuproject / protostuff / parser / ProtoLexer . g : 59:5 : ( ' [ ' )
// com / dyuproject / protostuff / parser / ProtoLexer . g : 59:9 : ' [ '
{ match ( '[' ) ; } state . type = _type ; state . channel = _channel ; } finally { } |
public class HtmlFocusBaseTag { /** * Sets the onFocus javascript event .
* @ param onfocus the onFocus event .
* @ jsptagref . attributedescription The onFocus JavaScript event .
* @ jsptagref . databindable false
* @ jsptagref . attributesyntaxvalue < i > string _ onFocus < / i >
* @ netui : attribute requi... | AbstractHtmlState tsh = getState ( ) ; tsh . registerAttribute ( AbstractHtmlState . ATTR_JAVASCRIPT , ONFOCUS , onfocus ) ; |
public class ExtractRegular { /** * 多个url模式可能会有相同的url前缀
* map结构 + url前缀定位
* 用于快速查找一个url需要匹配的模式
* @ param urlPatterns url模式列表
* @ return 以url前缀为key的map结构 */
private Map < String , List < UrlPattern > > toMap ( List < UrlPattern > urlPatterns ) { } } | Map < String , List < UrlPattern > > map = new ConcurrentHashMap < > ( ) ; for ( UrlPattern urlPattern : urlPatterns ) { try { URL url = new URL ( urlPattern . getUrlPattern ( ) ) ; String key = urlPrefix ( url ) ; List < UrlPattern > value = map . get ( key ) ; if ( value == null ) { value = new ArrayList < > ( ) ; ma... |
public class NDArrayMessageChunk { /** * Returns the overall size for an { @ link NDArrayMessageChunk } .
* The size of a message chunk is :
* idLengthSize ( 4 ) + messageTypeSize ( 4 ) + indexSize ( 4 ) + chunkSizeSize ( 4 ) + numChunksSize ( 4 ) + chunk . getData ( ) . limit ( ) + chunk . getId ( ) . getBytes ( )... | int messageTypeSize = 4 ; int indexSize = 4 ; int numChunksSize = 4 ; int chunkSizeSize = 4 ; int idLengthSize = 4 ; return idLengthSize + messageTypeSize + indexSize + chunkSizeSize + numChunksSize + chunk . getData ( ) . limit ( ) + chunk . getId ( ) . getBytes ( ) . length ; |
public class StringHelper { /** * Convert a byte array to a hexadecimal encoded string .
* @ param aInput
* The byte array to be converted to a String . May not be
* < code > null < / code > .
* @ param nOfs
* Byte array offset
* @ param nLen
* Number of bytes to encode
* @ return The String representat... | ValueEnforcer . isArrayOfsLen ( aInput , nOfs , nLen ) ; final StringBuilder aSB = new StringBuilder ( nLen * 2 ) ; for ( int i = nOfs ; i < ( nOfs + nLen ) ; ++ i ) { final byte b = aInput [ i ] ; final char c1 = getHexChar ( ( b & 0xf0 ) >> 4 ) ; final char c2 = getHexChar ( b & 0x0f ) ; aSB . append ( c1 ) . append ... |
public class NonplanarBonds { /** * Check that an atom ( v : index ) is only adjacent to plain single bonds ( may be a bold or
* hashed wedged - e . g . at fat end ) with the single exception being the allowed double bond
* passed as an argument .
* @ param v atom index
* @ param allowedDoubleBond a double bond... | int count = 0 ; for ( int neighbor : graph [ v ] ) { IBond adjBond = edgeToBond . get ( v , neighbor ) ; // non single bonds
if ( adjBond . getOrder ( ) . numeric ( ) > 1 ) { if ( ! allowedDoubleBond . equals ( adjBond ) ) { return false ; } } // single bonds
else { if ( adjBond . getStereo ( ) == UP_OR_DOWN || adjBond... |
public class SignatureFileVerifier { /** * See if the whole manifest was signed . */
private boolean verifyManifestHash ( Manifest sf , ManifestDigester md , BASE64Decoder decoder , List manifestDigests ) throws IOException { } } | Attributes mattr = sf . getMainAttributes ( ) ; boolean manifestSigned = false ; // go through all the attributes and process * - Digest - Manifest entries
for ( Map . Entry < Object , Object > se : mattr . entrySet ( ) ) { String key = se . getKey ( ) . toString ( ) ; if ( key . toUpperCase ( Locale . ENGLISH ) . ends... |
public class FastByteArrayOutputStream { /** * This can < b > ONLY < / b > be called if there is only a single buffer to write , instead
* use { @ link # writeTo ( java . io . Writer , String ) } , which auto detects if
* { @ link # writeToViaString ( java . io . Writer , String ) } is to be used or
* { @ link # ... | byte [ ] bufferToWrite = buffer ; // this is always the last buffer to write
int bufferToWriteLen = index ; // index points to our place in the last buffer
writeToImpl ( out , encoding , bufferToWrite , bufferToWriteLen ) ; |
public class MsgUtils { /** * Builds the list of SoyMsgParts for the given MsgPluralNode .
* @ param msgPluralNode The plural node parsed from the Soy source .
* @ param msgNode The MsgNode containing ' msgPluralNode ' .
* @ return A SoyMsgPluralPart . */
private static SoyMsgPluralPart buildMsgPartForPlural ( Ms... | // This is the list of the cases .
ImmutableList . Builder < SoyMsgPart . Case < SoyMsgPluralCaseSpec > > pluralCases = ImmutableList . builder ( ) ; for ( CaseOrDefaultNode child : msgPluralNode . getChildren ( ) ) { ImmutableList < SoyMsgPart > caseMsgParts = buildMsgPartsForChildren ( ( MsgBlockNode ) child , msgNod... |
public class CommerceDiscountModelImpl { /** * Converts the soap model instances into normal model instances .
* @ param soapModels the soap model instances to convert
* @ return the normal model instances */
public static List < CommerceDiscount > toModels ( CommerceDiscountSoap [ ] soapModels ) { } } | if ( soapModels == null ) { return null ; } List < CommerceDiscount > models = new ArrayList < CommerceDiscount > ( soapModels . length ) ; for ( CommerceDiscountSoap soapModel : soapModels ) { models . add ( toModel ( soapModel ) ) ; } return models ; |
public class ExecutionContext { /** * Method that initializes the default namespaces for namespace registries .
* @ param namespaceRegistry the namespace registry */
protected void initializeDefaultNamespaces ( NamespaceRegistry namespaceRegistry ) { } } | if ( namespaceRegistry == null ) return ; namespaceRegistry . register ( JcrLexicon . Namespace . PREFIX , JcrLexicon . Namespace . URI ) ; namespaceRegistry . register ( JcrMixLexicon . Namespace . PREFIX , JcrMixLexicon . Namespace . URI ) ; namespaceRegistry . register ( JcrNtLexicon . Namespace . PREFIX , JcrNtLexi... |
public class TweetData { /** * Produce request parameters for a Tweet .
* @ return a { @ link MultiValueMap } of request parameters . */
public MultiValueMap < String , Object > toTweetParameters ( ) { } } | MultiValueMap < String , Object > params = new LinkedMultiValueMap < String , Object > ( ) ; params . set ( "status" , message ) ; if ( inReplyToStatusId != null ) { params . set ( "in_reply_to_status_id" , inReplyToStatusId . toString ( ) ) ; } if ( latitude != null && longitude != null ) { params . set ( "lat" , lati... |
public class StateDP { /** * Adds a group address to this datapoint to indicate that KNX messages with that
* address are allowed to alter the associated datapoint state ( i . e . a state value
* related to this datapoint ) .
* A group address can be marked as updating a state or invalidating a state . An
* add... | if ( getMainAddress ( ) . equals ( a ) ) throw new KNXIllegalArgumentException ( "address equals datapoint main address" ) ; if ( isUpdating ) { if ( ! updating . contains ( a ) ) updating . add ( a ) ; } else { if ( ! invalidating . contains ( a ) ) invalidating . add ( a ) ; } |
public class Gaussian03Reader { /** * Reads partial atomic charges and add the to the given ChemModel . */
private void readPartialCharges ( IChemModel model ) throws CDKException , IOException { } } | logger . info ( "Reading partial atomic charges" ) ; IAtomContainerSet moleculeSet = model . getMoleculeSet ( ) ; IAtomContainer molecule = moleculeSet . getAtomContainer ( 0 ) ; String line = input . readLine ( ) ; // skip first line after " Total atomic charges "
while ( input . ready ( ) ) { line = input . readLine ... |
public class AbstractNpmAnalyzer { /** * Determines if the path contains " / node _ modules / " or " / bower _ components / "
* ( i . e . it is a child module ) . This analyzer does not scan child modules .
* @ param pathname the path to test
* @ return < code > true < / code > if the path does not contain " / no... | try { // Do not scan the node _ modules ( or bower _ components ) directory
final String canonicalPath = pathname . getCanonicalPath ( ) ; if ( canonicalPath . contains ( File . separator + "node_modules" + File . separator ) || canonicalPath . contains ( File . separator + "bower_components" + File . separator ) ) { L... |
public class HeatChart { /** * Replaces the z - values array . The number of elements should match the number of y - values , with
* each element containing a double array with an equal number of elements that matches the number
* of x - values . Use this method where the minimum and maximum values possible are not... | this . zValues = zValues ; this . lowValue = low ; this . highValue = high ; |
public class CmsErrorBean { /** * Returns the html code for the buttons , when the errorpage is included from outside the workplace . < p >
* @ return the default html for the buttons */
public String getDefaultButtonsHtml ( ) { } } | StringBuffer result = new StringBuffer ( ) ; String closeLabel = m_messages . key ( Messages . GUI_CLOSE_0 , new Object [ ] { } ) ; String detailsLabel = m_messages . key ( Messages . GUI_DETAILS_0 , new Object [ ] { } ) ; result . append ( "<div class=\"dialogbuttons\" unselectable=\"on\">" ) ; result . append ( "<inp... |
public class ContentCryptoMaterial { /** * Returns a new instance of < code > ContentCryptoMaterial < / code >
* for the input parameters using the specified s3 crypto scheme .
* Note network calls are involved if the CEK is to be protected by KMS .
* @ param cek content encrypting key
* @ param iv initializati... | return doCreate ( cek , iv , kekMaterials , scheme . getContentCryptoScheme ( ) , scheme , config , kms , req ) ; |
public class PrcBeginningInventorySave { /** * < p > Make other entries include reversing if it ' s need when save . < / p >
* @ param pAddParam additional param
* @ param pEntity entity
* @ param pRequestData Request Data
* @ param pIsNew if entity was new
* @ throws Exception - an exception */
@ Override pu... | String actionAdd = pRequestData . getParameter ( "actionAdd" ) ; if ( "makeAccEntries" . equals ( actionAdd ) && pEntity . getReversedId ( ) != null ) { // reverse none - reversed lines :
BeginningInventoryLine bil = new BeginningInventoryLine ( ) ; BeginningInventory reversed = new BeginningInventory ( ) ; reversed . ... |
public class TemplateServlet { /** * Compile the template and store it in the cache .
* @ param key a unique key for the template , such as a file ' s absolutePath or a URL .
* @ param inputStream an InputStream for the template ' s source .
* @ param file a file to be used to determine if the cached template is ... | if ( verbose ) { log ( "Creating new template from " + key + "..." ) ; } Reader reader = null ; try { String fileEncoding = ( fileEncodingParamVal != null ) ? fileEncodingParamVal : System . getProperty ( GROOVY_SOURCE_ENCODING ) ; reader = fileEncoding == null ? new InputStreamReader ( inputStream ) : new InputStreamR... |
public class PdfDictionary { /** * Returns a < CODE > PdfObject < / CODE > as a < CODE > PdfStream < / CODE > ,
* resolving indirect references .
* The object associated with the < CODE > PdfName < / CODE > given is retrieved
* and resolved to a direct object .
* If it is a < CODE > PdfStream < / CODE > , it is... | PdfStream stream = null ; PdfObject orig = getDirectObject ( key ) ; if ( orig != null && orig . isStream ( ) ) { stream = ( PdfStream ) orig ; } return stream ; |
public class CachedDirectoryLookupService { /** * Get the changed list for the MetadataKey from the server .
* @ param keyMap
* the MetadataKey list .
* @ return
* the ModelMetadataKey list that has been changed . */
private Map < String , OperationResult < ModelMetadataKey > > getChangedMetadataKeys ( Map < St... | return this . getDirectoryServiceClient ( ) . getChangedMetadataKeys ( keyMap ) ; |
public class MpMessages { /** * 群发视频预览给特定用户
* @ param wxName
* @ param openId
* @ param mediaId
* @ param title
* @ param desc
* @ return */
public long videoPreview ( String wxName , String openId , String mediaId , String title , String desc ) { } } | Map < String , String > uploadRequest = new HashMap < > ( ) ; uploadRequest . put ( "media_id" , mediaId ) ; uploadRequest . put ( "title" , title ) ; uploadRequest . put ( "description" , desc ) ; String uploadUrl = WxEndpoint . get ( "url.mass.message.video.upload" ) ; String json = JsonMapper . nonEmptyMapper ( ) . ... |
public class AutoDigestFileSystem { /** * { @ inheritDoc } */
public Entry get ( String path ) { } } | Entry entry = backing . get ( path ) ; if ( entry == null ) { if ( path . startsWith ( "/" ) ) { path = path . substring ( 1 ) ; } if ( path . length ( ) == 0 ) { return getRoot ( ) ; } String [ ] parts = path . split ( "/" ) ; if ( parts . length == 0 ) { return getRoot ( ) ; } DirectoryEntry parent = getRoot ( ) ; fo... |
public class CommerceAddressPersistenceImpl { /** * Removes all the commerce addresses where groupId = & # 63 ; and classNameId = & # 63 ; and classPK = & # 63 ; and defaultShipping = & # 63 ; from the database .
* @ param groupId the group ID
* @ param classNameId the class name ID
* @ param classPK the class pk... | for ( CommerceAddress commerceAddress : findByG_C_C_DS ( groupId , classNameId , classPK , defaultShipping , QueryUtil . ALL_POS , QueryUtil . ALL_POS , null ) ) { remove ( commerceAddress ) ; } |
public class Argon2Factory { /** * Creates a new { @ link Argon2 } instance with the given type .
* @ param type Argon2 type .
* @ param defaultSaltLength Default salt length in bytes . Can be overridden by some methods .
* @ param defaultHashLength Default hash length in bytes . Can be overridden by some methods... | return createInternal ( type , defaultSaltLength , defaultHashLength ) ; |
public class ListItemsResult { /** * The metadata entries for the folders and objects at the requested path .
* @ param items
* The metadata entries for the folders and objects at the requested path . */
public void setItems ( java . util . Collection < Item > items ) { } } | if ( items == null ) { this . items = null ; return ; } this . items = new java . util . ArrayList < Item > ( items ) ; |
public class JBBPTextWriter { /** * Change parameters for horizontal rule .
* @ param prefix the prefix to be printed before rule , it can be null
* @ param length the length in symbols .
* @ param ch symbol to draw
* @ return the context */
public JBBPTextWriter SetHR ( final String prefix , final int length ,... | this . prefixHR = prefix == null ? "" : prefix ; this . hrChar = ch ; this . hrLength = length ; return this ; |
public class ScanResult { /** * Deserialize a ScanResult from previously - serialized JSON .
* @ param json
* The JSON string for the serialized { @ link ScanResult } .
* @ return The deserialized { @ link ScanResult } . */
public static ScanResult fromJSON ( final String json ) { } } | final Matcher matcher = Pattern . compile ( "\\{[\\n\\r ]*\"format\"[ ]?:[ ]?\"([^\"]+)\"" ) . matcher ( json ) ; if ( ! matcher . find ( ) ) { throw new IllegalArgumentException ( "JSON is not in correct format" ) ; } if ( ! CURRENT_SERIALIZATION_FORMAT . equals ( matcher . group ( 1 ) ) ) { throw new IllegalArgumentE... |
public class DStreamExecutionGraphBuilder { /** * Will create an operation named ' extract ' with a pass - thru function */
private void createDefaultExtractOperation ( ) { } } | this . currentStreamOperation = new DStreamOperation ( this . operationIdCounter ++ ) ; this . currentStreamOperation . addStreamOperationFunction ( Ops . extract . name ( ) , s -> s ) ; |
public class AnnotationsInner { /** * Gets the list of annotations for a component for given time range .
* @ param resourceGroupName The name of the resource group .
* @ param resourceName The name of the Application Insights component resource .
* @ param start The start time to query from for annotations , can... | return ServiceFuture . fromResponse ( listWithServiceResponseAsync ( resourceGroupName , resourceName , start , end ) , serviceCallback ) ; |
public class HDRMetadata { /** * No compression */
@ Override protected IIOMetadataNode getStandardCompressionNode ( ) { } } | IIOMetadataNode node = new IIOMetadataNode ( "Compression" ) ; IIOMetadataNode compressionTypeName = new IIOMetadataNode ( "CompressionTypeName" ) ; compressionTypeName . setAttribute ( "value" , "RLE" ) ; node . appendChild ( compressionTypeName ) ; IIOMetadataNode lossless = new IIOMetadataNode ( "Lossless" ) ; lossl... |
public class WebSocketButtons { /** * Disables sending widgets . Enables connecting widgets . */
public void onDisconnect ( ) { } } | input . setDisabled ( true ) ; sendingButton . setDisabled ( true ) ; connectingButton . setDisabled ( false ) ; disconnectingButton . setDisabled ( true ) ; |
public class DescribeSpotFleetInstancesResult { /** * The running instances . This list is refreshed periodically and might be out of date .
* < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use
* { @ link # setActiveInstances ( java . util . Collection ) } or { @ link # withAc... | if ( this . activeInstances == null ) { setActiveInstances ( new com . amazonaws . internal . SdkInternalList < ActiveInstance > ( activeInstances . length ) ) ; } for ( ActiveInstance ele : activeInstances ) { this . activeInstances . add ( ele ) ; } return this ; |
public class InodeLockList { /** * Locks the next edge without checking or updating the mode .
* @ param childName the child to lock
* @ param mode the mode to lock in */
public void lockEdgeInternal ( String childName , LockMode mode ) { } } | Preconditions . checkState ( endsInInode ( ) ) ; Inode lastInode = get ( numLockedInodes ( ) - 1 ) ; Edge edge = new Edge ( lastInode . getId ( ) , childName ) ; mEntries . add ( new EdgeEntry ( mInodeLockManager . lockEdge ( edge , mode ) , edge ) ) ; |
public class BoundaryDate { /** * Grab random holiday from the equivalence class that falls between the two dates
* @ param earliest the earliest date parameter as defined in the model
* @ param latest the latest date parameter as defined in the model
* @ return a holiday that falls between the dates */
public St... | String dateString = "" ; DateTimeFormatter parser = ISODateTimeFormat . date ( ) ; DateTime earlyDate = parser . parseDateTime ( earliest ) ; DateTime lateDate = parser . parseDateTime ( latest ) ; List < Holiday > holidays = new LinkedList < > ( ) ; int min = Integer . parseInt ( earlyDate . toString ( ) . substring (... |
public class ProjectApi { /** * Get a single of project snippet as an Optional instance .
* < pre > < code > GET / projects / : id / snippets / : snippet _ id < / code > < / pre >
* @ param projectIdOrPath projectIdOrPath the project in the form of an Integer ( ID ) , String ( path ) , or Project instance , require... | try { return ( Optional . ofNullable ( getSnippet ( projectIdOrPath , snippetId ) ) ) ; } catch ( GitLabApiException glae ) { return ( GitLabApi . createOptionalFromException ( glae ) ) ; } |
public class FormattedStringBuilder { /** * Appends the specified string ( s ) to this character sequence .
* @ param strings The Strings to append
* @ return The updated instance of FormattedStringBuilder . */
public FormattedStringBuilder append ( String ... strings ) { } } | for ( String s : strings ) { _delegate . append ( s ) ; } return this ; |
public class Compiler { /** * Converts the parse tree for each input back to JS code . */
public String [ ] toSourceArray ( ) { } } | return runInCompilerThread ( ( ) -> { Tracer tracer = newTracer ( "toSourceArray" ) ; try { int numInputs = moduleGraph . getInputCount ( ) ; String [ ] sources = new String [ numInputs ] ; CodeBuilder cb = new CodeBuilder ( ) ; int i = 0 ; for ( CompilerInput input : moduleGraph . getAllInputs ( ) ) { Node scriptNode ... |
public class EntityPropertyClassNameResolver { /** * プロパティファイルをロードします 。
* @ param propertyFile プロパティファイル
* @ return エンティティプロパティ名の正規表現を表すパターンをキー 、 クラス名を値とするマップ */
protected LinkedHashMap < Pattern , String > load ( File propertyFile ) { } } | LinkedHashMap < Pattern , String > result = new LinkedHashMap < Pattern , String > ( ) ; BufferedReader reader = null ; try { reader = new BufferedReader ( new InputStreamReader ( new FileInputStream ( propertyFile ) , "UTF-8" ) ) ; String line ; while ( ( line = reader . readLine ( ) ) != null ) { if ( line . length (... |
public class MultipleEpochsIterator { /** * Returns { @ code true } if the iteration has more elements .
* ( In other words , returns { @ code true } if { @ link # next } would
* return an element rather than throwing an exception . )
* @ return { @ code true } if the iteration has more elements */
@ Override pub... | if ( iterationsCounter . get ( ) >= totalIterations ) return false ; if ( newEpoch ) { log . info ( "Epoch " + epochs + ", number of batches completed " + lastBatch ) ; newEpoch = false ; } if ( iter == null ) return ( epochs < numEpochs ) && ( ( ! batchedDS . isEmpty ( ) && batchedDS . size ( ) > batch ) || batchedDS ... |
public class FastSet { /** * { @ inheritDoc } */
@ Override public int compareTo ( IntSet o ) { } } | // empty set cases
if ( this . isEmpty ( ) && o . isEmpty ( ) ) { return 0 ; } if ( this . isEmpty ( ) ) { return - 1 ; } if ( o . isEmpty ( ) ) { return 1 ; } final FastSet other = convert ( o ) ; final int [ ] localWords = words ; // faster
final int [ ] localOtherWords = other . words ; // faster
if ( firstEmptyWord... |
public class StaticTypeCheckingVisitor { /** * Checks that a constructor style expression is valid regarding the number of arguments and the argument types .
* @ param node the class node for which we will try to find a matching constructor
* @ param arguments the constructor arguments
* @ deprecated use { @ link... | checkGroovyStyleConstructor ( node , arguments , typeCheckingContext . getEnclosingClassNode ( ) ) ; |
public class AndroidScanObjectsConverter { /** * TODO [ DS 18.05.2017 ] Consider a different implementation for Marshmallow */
@ SuppressLint ( "NewApi" ) @ RequiresApi ( api = Build . VERSION_CODES . LOLLIPOP ) public android . bluetooth . le . ScanSettings toNativeSettings ( ScanSettings scanSettings ) { } } | final android . bluetooth . le . ScanSettings . Builder builder = new android . bluetooth . le . ScanSettings . Builder ( ) ; if ( deviceSdk >= Build . VERSION_CODES . M ) { setMarshmallowSettings ( scanSettings , builder ) ; } return builder . setReportDelay ( scanSettings . getReportDelayMillis ( ) ) . setScanMode ( ... |
public class CleverTapAPI { /** * Push */
private boolean alreadyHaveGCMToken ( final String newToken ) { } } | if ( newToken == null ) return false ; String cachedToken = getCachedGCMToken ( ) ; return ( cachedToken != null && cachedToken . equals ( newToken ) ) ; |
public class IterableExtensions { /** * Creates a sorted list that contains the items of the given iterable . The resulting list is sorted according to
* the order induced by applying a key function to each element which yields a comparable criteria .
* @ param iterable
* the elements to be sorted . May not be < ... | return ListExtensions . sortInplaceBy ( Lists . newArrayList ( iterable ) , key ) ; |
public class CmsGalleryController { /** * Removes the folder from the search object . < p >
* @ param key the folder */
public void removeFolderParam ( String key ) { } } | if ( m_searchObject . getFolders ( ) . contains ( key ) ) { m_handler . onClearFolders ( Collections . singletonList ( key ) ) ; m_searchObject . removeFolder ( key ) ; updateResultsTab ( false ) ; ValueChangeEvent . fire ( this , m_searchObject ) ; } |
public class PAcl { /** * < code > optional string owningGroup = 2 ; < / code > */
public com . google . protobuf . ByteString getOwningGroupBytes ( ) { } } | java . lang . Object ref = owningGroup_ ; if ( ref instanceof java . lang . String ) { com . google . protobuf . ByteString b = com . google . protobuf . ByteString . copyFromUtf8 ( ( java . lang . String ) ref ) ; owningGroup_ = b ; return b ; } else { return ( com . google . protobuf . ByteString ) ref ; } |
public class AmazonRDSClient { /** * Stops an Amazon Aurora DB cluster . When you stop a DB cluster , Aurora retains the DB cluster ' s metadata ,
* including its endpoints and DB parameter groups . Aurora also retains the transaction logs so you can do a
* point - in - time restore if necessary .
* For more info... | request = beforeClientExecution ( request ) ; return executeStopDBCluster ( request ) ; |
public class ZosVarRdwDatumReader { /** * RDW is a 4 bytes numeric where the first 2 bytes are the length of the
* record ( LL ) including the 4 byte RDW .
* @ param hostData the mainframe data
* @ param start where the RDW starts
* @ param length the total size of the mainframe data
* @ return the integer co... | if ( length - start < RDW_LEN ) { throw new IllegalArgumentException ( "Not enough bytes for an RDW" ) ; } ByteBuffer buf = ByteBuffer . allocate ( RDW_LEN ) ; buf . put ( 0 , ( byte ) 0 ) ; buf . put ( 1 , ( byte ) 0 ) ; buf . put ( 2 , hostData [ start + 0 ] ) ; buf . put ( 3 , hostData [ start + 1 ] ) ; return buf .... |
public class CPSpecificationOptionPersistenceImpl { /** * Returns the last cp specification option in the ordered set where groupId = & # 63 ; .
* @ param groupId the group ID
* @ param orderByComparator the comparator to order the set by ( optionally < code > null < / code > )
* @ return the last matching cp spe... | CPSpecificationOption cpSpecificationOption = fetchByGroupId_Last ( groupId , orderByComparator ) ; if ( cpSpecificationOption != null ) { return cpSpecificationOption ; } StringBundler msg = new StringBundler ( 4 ) ; msg . append ( _NO_SUCH_ENTITY_WITH_KEY ) ; msg . append ( "groupId=" ) ; msg . append ( groupId ) ; m... |
public class ExtensionRegistry { /** * Clears the registry to prepare for re - registration ( e . g . as part of a reload ) . */
public void clear ( ) { } } | synchronized ( extensions ) { // we synchronize just to guard unnamedMerged
transformerRegistry = TransformerRegistry . Factory . create ( ) ; extensions . clear ( ) ; reverseMap . clear ( ) ; subsystemsInfo . clear ( ) ; } |
public class JDBCPersistenceManagerImpl { /** * Checks if the default schema JBATCH or the schema defined in batch - config exists .
* @ return true if the schema exists , false otherwise .
* @ throws SQLException */
private boolean isSchemaValid ( ) throws SQLException { } } | logger . entering ( CLASSNAME , "isSchemaValid" ) ; Connection conn = getConnectionToDefaultSchema ( ) ; DatabaseMetaData dbmd = conn . getMetaData ( ) ; ResultSet rs = dbmd . getSchemas ( ) ; while ( rs . next ( ) ) { if ( schema . equalsIgnoreCase ( rs . getString ( "TABLE_SCHEM" ) ) ) { cleanupConnection ( conn , rs... |
public class KTypeVTypeHashMap { /** * { @ inheritDoc } */
@ Override public void release ( ) { } } | assigned = 0 ; hasEmptyKey = false ; keys = null ; values = null ; ensureCapacity ( Containers . DEFAULT_EXPECTED_ELEMENTS ) ; |
public class Jenkins { /** * Gets just the immediate children of { @ link Jenkins } but of the given type . */
public < T > List < T > getItems ( Class < T > type ) { } } | List < T > r = new ArrayList < > ( ) ; for ( TopLevelItem i : getItems ( ) ) if ( type . isInstance ( i ) ) r . add ( type . cast ( i ) ) ; return r ; |
public class RestoreAgent { /** * Generate restore and replay plans and return the catalog associated with
* the snapshot to restore if there is anything to restore .
* @ return The ( host ID , catalog path ) pair , or null if there is no snapshot
* to restore . */
public Pair < Integer , String > findRestoreCata... | enterRestore ( ) ; try { m_snapshotToRestore = generatePlans ( ) ; } catch ( Exception e ) { VoltDB . crashGlobalVoltDB ( e . getMessage ( ) , true , e ) ; } if ( m_snapshotToRestore != null ) { int hostId = m_snapshotToRestore . hostId ; File file = new File ( m_snapshotToRestore . path , m_snapshotToRestore . nonce +... |
public class JqmExceptionMapper { /** * private HttpHeaders headers ; */
@ Override public Response toResponse ( JqmInvalidRequestException exception ) { } } | // String type = headers . getMediaType ( ) = = null ? MediaType . APPLICATION _ JSON : headers . getMediaType ( ) . getType ( ) ;
ErrorDto d = new ErrorDto ( exception . getMessage ( ) , 10 , exception , Status . BAD_REQUEST ) ; return Response . status ( Response . Status . BAD_REQUEST ) . entity ( d ) . type ( Media... |
public class TypeUtil { /** * Splits _ map to a list of maps where each map has _ nbElements .
* Last map in list maybe shorter if _ map . size ( ) is not divideable by _ nElements .
* @ param _ map map to split
* @ param _ nbElements elements per map
* @ param < K > key type
* @ param < V > value type
* @ ... | List < Map < K , V > > lofm = new ArrayList < > ( ) ; lofm . add ( _map . getClass ( ) . newInstance ( ) ) ; for ( Entry < K , V > e : _map . entrySet ( ) ) { Map < K , V > lastSubMap = lofm . get ( lofm . size ( ) - 1 ) ; if ( lastSubMap . size ( ) == _nbElements ) { lofm . add ( _map . getClass ( ) . newInstance ( ) ... |
public class JsonArray { /** * Retrieves the nth element in the array as double - precision floating point number . < br >
* If it is neither { @ code null } nor a { @ link Double } , { @ link IllegalStateException } will be thrown .
* @ param index
* @ return The element
* @ throws IllegalStateException The gi... | Type type = stateList . get ( index ) ; if ( type == null ) { return null ; } switch ( type ) { case NULL : return null ; case DOUBLE : Object obj = get ( index ) ; if ( obj instanceof Double ) { return ( Double ) obj ; } else if ( obj instanceof Float ) { return ( double ) ( Float ) obj ; } else { throw new IllegalSta... |
public class Maybe { /** * If the value is present , return it ; otherwise , return the value supplied by < code > otherSupplier < / code > .
* @ param otherSupplier the supplier for the other value
* @ return this value , or the supplied other value */
public final A orElseGet ( Supplier < A > otherSupplier ) { } ... | return match ( __ -> otherSupplier . get ( ) , id ( ) ) ; |
public class LegacyDocument { /** * Creates a { @ link LegacyDocument } which the document id , JSON content and the CAS value .
* @ param id the per - bucket unique document id .
* @ param content the content of the document .
* @ param cas the CAS ( compare and swap ) value for optimistic concurrency .
* @ re... | return new LegacyDocument ( id , 0 , content , cas , null ) ; |
public class ActionType { /** * Create a new action type that matches this cell , and add it to the map ,
* keyed on that column . */
public static void addNewActionType ( final Map < Integer , ActionType > actionTypeMap , final String value , final int column , final int row ) { } } | final String ucValue = value . toUpperCase ( ) ; Code code = tag2code . get ( ucValue ) ; if ( code == null ) { code = tag2code . get ( ucValue . substring ( 0 , 1 ) ) ; } if ( code != null ) { int count = 0 ; for ( ActionType at : actionTypeMap . values ( ) ) { if ( at . getCode ( ) == code ) { count ++ ; } } if ( cou... |
public class Logger { /** * Logs recoverable application error .
* @ param correlationId ( optional ) transaction id to trace execution through
* call chain .
* @ param error an error object associated with this message . */
public void error ( String correlationId , Exception error ) { } } | formatAndWrite ( LogLevel . Error , correlationId , error , null , null ) ; |
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < }
* { @ link EnumIncludeRelationships } { @ code > } */
@ XmlElementDecl ( namespace = "http://docs.oasis-open.org/ns/cmis/messaging/200908/" , name = "includeRelationships" , scope = GetCheckedOutDocs . class ) public JAXBElem... | return new JAXBElement < EnumIncludeRelationships > ( _GetObjectOfLatestVersionIncludeRelationships_QNAME , EnumIncludeRelationships . class , GetCheckedOutDocs . class , value ) ; |
public class RecyclerView { /** * Return the adapter position that the given child view corresponds to .
* @ param child Child View to query
* @ return Adapter position corresponding to the given view or { @ link # NO _ POSITION } */
public int getChildPosition ( View child ) { } } | final ViewHolder holder = getChildViewHolderInt ( child ) ; return holder != null ? holder . getPosition ( ) : NO_POSITION ; |
public class ApiOvhCaasregistry { /** * Delete namespace
* REST : DELETE / caas / registry / { serviceName } / namespaces / { namespaceId }
* @ param namespaceId [ required ] Namespace id
* @ param serviceName [ required ] Service name
* API beta */
public void serviceName_namespaces_namespaceId_DELETE ( String... | String qPath = "/caas/registry/{serviceName}/namespaces/{namespaceId}" ; StringBuilder sb = path ( qPath , serviceName , namespaceId ) ; exec ( qPath , "DELETE" , sb . toString ( ) , null ) ; |
public class ListAppsResult { /** * List of Amplify Apps .
* @ param apps
* List of Amplify Apps . */
public void setApps ( java . util . Collection < App > apps ) { } } | if ( apps == null ) { this . apps = null ; return ; } this . apps = new java . util . ArrayList < App > ( apps ) ; |
public class UNode { /** * Add the XML required for this node to the given XMLBuilder .
* @ param xml An in - progress XMLBuilder .
* @ throws IllegalArgumentException If an XML construction error occurs . */
public void toXML ( XMLBuilder xml ) throws IllegalArgumentException { } } | assert xml != null ; // Determine what tag name to use for the generated element .
Map < String , String > attrMap = new LinkedHashMap < > ( ) ; String elemName = m_name ; if ( m_tagName . length ( ) > 0 ) { // Place m _ name into a " name " attribute and use m _ tagName
attrMap . put ( "name" , m_name ) ; elemName = m... |
public class GroupMatcher { /** * Create a GroupMatcher that matches groups starting with the given string . */
public static < T extends Key < T > > GroupMatcher < T > groupStartsWith ( final String compareTo ) { } } | return new GroupMatcher < > ( compareTo , StringOperatorName . STARTS_WITH ) ; |
public class Attribute { /** * Set an attribute in the protect bucket of the COSE object
* @ param label CBOR object which identifies the attribute in the map
* @ param value byte array of value
* @ deprecated As of COSE 0.9.0 , use addAttribute ( HeaderKeys , byte [ ] , Attribute . PROTECTED ) ;
* @ exception ... | addAttribute ( label , value , PROTECTED ) ; |
public class Builder { /** * Builds a minimal perfect hash function .
* @ return a { @ link CHDMinimalPerfectHashFunction } instance with the specified parameters .
* @ throws IllegalStateException if called more than once . */
public CHDMinimalPerfectHashFunction < T > build ( ) throws IOException { } } | if ( built ) throw new IllegalStateException ( "This builder has been already used" ) ; built = true ; if ( transform == null ) { if ( chunkedHashStore != null ) transform = chunkedHashStore . transform ( ) ; else throw new IllegalArgumentException ( "You must specify a TransformationStrategy, either explicitly or via ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.