signature
stringlengths
43
39.1k
implementation
stringlengths
0
450k
public class ColorUtilities { /** * Converts a color string . * @ param rbgString the string in the form " r , g , b , a " as integer values between 0 and 255. * @ return the { @ link Color } . */ public static Color colorFromRbgString ( String rbgString ) { } }
String [ ] split = rbgString . split ( "," ) ; if ( split . length < 3 || split . length > 4 ) { throw new IllegalArgumentException ( "Color string has to be of type r,g,b." ) ; } int r = ( int ) Double . parseDouble ( split [ 0 ] . trim ( ) ) ; int g = ( int ) Double . parseDouble ( split [ 1 ] . trim ( ) ) ; int b = ...
public class TypeHandler { /** * Returns the < code > Object < / code > of type < code > clazz < / code > * with the value of < code > str < / code > . * @ param str the command line value * @ param clazz the type of argument * @ return The instance of < code > clazz < / code > initialised with * the value of...
if ( PatternOptionBuilder . STRING_VALUE == clazz ) { return str ; } else if ( PatternOptionBuilder . OBJECT_VALUE == clazz ) { return createObject ( str ) ; } else if ( PatternOptionBuilder . NUMBER_VALUE == clazz ) { return createNumber ( str ) ; } else if ( PatternOptionBuilder . DATE_VALUE == clazz ) { return creat...
public class SuppressionInfo { /** * Generates the { @ link SuppressionInfo } for a { @ link CompilationUnitTree } . This differs in that * { @ code isGenerated } is determined by inspecting the annotations of the outermost class so that * matchers on { @ link CompilationUnitTree } will also be suppressed . */ publ...
AtomicBoolean generated = new AtomicBoolean ( false ) ; new SimpleTreeVisitor < Void , Void > ( ) { @ Override public Void visitClass ( ClassTree node , Void unused ) { ClassSymbol symbol = ASTHelpers . getSymbol ( node ) ; generated . compareAndSet ( false , symbol != null && isGenerated ( symbol , state ) ) ; return ...
public class PlayUIServer { /** * Auto - attach StatsStorage if an unknown session ID is passed as URL path parameter in multi - session mode * @ param statsStorageProvider function that returns a StatsStorage containing the given session ID */ public void autoAttachStatsStorageBySessionId ( Function < String , Stats...
if ( statsStorageProvider != null ) { this . statsStorageLoader = new StatsStorageLoader ( statsStorageProvider ) ; }
public class BaseProcessRecords { /** * Get this record . */ public Record getThisRecord ( String strRecord , String strPackage , String strDBName ) { } }
String strRecordClass = strRecord ; if ( ! strRecordClass . contains ( "." ) ) strRecordClass = strPackage + '.' + strRecordClass ; Record record = Record . makeRecordFromClassName ( strRecordClass , this , false , true ) ; if ( record == null ) return null ; String strMode = this . getProperty ( ExportRecordsToXmlProc...
public class DateParser { /** * Gets possible component sequences in the given mode * @ param mode the mode * @ param length the length ( only returns sequences of this length ) * @ param dateStyle whether dates are usually entered day first or month first * @ return the list of sequences */ protected static Li...
List < Component [ ] > sequences = new ArrayList < > ( ) ; Component [ ] [ ] dateSequences = dateStyle . equals ( DateStyle . DAY_FIRST ) ? DATE_SEQUENCES_DAY_FIRST : DATE_SEQUENCES_MONTH_FIRST ; if ( mode == Mode . DATE || mode == Mode . AUTO ) { for ( Component [ ] seq : dateSequences ) { if ( seq . length == length ...
public class DefaultAuthorizationStrategy { /** * Remove a defined FoxHttpAuthorization from the AuthorizationStrategy * @ param foxHttpAuthorizationScope scope in which the authorization is used * @ param foxHttpAuthorization object of the same authorization */ @ Override public void removeAuthorization ( FoxHttpA...
ArrayList < FoxHttpAuthorization > authorizations = foxHttpAuthorizations . get ( foxHttpAuthorizationScope . toString ( ) ) ; ArrayList < FoxHttpAuthorization > cleandAuthorizations = new ArrayList < > ( ) ; for ( FoxHttpAuthorization authorization : authorizations ) { if ( authorization . getClass ( ) != foxHttpAutho...
public class WebJarController { /** * A bundle is removed . * @ param bundle the bundle * @ param bundleEvent the event * @ param webJarLibs the webjars that were embedded in the bundle . */ @ Override public void removedBundle ( Bundle bundle , BundleEvent bundleEvent , List < BundleWebJarLib > webJarLibs ) { } ...
removeWebJarLibs ( webJarLibs ) ;
public class MultipartBuilder { /** * Adds an attachment directly by content . * @ param content the content of the attachment * @ param filename the filename of the attachment * @ return this builder */ public MultipartBuilder attachment ( String content , String filename ) { } }
ByteArrayInputStream is = new ByteArrayInputStream ( content . getBytes ( ) ) ; return bodyPart ( new StreamDataBodyPart ( ATTACHMENT_NAME , is , filename ) ) ;
public class NetworkFetcher { /** * Returns null if the animation doesn ' t exist in the cache . */ @ Nullable @ WorkerThread private LottieComposition fetchFromCache ( ) { } }
Pair < FileExtension , InputStream > cacheResult = networkCache . fetch ( ) ; if ( cacheResult == null ) { return null ; } FileExtension extension = cacheResult . first ; InputStream inputStream = cacheResult . second ; LottieResult < LottieComposition > result ; if ( extension == FileExtension . ZIP ) { result = Lotti...
public class WhereUsedPanel { /** * This method is called from within the constructor to initialize the form . * WARNING : Do NOT modify this code . The content of this method is always * regenerated by the Form Editor . */ @ SuppressWarnings ( "unchecked" ) // < editor - fold defaultstate = " collapsed " desc = " ...
labelTextFieldName = new javax . swing . JLabel ( ) ; checkBoxFindInComments = new javax . swing . JCheckBox ( ) ; labelMindMapName = new javax . swing . JLabel ( ) ; panelScope = new org . netbeans . modules . refactoring . spi . ui . ScopePanel ( WhereUsedPanel . class . getCanonicalName ( ) . replace ( '.' , '-' ) ,...
public class ApplicationDescriptorImpl { /** * Adds a new namespace * @ return the current instance of < code > ApplicationDescriptor < / code > */ public ApplicationDescriptor addNamespace ( String name , String value ) { } }
model . attribute ( name , value ) ; return this ;
public class DynamicRepositoryDecoratorRegistryImpl { /** * Decorates a { @ link Repository } if there is a { @ link DecoratorConfiguration } specified for this * repository . */ @ Override public synchronized Repository < Entity > decorate ( Repository < Entity > repository ) { } }
String entityTypeId = repository . getEntityType ( ) . getId ( ) ; if ( ! entityTypeId . equals ( DECORATOR_CONFIGURATION ) && bootstrappingDone ) { DecoratorConfiguration config = dataService . query ( DECORATOR_CONFIGURATION , DecoratorConfiguration . class ) . eq ( ENTITY_TYPE_ID , entityTypeId ) . findOne ( ) ; if ...
public class ASTUtils { /** * Return null if specified name annotation is not found . */ public static IAnnotationBinding getAnnotationBinding ( IAnnotationBinding [ ] annotations , String annotationClassName ) { } }
if ( annotations == null ) { return null ; } if ( annotationClassName == null ) { throw new NullPointerException ( ) ; } for ( IAnnotationBinding annotation : annotations ) { String qName = annotation . getAnnotationType ( ) . getBinaryName ( ) ; assert qName != null ; // TODO if multiple annotations for annotationClas...
public class DataSiftAccount { /** * List tokens associated with an identity * @ param identity which identity you want to list the tokens of * @ param page page number ( can be 0) * @ param perPage items per page ( can be 0) * @ return List of identities */ public FutureData < TokenList > listTokens ( String i...
if ( identity == null ) { throw new IllegalArgumentException ( "An identity is required" ) ; } FutureData < TokenList > future = new FutureData < > ( ) ; ParamBuilder b = newParams ( ) ; if ( page > 0 ) { b . put ( "page" , page ) ; } if ( perPage > 0 ) { b . put ( "per_page" , perPage ) ; } URI uri = b . forURL ( conf...
public class WordTree { /** * 找出所有匹配的关键字 * @ param text 被检查的文本 * @ param limit 限制匹配个数 * @ return 匹配的词列表 */ public List < String > matchAll ( String text , int limit ) { } }
return matchAll ( text , limit , false , false ) ;
public class Ec2MachineConfigurator { /** * Looks up volume , by ID or Name tag . * @ param volumeIdOrName the EBS volume ID or Name tag * @ return The volume ID of 1st matching volume found , null if no volume found */ private String lookupVolume ( String volumeIdOrName ) { } }
String ret = null ; if ( ! Utils . isEmptyOrWhitespaces ( volumeIdOrName ) ) { // Lookup by volume ID DescribeVolumesRequest dvs = new DescribeVolumesRequest ( Collections . singletonList ( volumeIdOrName ) ) ; DescribeVolumesResult dvsresult = null ; try { dvsresult = this . ec2Api . describeVolumes ( dvs ) ; } catch ...
public class GeoPackageIOUtils { /** * Get the file name with the extension removed * @ param file * file * @ return file name */ public static String getFileNameWithoutExtension ( File file ) { } }
String name = file . getName ( ) ; int extensionIndex = name . lastIndexOf ( "." ) ; if ( extensionIndex > - 1 ) { name = name . substring ( 0 , extensionIndex ) ; } return name ;
public class OBDImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ @ Override public void eUnset ( int featureID ) { } }
switch ( featureID ) { case AfplibPackage . OBD__TRIPLETS : getTriplets ( ) . clear ( ) ; return ; } super . eUnset ( featureID ) ;
public class CompressedFile { /** * Reads the contents of a file . */ public InputStream read ( ) throws IOException { } }
if ( file . exists ( ) ) try { return Files . newInputStream ( file . toPath ( ) ) ; } catch ( InvalidPathException e ) { throw new IOException ( e ) ; } // check if the compressed file exists if ( gz . exists ( ) ) try { return new GZIPInputStream ( Files . newInputStream ( gz . toPath ( ) ) ) ; } catch ( InvalidPathE...
public class ZooKeeperMain { /** * this method deletes quota for a node . * @ param zk * the zookeeper client * @ param path * the path to delete quota for * @ param bytes * true if number of bytes needs to be unset * @ param numNodes * true if number of nodes needs to be unset * @ return true if quot...
String parentPath = Quotas . quotaZookeeper + path ; String quotaPath = Quotas . quotaZookeeper + path + "/" + Quotas . limitNode ; if ( zk . exists ( quotaPath , false ) == null ) { System . out . println ( "Quota does not exist for " + path ) ; return true ; } byte [ ] data = null ; try { data = zk . getData ( quotaP...
public class DocTreeScanner { /** * { @ inheritDoc } This implementation scans the children in left to right order . * @ param node { @ inheritDoc } * @ param p { @ inheritDoc } * @ return the result of scanning */ @ Override public R visitSerialData ( SerialDataTree node , P p ) { } }
return scan ( node . getDescription ( ) , p ) ;
public class DetectDescribeAssociate { /** * Adds a new track given its location and description */ protected PointTrack addNewTrack ( int setIndex , double x , double y , Desc desc ) { } }
PointTrack p = getUnused ( ) ; p . set ( x , y ) ; ( ( Desc ) p . getDescription ( ) ) . setTo ( desc ) ; if ( checkValidSpawn ( setIndex , p ) ) { p . setId = setIndex ; p . featureId = featureID ++ ; sets [ setIndex ] . tracks . add ( p ) ; tracksNew . add ( p ) ; tracksActive . add ( p ) ; tracksAll . add ( p ) ; re...
public class JcrTools { /** * Upload the content at the supplied URL into the repository at the defined path , using the given session . This method will * create a ' nt : file ' node at the supplied path , and any non - existant ancestors with nodes of type ' nt : folder ' . As defined by * the JCR specification ,...
isNotNull ( session , "session" ) ; isNotNull ( path , "path" ) ; isNotNull ( contentUrl , "contentUrl" ) ; // Open the URL ' s stream first . . . InputStream stream = contentUrl . openStream ( ) ; return uploadFile ( session , path , stream ) ;
public class EpollSocketChannelConfig { /** * Set the { @ code TCP _ NOTSENT _ LOWAT } option on the socket . See { @ code man 7 tcp } for more details . * @ param tcpNotSentLowAt is a uint32 _ t */ public EpollSocketChannelConfig setTcpNotSentLowAt ( long tcpNotSentLowAt ) { } }
try { ( ( EpollSocketChannel ) channel ) . socket . setTcpNotSentLowAt ( tcpNotSentLowAt ) ; return this ; } catch ( IOException e ) { throw new ChannelException ( e ) ; }
public class ServiceDirectoryImpl { /** * { @ inheritDoc } */ @ Override public DirectoryServiceClient getDirectoryServiceClient ( ) { } }
if ( client == null ) { synchronized ( this ) { if ( isShutdown ) { ServiceDirectoryError error = new ServiceDirectoryError ( ErrorCode . SERVICE_DIRECTORY_IS_SHUTDOWN ) ; throw new ServiceException ( error ) ; } if ( client == null ) { try { String host = ServiceDirectory . getServiceDirectoryConfig ( ) . getString ( ...
public class TransferManager { /** * Schedules a new transfer to download data from Amazon S3 using presigned url * and save it to the specified file . This method is non - blocking and returns immediately * ( i . e . before the data has been fully downloaded ) . * Use the returned { @ link PresignedUrlDownload }...
assertParameterNotNull ( request , "A valid PresignedUrlDownloadRequest must be provided to initiate download" ) ; assertParameterNotNull ( destFile , "A valid file must be provided to download into" ) ; assertParameterNotNull ( downloadContext , "A valid PresignedUrlDownloadContext must be provided" ) ; appendSingleOb...
public class Datatype_Builder { /** * Sets the value to be returned by { @ link Datatype # getBuilderFactory ( ) } . * @ return this { @ code Builder } object */ public Datatype . Builder setBuilderFactory ( Optional < ? extends BuilderFactory > builderFactory ) { } }
if ( builderFactory . isPresent ( ) ) { return setBuilderFactory ( builderFactory . get ( ) ) ; } else { return clearBuilderFactory ( ) ; }
public class VpnTunnelClient { /** * Retrieves an aggregated list of VPN tunnels . * < p > Sample code : * < pre > < code > * try ( VpnTunnelClient vpnTunnelClient = VpnTunnelClient . create ( ) ) { * ProjectName project = ProjectName . of ( " [ PROJECT ] " ) ; * for ( VpnTunnelsScopedList element : vpnTunnel...
AggregatedListVpnTunnelsHttpRequest request = AggregatedListVpnTunnelsHttpRequest . newBuilder ( ) . setProject ( project == null ? null : project . toString ( ) ) . build ( ) ; return aggregatedListVpnTunnels ( request ) ;
public class ModifyWorkspaceStateRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( ModifyWorkspaceStateRequest modifyWorkspaceStateRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( modifyWorkspaceStateRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( modifyWorkspaceStateRequest . getWorkspaceId ( ) , WORKSPACEID_BINDING ) ; protocolMarshaller . marshall ( modifyWorkspaceStateRequest . getWorkspaceState ( ...
public class XMLRoadUtil { /** * Read the roads from the XML description . * @ param xmlNode is the XML node to fill with the container data . * @ param primitive is the container of roads to read . * @ param pathBuilder is the tool to make paths relative . * @ param resources is the tool that permits to gather...
final ContainerWrapper w = new ContainerWrapper ( primitive ) ; readGISElementContainer ( xmlNode , w , NODE_ROAD , pathBuilder , resources ) ; URL u ; // Force the primitive to have the pointer to the Shape and dBase files u = w . getElementGeometrySourceURL ( ) ; if ( u != null ) { primitive . setAttribute ( MapEleme...
public class TimeCategory { /** * Subtract one date from the other . * @ param lhs a Date * @ param rhs another Date * @ return a Duration */ public static TimeDuration minus ( final Date lhs , final Date rhs ) { } }
long milliseconds = lhs . getTime ( ) - rhs . getTime ( ) ; long days = milliseconds / ( 24 * 60 * 60 * 1000 ) ; milliseconds -= days * 24 * 60 * 60 * 1000 ; int hours = ( int ) ( milliseconds / ( 60 * 60 * 1000 ) ) ; milliseconds -= hours * 60 * 60 * 1000 ; int minutes = ( int ) ( milliseconds / ( 60 * 1000 ) ) ; mill...
public class HomeHandleImpl { /** * Return < code > EJBHome < / code > reference for this HomeHandle . < p > */ public EJBHome getEJBHome ( ) throws RemoteException { } }
// When ivActualVersion is Constant . HOME _ HANDLE _ V1 , ivEjbHome may // be null . So if this happens , we need to find the EJBHome object // by doing a lookup in JNDI . For all other versions , ivEjbHome // should never be null . if ( ivEjbHome == null ) { try { Class homeClass = null ; try { // If we are running o...
public class MultiViewOps { /** * Extract the fundamental matrices between views 1 + 2 and views 1 + 3 . The returned Fundamental * matrices will have the following properties : x < sub > i < / sub > < sup > T < / sup > * Fi * x < sub > 1 < / sub > = 0 , where i is view 2 or 3. * NOTE : The first camera is assumed ...
TrifocalExtractGeometries e = new TrifocalExtractGeometries ( ) ; e . setTensor ( tensor ) ; e . extractFundmental ( F21 , F31 ) ;
public class PatternBox { /** * Pattern for two different EntityReference have member PhysicalEntity in the same Complex , and * the Complex has transcriptional activity . Complex membership can be through multiple nesting * and / or through homology relations . * @ return the pattern */ public static Pattern inS...
Pattern p = inSameComplex ( ) ; p . add ( peToControl ( ) , "Complex" , "Control" ) ; p . add ( controlToTempReac ( ) , "Control" , "TR" ) ; p . add ( new NOT ( participantER ( ) ) , "TR" , "first ER" ) ; p . add ( new NOT ( participantER ( ) ) , "TR" , "second ER" ) ; return p ;
public class Boxing { /** * Transforms any array into a primitive array . * @ param type target type * @ param src source array * @ param srcPos start position * @ param len length * @ return primitive array */ public static Object unboxAll ( Class < ? > type , Object src , int srcPos , int len ) { } }
switch ( tId ( type ) ) { case I_BOOLEAN : return unboxBooleans ( src , srcPos , len ) ; case I_BYTE : return unboxBytes ( src , srcPos , len ) ; case I_CHARACTER : return unboxCharacters ( src , srcPos , len ) ; case I_DOUBLE : return unboxDoubles ( src , srcPos , len ) ; case I_FLOAT : return unboxFloats ( src , srcP...
public class GitlabAPI { /** * use project id to get Project JSON */ public String getProjectJson ( Serializable projectId ) throws IOException { } }
String tailUrl = GitlabProject . URL + "/" + sanitizeProjectId ( projectId ) ; return retrieve ( ) . to ( tailUrl , String . class ) ;
public class Engine { /** * Gets the rule block of the given name after iterating the rule blocks . The * cost of this method is O ( n ) , where n is the number of rule blocks in the * engine . For performance , please get the rule blocks by index . * @ param name is the name of the rule block * @ return rule b...
for ( RuleBlock ruleBlock : this . ruleBlocks ) { if ( ruleBlock . getName ( ) . equals ( name ) ) { return ruleBlock ; } } throw new RuntimeException ( String . format ( "[engine error] no rule block by name <%s>" , name ) ) ;
public class RSQLUtility { /** * parses an RSQL valid string into an JPA { @ link Specification } which then * can be used to filter for JPA entities with the given RSQL query . * @ param rsql * the rsql query * @ param fieldNameProvider * the enum class type which implements the * { @ link FieldNameProvide...
return new RSQLSpecification < > ( rsql . toLowerCase ( ) , fieldNameProvider , virtualPropertyReplacer , database ) ;
public class AbstractAppender { /** * Move provided context to current appender and call { @ link # doAppend ( StringBuilder , Map , Tree , Parser ) } if no recursion has been detected . * @ param buffer * @ param configuration * @ param context */ public final void append ( StringBuilder buffer , Map < String , ...
// Create context if needed Tree < Appender > currentContext = context == null ? new Tree < Appender > ( this ) : context . addLeaf ( this ) ; // Check recursion if ( currentContext . inAncestors ( this ) ) { // For the moment just log a warning , and stop the resolving by appending original chunk buffer . append ( chu...
public class ApiOvhDbaastimeseries { /** * Create a key for a project * REST : POST / dbaas / timeseries / { serviceName } / key * @ param serviceName [ required ] Service Name * @ param description [ required ] Description * @ param permissions [ required ] Permissions for this token * @ param tags [ require...
String qPath = "/dbaas/timeseries/{serviceName}/key" ; StringBuilder sb = path ( qPath , serviceName ) ; HashMap < String , Object > o = new HashMap < String , Object > ( ) ; addBody ( o , "description" , description ) ; addBody ( o , "permissions" , permissions ) ; addBody ( o , "tags" , tags ) ; String resp = exec ( ...
public class AnnotationExpander { /** * 複数のアノテーションを展開する 。 * @ param targetAnnos 展開対象のアノテーション * @ return 展開されたアノテーション * @ throws NullPointerException { @ literal targetAnnos = = null . } */ public List < ExpandedAnnotation > expand ( final Annotation [ ] targetAnnos ) { } }
Objects . requireNonNull ( targetAnnos ) ; final List < ExpandedAnnotation > expanedList = new ArrayList < > ( ) ; for ( Annotation targetAnno : targetAnnos ) { expanedList . addAll ( expand ( targetAnno ) ) ; } Collections . sort ( expanedList , comparator ) ; return expanedList ;
public class KeyVaultClientBaseImpl { /** * Gets the specified deleted sas definition . * The Get Deleted SAS Definition operation returns the specified deleted SAS definition along with its attributes . This operation requires the storage / getsas permission . * @ param vaultBaseUrl The vault name , for example ht...
return getDeletedSasDefinitionWithServiceResponseAsync ( vaultBaseUrl , storageAccountName , sasDefinitionName ) . map ( new Func1 < ServiceResponse < DeletedSasDefinitionBundle > , DeletedSasDefinitionBundle > ( ) { @ Override public DeletedSasDefinitionBundle call ( ServiceResponse < DeletedSasDefinitionBundle > resp...
public class EntityFunctionResolver { /** * Resolves an { @ link Entity } type to a new resolved { @ link EntityFunction } . * @ param type * Type to resolve . * @ return New ( or cached ) resolved mapped type . */ @ SuppressWarnings ( "unchecked" ) public EntityFunction resolveType ( final Class < ? extends Enti...
// Check already resolved EntityFunction resolvedType = resolved . get ( Objects . requireNonNull ( type ) ) ; if ( resolvedType != null ) { return resolvedType ; } // Log type logger . info ( String . format ( "Resolving type %s" , type ) ) ; // Check not entity if ( Entity . class . equals ( type ) ) { throw new Ille...
public class ColumnDescriptorAdapter { /** * Parse a Bigtable { @ link GcRule } that is in line with * { @ link # buildGarbageCollectionRule ( HColumnDescriptor ) } into the provided * { @ link HColumnDescriptor } . * This method will likely throw IllegalStateException or IllegalArgumentException if the GC Rule ...
// The Bigtable default is to have infinite versions . columnDescriptor . setMaxVersions ( Integer . MAX_VALUE ) ; if ( gcRule == null || gcRule . equals ( GcRule . getDefaultInstance ( ) ) ) { return ; } switch ( gcRule . getRuleCase ( ) ) { case MAX_AGE : columnDescriptor . setTimeToLive ( ( int ) gcRule . getMaxAge ...
public class CurrentMetricDataMarshaller { /** * Marshall the given parameter object . */ public void marshall ( CurrentMetricData currentMetricData , ProtocolMarshaller protocolMarshaller ) { } }
if ( currentMetricData == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( currentMetricData . getMetric ( ) , METRIC_BINDING ) ; protocolMarshaller . marshall ( currentMetricData . getValue ( ) , VALUE_BINDING ) ; } catch ( Exception e ) { t...
public class AbstractSarlMojo { /** * Execute another MOJO . * @ param groupId identifier of the MOJO plugin group . * @ param artifactId identifier of the MOJO plugin artifact . * @ param version version of the MOJO plugin version . * @ param goal the goal to run . * @ param configuration the XML code for th...
final Plugin plugin = new Plugin ( ) ; plugin . setArtifactId ( artifactId ) ; plugin . setGroupId ( groupId ) ; plugin . setVersion ( version ) ; plugin . setDependencies ( Arrays . asList ( dependencies ) ) ; getLog ( ) . debug ( MessageFormat . format ( Messages . AbstractSarlMojo_0 , plugin . getId ( ) ) ) ; final ...
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } { @ link VerticalDatumTypeType } { @ code > } * @ param value * Java instance representing xml element ' s value . * @ return * the new instance of { @ link JAXBElement } { @ code < } { @ link VerticalDatumTypeType } { ...
return new JAXBElement < VerticalDatumTypeType > ( _VerticalDatumType_QNAME , VerticalDatumTypeType . class , null , value ) ;
public class ServiceManagerAmpWrapper { /** * @ Override * public < T > T run ( ResultFuture < T > future , * long timeout , * TimeUnit unit , * Runnable task ) * return getDelegate ( ) . run ( future , timeout , unit , task ) ; */ @ Override public < T > T run ( long timeout , TimeUnit unit , Consumer < Resu...
return delegate ( ) . run ( timeout , unit , task ) ;
public class ListTagOptionsResult { /** * Information about the TagOptions . * < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use * { @ link # setTagOptionDetails ( java . util . Collection ) } or { @ link # withTagOptionDetails ( java . util . Collection ) } if you * want t...
if ( this . tagOptionDetails == null ) { setTagOptionDetails ( new java . util . ArrayList < TagOptionDetail > ( tagOptionDetails . length ) ) ; } for ( TagOptionDetail ele : tagOptionDetails ) { this . tagOptionDetails . add ( ele ) ; } return this ;
public class URLHelper { /** * Get the passed URI as an URL . If the URI is null or cannot be converted to * an URL < code > null < / code > is returned . * @ param aURI * Source URI . May be < code > null < / code > . * @ return < code > null < / code > if the passed URI is null or cannot be converted * to a...
if ( aURI != null ) try { return aURI . toURL ( ) ; } catch ( final MalformedURLException ex ) { // fall - through if ( GlobalDebug . isDebugMode ( ) ) if ( LOGGER . isWarnEnabled ( ) ) LOGGER . warn ( "Debug warn: failed to convert '" + aURI + "' to a URL!" ) ; } return null ;
public class ScriptExecUtil { /** * Generate argument array for a script file invocation * @ param filepath remote filepath for the script * @ param scriptargs arguments to the script file * @ param scriptargsarr arguments to the script file as an array * @ param scriptinterpreter interpreter invocation for the...
ExecArgList . Builder builder = ExecArgList . builder ( ) ; boolean seenFilepath = false ; if ( null != scriptinterpreter ) { String [ ] burst = OptsUtil . burst ( scriptinterpreter ) ; List < String > args = new ArrayList < String > ( ) ; for ( String arg : burst ) { if ( arg . contains ( "${scriptfile}" ) ) { args . ...
public class Strings { /** * Trim white spaces around given string . White space characters are those recognized by * { @ link java . lang . Character # isWhitespace ( char ) } . * @ param string string value to trim . * @ return string with white spaces trimmed or null if given string was null . */ public static...
if ( string == null ) { return null ; } int length = string . length ( ) ; int beginIndex = 0 ; for ( ; beginIndex < length ; ++ beginIndex ) { if ( ! Character . isWhitespace ( string . charAt ( beginIndex ) ) ) break ; } int endIndex = length - 1 ; for ( ; endIndex >= 0 ; -- endIndex ) { if ( ! Character . isWhitespa...
public class SecretsManager { /** * Store a single Fernet key in a secret . This requires the permission < code > secretsmanager : PutSecretValue < / code > * @ param secretId * the ARN of the secret * @ param clientRequestToken * the secret version identifier * @ param key * the key to store in the secret ...
putSecretValue ( secretId , clientRequestToken , singletonList ( key ) , stage ) ;
public class ReschedulingRunnable { /** * Schedule . * @ return the scheduled future */ public ScheduledFuture < ? > schedule ( ) { } }
synchronized ( this . triggerContextMonitor ) { this . scheduledExecutionTime = this . trigger . nextExecutionTime ( this . triggerContext ) ; if ( this . scheduledExecutionTime == null ) { return null ; } long initialDelay = this . scheduledExecutionTime . getTime ( ) - System . currentTimeMillis ( ) ; this . currentF...
public class RuleBasedTokenizer { /** * Set as value of the token its normalized counterpart . Normalization is done * following languages and corpora ( Penn TreeBank , Ancora , Tiger , Tutpenn , * etc . ) conventions . * @ param tokens * the tokens * @ param lang * the language */ public static void normal...
for ( final List < Token > sentence : tokens ) { Normalizer . convertNonCanonicalStrings ( sentence , lang ) ; Normalizer . normalizeQuotes ( sentence , lang ) ; Normalizer . normalizeDoubleQuotes ( sentence , lang ) ; }
public class RendererBuilder { /** * Throws one RendererException if the viewType , layoutInflater or parent are null . */ private void validateAttributesToCreateANewRendererViewHolder ( ) { } }
if ( viewType == null ) { throw new NullContentException ( "RendererBuilder needs a view type to create a RendererViewHolder" ) ; } if ( layoutInflater == null ) { throw new NullLayoutInflaterException ( "RendererBuilder needs a LayoutInflater to create a RendererViewHolder" ) ; } if ( parent == null ) { throw new Null...
public class SelectorGeneratorBase { /** * used by benchmark harness */ private void genGetAllMethod ( SourceWriter sw , JMethod [ ] methods , TreeLogger treeLogger ) { } }
sw . println ( "public DeferredSelector[] getAllSelectors() {return ds;}" ) ; sw . println ( "private final DeferredSelector[] ds = new DeferredSelector[] {" ) ; sw . indent ( ) ; for ( JMethod m : methods ) { Selector selectorAnnotation = m . getAnnotation ( Selector . class ) ; if ( selectorAnnotation == null ) { con...
public class XDOMBuilder { /** * Add a block to the current block container . * @ param block the block to be added . */ public void addBlock ( Block block ) { } }
try { this . stack . getFirst ( ) . add ( block ) ; } catch ( NoSuchElementException e ) { throw new IllegalStateException ( "All container blocks are closed, too many calls to endBlockList()." ) ; }
public class RoadNetworkLayer { @ Override @ Pure public String getName ( ) { } }
String name = this . roadNetwork . getName ( ) ; if ( name != null && ! "" . equals ( name ) ) { // $ NON - NLS - 1 $ return name ; } name = super . getName ( ) ; if ( name != null && ! "" . equals ( name ) ) { // $ NON - NLS - 1 $ return name ; } return Locale . getString ( "NAME_TEMPLATE" ) ; // $ NON - NLS - 1 $
public class Contract { /** * syntactic sugar */ public SignatoryComponent addSigner ( ) { } }
SignatoryComponent t = new SignatoryComponent ( ) ; if ( this . signer == null ) this . signer = new ArrayList < SignatoryComponent > ( ) ; this . signer . add ( t ) ; return t ;
public class DifferenceMarshaller { /** * Marshall the given parameter object . */ public void marshall ( Difference difference , ProtocolMarshaller protocolMarshaller ) { } }
if ( difference == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( difference . getBeforeBlob ( ) , BEFOREBLOB_BINDING ) ; protocolMarshaller . marshall ( difference . getAfterBlob ( ) , AFTERBLOB_BINDING ) ; protocolMarshaller . marshall ( ...
public class INChIReader { /** * Reads a ChemFile object from input . * @ return ChemFile with the content read from the input */ private IChemFile readChemFile ( IChemObjectBuilder bldr ) { } }
IChemFile cf = null ; try { parser . setFeature ( "http://xml.org/sax/features/validation" , false ) ; logger . info ( "Deactivated validation" ) ; } catch ( SAXException e ) { logger . warn ( "Cannot deactivate validation." ) ; } INChIHandler handler = new INChIHandler ( bldr ) ; parser . setContentHandler ( handler )...
public class CalendarFormatterBase { /** * Format a time zone using a non - location format . */ void formatTimeZone_z ( StringBuilder b , ZonedDateTime d , int width ) { } }
if ( width > 4 ) { return ; } ZoneId zone = d . getZone ( ) ; ZoneRules zoneRules = null ; try { zoneRules = zone . getRules ( ) ; } catch ( ZoneRulesException e ) { // not expected , but catching for safety return ; } boolean daylight = zoneRules . isDaylightSavings ( d . toInstant ( ) ) ; // Select long or short name...
public class FoxHttpRequestBuilder { /** * Add a FoxHttpPlaceholderEntry to the FoxHttpPlaceholderStrategy * @ param placeholder name of the placeholder ( without escape char ) * @ param value value of the placeholder * @ return FoxHttpClientBuilder ( this ) */ public FoxHttpRequestBuilder addFoxHttpPlaceholderEn...
foxHttpRequest . getFoxHttpClient ( ) . getFoxHttpPlaceholderStrategy ( ) . addPlaceholder ( placeholder , value ) ; return this ;
public class RDFDataset { /** * Adds a triple to the specified graph of this dataset * @ param s * the subject for the triple * @ param p * the predicate for the triple * @ param value * the value of the literal object for the triple * @ param datatype * the datatype of the literal object for the triple...
if ( graph == null ) { graph = "@default" ; } if ( ! containsKey ( graph ) ) { put ( graph , new ArrayList < Quad > ( ) ) ; } ( ( ArrayList < Quad > ) get ( graph ) ) . add ( new Quad ( s , p , value , datatype , language , graph ) ) ;
public class AbstractResources { /** * Create an HttpRequest . * Exceptions : Any exception shall be propagated since it ' s a private method . * @ param uri the URI * @ param method the HttpMethod * @ return the http request * @ throws UnsupportedEncodingException the unsupported encoding exception */ protec...
HttpRequest request = new HttpRequest ( ) ; request . setUri ( uri ) ; request . setMethod ( method ) ; // Set authorization header request . setHeaders ( createHeaders ( ) ) ; return request ;
public class AESHelper { /** * Decrypts a string encrypted by { @ link # encrypt } method . * @ param c The encrypted HEX string . * @ param key The key . * @ return The decrypted string . */ public static String decrypt ( String c , String key ) { } }
try { SecretKeySpec skeySpec = new SecretKeySpec ( Hex . decodeHex ( key . toCharArray ( ) ) , "AES" ) ; Cipher cipher = Cipher . getInstance ( "AES" ) ; cipher . init ( Cipher . DECRYPT_MODE , skeySpec ) ; byte [ ] decoded = cipher . doFinal ( Hex . decodeHex ( c . toCharArray ( ) ) ) ; return new String ( decoded ) ;...
public class Validators { /** * Method will return a validator that will accept a blank string . Any other value will be passed on to the supplied validator . * @ param validator Validator to test non blank values with . * @ return validator that will accept a blank string . Any other value will be passed on to the...
Preconditions . checkNotNull ( validator , "validator cannot be null." ) ; return BlankOrValidator . of ( validator ) ;
public class InnerClasses { /** * Register the given name as an inner class with the given access modifiers . * @ return A { @ link TypeInfo } with the full class name */ public TypeInfo registerInnerClass ( String simpleName , int accessModifiers ) { } }
classNames . claimName ( simpleName ) ; TypeInfo innerClass = outer . innerClass ( simpleName ) ; innerClassesAccessModifiers . put ( innerClass , accessModifiers ) ; return innerClass ;
public class ElemForEach { /** * This after the template ' s children have been composed . */ public void endCompose ( StylesheetRoot sroot ) throws TransformerException { } }
int length = getSortElemCount ( ) ; for ( int i = 0 ; i < length ; i ++ ) { getSortElem ( i ) . endCompose ( sroot ) ; } super . endCompose ( sroot ) ;
public class CellsUtils { /** * Returns a Collection of SparkSQL Row objects from a collection of Stratio Cells * objects * @ param cellsCol Collection of Cells for transforming * @ return Collection of SparkSQL Row created from Cells . */ public static Collection < Row > getRowsFromsCells ( Collection < Cells > ...
Collection < Row > result = new ArrayList < > ( ) ; for ( Cells cells : cellsCol ) { result . add ( getRowFromCells ( cells ) ) ; } return result ;
public class Table { /** * / * Add a new heading Cell in the current row . * Adds to the table after this call and before next call to newRow , * newCell or newHeader are added to the cell . * @ return This table for call chaining */ public Table addHeading ( Object o , String attributes ) { } }
addHeading ( o ) ; cell . attribute ( attributes ) ; return this ;
public class Navigator { /** * Prepare the instance subject to being injected for the fragment being navigated to . It ' s an * equivalent way to pass arguments to the next fragment . For example , when next fragment needs * to have a pre set page title name , the controller referenced by the fragment can be prepar...
T instance ; try { instance = Mvc . graph ( ) . reference ( type , qualifier ) ; } catch ( PokeException e ) { throw new MvcGraphException ( e . getMessage ( ) , e ) ; } if ( preparer != null ) { preparer . prepare ( instance ) ; } if ( pendingReleaseInstances == null ) { pendingReleaseInstances = new ArrayList < > ( )...
public class VisitorState { /** * Gets the current source file . * @ return the source file as a sequence of characters , or null if it is not available */ @ Nullable public CharSequence getSourceCode ( ) { } }
try { return getPath ( ) . getCompilationUnit ( ) . getSourceFile ( ) . getCharContent ( false ) ; } catch ( IOException e ) { return null ; }
public class HtmlTree { /** * Generates a META tag with the http - equiv , content and charset attributes . * @ param httpEquiv http equiv attribute for the META tag * @ param content type of content * @ param charSet character set used * @ return an HtmlTree object for the META tag */ public static HtmlTree ME...
HtmlTree htmltree = new HtmlTree ( HtmlTag . META ) ; String contentCharset = content + "; charset=" + charSet ; htmltree . addAttr ( HtmlAttr . HTTP_EQUIV , nullCheck ( httpEquiv ) ) ; htmltree . addAttr ( HtmlAttr . CONTENT , contentCharset ) ; return htmltree ;
public class ActionImpl { /** * < ! - - begin - user - doc - - > * < ! - - end - user - doc - - > * @ generated */ @ Override public Object eGet ( int featureID , boolean resolve , boolean coreType ) { } }
switch ( featureID ) { case XtextPackage . ACTION__TYPE : return getType ( ) ; case XtextPackage . ACTION__FEATURE : return getFeature ( ) ; case XtextPackage . ACTION__OPERATOR : return getOperator ( ) ; } return super . eGet ( featureID , resolve , coreType ) ;
public class CmsUpdateBean { /** * Creates the shared folder if possible . < p > * @ throws Exception if something goes wrong */ public void createSharedFolder ( ) throws Exception { } }
String originalSiteRoot = m_cms . getRequestContext ( ) . getSiteRoot ( ) ; CmsProject originalProject = m_cms . getRequestContext ( ) . getCurrentProject ( ) ; try { m_cms . getRequestContext ( ) . setSiteRoot ( "" ) ; m_cms . getRequestContext ( ) . setCurrentProject ( m_cms . createTempfileProject ( ) ) ; if ( ! m_c...
public class ImportApi { /** * Import users . * Import users in the specified CSV / XLS file . * @ param csvfile The CSV / XLS file to import . ( optional ) * @ param validateBeforeImport Specifies whether the Provisioning API should validate the file before the actual import takes place . ( optional , default to...
ApiResponse < ApiSuccessResponse > resp = importFileWithHttpInfo ( csvfile , validateBeforeImport ) ; return resp . getData ( ) ;
public class PageContext { /** * Provides convenient access to error information . * @ return an ErrorData instance containing information about the * error , as obtained from the request attributes , as per the * Servlet specification . If this is not an error page ( that is , * if the isErrorPage attribute of...
return new ErrorData ( ( Throwable ) getRequest ( ) . getAttribute ( "javax.servlet.error.exception" ) , ( ( Integer ) getRequest ( ) . getAttribute ( "javax.servlet.error.status_code" ) ) . intValue ( ) , ( String ) getRequest ( ) . getAttribute ( "javax.servlet.error.request_uri" ) , ( String ) getRequest ( ) . getAt...
public class LFltFunctionBuilder { /** * One of ways of creating builder . This is possibly the least verbose way where compiler should be able to guess the generic parameters . */ @ Nonnull public static < R > LFltFunction < R > fltFunctionFrom ( Consumer < LFltFunctionBuilder < R > > buildingFunction ) { } }
LFltFunctionBuilder builder = new LFltFunctionBuilder ( ) ; buildingFunction . accept ( builder ) ; return builder . build ( ) ;
public class Cpe { /** * Converts the CPE into the CPE 2.2 URI format . * @ return the CPE 2.2 URI format of the CPE * @ throws CpeEncodingException thrown if the CPE is not well formed */ @ Override public String toCpe22Uri ( ) throws CpeEncodingException { } }
StringBuilder sb = new StringBuilder ( "cpe:/" ) ; sb . append ( Convert . wellFormedToCpeUri ( part ) ) . append ( ":" ) ; sb . append ( Convert . wellFormedToCpeUri ( vendor ) ) . append ( ":" ) ; sb . append ( Convert . wellFormedToCpeUri ( product ) ) . append ( ":" ) ; sb . append ( Convert . wellFormedToCpeUri ( ...
public class RegistryService { /** * Push a set of images to a registry * @ param imageConfigs images to push ( but only if they have a build configuration ) * @ param retries how often to retry * @ param registryConfig a global registry configuration * @ param skipTag flag to skip pushing tagged images * @ t...
for ( ImageConfiguration imageConfig : imageConfigs ) { BuildImageConfiguration buildConfig = imageConfig . getBuildConfiguration ( ) ; String name = imageConfig . getName ( ) ; if ( buildConfig != null ) { String configuredRegistry = EnvUtil . firstRegistryOf ( new ImageName ( imageConfig . getName ( ) ) . getRegistry...
public class BatchStopJobRunRequest { /** * A list of the JobRunIds that should be stopped for that job definition . * < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use * { @ link # setJobRunIds ( java . util . Collection ) } or { @ link # withJobRunIds ( java . util . Collec...
if ( this . jobRunIds == null ) { setJobRunIds ( new java . util . ArrayList < String > ( jobRunIds . length ) ) ; } for ( String ele : jobRunIds ) { this . jobRunIds . add ( ele ) ; } return this ;
public class Socks5LogicHandler { /** * Encodes the proxy authorization request packet . * @ param request the socks proxy request data * @ return the encoded buffer * @ throws UnsupportedEncodingException if request ' s hostname charset * can ' t be converted to ASCII . */ private IoBuffer encodeProxyRequestPa...
int len = 6 ; InetSocketAddress adr = request . getEndpointAddress ( ) ; byte addressType = 0 ; byte [ ] host = null ; if ( adr != null && ! adr . isUnresolved ( ) ) { if ( adr . getAddress ( ) instanceof Inet6Address ) { len += 16 ; addressType = SocksProxyConstants . IPV6_ADDRESS_TYPE ; } else if ( adr . getAddress (...
public class TermFrequencyCounter { /** * 取前N个高频词 * @ param N * @ return */ public Collection < TermFrequency > top ( int N ) { } }
MaxHeap < TermFrequency > heap = new MaxHeap < TermFrequency > ( N , new Comparator < TermFrequency > ( ) { @ Override public int compare ( TermFrequency o1 , TermFrequency o2 ) { return o1 . compareTo ( o2 ) ; } } ) ; heap . addAll ( termFrequencyMap . values ( ) ) ; return heap . toList ( ) ;
public class RebuildWorkspacesRequest { /** * The WorkSpace to rebuild . You can specify a single WorkSpace . * @ return The WorkSpace to rebuild . You can specify a single WorkSpace . */ public java . util . List < RebuildRequest > getRebuildWorkspaceRequests ( ) { } }
if ( rebuildWorkspaceRequests == null ) { rebuildWorkspaceRequests = new com . amazonaws . internal . SdkInternalList < RebuildRequest > ( ) ; } return rebuildWorkspaceRequests ;
public class JBBPUtils { /** * Convert array of JBBP fields into a list . * @ param fields an array of fields , must not be null * @ return a list of JBBP fields */ public static List < JBBPAbstractField > fieldsAsList ( final JBBPAbstractField ... fields ) { } }
final List < JBBPAbstractField > result = new ArrayList < > ( ) ; Collections . addAll ( result , fields ) ; return result ;
public class FieldParser { /** * Gets the parser for the type specified by the given class . Returns null , if no parser for that class * is known . * @ param type The class of the type to get the parser for . * @ return The parser for the given type , or null , if no such parser exists . */ public static < T > C...
Class < ? extends FieldParser < ? > > parser = PARSERS . get ( type ) ; if ( parser == null ) { return null ; } else { @ SuppressWarnings ( "unchecked" ) Class < FieldParser < T > > typedParser = ( Class < FieldParser < T > > ) parser ; return typedParser ; }
public class Host { /** * Parse the hostname from a " hostname : port " formatted string * @ param hostAndPort * @ return */ public static String parseHostFromHostAndPort ( String hostAndPort ) { } }
return hostAndPort . lastIndexOf ( ':' ) > 0 ? hostAndPort . substring ( 0 , hostAndPort . lastIndexOf ( ':' ) ) : hostAndPort ;
public class PennTokenizer { /** * Tokenizes according to the Penn Treebank conventions . * @ param str the str * @ return the string */ public static String tokenize ( String str ) { } }
str = str . replaceAll ( "``" , " `` " ) ; str = str . replaceAll ( "''" , " '' " ) ; str = str . replaceAll ( "\"" , " \" " ) ; str = str . replaceAll ( "([?!\";#$&])" , " $1 " ) ; str = str . replaceAll ( "\\.\\.\\." , " ... " ) ; str = str . replaceAll ( "([^.])([.])([\\])}>\"']*)\\s*$" , "$1 $2$3 " ) ; str = str ...
public class IOUtil { /** * Internal copy file method . * @ param srcFile * the validated source file , must not be { @ code null } * @ param destFile * the validated destination file , must not be { @ code null } * @ param preserveFileDate * whether to preserve the file date */ private static void doCopyFi...
if ( destFile . exists ( ) ) { throw new IllegalArgumentException ( "The destination file already existed: " + destFile . getAbsolutePath ( ) ) ; } FileInputStream fis = null ; FileOutputStream fos = null ; FileChannel input = null ; FileChannel output = null ; try { fis = new FileInputStream ( srcFile ) ; fos = new Fi...
public class Downloader { /** * 下载文件 * @ param downloadURL 下载的URL * @ return 是否下载成功 */ @ SuppressWarnings ( "ResultOfMethodCallIgnored" ) public static boolean download ( String downloadURL ) { } }
if ( Checker . isHyperLink ( downloadURL ) && checkDownloadPath ( ) ) { logger . info ( "ready for download url: " + downloadURL + " storage in " + storageFolder ) ; } else { logger . info ( "url or storage path are invalidated, can't download" ) ; return false ; } int byteRead ; String log = "download success from url...
public class Instagram4j { /** * / * TAGS ENDPOINTS */ @ Override public InstagramSingleObjectResponse < InstagramTags > getTagsCountByName ( String accessToken , String tagName ) throws InstagramError { } }
return instagramEndpoints . getTagsCountByName ( accessToken , tagName ) ;
public class Error { /** * Thrown if the class haven ' t an empty constructor . * @ param aClass class to analyze */ public static void emptyConstructorAbsent ( Class < ? > aClass ) { } }
throw new MalformedBeanException ( MSG . INSTANCE . message ( malformedBeanException1 , aClass . getSimpleName ( ) ) ) ;
public class IsomorphicGraphCounter { /** * Fill in */ public void addInitial ( G g ) { } }
Pair < Integer > orderAndSize = new Pair < Integer > ( g . order ( ) , g . size ( ) ) ; Map < G , Integer > graphs = orderAndSizeToGraphs . get ( orderAndSize ) ; if ( graphs == null ) { graphs = new HashMap < G , Integer > ( ) ; orderAndSizeToGraphs . put ( orderAndSize , graphs ) ; graphs . put ( g , 0 ) ; } else { f...
public class Category { /** * This internal method is used as a callback for when the translation * service or its locale changes . Also applies the translation to all * contained sections . * @ see com . dlsc . formsfx . model . structure . Group : : translate */ public void translate ( TranslationService transl...
if ( translationService == null ) { description . setValue ( descriptionKey . getValue ( ) ) ; return ; } if ( ! Strings . isNullOrEmpty ( descriptionKey . get ( ) ) ) { description . setValue ( translationService . translate ( descriptionKey . get ( ) ) ) ; }
public class Right { /** * Supports column level rights */ boolean canSelect ( Table table , boolean [ ] columnCheckList ) { } }
if ( isFull || isFullSelect ) { return true ; } return containsAllColumns ( selectColumnSet , table , columnCheckList ) ;
public class VersionsImpl { /** * Gets the application versions info . * @ param appId The application ID . * @ param listOptionalParameter the object representing the optional parameters to be set before calling this API * @ throws IllegalArgumentException thrown if parameters fail the validation * @ return th...
return listWithServiceResponseAsync ( appId , listOptionalParameter ) . map ( new Func1 < ServiceResponse < List < VersionInfo > > , List < VersionInfo > > ( ) { @ Override public List < VersionInfo > call ( ServiceResponse < List < VersionInfo > > response ) { return response . body ( ) ; } } ) ;
public class TypeToken { /** * 判断Type是否能确定最终的class , 是则返回true , 存在通配符或者不确定类型则返回false 。 * 例如 : Map & # 60 ; String , String & # 62 ; 返回 ture ; Map & # 60 ; ? extends Serializable , String & # 62 ; 返回false ; * @ param type Type对象 * @ return 是否可反解析 */ public final static boolean isClassType ( final Type type ) { } }
if ( type instanceof Class ) return true ; if ( type instanceof WildcardType ) return false ; if ( type instanceof TypeVariable ) return false ; if ( type instanceof GenericArrayType ) return isClassType ( ( ( GenericArrayType ) type ) . getGenericComponentType ( ) ) ; if ( ! ( type instanceof ParameterizedType ) ) ret...