signature
stringlengths
43
39.1k
implementation
stringlengths
0
450k
public class ProposalLineItemPremium { /** * Gets the premiumRateValue value for this ProposalLineItemPremium . * @ return premiumRateValue * The { @ link PremiumRateValue } triggered by the { @ link ProposalLineItem } . * This attribute is * required . */ public com . google . api . ads . admanager . axis . v201...
return premiumRateValue ;
public class Container { /** * Computes the in - place bitwise AND of this container with another ( intersection ) . The current * container is generally modified , whereas the provided container ( x ) is unaffected . May generate * a new container . * @ param x other container * @ return aggregated container *...
if ( x instanceof ArrayContainer ) { return iand ( ( ArrayContainer ) x ) ; } else if ( x instanceof BitmapContainer ) { return iand ( ( BitmapContainer ) x ) ; } return iand ( ( RunContainer ) x ) ;
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } { @ link SoapRequestHeader } { @ code > } } */ @ XmlElementDecl ( namespace = "https://www.google.com/apis/ads/publisher/v201902" , name = "RequestHeader" ) public JAXBElement < SoapRequestHeader > createRequestHeader ( SoapReq...
return new JAXBElement < SoapRequestHeader > ( _RequestHeader_QNAME , SoapRequestHeader . class , null , value ) ;
public class Table { /** * Returns list of constraints dependent only on one column */ OrderedHashSet getDependentConstraints ( int colIndex ) { } }
OrderedHashSet set = new OrderedHashSet ( ) ; for ( int i = 0 , size = constraintList . length ; i < size ; i ++ ) { Constraint c = constraintList [ i ] ; if ( c . hasColumnOnly ( colIndex ) ) { set . add ( c ) ; } } return set ;
public class EntityBeanTypeImpl { /** * If not already created , a new < code > query < / code > element will be created and returned . * Otherwise , the first existing < code > query < / code > element will be returned . * @ return the instance defined for the element < code > query < / code > */ public QueryType ...
List < Node > nodeList = childNode . get ( "query" ) ; if ( nodeList != null && nodeList . size ( ) > 0 ) { return new QueryTypeImpl < EntityBeanType < T > > ( this , "query" , childNode , nodeList . get ( 0 ) ) ; } return createQuery ( ) ;
public class CmsDefaultXmlContentHandler { /** * Helper method to create a visibility configuration . < p > * @ param className the visibility handler class name * @ param params the parameters for the visibility * @ return the visibility configuration */ protected VisibilityConfiguration createVisibilityConfigur...
I_CmsXmlContentVisibilityHandler handler = this ; if ( className != null ) { try { handler = ( I_CmsXmlContentVisibilityHandler ) ( Class . forName ( className ) . newInstance ( ) ) ; } catch ( Exception e ) { LOG . error ( e . getLocalizedMessage ( ) , e ) ; } } VisibilityConfiguration result = new VisibilityConfigura...
public class UIPasswordField { /** * Sets the text . * @ param text the new text */ @ Override public void setText ( String text ) { } }
if ( password == null ) // called from parent ctor return ; if ( filterFunction != null ) text = filterFunction . apply ( text ) ; password . setLength ( 0 ) ; password . append ( text ) ; updateText ( ) ; selectingText = false ; if ( focused ) cursor . jumpToEnd ( ) ;
public class ServiceInstanceQuery { /** * Get a metadata value not in String list QueryCriterion . * Add a QueryCriterion to check ServiceInstance has metadata value * not in the target String list . * @ param key * the metadata key . * @ param list * the target String list that metadata value should not be...
QueryCriterion c = new NotInQueryCriterion ( key , list ) ; addQueryCriterion ( c ) ; return this ;
public class SelectorHelper { /** * Return the selector value class . * @ param selector the selector . * @ return the selector class . * @ throws ExecutionException if an error happens . */ public static Class getClass ( Selector selector ) throws ExecutionException { } }
Class returnClass = null ; switch ( selector . getType ( ) ) { case STRING : case COLUMN : returnClass = String . class ; break ; case BOOLEAN : returnClass = Boolean . class ; break ; case INTEGER : returnClass = Long . class ; break ; case FLOATING_POINT : returnClass = Double . class ; break ; case GROUP : returnCla...
public class NetworkService { /** * { @ inheritDoc } */ @ Override public boolean isConnected ( ) { } }
NetworkInfo networkInfo = isAvailable ( ) ; return ( networkInfo == null ) ? false : ( networkInfo . getState ( ) . equals ( State . CONNECTED ) ) ? true : false ;
public class ListServicesRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( ListServicesRequest listServicesRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( listServicesRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( listServicesRequest . getNextToken ( ) , NEXTTOKEN_BINDING ) ; protocolMarshaller . marshall ( listServicesRequest . getMaxResults ( ) , MAXRESULTS_BINDING ) ; proto...
public class cacheobject { /** * Use this API to flush cacheobject resources . */ public static base_responses flush ( nitro_service client , cacheobject resources [ ] ) throws Exception { } }
base_responses result = null ; if ( resources != null && resources . length > 0 ) { cacheobject flushresources [ ] = new cacheobject [ resources . length ] ; for ( int i = 0 ; i < resources . length ; i ++ ) { flushresources [ i ] = new cacheobject ( ) ; flushresources [ i ] . locator = resources [ i ] . locator ; flus...
public class ModelExt { /** * Data Count */ public Long dataCount ( ) { } }
SqlPara sql = SqlpKit . select ( this , "count(*) AS cnt" ) ; Record record = Db . findFirst ( sql ) ; if ( null != record ) { return record . get ( "cnt" ) ; } return 0L ;
public class ShortCircuitBlockWriteHandler { /** * Handles complete block request . No exceptions should be thrown . */ public void handleBlockCompleteRequest ( boolean isCanceled ) { } }
final String methodName = isCanceled ? "AbortBlock" : "CommitBlock" ; RpcUtils . streamingRPCAndLog ( LOG , new RpcUtils . StreamingRpcCallable < CreateLocalBlockResponse > ( ) { @ Override public CreateLocalBlockResponse call ( ) throws Exception { if ( mRequest == null ) { return null ; } Context newContext = Context...
public class MetadataStore { /** * Changes to cluster OR store definition metadata results in routing * strategies changing . These changes need to be propagated to all the * listeners . * @ param cluster The updated cluster metadata * @ param storeDefs The updated list of store definition */ private void updat...
// acquire write lock writeLock . lock ( ) ; try { VectorClock clock = new VectorClock ( ) ; if ( metadataCache . containsKey ( ROUTING_STRATEGY_KEY ) ) clock = ( VectorClock ) metadataCache . get ( ROUTING_STRATEGY_KEY ) . getVersion ( ) ; logger . info ( "Updating routing strategy for all stores" ) ; HashMap < String...
public class DateRuleItem { /** * Gets the relativeValue value for this DateRuleItem . * @ return relativeValue * The relative date value of the right hand side . The { @ code * value } field will * override this field when both are present . */ public com . google . api . ads . adwords . axis . v201809 . rm . Re...
return relativeValue ;
public class CmsFlexBucketConfiguration { /** * Gets the bucket name for the given bit index . < p > * @ param bitIndex the bit index for the bucket in the bit set representation . < p > * @ return the name of the bucket */ public String getBucketName ( int bitIndex ) { } }
if ( bitIndex == 0 ) { return BUCKET_OTHER ; } else { String result = null ; if ( ( bitIndex - 1 ) < m_bucketNames . size ( ) ) { result = m_bucketNames . get ( bitIndex - 1 ) ; } if ( result == null ) { return "??? " + bitIndex ; } else { return result ; } }
public class BaseRxLoader { /** * Cancels the task . * @ return true if the task was started , false otherwise */ public boolean unsubscribe ( ) { } }
CachingWeakRefSubscriber < T > subscriber = manager . get ( tag ) ; if ( subscriber != null ) { subscriber . unsubscribe ( ) ; return true ; } return false ;
public class MethodSpec { /** * Returns a new method spec builder that overrides { @ code method } . * < p > This will copy its visibility modifiers , type parameters , return type , name , parameters , and * throws declarations . An { @ link Override } annotation will be added . * < p > Note that in JavaPoet 1.2...
checkNotNull ( method , "method == null" ) ; Element enclosingClass = method . getEnclosingElement ( ) ; if ( enclosingClass . getModifiers ( ) . contains ( Modifier . FINAL ) ) { throw new IllegalArgumentException ( "Cannot override method on final class " + enclosingClass ) ; } Set < Modifier > modifiers = method . g...
public class HexUtil { /** * Appends a byte array to a StringBuilder with each byte in a " Big Endian " * hexidecimal format . For example , a byte 0x34 will be appended as a * String in format " 34 " . A byte array of { 0x34 , 035 } would append " 3435 " . * @ param buffer The StringBuilder the byte array in hex...
assertNotNull ( buffer ) ; if ( bytes == null ) { return ; // do nothing ( a noop ) } assertOffsetLengthValid ( offset , length , bytes . length ) ; int end = offset + length ; for ( int i = offset ; i < end ; i ++ ) { int nibble1 = ( bytes [ i ] & 0xF0 ) >>> 4 ; int nibble0 = ( bytes [ i ] & 0x0F ) ; buffer . append (...
public class TimerGroup { /** * Log elapsed time of all named timers if the condition is true . */ private void log ( boolean finalLog , String format , Object ... args ) { } }
if ( m_condition ) { if ( format != null ) { m_logger . debug ( String . format ( format , args ) ) ; } ArrayList < String > timerNames = new ArrayList < String > ( m_timers . keySet ( ) ) ; Collections . sort ( timerNames ) ; for ( String name : timerNames ) { TimerGroupItem timer = m_timers . get ( name ) ; if ( fina...
public class LabelProcessor { /** * Create a new labelBuilder and register label with the default locale . * @ param label the label to be added * @ return the updated label builder */ public static Label buildLabel ( final String label ) { } }
return addLabel ( Label . newBuilder ( ) , Locale . getDefault ( ) , label ) . build ( ) ;
public class CmsAreaSelectPanel { /** * Calculates the matching X ( left / width ) value in case of a fixed height / width ratio . < p > * @ param newX the cursor X offset to the selection area * @ param newY the cursor Y offset to the selection area * @ return the matching X value */ private int getXForY ( int n...
int width = ( int ) Math . floor ( ( newY - m_firstY ) / m_heightToWidth ) ; int result = m_firstX + width ; if ( ( ( m_firstX - newX ) * ( m_firstX - result ) ) < 0 ) { result = m_firstX - width ; } return result ;
public class ImageRetinaApiImpl { /** * { @ inheritDoc } */ @ Override public ByteArrayInputStream getImage ( ImagePlotShape shape , Double sparsity , Model model ) throws JsonProcessingException , ApiException { } }
return getImage ( null , shape , null , sparsity , model ) ;
public class Serializer { /** * Reconstitute the given BagObject representation back to the object it represents , using a * " best - effort " approach to matching the fields of the BagObject to the class being initialized . * @ param bag The input data to reconstruct from , either a BagObject or BagArray * @ par...
return ( bag != null ) ? ( WorkingType ) deserialize ( type . getName ( ) , bag ) : null ;
public class LBiObjCharConsumerBuilder { /** * 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 < T1 , T2 > LBiObjCharConsumer < T1 , T2 > biObjCharConsumerFrom ( Consumer < LBiObjCharConsumerBuilder < T1 ...
LBiObjCharConsumerBuilder builder = new LBiObjCharConsumerBuilder ( ) ; buildingFunction . accept ( builder ) ; return builder . build ( ) ;
public class LegacyCompositionHandler { /** * ( non - Javadoc ) * @ see javax . faces . view . facelets . FaceletHandler # apply ( javax . faces . view . facelets . FaceletContext , * javax . faces . component . UIComponent ) */ public void apply ( FaceletContext ctx , UIComponent parent ) throws IOException , Face...
if ( _template != null ) { VariableMapper orig = ctx . getVariableMapper ( ) ; AbstractFaceletContext actx = ( AbstractFaceletContext ) ctx ; actx . extendClient ( this ) ; if ( _params != null ) { VariableMapper vm = new VariableMapperWrapper ( orig ) ; ctx . setVariableMapper ( vm ) ; for ( int i = 0 ; i < _params . ...
public class Nbvcxz { /** * Returns the best combination of matches based on multiple methods . We run the password through the * { @ code findGoodEnoughCombination } method test to see if is considered " random " . If it isn ' t , we * run it through the { @ code findBestCombination } method , which is much more e...
this . best_matches . clear ( ) ; this . best_matches_length = 0 ; final List < Match > all_matches = getAllMatches ( configuration , password ) ; final Map < Integer , Match > brute_force_matches = new HashMap < > ( ) ; for ( int i = 0 ; i < password . length ( ) ; i ++ ) { brute_force_matches . put ( i , createBruteF...
public class AbstractJaxb { /** * add class attribute . If already set , do nothing . */ public < T extends AbstractJaxb > void addCssClass ( String clazz ) { } }
List < String > classList = this . getCssClass ( ) ; if ( ! this . hasCssClass ( clazz ) ) { classList . add ( clazz ) ; }
public class MisoScenePanel { /** * Provides an icon for this tooltip , the default looks up an object action handler for the * action and requests the icon from it . */ protected Icon getTipIcon ( SceneObject scobj , String action ) { } }
ObjectActionHandler oah = ObjectActionHandler . lookup ( action ) ; return ( oah == null ) ? null : oah . getTipIcon ( action ) ;
public class Type { /** * If class passed in represents a primitive type , its object peer is * returned . Otherwise , it is returned unchanged . */ private static Class < ? > convertToObject ( Class < ? > type ) { } }
if ( type == int . class ) { return Integer . class ; } else if ( type == boolean . class ) { return Boolean . class ; } else if ( type == byte . class ) { return Byte . class ; } else if ( type == char . class ) { return Character . class ; } else if ( type == short . class ) { return Short . class ; } else if ( type ...
public class Medias { /** * Get the media with an additional suffix , just before the dot of the extension if has . * @ param media The current media reference ( must not be < code > null < / code > ) . * @ param suffix The suffix to add ( must not be < code > null < / code > ) . * @ return The new media with suf...
Check . notNull ( media ) ; Check . notNull ( suffix ) ; final String path = media . getPath ( ) ; final int dotIndex = path . lastIndexOf ( Constant . DOT ) ; if ( dotIndex > - 1 ) { return Medias . create ( path . substring ( 0 , dotIndex ) + Constant . UNDERSCORE + suffix + path . substring ( dotIndex ) ) ; } return...
public class ScanResult { /** * Get the list of all resources found in whitelisted packages that have a path matching the requested pattern . * @ param pattern * A pattern to match { @ link Resource } paths with . * @ return A list of all resources found in whitelisted packages that have a path matching the reque...
if ( closed . get ( ) ) { throw new IllegalArgumentException ( "Cannot use a ScanResult after it has been closed" ) ; } final ResourceList allWhitelistedResources = getAllResources ( ) ; if ( allWhitelistedResources . isEmpty ( ) ) { return ResourceList . EMPTY_LIST ; } else { final ResourceList filteredResources = new...
public class RuleModel { /** * This will get a list of all bound variables ( LHS and RHS ) , including bound fields . . */ public List < String > getAllVariables ( ) { } }
List < String > result = new ArrayList < String > ( ) ; result . addAll ( this . getAllLHSVariables ( ) ) ; result . addAll ( this . getAllRHSVariables ( ) ) ; return result ;
public class Cookies { /** * Parses a " Set - Cookie : " response header value into its cookie representation . The header value is parsed according to the * syntax that ' s defined in RFC2109: * < pre > * < code > * set - cookie = " Set - Cookie : " cookies * cookies = 1 # cookie * cookie = NAME " = " VALU...
String key = null ; CookieImpl cookie = null ; int state = 0 ; int current = 0 ; for ( int i = 0 ; i < headerValue . length ( ) ; ++ i ) { char c = headerValue . charAt ( i ) ; switch ( state ) { case 0 : { // reading key if ( c == '=' ) { key = headerValue . substring ( current , i ) ; current = i + 1 ; state = 1 ; } ...
public class BlueprintMarshaller { /** * Marshall the given parameter object . */ public void marshall ( Blueprint blueprint , ProtocolMarshaller protocolMarshaller ) { } }
if ( blueprint == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( blueprint . getBlueprintId ( ) , BLUEPRINTID_BINDING ) ; protocolMarshaller . marshall ( blueprint . getName ( ) , NAME_BINDING ) ; protocolMarshaller . marshall ( blueprint ....
public class ErrorHelper { /** * This method will recycle the given converter . */ public static RESTHandlerJsonException createRESTHandlerJsonException ( Throwable e , JSONConverter converter , int status ) { } }
try { // See if we need to fetch a converter if ( converter == null ) { converter = JSONConverter . getConverter ( ) ; } // Create a new OutputStream to avoid any corrupted data ByteArrayOutputStream os = new ByteArrayOutputStream ( ) ; // Write the exception inside the output stream converter . writeThrowable ( os , e...
public class TemplateProcessorMojo { /** * Apply templates . */ private void generate ( TemplateFile input , List < OutputFile > outputs , TemplateOptions templateOptions ) throws IOException { } }
final String targetFileName = targetFileName ( templatesPath . relativize ( input . path ) . toString ( ) , templateOptions ) ; final OutputFile output = new OutputFile ( outputPath . resolve ( targetFileName ) . toAbsolutePath ( ) . normalize ( ) ) ; if ( incremental && Files . exists ( output . path ) && Files . getL...
public class EntityHandle { /** * Return < code > EJBObject < / code > reference for this handle . < p > */ public EJBObject getEJBObject ( ) throws RemoteException { } }
if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "getEJBObject" ) ; if ( object == null ) { try { Class homeClass = null ; try { // If we are running on the server side , then the thread // context loader would have been set appropriately by // the container . If running on a...
public class QueryEngine { /** * Make a new FilterParsingResult after normalizing the query . This FilterParsingResult is not supposed to have * grouping / aggregation . */ private IckleParsingResult < TypeMetadata > makeFilterParsingResult ( IckleParsingResult < TypeMetadata > parsingResult , BooleanExpr normalizedW...
String queryString = SyntaxTreePrinter . printTree ( parsingResult . getTargetEntityName ( ) , projection , normalizedWhereClause , sortFields ) ; return new IckleParsingResult < > ( queryString , parsingResult . getParameterNames ( ) , normalizedWhereClause , null , parsingResult . getTargetEntityName ( ) , parsingRes...
public class system_settings { /** * < pre > * Use this operation to modify SDX system settings . * < / pre > */ public static system_settings update ( nitro_service client , system_settings resource ) throws Exception { } }
resource . validate ( "modify" ) ; return ( ( system_settings [ ] ) resource . update_resource ( client ) ) [ 0 ] ;
public class Drawer { /** * Draw the divider on the top side of the Item . */ public void drawBottom ( View view , Canvas c ) { } }
int left = view . getLeft ( ) - mWidth ; int top = view . getBottom ( ) ; int right = view . getRight ( ) + mWidth ; int bottom = top + mHeight ; mDivider . setBounds ( left , top , right , bottom ) ; mDivider . draw ( c ) ;
public class UserMessages { /** * Save validation success attribute , derived in validation process , e . g . selected data , < br > * to avoid duplicate database access between validation and main logic . * < pre > * String < span style = " color : # 553000 " > keyOfProduct < / span > = Product . < span style = ...
assertArgumentNotNull ( "key" , key ) ; assertArgumentNotNull ( "value" , value ) ; assertLocked ( ) ; if ( successAttributeMap == null ) { successAttributeMap = new LinkedHashMap < String , Object > ( 4 ) ; } successAttributeMap . put ( key , value ) ;
public class HistoricTaskInstanceManager { /** * Deletes all data related with tasks , which belongs to specified process instance ids . * @ param processInstanceIds * @ param deleteVariableInstances when true , will also delete variable instances . Can be false when variable instances were deleted separately . */ ...
CommandContext commandContext = Context . getCommandContext ( ) ; if ( deleteVariableInstances ) { getHistoricVariableInstanceManager ( ) . deleteHistoricVariableInstancesByTaskProcessInstanceIds ( processInstanceIds ) ; } getHistoricDetailManager ( ) . deleteHistoricDetailsByTaskProcessInstanceIds ( processInstanceIds...
public class StreamingEndpoint { /** * Create an operation object that will get the state of the given asset . * @ param assetId * id of asset to retrieve * @ return the get operation */ public static EntityGetOperation < StreamingEndpointInfo > get ( String streamingEndpointId ) { } }
return new DefaultGetOperation < StreamingEndpointInfo > ( ENTITY_SET , streamingEndpointId , StreamingEndpointInfo . class ) ;
public class MailClientHandler { /** * DO NOT synchronize ! */ public void enqueue ( CommandCompletion completion ) { } }
completions . add ( completion ) ; commandTrace . add ( new Date ( ) . toString ( ) + " " + completion . toString ( ) ) ;
public class ResourceResolutionContext { /** * Convenience wrapper for message parameters * @ param params * @ return */ public static Map < String , Object > with ( Object ... params ) { } }
Map < String , Object > map = new HashMap < > ( ) ; for ( int i = 0 ; i < params . length ; i ++ ) { map . put ( String . valueOf ( i ) , params [ i ] ) ; } return map ;
public class VectorRequestMessage { /** * This message is possible to get only as Shard */ @ Override public void processMessage ( ) { } }
VectorAggregation aggregation = new VectorAggregation ( rowIndex , ( short ) voidConfiguration . getNumberOfShards ( ) , getShardIndex ( ) , storage . getArray ( key ) . getRow ( rowIndex ) . dup ( ) ) ; aggregation . setOriginatorId ( this . getOriginatorId ( ) ) ; clipboard . pin ( aggregation ) ; DistributedVectorMe...
public class Languages { /** * Returns true if the language component is supported by this application . * For example , this application may have Portuguese ( pt ) as a registered * language but not Brazilian Portuguese ( pt - BR ) . In this case , pt - BR would * be supported because of the pt registration . ...
String lang = getLanguageComponent ( language ) ; return languageLookup . containsKey ( lang ) ;
public class GPIOEndpoint { /** * Create producer map to an Output PIN */ @ Override public Producer createProducer ( ) throws Exception { } }
LOG . debug ( this . toString ( ) ) ; if ( direction == null || ( direction . compareTo ( "" ) == 0 ) ) { direction = "DIR_OUTPUT_ONLY" ; } if ( mode == null || ( mode . compareTo ( "" ) == 0 ) ) { mode = "MODE_OUTPUT_PUSH_PULL" ; } if ( trigger == null || ( trigger . compareTo ( "" ) == 0 ) ) { trigger = "TRIGGER_NONE...
public class ReloadHandler { /** * / * ( non - Javadoc ) * @ see org . jboss . as . cli . handlers . CommandHandlerWithHelp # doHandle ( org . jboss . as . cli . CommandContext ) */ @ Override protected void doHandle ( CommandContext ctx ) throws CommandLineException { } }
final ModelControllerClient client = ctx . getModelControllerClient ( ) ; if ( client == null ) { throw new CommandLineException ( "Connection is not available." ) ; } if ( embeddedServerRef != null && embeddedServerRef . get ( ) != null ) { doHandleEmbedded ( ctx , client ) ; return ; } if ( ! ( client instanceof Awai...
public class ComponentBindingsProviderFactoryImpl { /** * ( non - Javadoc ) * @ see * com . sixdimensions . wcm . cq . component . bindings . ComponentBindingsProviderFactory * # getComponentBindingsProviders ( java . lang . String ) */ @ Override public List < ComponentBindingsProvider > getComponentBindingsProv...
List < ComponentBindingsProvider > cis = new ArrayList < ComponentBindingsProvider > ( ) ; for ( ServiceReference reference : getReferences ( resourceType ) ) { ComponentBindingsProvider ci = ComponentBindingsProvider . class . cast ( bundleContext . getService ( reference ) ) ; cis . add ( ci ) ; } if ( cis . size ( )...
public class RouteFilterRulesInner { /** * Updates a route in the specified route filter . * @ param resourceGroupName The name of the resource group . * @ param routeFilterName The name of the route filter . * @ param ruleName The name of the route filter rule . * @ param routeFilterRuleParameters Parameters s...
return beginUpdateWithServiceResponseAsync ( resourceGroupName , routeFilterName , ruleName , routeFilterRuleParameters ) . map ( new Func1 < ServiceResponse < RouteFilterRuleInner > , RouteFilterRuleInner > ( ) { @ Override public RouteFilterRuleInner call ( ServiceResponse < RouteFilterRuleInner > response ) { return...
public class CmsPathMap { /** * Adds an element for the given path , overwriting the previous element for that path if there is one . < p > * @ param path the path * @ param value the element to add */ public void add ( String path , V value ) { } }
m_tree . setValue ( splitPath ( path ) , value ) ;
public class JDBCDatabaseMetaData { /** * # ifdef JAVA4 */ public int getDatabaseMajorVersion ( ) throws SQLException { } }
ResultSet rs = execute ( "call \"org.hsqldb_voltpatches.Library.getDatabaseMajorVersion\"()" ) ; rs . next ( ) ; int result = rs . getInt ( 1 ) ; rs . close ( ) ; return result ;
public class AppServicePlansInner { /** * Reboot a worker machine in an App Service plan . * Reboot a worker machine in an App Service plan . * @ param resourceGroupName Name of the resource group to which the resource belongs . * @ param name Name of the App Service plan . * @ param workerName Name of worker m...
rebootWorkerWithServiceResponseAsync ( resourceGroupName , name , workerName ) . toBlocking ( ) . single ( ) . body ( ) ;
public class InIsaFragment { /** * A type - safe way to do ` a . choose ( pred , whenTrue , whenFalse ) ` , as ` choose ( a , pred , whenTrue , whenFalse ) ` . * This is because the default signature is too restrictive */ private < S , E1 , E2 > GraphTraversal < S , E2 > choose ( GraphTraversal < S , E1 > traversal ,...
// This is safe . The generics for ` GraphTraversal # choose ` are more restrictive than necessary // noinspection unchecked return traversal . choose ( traversalPredicate , ( GraphTraversal < S , E2 > ) trueChoice , ( GraphTraversal < S , E2 > ) falseChoice ) ;
public class CommerceTaxFixedRateAddressRelPersistenceImpl { /** * Returns the first commerce tax fixed rate address rel in the ordered set where commerceTaxMethodId = & # 63 ; . * @ param commerceTaxMethodId the commerce tax method ID * @ param orderByComparator the comparator to order the set by ( optionally < co...
CommerceTaxFixedRateAddressRel commerceTaxFixedRateAddressRel = fetchByCommerceTaxMethodId_First ( commerceTaxMethodId , orderByComparator ) ; if ( commerceTaxFixedRateAddressRel != null ) { return commerceTaxFixedRateAddressRel ; } StringBundler msg = new StringBundler ( 4 ) ; msg . append ( _NO_SUCH_ENTITY_WITH_KEY )...
public class FixIntegerQuantityPrecisionsBot { /** * Fetches the current online data for the given item , and fixes the * precision of integer quantities if necessary . * @ param itemIdValue * the id of the document to inspect * @ param propertyId * id of the property to consider */ protected void fixIntegerP...
String qid = itemIdValue . getId ( ) ; try { // Fetch the online version of the item to make sure we edit the // current version : ItemDocument currentItemDocument = ( ItemDocument ) dataFetcher . getEntityDocument ( qid ) ; if ( currentItemDocument == null ) { System . out . println ( "*** " + qid + " could not be fet...
public class WTreeRenderer { /** * Paints the given WTree . * @ param component the WTree to paint . * @ param renderContext the RenderContext to paint to . */ @ Override public void doRender ( final WComponent component , final WebXmlRenderContext renderContext ) { } }
WTree tree = ( WTree ) component ; XmlStringBuilder xml = renderContext . getWriter ( ) ; // Check if rendering an open item request String openId = tree . getOpenRequestItemId ( ) ; if ( openId != null ) { handleOpenItemRequest ( tree , xml , openId ) ; return ; } // Check the tree has tree items ( WCAG requirement ) ...
public class MessageProcessor { /** * Returns the LinkManager . * @ return LinkManager */ public LinkManager getLinkManager ( ) { } }
if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) { SibTr . entry ( tc , "getLinkManager" ) ; SibTr . exit ( tc , "getLinkManager" ) ; } return _linkManager ;
public class CreatePrivateVirtualInterfaceRequestMarshaller { /** * Marshall the given parameter object . */ public void marshall ( CreatePrivateVirtualInterfaceRequest createPrivateVirtualInterfaceRequest , ProtocolMarshaller protocolMarshaller ) { } }
if ( createPrivateVirtualInterfaceRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( createPrivateVirtualInterfaceRequest . getConnectionId ( ) , CONNECTIONID_BINDING ) ; protocolMarshaller . marshall ( createPrivateVirtualInterfaceR...
public class AppClassLoader { /** * Spring method to register the given ClassFileTransformer on this ClassLoader */ @ Override public boolean addTransformer ( final ClassFileTransformer cft ) { } }
transformers . add ( cft ) ; // Also recursively register with parent ( s ) , until a non - AppClassLoader or GlobalSharedLibrary loader is encountered . if ( parent instanceof AppClassLoader ) { if ( Util . isGlobalSharedLibraryLoader ( ( ( AppClassLoader ) parent ) ) ) { if ( TraceComponent . isAnyTracingEnabled ( ) ...
public class JCurand { /** * < pre > * Generate log - normally distributed doubles . * Use generator to generate num double results into the device memory at * outputPtr . The device memory must have been previously allocated and be * large enough to hold all the results . Launches are done with the stream * ...
return checkResult ( curandGenerateLogNormalDoubleNative ( generator , outputPtr , n , mean , stddev ) ) ;
public class AmazonAppStreamClient { /** * Deletes the specified image . You cannot delete an image when it is in use . After you delete an image , you cannot * provision new capacity using the image . * @ param deleteImageRequest * @ return Result of the DeleteImage operation returned by the service . * @ thro...
request = beforeClientExecution ( request ) ; return executeDeleteImage ( request ) ;
public class MaxFreeThreads { /** * { @ inheritDoc } */ @ Override public synchronized Address selectDistributedWorkManager ( Address own , DistributableWork work ) { } }
/* TODO String value = getWorkManager ( work ) ; if ( value ! = null ) if ( trace ) log . tracef ( " WorkManager : % s " , value ) ; return value ; */ Map < Address , Long > selectionMap = getSelectionMap ( own . getWorkManagerId ( ) , work ) ; Address result = null ; long freeThread = 0L ; if ( selectionMap ...
public class JcString { /** * < div color = ' red ' style = " font - size : 24px ; color : red " > < b > < i > < u > JCYPHER < / u > < / i > < / b > < / div > * < div color = ' red ' style = " font - size : 18px ; color : red " > < i > return the original string in lowercase < / i > < / div > * < br / > */ public J...
JcString ret = new JcString ( null , this , new FunctionInstance ( FUNCTION . String . LOWER , 1 ) ) ; QueryRecorder . recordInvocationConditional ( this , "lower" , ret ) ; return ret ;
public class Objects { /** * Creates an instance of { @ link ToStringHelper } . * < p > This is helpful for implementing { @ link Object # toString ( ) } . * Specification by example : < pre > { @ code * / / Returns " ClassName { } " * Objects . toStringHelper ( this ) * . toString ( ) ; * / / Returns " Cla...
return new ToStringHelper ( MoreObjects . simpleName ( self . getClass ( ) ) ) ;
public class DecimalUtils { /** * e . g . 0.30 equals 0.3 & & 0.30 equals 0.30 & & 0.30 equals 0.300. */ public static boolean isValueEquals ( BigDecimal decimal1 , BigDecimal decimal2 ) { } }
if ( decimal1 == null && decimal2 == null ) return true ; if ( decimal1 == null && decimal2 != null ) return false ; if ( decimal1 != null && decimal2 == null ) return false ; return cutInvalidSacle ( decimal1 ) . equals ( cutInvalidSacle ( decimal2 ) ) ;
public class DescribeDBSubnetGroupsResult { /** * A list of < a > DBSubnetGroup < / a > instances . * @ param dBSubnetGroups * A list of < a > DBSubnetGroup < / a > instances . */ public void setDBSubnetGroups ( java . util . Collection < DBSubnetGroup > dBSubnetGroups ) { } }
if ( dBSubnetGroups == null ) { this . dBSubnetGroups = null ; return ; } this . dBSubnetGroups = new java . util . ArrayList < DBSubnetGroup > ( dBSubnetGroups ) ;
public class ResourceUtil { /** * If the node is file . * @ param node node * @ return true if node is file false if not */ public static boolean isFile ( Node node ) { } }
try { if ( ! node . isNodeType ( "nt:file" ) ) return false ; if ( ! node . getNode ( "jcr:content" ) . isNodeType ( "nt:resource" ) ) return false ; return true ; } catch ( RepositoryException exc ) { LOG . error ( exc . getMessage ( ) , exc ) ; return false ; }
public class JDBC4ResultSet { /** * ResultSet object as a java . io . Reader object . */ @ Override public Reader getNCharacterStream ( int columnIndex ) throws SQLException { } }
checkColumnBounds ( columnIndex ) ; try { String value = table . getString ( columnIndex - 1 ) ; if ( ! wasNull ( ) ) return new StringReader ( value ) ; return null ; } catch ( Exception x ) { throw SQLError . get ( x ) ; }
public class Animation { /** * Check if we need to move to the next frame * @ param delta The amount of time thats passed since last update */ private void nextFrame ( long delta ) { } }
if ( stopped ) { return ; } if ( frames . size ( ) == 0 ) { return ; } nextChange -= delta ; while ( nextChange < 0 && ( ! stopped ) ) { if ( currentFrame == stopAt ) { stopped = true ; break ; } if ( ( currentFrame == frames . size ( ) - 1 ) && ( ! loop ) && ( ! pingPong ) ) { stopped = true ; break ; } currentFrame =...
public class MetaGraphDef { /** * < pre > * signature _ def : Map from user supplied key for a signature to a single * SignatureDef . * < / pre > * < code > map & lt ; string , . tensorflow . SignatureDef & gt ; signature _ def = 5 ; < / code > */ public java . util . Map < java . lang . String , org . tensorfl...
return internalGetSignatureDef ( ) . getMap ( ) ;
public class ContentElement { /** * Write the postamble into the given writer . Used by the FinalizeFlusher and by standard write method * @ param util an XML util * @ param writer the destination * @ throws IOException if the postamble could not be written */ public void writePostamble ( final XMLUtil util , fin...
if ( this . autofilters != null ) this . appendAutofilters ( writer , util ) ; writer . write ( "</office:spreadsheet>" ) ; writer . write ( "</office:body>" ) ; writer . write ( "</office:document-content>" ) ; writer . flush ( ) ; writer . closeEntry ( ) ;
public class BingMapTileSource { /** * Fire this after you ' ve set up your prefered tile styles and locale * if you forget , it should fire on the first request for tiles . * See issue < a href = " https : / / github . com / osmdroid / osmdroid / issues / 383 " > https : / / github . com / osmdroid / osmdroid / is...
if ( ! mImageryData . m_isInitialised ) { synchronized ( this ) { if ( ! mImageryData . m_isInitialised ) { final ImageryMetaDataResource imageryData = getMetaData ( ) ; if ( imageryData != null ) { mImageryData = imageryData ; updateBaseUrl ( ) ; } } } } return mImageryData ;
public class RegionUtils { /** * Returns the current set of region metadata for this process , * initializing it if it has not yet been explicitly initialized before . * @ return the current set of region metadata */ public static RegionMetadata getRegionMetadata ( ) { } }
RegionMetadata rval = regionMetadata ; if ( rval != null ) { return rval ; } synchronized ( RegionUtils . class ) { if ( regionMetadata == null ) { initialize ( ) ; } } return regionMetadata ;
public class NonMaxBlock { /** * Detects local minimums and / or maximums in the provided intensity image . * @ param intensityImage ( Input ) Feature intensity image . * @ param localMin ( Output ) storage for found local minimums . * @ param localMax ( Output ) storage for found local maximums . */ public void ...
if ( localMin != null ) localMin . reset ( ) ; if ( localMax != null ) localMax . reset ( ) ; // the defines the region that can be processed int endX = intensityImage . width - border ; int endY = intensityImage . height - border ; int step = configuration . radius + 1 ; search . initialize ( configuration , intensity...
public class GobblinClusterManager { /** * Configure Helix quota - based task scheduling */ @ VisibleForTesting void configureHelixQuotaBasedTaskScheduling ( ) { } }
// set up the cluster quota config List < String > quotaConfigList = ConfigUtils . getStringList ( this . config , GobblinClusterConfigurationKeys . HELIX_TASK_QUOTA_CONFIG_KEY ) ; if ( quotaConfigList . isEmpty ( ) ) { return ; } // retrieve the cluster config for updating ClusterConfig clusterConfig = this . multiMan...
public class OSQLPredicate { /** * Binds parameters . * @ param iArgs */ public void bindParameters ( final Map < Object , Object > iArgs ) { } }
if ( parameterItems == null || iArgs == null || iArgs . size ( ) == 0 ) return ; for ( Entry < Object , Object > entry : iArgs . entrySet ( ) ) { if ( entry . getKey ( ) instanceof Integer ) parameterItems . get ( ( ( Integer ) entry . getKey ( ) ) ) . setValue ( entry . setValue ( entry . getValue ( ) ) ) ; else { Str...
public class ControllerServiceMain { /** * Awaits until the internal state changes to STARTING , and returns the reference * of current ControllerServiceStarter . */ @ VisibleForTesting public ControllerServiceStarter awaitServiceStarting ( ) { } }
monitor . enterWhenUninterruptibly ( hasReachedStarting ) ; try { if ( serviceState != ServiceState . STARTING ) { throw new IllegalStateException ( "Expected state=" + ServiceState . STARTING + ", but actual state=" + serviceState ) ; } else { return this . starter ; } } finally { monitor . leave ( ) ; }
public class CommerceUserSegmentEntryWrapper { /** * Returns the localized name of this commerce user segment entry in the language , optionally using the default language if no localization exists for the requested language . * @ param languageId the ID of the language * @ param useDefault whether to use the defau...
return _commerceUserSegmentEntry . getName ( languageId , useDefault ) ;
public class MultimediaPickerFragment { /** * Overriding this method allows us to inject a preview image * in the layout * @ param vh to bind data from either a file or directory * @ param position 0 - n , where the header has been subtracted * @ param file to show info about */ @ Override public void onBindVie...
// Let the super method do its thing with checkboxes and text super . onBindViewHolder ( vh , position , file ) ; // Here we load the preview image if it is an image file final int viewType = getItemViewType ( position , file ) ; if ( viewType == VIEWTYPE_IMAGE_CHECKABLE || viewType == VIEWTYPE_IMAGE ) { // Need to set...
public class MethodWriterImpl { /** * Add the return type . * @ param method the method being documented . * @ param htmltree the content tree to which the return type will be added */ protected void addReturnType ( MethodDoc method , Content htmltree ) { } }
Type type = method . returnType ( ) ; if ( type != null ) { Content linkContent = writer . getLink ( new LinkInfoImpl ( configuration , LinkInfoImpl . Kind . RETURN_TYPE , type ) ) ; htmltree . addContent ( linkContent ) ; htmltree . addContent ( writer . getSpace ( ) ) ; }
public class MetricManager { /** * Start up the background thread that is processing metrics */ private static synchronized void startup ( ) { } }
try { if ( CONFIG == null ) { CONFIG = ApiConfigurations . fromProperties ( ) ; } ObjectMapper objectMapper = new ObjectMapper ( ) ; AppIdentityService appIdentityService = new AppIdentityService ( CONFIG , objectMapper , true ) ; MetricMonitorService monitorService = new MetricMonitorService ( CONFIG , objectMapper , ...
public class GenderMarshaller { /** * Marshall the given parameter object . */ public void marshall ( Gender gender , ProtocolMarshaller protocolMarshaller ) { } }
if ( gender == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( gender . getValue ( ) , VALUE_BINDING ) ; protocolMarshaller . marshall ( gender . getConfidence ( ) , CONFIDENCE_BINDING ) ; } catch ( Exception e ) { throw new SdkClientExcepti...
public class ObjectFactory { /** * Create an instance of { @ link JAXBElement } { @ code < } * { @ link IntegerUserMap } { @ code > } */ @ XmlElementDecl ( namespace = "http://hello.com" , name = "IntegerUserMap" ) public JAXBElement < IntegerUserMap > createIntegerUserMap ( IntegerUserMap value ) { } }
return new JAXBElement < IntegerUserMap > ( _IntegerUserMap_QNAME , IntegerUserMap . class , null , value ) ;
public class WSJdbcResultSet { /** * Gets a BLOB value in the current row of this ResultSet object . * @ param i - the first column is 1 , the second is 2 , . . . * @ return * a Blob object representing the SQL BLOB value in the specified column . */ public Blob getBlob ( int arg0 ) throws SQLException { } }
try { Blob blob = rsetImpl . getBlob ( arg0 ) ; if ( blob != null && freeResourcesOnClose ) blobs . add ( blob ) ; return blob ; } catch ( SQLException ex ) { FFDCFilter . processException ( ex , "com.ibm.ws.rsadapter.jdbc.WSJdbcResultSet.getBlob" , "754" , this ) ; throw WSJdbcUtil . mapException ( this , ex ) ; } cat...
public class nitro_service { /** * Use this API to login into NetScaler SDX . * @ param username Username * @ param password Password for the NetScaler SDX . * @ param timeout timeout for NetScaler SDX session . Default is 30mins * @ return status of the operation performed . * @ throws Exception nitro except...
this . set_credential ( username , password ) ; this . set_timeout ( timeout ) ; return this . login ( ) ;
public class Admin { /** * @ throws PageException */ private void doGetFLDs ( ) throws PageException { } }
lucee . runtime . type . Query qry = new QueryImpl ( new String [ ] { "displayname" , "namespace" , "namespaceseparator" , "shortname" , "description" , "uri" , "source" } , new String [ ] { "varchar" , "varchar" , "varchar" , "varchar" , "varchar" , "varchar" , "varchar" } , 0 , "tlds" ) ; int dialect = "lucee" . equa...
public class Charge { /** * Retrieves the details of a charge that has previously been created . Supply the unique charge ID * that was returned from your previous request , and Stripe will return the corresponding charge * information . The same information is returned when creating or refunding the charge . */ pu...
return retrieve ( charge , ( Map < String , Object > ) null , ( RequestOptions ) null ) ;
public class ContrastUtils { /** * Calculates the contrast ratio of two order - independent luminance values . * Derived from formula at http : / / gmazzocato . altervista . org / colorwheel / algo . php * @ param lum1 The first luminance value * @ param lum2 The second luminance value * @ return The contrast r...
if ( ( lum1 < 0.0d ) || ( lum2 < 0.0d ) ) { throw new IllegalArgumentException ( "Luminance values may not be negative." ) ; } return ( Math . max ( lum1 , lum2 ) + 0.05d ) / ( Math . min ( lum1 , lum2 ) + 0.05d ) ;
public class ToStringStyle { /** * < p > Append to the < code > toString < / code > an < code > Object < / code > , * correctly interpreting its type . < / p > * < p > This method performs the main lookup by Class type to correctly * route arrays , < code > Collections < / code > , < code > Maps < / code > and ...
if ( isRegistered ( value ) && ! ( value instanceof Number || value instanceof Boolean || value instanceof Character ) ) { appendCyclicObject ( buffer , fieldName , value ) ; return ; } register ( value ) ; try { if ( value instanceof Collection < ? > ) { if ( detail ) { appendDetail ( buffer , fieldName , ( Collection...
public class RegularExpressionValidator { /** * { @ inheritDoc } check if given string is a valid regular expression . * @ see javax . validation . ConstraintValidator # isValid ( java . lang . Object , * javax . validation . ConstraintValidatorContext ) */ @ Override public final boolean isValid ( final String pva...
if ( StringUtils . isEmpty ( pvalue ) ) { return true ; } try { // execute regular expression , result doesn ' t matter "x" . matches ( pvalue ) ; return true ; } catch ( final Exception pexception ) { // regular expression is invalid return false ; }
public class DefaultIoFuture { /** * Sets the result of the asynchronous operation , and mark it as finished . */ public void setValue ( Object newValue ) { } }
synchronized ( lock ) { // Allow only once . if ( ready ) { return ; } result = newValue ; ready = true ; if ( waiters > 0 ) { lock . notifyAll ( ) ; } } notifyListeners ( ) ;
public class Nfs3 { /** * / * ( non - Javadoc ) * @ see com . emc . ecs . nfsclient . nfs . Nfs # makeSetAttrRequest ( byte [ ] , com . emc . ecs . nfsclient . nfs . NfsSetAttributes , com . emc . ecs . nfsclient . nfs . NfsTime ) */ public NfsSetAttrRequest makeSetAttrRequest ( byte [ ] fileHandle , NfsSetAttributes...
return new Nfs3SetAttrRequest ( fileHandle , attributes , guardTime , _credential ) ;
public class RmPath { /** * currently does not support paths with name constrains */ private static List < Segment > parseSegments ( String origPathStr ) { } }
String pathStr = origPathStr ; if ( ! pathStr . startsWith ( "/" ) ) { pathStr = pathStr + "/" ; } List < Segment > result = new ArrayList < > ( ) ; for ( String segmentStr : PATH_SPLITTER . split ( pathStr ) ) { Matcher m = SEGMENT_PATTERN . matcher ( segmentStr ) ; if ( ! m . matches ( ) ) { throw new IllegalArgument...
public class LevelRipConverter { /** * Search current tile of image map by checking all surfaces . * @ param map The destination map reference . * @ param tileSprite The tiled sprite * @ param x The location x . * @ param y The location y . * @ return The tile found . */ private static Tile searchForTile ( Ma...
// Check each tile on each sheet for ( final Integer sheet : map . getSheets ( ) ) { final Tile tile = checkTile ( map , tileSprite , sheet , x , y ) ; if ( tile != null ) { return tile ; } } // No tile found return null ;
public class Policy { /** * clearPolicy clears all current policy . */ public void clearPolicy ( ) { } }
if ( model . containsKey ( "p" ) ) { for ( Assertion ast : model . get ( "p" ) . values ( ) ) { ast . policy = new ArrayList < > ( ) ; } } if ( model . containsKey ( "g" ) ) { for ( Assertion ast : model . get ( "g" ) . values ( ) ) { ast . policy = new ArrayList < > ( ) ; } }
public class CreateIconChoicePopup { /** * used for displaying marker SVG elements in a drawing area . * @ param shape * @ param amountOfMarkers * @ return */ private ClickableMarkerShape translateMarker ( ClickableMarkerShape shape , int amountOfMarkers ) { } }
if ( amountOfMarkers % imagePerRow != 0 ) { int size = choiceListImageSize + 6 ; shape . setTranslation ( size * ( amountOfMarkers % imagePerRow ) , size * ( amountOfMarkers / imagePerRow ) ) ; } return shape ;