signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class OutputContext { /** * Get an OutputBuffer containing a subset of the current one
* @ param limit How many bytes should be available
* @ return a new OutputContext */
public OutputContext getSlice ( int limit ) { } } | List < ByteBuffer > newBufs = new LinkedList < ByteBuffer > ( ) ; ByteBuffer buf = ByteBuffer . allocate ( limit ) ; Iterator < ByteBuffer > iter = buffers . iterator ( ) ; while ( iter . hasNext ( ) && buf . position ( ) < buf . limit ( ) ) { ByteBuffer cur = iter . next ( ) ; int diff = buf . limit ( ) - buf . positi... |
public class ConcurrentCache { /** * Returns a set of entries in this cache .
* @ return cache entries */
public Set < Entry < K , V > > entrySet ( ) { } } | TreeSet < Entry < K , V > > set = new TreeSet < Entry < K , V > > ( ) ; synchronized ( this ) { for ( K key : keySet ( ) ) { if ( containsKey ( key ) ) { get ( key ) ; set . add ( getEntry ( key ) ) ; } } return set ; } |
public class CachingPolicy { /** * If the request is cached an { @ link IConnectorInterceptor } is set in order to prevent the back - end connection to be established .
* Otherwise an empty { @ link CachedResponse } will be added to the context , this will be used to cache the response once it has been
* received f... | if ( config . getTtl ( ) > 0 ) { // Check to see if there is a cache entry for this request . If so , we need to
// short - circuit the connector factory by providing a connector interceptor
String cacheId = buildCacheID ( request ) ; context . setAttribute ( CACHE_ID_ATTR , cacheId ) ; ICacheStoreComponent cache = con... |
public class CharStream { /** * Zip together the " a " , " b " and " c " arrays until one of them runs out of values .
* Each triple of values is combined into a single value using the supplied zipFunction function .
* @ param a
* @ param b
* @ return */
public static CharStream zip ( final char [ ] a , final c... | return Stream . zip ( a , b , c , zipFunction ) . mapToChar ( ToCharFunction . UNBOX ) ; |
public class AclXmlFactory { /** * Returns an XML fragment representing the specified Grantee .
* @ param grantee
* The grantee to convert to an XML representation that can be
* sent to Amazon S3 as part of a request .
* @ param xml
* The XmlWriter to which to concatenate this node to .
* @ return The given... | if ( grantee instanceof CanonicalGrantee ) { return convertToXml ( ( CanonicalGrantee ) grantee , xml ) ; } else if ( grantee instanceof EmailAddressGrantee ) { return convertToXml ( ( EmailAddressGrantee ) grantee , xml ) ; } else if ( grantee instanceof GroupGrantee ) { return convertToXml ( ( GroupGrantee ) grantee ... |
public class JaxWsHttpServletRequestAdapter { /** * ( non - Javadoc )
* @ see javax . servlet . ServletRequest # getDispatcherType ( ) */
@ Override public DispatcherType getDispatcherType ( ) { } } | try { collaborator . preInvoke ( componentMetaData ) ; return request . getDispatcherType ( ) ; } finally { collaborator . postInvoke ( ) ; } |
public class Transformations { /** * rSum transformation */
public float rSum ( float [ ] y , float [ ] w ) { } } | float tmp1 = ( float ) 0.0 , tmp2 = ( float ) 0.0 ; for ( int i = 0 ; i < y . length ; i ++ ) { tmp1 += y [ i ] * w [ i ] ; tmp2 += w [ i ] ; } return correctTo01 ( tmp1 / tmp2 ) ; |
public class CharRange { /** * < p > Are all the characters of the passed in range contained in
* this range . < / p >
* @ param range the range to check against
* @ return { @ code true } if this range entirely contains the input range
* @ throws IllegalArgumentException if { @ code null } input */
public bool... | Validate . isTrue ( range != null , "The Range must not be null" ) ; if ( negated ) { if ( range . negated ) { return start >= range . start && end <= range . end ; } return range . end < start || range . start > end ; } if ( range . negated ) { return start == 0 && end == Character . MAX_VALUE ; } return start <= rang... |
public class Counters { /** * Multiplies each value in target by the given multiplier , in place .
* @ param target
* The values in this Counter will be changed throught by the
* multiplier
* @ param multiplier
* The number by which to change each number in the Counter */
public static < E > Counter < E > mul... | for ( Entry < E , Double > entry : target . entrySet ( ) ) { target . setCount ( entry . getKey ( ) , entry . getValue ( ) * multiplier ) ; } return target ; |
public class ObjIterator { /** * Lazy evaluation .
* @ param arraySupplier
* @ return */
public static < T > ObjIterator < T > oF ( final Supplier < T [ ] > arraySupplier ) { } } | N . checkArgNotNull ( arraySupplier , "arraySupplier" ) ; return new ObjIterator < T > ( ) { private T [ ] aar = null ; private int len = 0 ; private int cur = 0 ; private boolean isInitialized = false ; @ Override public boolean hasNext ( ) { if ( isInitialized == false ) { init ( ) ; } return cur < len ; } @ Override... |
public class FieldInfo { /** * Handle { @ link Repeatable } annotations .
* @ param allRepeatableAnnotationNames
* the names of all repeatable annotations */
void handleRepeatableAnnotations ( final Set < String > allRepeatableAnnotationNames ) { } } | if ( annotationInfo != null ) { annotationInfo . handleRepeatableAnnotations ( allRepeatableAnnotationNames , getClassInfo ( ) , RelType . FIELD_ANNOTATIONS , RelType . CLASSES_WITH_FIELD_ANNOTATION ) ; } |
public class KeywordQueryFactory { /** * - - - - - private methods - - - - - */
protected String escape ( final Object src ) { } } | final StringBuilder output = new StringBuilder ( ) ; final String input = src . toString ( ) ; for ( int i = 0 ; i < input . length ( ) ; i ++ ) { final char c = input . charAt ( i ) ; final String prefix = SPECIAL_CHARS . get ( c ) ; if ( prefix != null ) { output . append ( prefix ) ; } output . append ( c ) ; } retu... |
public class MlBaseState { /** * { @ inheritDoc } */
@ Override public List < T > multiGet ( List < List < Object > > keys ) { } } | // keysにはStateBaseNameの名称のみが指定される 。 そのため 、 1要素目を用いればいい 。
String baseKey = ( String ) keys . get ( 0 ) . get ( 0 ) ; // 前回のクラスタ実行結果を取得する 。 存在しない場合は空値として扱う 。
List < T > dataModels = new ArrayList < > ( ) ; T dataModel = null ; Long previousTxId = null ; if ( this . previousSaveTxId == null ) { // クエリによってtxIdが存在しない状態で... |
public class ServerProvisioningFeaturePack { /** * Creates a provisioning config file for each { @ link org . wildfly . build . common . model . ConfigFile } provided .
* @ param featurePackFile
* @ param configFiles
* @ param configOverride
* @ param configFileOverrides
* @ return */
private static List < Co... | final List < ConfigFile > result = new ArrayList < > ( ) ; if ( configOverride != null ) { if ( configFileOverrides != null && ! configFileOverrides . isEmpty ( ) ) { for ( org . wildfly . build . common . model . ConfigFile featurePackConfigFile : configFiles ) { ConfigFileOverride configFileOverride = configFileOverr... |
public class CmsMove { /** * Returns the current name of the resource without path information . < p >
* This is used to preset the input text field with the current resource name for single resource operations . < p >
* @ return the current name of the resource without path information */
public String getCurrentR... | if ( isMultiOperation ( ) ) { return "" ; } String resourceName = CmsResource . getName ( getParamResource ( ) ) ; if ( resourceName . endsWith ( "/" ) ) { resourceName = resourceName . substring ( 0 , resourceName . length ( ) - 1 ) ; } return resourceName ; |
public class RemoteConsumerTransmit { /** * / * ( non - Javadoc )
* @ see com . ibm . ws . sib . processor . runtime . SIMPDeliveryStreamSetTransmitControllable # forceFlushAtSource ( ) */
public void forceFlushAtSource ( ) { } } | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "forceFlushAtSource" ) ; _aoh . forceFlushAtSource ( _aoStream . getRemoteMEUuid ( ) , _aoStream . getGatheringTargetDestUuid ( ) ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . exit ( ... |
public class AuditActionContextCouchDbRepository { /** * Find audit records since + localDate + .
* @ param localDate Date to search from .
* @ return Audit records from after + localDate + . */
@ View ( name = "by_when_action_was_performed" , map = "function(doc) { if(doc.whenActionWasPerformed) { emit(doc.whenAct... | return db . queryView ( createQuery ( "by_when_action_was_performed" ) . startKey ( localDate ) . includeDocs ( true ) , CouchDbAuditActionContext . class ) ; |
public class ChangeObjects { /** * method to replace the MonomerNotation having the MonomerID with the new
* MonomerID
* @ param monomerNotation
* given monomer notation
* @ param existingMonomerID
* existing monomer id
* @ param newMonomerID
* new monomer id
* @ return MonomerNotation , if it had the o... | /* Nucleotide */
if ( monomerNotation instanceof MonomerNotationUnitRNA ) { List < String > result = generateIDForNucleotide ( ( ( MonomerNotationUnitRNA ) monomerNotation ) , existingMonomerID , newMonomerID ) ; if ( result . get ( 1 ) != null ) { MonomerNotationUnitRNA newObject = new MonomerNotationUnitRNA ( result ... |
public class SigningJobMarshaller { /** * Marshall the given parameter object . */
public void marshall ( SigningJob signingJob , ProtocolMarshaller protocolMarshaller ) { } } | if ( signingJob == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( signingJob . getJobId ( ) , JOBID_BINDING ) ; protocolMarshaller . marshall ( signingJob . getSource ( ) , SOURCE_BINDING ) ; protocolMarshaller . marshall ( signingJob . get... |
public class Job { /** * Overrides from job properties .
* @ see JobProperty # getJobOverrides */
public Collection < ? > getOverrides ( ) { } } | List < Object > r = new ArrayList < > ( ) ; for ( JobProperty < ? super JobT > p : properties ) r . addAll ( p . getJobOverrides ( ) ) ; return r ; |
public class BaseX { /** * Updates { @ code min } and { @ code max } so that the range { @ code min . . max }
* includes all values from { @ code chars } .
* @ param chars
* the list of characters to process . */
private void addMinMax ( String chars ) { } } | for ( int i = 0 ; i < chars . length ( ) ; i ++ ) { int c = chars . codePointAt ( i ) ; if ( min == - 1 || min > c ) { min = c ; } if ( max == - 1 || max < c ) { max = c ; } } |
public class CPDefinitionLinkPersistenceImpl { /** * Returns the cp definition links before and after the current cp definition link in the ordered set where uuid = & # 63 ; .
* @ param CPDefinitionLinkId the primary key of the current cp definition link
* @ param uuid the uuid
* @ param orderByComparator the com... | CPDefinitionLink cpDefinitionLink = findByPrimaryKey ( CPDefinitionLinkId ) ; Session session = null ; try { session = openSession ( ) ; CPDefinitionLink [ ] array = new CPDefinitionLinkImpl [ 3 ] ; array [ 0 ] = getByUuid_PrevAndNext ( session , cpDefinitionLink , uuid , orderByComparator , true ) ; array [ 1 ] = cpDe... |
public class Boss { /** * Add thread to managed list
* @ param worker the supervised worker */
public void manage ( SupervisedWorker worker ) { } } | if ( worker == null ) throw new IllegalArgumentException ( "worker required in Boss.manage" ) ; worker . setSupervisor ( this ) ; this . workers . add ( worker ) ; |
public class CPDefinitionVirtualSettingWrapper { /** * Sets the localized terms of use contents of this cp definition virtual setting from the map of locales and localized terms of use contents , and sets the default locale .
* @ param termsOfUseContentMap the locales and localized terms of use contents of this cp de... | _cpDefinitionVirtualSetting . setTermsOfUseContentMap ( termsOfUseContentMap , defaultLocale ) ; |
public class Base64 { /** * Encode a Byte array and return the encoded string .
* @ param in A string to encode .
* @ return The encoded byte array . */
public static String encode ( Byte [ ] in ) { } } | byte [ ] tmp = new byte [ in . length ] ; for ( int i = 0 ; i < tmp . length ; i ++ ) { tmp [ i ] = in [ i ] ; } return encode ( tmp ) ; |
public class FSDirectory { /** * Updates namespace and diskspace consumed for all
* directories until the parent directory of file represented by path .
* @ param path path for the file .
* @ param inodes inode array representation of the path
* @ param nsDelta the delta change of namespace
* @ param dsDelta ... | writeLock ( ) ; try { if ( inodes == null ) { inodes = rootDir . getExistingPathINodes ( path ) ; } int len = inodes . length ; if ( inodes [ len - 1 ] == null ) { throw new FileNotFoundException ( path + " does not exist under rootDir." ) ; } updateCount ( inodes , len - 1 , nsDelta , dsDelta , true ) ; } finally { wr... |
public class HttpSessionAdapter { /** * Method adapt
* This method adapts a protocol agnostic session into one that conforms to a protocol such as HTTP .
* @ see com . ibm . wsspi . session . IProtocolAdapter # adapt ( com . ibm . wsspi . session . ISession , Integer ) */
public Object adapt ( ISession session ) { ... | Object adaptation = session . getAdaptation ( ) ; if ( null == adaptation ) { adaptation = new HttpSessionImpl ( session ) ; session . setAdaptation ( adaptation ) ; } return adaptation ; |
public class DataService { /** * Method to retrieve records for the given list of query
* @ param query
* the query string
* @ return query result
* @ throws FMSException
* throws FMSException */
public QueryResult executeQuery ( String query ) throws FMSException { } } | IntuitMessage intuitMessage = prepareQuery ( query ) ; // execute interceptors
executeInterceptors ( intuitMessage ) ; QueryResult queryResult = null ; // Iterate the IntuitObjects list in QueryResponse and convert to < T > entity
IntuitResponse intuitResponse = ( IntuitResponse ) intuitMessage . getResponseElements ( ... |
public class WSJobRepositoryImpl { /** * { @ inheritDoc } */
@ Override public WSJobInstance getJobInstanceFromExecution ( long executionId ) throws NoSuchJobExecutionException , JobSecurityException { } } | long instanceId = persistenceManagerService . getJobInstanceIdFromExecutionId ( authorizedExecutionRead ( executionId ) ) ; return persistenceManagerService . getJobInstance ( instanceId ) ; |
public class TransformerIdentityImpl { /** * Set the output properties for the transformation . These
* properties will override properties set in the Templates
* with xsl : output .
* < p > If argument to this function is null , any properties
* previously set are removed , and the value will revert to the val... | if ( null != oformat ) { // See if an * explicit * method was set .
String method = ( String ) oformat . get ( OutputKeys . METHOD ) ; if ( null != method ) m_outputFormat = new OutputProperties ( method ) ; else m_outputFormat = new OutputProperties ( ) ; m_outputFormat . copyFrom ( oformat ) ; } else { // if oformat ... |
public class FedoraEventImpl { /** * Convert a JCR Event to a FedoraEvent
* @ param event the JCR Event
* @ return a FedoraEvent */
public static FedoraEvent from ( final Event event ) { } } | requireNonNull ( event ) ; try { @ SuppressWarnings ( "unchecked" ) final Map < String , String > info = new HashMap < > ( event . getInfo ( ) ) ; final String userdata = event . getUserData ( ) ; try { if ( userdata != null && ! userdata . isEmpty ( ) ) { final JsonNode json = MAPPER . readTree ( userdata ) ; if ( jso... |
public class MediaTypeParser { /** * Converts a string such as " text / plain " into a MediaType object .
* @ param value The value to parse
* @ return A MediaType object */
public static MediaType fromString ( String value ) { } } | if ( value == null ) { throw new NullPointerException ( "value" ) ; } List < ParameterizedHeaderWithValue > headerValues = ParameterizedHeaderWithValue . fromString ( value ) ; if ( headerValues . isEmpty ( ) ) { throw new IllegalArgumentException ( "The value '" + value + "' did not contain a valid header value" ) ; }... |
public class AbatisService { /** * Default DB file nameを利用する外部Constructor
* @ param context
* 呼び出し元Contextオブジェクト
* @ param dbName
* 生成するDB file name */
protected static AbatisService getInstance ( Context context , int version ) { } } | if ( instance == null ) { instance = new AbatisService ( context , version ) ; } return instance ; |
public class CmsXmlSitemapActionElement { /** * Constructs an XML sitemap generator given an XML sitemap configuration file . < p >
* @ param seoFileRes the sitemap XML file
* @ param config the parsed configuration
* @ return the sitemap generator , or null if the given configuration is not an XML sitemap config... | if ( config . getMode ( ) . equals ( CmsXmlSeoConfiguration . MODE_XML_SITEMAP ) ) { String baseFolderRootPath = CmsFileUtil . removeTrailingSeparator ( CmsResource . getParentFolder ( seoFileRes . getRootPath ( ) ) ) ; CmsXmlSitemapGenerator xmlSitemapGenerator = createSitemapGenerator ( config . getSitemapGeneratorCl... |
public class SpotifyApi { /** * Get a playlist .
* @ deprecated Playlist IDs are unique for themselves . This parameter is thus no longer used .
* ( https : / / developer . spotify . com / community / news / 2018/06/12 / changes - to - playlist - uris / )
* @ param user _ id The playlists owners username .
* @ ... | return new GetPlaylistRequest . Builder ( accessToken ) . setDefaults ( httpManager , scheme , host , port ) . user_id ( user_id ) . playlist_id ( playlist_id ) ; |
public class XMLUnit { /** * Utility method to build a Document using a specific DocumentBuilder
* and reading characters from a specific Reader .
* @ param withBuilder
* @ param fromReader
* @ return Document built
* @ throws SAXException
* @ throws IOException */
public static Document buildDocument ( Doc... | return buildDocument ( withBuilder , new InputSource ( fromReader ) ) ; |
public class StubObject { /** * Create a { @ link StubObject } using the provided user ID and a new object ID
* @ param sUserID
* User ID
* @ param aCustomAttrs
* Custom attributes . May be < code > null < / code > .
* @ return Never < code > null < / code > . */
@ Nonnull public static StubObject createForUs... | return new StubObject ( GlobalIDFactory . getNewPersistentStringID ( ) , sUserID , aCustomAttrs ) ; |
public class XDSRepositoryAuditor { /** * Get an instance of the XDS Document Repository Auditor from the
* global context
* @ return XDS Document Repository Auditor instance */
public static XDSRepositoryAuditor getAuditor ( ) { } } | AuditorModuleContext ctx = AuditorModuleContext . getContext ( ) ; return ( XDSRepositoryAuditor ) ctx . getAuditor ( XDSRepositoryAuditor . class ) ; |
public class BandwidthGroupTargeting { /** * Gets the bandwidthGroups value for this BandwidthGroupTargeting .
* @ return bandwidthGroups * The bandwidth groups that are being targeted or excluded by
* the
* { @ link LineItem } . */
public com . google . api . ads . admanager . axis . v201808 . Technology [ ] get... | return bandwidthGroups ; |
public class CustomMatchingStrategy { /** * Gets the collection match for the web resource collection based on the following custom method algorithm .
* < pre >
* Custom method matching use case .
* Happy path :
* 1 . Validate the resource name matches one of the URL patterns
* 2 . Validate the method matches... | CollectionMatch match = null ; CollectionMatch collectionMatchFound = webResourceCollection . performUrlMatch ( resourceName ) ; if ( collectionMatchFound != null ) { if ( webResourceCollection . isMethodMatched ( method ) ) { match = collectionMatchFound ; } else if ( webResourceCollection . isMethodListed ( method ) ... |
public class DateConverter { /** * Converts an { @ link Object } of { @ link Class type S } into an { @ link Object } of { @ link Class type T } .
* @ param value { @ link Object } of { @ link Class type S } to convert .
* @ return the converted { @ link Object } of { @ link Class type T } .
* @ throws Conversion... | if ( value instanceof Calendar ) { return ( ( Calendar ) value ) . getTime ( ) ; } else if ( value instanceof Date ) { return ( Date ) value ; } else if ( value instanceof Number ) { return new Date ( ( ( Number ) value ) . longValue ( ) ) ; } else if ( value instanceof String ) { String valueString = String . valueOf ... |
public class MultiPolylineMarkers { /** * Is it deleted
* @ return */
public boolean isDeleted ( ) { } } | boolean deleted = true ; for ( PolylineMarkers polyline : polylineMarkers ) { deleted = polyline . isDeleted ( ) ; if ( ! deleted ) { break ; } } return deleted ; |
public class JNvgraph { /** * Allocate numsets vectors of size E reprensenting Edge Data and attached them the graph .
* settypes [ i ] is the type of vector # i , currently all Vertex and Edge data should have the same type */
public static int nvgraphAllocateEdgeData ( nvgraphHandle handle , nvgraphGraphDescr descr... | return checkResult ( nvgraphAllocateEdgeDataNative ( handle , descrG , numsets , settypes ) ) ; |
public class EcoreGeneratorFragment { /** * Use { @ link GenModelAccess # getGenPackage ( EPackage , ResourceSet ) } */
@ Deprecated protected List < GenPackage > loadReferencedGenModels ( ResourceSet rs ) { } } | List < GenPackage > result = Lists . newArrayList ( ) ; if ( getReferencedGenModels ( ) != null ) { for ( String uri : getReferencedGenModels ( ) . split ( "," ) ) { try { Resource resource = rs . getResource ( URI . createURI ( uri . trim ( ) ) , true ) ; GenModel genmodel = ( GenModel ) resource . getContents ( ) . g... |
public class ProtoBufBuilderProcessor { /** * Method adds a new default message instance to the repeated field and return it ' s builder instance .
* @ param repeatedFieldDescriptor The field descriptor of the repeated field .
* @ param builder The builder instance of the message which contains the repeated field .... | if ( repeatedFieldDescriptor == null ) { throw new NotAvailableException ( "repeatedFieldDescriptor" ) ; } return addDefaultInstanceToRepeatedField ( repeatedFieldDescriptor . getName ( ) , builder ) ; |
public class MVQueryRewriter { /** * JSON deserializers - - pretend that deserialization will never fail */
private static AbstractExpression predicate_of ( MaterializedViewInfo mv ) { } } | try { return AbstractExpression . fromJSONString ( Encoder . hexDecodeToString ( mv . getPredicate ( ) ) , null ) ; } catch ( JSONException e ) { return null ; } |
public class ReadOnlyUtils { /** * Extracts the version id from a string
* @ param versionDir The string
* @ return Returns the version id of the directory , else - 1 */
private static long getVersionId ( String versionDir ) { } } | try { return Long . parseLong ( versionDir . replace ( "version-" , "" ) ) ; } catch ( NumberFormatException e ) { logger . trace ( "Cannot parse version directory to obtain id " + versionDir ) ; return - 1 ; } |
public class ShakeAroundAPI { /** * 批量查询设备统计数据接口
* @ param accessToken accessToken
* @ param statisticsDeviceList statisticsDeviceList
* @ return result */
public static StatisticsDeviceListResult statisticsDeviceList ( String accessToken , StatisticsDeviceList statisticsDeviceList ) { } } | return statisticsDeviceList ( accessToken , JsonUtil . toJSONString ( statisticsDeviceList ) ) ; |
public class vpnclientlessaccesspolicy { /** * Use this API to add vpnclientlessaccesspolicy . */
public static base_response add ( nitro_service client , vpnclientlessaccesspolicy resource ) throws Exception { } } | vpnclientlessaccesspolicy addresource = new vpnclientlessaccesspolicy ( ) ; addresource . name = resource . name ; addresource . rule = resource . rule ; addresource . profilename = resource . profilename ; return addresource . add_resource ( client ) ; |
public class LinearClassifier { /** * Returns number of features with weight above a certain threshold
* ( across all labels )
* @ param threshold Threshold above which we will count the feature
* @ param useMagnitude Whether the notion of " large " should ignore
* the sign of the feature weight .
* @ return ... | int n = 0 ; for ( int feat = 0 ; feat < weights . length ; feat ++ ) { for ( int lab = 0 ; lab < weights [ feat ] . length ; lab ++ ) { double thisWeight = ( useMagnitude ) ? Math . abs ( weights [ feat ] [ lab ] ) : weights [ feat ] [ lab ] ; if ( thisWeight > threshold ) { n ++ ; } } } return n ; |
public class OAuth20Utils { /** * Write to the output this error .
* @ param response the response
* @ param error error message
* @ return json - backed view . */
public static ModelAndView writeError ( final HttpServletResponse response , final String error ) { } } | val model = CollectionUtils . wrap ( OAuth20Constants . ERROR , error ) ; val mv = new ModelAndView ( new MappingJackson2JsonView ( MAPPER ) , ( Map ) model ) ; mv . setStatus ( HttpStatus . BAD_REQUEST ) ; response . setStatus ( HttpStatus . BAD_REQUEST . value ( ) ) ; return mv ; |
public class GradleToolingHelper { /** * Translate the given { @ link DependencyDescriptor } in to an instance of { @ link ArtifactSpec } . */
public static ArtifactSpec toArtifactSpec ( DependencyDescriptor descriptor ) { } } | return new ArtifactSpec ( descriptor . getScope ( ) , descriptor . getGroup ( ) , descriptor . getName ( ) , descriptor . getVersion ( ) , descriptor . getType ( ) , descriptor . getClassifier ( ) , descriptor . getFile ( ) ) ; |
public class MessageProcessInfoManualField { /** * Set up the default screen control for this field .
* @ param itsLocation Location of this component on screen ( ie . , GridBagConstraint ) .
* @ param targetScreen Where to place this component ( ie . , Parent screen or GridBagLayout ) .
* @ param converter The c... | ScreenComponent screenField = super . setupDefaultView ( itsLocation , targetScreen , converter , iDisplayFieldDesc , properties ) ; for ( int i = 0 ; ; i ++ ) { Object comp = converter . getField ( ) . getComponent ( i ) ; if ( comp == null ) break ; if ( comp instanceof ScreenComponent ) { ( ( ScreenComponent ) comp ... |
public class IterUtil { /** * 字段值与列表值对应的Map , 常用于元素对象中有唯一ID时需要按照这个ID查找对象的情况 < br >
* 例如 : 车牌号 = 》 车
* @ param < K > 字段名对应值得类型 , 不确定请使用Object
* @ param < V > 对象类型
* @ param iter 对象列表
* @ param fieldName 字段名 ( 会通过反射获取其值 )
* @ return 某个字段值与对象对应Map
* @ since 4.0.4 */
@ SuppressWarnings ( "unchecked" ) public ... | final Map < K , V > result = new HashMap < > ( ) ; if ( null != iter ) { V value ; while ( iter . hasNext ( ) ) { value = iter . next ( ) ; result . put ( ( K ) ReflectUtil . getFieldValue ( value , fieldName ) , value ) ; } } return result ; |
public class JMThread { /** * Start with single executor service executor service .
* @ param message the message
* @ param runnable the runnable
* @ return the executor service */
public static ExecutorService startWithSingleExecutorService ( String message , Runnable runnable ) { } } | return startWithExecutorService ( newSingleThreadPool ( ) , message , runnable ) ; |
public class DictTerm { /** * setter for DictCanon - sets canonical form
* @ generated
* @ param v value to set into the feature */
public void setDictCanon ( String v ) { } } | if ( DictTerm_Type . featOkTst && ( ( DictTerm_Type ) jcasType ) . casFeat_DictCanon == null ) jcasType . jcas . throwFeatMissing ( "DictCanon" , "org.apache.uima.conceptMapper.DictTerm" ) ; jcasType . ll_cas . ll_setStringValue ( addr , ( ( DictTerm_Type ) jcasType ) . casFeatCode_DictCanon , v ) ; |
public class ResourceDataSyncItemMarshaller { /** * Marshall the given parameter object . */
public void marshall ( ResourceDataSyncItem resourceDataSyncItem , ProtocolMarshaller protocolMarshaller ) { } } | if ( resourceDataSyncItem == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( resourceDataSyncItem . getSyncName ( ) , SYNCNAME_BINDING ) ; protocolMarshaller . marshall ( resourceDataSyncItem . getS3Destination ( ) , S3DESTINATION_BINDING ) ... |
public class DataSiftManagedSource { /** * Create a new managed source
* @ param name the name of the source
* @ param source the source and its configuratiosn
* @ return this */
public < T extends DataSource > FutureData < ManagedSource > create ( String name , T source ) { } } | return updateOrCreate ( name , source , null ) ; |
public class EsUtil { /** * Changes the givenm alias to refer tot eh supplied index name
* @ param index the index we were building
* @ param alias to refer to this index
* @ return 0 fir ok < 0 for not ok
* @ throws IndexException */
public int swapIndex ( final String index , final String alias ) throws Index... | // IndicesAliasesResponse resp = null ;
try { /* index is the index we were just indexing into */
final IndicesAdminClient idx = getAdminIdx ( ) ; final GetAliasesRequestBuilder igarb = idx . prepareGetAliases ( alias ) ; final ActionFuture < GetAliasesResponse > getAliasesAf = idx . getAliases ( igarb . request ( ) ) ... |
public class ExposeLinearLayoutManagerEx { /** * < p > Scroll the RecyclerView to make the position visible . < / p >
* < p > RecyclerView will scroll the minimum amount that is necessary to make the
* target position visible . If you are looking for a similar behavior to
* { @ link android . widget . ListView # ... | mCurrentPendingScrollPosition = position ; mPendingScrollPositionOffset = INVALID_OFFSET ; if ( mCurrentPendingSavedState != null ) { mCurrentPendingSavedState . putInt ( "AnchorPosition" , RecyclerView . NO_POSITION ) ; } requestLayout ( ) ; |
public class DeviceInfo { public static void main ( String [ ] args ) { } } | if ( args . length == 0 ) { System . out . println ( "Device name ?" ) ; System . exit ( 0 ) ; } try { String devname = args [ 0 ] ; Database db = ApiUtil . get_db_obj ( ) ; DeviceInfo info = db . get_device_info ( devname ) ; System . out . println ( info ) ; } catch ( DevFailed e ) { if ( args . length < 2 || args [ ... |
public class IPAddressDivision { /** * Produces a normalized string to represent the segment .
* If the segment CIDR prefix length covers the range , then it is assumed to be a CIDR , and the string has only the lower value of the CIDR range .
* Otherwise , the explicit range will be printed .
* @ return */
@ Ove... | String result = cachedString ; if ( result == null ) { synchronized ( this ) { result = cachedString ; if ( result == null ) { if ( isSinglePrefixBlock ( ) || ! isMultiple ( ) ) { // covers the case of ! isMultiple , ie single addresses , when there is no prefix or the prefix is the bit count
result = getDefaultLowerSt... |
public class InternalXtextParser { /** * InternalXtext . g : 3372:1 : ruleUntilToken returns [ EObject current = null ] : ( otherlv _ 0 = ' - > ' ( ( lv _ terminal _ 1_0 = ruleTerminalTokenElement ) ) ) ; */
public final EObject ruleUntilToken ( ) throws RecognitionException { } } | EObject current = null ; Token otherlv_0 = null ; EObject lv_terminal_1_0 = null ; enterRule ( ) ; try { // InternalXtext . g : 3378:2 : ( ( otherlv _ 0 = ' - > ' ( ( lv _ terminal _ 1_0 = ruleTerminalTokenElement ) ) ) )
// InternalXtext . g : 3379:2 : ( otherlv _ 0 = ' - > ' ( ( lv _ terminal _ 1_0 = ruleTerminalToke... |
public class LocationNumberImpl { /** * makes checks on APRI - see NOTE to APRI in Q . 763 , p 23 */
protected void doAddressPresentationRestricted ( ) { } } | if ( this . addressRepresentationRestrictedIndicator != _APRI_NOT_AVAILABLE ) return ; // NOTE 1 If the parameter is included and the address presentation
// restricted indicator indicates
// address not available , octets 3 to n ( this are digits . ) are omitted ,
// the subfields in items a - odd / evem , b - nai , c... |
public class ModelsSupporter { /** * Calculate the drainage direction factor ( is used in some horton machine like pitfiller ,
* flow , . . . )
* Is the distance betwen the central pixel , in a 3x3 kernel , and the neighboured pixels .
* @ param dx is the resolution of a raster map in the x direction .
* @ para... | // direction factor , where the components are 1 / length
double [ ] fact = new double [ 9 ] ; for ( int k = 1 ; k <= 8 ; k ++ ) { fact [ k ] = 1.0 / ( Math . sqrt ( DIR [ k ] [ 0 ] * dy * DIR [ k ] [ 0 ] * dy + DIR [ k ] [ 1 ] * DIR [ k ] [ 1 ] * dx * dx ) ) ; } return fact ; |
public class ConfigurationUtils { /** * Saves the instances into a file .
* @ param app the application ( not null )
* @ param configurationDirectory the configuration directory */
public static void saveInstances ( Application app ) { } } | File targetFile = new File ( app . getDirectory ( ) , Constants . PROJECT_DIR_INSTANCES + "/" + INSTANCES_FILE ) ; try { Utils . createDirectory ( targetFile . getParentFile ( ) ) ; RuntimeModelIo . writeInstances ( targetFile , app . getRootInstances ( ) ) ; } catch ( IOException e ) { Logger logger = Logger . getLogg... |
public class TCAbortMessageImpl { /** * ( non - Javadoc )
* @ see org . restcomm . protocols . ss7 . tcap . asn . Encodable # encode ( org . mobicents . protocols . asn . AsnOutputStream ) */
public void encode ( AsnOutputStream aos ) throws EncodeException { } } | try { aos . writeTag ( Tag . CLASS_APPLICATION , false , _TAG ) ; int pos = aos . StartContentDefiniteLength ( ) ; aos . writeOctetString ( Tag . CLASS_APPLICATION , _TAG_DTX , this . destTxId ) ; if ( this . type != null ) aos . writeInteger ( Tag . CLASS_APPLICATION , _TAG_P , this . type . getType ( ) ) ; else if ( ... |
public class FilterDriver { /** * parameter setting .
* @ param name parameter name
* @ param value Enum parameter value */
@ SuppressWarnings ( { } } | "unchecked" , "rawtypes" } ) public void setParameter ( String name , Enum value ) { conf . setEnum ( name , value ) ; |
public class ViewRecycler { /** * Inflates the view , which is used to visualize a specific item .
* @ param item
* The item , which should be visualized by the inflated view , as an instance of the
* generic type ItemType . The item may not be null
* @ param parent
* The parent of the inflated view as an ins... | Condition . INSTANCE . ensureNotNull ( params , "The array may not be null" ) ; Condition . INSTANCE . ensureNotNull ( getAdapter ( ) , "No adapter has been set" , IllegalStateException . class ) ; View view = getView ( item ) ; boolean inflated = false ; if ( view == null ) { int viewType = getAdapter ( ) . getViewTyp... |
public class AlertService { /** * Updates an existing trigger .
* @ param alertId The ID of the alert owning the trigger .
* @ param triggerId The ID of the trigger to update .
* @ param trigger The updated trigger information .
* @ return The updated trigger .
* @ throws IOException If the server cannot be r... | String requestUrl = RESOURCE + "/" + alertId . toString ( ) + "/triggers/" + triggerId . toString ( ) ; ArgusResponse response = getClient ( ) . executeHttpRequest ( ArgusHttpClient . RequestType . PUT , requestUrl , trigger ) ; assertValidResponse ( response , requestUrl ) ; return fromJson ( response . getResult ( ) ... |
public class LdapUtils { /** * Execute search operation response .
* @ param connectionFactory the connection factory
* @ param baseDn the base dn
* @ param filter the filter
* @ return the response
* @ throws LdapException the ldap exception */
public static Response < SearchResult > executeSearchOperation (... | return executeSearchOperation ( connectionFactory , baseDn , filter , ReturnAttributes . ALL_USER . value ( ) , ReturnAttributes . ALL_USER . value ( ) ) ; |
public class DirectoryWatcher { /** * Close the watch service . Releases resources . After calling , this instance becomes invalid and can ' t be used any more . */
public void stopWatching ( ) { } } | try { _watchService . close ( ) ; _watchService = null ; _watchedDirectories = null ; } catch ( IOException e ) { throw new RuntimeException ( "Could not stop watching directories!" , e ) ; } |
public class AbstractJcrNode { /** * Get the property definition ID .
* @ return the cached property definition ID ; never null
* @ throws ItemNotFoundException if the node that contains this property doesn ' t exist anymore
* @ throws ConstraintViolationException if no valid property definition could be found
... | CachedDefinition defn = cachedDefn ; NodeTypes nodeTypes = session ( ) . nodeTypes ( ) ; if ( defn == null || nodeTypes . getVersion ( ) > defn . nodeTypesVersion ) { assert ! this . isRoot ( ) ; // Determine the node type based upon this node ' s type information . . .
CachedNode parent = getParent ( ) . node ( ) ; Se... |
public class Repeater { /** * Assigns property names
* @ param propertyNames
* Names of properties for each iteration
* @ throws IllegalArgumentException
* In case when number of properties names does not correspond
* with number of iterations */
public void assignPropertyNames ( String ... propertyNames ) th... | if ( propertyNames . length != times ) throw new IllegalArgumentException ( "Invalid length of propertyNames in Repeater." ) ; this . names = Arrays . asList ( propertyNames ) ; |
public class RoadNetworkConstants { /** * Set the preferred name for the number of lanes of the roads .
* @ param name is the preferred name for the number of lanes of the roads .
* @ see # DEFAULT _ ATTR _ LANE _ COUNT */
public static void setPreferredAttributeNameForLaneCount ( String name ) { } } | final Preferences prefs = Preferences . userNodeForPackage ( RoadNetworkConstants . class ) ; if ( prefs != null ) { if ( name == null || "" . equals ( name ) || DEFAULT_ATTR_LANE_COUNT . equalsIgnoreCase ( name ) ) { // $ NON - NLS - 1 $
prefs . remove ( "LANE_COUNT_ATTR_NAME" ) ; // $ NON - NLS - 1 $
} else { prefs .... |
public class RegionMap { /** * Getter for the region ' s east bound .
* @ return the region east bound or { @ link HMConstants # doubleNovalue } */
public double getEast ( ) { } } | Double e = get ( EAST ) ; if ( e != null ) { return e ; } return HMConstants . doubleNovalue ; |
public class MsExcelUtils { /** * 保存到本地 , 关闭工作簿 , 并创建一个新的工作簿
* @ param path 路径
* @ throws IOException 异常
* @ throws NoSuchMethodException 异常
* @ throws IllegalAccessException 异常
* @ throws InvocationTargetException 异常 */
public static void writeAndClose ( String path ) throws InvocationTargetException , NoSuc... | writeTo ( path ) ; xssfWorkbook . close ( ) ; createXssfWorkbook ( ) ; |
public class TransformTask { /** * Set the output write mode : default , overwrite , or append .
* @ param mode the output write mode
* @ return this for method chaining */
public TransformTask setWriteMode ( Target . WriteMode mode ) { } } | Preconditions . checkArgument ( mode != Target . WriteMode . CHECKPOINT , "Checkpoint is not an allowed write mode" ) ; this . mode = mode ; return this ; |
public class SingleLockedMessageEnumerationImpl { /** * / * ( non - Javadoc )
* @ see com . ibm . wsspi . sib . core . LockedMessageEnumeration # resetCursor ( ) */
public void resetCursor ( ) throws SISessionUnavailableException , SISessionDroppedException , SIErrorException , SIIncorrectCallException { } } | if ( TraceComponent . isAnyTracingEnabled ( ) && CoreSPILockedMessageEnumeration . tc . isEntryEnabled ( ) ) SibTr . entry ( CoreSPILockedMessageEnumeration . tc , "resetCursor" , this ) ; checkValidState ( "resetCursor" ) ; _localConsumerPoint . checkNotClosed ( ) ; _seenSingleMessage = false ; if ( TraceComponent . i... |
public class JSONObject { /** * Tests if the value should be tried as a decimal . It makes no test if there are actual digits .
* @ param val value to test
* @ return true if the string is " - 0 " or if it contains ' . ' , ' e ' , or ' E ' , false otherwise . */
protected static boolean isDecimalNotation ( final St... | return val . indexOf ( '.' ) > - 1 || val . indexOf ( 'e' ) > - 1 || val . indexOf ( 'E' ) > - 1 || "-0" . equals ( val ) ; |
public class JKTableModel { public void setColumnValue ( final int row , final int col , final Object value , final boolean visibleIndex ) { } } | int actualColumn = col ; if ( visibleIndex ) { actualColumn = getActualColumnIndexFromVisible ( col ) ; } getRecord ( row ) . setColumnValue ( actualColumn , value ) ; fireTableCellUpdated ( row , col ) ; |
public class OjbConfiguration { /** * Loads the configuration from file " OBJ . properties " . If the system
* property " OJB . properties " is set , then the configuration in that file is
* loaded . Otherwise , the file " OJB . properties " is tried . If that is also
* unsuccessful , then the configuration is fi... | // properties file may be set as a System property .
// if no property is set take default name .
String fn = System . getProperty ( OJB_PROPERTIES_FILE , OJB_PROPERTIES_FILE ) ; setFilename ( fn ) ; super . load ( ) ; // default repository & connection descriptor file
repositoryFilename = getString ( "repositoryFile" ... |
public class Sizes { /** * Creates and returns an instance of { @ code ConstantSize } from the given encoded size and unit
* description .
* @ param encodedValueAndUnit value and unit in string representation
* @ param horizontaltrue for horizontal , false for vertical
* @ return a { @ code ConstantSize } for t... | String lowerCase = encodedValueAndUnit . toLowerCase ( Locale . ENGLISH ) ; String trimmed = lowerCase . trim ( ) ; return ConstantSize . valueOf ( trimmed , horizontal ) ; |
public class CmsWebdavServlet { /** * Parse the range header . < p >
* @ param request the servlet request we are processing
* @ param response the servlet response we are creating
* @ param item the WebdavItem with the information
* @ return Vector of ranges */
protected ArrayList < CmsWebdavRange > parseRange... | // Checking If - Range
String headerValue = request . getHeader ( HEADER_IFRANGE ) ; if ( headerValue != null ) { long headerValueTime = ( - 1L ) ; try { headerValueTime = request . getDateHeader ( HEADER_IFRANGE ) ; } catch ( Exception e ) { // noop
} String eTag = getETag ( item ) ; long lastModified = item . getLast... |
public class Ifc2x3tc1PackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public EEnum getIfcEvaporatorTypeEnum ( ) { } } | if ( ifcEvaporatorTypeEnumEEnum == null ) { ifcEvaporatorTypeEnumEEnum = ( EEnum ) EPackage . Registry . INSTANCE . getEPackage ( Ifc2x3tc1Package . eNS_URI ) . getEClassifiers ( ) . get ( 835 ) ; } return ifcEvaporatorTypeEnumEEnum ; |
public class MZXMLMultiSpectraParser { /** * Intended use : find the length of the last scan entry in the file . MzXML might contain
* chromatograms after scans , and the index only contains the offset of the last scan - there is
* no easy way to figure out what the length is . If you just consider , that the lengt... | int length = - 1 ; numOpeningScanTagsFound = 0 ; XMLStreamReaderImpl reader = null ; try { reader = ( readerPool == null ) ? new XMLStreamReaderImpl ( ) : readerPool . borrowObject ( ) ; reader . setInput ( is , StandardCharsets . UTF_8 . name ( ) ) ; LogHelper . setJavolutionLogLevelFatal ( ) ; int eventType = XMLStre... |
public class DynamicOutputBuffer { /** * Tries to copy as much bytes as possible from this buffer to
* the given channel . This method always copies whole internal
* buffers and deallocates them afterwards . It does not deallocate
* the buffer the write position is currently pointing to nor does
* it deallocate... | int n1 = _flushPosition / _bufferSize ; int n2 = _position / _bufferSize ; while ( n1 < n2 ) { ByteBuffer bb = _buffers . get ( n1 ) ; bb . rewind ( ) ; out . write ( bb ) ; deallocateBuffer ( n1 ) ; _flushPosition += _bufferSize ; ++ n1 ; } |
public class LuceneQueryBuilder { public Object visit ( QueryRootNode node , Object data ) throws RepositoryException { } } | BooleanQuery root = new BooleanQuery ( ) ; Query wrapped = root ; if ( node . getLocationNode ( ) != null ) { wrapped = ( Query ) node . getLocationNode ( ) . accept ( this , root ) ; } return wrapped ; |
public class Cursor { /** * Determines whether the input { @ link IoDevice } is compatible with the { @ link Cursor } .
* @ return true if device is compatible , else false */
public boolean isDeviceCompatible ( final IoDevice device ) { } } | List < IoDevice > ioDevices = new LinkedList < IoDevice > ( ) ; for ( PriorityIoDeviceTuple tuple : mCompatibleDevices ) { if ( tuple . getIoDevice ( ) . equals ( device ) ) { return true ; } } return false ; |
public class DBagImpl { /** * This method returns the number of occurrences of the object < code > obj < / code >
* in the < code > DBag < / code > collection .
* @ param obj The value that may have elements in the collection .
* @ return The number of occurrences of < code > obj < / code > in this collection . *... | int count = 0 ; for ( int i = 0 ; i < this . size ( ) ; i ++ ) { if ( ( obj == null ) ? this . get ( i ) == null : this . get ( i ) . equals ( obj ) ) { count ++ ; } } return count ; |
public class CacheFilter { /** * Check whether the URL start with one of the given prefixes .
* @ param uri URI
* @ param patterns possible prefixes
* @ return true when URL starts with one of the prefixes */
public boolean checkPrefixes ( String uri , String [ ] patterns ) { } } | for ( String pattern : patterns ) { if ( pattern . length ( ) > 0 ) { if ( uri . startsWith ( pattern ) ) { return true ; } } } return false ; |
public class CssEscape { /** * Perform a ( configurable ) CSS Identifier < strong > escape < / strong > operation on a < tt > String < / tt > input ,
* writing the results to a < tt > Writer < / tt > .
* This method will perform an escape operation according to the specified
* { @ link CssIdentifierEscapeType } a... | if ( writer == null ) { throw new IllegalArgumentException ( "Argument 'writer' cannot be null" ) ; } if ( type == null ) { throw new IllegalArgumentException ( "The 'type' argument cannot be null" ) ; } if ( level == null ) { throw new IllegalArgumentException ( "The 'level' argument cannot be null" ) ; } CssIdentifie... |
public class ArrayUtil { /** * 映射键值 ( 参考Python的zip ( ) 函数 ) < br >
* 例如 : < br >
* keys = [ a , b , c , d ] < br >
* values = [ 1,2,3,4 ] < br >
* 则得到的Map是 { a = 1 , b = 2 , c = 3 , d = 4 } < br >
* 如果两个数组长度不同 , 则只对应最短部分
* @ param < K > Key类型
* @ param < V > Value类型
* @ param keys 键列表
* @ param values... | if ( isEmpty ( keys ) || isEmpty ( values ) ) { return null ; } final int size = Math . min ( keys . length , values . length ) ; final Map < K , V > map = CollectionUtil . newHashMap ( size , isOrder ) ; for ( int i = 0 ; i < size ; i ++ ) { map . put ( keys [ i ] , values [ i ] ) ; } return map ; |
public class AuthorizationImpl { /** * Answers if the principal has permission to SUBSCRIBE to this Channel .
* @ return boolean
* @ param principal IAuthorizationPrincipal
* @ param portletDefinitionId
* @ exception AuthorizationException indicates authorization information could not be retrieved . */
@ Overri... | String owner = IPermission . PORTAL_SUBSCRIBE ; // retrieve the indicated channel from the channel registry store and
// determine its current lifecycle state
IPortletDefinition portlet = this . portletDefinitionRegistry . getPortletDefinition ( portletDefinitionId ) ; if ( portlet == null ) { return false ; } String t... |
public class ConvertKit { /** * bits转bytes
* @ param bits 二进制
* @ return bytes */
public static byte [ ] bits2Bytes ( String bits ) { } } | int lenMod = bits . length ( ) % 8 ; int byteLen = bits . length ( ) / 8 ; // 不是8的倍数前面补0
if ( lenMod != 0 ) { for ( int i = lenMod ; i < 8 ; i ++ ) { bits = "0" + bits ; } byteLen ++ ; } byte [ ] bytes = new byte [ byteLen ] ; for ( int i = 0 ; i < byteLen ; ++ i ) { for ( int j = 0 ; j < 8 ; ++ j ) { bytes [ i ] <<= 1... |
public class MarketplaceAgreementsInner { /** * Sign marketplace terms .
* @ param publisherId Publisher identifier string of image being deployed .
* @ param offerId Offer identifier string of image being deployed .
* @ param planId Plan identifier string of image being deployed .
* @ param serviceCallback the... | return ServiceFuture . fromResponse ( signWithServiceResponseAsync ( publisherId , offerId , planId ) , serviceCallback ) ; |
public class ClassProject { /** * Add this field in the Record ' s field sequence . */
public BaseField setupField ( int iFieldSeq ) { } } | BaseField field = null ; // if ( iFieldSeq = = 0)
// field = new CounterField ( this , ID , Constants . DEFAULT _ FIELD _ LENGTH , null , null ) ;
// field . setHidden ( true ) ;
// if ( iFieldSeq = = 1)
// field = new RecordChangedField ( this , LAST _ CHANGED , Constants . DEFAULT _ FIELD _ LENGTH , null , null ) ;
/... |
public class JawrBinaryResourceRequestHandler { /** * Process the request
* @ param requestedPath
* the requested path
* @ param request
* the request
* @ param response
* the response
* @ param bundleHashcodeType
* the bundle hashcode type
* @ throws IOException
* if an IOException occurs */
@ Over... | boolean responseHeaderWritten = false ; boolean validBundle = true ; if ( ! jawrConfig . isDebugModeOn ( ) && jawrConfig . isStrictMode ( ) && bundleHashcodeType . equals ( BundleHashcodeType . INVALID_HASHCODE ) ) { validBundle = false ; } // If debug mode is off , check for If - Modified - Since and
// If - none - ma... |
public class ClassLoaderLeakPreventorFactory { /** * Get instance of { @ link PreClassLoaderInitiator } for further configuring */
public < C extends PreClassLoaderInitiator > void removePreInitiator ( Class < C > clazz ) { } } | this . preInitiators . remove ( clazz . getName ( ) ) ; |
public class DBManagerService { /** * stamps , allowing for either property to be null for older definitions . */
private static boolean sameTenantDefs ( TenantDefinition tenantDef1 , TenantDefinition tenantDef2 ) { } } | return isEqual ( tenantDef1 . getProperty ( TenantService . CREATED_ON_PROP ) , tenantDef2 . getProperty ( TenantService . CREATED_ON_PROP ) ) && isEqual ( tenantDef1 . getProperty ( TenantService . CREATED_ON_PROP ) , tenantDef2 . getProperty ( TenantService . CREATED_ON_PROP ) ) ; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.