signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class ClassificationService { /** * Returns the total effort points in all of the { @ link ClassificationModel } s associated with the provided { @ link FileModel } . */
public int getMigrationEffortPoints ( FileModel fileModel ) { } } | GraphTraversal < Vertex , Vertex > classificationPipeline = new GraphTraversalSource ( getGraphContext ( ) . getGraph ( ) ) . V ( fileModel . getElement ( ) ) ; classificationPipeline . in ( ClassificationModel . FILE_MODEL ) ; classificationPipeline . has ( EffortReportModel . EFFORT , P . gt ( 0 ) ) ; classificationP... |
public class HeaderFooterRecyclerAdapter { /** * Notifies that a content item is inserted .
* @ param position the position of the content item . */
public final void notifyContentItemInserted ( int position ) { } } | int newHeaderItemCount = getHeaderItemCount ( ) ; int newContentItemCount = getContentItemCount ( ) ; if ( position < 0 || position >= newContentItemCount ) { throw new IndexOutOfBoundsException ( "The given position " + position + " is not within the position bounds for content items [0 - " + ( newContentItemCount - 1... |
public class GCSHelper { /** * Retrieve part of the file .
* @ throws IOException */
public ByteArrayOutputStream getPartialObjectData ( String bucket , String fname , long start , long endIncl ) throws IOException { } } | return getPartialObjectData ( bucket , fname , start , endIncl , null ) ; |
public class Materialize { /** * set the insetsFrameLayout to display the content in fullscreen
* under the statusBar and navigationBar
* @ param fullscreen */
public void setFullscreen ( boolean fullscreen ) { } } | if ( mBuilder . mScrimInsetsLayout != null ) { mBuilder . mScrimInsetsLayout . setTintStatusBar ( ! fullscreen ) ; mBuilder . mScrimInsetsLayout . setTintNavigationBar ( ! fullscreen ) ; } |
public class WebApplicationHandler { protected void dispatch ( String pathInContext , HttpServletRequest request , HttpServletResponse response , ServletHolder servletHolder , int type ) throws ServletException , UnavailableException , IOException { } } | if ( type == Dispatcher . __REQUEST ) { // This is NOT a dispatched request ( it it is an initial request )
ServletHttpRequest servletHttpRequest = ( ServletHttpRequest ) request ; ServletHttpResponse servletHttpResponse = ( ServletHttpResponse ) response ; // protect web - inf and meta - inf
if ( StringUtil . startsWi... |
public class JobSchedulesImpl { /** * Updates the properties of the specified job schedule .
* This replaces only the job schedule properties specified in the request . For example , if the schedule property is not specified with this request , then the Batch service will keep the existing schedule . Changes to a job... | patchWithServiceResponseAsync ( jobScheduleId , jobSchedulePatchParameter ) . toBlocking ( ) . single ( ) . body ( ) ; |
public class AbstractHttpTransport { /** * This method checks the request for the has conditions which may either be contained in URL
* query arguments or in a cookie sent from the client .
* @ param request
* the request object
* @ return The has conditions from the request .
* @ throws IOException
* @ thr... | final String sourceMethod = "getHasConditionsFromRequest" ; // $ NON - NLS - 1 $
boolean isTraceLogging = log . isLoggable ( Level . FINER ) ; if ( isTraceLogging ) { log . entering ( sourceClass , sourceMethod , new Object [ ] { request } ) ; } String ret = null ; if ( request . getParameter ( FEATUREMAPHASH_REQPARAM ... |
public class ArrayTagSet { /** * Add a new tag to the set . */
ArrayTagSet add ( String k , String v ) { } } | return add ( new BasicTag ( k , v ) ) ; |
public class MockEC2QueryHandler { /** * Handles " describeSecurityGroups " request and returns response with a security group .
* @ return a DescribeInternetGatewaysResponseType with our predefined internet gateway in aws - mock . properties ( or if
* not overridden , as defined in aws - mock - default . propertie... | DescribeSecurityGroupsResponseType ret = new DescribeSecurityGroupsResponseType ( ) ; ret . setRequestId ( UUID . randomUUID ( ) . toString ( ) ) ; SecurityGroupSetType securityGroupSet = new SecurityGroupSetType ( ) ; for ( Iterator < MockSecurityGroup > mockSecurityGroup = mockSecurityGroupController . describeSecuri... |
public class AbstractAttribute { /** * ( non - Javadoc )
* @ see javax . persistence . metamodel . Attribute # isAssociation ( ) */
public boolean isAssociation ( ) { } } | return persistenceAttribType . equals ( PersistentAttributeType . MANY_TO_MANY ) || persistenceAttribType . equals ( PersistentAttributeType . MANY_TO_ONE ) || persistenceAttribType . equals ( PersistentAttributeType . ONE_TO_MANY ) || persistenceAttribType . equals ( PersistentAttributeType . ONE_TO_ONE ) ; |
public class DirectQuickSelectSketchR { /** * Sketch */
@ Override public int getCurrentBytes ( final boolean compact ) { } } | if ( ! compact ) { final byte lgArrLongs = mem_ . getByte ( LG_ARR_LONGS_BYTE ) ; final int preambleLongs = mem_ . getByte ( PREAMBLE_LONGS_BYTE ) & 0X3F ; final int lengthBytes = ( preambleLongs + ( 1 << lgArrLongs ) ) << 3 ; return lengthBytes ; } final int preLongs = getCurrentPreambleLongs ( true ) ; final int curC... |
public class SpoiledChildInterfaceImplementor { /** * builds a set of all non constructor or static initializer method / signatures
* @ param cls
* the class to build the method set from
* @ return a set of method names / signatures */
private static Set < QMethod > buildMethodSet ( JavaClass cls ) { } } | Set < QMethod > methods = new HashSet < > ( ) ; boolean isInterface = cls . isInterface ( ) ; for ( Method m : cls . getMethods ( ) ) { boolean isDefaultInterfaceMethod = isInterface && ! m . isAbstract ( ) ; boolean isSyntheticForParentCall ; if ( m . isSynthetic ( ) ) { BitSet bytecodeSet = ClassContext . getBytecode... |
public class AnimatorSet { /** * This method creates a < code > Builder < / code > object , which is used to
* set up playing constraints . This initial < code > play ( ) < / code > method
* tells the < code > Builder < / code > the animation that is the dependency for
* the succeeding commands to the < code > Bu... | if ( anim != null ) { mNeedsSort = true ; return new Builder ( anim ) ; } return null ; |
public class WaitFor { /** * Waits up to the provided wait time for a cookies with the provided name has a value equal to the
* expected value . This information will be logged and recorded , with a
* screenshot for traceability and added debugging support .
* @ param cookieName the name of the cookie
* @ param... | double end = System . currentTimeMillis ( ) + ( seconds * 1000 ) ; while ( app . is ( ) . cookiePresent ( cookieName ) && System . currentTimeMillis ( ) < end ) ; if ( app . is ( ) . cookiePresent ( cookieName ) ) { while ( ! app . get ( ) . cookieValue ( cookieName ) . equals ( expectedCookieValue ) && System . curren... |
public class ExtractMsgsVisitor { /** * Implementations for specific nodes . */
@ Override protected void visitMsgNode ( MsgNode node ) { } } | MsgPartsAndIds msgPartsAndIds = MsgUtils . buildMsgPartsAndComputeMsgIdForDualFormat ( node ) ; SoyMsg . Builder builder = SoyMsg . builder ( ) . setId ( msgPartsAndIds . id ) ; if ( node . getMeaning ( ) != null ) { builder . setMeaning ( node . getMeaning ( ) ) ; } SoyMsg msg = builder . setDesc ( node . getDesc ( ) ... |
public class FoundationLoggingThrowableInformationPatternConverter { /** * Method generates abbreviated exception message .
* @ param message
* Original log message
* @ param throwable
* The attached throwable
* @ return Abbreviated exception message */
private String generateAbbreviatedExceptionMessage ( fin... | final StringBuilder builder = new StringBuilder ( ) ; builder . append ( ": " ) ; builder . append ( throwable . getClass ( ) . getCanonicalName ( ) ) ; builder . append ( ": " ) ; builder . append ( throwable . getMessage ( ) ) ; Throwable cause = throwable . getCause ( ) ; while ( cause != null ) { builder . append (... |
public class EC2Context { /** * < br >
* Needed AWS actions :
* < ul >
* < li > autoscaling : DescribeAutoScalingGroups < / li >
* < / ul >
* @ param autoScalingGroupName the name to search for
* @ return the given auto scaling group */
public AutoScalingGroup getAutoScalingGroup ( String autoScalingGroupNa... | Preconditions . checkArgument ( autoScalingGroupName != null && ! autoScalingGroupName . isEmpty ( ) ) ; DescribeAutoScalingGroupsRequest req = new DescribeAutoScalingGroupsRequest ( ) ; req . setAutoScalingGroupNames ( Collections . singleton ( autoScalingGroupName ) ) ; DescribeAutoScalingGroupsResult result = this .... |
public class MMCIFFileTools { /** * Converts a SpaceGroup object to a { @ link Symmetry } object .
* @ param sg
* @ return */
public static Symmetry convertSpaceGroupToSymmetry ( SpaceGroup sg ) { } } | Symmetry sym = new Symmetry ( ) ; sym . setSpace_group_name_H_M ( sg . getShortSymbol ( ) ) ; // TODO do we need to fill any of the other values ?
return sym ; |
public class SSLConfigManager { /** * This method adds an SSL config to the SSLConfigManager map and list .
* @ param alias
* @ param sslConfig
* @ throws Exception */
public synchronized void removeSSLConfigFromMap ( String alias , SSLConfig sslConfig ) throws Exception { } } | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "removeSSLConfigFromMap" , new Object [ ] { alias } ) ; sslConfigMap . remove ( alias ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) Tr . exit ( tc , "removeSSLConfigFromMap" ) ; |
public class FilterFactories { /** * Creates a { @ link Filter } .
* @ param filterFactoryFqcn The fully qualified class name of the { @ link FilterFactory }
* @ param params The arguments to the { @ link FilterFactory } */
public static Filter createFilter ( String filterFactoryFqcn , FilterFactoryParams params ) ... | FilterFactory filterFactory = createFilterFactory ( filterFactoryFqcn ) ; return filterFactory . createFilter ( params ) ; |
public class OAuthUtils { /** * Returns a signature base string . The signature base string
* is a consistent , reproducible concatenation of several of
* the HTTP request elements into a single string .
* The signature base string includes the following components of the HTTP request :
* < ul >
* < li > the ... | StringBuilder sb = new StringBuilder ( ) ; sb . append ( requestMethod . toUpperCase ( ) ) . append ( "&" ) . append ( AuthUtils . percentEncode ( normalizeUrl ( requestUrl ) ) ) . append ( "&" ) . append ( AuthUtils . percentEncode ( normalizeParameters ( requestUrl , protocolParameters ) ) ) ; return sb . toString ( ... |
public class ProgressiveJpegParser { /** * If this is the first time calling this method , the buffer will be checked to make sure it
* starts with SOI marker ( 0xffd8 ) . If the image has been identified as a non - JPEG , data will be
* ignored and false will be returned immediately on all subsequent calls .
* T... | if ( mParserState == NOT_A_JPEG ) { return false ; } final int dataBufferSize = encodedImage . getSize ( ) ; // Is there any new data to parse ?
// mBytesParsed might be greater than size of dataBuffer - that happens when
// we skip more data than is available to read inside doParseMoreData method
if ( dataBufferSize <... |
public class UaaStringUtils { /** * Hide the passwords and secrets in a config map ( e . g . for logging ) .
* @ param map a map with String keys ( e . g . Properties ) and String or nested
* map values
* @ return new properties with no plaintext passwords and secrets */
public static Map < String , ? > hidePassw... | Map < String , Object > result = new LinkedHashMap < String , Object > ( ) ; result . putAll ( map ) ; for ( String key : map . keySet ( ) ) { Object value = map . get ( key ) ; if ( value instanceof String ) { if ( isPassword ( key ) ) { result . put ( key , "#" ) ; } } else if ( value instanceof Map ) { @ SuppressWar... |
public class SdkDigestInputStream { /** * Skips over and discards < code > n < / code > bytes of data from this input
* stream , while taking the skipped bytes into account for digest
* calculation . The < code > skip < / code > method may , for a variety of reasons ,
* end up skipping over some smaller number of... | if ( n <= 0 ) return n ; byte [ ] b = new byte [ ( int ) Math . min ( SKIP_BUF_SIZE , n ) ] ; long m = n ; // remaining number of bytes to read
while ( m > 0 ) { int len = read ( b , 0 , ( int ) Math . min ( m , b . length ) ) ; if ( len == - 1 ) return n - m ; m -= len ; } assert ( m == 0 ) ; return n ; |
public class AceDataset { /** * Add a Weather Station to the dataset .
* Add a new Weather Station from a { @ code byte [ ] } consisting of the JSON
* for that weather station data .
* @ param source JSON weather station data
* @ throws IOException if there is an I / O error */
public void addWeather ( byte [ ]... | AceWeather weather = new AceWeather ( source ) ; String wstId = weather . getValue ( "wst_id" ) ; String climId = weather . getValue ( "clim_id" ) ; String wid = weather . getId ( ) ; if ( this . weatherMap . containsKey ( wid ) ) { LOG . error ( "Duplicate data found for wst_id: {}" , wstId ) ; } else { this . weather... |
public class InstrumentsNoDelayLoader { /** * the files are stored in folder + versiob + build For instance instruments version 4.6 build
* 46000 will be in / instruments _ no _ delay / 4.6/46000/ */
private String pathForVersion ( InstrumentsVersion version ) { } } | String path = version . getVersion ( ) + File . separatorChar + version . getBuild ( ) ; return path ; |
public class XStreamFactory { /** * Create XStream for chart template load / save .
* @ return XStream */
public static XStream createChartTemplateXStream ( ) { } } | XStream xstream = new XStream ( new DomDriver ( "UTF-8" ) ) ; xstream . setMode ( XStream . NO_REFERENCES ) ; xstream . registerConverter ( new FontConverter ( ) ) ; xstream . alias ( "chart-template" , ChartTemplate . class ) ; xstream . useAttributeFor ( ChartTemplate . class , "version" ) ; xstream . alias ( "color"... |
public class ServiceSettingMarshaller { /** * Marshall the given parameter object . */
public void marshall ( ServiceSetting serviceSetting , ProtocolMarshaller protocolMarshaller ) { } } | if ( serviceSetting == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( serviceSetting . getSettingId ( ) , SETTINGID_BINDING ) ; protocolMarshaller . marshall ( serviceSetting . getSettingValue ( ) , SETTINGVALUE_BINDING ) ; protocolMarshall... |
public class Ifc2x3tc1PackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public EEnum getIfcCableCarrierSegmentTypeEnum ( ) { } } | if ( ifcCableCarrierSegmentTypeEnumEEnum == null ) { ifcCableCarrierSegmentTypeEnumEEnum = ( EEnum ) EPackage . Registry . INSTANCE . getEPackage ( Ifc2x3tc1Package . eNS_URI ) . getEClassifiers ( ) . get ( 790 ) ; } return ifcCableCarrierSegmentTypeEnumEEnum ; |
public class RelativeDateFormat { /** * Set capitalizationOfRelativeUnitsForListOrMenu , capitalizationOfRelativeUnitsForStandAlone */
private void initCapitalizationContextInfo ( ULocale locale ) { } } | ICUResourceBundle rb = ( ICUResourceBundle ) UResourceBundle . getBundleInstance ( ICUData . ICU_BASE_NAME , locale ) ; try { ICUResourceBundle rdb = rb . getWithFallback ( "contextTransforms/relative" ) ; int [ ] intVector = rdb . getIntVector ( ) ; if ( intVector . length >= 2 ) { capitalizationOfRelativeUnitsForList... |
public class LenientAuthorizationCodeTokenRequest { /** * Executes request for an access token , and returns the HTTP response .
* To execute and parse the response to { @ link TokenResponse } , instead use
* { @ link # execute ( ) } .
* Callers should call { @ link HttpResponse # disconnect } when the returned
... | // must set clientAuthentication as last execute interceptor in case it
// needs to sign request
HttpRequestFactory requestFactory = getTransport ( ) . createRequestFactory ( new HttpRequestInitializer ( ) { public void initialize ( HttpRequest request ) throws IOException { if ( getRequestInitializer ( ) != null ) { g... |
public class DataLabelingServiceClient { /** * Creates an instruction for how data should be labeled .
* < p > Sample code :
* < pre > < code >
* try ( DataLabelingServiceClient dataLabelingServiceClient = DataLabelingServiceClient . create ( ) ) {
* String formattedParent = DataLabelingServiceClient . formatPr... | return createInstructionOperationCallable ( ) . futureCall ( request ) ; |
public class MongoDBQueryModelDAO { @ Override public void save ( T object , AccessControlContext accessControlContext ) throws OptimisticLockException , AccessControlException , JeppettoException { } } | ensureAccessControlEnabled ( ) ; T enhancedEntity = dirtyableDBObjectEnhancer . enhance ( object ) ; DirtyableDBObject dbo = ( DirtyableDBObject ) enhancedEntity ; if ( dbo . isPersisted ( dbCollection ) ) { verifyWriteAllowed ( dbo , accessControlContext ) ; } else { if ( dbo . get ( ID_FIELD ) == null ) { dbo . put (... |
public class FastPathResolver { /** * Strip away any " jar : " prefix from a filename URI , and convert it to a file path , handling possibly - broken
* mixes of filesystem and URI conventions ; resolve relative paths relative to resolveBasePath .
* @ param resolveBasePath
* The base path .
* @ param relativePa... | // See : http : / / stackoverflow . com / a / 17870390/3950982
// https : / / weblogs . java . net / blog / kohsuke / archive / 2007/04 / how _ to _ convert . html
if ( relativePath == null || relativePath . isEmpty ( ) ) { return resolveBasePath == null ? "" : resolveBasePath ; } String prefix = "" ; boolean isAbsolut... |
public class HttpClientFactory { /** * Configures the HttpClient with an SSL TrustManager that will accept any
* SSL server certificate . The server SSL certificate will not be verified .
* This method creates a new Scheme for " https " that is setup for an SSL
* context to uses an DoNotVerifySSLCertificateTrustM... | // create a new https scheme with no SSL verification
Scheme httpsScheme = SchemeFactory . createDoNotVerifyHttpsScheme ( ) ; // register this new scheme on the https client
client . getConnectionManager ( ) . getSchemeRegistry ( ) . register ( httpsScheme ) ; |
public class PForDelta { /** * The core implementation of compressing a block with blockSize
* integers using PForDelta with the given parameter b
* @ param inputBlock
* the block to be compressed
* @ param bits
* the the value of the parameter b
* @ param blockSize
* the block size
* @ return the compr... | int [ ] expAux = new int [ blockSize * 2 ] ; int maxCompBitSize = HEADER_SIZE + blockSize * ( MAX_BITS + MAX_BITS + MAX_BITS ) + 32 ; int [ ] tmpCompressedBlock = new int [ ( maxCompBitSize >>> 5 ) ] ; int outputOffset = HEADER_SIZE ; int expUpperBound = 1 << bits ; int expNum = 0 ; for ( int elem : inputBlock ) { if (... |
public class PluginCommandLine { /** * Returns < code > true < / code > if the option is present .
* @ param optionName
* The option name
* @ return < code > true < / code > if the option is present * @ see it . jnrpe . ICommandLine # hasOption ( String ) */
public boolean hasOption ( final String optionName ) { ... | if ( optionName . length ( ) == 1 ) { return hasOption ( optionName . charAt ( 0 ) ) ; } return commandLine . hasOption ( "--" + optionName ) ; |
public class CommerceUserSegmentEntryUtil { /** * Returns the last commerce user segment entry 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 commerce u... | return getPersistence ( ) . fetchByGroupId_Last ( groupId , orderByComparator ) ; |
public class ExcelReader { /** * 读取Excel为Bean的列表
* @ param < T > Bean类型
* @ param headerRowIndex 标题所在行 , 如果标题行在读取的内容行中间 , 这行做为数据将忽略 , , 从0开始计数
* @ param startRowIndex 起始行 ( 包含 , 从0开始计数 )
* @ param beanType 每行对应Bean的类型
* @ return Map的列表
* @ since 4.0.1 */
public < T > List < T > read ( int headerRowIndex , i... | return read ( headerRowIndex , startRowIndex , Integer . MAX_VALUE , beanType ) ; |
public class ObjectDigestUtil { /** * 将Object按照key1 = value1 & key2 = value2的形式拼接起来 , 程序不递归 。 Value需为基本类型 ,
* 或者其toString方法能表示其实际的值
* @ param o
* @ return */
private static String getOrderedMapString ( Map < Object , Object > map ) { } } | ArrayList < String > list = new ArrayList < String > ( ) ; for ( Map . Entry < Object , Object > entry : map . entrySet ( ) ) { if ( entry . getValue ( ) != null ) { Object key = entry . getKey ( ) ; Object value = entry . getValue ( ) ; String objectString = getObjectString ( value ) ; if ( ! StringUtils . isEmpty ( o... |
public class Ginv { /** * Add a factor times one column to another column
* @ param matrix
* the matrix to modify
* @ param diag
* coordinate on the diagonal
* @ param fromRow
* first row to process
* @ param col
* column to process
* @ param factor
* factor to multiply */
public static void addColT... | long rows = matrix . getRowCount ( ) ; for ( long row = fromRow ; row < rows ; row ++ ) { matrix . setAsDouble ( matrix . getAsDouble ( row , col ) - factor * matrix . getAsDouble ( row , diag ) , row , col ) ; } |
public class ExportConfigurationsRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( ExportConfigurationsRequest exportConfigurationsRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( exportConfigurationsRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { } catch ( Exception e ) { throw new SdkClientException ( "Unable to marshall request to JSON: " + e . getMessage ( ) , e ) ; } |
public class OutboundResourceadapterTypeImpl { /** * If not already created , a new < code > authentication - mechanism < / code > element will be created and returned .
* Otherwise , the first existing < code > authentication - mechanism < / code > element will be returned .
* @ return the instance defined for the... | List < Node > nodeList = childNode . get ( "authentication-mechanism" ) ; if ( nodeList != null && nodeList . size ( ) > 0 ) { return new AuthenticationMechanismTypeImpl < OutboundResourceadapterType < T > > ( this , "authentication-mechanism" , childNode , nodeList . get ( 0 ) ) ; } return createAuthenticationMechanis... |
public class PseudoNthSpecifierChecker { /** * Add the { @ code : nth - child } elements .
* @ see < a href = " http : / / www . w3 . org / TR / css3 - selectors / # nth - child - pseudo " > < code > : nth - child < / code > pseudo - class < / a > */
private void addNthChild ( ) { } } | for ( Node node : nodes ) { int count = 1 ; Node n = DOMHelper . getPreviousSiblingElement ( node ) ; while ( n != null ) { count ++ ; n = DOMHelper . getPreviousSiblingElement ( n ) ; } if ( specifier . isMatch ( count ) ) { result . add ( node ) ; } } |
public class ProcessorManager { /** * This method processes the supplied information against the configured processor
* details for the trace .
* @ param trace The trace
* @ param node The node being processed
* @ param direction The direction
* @ param headers The headers
* @ param values The values */
pub... | if ( log . isLoggable ( Level . FINEST ) ) { log . finest ( "ProcessManager: process trace=" + trace + " node=" + node + " direction=" + direction + " headers=" + headers + " values=" + values + " : available processors=" + processors ) ; } if ( trace . getTransaction ( ) != null ) { List < ProcessorWrapper > procs = n... |
public class DatabaseOperationsInner { /** * Gets a list of operations performed on the database .
* @ param nextPageLink The NextLink from the previous successful call to List operation .
* @ throws IllegalArgumentException thrown if parameters fail the validation
* @ return the observable to the PagedList & lt ... | return listByDatabaseNextWithServiceResponseAsync ( nextPageLink ) . map ( new Func1 < ServiceResponse < Page < DatabaseOperationInner > > , Page < DatabaseOperationInner > > ( ) { @ Override public Page < DatabaseOperationInner > call ( ServiceResponse < Page < DatabaseOperationInner > > response ) { return response .... |
public class ConfigurationImpl { /** * { @ inheritDoc } */
@ Override public Locale getLocale ( ) { } } | if ( root instanceof RootDocImpl ) return ( ( RootDocImpl ) root ) . getLocale ( ) ; else return Locale . getDefault ( ) ; |
public class RateLimiterUtil { /** * 一个用来定制RateLimiter的方法 。
* @ param permitsPerSecond 每秒允许的请求书 , 可看成QPS
* @ param maxBurstSeconds 最大的突发缓冲时间 。 用来应对突发流量 。 Guava的实现默认是1s 。 permitsPerSecond * maxBurstSeconds的数量 , 就是闲置时预留的缓冲token数量
* @ param filledWithToken 是否需要创建时就保留有permitsPerSecond * maxBurstSeconds的token */
publi... | Class < ? > sleepingStopwatchClass = Class . forName ( "com.google.common.util.concurrent.RateLimiter$SleepingStopwatch" ) ; Method createStopwatchMethod = sleepingStopwatchClass . getDeclaredMethod ( "createFromSystemTimer" ) ; createStopwatchMethod . setAccessible ( true ) ; Object stopwatch = createStopwatchMethod .... |
public class RemoteRecordOwner { /** * Free this remote record owner .
* Also explicitly unexports the RMI object . */
public void free ( ) { } } | if ( m_recordOwnerCollection != null ) m_recordOwnerCollection . free ( ) ; m_recordOwnerCollection = null ; if ( m_messageFilterList != null ) m_messageFilterList . free ( ) ; m_messageFilterList = null ; // Close all records associated with this SessionObject
if ( m_vRecordList != null ) m_vRecordList . free ( this )... |
public class WordVectorSerializer { /** * This method loads previously saved SequenceVectors model from File
* @ param factory
* @ param file
* @ param < T >
* @ return */
public static < T extends SequenceElement > SequenceVectors < T > readSequenceVectors ( @ NonNull SequenceElementFactory < T > factory , @ N... | return readSequenceVectors ( factory , new FileInputStream ( file ) ) ; |
public class CategoryMarshaller { /** * Marshall the given parameter object . */
public void marshall ( Category category , ProtocolMarshaller protocolMarshaller ) { } } | if ( category == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( category . getCode ( ) , CODE_BINDING ) ; protocolMarshaller . marshall ( category . getName ( ) , NAME_BINDING ) ; } catch ( Exception e ) { throw new SdkClientException ( "Un... |
public class LaJobRunner { protected void arrangePreparedAccessContext ( LaJobRuntime runtime ) { } } | if ( accessContextArranger == null ) { return ; } final AccessContextResource resource = createAccessContextResource ( runtime ) ; final AccessContext context = accessContextArranger . arrangePreparedAccessContext ( resource ) ; if ( context == null ) { String msg = "Cannot return null from access context arranger: " +... |
public class BundleUtils { /** * Discovers the bundle context for a bundle . If the bundle is an 4.1.0 or greater bundle it should have a method
* that just returns the bundle context . Otherwise uses reflection to look for an internal bundle context .
* @ param bundle the bundle from which the bundle context is ne... | try { // first try to find the getBundleContext method ( OSGi spec > = 4.10)
final Method method = Bundle . class . getDeclaredMethod ( "getBundleContext" ) ; if ( ! method . isAccessible ( ) ) { method . setAccessible ( true ) ; } return ( BundleContext ) method . invoke ( bundle ) ; } catch ( Exception e ) { // then ... |
public class WSJdbcResultSet { /** * Updates a column with a binary stream value . The updateXXX methods are used to update column values
* in the current row , or the insert row . The updateXXX methods do not update the underlying database ; instead the
* updateRow or insertRow methods are called to update the dat... | try { rsetImpl . updateBinaryStream ( arg0 , arg1 , arg2 ) ; } catch ( SQLException ex ) { FFDCFilter . processException ( ex , "com.ibm.ws.rsadapter.jdbc.WSJdbcResultSet.updateBinaryStream" , "3075" , this ) ; throw WSJdbcUtil . mapException ( this , ex ) ; } catch ( NullPointerException nullX ) { // No FFDC code need... |
public class Distance { /** * Gets the Kullback Leibler divergence .
* @ param p P vector .
* @ param q Q vector .
* @ return The Kullback Leibler divergence between u and v . */
public static double KullbackLeiblerDivergence ( double [ ] p , double [ ] q ) { } } | boolean intersection = false ; double k = 0 ; for ( int i = 0 ; i < p . length ; i ++ ) { if ( p [ i ] != 0 && q [ i ] != 0 ) { intersection = true ; k += p [ i ] * Math . log ( p [ i ] / q [ i ] ) ; } } if ( intersection ) return k ; else return Double . POSITIVE_INFINITY ; |
public class OpenTSDBMain { /** * Returns the agent properties
* @ return the agent properties or null if reflective call failed */
protected static Properties getAgentProperties ( ) { } } | try { Class < ? > clazz = Class . forName ( "sun.misc.VMSupport" ) ; Method m = clazz . getDeclaredMethod ( "getAgentProperties" ) ; m . setAccessible ( true ) ; Properties p = ( Properties ) m . invoke ( null ) ; return p ; } catch ( Throwable t ) { return null ; } |
public class ApiOvhMe { /** * Alter this object properties
* REST : PUT / me / paymentMean / creditCard / { id }
* @ param body [ required ] New object properties
* @ param id [ required ] Id of the object */
public void paymentMean_creditCard_id_PUT ( Long id , OvhCreditCard body ) throws IOException { } } | String qPath = "/me/paymentMean/creditCard/{id}" ; StringBuilder sb = path ( qPath , id ) ; exec ( qPath , "PUT" , sb . toString ( ) , body ) ; |
public class GrailsASTUtils { /** * Set the method target of a MethodCallExpression to the first matching method with same number and type of arguments .
* @ param methodCallExpression
* @ param targetClassNode
* @ param targetParameterClassTypes
* @ return The method call expression */
public static MethodCall... | return applyMethodTarget ( methodCallExpression , targetClassNode , convertTargetParameterTypes ( targetParameterClassTypes ) ) ; |
public class CloudStorageRetryHandler { /** * Records a retry attempt for the given StorageException , sleeping for an amount of time
* dependent on the attempt number . Throws a StorageException if we ' ve exhausted all retries .
* @ param exs The StorageException error that prompted this retry attempt . */
privat... | retries ++ ; if ( retries > maxRetries ) { throw new StorageException ( exs . getCode ( ) , "All " + maxRetries + " retries failed. Waited a total of " + totalWaitTime + " ms between attempts" , exs ) ; } sleepForAttempt ( retries ) ; |
public class CmsDocumentDependency { /** * Read the information out of the given JSON object to fill
* the values of the document . < p >
* @ param json the JSON object with the information about this document
* @ param rootPath the current path the home division */
public void fromJSON ( JSONObject json , String... | try { // language versions
if ( json . has ( JSON_LANGUAGES ) ) { JSONArray jsonLanguages = json . getJSONArray ( JSON_LANGUAGES ) ; for ( int i = 0 ; i < jsonLanguages . length ( ) ; i ++ ) { JSONObject jsonLang = ( JSONObject ) jsonLanguages . get ( i ) ; CmsDocumentDependency lang = new CmsDocumentDependency ( null ... |
public class ASTPrinter { /** * prints an arg as
* type name
* @ param arg Arg to be printed
* @ return pretty string */
public static String print ( Arg arg ) { } } | return printArgModifiers ( arg . modifiers ) + print ( arg . type ) + " " + arg . name ; |
public class JavaInlineExpressionCompiler { /** * Append the inline code for the given XReturnLiteral .
* @ param expression the expression of the operation .
* @ param parentExpression is the expression that contains this one , or { @ code null } if the current expression is
* the root expression .
* @ param f... | return generate ( expression . getExpression ( ) , parentExpression , feature , output ) ; |
public class JsonModelGenerator { /** * Initialization .
* @ param env
* @ author vvakame */
public static void init ( ProcessingEnvironment env ) { } } | processingEnv = env ; typeUtils = processingEnv . getTypeUtils ( ) ; elementUtils = processingEnv . getElementUtils ( ) ; |
public class CeylonUtil { /** * Returns the directory part of path string .
* @ param path Input path
* @ return String The directory part of the path */
public static String dirpart ( final String path ) { } } | int s = path . lastIndexOf ( File . separatorChar ) ; if ( s != - 1 ) { return path . substring ( 0 , s ) ; } else { return null ; } |
public class MemoryEntityLockStore { /** * Returns an IEntityLock [ ] based on the params , any or all of which may be null . A null param
* means any value , so < code > find ( myType , myKey , null , null , null ) < / code > will return all < code >
* IEntityLocks < / code > for myType and myKey .
* @ return or... | List locks = new ArrayList ( ) ; Map cache = null ; Collection caches = null ; Iterator cacheIterator = null ; Iterator cacheKeyIterator = null ; Iterator keyIterator = null ; IEntityLock lock = null ; if ( entityType == null ) { caches = getLockCache ( ) . values ( ) ; } else { caches = new ArrayList ( 1 ) ; caches . ... |
public class JournalRecoveryLog { /** * Helper for the { @ link # log ( ConsumerJournalEntry ) } method . Writes the
* values of a context multi - map . */
private < T > String writeMapValues ( String mapName , MultiValueMap < T > map ) { } } | StringBuffer buffer = new StringBuffer ( ) ; buffer . append ( " " + mapName + "\n" ) ; for ( Iterator < T > names = map . names ( ) ; names . hasNext ( ) ; ) { T name = names . next ( ) ; buffer . append ( " " ) . append ( name . toString ( ) ) . append ( "\n" ) ; String [ ] values = map . getStringA... |
public class AzureFirewallsInner { /** * Creates or updates the specified Azure Firewall .
* @ param resourceGroupName The name of the resource group .
* @ param azureFirewallName The name of the Azure Firewall .
* @ param parameters Parameters supplied to the create or update Azure Firewall operation .
* @ thr... | return createOrUpdateWithServiceResponseAsync ( resourceGroupName , azureFirewallName , parameters ) . map ( new Func1 < ServiceResponse < AzureFirewallInner > , AzureFirewallInner > ( ) { @ Override public AzureFirewallInner call ( ServiceResponse < AzureFirewallInner > response ) { return response . body ( ) ; } } ) ... |
public class ApiOvhCdndedicated { /** * Add a backend IP
* REST : POST / cdn / dedicated / { serviceName } / domains / { domain } / backends
* @ param ip [ required ] IP to add to backends list
* @ param serviceName [ required ] The internal name of your CDN offer
* @ param domain [ required ] Domain of this ob... | String qPath = "/cdn/dedicated/{serviceName}/domains/{domain}/backends" ; StringBuilder sb = path ( qPath , serviceName , domain ) ; HashMap < String , Object > o = new HashMap < String , Object > ( ) ; addBody ( o , "ip" , ip ) ; String resp = exec ( qPath , "POST" , sb . toString ( ) , o ) ; return convertTo ( resp ,... |
public class Client { /** * Gets a list of Event resources . ( 50 elements )
* @ return List of Event
* @ throws OAuthSystemException - if there is a IOException reading parameters of the httpURLConnection
* @ throws OAuthProblemException - if there are errors validating the OneloginOAuthJSONResourceResponse and ... | HashMap < String , String > queryParameters = new HashMap < String , String > ( ) ; return getEvents ( queryParameters ) ; |
public class JDBCUserRealm { private void loadUser ( String username ) { } } | try { if ( null == _con ) connectDatabase ( ) ; if ( null == _con ) throw new SQLException ( "Can't connect to database" ) ; PreparedStatement stat = _con . prepareStatement ( _userSql ) ; stat . setObject ( 1 , username ) ; ResultSet rs = stat . executeQuery ( ) ; if ( rs . next ( ) ) { Object key = rs . getObject ( _... |
public class Objects { /** * Returns long value of argument , if possible , wrapped in Optional
* Interprets String as Number */
public static Optional < Long > toLong ( Object arg ) { } } | if ( arg instanceof Number ) { return Optional . of ( ( ( Number ) arg ) . longValue ( ) ) ; } else if ( arg instanceof String ) { Optional < ? extends Number > optional = toNumber ( arg ) ; if ( optional . isPresent ( ) ) { return Optional . of ( optional . get ( ) . longValue ( ) ) ; } else { return Optional . empty ... |
public class StubInvocationBenchmark { /** * Performs a benchmark for a trivial class creation using javassist .
* @ param blackHole A black hole for avoiding JIT erasure . */
@ Benchmark @ OperationsPerInvocation ( 20 ) public void benchmarkJavassist ( Blackhole blackHole ) { } } | blackHole . consume ( javassistInstance . method ( booleanValue ) ) ; blackHole . consume ( javassistInstance . method ( byteValue ) ) ; blackHole . consume ( javassistInstance . method ( shortValue ) ) ; blackHole . consume ( javassistInstance . method ( intValue ) ) ; blackHole . consume ( javassistInstance . method ... |
public class CmsContainerpageService { /** * Generates the model resource data list . < p >
* @ param cms the cms context
* @ param resourceType the resource type name
* @ param modelResources the model resource
* @ param contentLocale the content locale
* @ return the model resources data
* @ throws CmsExc... | List < CmsModelResourceInfo > result = new ArrayList < CmsModelResourceInfo > ( ) ; Locale wpLocale = OpenCms . getWorkplaceManager ( ) . getWorkplaceLocale ( cms ) ; CmsModelResourceInfo defaultInfo = new CmsModelResourceInfo ( Messages . get ( ) . getBundle ( wpLocale ) . key ( Messages . GUI_TITLE_DEFAULT_RESOURCE_C... |
public class ConfigurationMBean { /** * uniqueObjectName
* Make a unique jmx name for this configuration object
* @ see org . browsermob . proxy . jetty . util . jmx . ModelMBeanImpl # uniqueObjectName ( javax . management . MBeanServer , java . lang . String ) */
public synchronized ObjectName uniqueObjectName ( M... | ObjectName oName = null ; try { oName = new ObjectName ( on + ",config=" + _config . getClass ( ) . getName ( ) ) ; } catch ( Exception e ) { log . warn ( LogSupport . EXCEPTION , e ) ; } return oName ; |
public class RequestParameterBuilder { /** * Adds a request parameter to the URL without specifying a data type of the given parameter value . Parameter ' s value is converted to JSON notation when
* adding . Furthermore , it will be encoded according to the acquired encoding .
* @ param name name of the request pa... | return paramJson ( name , value , null ) ; |
public class AdminOperation { /** * create partitions in the broker
* @ param topic topic name
* @ param partitionNum partition numbers
* @ param enlarge enlarge partition number if broker configuration has
* setted
* @ return partition number in the broker
* @ throws IOException if an I / O error occurs */... | KV < Receive , ErrorMapping > response = send ( new CreaterRequest ( topic , partitionNum , enlarge ) ) ; return Utils . deserializeIntArray ( response . k . buffer ( ) ) [ 0 ] ; |
public class XExtensionManager { /** * Retrieves an extension instance by its unique URI . If the extension
* has not been registered before , it is looked up in the local cache .
* If it cannot be found in the cache , the manager attempts to download
* it from its unique URI , and add it to the set of managed ex... | XExtension extension = extensionMap . get ( uri ) ; if ( extension == null ) { try { extension = XExtensionParser . instance ( ) . parse ( uri ) ; register ( extension ) ; XLogging . log ( "Imported XES extension '" + extension . getUri ( ) + "' from remote source" , XLogging . Importance . DEBUG ) ; } catch ( IOExcept... |
public class DynamicPipelineServiceImpl { /** * this is here for future expansion */
private Map < Environment , Collection < ArtifactIdentifier > > getArtifactIdentifiers ( List < Environment > environments ) { } } | Map < Environment , Collection < ArtifactIdentifier > > rt = new HashMap < > ( ) ; for ( Environment env : environments ) { Set < ArtifactIdentifier > ids = new HashSet < > ( ) ; if ( env . getUnits ( ) != null ) { for ( DeployableUnit du : env . getUnits ( ) ) { String artifactName = du . getName ( ) ; String artifact... |
public class AuthenticationService { /** * Returns a formatted string containing an IP address , or list of IP
* addresses , which represent the HTTP client and any involved proxies . As
* the headers used to determine proxies can easily be forged , this data is
* superficially validated to ensure that it at leas... | // Log X - Forwarded - For , if present and valid
String header = request . getHeader ( "X-Forwarded-For" ) ; if ( header != null && X_FORWARDED_FOR . matcher ( header ) . matches ( ) ) return "[" + header + ", " + request . getRemoteAddr ( ) + "]" ; // If header absent or invalid , just use source IP
return request . ... |
public class FeatureInfo { /** * Tells if any of the methods associated with this feature has the specified
* name in bytecode .
* @ param name a method name in bytecode
* @ return < tt > true < / tt iff any of the methods associated with this feature
* has the specified name in bytecode */
public boolean hasBy... | if ( featureMethod . hasBytecodeName ( name ) ) return true ; if ( dataProcessorMethod != null && dataProcessorMethod . hasBytecodeName ( name ) ) return true ; for ( DataProviderInfo provider : dataProviders ) if ( provider . getDataProviderMethod ( ) . hasBytecodeName ( name ) ) return true ; return false ; |
public class DynamoDBTableMapper { /** * Transactionally writes objects specified by transactionWriteRequest by calling
* { @ link com . amazonaws . services . dynamodbv2 . datamodeling . DynamoDBMapper # transactionWrite ( TransactionWriteRequest ) } API .
* @ param transactionWriteRequest List of objects to write... | for ( TransactionWriteRequest . TransactionWriteOperation transactionWriteOperation : transactionWriteRequest . getTransactionWriteOperations ( ) ) { if ( ! model . targetType ( ) . equals ( transactionWriteOperation . getObject ( ) . getClass ( ) ) ) { throw new DynamoDBMappingException ( "Input object is of the class... |
public class SamlObjectSignatureValidator { /** * Gets role descriptor resolver .
* @ param resolver the resolver
* @ param context the context
* @ param profileRequest the profile request
* @ return the role descriptor resolver
* @ throws Exception the exception */
protected RoleDescriptorResolver getRoleDes... | val idp = casProperties . getAuthn ( ) . getSamlIdp ( ) ; return SamlIdPUtils . getRoleDescriptorResolver ( resolver , idp . getMetadata ( ) . isRequireValidMetadata ( ) ) ; |
public class RuleProviderSorter { /** * Perform the entire sort operation */
private void sort ( ) { } } | DefaultDirectedWeightedGraph < RuleProvider , DefaultEdge > graph = new DefaultDirectedWeightedGraph < > ( DefaultEdge . class ) ; for ( RuleProvider provider : providers ) { graph . addVertex ( provider ) ; } addProviderRelationships ( graph ) ; checkForCycles ( graph ) ; List < RuleProvider > result = new ArrayList <... |
public class PreloadFontManager { /** * Create and add a new embedding { @ link PreloadFont } if it is not yet
* contained .
* @ param aFontResProvider
* The font resource provider to be added for embedding . May not be
* < code > null < / code > .
* @ return The created { @ link PreloadFont } . Never < code ... | ValueEnforcer . notNull ( aFontResProvider , "FontResProvider" ) ; return getOrAddEmbeddingPreloadFont ( aFontResProvider . getFontResource ( ) ) ; |
public class UpdateManagedInstanceRoleRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( UpdateManagedInstanceRoleRequest updateManagedInstanceRoleRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( updateManagedInstanceRoleRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( updateManagedInstanceRoleRequest . getInstanceId ( ) , INSTANCEID_BINDING ) ; protocolMarshaller . marshall ( updateManagedInstanceRoleRequest . getIamR... |
public class OmemoService { /** * Decrypt an OMEMO message .
* @ param managerGuard authenticated OmemoManager .
* @ param senderJid BareJid of the sender .
* @ param omemoElement omemoElement .
* @ return decrypted OmemoMessage object .
* @ throws CorruptedOmemoKeyException if the identityKey of the sender i... | OmemoManager manager = managerGuard . get ( ) ; int senderId = omemoElement . getHeader ( ) . getSid ( ) ; OmemoDevice senderDevice = new OmemoDevice ( senderJid , senderId ) ; CipherAndAuthTag cipherAndAuthTag = getOmemoRatchet ( manager ) . retrieveMessageKeyAndAuthTag ( senderDevice , omemoElement ) ; // Retrieve se... |
public class AbstractLifeCycle { /** * Propagates a change of { @ link State } to all the
* { @ link StateListener } registered with this life cycle
* object .
* @ see # changeState ( State , State )
* @ param from the old state
* @ param to the new state
* @ throws Exception if a listener fails to accept t... | final Collection < StateListener > listeners = getStateListeners ( ) ; synchronized ( listeners ) { for ( StateListener listener : listeners ) { listener . stateChanged ( from , to ) ; } } |
public class JobTrackerTraits { /** * Get the diagnostics for a given task
* @ param taskId the id of the task
* @ return an array of the diagnostic messages */
protected String [ ] getTaskDiagnosticsImpl ( TaskAttemptID taskId ) throws IOException { } } | List < String > taskDiagnosticInfo = null ; JobID jobId = taskId . getJobID ( ) ; TaskID tipId = taskId . getTaskID ( ) ; JobInProgressTraits job = getJobInProgress ( jobId ) ; if ( job != null && job . inited ( ) ) { TaskInProgress tip = job . getTaskInProgress ( tipId ) ; if ( tip != null ) { taskDiagnosticInfo = tip... |
public class AFactoryAppBeansMysql { /** * < p > Get Service that prepare Database after full import
* in lazy mode . < / p >
* @ return IDelegator - preparator Database after full import .
* @ throws Exception - an exception */
@ Override public final synchronized PrepareDbAfterGetCopy lazyGetPrepareDbAfterFullI... | String beanName = getPrepareDbAfterFullImportName ( ) ; PrepareDbAfterGetCopy prepareDbAfterGetCopyMysql = ( PrepareDbAfterGetCopy ) getBeansMap ( ) . get ( beanName ) ; if ( prepareDbAfterGetCopyMysql == null ) { prepareDbAfterGetCopyMysql = new PrepareDbAfterGetCopy ( ) ; prepareDbAfterGetCopyMysql . setLogger ( lazy... |
public class Neo4JIndexManager { /** * Adds Node Index for all singular attributes ( including ID ) of a given
* entity
* @ param entityMetadata
* @ param node
* @ param metaModel
* @ param nodeIndex */
private void addNodeIndex ( EntityMetadata entityMetadata , Node node , Index < Node > nodeIndex , Metamode... | // MetamodelImpl metaModel = ( MetamodelImpl ) kunderaMetadata . getApplicationMetadata ( ) . getMetamodel (
// entityMetadata . getPersistenceUnit ( ) ) ;
// ID attribute has to be indexed necessarily
String idColumnName = ( ( AbstractAttribute ) entityMetadata . getIdAttribute ( ) ) . getJPAColumnName ( ) ; nodeIndex... |
public class StatFsHelper { /** * Update stats for a single directory and return the StatFs object for that directory . If the
* directory does not exist or the StatFs restat ( ) or constructor fails ( throws ) , a null StatFs
* object is returned . */
private @ Nullable StatFs updateStatsHelper ( @ Nullable StatFs... | if ( dir == null || ! dir . exists ( ) ) { // The path does not exist , do not track stats for it .
return null ; } try { if ( statfs == null ) { // Create a new StatFs object for this path .
statfs = createStatFs ( dir . getAbsolutePath ( ) ) ; } else { // Call restat and keep the existing StatFs object .
statfs . res... |
public class QueryBuilder { /** * Shortcut for { @ link # deleteFrom ( CqlIdentifier ) deleteFrom ( CqlIdentifier . fromCql ( table ) ) } */
@ NonNull public static DeleteSelection deleteFrom ( @ NonNull String table ) { } } | return deleteFrom ( CqlIdentifier . fromCql ( table ) ) ; |
public class FixedDelayBuilder { /** * Set the maximum number of attempts .
* You can specify a direct value . For example :
* < pre >
* . maxRetries ( " 10 " ) ;
* < / pre >
* You can also specify one or several property keys . For example :
* < pre >
* . delay ( " $ { custom . property . high - priority... | for ( String m : maxRetries ) { if ( m != null ) { maxRetriesProps . add ( m ) ; } } return this ; |
public class MatrixToImageWriter { /** * Writes a { @ link BitMatrix } to a file with default configuration .
* @ param matrix { @ link BitMatrix } to write
* @ param format image format
* @ param file file { @ link Path } to write image to
* @ throws IOException if writes to the stream fail
* @ see # toBuffe... | writeToPath ( matrix , format , file , DEFAULT_CONFIG ) ; |
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } { @ link PointArrayPropertyType } { @ code > }
* @ param value
* Java instance representing xml element ' s value .
* @ return
* the new instance of { @ link JAXBElement } { @ code < } { @ link PointArrayPropertyType } ... | return new JAXBElement < PointArrayPropertyType > ( _PointArrayProperty_QNAME , PointArrayPropertyType . class , null , value ) ; |
public class RemoveIpRoutesRequest { /** * IP address blocks that you want to remove .
* @ return IP address blocks that you want to remove . */
public java . util . List < String > getCidrIps ( ) { } } | if ( cidrIps == null ) { cidrIps = new com . amazonaws . internal . SdkInternalList < String > ( ) ; } return cidrIps ; |
public class IsoChronology { /** * Obtains an ISO local date from the era , year - of - era and day - of - year fields .
* @ param era the ISO era , not null
* @ param yearOfEra the ISO year - of - era
* @ param dayOfYear the ISO day - of - year
* @ return the ISO local date , not null
* @ throws DateTimeExce... | return dateYearDay ( prolepticYear ( era , yearOfEra ) , dayOfYear ) ; |
public class Ransac { /** * Turns the current candidates into the best ones . */
protected void swapCandidateWithBest ( ) { } } | List < Point > tempPts = candidatePoints ; candidatePoints = bestFitPoints ; bestFitPoints = tempPts ; int tempIndex [ ] = matchToInput ; matchToInput = bestMatchToInput ; bestMatchToInput = tempIndex ; Model m = candidateParam ; candidateParam = bestFitParam ; bestFitParam = m ; |
public class CSSPageRuleImpl { /** * { @ inheritDoc } */
@ Override public void setCssText ( final String cssText ) throws DOMException { } } | try { final CSSOMParser parser = new CSSOMParser ( ) ; final AbstractCSSRuleImpl r = parser . parseRule ( cssText ) ; // The rule must be a page rule
if ( r instanceof CSSPageRuleImpl ) { pseudoPage_ = ( ( CSSPageRuleImpl ) r ) . pseudoPage_ ; style_ = ( ( CSSPageRuleImpl ) r ) . style_ ; } else { throw new DOMExceptio... |
public class NettyMessage { /** * Allocates a new ( header and contents ) buffer and adds some header information for the frame
* decoder .
* < p > If the < tt > contentLength < / tt > is unknown , you must write the actual length after adding
* the contents as an integer to position < tt > 0 < / tt > !
* @ par... | return allocateBuffer ( allocator , id , 0 , contentLength , true ) ; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.