signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class IotHubResourcesInner { /** * Delete an IoT hub .
* Delete an IoT hub .
* @ param resourceGroupName The name of the resource group that contains the IoT hub .
* @ param resourceName The name of the IoT hub .
* @ throws IllegalArgumentException thrown if parameters fail the validation
* @ throws Er... | return deleteWithServiceResponseAsync ( resourceGroupName , resourceName ) . toBlocking ( ) . last ( ) . body ( ) ; |
public class CustomFieldValueReader { /** * Convert raw value as read from the MPP file into a Java type .
* @ param type MPP value type
* @ param value raw value data
* @ return Java object */
protected Object getTypedValue ( int type , byte [ ] value ) { } } | Object result ; switch ( type ) { case 4 : // Date
{ result = MPPUtility . getTimestamp ( value , 0 ) ; break ; } case 6 : // Duration
{ TimeUnit units = MPPUtility . getDurationTimeUnits ( MPPUtility . getShort ( value , 4 ) , m_properties . getDefaultDurationUnits ( ) ) ; result = MPPUtility . getAdjustedDuration ( m... |
public class WebUtils { /** * 执行HTTP POST请求 , 可使用代理proxy 。
* @ param url 请求地址
* @ param params 请求参数
* @ param charset 字符集 , 如UTF - 8 , GBK , GB2312
* @ param connectTimeout 连接超时时间
* @ param readTimeout 请求超时时间
* @ param proxyHost 代理host , 传null表示不使用代理
* @ param proxyPort 代理端口 , 传0表示不使用代理
* @ return 响应字符串... | String ctype = "application/x-www-form-urlencoded;charset=" + charset ; String query = buildQuery ( params , charset ) ; byte [ ] content = { } ; if ( query != null ) { content = query . getBytes ( charset ) ; } return doPost ( url , ctype , content , connectTimeout , readTimeout , proxyHost , proxyPort ) ; |
public class Block { /** * { @ inheritDoc } */
public int compareTo ( Block b ) { } } | // Wildcard generationStamp is NOT ALLOWED here
validateGenerationStamp ( this . generationStamp ) ; validateGenerationStamp ( b . generationStamp ) ; if ( blockId < b . blockId ) { return - 1 ; } else if ( blockId == b . blockId ) { return GenerationStamp . compare ( generationStamp , b . generationStamp ) ; } else { ... |
public class CountingLruMap { /** * Removes all the matching elements from the map . */
public synchronized ArrayList < V > removeAll ( @ Nullable Predicate < K > predicate ) { } } | ArrayList < V > oldValues = new ArrayList < > ( ) ; Iterator < LinkedHashMap . Entry < K , V > > iterator = mMap . entrySet ( ) . iterator ( ) ; while ( iterator . hasNext ( ) ) { LinkedHashMap . Entry < K , V > entry = iterator . next ( ) ; if ( predicate == null || predicate . apply ( entry . getKey ( ) ) ) { oldValu... |
public class BytecodeHelper { /** * array types are special :
* eg . : String [ ] : classname : [ Ljava . lang . String ;
* Object : classname : java . lang . Object
* int [ ] : classname : [ I
* unlike getTypeDescription ' . ' is not replaced by ' / ' .
* it seems that makes problems for
* the class loadin... | StringBuilder buf = new StringBuilder ( ) ; boolean array = false ; while ( true ) { if ( c . isArray ( ) ) { buf . append ( '[' ) ; c = c . getComponentType ( ) ; array = true ; } else { if ( ClassHelper . isPrimitiveType ( c ) ) { buf . append ( getTypeDescription ( c ) ) ; } else { if ( array ) buf . append ( 'L' ) ... |
public class KeyVaultClientBaseImpl { /** * Deletes a certificate from a specified key vault .
* Deletes all versions of a certificate object along with its associated policy . Delete certificate cannot be used to remove individual versions of a certificate object . This operation requires the certificates / delete p... | return deleteCertificateWithServiceResponseAsync ( vaultBaseUrl , certificateName ) . map ( new Func1 < ServiceResponse < DeletedCertificateBundle > , DeletedCertificateBundle > ( ) { @ Override public DeletedCertificateBundle call ( ServiceResponse < DeletedCertificateBundle > response ) { return response . body ( ) ;... |
public class LoggerWrapper { /** * Delegate to the appropriate method of the underlying logger . */
public void warn ( String format , Object arg1 , Object arg2 ) { } } | if ( ! logger . isWarnEnabled ( ) ) return ; if ( instanceofLAL ) { String formattedMessage = MessageFormatter . format ( format , arg1 , arg2 ) . getMessage ( ) ; ( ( LocationAwareLogger ) logger ) . log ( null , fqcn , LocationAwareLogger . WARN_INT , formattedMessage , new Object [ ] { arg1 , arg2 } , null ) ; } els... |
public class AssignedDeclaration { /** * Computes the priority order of the declaration based on its origin and importance
* according to the CSS specification .
* @ return The priority order ( 1 . . 5 ) .
* @ see < a href = " http : / / www . w3 . org / TR / CSS21 / cascade . html # cascading - order " > http : ... | if ( important ) { if ( origin == StyleSheet . Origin . AUTHOR ) return 4 ; else if ( origin == StyleSheet . Origin . AGENT ) return 1 ; else return 5 ; } else { if ( origin == StyleSheet . Origin . AUTHOR ) return 3 ; else if ( origin == StyleSheet . Origin . AGENT ) return 1 ; else return 2 ; } |
public class Img { /** * Creates an Img sharing the specified BufferedImage ' s data . Changes in
* the BufferdImage are reflected in the created Img and vice versa .
* Only BufferedImages with DataBuffer of { @ link DataBuffer # TYPE _ INT } can
* be used since the Img class uses an int [ ] to store its data . A... | int type = bimg . getRaster ( ) . getDataBuffer ( ) . getDataType ( ) ; if ( type != DataBuffer . TYPE_INT ) { throw new IllegalArgumentException ( String . format ( "cannot create Img as remote of provided BufferedImage!%n" + "Need BufferedImage with DataBuffer of type TYPE_INT (%d). Provided type: %d" , DataBuffer . ... |
public class CleaneLingSolver { /** * Distills units and subsumes / strengthens clauses . */
private void distill ( ) { } } | final long steps = this . limits . simpSteps ; assert this . level == 0 ; assert ! this . config . plain ; if ( ! this . config . distill ) { return ; } final long limit = this . stats . steps + steps / sizePenalty ( ) ; boolean changed = false ; boolean done = this . clauses . empty ( ) ; if ( this . distilled >= this... |
public class Traverson { /** * Iterates over pages by following ' prev ' links . For every page , a { @ code Traverson } is created and provided as a
* parameter to the callback function .
* < pre >
* prev
* . . . - - & gt ; HalRepresentation - - & gt ; HalRepresentation
* v N item v N item
* & lt ; embedde... | paginateAs ( "prev" , HalRepresentation . class , embeddedTypeInfo , pageHandler ) ; |
public class Str { /** * use { @ link Str # joinArgs ( String , Object . . . ) }
* @ param separator
* @ param strings
* @ return */
@ Deprecated public < T > String join1 ( String separator , Object ... strings ) { } } | return joinArgs ( separator , strings ) ; |
public class scpolicy { /** * Use this API to fetch all the scpolicy resources that are configured on netscaler . */
public static scpolicy [ ] get ( nitro_service service ) throws Exception { } } | scpolicy obj = new scpolicy ( ) ; scpolicy [ ] response = ( scpolicy [ ] ) obj . get_resources ( service ) ; return response ; |
public class ExpressionParser { /** * The auxiliary method allows to form a function and its arguments as a tree
* @ param function the function which arguments will be read from the stream , must not be null
* @ param reader the reader to be used as the character source , must not be null
* @ param context a pre... | final ExpressionItem expectedBracket = nextItem ( reader , context ) ; if ( expectedBracket == null ) { throw context . makeException ( "Detected function without params [" + function . getName ( ) + ']' , null ) ; } final int arity = function . getArity ( ) ; ExpressionTree functionTree ; if ( arity == 0 ) { final Exp... |
public class DocumentRootImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public void setStringParameter ( StringParameterType newStringParameter ) { } } | ( ( FeatureMap . Internal ) getMixed ( ) ) . set ( BpsimPackage . Literals . DOCUMENT_ROOT__STRING_PARAMETER , newStringParameter ) ; |
public class IncludeValue { /** * Get configuration name of the linked config
* @ return configuration name of the linked config */
public ConfigurationSourceKey getConfigName ( ) { } } | return new ConfigurationSourceKey ( ConfigurationSourceKey . Type . FILE , ConfigurationSourceKey . Format . JSON , configurationName ) ; |
public class AstBuilder { /** * statement { - - - - - */
@ Override public AssertStatement visitAssertStatement ( AssertStatementContext ctx ) { } } | visitingAssertStatementCnt ++ ; Expression conditionExpression = ( Expression ) this . visit ( ctx . ce ) ; if ( conditionExpression instanceof BinaryExpression ) { BinaryExpression binaryExpression = ( BinaryExpression ) conditionExpression ; if ( binaryExpression . getOperation ( ) . getType ( ) == Types . ASSIGN ) {... |
public class AntTask { /** * Creates a instance of an annotation class name that suppresses error reporting in classes / methods / fields . */
public SuppressAnnotationType createSuppressAnnotation ( ) { } } | final SuppressAnnotationType s = new SuppressAnnotationType ( ) ; s . setProject ( getProject ( ) ) ; suppressAnnotations . add ( s ) ; return s ; |
public class Call { /** * Abbreviation for { { @ link # methodForSetOf ( Type , String , Object . . . ) } .
* @ since 1.1
* @ param methodName the name of the method
* @ param optionalParameters the ( optional ) parameters of the method .
* @ return the result of the method execution */
public static < R > Func... | return methodForSetOf ( resultType , methodName , optionalParameters ) ; |
public class DWOF { /** * This method applies a density based clustering algorithm .
* It looks for an unclustered object and builds a new cluster for it , then
* adds all the points within its radius to that cluster .
* nChain represents the points to be added to the cluster and its
* radius - neighbors
* @ ... | FiniteProgress clustProg = LOG . isVerbose ( ) ? new FiniteProgress ( "Density-Based Clustering" , ids . size ( ) , LOG ) : null ; // Iterate over all objects
for ( DBIDIter iter = ids . iter ( ) ; iter . valid ( ) ; iter . advance ( ) ) { if ( labels . get ( iter ) != null ) { continue ; } ModifiableDBIDs newCluster =... |
public class BlockCanaryUi { /** * Converts from device independent pixels ( dp or dip ) to
* device dependent pixels . This method returns the input
* multiplied by the display ' s density . The result is not
* rounded nor clamped .
* The value returned by this method is well suited for
* drawing with the Ca... | DisplayMetrics metrics = resources . getDisplayMetrics ( ) ; return metrics . density * dp ; |
public class BufferingHintsMarshaller { /** * Marshall the given parameter object . */
public void marshall ( BufferingHints bufferingHints , ProtocolMarshaller protocolMarshaller ) { } } | if ( bufferingHints == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( bufferingHints . getSizeInMBs ( ) , SIZEINMBS_BINDING ) ; protocolMarshaller . marshall ( bufferingHints . getIntervalInSeconds ( ) , INTERVALINSECONDS_BINDING ) ; } catc... |
public class ResourcePathComponentMarshaller { /** * Marshall the given parameter object . */
public void marshall ( ResourcePathComponent resourcePathComponent , ProtocolMarshaller protocolMarshaller ) { } } | if ( resourcePathComponent == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( resourcePathComponent . getId ( ) , ID_BINDING ) ; protocolMarshaller . marshall ( resourcePathComponent . getName ( ) , NAME_BINDING ) ; } catch ( Exception e ) {... |
public class ThreadContextAccessor { /** * Resets the context class loader of the current thread after a call to { @ link # pushContextClassLoaderForUnprivileged } or { @ link # repushContextClassLoaderForUnprivileged } .
* This method does
* nothing if the specified class loader is { @ link # UNCHANGED } . Otherwi... | if ( origLoader != UNCHANGED ) { setContextClassLoaderForUnprivileged ( Thread . currentThread ( ) , ( ClassLoader ) origLoader ) ; } |
public class QueuedFuture { /** * { @ inheritDoc } */
@ Override @ FFDCIgnore ( { } } | ExecutionException . class } ) public boolean isCancelled ( ) { Future < Future < R > > resultFuture = getResultFuture ( ) ; if ( resultFuture . isDone ( ) ) { if ( resultFuture . isCancelled ( ) ) { return true ; } else { try { Future < R > innerFuture = resultFuture . get ( ) ; return innerFuture . isCancelled ( ) ; ... |
public class DistributedExceptionInfo { /** * Get a specific exception in a possible chain of exceptions .
* If there are multiple exceptions in the chain , the most recent one thrown
* will be returned .
* If the exceptions does not exist or no exceptions have been chained ,
* null will be returned .
* @ exc... | if ( exceptionClassName == null ) { return null ; } Throwable ex = null ; if ( previousExceptionInfo != null ) { if ( previousExceptionInfo . getClassName ( ) . equals ( exceptionClassName ) ) { ex = getPreviousException ( ) ; } else { ex = previousExceptionInfo . getException ( exceptionClassName ) ; } } return ex ; |
public class BaseApplet { /** * Display the logon dialog and login .
* @ return */
public int onLogonDialog ( ) { } } | String strDisplay = "Login required" ; strDisplay = this . getTask ( ) . getString ( strDisplay ) ; for ( int i = 1 ; i < 3 ; i ++ ) { String strUserName = this . getProperty ( Params . USER_NAME ) ; Frame frame = ScreenUtil . getFrame ( this ) ; LoginDialog dialog = new LoginDialog ( frame , true , strDisplay , strUse... |
public class UpdatePrimaryEmailAddressRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( UpdatePrimaryEmailAddressRequest updatePrimaryEmailAddressRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( updatePrimaryEmailAddressRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( updatePrimaryEmailAddressRequest . getOrganizationId ( ) , ORGANIZATIONID_BINDING ) ; protocolMarshaller . marshall ( updatePrimaryEmailAddressRequest .... |
public class ChannelFrameworkImpl { /** * @ seecom . ibm . wsspi . channelfw . ChannelFramework # removeGroupEventListener (
* ChainEventListener , String ) */
@ Override public synchronized void removeGroupEventListener ( ChainEventListener cel , String groupName ) throws ChainGroupException { } } | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { Tr . entry ( tc , "removeGroupEventListener" ) ; } if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "groupName=" + groupName ) ; Tr . debug ( tc , "Listener=" + cel ) ; } // Find the chain group .
... |
public class GenericDao { /** * 查询符合条件组合的记录数
* @ param matches
* @ return 2013-8-26 下午3:04:02 created by wangchongjie */
public int count ( List < Match > matches ) { } } | Query query = queryGenerator . getCountQuery ( matches ) ; // 执行操作
String sql = query . getSql ( ) ; return countBySQL ( sql , query . getParams ( ) ) ; |
public class Cycles { /** * Obtain the bond between the atoms at index ' u ' and ' v ' . If the ' bondMap '
* is non - null it is used for direct lookup otherwise the slower linear
* lookup in ' container ' is used .
* @ param container a structure
* @ param bondMap optimised map of atom indices to bond instanc... | if ( bondMap != null ) return bondMap . get ( u , v ) ; return container . getBond ( container . getAtom ( u ) , container . getAtom ( v ) ) ; |
public class AuthTokenUtil { /** * Adds a digital signature to the auth token .
* @ param token the auth token */
public static final void signAuthToken ( AuthToken token ) { } } | String signature = generateSignature ( token ) ; token . setSignature ( signature ) ; |
public class MIORGImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ SuppressWarnings ( "unchecked" ) @ Override public void eSet ( int featureID , Object newValue ) { } } | switch ( featureID ) { case AfplibPackage . MIORG__RG_LENGTH : setRGLength ( ( Integer ) newValue ) ; return ; case AfplibPackage . MIORG__TRIPLETS : getTriplets ( ) . clear ( ) ; getTriplets ( ) . addAll ( ( Collection < ? extends Triplet > ) newValue ) ; return ; } super . eSet ( featureID , newValue ) ; |
public class ObjectAnimator { /** * Constructs and returns an ObjectAnimator that animates between float values . A single
* value implies that that value is the one being animated to . Two values imply a starting
* and ending values . More than two values imply a starting value , values to animate through
* alon... | ObjectAnimator anim = new ObjectAnimator ( target , property ) ; anim . setFloatValues ( values ) ; return anim ; |
public class CommerceNotificationTemplateLocalServiceBaseImpl { /** * Returns all the commerce notification templates matching the UUID and company .
* @ param uuid the UUID of the commerce notification templates
* @ param companyId the primary key of the company
* @ return the matching commerce notification temp... | return commerceNotificationTemplatePersistence . findByUuid_C ( uuid , companyId ) ; |
public class AbstractCache { /** * The static method removes all values in all caches . */
public static void clearCaches ( ) { } } | synchronized ( AbstractCache . CACHES ) { for ( final AbstractCache < ? > cache : AbstractCache . CACHES ) { cache . getCache4Id ( ) . clear ( ) ; cache . getCache4Name ( ) . clear ( ) ; cache . getCache4UUID ( ) . clear ( ) ; } } |
public class AmazonCloudWatchClient { /** * Deletes all dashboards that you specify . You may specify up to 100 dashboards to delete . If there is an error
* during this call , no dashboards are deleted .
* @ param deleteDashboardsRequest
* @ return Result of the DeleteDashboards operation returned by the service... | request = beforeClientExecution ( request ) ; return executeDeleteDashboards ( request ) ; |
public class StepImpl { /** * If not already created , a new < code > partition < / code > element with the given value will be created .
* Otherwise , the existing < code > partition < / code > element will be returned .
* @ return a new or existing instance of < code > Partition < Step < T > > < / code > */
publi... | Node node = childNode . getOrCreate ( "partition" ) ; Partition < Step < T > > partition = new PartitionImpl < Step < T > > ( this , "partition" , childNode , node ) ; return partition ; |
public class ParallelScanner { /** * This method gets a segmentedScanResult and submits the next scan request for that segment , if there is one .
* @ return the next available ScanResult
* @ throws ExecutionException if one of the segment pages threw while executing
* @ throws InterruptedException if one of the ... | final Future < ScanContext > ret = exec . take ( ) ; final ScanRequest originalRequest = ret . get ( ) . getScanRequest ( ) ; final int segment = originalRequest . getSegment ( ) ; final ScanSegmentWorker sw = workers [ segment ] ; if ( sw . hasNext ( ) ) { currentFutures [ segment ] = exec . submit ( sw ) ; } else { f... |
public class JmsJMSContextImpl { /** * ( non - Javadoc )
* @ see javax . jms . JMSContext # createBrowser ( javax . jms . Queue , java . lang . String ) */
@ Override public QueueBrowser createBrowser ( Queue queue , String messageSelector ) throws JMSRuntimeException , InvalidDestinationRuntimeException , InvalidSel... | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( this , tc , "createBrowser" , new Object [ ] { queue , messageSelector } ) ; QueueBrowser queueBrowser = null ; try { queueBrowser = jmsSession . createBrowser ( queue , messageSelector ) ; } catch ( InvalidDestinationException i... |
public class KeyStoreHelper { /** * Load the specified secret key entry from the provided key store .
* @ param aKeyStore
* The key store to load the key from . May not be < code > null < / code > .
* @ param sKeyStorePath
* Key store path . For nice error messages only . May be
* < code > null < / code > .
... | return _loadKey ( aKeyStore , sKeyStorePath , sKeyStoreKeyAlias , aKeyStoreKeyPassword , KeyStore . SecretKeyEntry . class ) ; |
public class BuildUtil { /** * Read the value of an extra property of the project .
* @ param pExtraPropName the reference to the extra property name
* @ param < T > type of the property value
* @ return the property ' s value */
@ SuppressWarnings ( "unchecked" ) public < T > T getExtraPropertyValue ( @ Nonnull ... | ExtraPropertiesExtension extraProps = project . getExtensions ( ) . getByType ( ExtraPropertiesExtension . class ) ; if ( extraProps . has ( pExtraPropName . getPropertyName ( ) ) ) { return ( T ) extraProps . get ( pExtraPropName . getPropertyName ( ) ) ; } throw new GradleException ( "Reference to non-existent projec... |
public class BaseDaoImpl { /** * 分页查询list总条目数 */
@ Override public int count ( HashMap < Object , Object > hashMap ) { } } | String count = "count" + clazz . getSimpleName ( ) + "sByConditions" ; System . out . println ( count ) ; return sqlSessionTemplate . selectOne ( count , hashMap ) ; |
public class PolicyDefinitionsInner { /** * Creates or updates a policy definition .
* @ param policyDefinitionName The name of the policy definition to create .
* @ param parameters The policy definition properties .
* @ throws IllegalArgumentException thrown if parameters fail the validation
* @ throws CloudE... | return createOrUpdateWithServiceResponseAsync ( policyDefinitionName , parameters ) . toBlocking ( ) . single ( ) . body ( ) ; |
public class ClassLoaderUtils { /** * Gets an appropriate classloader for usage when performing classpath
* lookups and scanning .
* @ return */
public static ClassLoader getParentClassLoader ( ) { } } | logger . debug ( "getParentClassLoader() invoked, web start mode: {}" , IS_WEB_START ) ; if ( IS_WEB_START ) { return Thread . currentThread ( ) . getContextClassLoader ( ) ; } else { return ClassLoaderUtils . class . getClassLoader ( ) ; } |
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } { @ link TextType }
* { @ code > } */
@ XmlElementDecl ( namespace = "http://www.w3.org/2005/Atom" , name = "rights" , scope = SourceType . class ) public JAXBElement < TextType > createSourceTypeRights ( TextType value ) { }... | return new JAXBElement < TextType > ( ENTRY_TYPE_RIGHTS_QNAME , TextType . class , SourceType . class , value ) ; |
public class Optional { /** * Returns an empty { @ code Optional } .
* @ param < T > the type of value
* @ return an { @ code Optional } */
@ NotNull @ Contract ( pure = true ) @ SuppressWarnings ( "unchecked" ) public static < T > Optional < T > empty ( ) { } } | return ( Optional < T > ) EMPTY ; |
public class MockArtifactStore { /** * { @ inheritDoc } */
public synchronized long getLastModified ( Artifact artifact ) throws IOException , ArtifactNotFoundException { } } | Map < String , Map < String , Map < Artifact , Content > > > artifactMap = contents . get ( artifact . getGroupId ( ) ) ; Map < String , Map < Artifact , Content > > versionMap = ( artifactMap == null ? null : artifactMap . get ( artifact . getArtifactId ( ) ) ) ; Map < Artifact , Content > filesMap = ( versionMap == n... |
public class KieModuleDeploymentHelperImpl { /** * Create the pom that will be placed in the KJar .
* @ param releaseId The release ( deployment ) id .
* @ param dependencies The list of dependendencies to be added to the pom
* @ return A string representation of the pom . */
private static String getPomText ( Re... | String pom = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" + "<project xmlns=\"http://maven.apache.org/POM/4.0.0\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n" + " xsi:schemaLocation=\"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd\">\n" + " <modelVersion>4.0.0</model... |
public class TupleMRConfigBuilder { /** * Adds a Map - output schema . Tuples emitted by TupleMapper will use one of the
* schemas added by this method . Schemas added in consecutive calls to this
* method must be named differently . */
public void addIntermediateSchema ( Schema schema ) throws TupleMRException { }... | if ( schemaAlreadyExists ( schema . getName ( ) ) ) { throw new TupleMRException ( "There's a schema with that name '" + schema . getName ( ) + "'" ) ; } schemas . add ( schema ) ; |
public class BaseClassFinderService { /** * Convert this encoded string back to a Java Object .
* @ param versionRange version
* @ param string The string to convert .
* @ return The java object . */
public Object convertStringToObject ( Object resource , String className , String versionRange , String string ) {... | if ( ( string == null ) || ( string . length ( ) == 0 ) ) return null ; Object object = null ; try { if ( resource == null ) { Object classAccess = this . getClassBundleService ( null , className , versionRange , null , 0 ) ; if ( classAccess != null ) object = this . convertStringToObject ( string ) ; } else { /* Bund... |
public class ObjectInputStream { /** * Reads an object from the input stream that was previously written with { @ link
* ObjectOutputStream # writeBareObject ( Object ) } .
* @ param object the object to be populated from data on the stream . It cannot be
* < code > null < / code > . */
public void readBareObject... | readBareObject ( object , Streamer . getStreamer ( object . getClass ( ) ) , true ) ; |
public class AlexaRequestStreamHandler { /** * Provides the speechlet used to handle the request .
* @ return speechlet used to handle the request . */
public Class < ? extends AlexaSpeechlet > getSpeechlet ( ) { } } | final AlexaApplication app = this . getClass ( ) . getAnnotation ( AlexaApplication . class ) ; return app != null ? app . speechlet ( ) : AlexaSpeechlet . class ; |
public class ScreenSizeExtensions { /** * Gets the screen ID from the given component
* @ param component
* the component
* @ return the screen ID */
public static int getScreenID ( Component component ) { } } | int screenID ; final AtomicInteger counter = new AtomicInteger ( - 1 ) ; Stream . of ( getScreenDevices ( ) ) . forEach ( graphicsDevice -> { GraphicsConfiguration gc = graphicsDevice . getDefaultConfiguration ( ) ; Rectangle rectangle = gc . getBounds ( ) ; if ( rectangle . contains ( component . getLocation ( ) ) ) {... |
public class Mapping { /** * Map a bean to a column mutation . i . e . set the columns in the mutation to
* the corresponding values from the instance
* @ param instance
* instance
* @ param mutation
* mutation */
public void fillMutation ( T instance , ColumnListMutation < String > mutation ) { } } | for ( String fieldName : getNames ( ) ) { Coercions . setColumnMutationFromField ( instance , fields . get ( fieldName ) , fieldName , mutation ) ; } |
public class EventSubscriber { /** * This method validates the given ( received ) NOTIFY request , updates the subscription information
* based on the NOTIFY contents , and creates and returns the correctly formed response that should
* be sent back in reply to the NOTIFY , based on the NOTIFY content that was rece... | initErrorInfo ( ) ; String cseqStr = "CSEQ x" ; try { if ( ( requestEvent == null ) || ( getLastSentRequest ( ) == null ) ) { setReturnCode ( SipSession . INVALID_OPERATION ) ; setErrorMessage ( "Request event is null and/or last sent request is null" ) ; return null ; } Request request = requestEvent . getRequest ( ) ... |
public class OpChain { /** * { @ inheritDoc }
* This is an intermediate result . Its result is not directly returned .
* Assign the value to a variable if you need access to it later . */
@ Override public void resolve ( final ValueStack values ) throws Exception { } } | if ( values . size ( ) < 2 ) throw new ParseException ( "missing operand" , 0 ) ; try { final Object rightSideResult = values . popWhatever ( ) ; values . popWhatever ( ) ; values . push ( rightSideResult ) ; } catch ( final ParseException e ) { e . fillInStackTrace ( ) ; throw new Exception ( toString ( ) + "; " + e .... |
public class ComputerVisionImpl { /** * This operation generates a list of words , or tags , that are relevant to the content of the supplied image . The Computer Vision API can return tags based on objects , living beings , scenery or actions found in images . Unlike categories , tags are not organized according to a ... | if ( this . client . endpoint ( ) == null ) { throw new IllegalArgumentException ( "Parameter this.client.endpoint() is required and cannot be null." ) ; } if ( url == null ) { throw new IllegalArgumentException ( "Parameter url is required and cannot be null." ) ; } final String language = tagImageOptionalParameter !=... |
public class Page { /** * Finds a Page by its name ( not the full qualified name ) .
* Create a instance or use instance if already exist ( com . google . inject . @ Singleton ) .
* @ param className
* The name of the class to find . Full qualified name is not required .
* Ex : ' MyPage ' or ' mypackageinpages ... | try { return ( Page ) NoraUiInjector . getNoraUiInjectorSource ( ) . getInstance ( Class . forName ( pagesPackage + className ) ) ; } catch ( final ClassNotFoundException e ) { throw new TechnicalException ( Messages . format ( Messages . getMessage ( PAGE_UNABLE_TO_RETRIEVE ) , className ) , e ) ; } |
public class ManagementLocksInner { /** * Gets a management lock at the resource group level .
* @ param resourceGroupName The name of the locked resource group .
* @ param lockName The name of the lock to get .
* @ throws IllegalArgumentException thrown if parameters fail the validation
* @ throws CloudExcepti... | return getByResourceGroupWithServiceResponseAsync ( resourceGroupName , lockName ) . toBlocking ( ) . single ( ) . body ( ) ; |
public class ArgumentConvertor { /** * If argument is annotated with JsonUnmarshaller annotation , get the JsonUnmarshaller class
* @ param annotations
* @ param paramType
* @ return */
Class < ? extends IJsonMarshaller > getMarshallerAnnotation ( Annotation [ ] annotations ) { } } | JsonUnmarshaller ju = getJsonUnmarshallerAnnotation ( annotations ) ; return ( ju != null ) ? ju . value ( ) : null ; |
public class ModCheckBase { /** * valid check .
* @ param value value to check .
* @ param context constraint validator context
* @ return true if valid */
public boolean isValid ( final CharSequence value , final ConstraintValidatorContext context ) { } } | if ( value == null ) { return true ; } final String valueAsString = value . toString ( ) ; String digitsAsString ; char checkDigit ; try { digitsAsString = this . extractVerificationString ( valueAsString ) ; checkDigit = this . extractCheckDigit ( valueAsString ) ; } catch ( final IndexOutOfBoundsException e ) { retur... |
public class LogBase { /** * Log a message , with an array of object arguments .
* If the logger is currently enabled for the given message
* level then the given message is forwarded to all the
* registered LogTarget objects .
* @ param level the level to log with
* @ param message the message to log
* @ p... | this . log ( level , null , message , arguments ) ; |
public class SetLabelsForNumbersBot { /** * Main method to run the bot .
* @ param args
* @ throws LoginFailedException
* @ throws IOException
* @ throws MediaWikiApiErrorException */
public static void main ( String [ ] args ) throws LoginFailedException , IOException , MediaWikiApiErrorException { } } | ExampleHelpers . configureLogging ( ) ; printDocumentation ( ) ; SetLabelsForNumbersBot bot = new SetLabelsForNumbersBot ( ) ; ExampleHelpers . processEntitiesFromWikidataDump ( bot ) ; bot . finish ( ) ; System . out . println ( "*** Done." ) ; |
public class Scte35TimeSignalScheduleActionSettingsMarshaller { /** * Marshall the given parameter object . */
public void marshall ( Scte35TimeSignalScheduleActionSettings scte35TimeSignalScheduleActionSettings , ProtocolMarshaller protocolMarshaller ) { } } | if ( scte35TimeSignalScheduleActionSettings == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( scte35TimeSignalScheduleActionSettings . getScte35Descriptors ( ) , SCTE35DESCRIPTORS_BINDING ) ; } catch ( Exception e ) { throw new SdkClientExc... |
public class Ifc2x3tc1PackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public EEnum getIfcRoofTypeEnum ( ) { } } | if ( ifcRoofTypeEnumEEnum == null ) { ifcRoofTypeEnumEEnum = ( EEnum ) EPackage . Registry . INSTANCE . getEPackage ( Ifc2x3tc1Package . eNS_URI ) . getEClassifiers ( ) . get ( 889 ) ; } return ifcRoofTypeEnumEEnum ; |
public class NumberParser { /** * Scan the string for an SVG number .
* Assumes maxPos will not be greater than str . length ( ) . */
float parseNumber ( String input , int startpos , int len ) { } } | boolean isNegative = false ; long significand = 0 ; int numDigits = 0 ; int numLeadingZeroes = 0 ; int numTrailingZeroes = 0 ; boolean decimalSeen = false ; int sigStart ; int decimalPos = 0 ; int exponent ; long TOO_BIG = Long . MAX_VALUE / 10 ; pos = startpos ; if ( pos >= len ) return Float . NaN ; // String is empt... |
public class WorkflowExecutionCancelRequestedEventAttributesMarshaller { /** * Marshall the given parameter object . */
public void marshall ( WorkflowExecutionCancelRequestedEventAttributes workflowExecutionCancelRequestedEventAttributes , ProtocolMarshaller protocolMarshaller ) { } } | if ( workflowExecutionCancelRequestedEventAttributes == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( workflowExecutionCancelRequestedEventAttributes . getExternalWorkflowExecution ( ) , EXTERNALWORKFLOWEXECUTION_BINDING ) ; protocolMarsha... |
public class XmlReport { /** * { @ inheritDoc } */
public void generate ( Execution execution ) { } } | createEmptyDocument ( ) ; Element element = dom . createElement ( DOCUMENT ) ; root . appendChild ( element ) ; if ( execution . getSections ( ) != null ) { Element sections = dom . createElement ( SECTIONS ) ; root . appendChild ( sections ) ; StringTokenizer st = new StringTokenizer ( execution . getSections ( ) , ",... |
public class ResultUtils { /** * Build single result value from the column
* @ param result
* result
* @ param column
* column index
* @ param dataType
* GeoPackage data type
* @ return value
* @ since 3.1.0 */
public static Object buildSingleResult ( Result result , int column , GeoPackageDataType data... | Object value = null ; try { if ( result . moveToNext ( ) ) { value = result . getValue ( column , dataType ) ; } } finally { result . close ( ) ; } return value ; |
public class ChannelzService { /** * Returns a subchannel . */
@ Override public void getSubchannel ( GetSubchannelRequest request , StreamObserver < GetSubchannelResponse > responseObserver ) { } } | InternalInstrumented < ChannelStats > s = channelz . getSubchannel ( request . getSubchannelId ( ) ) ; if ( s == null ) { responseObserver . onError ( Status . NOT_FOUND . withDescription ( "Can't find subchannel " + request . getSubchannelId ( ) ) . asRuntimeException ( ) ) ; return ; } GetSubchannelResponse resp ; tr... |
public class BDDFactory { /** * Returns an arbitrary model for a given BDD or { @ code null } if there is none .
* @ param bdd the BDD
* @ return an arbitrary model of the BDD */
public Assignment model ( final BDD bdd ) { } } | final int modelBDD = this . kernel . satOne ( bdd . index ( ) ) ; return createAssignment ( modelBDD ) ; |
public class FileHelper { /** * * Method that returns the file contents
* @ param pFileName
* @ return FileContents */
public static String getFileContents ( String pFileName ) throws IOException { } } | String fileContents = null ; InputStream is = new FileInputStream ( pFileName ) ; BufferedReader reader = new BufferedReader ( new InputStreamReader ( is ) ) ; StringBuffer xml = new StringBuffer ( ) ; String aLine = null ; while ( ( aLine = reader . readLine ( ) ) != null ) { xml . append ( aLine ) ; xml . append ( "\... |
public class TurfMeasurement { /** * Takes a line and returns a point at a specified distance along the line .
* @ param line that the point should be placed upon
* @ param distance along the linestring geometry which the point should be placed on
* @ param units one of the units found inside { @ link TurfConstan... | List < Point > coords = line . coordinates ( ) ; double travelled = 0 ; for ( int i = 0 ; i < coords . size ( ) ; i ++ ) { if ( distance >= travelled && i == coords . size ( ) - 1 ) { break ; } else if ( travelled >= distance ) { double overshot = distance - travelled ; if ( overshot == 0 ) { return coords . get ( i ) ... |
public class MtasCRMParser { /** * Process CRM pair .
* @ param mtasTokenIdFactory the mtas token id factory
* @ param position the position
* @ param name the name
* @ param text the text
* @ param currentOffset the current offset
* @ param functionOutputList the function output list
* @ param unknownAnc... | MtasParserType tmpCurrentType ; MtasParserObject currentObject ; if ( ( tmpCurrentType = crmPairTypes . get ( name ) ) != null ) { // get history
HashMap < String , MtasParserObject > currentNamePairHistory ; if ( ! historyPair . containsKey ( name ) ) { currentNamePairHistory = new HashMap < > ( ) ; historyPair . put ... |
public class GetSizeConstraintSetRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( GetSizeConstraintSetRequest getSizeConstraintSetRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( getSizeConstraintSetRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( getSizeConstraintSetRequest . getSizeConstraintSetId ( ) , SIZECONSTRAINTSETID_BINDING ) ; } catch ( Exception e ) { throw new SdkClientException ( "Unable t... |
public class XmlUtils { /** * Helper method for getting qualified name from stax reader given a set of specified schema namespaces
* @ param xmlReader stax reader
* @ param namespaces specified schema namespaces
* @ return qualified element name */
public static String getElementQualifiedName ( XMLStreamReader xm... | String namespaceUri = null ; String localName = null ; switch ( xmlReader . getEventType ( ) ) { case XMLStreamConstants . START_ELEMENT : case XMLStreamConstants . END_ELEMENT : namespaceUri = xmlReader . getNamespaceURI ( ) ; localName = xmlReader . getLocalName ( ) ; break ; default : localName = StringUtils . EMPTY... |
public class PojoSerializerSnapshot { /** * Checks if the new { @ link PojoSerializer } is compatible with a reconfigured instance . */
private static < T > boolean newPojoSerializerIsCompatibleWithReconfiguredSerializer ( PojoSerializer < T > newPojoSerializer , IntermediateCompatibilityResult < T > fieldSerializerCom... | return newPojoHasDifferentSubclassRegistrationOrder ( registeredSubclassSerializerSnapshots , newPojoSerializer ) || previousSerializerHasNonRegisteredSubclasses ( nonRegisteredSubclassSerializerSnapshots ) || fieldSerializerCompatibility . isCompatibleWithReconfiguredSerializer ( ) || preExistingRegistrationsCompatibi... |
public class EnvLoader { /** * Sets a local variable for the current environment .
* @ param name the attribute name
* @ param value the new attribute value
* @ return the old attribute value */
public static Object setAttribute ( String name , Object value ) { } } | ClassLoader loader = Thread . currentThread ( ) . getContextClassLoader ( ) ; return setAttribute ( name , value , loader ) ; |
public class MessageHeader { /** * Prepends a key value pair to the beginning of the
* header . Duplicates are allowed */
public synchronized void prepend ( String k , String v ) { } } | grow ( ) ; for ( int i = nkeys ; i > 0 ; i -- ) { keys [ i ] = keys [ i - 1 ] ; values [ i ] = values [ i - 1 ] ; } keys [ 0 ] = k ; values [ 0 ] = v ; nkeys ++ ; |
public class ProgressionUtil { /** * Initialize the given task progression if not < code > null < / code > .
* < p > The inderterminate state is not changed .
* @ param model is the task progression to initialize .
* @ param min is the minimum value .
* @ param max is the maximum value .
* @ param isAdjusting... | if ( model != null ) { model . setProperties ( min , min , max , isAdjusting ) ; } |
public class ReUtil { /** * 取得内容中匹配的所有结果 , 获得匹配的所有结果中正则对应分组1的内容
* @ param regex 正则
* @ param content 被查找的内容
* @ return 结果列表
* @ since 3.1.2 */
public static List < String > findAllGroup1 ( String regex , CharSequence content ) { } } | return findAll ( regex , content , 1 ) ; |
public class ClientSocketFactory { /** * Returns the latency factory */
public double getLatencyFactor ( ) { } } | long now = CurrentTime . currentTime ( ) ; long decayPeriod = 60000 ; long delta = decayPeriod - ( now - _lastSuccessTime ) ; // decay the latency factor over 60s
if ( delta <= 0 ) return 0 ; else return ( _latencyFactor * delta ) / decayPeriod ; |
public class CommonOps_DSCC { /** * Computes the sum of each row in the input matrix and returns the results in a vector : < br >
* < br >
* b < sub > j < / sub > = sum ( i = 1 : n ; a < sub > ji < / sub > )
* @ param input Input matrix
* @ param output Optional storage for output . Reshaped into a column vecto... | if ( output == null ) { output = new DMatrixRMaj ( input . numRows , 1 ) ; } else { output . reshape ( input . numRows , 1 ) ; } Arrays . fill ( output . data , 0 , input . numRows , 0 ) ; for ( int col = 0 ; col < input . numCols ; col ++ ) { int idx0 = input . col_idx [ col ] ; int idx1 = input . col_idx [ col + 1 ] ... |
public class ImgWMF { /** * Reads the WMF into a template .
* @ param template the template to read to
* @ throws IOException on error
* @ throws DocumentException on error */
public void readWMF ( PdfTemplate template ) throws IOException , DocumentException { } } | setTemplateData ( template ) ; template . setWidth ( getWidth ( ) ) ; template . setHeight ( getHeight ( ) ) ; InputStream is = null ; try { if ( rawData == null ) { is = url . openStream ( ) ; } else { is = new java . io . ByteArrayInputStream ( rawData ) ; } MetaDo meta = new MetaDo ( is , template ) ; meta . readAll... |
public class CmsStaticResourceHandler { /** * Returns whether this servlet should attempt to serve a precompressed
* version of the given static resource . If this method returns true , the
* suffix { @ code . gz } is appended to the URL and the corresponding resource
* is served if it exists . It is assumed that... | String accept = request . getHeader ( "Accept-Encoding" ) ; return ( accept != null ) && accept . contains ( "gzip" ) && ( url . endsWith ( ".js" ) || url . endsWith ( ".css" ) || url . endsWith ( ".html" ) ) ; |
public class TransformRdfGraph { /** * TODO only transform blank nodes that appear within the given graph */
public static void main ( String [ ] args ) throws IOException , TrustyUriException { } } | if ( args . length < 2 ) { throw new RuntimeException ( "Not enough arguments: <file> <graph-uri1> (<graph-uri2> ...)" ) ; } File inputFile = new File ( args [ 0 ] ) ; List < IRI > baseUris = new ArrayList < IRI > ( ) ; for ( int i = 1 ; i < args . length ; i ++ ) { String arg = args [ i ] ; if ( arg . contains ( "://"... |
public class JwtEndpointServices { /** * Extracts the { @ value WebConstants # JWT _ REQUEST _ ATTR } attribute from the
* provided request . That particular attribute is supposed to be created and
* set by the filter directing the request .
* @ param request
* @ param response
* @ return
* @ throws IOExcep... | JwtRequest jwtRequest = ( JwtRequest ) request . getAttribute ( WebConstants . JWT_REQUEST_ATTR ) ; if ( jwtRequest == null ) { String errorMsg = Tr . formatMessage ( tc , "JWT_REQUEST_ATTRIBUTE_MISSING" , new Object [ ] { request . getRequestURI ( ) , WebConstants . JWT_REQUEST_ATTR } ) ; Tr . error ( tc , errorMsg ) ... |
public class AbstractParser { /** * Check to make sure the JSONObject has the specified key and if so return
* the value as a JSONObject . If no key is found null is returned .
* @ param key name of the field to fetch from the json object
* @ param jsonObject object from which to fetch the value
* @ return json... | JSONObject json = null ; try { if ( hasKey ( key , jsonObject ) ) { json = jsonObject . getJSONObject ( key ) ; } } catch ( JSONException e ) { LOGGER . error ( "Could not get JSONObject from JSONObject for key: " + key , e ) ; } return json ; |
public class GCRLINERGImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public Object eGet ( int featureID , boolean resolve , boolean coreType ) { } } | switch ( featureID ) { case AfplibPackage . GCRLINERG__XOSSF : return getXOSSF ( ) ; case AfplibPackage . GCRLINERG__YOFFS : return getYOFFS ( ) ; } return super . eGet ( featureID , resolve , coreType ) ; |
public class UpdateGameSessionQueueRequest { /** * Collection of latency policies to apply when processing game sessions placement requests with player latency
* information . Multiple policies are evaluated in order of the maximum latency value , starting with the lowest
* latency values . With just one policy , i... | if ( this . playerLatencyPolicies == null ) { setPlayerLatencyPolicies ( new java . util . ArrayList < PlayerLatencyPolicy > ( playerLatencyPolicies . length ) ) ; } for ( PlayerLatencyPolicy ele : playerLatencyPolicies ) { this . playerLatencyPolicies . add ( ele ) ; } return this ; |
public class Utils { /** * 配列を { @ link List } に変換します 。
* プリミティブ型の配列をを考慮して処理します 。
* @ param object 変換対象の配列
* @ param componentType 配列の要素のタイプ
* @ return 配列がnullの場合は 、 空のリストに変換します 。
* @ throws IllegalArgumentException { @ literal arrayが配列でない場合 。 componentTypeがサポートしていないプリミティブ型の場合 。 } */
public static L... | ArgUtils . notNull ( componentType , "componentType" ) ; if ( object == null ) { return new ArrayList < > ( ) ; } if ( ! object . getClass ( ) . isArray ( ) ) { throw new IllegalArgumentException ( String . format ( "args0 is not arrays : %s." , object . getClass ( ) . getName ( ) ) ) ; } if ( ! componentType . isPrimi... |
public class WebSocketClientStepInvoker { /** * this is called by web socket thread not Chorus interpreter so log don ' t throw ChorusException , log errors instead */
public void stepFailed ( StepFailedMessage stepFailedMessage ) { } } | ExecutingStep s = executingStep . get ( ) ; if ( ! s . getExecutionUUID ( ) . equals ( stepFailedMessage . getExecutionId ( ) ) ) { // This could happen if chorus interpreter timed out the previous step while waiting for the reply
// Hence log to debug rather than error
log . debug ( "Received a StepFailedMessage for e... |
public class SchemaUpdater { /** * Returns the SQL which located within a package specified by the packageName as
* " dialectname _ version . sql " or " version . sql " .
* @ param version the version number
* @ return SQL or null if the SQL file does not exist */
protected String getSql ( int version ) { } } | Dialect dialect = ( ( SqlManagerImpl ) sqlManager ) . getDialect ( ) ; ClassLoader classLoader = Thread . currentThread ( ) . getContextClassLoader ( ) ; InputStream in = classLoader . getResourceAsStream ( String . format ( "%s/%s_%d.sql" , packageName , dialect . getName ( ) . toLowerCase ( ) , version ) ) ; if ( in ... |
public class BitsUtil { /** * Clear bit number " off " in v .
* Low - endian layout for the array .
* @ param v Buffer
* @ param off Offset to clear */
public static long [ ] clearI ( long [ ] v , int off ) { } } | final int wordindex = off >>> LONG_LOG2_SIZE ; v [ wordindex ] &= ~ ( 1L << off ) ; return v ; |
public class MagnetManager { /** * Right now it only works with provided FOUR or EIGHT cardinals , anything else will break WiresConnector autoconnection
* @ param wiresShape
* @ param requestedCardinals
* @ return */
public Magnets createMagnets ( final WiresShape wiresShape , final Direction [ ] requestedCardin... | final IPrimitive < ? > primTarget = wiresShape . getGroup ( ) ; final Point2DArray points = getWiresIntersectionPoints ( wiresShape , requestedCardinals ) ; final ControlHandleList list = new ControlHandleList ( primTarget ) ; final BoundingBox box = wiresShape . getPath ( ) . getBoundingBox ( ) ; final Point2D primLoc... |
public class ConnectionUtils { /** * Remove the { @ link ConnectionData } associated to the provider ID and user ID .
* @ param providerId the provider ID of the connection
* @ param providerUserId the provider user ID
* @ param profile the profile where to remove the data from */
public static void removeConnect... | Map < String , List < Map < String , Object > > > allConnections = profile . getAttribute ( CONNECTIONS_ATTRIBUTE_NAME ) ; if ( MapUtils . isNotEmpty ( allConnections ) ) { List < Map < String , Object > > connectionsForProvider = allConnections . get ( providerId ) ; if ( CollectionUtils . isNotEmpty ( connectionsForP... |
public class WikipediaXMLReader { /** * Reads the namespaces from the siteinfo section and processes them
* in order to initialize the ArticleFilter */
private void initNamespaces ( ) { } } | Map < Integer , String > namespaceMap = new HashMap < Integer , String > ( ) ; try { int b = read ( ) ; this . keywords . reset ( ) ; StringBuilder buffer = null ; while ( b != - 1 ) { // System . out . print ( ( char ) b ) ;
if ( buffer != null ) { buffer . append ( ( char ) b ) ; } if ( this . keywords . check ( ( ch... |
public class SeleniumHelper { /** * Simulates ' cut ' ( e . g . Ctrl + X on Windows ) on the active element , copying the current selection to the clipboard
* and removing that selection .
* @ return whether an active element was found . */
public boolean cut ( ) { } } | boolean result = false ; WebElement element = getActiveElement ( ) ; if ( element != null ) { if ( connectedToMac ( ) ) { element . sendKeys ( Keys . chord ( Keys . CONTROL , Keys . INSERT ) , Keys . BACK_SPACE ) ; } else { element . sendKeys ( Keys . CONTROL , "x" ) ; } result = true ; } return result ; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.