signature stringlengths 43 39.1k | implementation stringlengths 0 450k |
|---|---|
public class AABBUtils { /** * Checks if an { @ link AxisAlignedBB } array is colliding with another one .
* @ param aabbs1 the aabbs1
* @ param aabbs2 the aabbs2
* @ return true , if is colliding */
public static boolean isColliding ( AxisAlignedBB [ ] aabbs1 , AxisAlignedBB [ ] aabbs2 ) { } } | if ( ArrayUtils . isEmpty ( aabbs1 ) || ArrayUtils . isEmpty ( aabbs2 ) ) return false ; for ( AxisAlignedBB aabb1 : aabbs1 ) { if ( aabb1 != null ) { for ( AxisAlignedBB aabb2 : aabbs2 ) if ( aabb2 != null && aabb1 . intersects ( aabb2 ) ) return true ; } } return false ; |
public class AtomContainer { /** * { @ inheritDoc } */
@ Override public ISingleElectron removeSingleElectron ( int position ) { } } | ISingleElectron se = singleElectrons [ position ] ; for ( int i = position ; i < singleElectronCount - 1 ; i ++ ) { singleElectrons [ i ] = singleElectrons [ i + 1 ] ; } singleElectrons [ singleElectronCount - 1 ] = null ; singleElectronCount -- ; return se ; |
public class DelegateAdapter { /** * Add adapters in < code > position < / code >
* @ param position the index where adapters added
* @ param adapters adapters */
public void addAdapters ( int position , @ Nullable List < Adapter > adapters ) { } } | if ( adapters == null || adapters . size ( ) == 0 ) { return ; } if ( position < 0 ) { position = 0 ; } if ( position > mAdapters . size ( ) ) { position = mAdapters . size ( ) ; } List < Adapter > newAdapter = new ArrayList < > ( ) ; Iterator < Pair < AdapterDataObserver , Adapter > > itr = mAdapters . iterator ( ) ; ... |
public class LoginAbstractAzkabanServlet { /** * Filter Project based on user authorization
* @ param project project
* @ param user user
* @ param type permission allowance
* @ param ret return map for holding messages
* @ return authorized project itself or null if the project is not authorized */
protected... | if ( project == null ) { if ( ret != null ) { ret . put ( "error" , "Project 'null' not found." ) ; } } else if ( ! hasPermission ( project , user , type ) ) { if ( ret != null ) { ret . put ( "error" , "User '" + user . getUserId ( ) + "' doesn't have " + type . name ( ) + " permissions on " + project . getName ( ) ) ... |
public class ZipTelemetryReceiver { private void createTelemetryInfoEntry ( TelemetryInfo info ) { } } | String infoEntry = createNumberedZipEntry ( info ) ; ZipEntry ze = new ZipEntry ( infoEntry ) ; try { zipOutputStream . putNextEntry ( ze ) ; zipOutputStream . closeEntry ( ) ; } catch ( IOException e ) { e . printStackTrace ( ) ; } telemetryInfoStack . push ( info ) ; info2EntryMap . put ( info , infoEntry ) ; info2Pr... |
public class ColumnSpec { /** * Splits and parses the encoded column specifications using the given { @ link LayoutMap } and
* returns an array of ColumnSpec objects .
* @ param encodedColumnSpecs comma separated encoded column specifications
* @ param layoutMap expands layout column variables
* @ return an arr... | return FormSpecParser . parseColumnSpecs ( encodedColumnSpecs , layoutMap ) ; |
public class ESGImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public Object eGet ( int featureID , boolean resolve , boolean coreType ) { } } | switch ( featureID ) { case AfplibPackage . ESG__REG_NAME : return getREGName ( ) ; } return super . eGet ( featureID , resolve , coreType ) ; |
public class ProtectionContainerOperationResultsInner { /** * Fetches the result of any operation on the container .
* @ param vaultName The name of the recovery services vault .
* @ param resourceGroupName The name of the resource group where the recovery services vault is present .
* @ param fabricName Fabric n... | return ServiceFuture . fromResponse ( getWithServiceResponseAsync ( vaultName , resourceGroupName , fabricName , containerName , operationId ) , serviceCallback ) ; |
public class Ec2InstanceAttributes { /** * Applies to clusters configured with the instance fleets option . Specifies the unique identifier of one or more
* Amazon EC2 subnets in which to launch EC2 cluster instances . Subnets must exist within the same VPC . Amazon EMR
* chooses the EC2 subnet with the best fit fr... | if ( this . requestedEc2SubnetIds == null ) { setRequestedEc2SubnetIds ( new com . amazonaws . internal . SdkInternalList < String > ( requestedEc2SubnetIds . length ) ) ; } for ( String ele : requestedEc2SubnetIds ) { this . requestedEc2SubnetIds . add ( ele ) ; } return this ; |
public class DeltaCollectionValuedMap { /** * This is more expensive than normal . */
@ Override public void clear ( ) { } } | // iterate over all keys in originalMap and set them to null in deltaMap
for ( K key : originalMap . keySet ( ) ) { deltaMap . put ( key , ErasureUtils . < Collection < V > > uncheckedCast ( removedValue ) ) ; } |
public class OProfiler { /** * ( non - Javadoc )
* @ see com . orientechnologies . common . profiler . ProfileMBean # getStatistic ( java . lang . String ) */
public long getCounter ( final String iStatName ) { } } | if ( iStatName == null ) return - 1 ; // CHECK IF STATISTICS ARE ACTIVED
if ( recording < 0 ) return - 1 ; synchronized ( counters ) { Long stat = counters . get ( iStatName ) ; if ( stat == null ) return - 1 ; return stat . longValue ( ) ; } |
public class Version { /** * < pre >
* An ordered list of URL - matching patterns that should be applied to incoming
* requests . The first matching URL handles the request and other request
* handlers are not attempted .
* Only returned in ` GET ` requests if ` view = FULL ` is set .
* < / pre >
* < code >... | return handlers_ ; |
public class WeakArrayList { /** * Replies the null value given by the user by the corresponding null object . */
@ SuppressWarnings ( "unchecked" ) private static < T > T maskNull ( T value ) { } } | return ( value == null ) ? ( T ) NULL_VALUE : value ; |
public class RequestHandler { /** * For every bucket that is open , apply the reconfiguration .
* @ param config the config for this bucket . */
private Observable < Boolean > reconfigureBucket ( final BucketConfig config ) { } } | LOGGER . debug ( "Starting reconfiguration for bucket {}" , config . name ( ) ) ; List < Observable < Boolean > > observables = new ArrayList < Observable < Boolean > > ( ) ; for ( final NodeInfo nodeInfo : config . nodes ( ) ) { final String alternate = nodeInfo . useAlternateNetwork ( ) ; final NetworkAddress altHost... |
public class GoogleMapsUrlSigner { /** * Returns the full url as String object with the signature as parameter .
* @ param url
* the url
* @ param yourGooglePrivateKeyString
* the your google private key string
* @ return the string
* @ throws NoSuchAlgorithmException
* the no such algorithm exception
*... | // Retrieve the proper URL components to sign
final String resource = url . getPath ( ) + '?' + url . getQuery ( ) ; // Get an HMAC - SHA1 signing key from the raw key bytes
final SecretKeySpec sha1Key = new SecretKeySpec ( convertToKeyByteArray ( yourGooglePrivateKeyString ) , "HmacSHA1" ) ; // Get an HMAC - SHA1 Mac ... |
public class CassandraSchemaManager { /** * Create secondary indexes on columns .
* @ param tableInfo
* the table info
* @ throws Exception
* the exception */
private void createIndexUsingCql ( TableInfo tableInfo ) throws Exception { } } | List < String > embeddedIndexes = new ArrayList < String > ( ) ; for ( EmbeddedColumnInfo embeddedColumnInfo : tableInfo . getEmbeddedColumnMetadatas ( ) ) { for ( ColumnInfo columnInfo : embeddedColumnInfo . getColumns ( ) ) { if ( columnInfo . isIndexable ( ) ) { embeddedIndexes . add ( columnInfo . getColumnName ( )... |
public class Messages { /** * get specific message by key and locale .
* @ param key key
* @ param msgLocale locale
* @ return string */
public static String getString ( final String key , final Locale msgLocale ) { } } | /* read message resource file . */
ResourceBundle RESOURCE_BUNDLE = ResourceBundle . getBundle ( BUNDLE_NAME , msgLocale ) ; try { return RESOURCE_BUNDLE . getString ( key ) ; } catch ( final MissingResourceException e ) { return key ; } |
public class FileMask { /** * Retourne une representation humainement lisible de la description de ce filtre . Par
* example : " JPEG and GIF Image Files ( * . jpg , * . gif ) "
* @ see # setDescription
* @ see # setExtensionListInDescription
* @ see # isExtensionListInDescription */
public String getDescriptio... | if ( fullDescription == null ) { if ( description == null || isExtensionListInDescription ( ) ) { fullDescription = description == null ? "(" : description + " (" ; // Construit la description a partir des extentions .
Enumeration < String > extensions = filters . keys ( ) ; if ( extensions != null ) { fullDescription ... |
public class Driver { /** * This method was added in v6.5 , and simply throws an SQLException for an unimplemented method . I
* decided to do it this way while implementing the JDBC2 extensions to JDBC , as it should help
* keep the overall driver size down . It now requires the call Class and the function name to ... | return new SQLFeatureNotSupportedException ( GT . tr ( "Method {0} is not yet implemented." , callClass . getName ( ) + "." + functionName ) , PSQLState . NOT_IMPLEMENTED . getState ( ) ) ; |
public class DOMHelper { /** * Use DTMNodeProxy to determine whether two nodes are the same .
* @ param node1 The first DOM node to compare .
* @ param node2 The second DOM node to compare .
* @ return true if the two nodes are the same . */
public static boolean isNodeTheSame ( Node node1 , Node node2 ) { } } | if ( node1 instanceof DTMNodeProxy && node2 instanceof DTMNodeProxy ) return ( ( DTMNodeProxy ) node1 ) . equals ( ( DTMNodeProxy ) node2 ) ; else return ( node1 == node2 ) ; |
public class DashboardDeserializer { /** * Gson invokes this call - back method during deserialization when it encounters a field of the specified type .
* @ param element The Json data being deserialized
* @ param type The type of the Object to deserialize to
* @ param context The JSON deserialization context
... | JsonObject obj = element . getAsJsonObject ( ) ; JsonElement dashboard = obj . get ( "dashboard" ) ; if ( dashboard != null && dashboard . isJsonObject ( ) ) return gson . fromJson ( dashboard , Dashboard . class ) ; return gson . fromJson ( element , Dashboard . class ) ; |
public class MultiUserChatManager { /** * Creates a multi user chat . Note : no information is sent to or received from the server until you attempt to
* { @ link MultiUserChat # join ( org . jxmpp . jid . parts . Resourcepart ) join } the chat room . On some server implementations , the room will not be
* created ... | WeakReference < MultiUserChat > weakRefMultiUserChat = multiUserChats . get ( jid ) ; if ( weakRefMultiUserChat == null ) { return createNewMucAndAddToMap ( jid ) ; } MultiUserChat multiUserChat = weakRefMultiUserChat . get ( ) ; if ( multiUserChat == null ) { return createNewMucAndAddToMap ( jid ) ; } return multiUser... |
public class ExpressionUtils { /** * Formats a date time as ISO8601 with microsecond precision and offset , e . g . " 2014-10-03T09:41:12.790123 + 02:00" */
public static String formatIsoDate ( ZonedDateTime value ) { } } | if ( value == null ) { return null ; } // to match the format we get from Python ' s . isoformat ( ) , we don ' t include second fraction if it ' s zero
if ( value . getNano ( ) == 0 ) { return ISO_DATETIME_FORMAT_NO_SECOND_FRACTION . format ( value ) ; } return ISO_DATETIME_FORMAT . format ( value ) ; |
public class Utils { /** * Returns a random string of a certain length */
public static String randomString ( int len , Random random ) { } } | if ( len < 1 ) { return "" ; } int start = ' ' ; int end = 'z' + 1 ; StringBuffer buffer = new StringBuffer ( ) ; int gap = end - start ; while ( len -- != 0 ) { char ch ; ch = ( char ) ( random . nextInt ( gap ) + start ) ; if ( Character . isLetterOrDigit ( ch ) ) { buffer . append ( ch ) ; } else { len ++ ; } } retu... |
public class AbstractHibernateCriteriaBuilder { /** * Creates a " between " Criterion based on the property name and specified lo and hi values
* @ param propertyName The property name
* @ param lo The low value
* @ param hi The high value
* @ return A Criterion instance */
public org . grails . datastore . map... | if ( ! validateSimpleExpression ( ) ) { throwRuntimeException ( new IllegalArgumentException ( "Call to [between] with propertyName [" + propertyName + "] not allowed here." ) ) ; } propertyName = calculatePropertyName ( propertyName ) ; addToCriteria ( Restrictions . between ( propertyName , lo , hi ) ) ; return this... |
public class AttributePropertiesManager { /** * Get an attribute property from tango db
* @ param attributeName
* @ param propertyName
* @ return The property
* @ throws DevFailed */
public String getAttributePropertyFromDB ( final String attributeName , final String propertyName ) throws DevFailed { } } | xlogger . entry ( propertyName ) ; String [ ] result = new String [ ] { } ; final Map < String , String [ ] > prop = DatabaseFactory . getDatabase ( ) . getAttributeProperties ( deviceName , attributeName ) ; if ( prop . get ( propertyName ) != null ) { // get value
result = prop . get ( propertyName ) ; logger . debug... |
public class DomainValidator { /** * Check if input contains only ASCII
* Treats null as all ASCII */
private static boolean isOnlyASCII ( String input ) { } } | if ( input == null ) { return true ; } for ( int i = 0 ; i < input . length ( ) ; i ++ ) { if ( input . charAt ( i ) > 0x7F ) { // CHECKSTYLE IGNORE MagicNumber
return false ; } } return true ; |
public class UserProfileHandlerImpl { /** * Migrates user profile from old storage into new .
* @ param oldUserNode
* the node where user properties are stored ( from old structure ) */
void migrateProfile ( Node oldUserNode ) throws Exception { } } | UserProfile userProfile = new UserProfileImpl ( oldUserNode . getName ( ) ) ; Node attrNode = null ; try { attrNode = oldUserNode . getNode ( JCROrganizationServiceImpl . JOS_PROFILE + "/" + MigrationTool . JOS_ATTRIBUTES ) ; } catch ( PathNotFoundException e ) { return ; } PropertyIterator props = attrNode . getProper... |
public class DefaultPropertyPlaceholderConfigurer { /** * extract the placeholder name from the complete placeholder string ( between prefix and separator ,
* or complete placeholder if no separator is found ) .
* @ param placeholderWithDefault default placeholder
* @ return the placeholder
* @ see # setPlaceho... | int separatorIdx = placeholderWithDefault . indexOf ( defaultSeparator ) ; if ( separatorIdx == - 1 ) { return placeholderWithDefault ; } return placeholderWithDefault . substring ( 0 , separatorIdx ) ; |
public class LocationAttributes { /** * Returns the { @ link Location } of an element ( SAX flavor ) .
* @ param attrs
* the element ' s attributes that hold the location information
* @ param description
* a description for the location ( can be null )
* @ return a { @ link Location } object */
public static... | String src = attrs . getValue ( URI , SRC_ATTR ) ; if ( src == null ) { return LocationImpl . UNKNOWN ; } return new LocationImpl ( description , src , getLine ( attrs ) , getColumn ( attrs ) ) ; |
public class SearchManager { /** * Perform hot reindexing of the workspace
* @ param dropExisting use the same index directory ( if " true " ) and all queries will throw
* an exception while task is running . Otherwise ( if " false " ) Server can continue
* working as expected while index is recreated ( the new i... | // checks
if ( handler == null || handler . getIndexerIoModeHandler ( ) == null || changesFilter == null ) { throw new IllegalStateException ( "Index might have not been initialized yet." ) ; } if ( handler . getIndexerIoModeHandler ( ) . getMode ( ) != IndexerIoMode . READ_WRITE ) { throw new IllegalStateException ( "... |
public class FileUtils { /** * Check the state of the external media ( i . e . SDCard ) on whether
* it is read / write , read only , or unavailable
* @ return the corresponding constant to the media state ( RW / RO / Unavailable ) */
public static int checkMediaState ( ) { } } | int mediastate = UNAVAILABLE ; String state = Environment . getExternalStorageState ( ) ; if ( Environment . MEDIA_MOUNTED . equals ( state ) ) { // We can read and write the media
mediastate = READ_WRITE ; } else if ( Environment . MEDIA_MOUNTED_READ_ONLY . equals ( state ) ) { // We can only read the media
mediastate... |
public class ReconciliationReportRow { /** * Gets the reconciledRevenue value for this ReconciliationReportRow .
* @ return reconciledRevenue * The revenue calculated based on the { @ link # billFrom } , { @ link
* # contractedRevenue } ,
* { @ link # dfpRevenue } , { @ link # thirdPartyRevenue } and
* { @ link... | return reconciledRevenue ; |
public class SSOClient { /** * 验证登录后获取到的Id Token并返回认证信息 。
* @ throws InvalidTokenException 如果idToken是无效的
* @ throws TokenExpiredException 如果idToken已经过期
* @ since 3.0.1 */
public Authentication verifyIdToken ( String idToken ) throws InvalidTokenException , TokenExpiredException { } } | CacheProvider cp = cp ( ) ; Authentication authc = cp . get ( idToken ) ; if ( null != authc ) { if ( ! authc . isExpired ( ) ) { return authc ; } else { cp . remove ( idToken ) ; } } // check is jwt token ?
boolean jwt = checkJwtToken ( idToken ) ; if ( jwt ) { authc = tp ( ) . verifyIdToken ( idToken ) ; } else { thr... |
public class YearQuarter { /** * Returns a copy of this year - quarter with the specified period in quarters added .
* This instance is immutable and unaffected by this method call .
* @ param quartersToAdd the quarters to add , may be negative
* @ return a { @ code YearQuarter } based on this year - quarter with... | if ( quartersToAdd == 0 ) { return this ; } long quarterCount = year * 4L + ( quarter . getValue ( ) - 1 ) ; long calcQuarters = quarterCount + quartersToAdd ; // safe overflow
int newYear = YEAR . checkValidIntValue ( Math . floorDiv ( calcQuarters , 4 ) ) ; int newQuarter = ( int ) Math . floorMod ( calcQuarters , 4 ... |
public class RowMaskedMatrix { /** * { @ inheritDoc } */
public void set ( int row , int col , double val ) { } } | backingMatrix . set ( getRealRow ( row ) , col , val ) ; |
public class Proxy { /** * Specifies whether to autodetect proxy settings .
* @ param autodetect set to true to use proxy auto detection , false to leave proxy settings
* unspecified
* @ return reference to self */
public Proxy setAutodetect ( boolean autodetect ) { } } | if ( this . autodetect == autodetect ) { return this ; } if ( autodetect ) { verifyProxyTypeCompatibility ( ProxyType . AUTODETECT ) ; this . proxyType = ProxyType . AUTODETECT ; } else { this . proxyType = ProxyType . UNSPECIFIED ; } this . autodetect = autodetect ; return this ; |
public class ArgumentCaptor { /** * Build a new < code > ArgumentCaptor < / code > .
* Note that an < code > ArgumentCaptor < / code > < b > * doesn ' t do any type checks * < / b > . It is only there to avoid casting
* in your code . This might however change ( type checks could be added ) in a
* future major re... | return new ArgumentCaptor < U > ( clazz ) ; |
public class sdx_license { /** * < pre >
* Converts API response of bulk operation into object and returns the object array in case of get request .
* < / pre > */
protected base_resource [ ] get_nitro_bulk_response ( nitro_service service , String response ) throws Exception { } } | sdx_license_responses result = ( sdx_license_responses ) service . get_payload_formatter ( ) . string_to_resource ( sdx_license_responses . class , response ) ; if ( result . errorcode != 0 ) { if ( result . errorcode == SESSION_NOT_EXISTS ) service . clear_session ( ) ; throw new nitro_exception ( result . message , r... |
public class DateControl { /** * $ NON - NLS - 1 $ */
@ Override public ObservableList < Item > getPropertySheetItems ( ) { } } | ObservableList < Item > items = super . getPropertySheetItems ( ) ; items . add ( new Item ( ) { @ Override public Optional < ObservableValue < ? > > getObservableValue ( ) { return Optional . of ( dateProperty ( ) ) ; } @ Override public void setValue ( Object value ) { setDate ( ( LocalDate ) value ) ; } @ Override p... |
public class JoinClient { /** * private boolean isSeedServer ( ServerBartender server )
* return ( ! " " . equals ( server . getAddress ( ) ) & & server . getPort ( ) > 0 ) ; */
private void startServer ( ServerHeartbeat server , ClusterHeartbeat cluster , Consumer < UpdateRackHeartbeat > consumer , JoinFuture future... | String address = server . getAddress ( ) ; int port = server . port ( ) ; if ( port <= 0 ) { throw new IllegalStateException ( String . valueOf ( server ) ) ; } if ( "" . equals ( address ) ) { address = "127.0.0.1" ; } int seedIndex = getSeedIndex ( server , cluster ) ; ServiceManagerClient client = createBartenderCli... |
public class TransactionImpl { /** * Upgrade the lock on the given object to the given lock mode . The call has
* no effect if the object ' s current lock is already at or above that level of
* lock mode .
* @ param obj object to acquire a lock on .
* @ param lockMode lock mode to acquire . The lock modes
* a... | if ( log . isDebugEnabled ( ) ) log . debug ( "lock object was called on tx " + this + ", object is " + obj . toString ( ) ) ; checkOpen ( ) ; RuntimeObject rtObject = new RuntimeObject ( obj , this ) ; lockAndRegister ( rtObject , lockMode , isImplicitLocking ( ) , getRegistrationList ( ) ) ; // if ( isImplicitLocking... |
public class ASTUtils { /** * returns null if specified varName annotation is not found */
private static String getEnumAnnotationFieldName ( IAnnotationBinding annotation , String varName ) { } } | if ( annotation == null ) { throw new NullPointerException ( ) ; } if ( varName == null ) { throw new NullPointerException ( ) ; } for ( IMemberValuePairBinding value : annotation . getDeclaredMemberValuePairs ( ) ) { if ( value . getName ( ) != null && value . getName ( ) . equals ( varName ) ) { assert value . getVal... |
public class WmfDumpFile { /** * Returns the absolute directory on the Web site where dumpfiles of the
* given type can be found .
* @ param dumpContentType
* the type of dump
* @ return relative web directory for the current dumpfiles
* @ throws IllegalArgumentException
* if the given dump file type is not... | if ( dumpContentType == DumpContentType . JSON ) { if ( "wikidatawiki" . equals ( projectName ) ) { return WmfDumpFile . DUMP_SITE_BASE_URL + WmfDumpFile . WEB_DIRECTORY . get ( dumpContentType ) + "wikidata" + "/" ; } else { throw new RuntimeException ( "Wikimedia Foundation uses non-systematic directory names for thi... |
public class JMLambda { /** * Group by two key map .
* @ param < T > the type parameter
* @ param < R1 > the type parameter
* @ param < R2 > the type parameter
* @ param collection the collection
* @ param classifier1 the classifier 1
* @ param classifier2 the classifier 2
* @ return the map */
public sta... | return collection . stream ( ) . collect ( groupingBy ( classifier1 , toMap ( classifier2 , t -> t ) ) ) ; |
public class FormData { /** * Returns the FormEntry for the given entryKey and index . This is the same as calling
* getFormEntry ( entryKey + index )
* @ see # getFormEntry ( String ) */
public FormEntry getFormEntry ( final String entryKey , final int index ) { } } | return getFormEntry ( entryKey + JFunkConstants . INDEXED_KEY_SEPARATOR + index ) ; |
public class CreatePhoneNumberOrderRequest { /** * List of phone numbers , in E . 164 format .
* @ param e164PhoneNumbers
* List of phone numbers , in E . 164 format . */
public void setE164PhoneNumbers ( java . util . Collection < String > e164PhoneNumbers ) { } } | if ( e164PhoneNumbers == null ) { this . e164PhoneNumbers = null ; return ; } this . e164PhoneNumbers = new java . util . ArrayList < String > ( e164PhoneNumbers ) ; |
public class JmxReporter { /** * Starts JmxReporter - registers all required beans in JMX bean server . */
public JmxReporter start ( ) { } } | SimonManagerMXBean simonManagerMXBean = new SimonManagerMXBeanImpl ( manager ) ; registerMXBean ( simonManagerMXBean , beanName ) ; if ( registerSimons ) { jmxRegisterCallback = new JmxRegisterCallback ( beanServer , simonDomain ) ; if ( registerExistingSimons ) { jmxRegisterCallback . setRegisterExisting ( true ) ; } ... |
public class ClassPathResource { /** * Get the input stream to the this resource , using the passed class loader
* only .
* @ param aClassLoader
* The class loader to be used . May not be < code > null < / code > .
* @ return < code > null < / code > if the path could not be resolved . */
@ Nullable public Inpu... | final URL aURL = getAsURLNoCache ( aClassLoader ) ; return _getInputStream ( m_sPath , aURL , aClassLoader ) ; |
public class TagsBuilder { /** * Add an additional tag value . */
public T withTag ( String k , Boolean v ) { } } | return withTag ( k , Boolean . toString ( v ) ) ; |
public class MultiColumnRelation { /** * Creates a multi - column EQ , LT , LTE , GT , or GTE relation .
* For example : " SELECT . . . WHERE ( a , b ) > ( 0 , 1 ) "
* @ param entities the columns on the LHS of the relation
* @ param relationType the relation operator
* @ param valuesOrMarker a Tuples . Literal... | assert relationType != Operator . IN ; return new MultiColumnRelation ( entities , relationType , valuesOrMarker , null , null ) ; |
public class ReceiptTemplateBuilder { /** * Adds a { @ link QuickReply } to the current object .
* @ param title
* the quick reply button label . It can ' t be empty .
* @ param payload
* the payload sent back when the button is pressed . It can ' t be
* empty .
* @ return this builder .
* @ see < a href ... | this . messageBuilder . addQuickReply ( title , payload ) ; return this ; |
public class FilterInstanceWrapper { /** * Destroys the filter wrapper and the underlying filter instance */
public void destroy ( ) throws ServletException { } } | try { // destroy the filter instance
_filterState = FILTER_STATE_DESTROYING ; for ( int i = 0 ; ( nServicing . get ( ) > 0 ) && i < 60 ; i ++ ) { try { if ( i == 0 ) { logger . logp ( Level . INFO , CLASS_NAME , "destroy" , "waiting.to.destroy.filter.[{0}]" , _filterName ) ; } Thread . sleep ( 1000 ) ; } catch ( Interr... |
public class JsonReader { /** * Reads a class implementing readable
* @ param < T > the type parameter
* @ param clazz the clazz
* @ return the t
* @ throws IOException the io exception */
protected < T > T readReadable ( Class < T > clazz ) throws IOException { } } | try { T object = Reflect . onClass ( clazz ) . allowPrivilegedAccess ( ) . create ( ) . get ( ) ; JsonSerializable readable = Cast . as ( object ) ; boolean isArray = JsonArraySerializable . class . isAssignableFrom ( clazz ) ; // ( object instanceof ArrayValue ) ;
if ( isArray && peek ( ) == JsonTokenType . BEGIN_ARRA... |
public class JKTableModel { public int getColunmIndexByName ( final String colName ) { } } | for ( final JKTableColumn col : this . tableColumns ) { if ( col . getName ( ) . equalsIgnoreCase ( colName ) ) { return col . getVisibleIndex ( ) ; } } return - 1 ; |
public class Substitutor { /** * { @ inheritDoc } */
public Generic onParameterizedType ( Generic parameterizedType ) { } } | Generic ownerType = parameterizedType . getOwnerType ( ) ; List < Generic > typeArguments = new ArrayList < Generic > ( parameterizedType . getTypeArguments ( ) . size ( ) ) ; for ( Generic typeArgument : parameterizedType . getTypeArguments ( ) ) { typeArguments . add ( typeArgument . accept ( this ) ) ; } return new ... |
public class CmsCssIcon { /** * Returns the icon HTML with the title attribute set . < p >
* @ param title the title to set
* @ return the icon HTML */
public String getHtml ( String title ) { } } | return "<span class=\"v-icon " + m_styleName + " " + m_additionalButtonStyle + "\" title=\"" + title + "\">&#x" + Integer . toHexString ( getCodepoint ( ) ) + ";</span>" ; |
public class DescribeOrganizationalUnitRequestMarshaller { /** * Marshall the given parameter object . */
public void marshall ( DescribeOrganizationalUnitRequest describeOrganizationalUnitRequest , ProtocolMarshaller protocolMarshaller ) { } } | if ( describeOrganizationalUnitRequest == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( describeOrganizationalUnitRequest . getOrganizationalUnitId ( ) , ORGANIZATIONALUNITID_BINDING ) ; } catch ( Exception e ) { throw new SdkClientExcepti... |
public class Arguments { /** * Gets any options specifying plugins to be run .
* @ return options for plugins */
public Set < List < String > > getPluginOpts ( ) { } } | String plugins = options . get ( Option . PLUGIN ) ; if ( plugins == null ) return Collections . emptySet ( ) ; Set < List < String > > pluginOpts = new LinkedHashSet < > ( ) ; for ( String plugin : plugins . split ( "\\x00" ) ) { pluginOpts . add ( List . from ( plugin . split ( "\\s+" ) ) ) ; } return Collections . u... |
public class lbpersistentsessions { /** * Use this API to fetch all the lbpersistentsessions resources that are configured on netscaler .
* This uses lbpersistentsessions _ args which is a way to provide additional arguments while fetching the resources . */
public static lbpersistentsessions [ ] get ( nitro_service ... | lbpersistentsessions obj = new lbpersistentsessions ( ) ; options option = new options ( ) ; option . set_args ( nitro_util . object_to_string_withoutquotes ( args ) ) ; lbpersistentsessions [ ] response = ( lbpersistentsessions [ ] ) obj . get_resources ( service , option ) ; return response ; |
public class ListSentimentDetectionJobsResult { /** * A list containing the properties of each job that is returned .
* < b > NOTE : < / b > This method appends the values to the existing list ( if any ) . Use
* { @ link # setSentimentDetectionJobPropertiesList ( java . util . Collection ) } or
* { @ link # withS... | if ( this . sentimentDetectionJobPropertiesList == null ) { setSentimentDetectionJobPropertiesList ( new java . util . ArrayList < SentimentDetectionJobProperties > ( sentimentDetectionJobPropertiesList . length ) ) ; } for ( SentimentDetectionJobProperties ele : sentimentDetectionJobPropertiesList ) { this . sentiment... |
public class TrmMessageFactoryImpl { /** * Create a new , empty TrmClientBootstrapReply message
* @ return The new TrmClientBootstrapReply .
* @ exception MessageCreateFailedException Thrown if such a message can not be created */
public TrmClientBootstrapReply createNewTrmClientBootstrapReply ( ) throws MessageCre... | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isEntryEnabled ( ) ) SibTr . entry ( tc , "createNewTrmClientBootstrapReply" ) ; TrmClientBootstrapReply msg = null ; try { msg = new TrmClientBootstrapReplyImpl ( ) ; } catch ( MessageDecodeFailedException e ) { /* No need to FFDC this as JsMsgObject will already h... |
public class TrmRouteDataImpl { /** * Get the originator SIBUuid from the message .
* Javadoc description supplied by TrmRouteData interface . */
public final SIBUuid8 getOriginator ( ) { } } | byte [ ] a = ( byte [ ] ) getPayload ( ) . getField ( TrmAccess . BODY_ROUTEDATA_ORIGINATOR ) ; if ( a != null ) { return new SIBUuid8 ( a ) ; } else { return null ; } |
public class AppServiceCertificateOrdersInner { /** * Get a certificate order .
* Get a certificate order .
* @ param resourceGroupName Name of the resource group to which the resource belongs .
* @ param certificateOrderName Name of the certificate order . .
* @ param serviceCallback the async ServiceCallback ... | return ServiceFuture . fromResponse ( getByResourceGroupWithServiceResponseAsync ( resourceGroupName , certificateOrderName ) , serviceCallback ) ; |
public class StatelessBeanO { /** * 456222 */
@ Override protected void initialize ( boolean reactivate ) throws RemoteException , InvocationTargetException { } } | final boolean isTraceOn = TraceComponent . isAnyTracingEnabled ( ) ; if ( isTraceOn && tc . isEntryEnabled ( ) ) Tr . entry ( tc , "initialize" ) ; // Set state to PRE _ CREATE so only methods that we permitted
// to be called setSessionContext or dependency injection
// ( e . g . getEJBHome ) are allowed and those met... |
public class StringUtil { /** * Method that implements a loose String compairon for encoding
* Strings . It will work like { @ link String # equalsIgnoreCase } ,
* except that it will also ignore all hyphen , underscore and
* space characters . */
public static boolean equalEncodings ( String str1 , String str2 )... | final int len1 = str1 . length ( ) ; final int len2 = str2 . length ( ) ; // Need to loop completely over both Strings
for ( int i1 = 0 , i2 = 0 ; i1 < len1 || i2 < len2 ; ) { int c1 = ( i1 >= len1 ) ? EOS : str1 . charAt ( i1 ++ ) ; int c2 = ( i2 >= len2 ) ? EOS : str2 . charAt ( i2 ++ ) ; // Can first do a quick comp... |
public class WebApp { /** * F743-31926 - refactored this method and added support for the SCI Extension Point .
* Initialize all of the ServletContainerINitializers including those
* from the SCI Extension Point . */
protected void initializeServletContainerInitializers ( DeployedModule moduleConfig ) { } } | if ( WCCustomProperties . DISABLE_SCI_FOR_PRE_V8_APPS && this . getVersionID ( ) < 30 ) { // don ' t do this for 2.5 apps
// don ' t handle SCIs for Servlet 2.5 and lower apps
logger . logp ( Level . FINE , CLASS_NAME , "initializeServletContainerInitializers" , "No processing of ServletContainerInitializers on applica... |
public class ScopeDesktopWindowManager { /** * Window */
public int getActiveQuickWindowId ( ) { } } | Response response = executeMessage ( DesktopWindowManagerMessage . GET_ACTIVE_WINDOW , null ) ; DesktopWindowID . Builder builder = DesktopWindowID . newBuilder ( ) ; buildPayload ( response , builder ) ; activeWindowId = builder . build ( ) . getWindowID ( ) ; return activeWindowId ; |
public class PorterStemmer { /** * / * step3 ( ) maps double suffices to single ones . so - ization ( = - ize plus
* - ation ) maps to - ize etc . note that the string before the suffix must give
* m ( ) > 0. */
private final void step3 ( ) { } } | if ( k == 0 ) return ; /* For Bug 1 */
switch ( sb . charAt ( k - 1 ) ) { case 'a' : if ( ends ( "ational" ) ) r ( "ate" ) ; else if ( ends ( "tional" ) ) r ( "tion" ) ; break ; case 'c' : if ( ends ( "enci" ) ) r ( "ence" ) ; else if ( ends ( "anci" ) ) r ( "ance" ) ; break ; case 'e' : if ( ends ( "izer" ) ) r ( "ize... |
public class ParallelTaskManager { /** * get current total used capacity .
* @ return the total used capacity */
public int getTotalUsedCapacity ( ) { } } | int totalCapacity = 0 ; for ( Entry < String , ParallelTask > entry : inprogressTaskMap . entrySet ( ) ) { ParallelTask task = entry . getValue ( ) ; if ( task != null ) totalCapacity += task . capacityUsed ( ) ; } return totalCapacity ; |
public class AfplibPackageImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
public EEnum getFontFidelityStpFntEx ( ) { } } | if ( fontFidelityStpFntExEEnum == null ) { fontFidelityStpFntExEEnum = ( EEnum ) EPackage . Registry . INSTANCE . getEPackage ( AfplibPackage . eNS_URI ) . getEClassifiers ( ) . get ( 162 ) ; } return fontFidelityStpFntExEEnum ; |
public class NotExpressionImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public NotificationChain eInverseRemove ( InternalEObject otherEnd , int featureID , NotificationChain msgs ) { } } | switch ( featureID ) { case SimpleExpressionsPackage . NOT_EXPRESSION__EXPRESSION : return basicSetExpression ( null , msgs ) ; } return super . eInverseRemove ( otherEnd , featureID , msgs ) ; |
public class SimpleReadWriteLock { /** * Execute the provided runnable in a write lock .
* @ param aRunnable
* Runnable to be executed . May not be < code > null < / code > . */
public void writeLocked ( @ Nonnull final Runnable aRunnable ) { } } | writeLock ( ) . lock ( ) ; try { aRunnable . run ( ) ; } finally { writeLock ( ) . unlock ( ) ; } |
public class Annotations { /** * Discover if a Method < b > m < / b > has been annotated with < b > type < / b > .
* @ param m The method to inspect .
* @ param type The targeted annotation class
* @ return True if annotation is present either on the method itself , or on the declaring class of the method .
* R... | boolean result = false ; if ( m . isAnnotationPresent ( type ) ) { result = true ; } else { for ( Annotation a : m . getAnnotations ( ) ) { if ( isAnnotationPresent ( a , type ) ) { result = true ; break ; } } } if ( ! result ) { result = isAnnotationPresent ( m . getDeclaringClass ( ) , type ) ; } return result ; |
public class LMAlgoFactoryDecorator { /** * This method creates the landmark storages ready for landmark creation . */
public void createPreparations ( GraphHopperStorage ghStorage , LocationIndex locationIndex ) { } } | if ( ! isEnabled ( ) || ! preparations . isEmpty ( ) ) return ; if ( weightings . isEmpty ( ) ) throw new IllegalStateException ( "No landmark weightings found" ) ; List < LandmarkSuggestion > lmSuggestions = new ArrayList < > ( lmSuggestionsLocations . size ( ) ) ; if ( ! lmSuggestionsLocations . isEmpty ( ) ) { try {... |
public class BitmapUtils { /** * Write the given bitmap to a file in the external storage . Requires
* " android . permission . WRITE _ EXTERNAL _ STORAGE " permission . */
public static void writeToFile ( Bitmap bitmap , String dir , String filename ) throws FileNotFoundException , IOException { } } | File sdCard = Environment . getExternalStorageDirectory ( ) ; File dirFile = new File ( sdCard . getAbsolutePath ( ) + "/" + dir ) ; dirFile . mkdirs ( ) ; File f = new File ( dirFile , filename ) ; FileOutputStream fos = new FileOutputStream ( f , false ) ; bitmap . compress ( CompressFormat . PNG , 100 /* ignored for... |
public class CommercePriceListPersistenceImpl { /** * Returns the last commerce price list in the ordered set where displayDate & lt ; & # 63 ; and status = & # 63 ; .
* @ param displayDate the display date
* @ param status the status
* @ param orderByComparator the comparator to order the set by ( optionally < c... | CommercePriceList commercePriceList = fetchByLtD_S_Last ( displayDate , status , orderByComparator ) ; if ( commercePriceList != null ) { return commercePriceList ; } StringBundler msg = new StringBundler ( 6 ) ; msg . append ( _NO_SUCH_ENTITY_WITH_KEY ) ; msg . append ( "displayDate=" ) ; msg . append ( displayDate ) ... |
public class NeedleRule { /** * Encloses the added rule .
* @ param rule
* - outer method rule
* @ return { @ link NeedleRule } */
public NeedleRule withOuter ( final MethodRule rule ) { } } | if ( rule instanceof InjectionProvider ) { addInjectionProvider ( ( InjectionProvider < ? > ) rule ) ; } methodRuleChain . add ( 0 , rule ) ; return this ; |
public class CPDisplayLayoutLocalServiceBaseImpl { /** * Deletes the cp display layout with the primary key from the database . Also notifies the appropriate model listeners .
* @ param CPDisplayLayoutId the primary key of the cp display layout
* @ return the cp display layout that was removed
* @ throws PortalEx... | return cpDisplayLayoutPersistence . remove ( CPDisplayLayoutId ) ; |
public class SRTInputStream31 { /** * Call into the HttpInputStream to find out the result of their available call ,
* which returns how much data , if any , is available in the current buffer .
* If there is more than 0 bytes of data we return true */
private boolean checkAvailable ( ) { } } | int i = 0 ; try { i = this . in . available ( ) ; if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "Current amount immediately available in buffers : " + i ) ; } } catch ( Exception e ) { if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debu... |
public class AuthleteApiImpl { /** * Create a { @ link BasicCredentials } for the service . */
private static BasicCredentials createServiceCredentials ( AuthleteConfiguration configuration ) { } } | // API key and API secret of a Service .
String key = configuration . getServiceApiKey ( ) ; String secret = configuration . getServiceApiSecret ( ) ; return new BasicCredentials ( key , secret ) ; |
public class CommerceDiscountUserSegmentRelPersistenceImpl { /** * Returns the commerce discount user segment rels before and after the current commerce discount user segment rel in the ordered set where commerceUserSegmentEntryId = & # 63 ; .
* @ param commerceDiscountUserSegmentRelId the primary key of the current ... | CommerceDiscountUserSegmentRel commerceDiscountUserSegmentRel = findByPrimaryKey ( commerceDiscountUserSegmentRelId ) ; Session session = null ; try { session = openSession ( ) ; CommerceDiscountUserSegmentRel [ ] array = new CommerceDiscountUserSegmentRelImpl [ 3 ] ; array [ 0 ] = getByCommerceUserSegmentEntryId_PrevA... |
public class SerializerIntrinsics { /** * Round Packed DP - FP Values ( SSE4.1 ) . */
public final void roundpd ( XMMRegister dst , XMMRegister src , Immediate imm8 ) { } } | emitX86 ( INST_ROUNDPD , dst , src , imm8 ) ; |
public class MBLinkObjectFactory { /** * d702400 */
private void callLifecycleInterceptors ( Class < ? > mbClass , Object mbInstance ) throws InjectionException { } } | Collection < MethodInfo > methods = MethodMap . getAllDeclaredMethods ( mbClass ) ; for ( MethodInfo methodInfo : methods ) { Method method = methodInfo . getMethod ( ) ; PostConstruct postConstruct = method . getAnnotation ( PostConstruct . class ) ; if ( postConstruct != null ) { method . setAccessible ( true ) ; val... |
public class Grammar { /** * Adds new rule if the same rule doesn ' t exist already .
* @ param nonterminal Left hand side of the rule .
* @ param rhs */
public void addRule ( String nonterminal , List < String > rhs ) { } } | addRule ( null , nonterminal , "" , false , rhs ) ; |
public class NamespaceChangeStreamListener { /** * Opens the stream in a background thread . */
public void start ( ) { } } | nsLock . writeLock ( ) . lock ( ) ; try { if ( runnerThread != null ) { return ; } runnerThread = new Thread ( new NamespaceChangeStreamRunner ( new WeakReference < > ( this ) , networkMonitor , logger ) ) ; runnerThread . start ( ) ; } finally { nsLock . writeLock ( ) . unlock ( ) ; } |
public class DoubleArrayList { /** * Returns a new list of the part of the receiver between < code > from < / code > , inclusive , and < code > to < / code > , inclusive .
* @ param from the index of the first element ( inclusive ) .
* @ param to the index of the last element ( inclusive ) .
* @ return a new list... | if ( size == 0 ) return new DoubleArrayList ( 0 ) ; checkRangeFromTo ( from , to , size ) ; double [ ] part = new double [ to - from + 1 ] ; System . arraycopy ( elements , from , part , 0 , to - from + 1 ) ; return new DoubleArrayList ( part ) ; |
public class GenJsCodeVisitor { /** * Generates the module imports and aliasing . This generates code like the following :
* < pre >
* var $ import1 = goog . require ( ' some . namespace ' ) ;
* var $ templateAlias1 = $ import1 . tmplOne ;
* var $ templateAlias2 = $ import1 . tmplTwo ;
* var $ import2 = goog ... | int counter = 1 ; // Get all the unique calls in the file .
Set < String > calls = new HashSet < > ( ) ; for ( CallBasicNode callNode : SoyTreeUtils . getAllNodesOfType ( soyFile , CallBasicNode . class ) ) { calls . add ( callNode . getCalleeName ( ) ) ; } // Map all the unique namespaces to the templates in those nam... |
public class HashMapImpl { /** * Puts a new item in the cache .
* @ param key key to store data
* @ param value value to be stored
* @ return old value stored under the key */
@ Override public V put ( K key , V value ) { } } | if ( key == null ) { V item = _nullValue ; _nullValue = value ; return item ; } // forced resizing if 1/2 full
if ( _values . length <= 2 * _size ) { K [ ] oldKeys = _keys ; V [ ] oldValues = _values ; _keys = ( K [ ] ) new Object [ 2 * oldKeys . length ] ; _values = ( V [ ] ) new Object [ 2 * oldValues . length ] ; _m... |
public class OidcUserInfoController { /** * Obtain an OIDC Id token for the specified < code > client _ id < / code > . At least one bean of type
* { @ link OAuthClient } is required to use this endpoint .
* < p > This token strategy supports Spring ' s < code > OAuth2RestTemplate < / code > for accessing
* uPort... | /* * NB : Several of this method ' s parameters are not consumed ( yet ) in any way . They are
* defined to match a two - legged OAuth strategy and for future use . */
final String msg = "Processing request for OAuth access token; client_id='{}', client_secret='{}', " + "grant_type='{}', scope='{}', claims='{}', gro... |
public class CTCImpl { /** * < ! - - begin - user - doc - - >
* < ! - - end - user - doc - - >
* @ generated */
@ Override public void eUnset ( int featureID ) { } } | switch ( featureID ) { case AfplibPackage . CTC__CON_DATA : setConData ( CON_DATA_EDEFAULT ) ; return ; } super . eUnset ( featureID ) ; |
public class Gaussian98Reader { /** * Select the theory and basis set from the first archive line .
* @ param line Description of the Parameter
* @ return Description of the Return Value */
private String parseLevelOfTheory ( String line ) { } } | StringBuffer summary = new StringBuffer ( ) ; summary . append ( line ) ; try { do { line = input . readLine ( ) . trim ( ) ; summary . append ( line ) ; } while ( ! ( line . indexOf ( '@' ) >= 0 ) ) ; } catch ( Exception exc ) { logger . debug ( "syntax problem while parsing summary of g98 section: " ) ; logger . debu... |
public class TopicAdminClient { /** * Gets the configuration of a topic .
* < p > Sample code :
* < pre > < code >
* try ( TopicAdminClient topicAdminClient = TopicAdminClient . create ( ) ) {
* ProjectTopicName topic = ProjectTopicName . of ( " [ PROJECT ] " , " [ TOPIC ] " ) ;
* Topic response = topicAdminC... | GetTopicRequest request = GetTopicRequest . newBuilder ( ) . setTopic ( topic == null ? null : topic . toString ( ) ) . build ( ) ; return getTopic ( request ) ; |
public class H2StreamProcessor { /** * Read the HTTP header and data bytes for this stream
* @ param numBytes the number of bytes to read
* @ param requestBuffers an array of buffers to copy the read data into
* @ return this stream ' s VirtualConnection or null if too many bytes were requested */
@ SuppressWarni... | if ( TraceComponent . isAnyTracingEnabled ( ) && tc . isDebugEnabled ( ) ) { Tr . debug ( tc , "read entry: stream " + myID + " request: " + requestBuffers + " num bytes requested: " + numBytes ) ; } long streamByteCount = streamReadSize ; // number of bytes available on this stream
long requestByteCount = bytesRemaini... |
public class JmxClient { /** * Return the value of a JMX attribute . */
public Object getAttribute ( ObjectName name , String attributeName ) throws Exception { } } | checkClientConnected ( ) ; return mbeanConn . getAttribute ( name , attributeName ) ; |
public class FileManagerImpl { /** * Save userdata in parm 1 under unique serial number from parm2.
* @ param instanceid This is the unique identifier for this userdata
* @ param data This is the data associated with the instanceid
* @ return true if the data is stored , false if the serial number is 0
* @ thro... | if ( instanceid == 0 ) { return false ; } for ( int i = 0 ; i < NUM_USER_WORDS ; i ++ ) { if ( userData [ i ] [ 0 ] == instanceid ) { userData [ i ] [ 1 ] = data ; writeUserData ( i ) ; return true ; } } // If we fall through then this is the first time . Now search for an
// opening .
for ( int i = 0 ; i < NUM_USER_WO... |
public class ProxyHelper { /** * Checks if the proxied entity has been fetched .
* @ param entity the entity to check
* @ return true if the proxy has been fetched . */
public static boolean isFetched ( final Object entity ) { } } | return entity == null || ! isProxy ( entity ) || asProxy ( entity ) . __isFetched ( ) ; |
public class DiskMarshaller { /** * Marshall the given parameter object . */
public void marshall ( Disk disk , ProtocolMarshaller protocolMarshaller ) { } } | if ( disk == null ) { throw new SdkClientException ( "Invalid argument passed to marshall(...)" ) ; } try { protocolMarshaller . marshall ( disk . getDiskId ( ) , DISKID_BINDING ) ; protocolMarshaller . marshall ( disk . getDiskPath ( ) , DISKPATH_BINDING ) ; protocolMarshaller . marshall ( disk . getDiskNode ( ) , DIS... |
public class sslpolicy { /** * Use this API to add sslpolicy . */
public static base_response add ( nitro_service client , sslpolicy resource ) throws Exception { } } | sslpolicy addresource = new sslpolicy ( ) ; addresource . name = resource . name ; addresource . rule = resource . rule ; addresource . reqaction = resource . reqaction ; addresource . action = resource . action ; addresource . undefaction = resource . undefaction ; addresource . comment = resource . comment ; return a... |
public class RawPacket { /** * Read a byte region from specified offset with specified length
* @ param off start offset of the region to be read
* @ param len length of the region to be read
* @ return byte array of [ offset , offset + length ) */
public byte [ ] readRegion ( int off , int len ) { } } | this . buffer . rewind ( ) ; if ( off < 0 || len <= 0 || off + len > this . buffer . limit ( ) ) { return null ; } byte [ ] region = new byte [ len ] ; this . buffer . get ( region , off , len ) ; return region ; |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.