query
stringlengths
74
6.1k
positive
sequencelengths
1
1
negative
sequencelengths
9
9
public int getNumWeights() { if (weights == null) return 0; int numWeights = 0; for (double[] wts : weights) { numWeights += wts.length; } return numWeights; }
[ "Returns the total number of weights associated with this classifier.\n\n@return number of weights" ]
[ "Returns the list of store defs as a map\n\n@param storeDefs\n@return", "Returns a non-validating XML parser. The parser ignores both DTDs and XSDs.\n\n@return An XML parser in the form of a DocumentBuilder", "Use this API to fetch all the bridgetable resources that are configured on netscaler.", "Retrieve configuration details for a given custom field.\n\n@param field required custom field\n@return configuration detail", "Appends to the statement table and all tables joined to it.\n@param alias the table alias\n@param where append conditions for WHERE clause here", "ceiling for clipped RELU, alpha for ELU", "Build control archive of the deb\n\n@param packageControlFile the package control file\n@param controlFiles the other control information files (maintainer scripts, etc)\n@param dataSize the size of the installed package\n@param checksums the md5 checksums of the files in the data archive\n@param output\n@return\n@throws java.io.FileNotFoundException\n@throws java.io.IOException\n@throws java.text.ParseException", "Gets the interpolated text of a query from cache. If key does not exist, an exception is thrown.\n\n@param key\nname of the query\n@return the query text", "Boyer Moore scan that proceeds backwards from the end of the file looking for ENDSIG\n@throws NonScannableZipException" ]
public static lbvserver[] get_filtered(nitro_service service, filtervalue[] filter) throws Exception{ lbvserver obj = new lbvserver(); options option = new options(); option.set_filter(filter); lbvserver[] response = (lbvserver[]) obj.getfiltered(service, option); return response; }
[ "Use this API to fetch filtered set of lbvserver resources.\nset the filter parameter values in filtervalue object." ]
[ "Copies entries in the source map to target map.\n\n@param source source map\n@param target target map", "Creates a resource key for given enumeration value. By convention,\nresource bundle for enumerations has the name of enumeration class\nand value identifier is the same as enumeration value name.\n@param value the enumeration value\n@return the resource key", "Print the String features generated from a IN", "Utils for making collections out of arrays of primitive types.", "Scans given directory for files passing given filter, adds the results into given list.", "Use this API to sync gslbconfig.", "Throws an IllegalStateException when the given value is not false.", "Checks if a given number is in the range of a byte.\n\n@param number\na number which should be in the range of a byte (positive or negative)\n\n@see java.lang.Byte#MIN_VALUE\n@see java.lang.Byte#MAX_VALUE\n\n@return number as a byte (rounding might occur)", "compute Exp using Taylor Series.\n\n@param x An angle, in radians.\n@param nTerms Number of terms.\n@return Result." ]
private void cleanUpAction() { try { m_model.deleteDescriptorIfNecessary(); } catch (CmsException e) { LOG.error(m_messages.key(Messages.ERR_DELETING_DESCRIPTOR_0), e); } // unlock resource m_model.unlock(); }
[ "Unlock all edited resources." ]
[ "Returns the index descriptor definition of the given name if it exists.\n\n@param name The name of the index\n@return The index descriptor definition or <code>null</code> if there is no such index", "Constructs and sets the layout parameters to have some gravity.\n\n@param gravity the gravity of the Crouton\n@return <code>this</code>, for chaining.\n@see android.view.Gravity", "returns a collection of Reader LockEntries for object obj.\nIf no LockEntries could be found an empty Vector is returned.", "Remove all references to a groupId\n\n@param groupIdToRemove ID of group", "Add a shutdown listener, which gets called when all requests completed on shutdown.\n\n@param listener the shutdown listener", "Validates specialization if this bean specializes another bean.", "Retrieve a child record by name.\n\n@param key child record name\n@return child record", "Returns the expected name of a workspace for a given suffix\n@param suffix\n@return", "Loads the Configuration from the properties file.\n\nLoads the properties file, or uses defaults on failure.\n\n@see org.apache.ojb.broker.util.configuration.impl.ConfigurationAbstractImpl#setFilename(java.lang.String)" ]
public String updateClassification(String classificationType) { Metadata metadata = new Metadata("enterprise", Metadata.CLASSIFICATION_TEMPLATE_KEY); metadata.add("/Box__Security__Classification__Key", classificationType); Metadata classification = this.updateMetadata(metadata); return classification.getString(Metadata.CLASSIFICATION_KEY); }
[ "Updates a metadata classification on the specified file.\n\n@param classificationType the metadata classification type.\n@return the new metadata classification type updated on the file." ]
[ "get all consumers for the group\n\n@param zkClient the zookeeper client\n@param group the group name\n@return topic-&gt;(consumerIdStringA-0,consumerIdStringA-1...consumerIdStringB-0,consumerIdStringB-1)", "Use this API to add vpath.", "Save the current file as the given type.\n\n@param file target file\n@param type file type", "Return the item view type used by the adapter to implement recycle mechanism.\n\n@param content to be rendered.\n@return an integer that represents the renderer inside the adapter.", "Specify the class represented by this `ClassNode` is annotated\nby an annotation class specified by the name\n@param name the name of the annotation class\n@return this `ClassNode` instance", "Associate a type with the given resource model.", "Processes the template if the property value of the current object on the specified level equals the given value.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException If an error occurs\[email protected] type=\"block\"\[email protected] name=\"level\" optional=\"false\" description=\"The level for the current object\"\nvalues=\"class,field,reference,collection\"\[email protected] name=\"name\" optional=\"false\" description=\"The name of the property\"\[email protected] name=\"value\" optional=\"false\" description=\"The value to check for\"\[email protected] name=\"default\" optional=\"true\" description=\"A default value to use if the property\nis not defined\"", "Handle a whole day change event.\n@param event the change event.", "2-D Perlin noise function.\n\n@param x X Value.\n@param y Y Value.\n@return Returns function's value at point xy." ]
public static base_responses restore(nitro_service client, appfwprofile resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { appfwprofile restoreresources[] = new appfwprofile[resources.length]; for (int i=0;i<resources.length;i++){ restoreresources[i] = new appfwprofile(); restoreresources[i].archivename = resources[i].archivename; } result = perform_operation_bulk_request(client, restoreresources,"restore"); } return result; }
[ "Use this API to restore appfwprofile resources." ]
[ "Takes a date, and retrieves the next business day\n\n@param dateString the date\n@param onlyBusinessDays only business days\n@return a string containing the next business day", "Get a message bundle of the given type.\n\n@param type the bundle type class\n\n@return the bundle", "Copy the data from an InputStream to a temp file.\n\n@param inputStream data source\n@param tempFileSuffix suffix to use for temp file\n@return File instance", "Returns all the version directories present in the root directory\nspecified\n\n@param rootDir The parent directory\n@param maxId The\n@return An array of version directories", "Use this API to update filterhtmlinjectionparameter.", "Returns a sampling of the source at the specified line and column,\nof null if it is unavailable.", "Submit a command to the server.\n\n@param command The CLI command\n@return The DMR response as a ModelNode\n@throws CommandFormatException\n@throws IOException", "Use this API to enable nsacl6 of given name.", "This essentially ensures that we only store a single Vertex for each unique \"Set\" of tags." ]
public PhotoList<Photo> getContactsPublicPhotos(String userId, int count, boolean justFriends, boolean singlePhoto, boolean includeSelf) throws FlickrException { return getContactsPublicPhotos(userId, Extras.MIN_EXTRAS, count, justFriends, singlePhoto, includeSelf); }
[ "Get public photos from the user's contacts.\n\nThis method does not require authentication.\n\n@see com.flickr4java.flickr.photos.Extras\n@param userId\nThe user ID\n@param count\nThe number of photos to return\n@param justFriends\nTrue to include friends\n@param singlePhoto\nTrue to get a single photo\n@param includeSelf\nTrue to include self\n@return A collection of Photo objects\n@throws FlickrException" ]
[ "Converts a vector from eigen space into sample space.\n\n@param eigenData Eigen space data.\n@return Sample space projection.", "Reads a file and returns the result in a String\n\n@param file File\n@return String\n@throws IOException", "Returns the class hierarchy of the given type, from bottom to top, starting with the given class itself.\nInterfaces are not included.\n\n@param clazz the class of interest\n@return the class hierarchy of the given class", "Retrieve multiple properties.\n\n@param method method definition\n@param object target object\n@param map parameter values", "Returns a new created connection\n\n@param jcd the connection descriptor\n@return an instance of Connection from the drivermanager", "Initializes module enablement.\n\n@see ModuleEnablement", "Returns the class hierarchy of the given type, from bottom to top, starting with the given class itself.\nInterfaces are not included.\n\n@param clazz the class of interest\n@return the class hierarchy of the given class", "Get a list of referrers from a given domain to a user's photostream.\n\n@param date\n(Required) Stats will be returned for this date. A day according to Flickr Stats starts at midnight GMT for all users, and timestamps will\nautomatically be rounded down to the start of the day.\n@param domain\n(Required) The domain to return referrers for. This should be a hostname (eg: \"flickr.com\") with no protocol or pathname.\n@param perPage\n(Optional) Number of domains to return per page. If this argument is omitted, it defaults to 25. The maximum allowed value is 100.\n@param page\n(Optional) The page of results to return. If this argument is omitted, it defaults to 1.\n@see \"http://www.flickr.com/services/api/flickr.stats.getPhotostreamReferrers.html\"", "Returns the compact tag records for all tags in the workspace.\n\n@param workspace The workspace or organization to find tags in.\n@return Request object" ]
public QueryBuilder<T, ID> groupBy(String columnName) { FieldType fieldType = verifyColumnName(columnName); if (fieldType.isForeignCollection()) { throw new IllegalArgumentException("Can't groupBy foreign collection field: " + columnName); } addGroupBy(ColumnNameOrRawSql.withColumnName(columnName)); return this; }
[ "Add \"GROUP BY\" clause to the SQL query statement. This can be called multiple times to add additional \"GROUP BY\"\nclauses.\n\n<p>\nNOTE: Use of this means that the resulting objects may not have a valid ID column value so cannot be deleted or\nupdated.\n</p>" ]
[ "Wrapped version of standard jdbc executeUpdate Pays attention to DB\nlocked exception and waits up to 1s\n\n@param query SQL query to execute\n@throws Exception - will throw an exception if we can never get a lock", "Updates the date and time formats.\n\n@param properties project properties", "Generates a full list of all parents and their children, in order. Uses Map to preserve\nlast expanded state.\n\n@param parentList A list of the parents from\nthe {@link ExpandableRecyclerAdapter}\n@param savedLastExpansionState A map of the last expanded state for a given parent key.\n@return A list of all parents and their children, expanded accordingly", "Setter for property value. Doesn't affect entity version and doesn't\ninvalidate any of the cached entity iterables.\n\n@param localId entity local id.\n@param value property value.\n@param oldValue property old value\n@param propertyId property id", "Reads the text files in the given directory and puts their content\nin the given map after compressing it. Note that this method does not\ntraverse recursivly into sub-directories.\n\n@param dir The directory to process\n@param results Map that will receive the contents (indexed by the relative filenames)\n@throws IOException If an error ocurred", "Read an individual remark type from a Gantt Designer file.\n\n@param remark remark type", "Returns a raw handle to the SQLite database connection. Do not close!\n@param context A context, which is used to (when needed) set up a connection to the database\n@return The single, unique connection to the database, as is (also) used by our Cupboard instance", "Update the context session to mark a user logged in\n\n@param userIdentifier\nthe user identifier, could be either userId or username", "Use this API to flush cacheobject." ]
public void delete() { BoxAPIConnection api = this.getAPI(); URL url = COLLABORATION_WHITELIST_ENTRY_URL_TEMPLATE.build(api.getBaseURL(), this.getID()); BoxAPIRequest request = new BoxAPIRequest(api, url, HttpMethod.DELETE); BoxAPIResponse response = request.send(); response.disconnect(); }
[ "Deletes this collaboration whitelist." ]
[ "Get the underlying channel. This may block until the channel is set.\n\n@return the channel\n@throws IOException for any error", "Add a listener to be invoked when the checked button changes in this group.\n@param listener\n@param <T>\n@return", "Returns the associated SQL WHERE statement.", "Most complete output", "all objects in list1 that are not in list2\n\n@param <T>\n@param list1\nFirst collection\n@param list2\nSecond collection\n@return The collection difference list1 - list2", "Returns the Set of entities recognized by this Classifier.\n\n@return The Set of entities recognized by this Classifier.", "Return the score of the specified element of the sorted set at key.\n@param member\n@return The score value or <code>null</code> if the element does not exist in the set.", "Attach a script file to a scriptable target.\n\n@param target The scriptable target.\n@param scriptFile The script file object.", "Gets the thread usage.\n\n@return the thread usage" ]
public void load(String soundFile) { if (mSoundFile != null) { unload(); } mSoundFile = soundFile; if (mAudioListener != null) { mAudioListener.getAudioEngine().preloadSoundFile(soundFile); Log.d("SOUND", "loaded audio file %s", getSoundFile()); } }
[ "Preloads a sound file.\n\n@param soundFile path/name of the file to be played." ]
[ "Process start.\n\n@param endpoint the endpoint\n@param eventType the event type", "For a particular stealer node find all the primary partitions tuples it\nwill steal.\n\n@param currentCluster The cluster definition of the existing cluster\n@param finalCluster The final cluster definition\n@param stealNodeId Node id of the stealer node\n@return Returns a list of primary partitions which this stealer node will\nget", "Create an element that represents a horizntal or vertical line.\n@param x1\n@param y1\n@param x2\n@param y2\n@return the created DOM element", "Generate debug dump of the tree from the scene object.\nIt should include a newline character at the end.\n\n@param sb the {@code StringBuffer} to dump the object.\n@param indent indentation level as number of spaces.", "Returns PatternParser used to parse the conversion string. Subclasses may\noverride this to return a subclass of PatternParser which recognize\ncustom conversion characters.\n\n@since 0.9.0", "Write a comma to the output stream if required.", "Returns a compact representation of all of the subtasks of a task.\n\n@param task The task to get the subtasks of.\n@return Request object", "Generate the init script from the Artifactory URL.\n\n@return The generated script.", "Return a list of unique namespaces, optionally limited by a given predicate, in alphabetical order.\n\nThis method does not require authentication.\n\n@param predicate\n@param perPage\n@param page\n@return NamespacesList\n@throws FlickrException" ]
public void updateShownOptions(boolean showModeSwitch, boolean showAddKeyOption) { if (showModeSwitch != m_showModeSwitch) { m_upperLeftComponent.removeAllComponents(); m_upperLeftComponent.addComponent(m_languageSwitch); if (showModeSwitch) { m_upperLeftComponent.addComponent(m_modeSwitch); } m_upperLeftComponent.addComponent(m_filePathLabel); m_showModeSwitch = showModeSwitch; } if (showAddKeyOption != m_showAddKeyOption) { if (showAddKeyOption) { m_optionsComponent.addComponent(m_lowerLeftComponent, 0, 1); m_optionsComponent.addComponent(m_lowerRightComponent, 1, 1); } else { m_optionsComponent.removeComponent(0, 1); m_optionsComponent.removeComponent(1, 1); } m_showAddKeyOption = showAddKeyOption; } }
[ "Update which options are shown.\n@param showModeSwitch flag, indicating if the mode switch should be shown.\n@param showAddKeyOption flag, indicating if the \"Add key\" row should be shown." ]
[ "Process a beat packet, potentially updating the master tempo and sending our listeners a master\nbeat notification. Does nothing if we are not active.", "Converts a submatrix into an extract matrix operation.\n@param variableTarget The variable in which the submatrix is extracted from", "Gets the file from which boot operations should be parsed.\n@return the file. Will not be {@code null}", "Initialize the connection with the specified properties in OJB\nconfiguration files and platform depended properties.\nInvoke this method after a NEW connection is created, not if re-using from pool.\n\n@see org.apache.ojb.broker.platforms.PlatformFactory\n@see org.apache.ojb.broker.platforms.Platform", "Permanently close the ClientRequestExecutor pool. Resources subsequently\nchecked in will be destroyed.", "Use this API to fetch authenticationlocalpolicy_authenticationvserver_binding resources of given name .", "Handle interval change.\n@param event the change event.", "Copy the contents of the given String to the given output Writer.\nCloses the writer when done.\n@param in the String to copy from\n@param out the Writer to copy to\n@throws IOException in case of I/O errors", "ends the request and clears the cache. This can be called before the request is over,\nin which case the cache will be unavailable for the rest of the request." ]
public static base_responses enable(nitro_service client, String trapname[]) throws Exception { base_responses result = null; if (trapname != null && trapname.length > 0) { snmpalarm enableresources[] = new snmpalarm[trapname.length]; for (int i=0;i<trapname.length;i++){ enableresources[i] = new snmpalarm(); enableresources[i].trapname = trapname[i]; } result = perform_operation_bulk_request(client, enableresources,"enable"); } return result; }
[ "Use this API to enable snmpalarm resources of given names." ]
[ "This method writes assignment data to a Planner file.", "Call the Yahoo! PlaceFinder service for a result.\n\n@param q\nsearch string\n@param maxRows\nmax number of rows in result, or 0 for all\n@param locale\nlocale for strings\n@return list of found results\n@throws Exception\noops\n@see <a\nhref=\"http://developer.yahoo.com/boss/geo/docs/free_YQL.html#table_pf\">Yahoo!\nBoss Geo PlaceFinder</a>", "Remove any overrides for an endpoint\n\n@param pathValue path (endpoint) value\n@param requestType path request type. \"GET\", \"POST\", etc\n@return true if success, false otherwise", "Computes the inner product of A times A and stores the results in B. The inner product is symmetric and this\nfunction will only store the lower triangle. The value of the upper triangular matrix is undefined.\n\n<p>B = A<sup>T</sup>*A</sup>\n\n@param A (Input) Matrix\n@param B (Output) Storage for output.", "Overridden to add transform.", "Deletes specified entity clearing all its properties and deleting all its outgoing links.\n\n@param entity to delete.", "This method is used to initiate a release staging process using the Artifactory Release Staging API.", "Overloads the left shift operator to provide syntactic sugar for appending to a StringBuilder.\n\n@param self a StringBuilder\n@param value an Object\n@return the original StringBuilder\n@since 1.8.2", "Compute \"sent\" date\n\n@param msg Message to take sent date from. May be null to use default\n@param defaultVal Default if sent date is not present\n@return Sent date or now if no date could be found" ]
private YearWeek with(int newYear, int newWeek) { if (year == newYear && week == newWeek) { return this; } return of(newYear, newWeek); }
[ "Returns a copy of this year-week with the new year and week, checking\nto see if a new object is in fact required.\n\n@param newYear the year to represent, validated from MIN_YEAR to MAX_YEAR\n@param newWeek the week to represent, validated from 1 to 53\n@return the year-week, not null" ]
[ "Try to extract a numeric version from a collection of strings.\n\n@param versionStrings Collection of string properties.\n@return The version string if exists in the collection.", "Resolves the POM for the specified parent.\n\n@param parent the parent coordinates to resolve, must not be {@code null}\n@return The source of the requested POM, never {@code null}\n@since Apache-Maven-3.2.2 (MNG-5639)", "Remove the given pair into the map.\n\n<p>\nIf the given key is inside the map, but is not mapped to the given value, the\nmap will not be changed.\n</p>\n\n@param <K> type of the map keys.\n@param <V> type of the map values.\n@param map the map to update.\n@param entry the entry (key, value) to remove from the map.\n@return {@code true} if the pair was removed.\n@since 2.15", "Parse duration represented in thousandths of minutes.\n\n@param properties project properties\n@param value duration value\n@param targetTimeUnit required output time units\n@return Duration instance", "add trace information for received frame", "Get random geographical location\n@return 2-Tuple of ints (latitude, longitude)", "refresh all deliveries dependencies for a particular product", "Sends the events to monitoring service client.\n\n@param events the events", "Shutdown the socket server" ]
@Override protected final void subAppend(final LoggingEvent event) { if (event instanceof ScheduledFileRollEvent) { // the scheduled append() call has been made by a different thread synchronized (this) { if (this.closed) { // just consume the event return; } this.rollFile(event); } } else if (event instanceof FileRollEvent) { // definitely want to avoid rolling here whilst a file roll event is still being handled super.subAppend(event); } else { if(event instanceof FoundationLof4jLoggingEvent){ FoundationLof4jLoggingEvent foundationLof4jLoggingEvent = (FoundationLof4jLoggingEvent)event; foundationLof4jLoggingEvent.setAppenderName(this.getName()); } this.rollFile(event); super.subAppend(event); } }
[ "Responsible for executing file rolls as and when required, in addition to\ndelegating to the super class to perform the actual append operation.\nSynchronized for safety during enforced file roll.\n\n@see org.apache.log4j.WriterAppender#subAppend(org.apache.log4j.spi.LoggingEvent)" ]
[ "Retrieve the var data key for a specific field.\n\n@param type field type\n@return var data key", "Returns a representation of the date from the value attributes as ISO\n8601 encoding.\n\n@param value\n@return ISO 8601 value (String)", "Generates a schedule based on some meta data. The schedule generation\nconsiders short periods. Date rolling is ignored.\n\n@param referenceDate The date which is used in the schedule to internally convert dates to doubles, i.e., the date where t=0.\n@param startDate The start date of the first period.\n@param frequency The frequency.\n@param maturity The end date of the last period.\n@param daycountConvention The daycount convention.\n@param shortPeriodConvention If short period exists, have it first or last.\n@return The corresponding schedule\n@deprecated Will be removed in version 2.3", "helper function to convert strings to bytes as needed.\n\n@param key\n@param value", "This is private. It is a helper function for the utils.", "Converts the http entity to string. If entity is null, returns empty string.\n@param entity\n@return\n@throws IOException", "Helper to get locale specific properties.\n\n@return the locale specific properties map.", "Create and serialize a WorkerStatus for a pause event.\n\n@return the JSON representation of a new WorkerStatus\n@throws IOException if there was an error serializing the WorkerStatus", "Write an integer field to the JSON file.\n\n@param fieldName field name\n@param value field value" ]
public ItemRequest<Project> createInWorkspace(String workspace) { String path = String.format("/workspaces/%s/projects", workspace); return new ItemRequest<Project>(this, Project.class, path, "POST"); }
[ "If the workspace for your project _is_ an organization, you must also\nsupply a `team` to share the project with.\n\nReturns the full record of the newly created project.\n\n@param workspace The workspace or organization to create the project in.\n@return Request object" ]
[ "Gen error response.\n\n@param t\nthe t\n@return the response on single request", "Initialize current thread's JobContext using specified copy\n@param origin the original job context", "Looks up the EJB in the container and executes the method on it\n\n@param self the proxy instance.\n@param method the overridden method declared in the super class or\ninterface.\n@param proceed the forwarder method for invoking the overridden method. It\nis null if the overridden method is abstract or declared in the\ninterface.\n@param args an array of objects containing the values of the arguments\npassed in the method invocation on the proxy instance. If a\nparameter type is a primitive type, the type of the array\nelement is a wrapper class.\n@return the resulting value of the method invocation.\n@throws Throwable if the method invocation fails.", "Use this API to fetch all the dnsview resources that are configured on netscaler.", "Returns a product regarding its name\n\n@param name String\n@return DbProduct", "Places a disabled marker file in the directory of the specified version.\n\n@param version to disable\n@throws PersistenceFailureException if the marker file could not be created (can happen if\nthe storage system has become read-only or is otherwise\ninaccessible).", "Takes a string of the form \"x1=y1,x2=y2,...\" and returns Map\n@param map A string of the form \"x1=y1,x2=y2,...\"\n@return A Map m is returned such that m.get(xn) = yn", "Handle slop for nodes that are no longer part of the cluster. It may not\nalways be the case. For example, shrinking a zone or deleting a store.", "Complete the current operation and persist the current state to the disk. This will also trigger the invalidation\nof outdated modules.\n\n@param modification the current modification\n@param callback the completion callback" ]
public static void handleDomainOperationResponseStreams(final OperationContext context, final ModelNode responseNode, final List<OperationResponse.StreamEntry> streams) { if (responseNode.hasDefined(RESPONSE_HEADERS)) { ModelNode responseHeaders = responseNode.get(RESPONSE_HEADERS); // Strip out any stream header as the header created by this process is what counts responseHeaders.remove(ATTACHED_STREAMS); if (responseHeaders.asInt() == 0) { responseNode.remove(RESPONSE_HEADERS); } } for (OperationResponse.StreamEntry streamEntry : streams) { context.attachResultStream(streamEntry.getUUID(), streamEntry.getMimeType(), streamEntry.getStream()); } }
[ "Deal with streams attached to an operation response from a proxied domain process.\n\n@param context the context of the operation\n@param responseNode the DMR response from the proxied process\n@param streams the streams associated with the response" ]
[ "why isn't this functionality in enum?", "Remove a partition from the node provided\n\n@param node The node from which we're removing the partition\n@param donatedPartition The partitions to remove\n@return The new node without the partition", "Handles an incoming request message.\nAn incoming request message is a message initiated by a node or the controller.\n@param incomingMessage the incoming message to process.", "checks if a bean has been seen before in the dependencyPath. If not, it\nresolves the InjectionPoints and adds the resolved beans to the set of\nbeans to be validated", "Use this API to update nd6ravariables resources.", "MPP14 files seem to exhibit some occasional weirdness\nwith duplicate ID values which leads to the task structure\nbeing reported incorrectly. The following method attempts to correct this.\nThe method uses ordering data embedded in the file to reconstruct\nthe correct ID order of the tasks.", "When all the elements in a sorted set are inserted with the same score, in order to force lexicographical\nordering, this command returns all the elements in the sorted set with a value in the given range.\nIf the elements in the sorted set have different scores, the returned elements are unspecified.\n@param lexRange\n@return the range of elements", "Converts a date to an instance date bean.\n@return the instance date bean.", "Exit reporting up to distributor, using information gained from status reports to the LineCountManager\n\n@return a boolean of whether this consumer should immediately exit" ]
private JSONValue datesToJsonArray(Collection<Date> dates) { if (null != dates) { JSONArray result = new JSONArray(); for (Date d : dates) { result.set(result.size(), dateToJson(d)); } return result; } return null; }
[ "Converts a collection of dates to a JSON array with the long representation of the dates as strings.\n@param dates the list to convert.\n@return JSON array with long values of dates as string" ]
[ "Clear the selection of all items.\n@param requestLayout request layout after clear selection if the flag is true, no layout\nrequested otherwise\n@return {@code true} if at least one item was deselected,\n{@code false} otherwise.", "Static factory method.\n\n@param targetVariable\nthe variable to find the effective {@code putfield} or\n{@code putstatic} instruction for.\n@param controlFlowBlocks\nall control flow blocks of an initialising constructor or\nmethod.\n@return a new instance of this class.", "Stops the background stream thread.", "Performs the BFS and gives the results to a distributor to distribute\n\n@param distributor the distributor", "The cell String is the string representation of the object.\nIf padLeft is greater than 0, it is padded. Ditto right", "Disallow the job type from being executed.\n@param jobType the job type to disallow", "Converts to credentials for use in Grgit.\n@return {@code null} if both username and password are {@code null},\notherwise returns credentials in Grgit format.", "Registers your facet filters, adding them to this InstantSearch's widgets.\n\n@param filters a List of facet filters.", "Sets the right padding for all cells in the row.\n@param paddingRight new padding, ignored if smaller than 0\n@return this to allow chaining" ]
public void begin(String key) { if (key == null) { return; } TimingData data = executionInfo.get(key); if (data == null) { data = new TimingData(key); executionInfo.put(key, data); } data.begin(); }
[ "Start timing an operation with the given identifier." ]
[ "Use this API to fetch all the cmppolicylabel resources that are configured on netscaler.", "IN Criteria with SubQuery\n@param attribute The field name to be used\n@param subQuery The subQuery", "Stop finding signatures for all active players.", "Called from the native side\n@param eye", "Callback from the worker when it terminates", "Read a nested table whose contents we don't understand.\n\n@param rowSize fixed row size\n@param rowMagicNumber row magic number\n@return table rows", "Returns the specified range of elements in the sorted set.\nThe elements are considered to be ordered from the lowest to the highest score.\nLexicographical order is used for elements with equal score.\nBoth start and stop are zero-based inclusive indexes. They can also be negative numbers indicating offsets from\nthe end of the sorted set, with -1 being the last element of the sorted set.\n@param start\n@param end\n@return the range of elements", "Extract resource type from a resource ID string.\n@param id the resource ID string\n@return the resource type", "This method computes the eigen vector with the largest eigen value by using the\ndirect power method. This technique is the easiest to implement, but the slowest to converge.\nWorks only if all the eigenvalues are real.\n\n@param A The matrix. Not modified.\n@return If it converged or not." ]
@Override public Future<GcsFileMetadata> readObjectAsync(final ByteBuffer dst, final GcsFilename filename, long startOffsetBytes, long timeoutMillis) { Preconditions.checkArgument(startOffsetBytes >= 0, "%s: offset must be non-negative: %s", this, startOffsetBytes); final int n = dst.remaining(); Preconditions.checkArgument(n > 0, "%s: dst full: %s", this, dst); final int want = Math.min(READ_LIMIT_BYTES, n); final HTTPRequest req = makeRequest(filename, null, GET, timeoutMillis); req.setHeader( new HTTPHeader(RANGE, "bytes=" + startOffsetBytes + "-" + (startOffsetBytes + want - 1))); final HTTPRequestInfo info = new HTTPRequestInfo(req); return new FutureWrapper<HTTPResponse, GcsFileMetadata>(urlfetch.fetchAsync(req)) { @Override protected GcsFileMetadata wrap(HTTPResponse resp) throws IOException { long totalLength; switch (resp.getResponseCode()) { case 200: totalLength = getLengthFromHeader(resp, X_GOOG_CONTENT_LENGTH); break; case 206: totalLength = getLengthFromContentRange(resp); break; case 404: throw new FileNotFoundException("Could not find: " + filename); case 416: throw new BadRangeException("Requested Range not satisfiable; perhaps read past EOF? " + URLFetchUtils.describeRequestAndResponse(info, resp)); default: throw HttpErrorHandler.error(info, resp); } byte[] content = resp.getContent(); Preconditions.checkState(content.length <= want, "%s: got %s > wanted %s", this, content.length, want); dst.put(content); return getMetadataFromResponse(filename, resp, totalLength); } @Override protected Throwable convertException(Throwable e) { return OauthRawGcsService.convertException(info, e); } }; }
[ "Might not fill all of dst." ]
[ "Adds a new point.\n\n@param point a point\n@return this for chaining", "Apply any applicable header overrides to request\n\n@param httpMethodProxyRequest\n@throws Exception", "a small static helper class to get the color from the colorHolder\n\n@param colorHolder\n@param ctx\n@return", "These exact lines are shared between three different tools, so\nthey have been moved here to reduce code duplication.\n@return The parsed command-line, with options removed.", "lookup current maximum value for a single field in\ntable the given class descriptor was associated.", "Returns a lazily generated map from site paths of resources to the available locales for the resource.\n\n@return a lazily generated map from site paths of resources to the available locales for the resource.", "Shows the Loader component", "Record the checkout queue length\n\n@param dest Destination of the socket to checkout. Will actually record\nif null. Otherwise will call this on self and corresponding child\nwith this param null.\n@param queueLength The number of entries in the \"synchronous\" checkout\nqueue.", "Write a resource.\n\n@param record resource instance\n@throws IOException" ]
private TrackMetadata requestMetadataInternal(final DataReference track, final CdjStatus.TrackType trackType, final boolean failIfPassive) { // First check if we are using cached data for this request. MetadataCache cache = getMetadataCache(SlotReference.getSlotReference(track)); if (cache != null && trackType == CdjStatus.TrackType.REKORDBOX) { return cache.getTrackMetadata(null, track); } // Then see if any registered metadata providers can offer it for us. final MediaDetails sourceDetails = getMediaDetailsFor(track.getSlotReference()); if (sourceDetails != null) { final TrackMetadata provided = allMetadataProviders.getTrackMetadata(sourceDetails, track); if (provided != null) { return provided; } } // At this point, unless we are allowed to actively request the data, we are done. We can always actively // request tracks from rekordbox. if (passive.get() && failIfPassive && track.slot != CdjStatus.TrackSourceSlot.COLLECTION) { return null; } // Use the dbserver protocol implementation to request the metadata. ConnectionManager.ClientTask<TrackMetadata> task = new ConnectionManager.ClientTask<TrackMetadata>() { @Override public TrackMetadata useClient(Client client) throws Exception { return queryMetadata(track, trackType, client); } }; try { return ConnectionManager.getInstance().invokeWithClientSession(track.player, task, "requesting metadata"); } catch (Exception e) { logger.error("Problem requesting metadata, returning null", e); } return null; }
[ "Ask the specified player for metadata about the track in the specified slot with the specified rekordbox ID,\nusing cached media instead if it is available, and possibly giving up if we are in passive mode.\n\n@param track uniquely identifies the track whose metadata is desired\n@param trackType identifies the type of track being requested, which affects the type of metadata request\nmessage that must be used\n@param failIfPassive will prevent the request from taking place if we are in passive mode, so that automatic\nmetadata updates will use available caches only\n\n@return the metadata found, if any" ]
[ "calls _initMH on the method handler and then stores the result in the\nmethodHandler field as then new methodHandler", "Deletes the disabled marker file in the directory of the specified version.\n\n@param version to enable\n@throws PersistenceFailureException if the marker file could not be deleted (can happen if\nthe storage system has become read-only or is otherwise\ninaccessible).", "Reports that a node is resolved hence other nodes depends on it can consume it.\n\n@param completed the node ready to be consumed", "Retrieve the date range at the specified index.\nThe index is zero based, and this method will return\nnull if the requested date range does not exist.\n\n@param index range index\n@return date range instance", "Requests the waveform preview for a specific track ID, given a connection to a player that has already been\nset up.\n\n@param rekordboxId the track whose waveform preview is desired\n@param slot identifies the media slot we are querying\n@param client the dbserver client that is communicating with the appropriate player\n\n@return the retrieved waveform preview, or {@code null} if none was available\n@throws IOException if there is a communication problem", "Converts the permutation matrix into a vector\n@param P (Input) Permutation matrix\n@param vector (Output) Permutation vector", "Check the document field's type\nand object\n@param lhs The field to check\n@param rhs The type\n@return Expression: lhs $type rhs", "Copy a single named file to the output directory.\n@param outputDirectory The destination directory for the copied resource.\n@param sourceFile The path of the file to copy.\n@param targetFileName The name of the file created in {@literal outputDirectory}.\n@throws IOException If the file cannot be copied.", "Parse units.\n\n@param value units value\n@return units value" ]
private String generateAbbreviatedExceptionMessage(final Throwable throwable) { final StringBuilder builder = new StringBuilder(); builder.append(": "); builder.append(throwable.getClass().getCanonicalName()); builder.append(": "); builder.append(throwable.getMessage()); Throwable cause = throwable.getCause(); while (cause != null) { builder.append('\n'); builder.append("Caused by: "); builder.append(cause.getClass().getCanonicalName()); builder.append(": "); builder.append(cause.getMessage()); // make sure the exception cause is not itself to prevent infinite // looping assert (cause != cause.getCause()); cause = (cause == cause.getCause() ? null : cause.getCause()); } return builder.toString(); }
[ "Method generates abbreviated exception message.\n\n@param message\nOriginal log message\n@param throwable\nThe attached throwable\n@return Abbreviated exception message" ]
[ "Create a new collaboration object.\n@param api the API connection used to make the request.\n@param accessibleBy the JSON object describing who should be collaborated.\n@param item the JSON object describing which item to collaborate.\n@param role the role to give the collaborators.\n@param notify the user/group should receive email notification of the collaboration or not.\n@param canViewPath the view path collaboration feature is enabled or not.\n@return info about the new collaboration.", "Retrieve the value of a single-valued parameter.\n\n@param key\n@param defaultValue\n@param cnx", "This is the profiles page. this is the 'regular' page when the url is typed in", "Obtain override ID\n\n@param overrideIdentifier can be the override ID or class name\n@return\n@throws Exception", "Removes a parameter from this configuration.\n\n@param key the parameter to remove", "Creates the tcpClient with proper handler.\n\n@return the bound request builder\n@throws HttpRequestCreateException\nthe http request create exception", "Delivers the correct JSON Object for the target\n\n@param target\n@throws org.json.JSONException", "Comparator against other element.\n\n@param otherElement The other element.\n@param logging Whether to do logging.\n@return Whether the elements are equal.", "Writes the details of a recurring exception.\n\n@param mpxjException source MPXJ calendar exception\n@param xmlException target MSPDI exception" ]
public void deployApplication(String applicationName, String... classpathLocations) throws IOException { final List<URL> classpathElements = Arrays.stream(classpathLocations) .map(classpath -> Thread.currentThread().getContextClassLoader().getResource(classpath)) .collect(Collectors.toList()); deployApplication(applicationName, classpathElements.toArray(new URL[classpathElements.size()])); }
[ "Deploys application reading resources from specified classpath location\n\n@param applicationName to configure in cluster\n@param classpathLocations where resources are read\n@throws IOException" ]
[ "Moves a particular enum option to be either before or after another specified enum option in the custom field.\n\n@param customField Globally unique identifier for the custom field.\n@return Request object", "Method will be executed asynchronously.", "Pump events from event stream.", "Calls afterMaterialization on all registered listeners in the reverse\norder of registration.", "Gets all checked widgets in the group\n@return list of checked widgets", "Starts the transition", "Use this API to fetch appflowpolicy_binding resource of given name .", "Set the value of one or more fields based on the contents of a database row.\n\n@param map column to field map\n@param row database row\n@param container field container", "Creates a new indirection handler instance.\n\n@param brokerKey The associated {@link PBKey}.\n@param id The subject's ids\n@return The new instance" ]
public void seekToMonth(String direction, String seekAmount, String month) { int seekAmountInt = Integer.parseInt(seekAmount); int monthInt = Integer.parseInt(month); assert(direction.equals(DIR_LEFT) || direction.equals(DIR_RIGHT)); assert(monthInt >= 1 && monthInt <= 12); markDateInvocation(); // set the day to the first of month. This step is necessary because if we seek to the // current day of a month whose number of days is less than the current day, we will // pushed into the next month. _calendar.set(Calendar.DAY_OF_MONTH, 1); // seek to the appropriate year if(seekAmountInt > 0) { int currentMonth = _calendar.get(Calendar.MONTH) + 1; int sign = direction.equals(DIR_RIGHT) ? 1 : -1; int numYearsToShift = seekAmountInt + (currentMonth == monthInt ? 0 : (currentMonth < monthInt ? sign > 0 ? -1 : 0 : sign > 0 ? 0 : -1)); _calendar.add(Calendar.YEAR, (numYearsToShift * sign)); } // now set the month _calendar.set(Calendar.MONTH, monthInt - 1); }
[ "seeks to a particular month\n\n@param direction the direction to seek: two possibilities\n'<' go backward\n'>' go forward\n\n@param seekAmount the amount to seek. Must be guaranteed to parse as an integer\n\n@param month the month to seek to. Must be guaranteed to parse as an integer\nbetween 1 and 12" ]
[ "As already described, but if separator is not null, then objects\nsuch as TaggedWord\n\n@param separator The string used to separate Word and Tag\nin TaggedWord, etc", "This method allows us to peek into the OLE compound document to extract the file format.\nThis allows the UniversalProjectReader to determine if this is an MPP file, or if\nit is another type of OLE compound document.\n\n@param fs POIFSFileSystem instance\n@return file format name\n@throws IOException", "Returns the index of the eigenvalue which has the smallest magnitude.\n\n@return index of the smallest magnitude eigen value.", "Returns the index of the eigenvalue which has the smallest magnitude.\n\n@return index of the smallest magnitude eigen value.", "Prepares this DAG for node enumeration using getNext method, each call to getNext returns next node\nin the DAG with no dependencies.", "Decrements the client's use count, and makes it eligible for closing if it is no longer in use.\n\n@param client the dbserver connection client which is no longer being used for a task", "Gets an array of of all registered ConstantMetaClassListener instances.", "Converts milliseconds into a calendar object.\n\n@param millis a time given in milliseconds after epoch\n@return the calendar object for the given time", "Generic string joining function.\n@param strings Strings to be joined\n@param fixCase does it need to fix word case\n@param withChar char to join strings with.\n@return joined-string" ]
private void clearMetadata(DeviceAnnouncement announcement) { final int player = announcement.getNumber(); // Iterate over a copy to avoid concurrent modification issues for (DeckReference deck : new HashSet<DeckReference>(hotCache.keySet())) { if (deck.player == player) { hotCache.remove(deck); if (deck.hotCue == 0) { deliverTrackMetadataUpdate(player, null); // Inform listeners the metadata is gone. } } } }
[ "We have received notification that a device is no longer on the network, so clear out its metadata.\n\n@param announcement the packet which reported the device’s disappearance" ]
[ "Upload a photo from an InputStream.\n\n@param in\n@param metaData\n@return photoId or ticketId\n@throws FlickrException", "Prints one line to the csv file\n\n@param cr data pipe with search results", "Return whether or not the field value passed in is the default value for the type of the field. Null will return\ntrue.", "Read properties from the active profiles.\n\nGoes through all active profiles (in the order the\nprofiles are defined in settings.xml) and extracts\nthe desired properties (if present). The prefix is\nused when looking up properties in the profile but\nnot in the returned map.\n\n@param prefix The prefix to use or null if no prefix should be used\n@param properties The properties to read\n\n@return A map containing the values for the properties that were found", "Use this API to update rsskeytype.", "Creates a tar file entry with defaults parameters.\n@param fileName the entry name\n@return file entry with reasonable defaults", "Returns a new ObjectPool for the specified connection descriptor.\nOverride this method to setup your own pool.\n@param jcd the connection descriptor for which to set up the pool\n@return a newly created object pool", "Function to serialize the given Vector clock into a string. If something\ngoes wrong, it returns an empty string.\n\n@param vc The Vector clock to serialize\n@return The string (JSON) version of the specified Vector clock", "Use this API to delete linkset of given name." ]
public long getLong(Integer type) { long result = 0; byte[] item = m_map.get(type); if (item != null) { result = MPPUtility.getLong6(item, 0); } return (result); }
[ "Retrieves a long value from the extended data.\n\n@param type Type identifier\n@return long value" ]
[ "Init the headers of the table regarding the filters\n\n@return String[]", "Removes a parameter from this configuration.\n\n@param key the parameter to remove", "Use this API to fetch all the systementitydata resources that are configured on netscaler.\nThis uses systementitydata_args which is a way to provide additional arguments while fetching the resources.", "Grab random holiday from the equivalence class that falls between the two dates\n\n@param earliest the earliest date parameter as defined in the model\n@param latest the latest date parameter as defined in the model\n@return a holiday that falls between the dates", "Add the dependencies if the deployment contains a service activator loader entry.\n@param phaseContext the deployment unit context\n@throws DeploymentUnitProcessingException", "Use this API to fetch Interface resource of given name .", "If there are any observer methods, they must be static or business\nmethods.", "Changes to a new sub-view and stores a report to be displayed by that subview.<p<\n\n@param newState the new state\n@param thread the report thread which should be displayed in the sub view\n@param label the label to display for the report", "Evaluates the body if value for the member tag equals the specified value.\n\n@param template The body of the block tag\n@param attributes The attributes of the template tag\n@exception XDocletException If an error occurs\[email protected] type=\"block\"\[email protected] name=\"tagName\" optional=\"false\" description=\"The tag name.\"\[email protected] name=\"paramName\" description=\"The parameter name. If not specified, then the raw\ncontent of the tag is returned.\"\[email protected] name=\"paramNum\" description=\"The zero-based parameter number. It's used if the user\nused the space-separated format for specifying parameters.\"\[email protected] name=\"value\" optional=\"false\" description=\"The expected value.\"" ]
public void setWeekDay(String dayString) { final WeekDay day = WeekDay.valueOf(dayString); if (m_model.getWeekDay() != day) { removeExceptionsOnChange(new Command() { public void execute() { m_model.setWeekDay(day); onValueChange(); } }); } }
[ "Set the week day the event should take place.\n@param dayString the day as string." ]
[ "Find the earliest task start date. We treat this as the\nstart date for the project.\n\n@return start date", "Disable all overrides for a specified path\n\n@param pathID ID of path containing overrides\n@param clientUUID UUID of client", "Given a list of store definitions return a set of store names\n\n@param storeDefList The list of store definitions\n@return Returns a set of store names", "Only converts the B matrix and passes that onto solve. Te result is then copied into\nthe input 'X' matrix.\n\n@param B A matrix &real; <sup>m &times; p</sup>. Not modified.\n@param X A matrix &real; <sup>n &times; p</sup>, where the solution is written to. Modified.", "Add a IN clause so the column must be equal-to one of the objects passed in.", "Finds the column with the largest normal and makes that the first column\n\n@param j Current column being inspected", "Presents the Cursor Settings to the User. Only works if scene is set.", "This method extracts data for a single resource from a GanttProject file.\n\n@param gpResource resource data", "Enable a host\n\n@param hostName\n@throws Exception" ]
public ItemRequest<CustomField> delete(String customField) { String path = String.format("/custom_fields/%s", customField); return new ItemRequest<CustomField>(this, CustomField.class, path, "DELETE"); }
[ "A specific, existing custom field can be deleted by making a DELETE request on the URL for that custom field.\n\nReturns an empty data record.\n\n@param customField Globally unique identifier for the custom field.\n@return Request object" ]
[ "Returns a compact representation of all of the tags the task has.\n\n@param task The task to get tags on.\n@return Request object", "Returns the first found autoincrement field\ndefined in this class descriptor. Use carefully\nwhen multiple autoincrement field were defined.\n@deprecated does not make sense because it's possible to\ndefine more than one autoincrement field. Alternative\nsee {@link #getAutoIncrementFields}", "Utility function to find the first index of a value in a\nListBox.", "Returns a \"clean\" version of the given filename in which spaces have\nbeen converted to dashes and all non-alphanumeric chars are underscores.", "Returns the default table name for this class which is the unqualified class name.\n\n@return The default table name", "Return the number of days between startDate and endDate given the\nspecific daycount convention.\n\n@param startDate The start date given as a {@link org.threeten.bp.LocalDate}.\n@param endDate The end date given as a {@link org.threeten.bp.LocalDate}.\n@param convention A convention string.\n@return The number of days within the given period.", "Stops the scavenger.", "Set brightness to eg. darken the resulting image for use as background\n\n@param brightness default is 0, pos values increase brightness, neg. values decrease brightness\n.-100 is black, positive goes up to 1000+", "Read the table from the file and populate the supplied Table instance.\n\n@param file database file\n@param table Table instance" ]
public String getOriginalUrl() throws FlickrException { if (originalSize == null) { if (originalFormat != null) { return getOriginalBaseImageUrl() + "_o." + originalFormat; } return getOriginalBaseImageUrl() + DEFAULT_ORIGINAL_IMAGE_SUFFIX; } else { return originalSize.getSource(); } }
[ "Get the original image URL.\n\n@return The original image URL" ]
[ "Use this API to fetch statistics of service_stats resource of given name .", "set the textColor of the ColorHolder to an drawable\n\n@param ctx\n@param drawable", "Saves a matrix to disk using Java binary serialization.\n\n@param A The matrix being saved.\n@param fileName Name of the file its being saved at.\n@throws java.io.IOException", "Legacy conversion.\n@param map\n@return Properties", "Gets the health memory.\n\n@return the health memory", "Add columns to be returned by the SELECT query. If no columns are selected then all columns are returned by\ndefault. For classes with id columns, the id column is added to the select list automagically. This can be called\nmultiple times to add more columns to select.\n\n<p>\n<b>WARNING:</b> If you specify any columns to return, then any foreign-collection fields will be returned as null\n<i>unless</i> their {@link ForeignCollectionField#columnName()} is also in the list.\n</p>", "Support the range subscript operator for CharSequence with IntRange\n\n@param text a CharSequence\n@param range an IntRange\n@return the subsequence CharSequence\n@since 1.0", "characters callback.", "Use this API to update nspbr6 resources." ]
public boolean setCustomResponse(String pathName, String customResponse) throws Exception { // figure out the new ordinal int nextOrdinal = this.getNextOrdinalForMethodId(-1, pathName); // add override this.addMethodToResponseOverride(pathName, "-1"); // set argument return this.setMethodArguments(pathName, "-1", nextOrdinal, customResponse); }
[ "Set a custom response for this path\n\n@param pathName name of path\n@param customResponse value of custom response\n@return true if success, false otherwise\n@throws Exception exception" ]
[ "this remove the linebreak.\n\n@param input\nthe input\n@param patternStr\nthe pattern str\n@return the string", "Constructs the appropriate MenuDrawer based on the position.", "Read a text file into a single string\n\n@param file\nThe file to read\n@return The contents, or null on error.", "Perform construction.\n\n@param callbackHandler", "Removes any child object that has the given name by performing\ncase-sensitive search.\n\n@param name name of scene object to be removed.\n\n@return number of removed objects, 0 if none was found.", "The default User-Agent header. Override this method to override the user agent.\n\n@return the user agent string.", "This method must be called on the start of the component. Initialize and start the directory monitor.\n\n@param monitoredDirectory\n@param pollingTime", "Resets the handler data to a basic state.", "Use this API to fetch all the sslservice resources that are configured on netscaler." ]
public static DMatrixSparseCSC convert(DMatrixSparseTriplet src , DMatrixSparseCSC dst , int hist[] ) { if( dst == null ) dst = new DMatrixSparseCSC(src.numRows, src.numCols , src.nz_length); else dst.reshape(src.numRows, src.numCols, src.nz_length); if( hist == null ) hist = new int[ src.numCols ]; else if( hist.length >= src.numCols ) Arrays.fill(hist,0,src.numCols, 0); else throw new IllegalArgumentException("Length of hist must be at least numCols"); // compute the number of elements in each columns for (int i = 0; i < src.nz_length; i++) { hist[src.nz_rowcol.data[i*2+1]]++; } // define col_idx dst.histogramToStructure(hist); System.arraycopy(dst.col_idx,0,hist,0,dst.numCols); // now write the row indexes and the values for (int i = 0; i < src.nz_length; i++) { int row = src.nz_rowcol.data[i*2]; int col = src.nz_rowcol.data[i*2+1]; double value = src.nz_value.data[i]; int index = hist[col]++; dst.nz_rows[index] = row; dst.nz_values[index] = value; } dst.indicesSorted = false; return dst; }
[ "Converts SMatrixTriplet_64 into a SMatrixCC_64.\n\n@param src Original matrix which is to be copied. Not modified.\n@param dst Destination. Will be a copy. Modified.\n@param hist Workspace. Should be at least as long as the number of columns. Can be null." ]
[ "Sets the necessary height for all bands in the report, to hold their children", "Loads the Configuration from the properties file.\n\nLoads the properties file, or uses defaults on failure.\n\n@see org.apache.ojb.broker.util.configuration.impl.ConfigurationAbstractImpl#setFilename(java.lang.String)", "Get random geographical location\n@return 2-Tuple of ints (latitude, longitude)", "Check if the property is part of the identifier of the entity.\n\n@param persister the {@link OgmEntityPersister} of the entity with the property\n@param namesWithoutAlias the path to the property with all the aliases resolved\n@return {@code true} if the property is part of the id, {@code false} otherwise.", "Receive some bytes from the player we are requesting metadata from.\n\n@param is the input stream associated with the player metadata socket.\n@return the bytes read.\n\n@throws IOException if there is a problem reading the response", "Download a specified URL to a file\n\n@param stringUrl URL to use\n@param parameters HTTP Headers\n@param fileToSave File to save content\n@throws IOException I/O error happened", "JSObject will return the String \"undefined\" at certain times, so we\nneed to make sure we're not getting a value that looks valid, but isn't.\n\n@param val The value from Javascript to be checked.\n@return Either null or the value passed in.", "Used by the slave host when creating the host info dmr sent across to the DC during the registration process\n\n@param ignoreUnaffectedServerGroups whether the slave host is set up to ignore config for server groups it does not have servers for\n@param hostModel the resource containing the host model\n@param model the dmr sent across to theDC\n@return the modified dmr", "Use this API to add lbroute." ]
public boolean removeWriter(Object key, Object resourceId) { boolean result = false; ObjectLocks objectLocks = null; synchronized(locktable) { objectLocks = (ObjectLocks) locktable.get(resourceId); if(objectLocks != null) { /** * MBAIRD, last one out, close the door and turn off the lights. * if no locks (readers or writers) exist for this object, let's remove * it from the locktable. */ LockEntry entry = objectLocks.getWriter(); if(entry != null && entry.isOwnedBy(key)) { objectLocks.setWriter(null); result = true; // no need to check if writer is null, we just set it. if(objectLocks.getReaders().size() == 0) { locktable.remove(resourceId); } } } } return result; }
[ "Remove an write lock." ]
[ "Use this API to fetch service_dospolicy_binding resources of given name .", "Generate random velocities for every particle. The direction is obtained by assuming\nthe position of a particle as a vector. This normalised vector is scaled by\nthe speed range.\n\n@return", "Get a compatible constructor\n\n@param type\nClass to look for constructor in\n@param argumentType\nArgument type for constructor\n@return the compatible constructor or null if none found", "Returns the names of the involved fields when post processing.\n\n@return the names of the involved fields", "Sets the invalid values for the TextBox\n@param invalidValues\n@param isCaseSensitive\n@param invalidValueErrorMessage", "Converts from a Fluo RowColumn to a Accumulo Key\n\n@param rc RowColumn\n@return Key", "Encodes the given source into an encoded String using the rules specified\nby the given component and with the given options.\n@param source the source string\n@param encoding the encoding of the source string\n@param type the URI component for the source\n@return the encoded URI\n@throws IllegalArgumentException when the given uri parameter is not a valid URI", "Determines the address for the host being used.\n\n@param client the client used to communicate with the server\n\n@return the address of the host\n\n@throws IOException if an error occurs communicating with the server\n@throws OperationExecutionException if the operation used to determine the host name fails", "Returns with an iterable of URIs that points to all elements that are\nreferenced by the argument or vice-versa.\n\n@return an iterable of URIs that are referenced by the argument or the\nother way around." ]
public String prepareStatementString() throws SQLException { List<ArgumentHolder> argList = new ArrayList<ArgumentHolder>(); return buildStatementString(argList); }
[ "Build and return a string version of the query. If you change the where or make other calls you will need to\nre-call this method to re-prepare the query for execution." ]
[ "Registers your facet filters, adding them to this InstantSearch's widgets.\n\n@param filters a List of facet filters.", "Set the current playback position. This method can only be used in situations where the component is\ntied to a single player, and therefore always has a single playback position.\n\nWill cause part of the component to be redrawn if the position has\nchanged. This will be quickly overruled if a player is being monitored, but\ncan be used in other contexts.\n\n@param milliseconds how far into the track has been played\n\n@see #setPlaybackState", "Reads the detail container resources which are connected by relations to the given resource.\n\n@param cms the current CMS context\n@param res the detail content\n\n@return the list of detail only container resources\n\n@throws CmsException if something goes wrong", "Allocate a timestamp", "Clones the cluster by constructing a new one with same name, partition\nlayout, and nodes.\n\n@param cluster\n@return clone of Cluster cluster.", "Get a collection of recent photos.\n\nThis method does not require authentication.\n\n@see com.flickr4java.flickr.photos.Extras\n@param extras\nSet of extra-fields\n@param perPage\nThe number of photos per page\n@param page\nThe page offset\n@return A collection of Photo objects\n@throws FlickrException", "Returns a flag indicating if also unreleased resources should be found.\n@return A flag indicating if also unreleased resources should be found.", "Function to perform backward pooling", "Given a key and a list of steal infos give back a list of stealer node\nids which will steal this.\n\n@param key Byte array of key\n@param stealerNodeToMappingTuples Pairs of stealer node id to their\ncorresponding [ partition - replica ] tuples\n@param cluster Cluster metadata\n@param storeDef Store definitions\n@return List of node ids" ]
public void drawGeometry(Geometry geometry, SymbolInfo symbol, Color fillColor, Color strokeColor, float lineWidth, float[] dashArray, Rectangle clipRect) { template.saveState(); // clipping code if (clipRect != null) { template.rectangle(clipRect.getLeft() + origX, clipRect.getBottom() + origY, clipRect.getWidth(), clipRect .getHeight()); template.clip(); template.newPath(); } setStroke(strokeColor, lineWidth, dashArray); setFill(fillColor); drawGeometry(geometry, symbol); template.restoreState(); }
[ "Draw the specified geometry.\n\n@param geometry geometry to draw\n@param symbol symbol for geometry\n@param fillColor fill colour\n@param strokeColor stroke colour\n@param lineWidth line width\n@param clipRect clipping rectangle" ]
[ "Returns a string that should be used as a label for the given item. The\nmethod also ensures that each label is used for only one class. Other\nclasses with the same label will have their QID added for disambiguation.\n\n@param entityIdValue\nthe item to label\n@return the label", "This method extracts data for a single day from an MSPDI file.\n\n@param calendar Calendar data\n@param day Day data\n@param readExceptionsFromDays read exceptions form day definitions", "Sets the occurence.\n\n@param min the min\n@param max the max\n@throws ParseException the parse exception", "Parses the resource String id and get back the int res id\n@param context\n@param id String resource id\n@return int resource id", "Check if the provided manifestPath is correct.\nSet the manifest and imagePath in case of the correct manifest.\n@param manifestPath\n@param candidateImagePath\n@param dependenciesClient\n@param listener\n@return true if found the correct manifest\n@throws IOException", "Utility function that fetches system store definitions\n\n@return The map container that maps store names to store definitions", "Non-blocking call that will throw any Exceptions in the traditional\nmanner on access\n\n@param key\n@param value\n@return", "Sets an attribute in the main section of the manifest to a list.\nThe list elements will be joined with a single whitespace character.\n\n@param name the attribute's name\n@param values the attribute's value\n@return {@code this}\n@throws IllegalStateException if entries have been added or the JAR has been written prior to calling this methods.", "Notifies that a content item is changed.\n\n@param position the position." ]
@UiHandler("m_seriesCheckBox") void onSeriesChange(ValueChangeEvent<Boolean> event) { if (handleChange()) { m_controller.setIsSeries(event.getValue()); } }
[ "Handle changes of the series check box.\n@param event the change event." ]
[ "Get an image as a stream. Callers must be sure to close the stream when they are done with it.\n\n@deprecated\n@see PhotosInterface#getImageAsStream(Photo, int)\n@param suffix\nThe suffix\n@return The InputStream\n@throws IOException", "Determine the generic value type of the given Map field.\n@param mapField the map field to introspect\n@param nestingLevel the nesting level of the target type\n(typically 1; e.g. in case of a List of Lists, 1 would indicate the\nnested List, whereas 2 would indicate the element of the nested List)\n@return the generic type, or {@code null} if none", "Create a temporary directory under a given workspace", "Removes double-quotes from around a string\n@param str\n@return", "Use this API to fetch csvserver_spilloverpolicy_binding resources of given name .", "Add views to the tree.\n\n@param parentNode parent tree node\n@param file views container", "Determine the X coordinate within the component at which the specified beat begins.\n\n@param beat the beat number whose position is desired\n@return the horizontal position within the component coordinate space where that beat begins\n@throws IllegalArgumentException if the beat number exceeds the number of beats in the track.", "Use this API to fetch all the dospolicy resources that are configured on netscaler.", "Creates a new GridLines instance.\n\n@param data data block\n@param offset offset into data block\n@return new GridLines instance" ]
public static CmsResourceTypeStatResultList init(CmsResourceTypeStatResultList resList) { if (resList == null) { return new CmsResourceTypeStatResultList(); } resList.deleteOld(); return resList; }
[ "Method to initialize the list.\n\n@param resList a given instance or null\n@return an instance" ]
[ "Get upload status for the currently authenticated user.\n\nRequires authentication with 'read' permission using the new authentication API.\n\n@return A User object with upload status data fields filled\n@throws FlickrException", "prefix length in this section is ignored when converting to MAC", "Get info about the shard a document belongs to.\n\n@param docId document ID\n@return Shard info\n@see <a\nhref=\"https://console.bluemix.net/docs/services/Cloudant/api/advanced.html#-get-database-_shards-\"\ntarget=\"_blank\">_shards</a>", "Utility function to get the current text.", "Return a long value which is the number of rows in the table.", "Set a knot color.\n@param n the knot index\n@param color the color", "performs a SELECT operation against RDBMS.\n@param query the query string.\n@param cld ClassDescriptor providing JDBC information.", "Return the number of arguments associated with the specified option.\nThe return value includes the actual option.\nWill return 0 if the option is not supported.", "Retrieve and validate vector clock value from the REST request.\n\"X_VOLD_VECTOR_CLOCK\" is the vector clock header.\n\n@return true if present, false if missing" ]
public ImageSource apply(ImageSource input) { ImageSource originalImage = input; int width = originalImage.getWidth(); int height = originalImage.getHeight(); boolean[][] matrix = new boolean[width][height]; // black n white boolean matrix; true = blck, false = white // Copy ImageSource filteredImage = new MatrixSource(input); int[] histogram = OtsuBinarize.imageHistogram(originalImage); int totalNumberOfpixels = height * width; int threshold = OtsuBinarize.threshold(histogram, totalNumberOfpixels); int black = 0; int white = 255; int gray; int alpha; int newColor; for (int i = 0; i < width; i++) { for (int j = 0; j < height; j++) { gray = originalImage.getGray(i, j); if (gray > threshold) { matrix[i][j] = false; } else { matrix[i][j] = true; } } } int blackTreshold = letterThreshold(originalImage, matrix); for (int i = 0; i < width; i++) { for (int j = 0; j < height; j++) { gray = originalImage.getGray(i, j); alpha = originalImage.getA(i, j); if (gray > blackTreshold) { newColor = white; } else { newColor = black; } newColor = ColorHelper.getARGB(newColor, newColor, newColor, alpha); filteredImage.setRGB(i, j, newColor); } } return filteredImage; }
[ "radi otsu da dobije spojena crna slova i ra\n\n@param input\n@return the processed image" ]
[ "Adds all rows from the TSV file specified, using the provided delimiter and null value.\n\n@param file The file to read the data from.\n@param delimiter A column delimiter.\n@param nullValue Value to be treated as null in the source data.\n@return {@code this}", "Get all field attributes in an unmodifiable Map, or null if no attributes have been added\n\n@return all field attributes, or <code>NULL</code> if none exist", "Set the duration option.\n@param value the duration option to set ({@link EndType} as string).", "Use this API to fetch a vpnglobal_appcontroller_binding resources.", "Redirect to page\n\n@param model\n@return", "Use this API to fetch filtered set of gslbservice resources.\nset the filter parameter values in filtervalue object.", "Returns the available module names regarding the filters\n\n@param name String\n@param filters FiltersHolder\n@return List<String>", "Resolves line alpha based on distance comparing to max distance.\nWhere alpha is close to 0 for maxDistance, and close to 1 to 0 distance.\n\n@param distance line length\n@param maxDistance max line length\n@return line alpha", "Remove all controllers but leave input manager running.\n@return number of controllers removed" ]
public static String join(Iterable<?> iterable, String separator) { if (iterable != null) { StringBuilder buf = new StringBuilder(); Iterator<?> it = iterable.iterator(); char singleChar = separator.length() == 1 ? separator.charAt(0) : 0; while (it.hasNext()) { buf.append(it.next()); if (it.hasNext()) { if (singleChar != 0) { // More efficient buf.append(singleChar); } else { buf.append(separator); } } } return buf.toString(); } else { return ""; } }
[ "Joins the given iterable objects using the given separator into a single string.\n\n@return the joined string or an empty string if iterable is null" ]
[ "Return all valid tenors for a given moneyness and maturity.\nUses the payment times of the fix schedule to determine fractions.\n\n@param moneyness The moneyness as actual offset from par swap rate for which to get the maturities.\n@param maturity The maturities as year fraction from the reference date.\n@return The tenors as year fraction from reference date.", "Use this API to fetch all the route6 resources that are configured on netscaler.\nThis uses route6_args which is a way to provide additional arguments while fetching the resources.", "After obtaining a connection, perform additional tasks.\n@param handle\n@param statsObtainTime", "Convert this path address to its model node representation.\n\n@return the model node list of properties", "Set the parent from which this week is derived.\n\n@param parent parent week", "Function to serialize the given Vector clock into a string. If something\ngoes wrong, it returns an empty string.\n\n@param vc The Vector clock to serialize\n@return The string (JSON) version of the specified Vector clock", "Appends to the statement table and all tables joined to it.\n@param alias the table alias\n@param where append conditions for WHERE clause here", "Return collection of path Ids in priority order\n\n@param profileId ID of profile\n@return collection of path Ids in priority order", "Merges the two classes into a single class. The smaller class is\nremoved, while the largest class is kept." ]
public void awaitStartupCompletion() { try { Object obj = startedStatusQueue.take(); if(obj instanceof Throwable) throw new VoldemortException((Throwable) obj); } catch(InterruptedException e) { // this is okay, if we are interrupted we can stop waiting } }
[ "Blocks until the server has started successfully or an exception is\nthrown.\n\n@throws VoldemortException if a problem occurs during start-up wrapping\nthe original exception." ]
[ "Parses an RgbaColor from an rgba value.\n\n@return the parsed color", "Prints text to output stream, replacing parameter start and end\nplaceholders\n\n@param text the String to print", "get all consumers for the group\n\n@param zkClient the zookeeper client\n@param group the group name\n@return topic-&gt;(consumerIdStringA-0,consumerIdStringA-1...consumerIdStringB-0,consumerIdStringB-1)", "Maps a story if it is allowed by the meta filter\n\n@param story\nthe Story\n@param metaFilter\nthe meta filter", "Match the Origin header with the allowed origins.\nIf it doesn't match then a 403 response code is set on the response and it returns null.\n@param exchange the current HttpExchange.\n@param allowedOrigins list of sanitized allowed origins.\n@return the first matching origin, null otherwise.\n@throws Exception", "Readable yyyyMMdd representation of a day, which is also sortable.", "Use this API to rename a gslbservice resource.", "Merge the given maps.\n\n<p>\nThe replied map is a view on the given two maps.\nIf a key exists in the two maps, the replied value is the value of the right operand.\n</p>\n\n<p>\nEven if the key of the right operand exists in the left operand, the value in the right operand is preferred.\n</p>\n\n<p>\nThe replied map is unmodifiable.\n</p>\n\n@param <K> type of the map keys.\n@param <V> type of the map values.\n@param left the left map.\n@param right the right map.\n@return a map with the merged contents from the two maps.\n@since 2.15", "This is the main entry point used to convert the internal representation\nof timephased baseline cost into an external form which can\nbe displayed to the user.\n\n@param file parent project file\n@param cost timephased resource assignment data\n@param rangeUnits timescale units\n@param dateList timescale date ranges\n@return list of durations, one per timescale date range" ]
public static Envelope getTileBounds(TileCode code, Envelope maxExtent, double scale) { double[] layerSize = getTileLayerSize(code, maxExtent, scale); if (layerSize[0] == 0) { return null; } double cX = maxExtent.getMinX() + code.getX() * layerSize[0]; double cY = maxExtent.getMinY() + code.getY() * layerSize[1]; return new Envelope(cX, cX + layerSize[0], cY, cY + layerSize[1]); }
[ "Get the bounding box for a certain tile.\n\n@param code\nThe unique tile code. Determines what tile we're talking about.\n@param maxExtent\nThe maximum extent of the grid to which this tile belongs.\n@param scale\nThe current client side scale.\n@return Returns the bounding box for the tile, expressed in the layer's coordinate system." ]
[ "Inserts a Parcelable value into the mapping of the underlying Bundle, replacing any existing\nvalue for the given key. Either key or value may be null.\n\n@param key a String, or null\n@param value a Parcelable object, or null\n@return this bundler instance to chain method calls", "Return true if the DeclarationExpression represents a 'final' variable declaration.\n\nNOTE: THIS IS A WORKAROUND.\n\nThere does not seem to be an easy way to determine whether the 'final' modifier has been\nspecified for a variable declaration. Return true if the 'final' is present before the variable name.", "get the last segment at the moment\n\n@return the last segment", "Calculates the next date, starting from the provided date.\n\n@param date the current date.\n@param interval the number of month to add when moving to the next month.", "This method returns the existing folder, and if it does not exist, the\nmethod generates it.\n\n@param path\n@param dest_dir\n@return the folder\n@throws BeastException", "Returns the screen height in pixels\n\n@param context is the context to get the resources\n@return the screen height in pixels", "Determines run length for each 'initial' partition ID. Note that a\ncontiguous run may \"wrap around\" the end of the ring.\n\n@param cluster\n@param zoneId\n@return map of initial partition Id to length of contiguous run of\npartition IDs within the same zone..", "This adds to the feature name the name of classes that are other than\nthe current class that are involved in the clique. In the CMM, these\nother classes become part of the conditioning feature, and only the\nclass of the current position is being predicted.\n\n@return A collection of features with extra class information put\ninto the feature name.", "Returns true if templates are to be instantiated synchronously and false if\nasynchronously." ]
public FinishRequest toFinishRequest(boolean includeHeaders) { if (includeHeaders) { return new FinishRequest(body, copyHeaders(headers), statusCode); } else { String mime = null; if (body!=null) { mime = "text/plain"; if (headers!=null && (headers.containsKey("Content-Type") || headers.containsKey("content-type"))) { mime = headers.get("Content-Type"); if (mime==null) { mime = headers.get("content-type"); } } } return new FinishRequest(body, mime, statusCode); } }
[ "Convert the message to a FinishRequest" ]
[ "Gets the publisher wrapped by the specofoed FlexiblePublisher.\n@param publisher The FlexiblePublisher wrapping the publisher.\n@param type The type of the publisher wrapped by the FlexiblePublisher.\n@return The publisher object wrapped by the FlexiblePublisher.\nNull is returned if the FlexiblePublisher does not wrap a publisher of the specified type.\n@throws IllegalArgumentException In case publisher is not of type\n{@link org.jenkins_ci.plugins.flexible_publish.FlexiblePublisher}", "Check from another ConcurrentGroupServerUpdatePolicy whose plans are meant to\nexecute once this policy's plans are successfully completed.\n\n@return <code>true</code> if the successor can proceed", "Gets the string representation of the path to the current JSON element.\n\n@param key the leaf key", "Reads the next \"word from the request, comprising all characters up to the next SPACE.\nCharacters are tested by the supplied CharacterValidator, and an exception is thrown\nif invalid characters are encountered.", "Sets the values of this vector to those of v1.\n\n@param v1\nvector whose values are copied", "Create a JMX ObjectName\n\n@param domain The domain of the object\n@param type The type of the object\n@return An ObjectName representing the name", "Magnitude of complex number.\n\n@param z Complex number.\n@return Magnitude of complex number.", "Retrieve the configuration of the named template.\n\n@param name the template name;", "Convert Day instance to MPX day index.\n\n@param day Day instance\n@return day index" ]
private void processPredecessors() { for (Map.Entry<Task, List<MapRow>> entry : m_predecessorMap.entrySet()) { Task task = entry.getKey(); List<MapRow> predecessors = entry.getValue(); for (MapRow predecessor : predecessors) { processPredecessor(task, predecessor); } } }
[ "Extract predecessor data." ]
[ "Convert the Primavera string representation of a UUID into a Java UUID instance.\n\n@param value Primavera UUID\n@return Java UUID instance", "generate a prepared INSERT-Statement for the Class\ndescribed by cld.\n\n@param cld the ClassDescriptor", "Associate an input stream with the operation. Closing the input stream\nis the responsibility of the caller.\n\n@param in the input stream. Cannot be {@code null}\n@return a builder than can be used to continue building the operation", "Builds the DynamicReport object. Cannot be used twice since this produced\nundesired results on the generated DynamicReport object\n\n@return", "Use this API to fetch vlan_interface_binding resources of given name .", "Computes execution time\n@param extra", "Print a task UID.\n\n@param value task UID\n@return task UID string", "Read all of the fields information from the configuration file.", "Add the list with given bundles to the \"Import-Package\" main attribute.\n\n@param importedPackages The list of all packages to add." ]
private void updateLetsEncrypt() { getReport().println(Messages.get().container(Messages.RPT_STARTING_LETSENCRYPT_UPDATE_0)); CmsLetsEncryptConfiguration config = OpenCms.getLetsEncryptConfig(); if ((config == null) || !config.isValidAndEnabled()) { return; } CmsSiteConfigToLetsEncryptConfigConverter converter = new CmsSiteConfigToLetsEncryptConfigConverter(config); boolean ok = converter.run(getReport(), OpenCms.getSiteManager()); if (ok) { getReport().println( org.opencms.ui.apps.Messages.get().container(org.opencms.ui.apps.Messages.RPT_LETSENCRYPT_FINISHED_0), I_CmsReport.FORMAT_OK); } }
[ "Updates LetsEncrypt configuration." ]
[ "Method to send Request messages to a specific df_service\n\n@param df_service\nThe name of the df_service\n@param msgContent\nThe content of the message to be sent\n@return Message sent to + the name of the df_service", "Acquires a write lock on a specific key.\n@param key The key to lock\n@param timeout in milliseconds; -1 means wait indefinitely, 0 means no wait.", "Get a list of tags for the specified photo.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@param photoId\nThe photo ID\n@return The collection of Tag objects", "Registers all custom Externalizer implementations that Hibernate OGM needs into a running\nInfinispan CacheManager configuration.\nThis is only safe to do when Caches from this CacheManager haven't been started yet,\nor the ones already started do not contain any data needing these.\n\n@see ExternalizerIds\n@param globalCfg the Serialization section of a GlobalConfiguration builder", "Use this API to delete nsacl6 of given name.", "Diagnostic method used to dump known field map data.\n\n@param props props block containing field map data", "Creates the string mappings.\n\n@param mtasTokenIdFactory\nthe mtas token id factory\n@param level\nthe level\n@param stringValue\nthe string value\n@param offsetStart\nthe offset start\n@param offsetEnd\nthe offset end\n@param position\nthe position\n@throws IOException\nSignals that an I/O exception has occurred.", "add a foreign key field", "Sets the target hosts from json path.\n\n@param jsonPath\nthe json path\n@param sourcePath\nthe source path\n@param sourceType\nthe source type\n@return the parallel task builder\n@throws TargetHostsLoadException\nthe target hosts load exception" ]
protected String extractHeaderComment( File xmlFile ) throws MojoExecutionException { try { SAXParser parser = SAXParserFactory.newInstance().newSAXParser(); SaxHeaderCommentHandler handler = new SaxHeaderCommentHandler(); parser.setProperty( "http://xml.org/sax/properties/lexical-handler", handler ); parser.parse( xmlFile, handler ); return handler.getHeaderComment(); } catch ( Exception e ) { throw new MojoExecutionException( "Failed to parse XML from " + xmlFile, e ); } }
[ "This method extracts the XML header comment if available.\n\n@param xmlFile is the XML {@link File} to parse.\n@return the XML comment between the XML header declaration and the root tag or <code>null</code> if NOT\navailable.\n@throws MojoExecutionException if anything goes wrong." ]
[ "Used to determine if the current method should be ignored.\n\n@param name method name\n@return true if the method should be ignored", "Builds the HTML code for a select widget given a bean containing the select options\n\n@param htmlAttributes html attributes for the select widget\n@param options the bean containing the select options\n\n@return the HTML for the select box", "Use this API to fetch sslfipskey resource of given name .", "Login for a specific authentication, creating a specific token if given.\n\n@param token token to use\n@param authentication authentication to assign to token\n@return token", "Checks if two parameterized types are exactly equal, under the variable\nreplacement described in the typeVarMap.", "Return the \"common\" configuration set name. By default it is \"common\"\n@return the \"common\" conf set name", "Return the build string of this instance of finmath-lib.\nCurrently this is the Git commit hash.\n\n@return The build string of this instance of finmath-lib.", "Boyer Moore scan that proceeds backwards from the end of the file looking for endsig\n\n@param file the file being checked\n@param channel the channel\n@param context the scan context\n@return\n@throws IOException", "Check the given JWT\n\n@param jwtString the JSON Web Token\n@return the parsed and verified token or null if token is invalid\n@throws ParseException if the token cannot be parsed" ]
private static <D extends DatastoreConfiguration<G>, G extends GlobalContext<?, ?>> AppendableConfigurationContext invokeOptionConfigurator( OptionConfigurator configurator) { ConfigurableImpl configurable = new ConfigurableImpl(); configurator.configure( configurable ); return configurable.getContext(); }
[ "Invokes the given configurator, obtaining the correct global context type via the datastore configuration type of\nthe current datastore provider.\n\n@param configurator the configurator to invoke\n@return a context object containing the options set via the given configurator" ]
[ "Drops a driver from the DriverManager's list.", "Parses values out of the header text.\n\n@param header header text", "Make sure that we have some reasonable defaults available. These would typically be provided by the rulesets\nin the real world.", "Returns a OkHttpClient that ignores SSL cert errors\n@return", "Generates a Map of query parameters for Artifact regarding the filters\n\n@return Map<String, Object>", "Provides an object that can build SQL clauses to match this string representation.\n\nThis method can be overridden for other IP address types to match in their own ways.\n\n@param isEntireAddress\n@param translator\n@return", "build the Join-Information if a super reference exists\n\n@param left\n@param cld\n@param name", "Create constant name.\n@param state STATE_UNCHANGED, STATE_CHANGED, STATE_NEW or STATE_DELETED.\n@return cconstanname as String", "Adds a procedure argument definition to this class descriptor.\n\n@param argDef The procedure argument definition" ]
public static boolean doAcquireLock(final Jedis jedis, final String namespace, final String lockName, final String lockHolder, final int timeout) { final String key = JesqueUtils.createKey(namespace, lockName); // If lock already exists, extend it String existingLockHolder = jedis.get(key); if ((existingLockHolder != null) && existingLockHolder.equals(lockHolder)) { if (jedis.expire(key, timeout) == 1) { existingLockHolder = jedis.get(key); if ((existingLockHolder != null) && existingLockHolder.equals(lockHolder)) { return true; } } } // Check to see if the key exists and is expired for cleanup purposes if (jedis.exists(key) && (jedis.ttl(key) < 0)) { // It is expired, but it may be in the process of being created, so // sleep and check again try { Thread.sleep(2000); } catch (InterruptedException ie) { } // Ignore interruptions if (jedis.ttl(key) < 0) { existingLockHolder = jedis.get(key); // If it is our lock mark the time to live if ((existingLockHolder != null) && existingLockHolder.equals(lockHolder)) { if (jedis.expire(key, timeout) == 1) { existingLockHolder = jedis.get(key); if ((existingLockHolder != null) && existingLockHolder.equals(lockHolder)) { return true; } } } else { // The key is expired, whack it! jedis.del(key); } } else { // Someone else locked it while we were sleeping return false; } } // Ignore the cleanup steps above, start with no assumptions test // creating the key if (jedis.setnx(key, lockHolder) == 1) { // Created the lock, now set the expiration if (jedis.expire(key, timeout) == 1) { // Set the timeout existingLockHolder = jedis.get(key); if ((existingLockHolder != null) && existingLockHolder.equals(lockHolder)) { return true; } } else { // Don't know why it failed, but for now just report failed // acquisition return false; } } // Failed to create the lock return false; }
[ "Helper method that encapsulates the logic to acquire a lock.\n\n@param jedis\nthe connection to Redis\n@param namespace\nthe Resque namespace\n@param lockName\nall calls to this method will contend for a unique lock with\nthe name of lockName\n@param timeout\nseconds until the lock will expire\n@param lockHolder\na unique string used to tell if you are the current holder of\na lock for both acquisition, and extension\n@return Whether or not the lock was acquired." ]
[ "Locate the no arg constructor for the class.", "Clears the internal used cache for object materialization.", "Use this API to convert sslpkcs12.", "Get interfaces implemented by clazz\n\n@param clazz\n@return", "Set the classpath for loading the driver.\n\n@param classpath the classpath", "Set keyboard done listener to detect when the user click \"DONE\" on his keyboard\n\n@param listener IntlPhoneInputListener", "Returns a description String based on the defined command and options.\nUseful when printing \"help\" info etc.", "Call the onQueryExecuteTimeLimitExceeded hook if necessary\n@param sql sql statement that took too long\n@param queryStartTime time when query was started.", "Generate the specified output file by merging the specified\nVelocity template with the supplied context." ]
@JmxGetter(name = "avgSlopUpdateNetworkTimeMs", description = "average time spent on network, for streaming operations") public double getAvgSlopUpdateNetworkTimeMs() { return networkTimeCounterMap.get(Operation.SLOP_UPDATE).getAvgEventValue() / Time.NS_PER_MS; }
[ "Mbeans for SLOP_UPDATE" ]
[ "Import user from file.", "1-D Perlin noise function.\n\n@param x X Value.\n@return Returns function's value at point x.", "Use this API to update dbdbprofile.", "Read custom property definitions for tasks.\n\n@param gpTasks GanttProject tasks", "Counts a single pair of coordinates in all datasets.\n\n@param xCoord\n@param yCoord\n@param itemDocument", "Find a toBuilder method, if the user has provided one.", "Create the actual patchable target.\n\n@param name the layer name\n@param layer the layer path config\n@param metadata the metadata location for this target\n@param image the installed image\n@return the patchable target\n@throws IOException", "Turns a series of strings into their corresponding license entities\nby using regular expressions\n\n@param licStrings The list of license strings\n@return A set of license entities", "Get file size\n\n@return Long" ]
public void sendJsonToTagged(Object data, String ... labels) { for (String label : labels) { sendJsonToTagged(data, label); } }
[ "Send JSON representation of given data object to all connections tagged with all give tag labels\n@param data the data object\n@param labels the tag labels" ]
[ "Returns an input stream that applies the required decompression to the\ngiven input stream.\n\n@param inputStream\nthe input stream with the (possibly compressed) data\n@param compressionType\nthe kind of compression\n@return an input stream with decompressed data\n@throws IOException\nif there was a problem creating the decompression streams", "Use this API to Import sslfipskey.", "Parse work units.\n\n@param value work units value\n@return TimeUnit instance", "Maps the text representation of column data to Java types.\n\n@param table table name\n@param column column name\n@param data text representation of column data\n@param type column data type\n@param epochDateFormat true if date is represented as an offset from an epoch\n@return Java representation of column data\n@throws MPXJException", "Dump an array of bytes in hexadecimal.\n\n@param displayOffset the display offset (left column)\n@param data the byte array of data\n@param offset the offset to start dumping in the byte array\n@param len the length of data to dump\n@return the dump string", "Resizes the array that represents this bit vector.\n\n@param newArraySize\nnew array size", "Checks given permissions are needed to show rationale.\n\n@return returns true if one of the permission is needed to show rationale.", "Scales the brightness of a pixel.", "Returns redirect information for the given ID\n\n@param id ID of redirect\n@return ServerRedirect\n@throws Exception exception" ]
public static String get(String language) { language = language.toLowerCase(); if("ecmascript".equals(language)) { language = "javascript"; } String extension = extensions.get(language); if(extension == null) { return null; } else { return loadScriptEnv(language, extension); } }
[ "Get the spin scripting environment\n\n@param language the language name\n@return the environment script as string or null if the language is\nnot in the set of languages supported by spin." ]
[ "Remove any overrides for an endpoint\n\n@param pathValue path (endpoint) value\n@param requestType path request type. \"GET\", \"POST\", etc\n@return true if success, false otherwise", "Resize picture to desired size.\n\n@param width Desired width.\n@param height Desired height.\n@throws IllegalArgumentException if {@code width} or {@code height} is less than 0 or both are\n0.", "Register the ChangeHandler to become notified if the user changes the slider.\nThe Handler is called when the user releases the mouse only at the end of the slide\noperation.", "Use this API to fetch all the appfwprofile resources that are configured on netscaler.", "Prepares Artifactory server either from serverID or from ArtifactoryServer.\n\n@param artifactoryServerID\n@param pipelineServer\n@return", "Opens a new FileOutputStream for a file of the given name in the given\nresult directory. Any file of this name that exists already will be\nreplaced. The caller is responsible for eventually closing the stream.\n\n@param resultDirectory\nthe path to the result directory\n@param filename\nthe name of the file to write to\n@return FileOutputStream for the file\n@throws IOException\nif the file or example output directory could not be created", "Performs a partial BFS on model until the search frontier reaches the desired bootstrap size\n\n@param min the desired bootstrap size\n@return a list of found PossibleState\n@throws ModelException if the desired bootstrap can not be reached", "Locks a file.\n\n@param expiresAt expiration date of the lock.\n@param isDownloadPrevented is downloading of file prevented when locked.\n@return the lock returned from the server.", "Creates a Bytes object by copying the value of the given String with a given charset" ]
public BoxAPIResponse send(ProgressListener listener) { if (this.api == null) { this.backoffCounter.reset(BoxGlobalSettings.getMaxRequestAttempts()); } else { this.backoffCounter.reset(this.api.getMaxRequestAttempts()); } while (this.backoffCounter.getAttemptsRemaining() > 0) { try { return this.trySend(listener); } catch (BoxAPIException apiException) { if (!this.backoffCounter.decrement() || !isResponseRetryable(apiException.getResponseCode())) { throw apiException; } try { this.resetBody(); } catch (IOException ioException) { throw apiException; } try { this.backoffCounter.waitBackoff(); } catch (InterruptedException interruptedException) { Thread.currentThread().interrupt(); throw apiException; } } } throw new RuntimeException(); }
[ "Sends this request while monitoring its progress and returns a BoxAPIResponse containing the server's response.\n\n<p>A ProgressListener is generally only useful when the size of the request is known beforehand. If the size is\nunknown, then the ProgressListener will be updated for each byte sent, but the total number of bytes will be\nreported as 0.</p>\n\n<p> See {@link #send} for more information on sending requests.</p>\n\n@param listener a listener for monitoring the progress of the request.\n@throws BoxAPIException if the server returns an error code or if a network error occurs.\n@return a {@link BoxAPIResponse} containing the server's response." ]
[ "Get random stub matching this user type\n@param userType User type\n@return Random stub", "Broadcast a packet that tells some players to start playing and others to stop. If a player number is in\nboth sets, it will be told to stop. Numbers outside the range 1 to 4 are ignored.\n\n@param deviceNumbersToStart the players that should start playing if they aren't already\n@param deviceNumbersToStop the players that should stop playing\n\n@throws IOException if there is a problem broadcasting the command to the players\n@throws IllegalStateException if the {@code VirtualCdj} is not active", "convert object into another class using the JSON mapper\n\n@param <C> the generic target type\n@param object the object to convert\n@param targetClass the class of the target object\n@return the converted object\n@throws IllegalArgumentException if conversion fails", "LV morphology helper functions", "Use this API to add dnsview resources.", "Checks to see if the token is in the list of allowed character operations. Used to apply order of operations\n@param token Token being checked\n@param ops List of allowed character operations\n@return true for it being in the list and false for it not being in the list", "Switches from a sparse to dense matrix", "Use this API to fetch lbvserver resource of given name .", "This method extracts data for a single resource from a GanttProject file.\n\n@param gpResource resource data" ]
public Class<?> getType(String key) { Object val = this.data.get(key); return val == null ? null : val.getClass(); }
[ "Get the current attribute type.\n@param key the entry's key, not null\n@return the current attribute type, or null, if no such attribute exists." ]
[ "Check if the current node is part of routing request based on cluster.xml\nor throw an exception.\n\n@param key The key we are checking\n@param routingStrategy The routing strategy\n@param currentNode Current node", "Returns the time elapsed by the user on the app\n@return Time elapsed by user on the app in int", "get the property source method corresponding to given destination\nproperty\n\n@param sourceObject\n@param destinationObject\n@param destinationProperty\n@return", "create a HashMap form the json properties and add it to the shape\n@param modelJSON\n@param current\n@throws org.json.JSONException", "Retrieves a vertex attribute as a float buffer.\nThe attribute name must be one of the\nattributes named in the descriptor passed to the constructor.\n@param attributeName name of the attribute to update\n@throws IllegalArgumentException if attribute name not in descriptor vertex attribute is not <i>float</i>\n@see #setFloatArray(String, float[])\n@see #getFloatVec(String)", "Executes the given xpath and returns the result with the type specified.", "Gives an sequence of ByteBuffers of a specified range. Writing to these ByteBuffers modifies the contents of this LBuffer.\n@param offset\n@param size\n@return", "Generate the next permutation and return an array containing\nthe elements in the appropriate order.\n@see #nextPermutationAsArray(Object[])\n@see #nextPermutationAsList()\n@return The next permutation as an array.", "Set an unknown field.\n@param name the unknown property name\n@param value the unknown property value" ]
public void increasePriority(int overrideId, int ordinal, int pathId, String clientUUID) { logger.info("Increase priority"); int origPriority = -1; int newPriority = -1; int origId = 0; int newId = 0; PreparedStatement statement = null; ResultSet results = null; try (Connection sqlConnection = sqlService.getConnection()) { results = null; statement = sqlConnection.prepareStatement( "SELECT * FROM " + Constants.DB_TABLE_ENABLED_OVERRIDE + " WHERE " + Constants.ENABLED_OVERRIDES_PATH_ID + " = ?" + " AND " + Constants.GENERIC_CLIENT_UUID + " = ?" + " ORDER BY " + Constants.ENABLED_OVERRIDES_PRIORITY ); statement.setInt(1, pathId); statement.setString(2, clientUUID); results = statement.executeQuery(); int ordinalCount = 0; while (results.next()) { if (results.getInt(Constants.ENABLED_OVERRIDES_OVERRIDE_ID) == overrideId) { ordinalCount++; if (ordinalCount == ordinal) { origPriority = results.getInt(Constants.ENABLED_OVERRIDES_PRIORITY); origId = results.getInt(Constants.GENERIC_ID); break; } } newPriority = results.getInt(Constants.ENABLED_OVERRIDES_PRIORITY); newId = results.getInt(Constants.GENERIC_ID); } } catch (Exception e) { e.printStackTrace(); } finally { try { if (results != null) { results.close(); } } catch (Exception e) { } try { if (statement != null) { statement.close(); } } catch (Exception e) { } } try (Connection sqlConnection = sqlService.getConnection()) { // update priorities if (origPriority != -1 && newPriority != -1) { statement = sqlConnection.prepareStatement( "UPDATE " + Constants.DB_TABLE_ENABLED_OVERRIDE + " SET " + Constants.ENABLED_OVERRIDES_PRIORITY + "=?" + " WHERE " + Constants.GENERIC_ID + "=?" ); statement.setInt(1, origPriority); statement.setInt(2, newId); statement.executeUpdate(); statement.close(); statement = sqlConnection.prepareStatement( "UPDATE " + Constants.DB_TABLE_ENABLED_OVERRIDE + " SET " + Constants.ENABLED_OVERRIDES_PRIORITY + "=?" + " WHERE " + Constants.GENERIC_ID + "=?" ); statement.setInt(1, newPriority); statement.setInt(2, origId); statement.executeUpdate(); } } catch (Exception e) { } finally { try { if (statement != null) { statement.close(); } } catch (Exception e) { } } }
[ "Increase the priority of an overrideId\n\n@param overrideId ID of override\n@param pathId ID of path containing override\n@param clientUUID UUID of client" ]
[ "Converts a string representation of an integer into an Integer object.\nSilently ignores any parse exceptions and returns null.\n\n@param value String representation of an integer\n@return Integer instance", "Gets the txinfo cache weight\n\n@param conf The FluoConfiguration\n@return The size of the cache value from the property value {@value #TX_INFO_CACHE_WEIGHT} if\nit is set, else the value of the default value {@value #TX_INFO_CACHE_WEIGHT_DEFAULT}", "Writes this address as a single hexadecimal value with always the exact same number of characters, with or without a preceding 0x prefix.", "Get an exception reporting an unexpected end tag for an XML element.\n@param reader the stream reader\n@return the exception", "Method to declare Video-VideoRenderer mapping.\nFavorite videos will be rendered using FavoriteVideoRenderer.\nLive videos will be rendered using LiveVideoRenderer.\nLiked videos will be rendered using LikeVideoRenderer.\n\n@param content used to map object-renderers.\n@return VideoRenderer subtype class.", "Evaluates the body if value for the member tag equals the specified value.\n\n@param template The body of the block tag\n@param attributes The attributes of the template tag\n@exception XDocletException If an error occurs\[email protected] type=\"block\"\[email protected] name=\"tagName\" optional=\"false\" description=\"The tag name.\"\[email protected] name=\"paramName\" description=\"The parameter name. If not specified, then the raw\ncontent of the tag is returned.\"\[email protected] name=\"paramNum\" description=\"The zero-based parameter number. It's used if the user\nused the space-separated format for specifying parameters.\"\[email protected] name=\"value\" optional=\"false\" description=\"The expected value.\"", "This method writes data for a single calendar to an MSPDI file.\n\n@param bc Base calendar data\n@return New MSPDI calendar instance", "This method returns the value random variable of the product within the specified model,\nevaluated at a given evalutationTime.\nCash-flows prior evaluationTime are not considered.\n\n@param evaluationTime The time on which this products value should be observed.\n@param model The model used to price the product.\n@return The random variable representing the value of the product discounted to evaluation time.\n@throws net.finmath.exception.CalculationException Thrown if the valuation fails, specific cause may be available via the <code>cause()</code> method.", "Returns an array specifing the index of each hull vertex with respect to\nthe original input points.\n\n@return vertex indices with respect to the original points" ]
public static final BigInteger printConstraintType(ConstraintType value) { return (value == null ? null : BigInteger.valueOf(value.getValue())); }
[ "Print a constraint type.\n\n@param value ConstraintType instance\n@return constraint type value" ]
[ "Exception handler if we are unable to parse a json value into a java representation\n\n@param expectedType Name of the expected Type\n@param type Type of the json node\n@return SpinJsonDataFormatException", "Get a list of referring domains for a photostream.\n\n@param date\n(Required) Stats will be returned for this date. A day according to Flickr Stats starts at midnight GMT for all users, and timestamps will\nautomatically be rounded down to the start of the day.\n@param perPage\n(Optional) Number of domains to return per page. If this argument is omitted, it defaults to 25. The maximum allowed value is 100.\n@param page\n(Optional) The page of results to return. If this argument is omitted, it defaults to 1.\n@see \"http://www.flickr.com/services/api/flickr.stats.getPhotostreamDomains.html\"", "Deserialize a directory of javascript design documents to a List of DesignDocument objects.\n\n@param directory the directory containing javascript files\n@return {@link DesignDocument}\n@throws FileNotFoundException if the file does not exist or cannot be read", "Create a new DateTime. To the last second. This will not create any\nextra-millis-seconds, which may cause bugs when writing to stores such as\ndatabases that round milli-seconds up and down.", "create a broker with given broker info\n\n@param id broker id\n@param brokerInfoString broker info format: <b>creatorId:host:port:autocreated</b>\n@return broker instance with connection config\n@see #getZKString()", "Use this API to fetch nssimpleacl resource of given name .", "Specialized version of readValue just for reading map keys, because the StdDeserializer methods like\n_parseIntPrimitive blow up when the current JsonToken is FIELD_NAME", "Create and return a new Violation for this rule and the specified import\n@param sourceCode - the SourceCode\n@param importNode - the ImportNode for the import triggering the violation\n@return a new Violation object", "Gets a single byte return or -1 if no data is available." ]
private Integer mapTaskID(Integer id) { Integer mappedID = m_clashMap.get(id); if (mappedID == null) { mappedID = id; } return (mappedID); }
[ "Deals with the case where we have had to map a task ID to a new value.\n\n@param id task ID from database\n@return mapped task ID" ]
[ "Used to retrieve all metadata associated with the item.\n@param item item to get metadata for.\n@param fields the optional fields to retrieve.\n@return An iterable of metadata instances associated with the item.", "callers of doLogin should be serialized before calling in.", "Returns the data about all of the plugins that are set\n\n@param onlyValid True to get only valid plugins, False for all\n@return array of Plugins set", "The Maven3Builder class is looking for the PATH+JDK environment variable due to legacy code.\nIn The pipeline flow we need to convert the JAVA_HOME to PATH+JDK in order to reuse the code.", "Create a new DirectByteBuffer from a given address and size.\nThe returned DirectByteBuffer does not release the memory by itself.\n\n@param addr\n@param size\n@param att object holding the underlying memory to attach to the buffer.\nThis will prevent the garbage collection of the memory area that's\nassociated with the new <code>DirectByteBuffer</code>\n@return", "For the DC to check whether an operation should be ignored on the slave, if the slave is set up to ignore config not relevant to it\n\n@param domainResource the domain root resource\n@param serverConfigs the server configs the slave is known to have\n@param pathAddress the address of the operation to check if should be ignored or not", "Get a System property by its name.\n\n@param name the name of the wanted System property.\n@return the System property value - null if it is not defined.", "Converts the suggestions from the Solrj format to JSON format.\n\n@param response The SpellCheckResponse object containing the spellcheck results.\n@return The spellcheck suggestions as JSON object or null if something goes wrong.", "Detach a connection from a key.\n\n@param key\nthe key\n@param connection\nthe connection" ]
public boolean isHomeKeyPresent() { final GVRApplication application = mApplication.get(); if (null != application) { final String model = getHmtModel(); if (null != model && model.contains("R323")) { return true; } } return false; }
[ "Does the headset the device is docked into have a dedicated home key\n@return" ]
[ "Load physics information for the current avatar\n@param filename name of physics file\n@param scene scene the avatar is part of\n@throws IOException if physics file cannot be parsed", "URLDecode a string\n@param s\n@return", "calculate and set position to menu items", "Returns the instance.\n@return InterceptorFactory", "Starts the compressor.", "Converts the given list of a type to paged list of a different type.\n\n@param list the list to convert to paged list\n@param mapper the mapper to map type in input list to output list\n@param <OutT> the type of items in output paged list\n@param <InT> the type of items in input paged list\n@return the paged list", "List the photos with the most views, comments or favorites.\n\n@param date\n(Optional) Stats will be returned for this date. A day according to Flickr Stats starts at midnight GMT for all users, and timestamps will\nautomatically be rounded down to the start of the day. If no date is provided, all time view counts will be returned.\n@param sort\n(Optional) The order in which to sort returned photos. Defaults to views. The possible values are views, comments and favorites. Other sort\noptions are available through flickr.photos.search.\n@param perPage\n(Optional) Number of referrers to return per page. If this argument is omitted, it defaults to 25. The maximum allowed value is 100.\n@param page\n(Optional) The page of results to return. If this argument is omitted, it defaults to 1.\n@throws FlickrException\n@see \"http://www.flickr.com/services/api/flickr.stats.getPopularPhotos.html\"", "Enable the use of the given controller type by\nadding it to the cursor controller types list.\n@param controllerType GVRControllerType to add to the list", "Answer the TableAlias for aPath\n@param aPath\n@param hintClasses\n@return TableAlias, null if none" ]
private void checkMessageID(Message message) { if (!MessageUtils.isOutbound(message)) return; AddressingProperties maps = ContextUtils.retrieveMAPs(message, false, MessageUtils.isOutbound(message)); if (maps == null) { maps = new AddressingProperties(); } if (maps.getMessageID() == null) { String messageID = ContextUtils.generateUUID(); boolean isRequestor = ContextUtils.isRequestor(message); maps.setMessageID(ContextUtils.getAttributedURI(messageID)); ContextUtils.storeMAPs(maps, message, ContextUtils.isOutbound(message), isRequestor); } }
[ "check if MessageID exists in the message, if not, only generate new MessageID for outbound message.\n@param message" ]
[ "Awaits at most 5 minutes until all pods meets the given predicate.\n\n@param filter used to wait to detect that a pod is up and running.", "Counts the coordinates stored in a single statement for the relevant\nproperty, if they are actually given and valid.\n\n@param statement\n@param itemDocument", "Saves the favorites.\n\n@param favorites the list of favorites to save\n@throws CmsException if something goes wrong", "Use this API to add dnssuffix resources.", "Sets a new config and clears the previous cache", "Use this API to update cmpparameter.", "Read resource assignment baseline values.\n\n@param row result set row", "If the DefaultActionInvocation has been executed before and the Result is\nan instance of ActionChainResult, this method will walk down the chain of\nActionChainResults until it finds a non-chain result, which will be\nreturned. If the DefaultActionInvocation's result has not been executed\nbefore, the Result instance will be created and populated with the result\nparams.\n\n@return a Result instance\n@throws Exception", "Set session factory.\n\n@param sessionFactory session factory\n@throws HibernateLayerException could not get class metadata for data source" ]
private int readOptionalInt(JSONValue val) { JSONString str = null == val ? null : val.isString(); if (str != null) { try { return Integer.valueOf(str.stringValue()).intValue(); } catch (@SuppressWarnings("unused") NumberFormatException e) { // Do nothing, return default value } } return 0; }
[ "Read an optional int value form a JSON value.\n@param val the JSON value that should represent the int.\n@return the int from the JSON or 0 reading the int fails." ]
[ "find the middle point of two intersect points in circle,only one point will be correct\n\n@param center\n@param a\n@param b\n@param area\n@param radius\n@return", "Creates a color item that represents a color field fond for a track.\n\n@param colorId the key of the color as found in the database\n@param label the corresponding color label as found in the database (or sent in the dbserver message)\n\n@return the color metadata field", "Called just before the thread finishes, regardless of status, to take any necessary action on\nthe downloaded file with mDownloadedCacheSize file.\n\n@param forceClean - It will delete downloaded cache, Even streaming is enabled, If user intentionally cancelled.", "Return the area polygon as the only feature in the feature collection.\n\n@param mapAttributes the attributes that this aoi is part of.", "Construct a new instance.\n\n@return the new instance", "Use this API to fetch lbvserver_auditnslogpolicy_binding resources of given name .", "Finds all variables in the context with the given names, and also attaches all WindupFreeMarkerMethods from all addons into the map.\n\nThis allows external addons to extend the capabilities in the freemarker reporting system.", "Returns the text content to any HTML.\n\n@param html the HTML\n\n@return the text content", "Check if the path to the property correspond to an association.\n\n@param targetTypeName the name of the entity containing the property\n@param pathWithoutAlias the path to the property WITHOUT aliases\n@return {@code true} if the property is an association or {@code false} otherwise" ]
private void readRecord(Tokenizer tk, List<String> record) throws IOException { record.clear(); while (tk.nextToken() == Tokenizer.TT_WORD) { record.add(tk.getToken()); } }
[ "Reads each token from a single record and adds it to a list.\n\n@param tk tokenizer\n@param record list of tokens\n@throws IOException" ]
[ "Maps the text representation of column data to Java types.\n\n@param table table name\n@param column column name\n@param data text representation of column data\n@param type column data type\n@param epochDateFormat true if date is represented as an offset from an epoch\n@return Java representation of column data\n@throws MPXJException", "Use this API to fetch vpnvserver_authenticationsamlpolicy_binding resources of given name .", "Get a log file and last relevant date, and check if the log file is relevant\n@param currentLogFile The log file\n@param lastRelevantDate The last date which files should be keeping since\n@return false if the file should be deleted, true if it does not.", "Extract and return the table name for a class.", "Main method to run the bot.\n\n@param args\n@throws LoginFailedException\n@throws IOException\n@throws MediaWikiApiErrorException", "Get the bytes which represent the payload of this field, without the leading type tag and length header, as\na newly-allocated byte array.\n\n@return a new byte array containing a copy of the bytes this field contains", "Receive an expected number of bytes from the player, logging a warning if we get a different number of them.\n\n@param is the input stream associated with the player metadata socket.\n@param size the number of bytes we expect to receive.\n@param description the type of response being processed, for use in the warning message.\n@return the bytes read.\n\n@throws IOException if there is a problem reading the response.", "Get the FieldDescriptor for the PathInfo\n\n@param aTableAlias\n@param aPathInfo\n@return FieldDescriptor", "Adds a file to your assembly but automatically generates the field name of the file.\n\n@param file {@link File} the file to be uploaded." ]
public static base_response add(nitro_service client, onlinkipv6prefix resource) throws Exception { onlinkipv6prefix addresource = new onlinkipv6prefix(); addresource.ipv6prefix = resource.ipv6prefix; addresource.onlinkprefix = resource.onlinkprefix; addresource.autonomusprefix = resource.autonomusprefix; addresource.depricateprefix = resource.depricateprefix; addresource.decrementprefixlifetimes = resource.decrementprefixlifetimes; addresource.prefixvalidelifetime = resource.prefixvalidelifetime; addresource.prefixpreferredlifetime = resource.prefixpreferredlifetime; return addresource.add_resource(client); }
[ "Use this API to add onlinkipv6prefix." ]
[ "Initializes the mode switcher.\n@param current the current edit mode", "Used to retrieve all metadata associated with the item.\n@param item item to get metadata for.\n@param fields the optional fields to retrieve.\n@return An iterable of metadata instances associated with the item.", "Removes a value from the list box. Nothing is done if the value isn't on\nthe list box.\n\n@param value the value to be removed from the list\n@param reload perform a 'material select' reload to update the DOM.", "Use this API to delete gslbsite of given name.", "Assigns this retention policy to folder.\n@param folder the folder to assign policy to.\n@return info about created assignment.", "The default User-Agent header. Override this method to override the user agent.\n\n@return the user agent string.", "marks the message as read", "Checks if the given argument is null and throws an exception with a\nmessage containing the argument name if that it true.\n\n@param argument the argument to check for null\n@param argumentName the name of the argument to check.\nThis is used in the exception message.\n@param <T> the type of the argument\n@return the argument itself\n@throws IllegalArgumentException in case argument is null", "Determines whether the given array only contains unbounded type variables or Object.class.\n\n@param types the given array of types\n@return true if and only if the given array only contains unbounded type variables or Object.class" ]
public static base_response add(nitro_service client, snmpmanager resource) throws Exception { snmpmanager addresource = new snmpmanager(); addresource.ipaddress = resource.ipaddress; addresource.netmask = resource.netmask; addresource.domainresolveretry = resource.domainresolveretry; return addresource.add_resource(client); }
[ "Use this API to add snmpmanager." ]
[ "Use this API to disable vserver of given name.", "Builds sql clause to load data into a database.\n\n@param config Load configuration.\n@param prefix Prefix for temporary resources.\n@return the load DDL", "Lookup a PortComponentMetaData by wsdl-port local part\n\n@param name - the wsdl-port local part\n@return PortComponentMetaData if found, null otherwise", "Set the TimeSensor's cycleInterval property\nCurrently, this does not change the duration of the animation.\n@param newCycleInterval", "Convenience routine to return the specified error's\nunderlying SyntaxException, or null if it isn't one.", "Returns the y-coordinate of a vertex normal.\n\n@param vertex the vertex index\n@return the y coordinate", "Adds a new email alias to this user's account and confirms it without user interaction.\nThis functionality is only available for enterprise admins.\n@param email the email address to add as an alias.\n@param isConfirmed whether or not the email alias should be automatically confirmed.\n@return the newly created email alias.", "This method lists task predecessor and successor relationships.\n\n@param file project file", "Given the current cluster and a zone id that needs to be dropped, this\nmethod will remove all partitions from the zone that is being dropped and\nmove it to the existing zones. The partitions are moved intelligently so\nas not to avoid any data movement in the existing zones.\n\nThis is achieved by moving the partitions to nodes in the surviving zones\nthat is zone-nry to that partition in the surviving zone.\n\n@param currentCluster Current cluster metadata\n@return Returns an interim cluster with empty partition lists on the\nnodes from the zone being dropped" ]
protected TokenList.Token parseSubmatrixToExtract(TokenList.Token variableTarget, TokenList tokens, Sequence sequence) { List<TokenList.Token> inputs = parseParameterCommaBlock(tokens, sequence); List<Variable> variables = new ArrayList<Variable>(); // for the operation, the first variable must be the matrix which is being manipulated variables.add(variableTarget.getVariable()); addSubMatrixVariables(inputs, variables); if( variables.size() != 2 && variables.size() != 3 ) { throw new ParseError("Unexpected number of variables. 1 or 2 expected"); } // first parameter is the matrix it will be extracted from. rest specify range Operation.Info info; // only one variable means its referencing elements // two variables means its referencing a sub matrix if( inputs.size() == 1 ) { Variable varA = variables.get(1); if( varA.getType() == VariableType.SCALAR ) { info = functions.create("extractScalar", variables); } else { info = functions.create("extract", variables); } } else if( inputs.size() == 2 ) { Variable varA = variables.get(1); Variable varB = variables.get(2); if( varA.getType() == VariableType.SCALAR && varB.getType() == VariableType.SCALAR) { info = functions.create("extractScalar", variables); } else { info = functions.create("extract", variables); } } else { throw new ParseError("Expected 2 inputs to sub-matrix"); } sequence.addOperation(info.op); return new TokenList.Token(info.output); }
[ "Converts a submatrix into an extract matrix operation.\n@param variableTarget The variable in which the submatrix is extracted from" ]
[ "Use this API to rename a gslbservice resource.", "Use this API to update responderpolicy.", "set the property destination type for given property\n\n@param propertyName\n@param destinationType", "Merge two maps of configuration properties. If the original contains a mapping for the same key, the new mapping is ignored.\n\n@param original\n@param toMerge", "Log a trace message.", "Boyer Moore scan that proceeds backwards from the end of the file looking for endsig\n\n@param file the file being checked\n@param channel the channel\n@param context the scan context\n@return\n@throws IOException", "Get a System property by its name.\n\n@param name the name of the wanted System property.\n@return the System property value - null if it is not defined.", "Set the individual dates.\n@param dates the dates to set.", "convert object into another class using the JSON mapper\n\n@param <C> the generic target type\n@param object the object to convert\n@param targetClass the class of the target object\n@return the converted object\n@throws IllegalArgumentException if conversion fails" ]
private Task findChildTaskByUUID(ChildTaskContainer parent, UUID uuid) { Task result = null; for (Task task : parent.getChildTasks()) { if (uuid.equals(task.getGUID())) { result = task; break; } } return result; }
[ "Locates a task within a child task container which matches the supplied UUID.\n\n@param parent child task container\n@param uuid required UUID\n@return Task instance or null if the task is not found" ]
[ "Use this API to export sslfipskey.", "Helper method for formatting connection termination messages.\n\n@param connectionName\nThe name of the connection\n@param host\nThe remote host\n@param connectionReason\nThe reason for establishing the connection\n@param terminationReason\nThe reason for terminating the connection\n@return A formatted message in the format:\n\"[&lt;connectionName&gt;] remote host[&lt;host&gt;] &lt;connectionReason&gt; - &lt;terminationReason&gt;\"\n<br/>\ne.g. [con1] remote host[123.123.123.123] connection to ECMG -\nterminated by remote host.", "Use this API to fetch clusterinstance resource of given name .", "Get the collection of the server groups\n\n@return Collection of active server groups", "Adds OPT_N | OPT_NODE option to OptionParser, with multiple arguments.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional", "Use this API to fetch filtered set of sslglobal_sslpolicy_binding resources.\nset the filter parameter values in filtervalue object.", "Used to create a new retention policy.\n@param api the API connection to be used by the created user.\n@param name the name of the retention policy.\n@param type the type of the retention policy. Can be \"finite\" or \"indefinite\".\n@param length the duration in days that the retention policy will be active for after being assigned to content.\n@param action the disposition action can be \"permanently_delete\" or \"remove_retention\".\n@return the created retention policy's info.", "Start the rendering of the scalebar.", "Set the position of the given Matcher to the given index.\n\n@param matcher a Matcher\n@param idx the index number\n@since 1.0" ]
private static boolean isAssignableFrom(WildcardType type1, Type type2) { if (!isAssignableFrom(type1.getUpperBounds()[0], type2)) { return false; } if (type1.getLowerBounds().length > 0 && !isAssignableFrom(type2, type1.getLowerBounds()[0])) { return false; } return true; }
[ "This logic is shared for all actual types i.e. raw types, parameterized types and generic array types." ]
[ "Get a property as a float or throw an exception.\n\n@param key the property name", "Check whether the given class is cache-safe in the given context,\ni.e. whether it is loaded by the given ClassLoader or a parent of it.\n@param clazz the class to analyze\n@param classLoader the ClassLoader to potentially cache metadata in", "Add an appliable dependency for this task item.\n\n@param appliable the appliable dependency.\n@return the key to be used as parameter to taskResult(string) method to retrieve updated dependency", "This method prints goal information of an agent through its external\naccess. It can be used to check the correct behaviour of the agent.\n\n@param agent_name\nThe name of the agent\n@param connector\nThe connector to get the external access\n@return goals the IGoal[] with all the information, so the tester can\nlook for information", "Delete a photo from flickr.\n\nThis method requires authentication with 'delete' permission.\n\n@param photoId\n@throws FlickrException", "Rethrows platform specific OperationCanceledExceptions and unwraps OperationCanceledErrors. Does nothing for any other type of Throwable.", "Creates AzureAsyncOperation from the given HTTP response.\n\n@param serializerAdapter the adapter to use for deserialization\n@param response the response\n@return the async operation object\n@throws CloudException if the deserialization fails or response contains invalid body", "get the property source method corresponding to given destination\nproperty\n\n@param sourceObject\n@param destinationObject\n@param destinationProperty\n@return", "Updates metadata versions on stores.\n\n@param adminClient An instance of AdminClient points to given cluster\n@param oldStoreDefs List of old store definitions\n@param newStoreDefs List of new store definitions" ]
public Set<Action.ActionEffect> getActionEffects() { switch(getImpact()) { case CLASSLOADING: case WRITE: return WRITES; case READ_ONLY: return READS; default: throw new IllegalStateException(); } }
[ "Gets the effects of this action.\n\n@return the effects. Will not be {@code null}" ]
[ "Performs a variety of tests to see if the provided matrix is a valid\ncovariance matrix.\n\n@return 0 = is valid 1 = failed positive diagonal, 2 = failed on symmetry, 2 = failed on positive definite", "Gets the Taneja divergence.\n\n@param p P vector.\n@param q Q vector.\n@return The Taneja divergence between p and q.", "1-D Gabor function.\n\n@param x Value.\n@param mean Mean.\n@param amplitude Amplitude.\n@param position Position.\n@param width Width.\n@param phase Phase.\n@param frequency Frequency.\n@return Gabor response.", "Removes all commas from the token list", "Constructs the appropriate MenuDrawer based on the position.", "Processes one dump file with the given dump file processor, handling\nexceptions appropriately.\n\n@param dumpFile\nthe dump file to process\n@param dumpFileProcessor\nthe dump file processor to use", "Byte run automaton map.\n\n@param automatonMap the automaton map\n@return the map", "Handles week day changes.\n@param event the change event.", "Get the current stack trace element, skipping anything from known logging classes.\n@return The current stack trace for this thread" ]
public Token add( String word ) { Token t = new Token(word); push( t ); return t; }
[ "Adds a word to the end of the token list\n@param word word which is to be added\n@return The new Token created around symbol" ]
[ "Byte run automaton map.\n\n@param automatonMap the automaton map\n@return the map", "Walk through the object graph of the specified insert object. Was used for\nrecursive object graph walk.", "Updates the Q matrix to take inaccount the row that was removed by only multiplying e\nlements that need to be. There is still some room for improvement here...\n@param rowIndex", "Use this API to delete dnsaaaarec resources of given names.", "Registers add operation\n\n@param registration resource on which to register\n@param handler operation handler to register\n@param flags with flags\n@deprecated use {@link #registerAddOperation(org.jboss.as.controller.registry.ManagementResourceRegistration, AbstractAddStepHandler, org.jboss.as.controller.registry.OperationEntry.Flag...)}", "Generate a sql where-clause matching the contraints defined by the array of fields\n\n@param columns array containing all columns used in WHERE clause", "Blocking function which completes the migration of one store\n\n@param storeName The name of the store\n@param adminClient Admin client used to initiate the copying of data\n@param stealInfo The steal information\n@param isReadOnlyStore Boolean indicating that this is a read-only store", "To use main report datasource. There should be nothing else in the detail band\n@param preSorted\n@return", "Use this API to fetch all the systemuser resources that are configured on netscaler." ]
public static void fillHermitian(ZMatrixRMaj A, double min, double max, Random rand) { if( A.numRows != A.numCols ) throw new IllegalArgumentException("A must be a square matrix"); double range = max-min; int length = A.numRows; for( int i = 0; i < length; i++ ) { A.set(i,i,rand.nextDouble()*range + min,0); for( int j = i+1; j < length; j++ ) { double real = rand.nextDouble()*range + min; double imaginary = rand.nextDouble()*range + min; A.set(i,j,real,imaginary); A.set(j,i,real,-imaginary); } } }
[ "Assigns the provided square matrix to be a random Hermitian matrix with elements from min to max value.\n\n@param A The matrix that is to be modified. Must be square. Modified.\n@param min Minimum value an element can have.\n@param max Maximum value an element can have.\n@param rand Random number generator." ]
[ "Runs through the log removing segments until the size of the log is at least\nlogRetentionSize bytes in size\n\n@throws IOException", "Given the lambda value perform an implicit QR step on the matrix.\n\nB^T*B-lambda*I\n\n@param lambda Stepping factor.", "Merge msg bundles together, creating new MsgBundle with merges msg bundles passed in as a method argument", "Cancel a particular download in progress. Returns 1 if the download Id is found else returns 0.\n\n@param downloadId\n@return int", "Enables or disabled shadow casting for a direct light.\nEnabling shadows attaches a GVRShadowMap component to the\nGVRSceneObject which owns the light and provides the\ncomponent with an orthographic camera for shadow casting.\n@param enableFlag true to enable shadow casting, false to disable", "Returns a \"clean\" version of the given filename in which spaces have\nbeen converted to dashes and all non-alphanumeric chars are underscores.", "Configure file logging and stop console logging.\n\n@param filename\nLog to this file.", "Bessel function of order n.\n\n@param n Order.\n@param x Value.\n@return J value.", "Creates a sorted list that contains the items of the given iterable. The resulting list is sorted according to\nthe order induced by the specified comparator.\n\n@param iterable\nthe items to be sorted. May not be <code>null</code>.\n@param comparator\nthe comparator to be used. May be <code>null</code> to indicate that the natural ordering of the\nelements should be used.\n@return a sorted list as a shallow copy of the given iterable.\n@see Collections#sort(List, Comparator)\n@see #sort(Iterable)\n@see #sortBy(Iterable, org.eclipse.xtext.xbase.lib.Functions.Function1)\n@see ListExtensions#sortInplace(List, Comparator)\n@since 2.7" ]
@Override public synchronized boolean fireEventAndWait(Eventable eventable) throws ElementNotVisibleException, NoSuchElementException, InterruptedException { try { boolean handleChanged = false; boolean result = false; if (eventable.getRelatedFrame() != null && !eventable.getRelatedFrame().equals("")) { LOGGER.debug("switching to frame: " + eventable.getRelatedFrame()); try { switchToFrame(eventable.getRelatedFrame()); } catch (NoSuchFrameException e) { LOGGER.debug("Frame not found, possibly while back-tracking..", e); // TODO Stefan, This exception is caught to prevent stopping // from working // This was the case on the Gmail case; find out if not switching // (catching) // Results in good performance... } handleChanged = true; } WebElement webElement = browser.findElement(eventable.getIdentification().getWebDriverBy()); if (webElement != null) { result = fireEventWait(webElement, eventable); } if (handleChanged) { browser.switchTo().defaultContent(); } return result; } catch (ElementNotVisibleException | NoSuchElementException e) { throw e; } catch (WebDriverException e) { throwIfConnectionException(e); return false; } }
[ "Fires an event on an element using its identification.\n\n@param eventable The eventable.\n@return true if it is able to fire the event successfully on the element.\n@throws InterruptedException when interrupted during the wait." ]
[ "Handling out request.\n\n@param message\nthe message\n@throws Fault\nthe fault", "Creates a new child folder inside this folder.\n\n@param name the new folder's name.\n@return the created folder's info.", "Send a waveform detail update announcement to all registered listeners.\n\n@param player the player whose waveform detail has changed\n@param detail the new waveform detail, if any", "Remove a previously registered requirement for a capability.\n\n@param requirementRegistration the requirement. Cannot be {@code null}\n@see #registerAdditionalCapabilityRequirement(org.jboss.as.controller.capability.registry.RuntimeRequirementRegistration)", "Send Request Node info message to the controller.\n@param nodeId the nodeId of the node to identify\n@throws SerialInterfaceException when timing out or getting an invalid response.", "Returns the given collection persister for the inverse side in case the given persister represents the main side\nof a bi-directional many-to-many association.\n\n@param mainSidePersister the collection persister on the main side of a bi-directional many-to-many association\n@return the collection persister for the inverse side of the given persister or {@code null} in case it\nrepresents the inverse side itself or the association is uni-directional", "Add a new PropertyChangeListener to this node for a specific property.\nThis functionality has\nbeen borrowed from the java.beans package, though this class has\nnothing to do with a bean", "Calculates the world matrix based on the local matrix.", "generate a select-Statement according to query\n\n@param query the Query\n@param cld the ClassDescriptor" ]
private TreeMap<Integer, Integer> createResourceMap(FieldMap fieldMap, FixedMeta rscFixedMeta, FixedData rscFixedData) { TreeMap<Integer, Integer> resourceMap = new TreeMap<Integer, Integer>(); int itemCount = rscFixedMeta.getAdjustedItemCount(); for (int loop = 0; loop < itemCount; loop++) { byte[] data = rscFixedData.getByteArrayValue(loop); if (data == null || data.length < fieldMap.getMaxFixedDataSize(0)) { continue; } Integer uniqueID = Integer.valueOf(MPPUtility.getShort(data, 0)); resourceMap.put(uniqueID, Integer.valueOf(loop)); } return (resourceMap); }
[ "This method maps the resource unique identifiers to their index number\nwithin the FixedData block.\n\n@param fieldMap field map\n@param rscFixedMeta resource fixed meta data\n@param rscFixedData resource fixed data\n@return map of resource IDs to resource data" ]
[ "Awaits at most 5 minutes until all pods meets the given predicate.\n\n@param filter used to wait to detect that a pod is up and running.", "Return all server groups for a profile\n\n@param profileId ID of profile\n@return collection of ServerGroups for a profile", "Will prompt a user the \"Add to Homescreen\" feature\n\n@param callback A callback function after the method has been executed.", "Process data for an individual calendar.\n\n@param row calendar data", "Use this API to add vlan resources.", "Read an optional string value form a JSON value.\n@param val the JSON value that should represent the string.\n@return the string from the JSON or null if reading the string fails.", "Determines if a token stream contains only numeric tokens\n@param stream\n@return true if all tokens in the given stream can be parsed as an integer", "Create a Count-Query for QueryBySQL\n\n@param aQuery\n@return The count query", "Use this API to fetch csvserver_cspolicy_binding resources of given name ." ]
public FieldDescriptorDef getField(String name) { FieldDescriptorDef fieldDef = null; for (Iterator it = _fields.iterator(); it.hasNext(); ) { fieldDef = (FieldDescriptorDef)it.next(); if (fieldDef.getName().equals(name)) { return fieldDef; } } return null; }
[ "Returns the field definition with the specified name.\n\n@param name The name of the desired field\n@return The field definition or <code>null</code> if there is no such field" ]
[ "Logs an error message for unhandled exception thrown from the target method.\n\n@param joinPoint - the joint point cut that contains information about the target\n@param throwable - the cause of the exception from the target method invocation", "Resolves line alpha based on distance comparing to max distance.\nWhere alpha is close to 0 for maxDistance, and close to 1 to 0 distance.\n\n@param distance line length\n@param maxDistance max line length\n@return line alpha", "Adds all items from the iterator to the Collection.\n\n@param self the collection\n@param items the items to add\n@return true if the collection changed", "Retrieve a value from the map, ensuring that a key exists in the map\nwith the specified name.\n\n@param name column name\n@return column value", "Add a management request handler factory to this context.\n\n@param factory the request handler to add", "Use this API to update nsacl6 resources.", "Use this API to clear nspbr6.", "Use this API to fetch authenticationradiuspolicy_vpnvserver_binding resources of given name .", "This method is used to launch mock agents. First it creates them, with\nthe generic df_service_name \\\"mock_agent\\\", and then the method sends to\nthe agent a message with the new df_service_name and its behaviour.\n\n@param agent_name\nThe name of the mock agent\n@param agent_path\nThe path of the agent, described in\nmocks/jadex/common/Definitions file\n@param configuration\nWhere the new df_service_name and the agents behaviour is\nsaved\n@param scenario\nThe Scenario of the Test" ]
private static void writeCharSequence(CharSequence seq, CharBuf buffer) { if (seq.length() > 0) { buffer.addJsonEscapedString(seq.toString()); } else { buffer.addChars(EMPTY_STRING_CHARS); } }
[ "Serializes any char sequence and writes it into specified buffer." ]
[ "Replies to this comment with another message.\n@param message the message for the reply.\n@return info about the newly created reply comment.", "Checks if the given operator code is a valid one.\n\n@param operatorCode an operator code to evaluate\n@throws IllegalStateException if operatorCode is not a known operator code.", "Stops the background stream thread.", "Populate a Command instance with the values parsed from a command line\nIf any parser errors are detected it will throw an exception\n@param processedCommand command line\n@param mode do validation or not\n@throws CommandLineParserException any incorrectness in the parser will abort the populate", "Get container for principal.\n\n@param cms cmsobject\n@param list of principals\n@param captionID caption id\n@param descID description id\n@param iconID icon id\n@param ouID ou id\n@param icon icon\n@param iconList iconlist\n@return indexedcontainer", "Generate the next permutation and return a list containing\nthe elements in the appropriate order.\n@see #nextPermutationAsList(java.util.List)\n@see #nextPermutationAsArray()\n@return The next permutation as a list.", "Returns script view\n\n@param model\n@return\n@throws Exception", "Parse a currency symbol position from a string representation.\n\n@param value String representation\n@return CurrencySymbolPosition instance", "Gets a list of registered docker images from the images cache, if it has been\nregistered to the cache for a specific build-info ID and if a docker manifest has been captured for it\nby the build-info proxy.\n@param buildInfoId\n@return" ]
boolean hasNoAlternativeWildcardRegistration() { return parent == null || PathElement.WILDCARD_VALUE.equals(valueString) || !parent.getChildNames().contains(PathElement.WILDCARD_VALUE); }
[ "Gets whether this registration has an alternative wildcard registration" ]
[ "Return the most appropriate log type. This should _never_ return null.", "Set the color at \"index\" to \"color\". Entries are interpolated linearly from\nthe existing entries at \"firstIndex\" and \"lastIndex\" to the new entry.\nfirstIndex < index < lastIndex must hold.\n@param index the position to set\n@param firstIndex the position of the first color from which to interpolate\n@param lastIndex the position of the second color from which to interpolate\n@param color the color to set", "Create a Count-Query for QueryByCriteria", "Encodes the given URI path segment with the given encoding.\n@param segment the segment to be encoded\n@param encoding the character encoding to encode to\n@return the encoded segment\n@throws UnsupportedEncodingException when the given encoding parameter is not supported", "Builds a batch-fetch capable loader based on the given persister, lock-mode, etc.\n\n@param persister The entity persister\n@param batchSize The maximum number of ids to batch-fetch at once\n@param lockMode The lock mode\n@param factory The SessionFactory\n@param influencers Any influencers that should affect the built query\n@param innerEntityLoaderBuilder Builder of the entity loader receiving the subset of batches\n\n@return The loader.", "Calculate where within the beat grid array the information for the specified beat can be found.\nYes, this is a super simple calculation; the main point of the method is to provide a nice exception\nwhen the beat is out of bounds.\n\n@param beatNumber the beat desired\n\n@return the offset of the start of our cache arrays for information about that beat", "Quits server by closing server socket and closing client socket handlers.", "Check if one Renderer is recyclable getting it from the convertView's tag and checking the\nclass used.\n\n@param convertView to get the renderer if is not null.\n@param content used to get the prototype class.\n@return true if the renderer is recyclable.", "This is the main entry point used to convert the internal representation\nof timephased baseline work into an external form which can\nbe displayed to the user.\n\n@param file parent project file\n@param work timephased resource assignment data\n@param rangeUnits timescale units\n@param dateList timescale date ranges\n@return list of durations, one per timescale date range" ]
public synchronized void addListener(CollectionProxyListener listener) { if (_listeners == null) { _listeners = new ArrayList(); } // to avoid multi-add of same listener, do check if(!_listeners.contains(listener)) { _listeners.add(listener); } }
[ "Adds a listener to this collection.\n\n@param listener The listener to add" ]
[ "Use this API to fetch sslpolicylabel resource of given name .", "Calculate start dates for a monthly relative recurrence.\n\n@param calendar current date\n@param frequency frequency\n@param dates array of start dates", "Creates SLD rules for each old style.", "Sets the time warp.\n\n@param l the new time warp", "Utility function that gives list of values from list of value-pair\nstrings.\n\n@param valuePairs List of value-pair strings\n@param delim Delimiter that separates the value pair\n@returns The list of values; empty if no value-pair is present, The even\nelements are the first ones of the value pair, and the odd\nelements are the second ones. For example, if the list of\nvalue-pair is [\"cluster.xml=file1\", \"stores.xml=file2\"], and the\npair delimiter is '=', we will then have the list of values in\nreturn: [\"cluster.xml\", \"file1\", \"stores.xml\", \"file2\"].", "Prepare a parallel HTTP POST Task.\n\n@param url\nthe UrlPostfix: e.g. in http://localhost:8080/index.html.,the url is \"/index.html\"\n@return the parallel task builder", "any possible bean invocations from other ADV observers", "Generate the specified output file by merging the specified\nVelocity template with the supplied context.", "Set default values for annotations.\nInitial annotation take precedence over the default annotation when both annotation types are present\n\n@param defaultAnnotations default value for annotations" ]
private void readCalendars(Project ganttProject) { m_mpxjCalendar = m_projectFile.addCalendar(); m_mpxjCalendar.setName(ProjectCalendar.DEFAULT_BASE_CALENDAR_NAME); Calendars gpCalendar = ganttProject.getCalendars(); setWorkingDays(m_mpxjCalendar, gpCalendar); setExceptions(m_mpxjCalendar, gpCalendar); m_eventManager.fireCalendarReadEvent(m_mpxjCalendar); }
[ "This method extracts calendar data from a GanttProject file.\n\n@param ganttProject Root node of the GanttProject file" ]
[ "crates a StencilSet object and add it to the current diagram\n@param modelJSON\n@param current\n@throws org.json.JSONException", "Get a View that displays the data at the specified\nposition in the data set.\n\n@param position Position of the item whose data we want\n@param convertView View to recycle, if not null\n@param parent ViewGroup containing the returned View", "Returns the name of the bone.\n\n@return the name", "A convenience method for creating an immutable list.\n\n@param self a Set\n@return an immutable Set\n@see java.util.Collections#unmodifiableSet(java.util.Set)\n@since 1.0", "Count the total number of queued resource requests for all queues. The\nresult is \"approximate\" in the face of concurrency since individual\nqueues can change size during the aggregate count.\n\n@return The (approximate) aggregate count of queued resource requests.", "Displays text which shows the valid command line parameters, and then exits.", "Swaps two specified partitions.\n\nPair-wase partition swapping may be more prone to local minima than\nlarger perturbations. Could consider \"swapping\" a list of\n<nodeId/partitionId>. This would allow a few nodes to be identified\n(random # btw 2-5?) and then \"swapped\" (shuffled? rotated?).\n\n@return modified cluster metadata.", "Adds a filter definition to this project file.\n\n@param filter filter definition", "Adds OPT_X | OPT_HEX option to OptionParser, with multiple arguments.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional" ]
public SelectBuilder orderBy(String name, boolean ascending) { if (ascending) { orderBys.add(name + " asc"); } else { orderBys.add(name + " desc"); } return this; }
[ "Adds an ORDER BY item with a direction indicator.\n\n@param name\nName of the column by which to sort.\n@param ascending\nIf true, specifies the direction \"asc\", otherwise, specifies\nthe direction \"desc\"." ]
[ "Get the label distance..\n\n@param settings Parameters for rendering the scalebar.", "Format the date for the status messages.\n\n@param date the date to format.\n\n@return the formatted date.", "Use this API to add dnsview resources.", "Registers Jersey HeaderDelegateProviders for the specified TinyTypes.\n\n@param head a TinyType\n@param tail other TinyTypes\n@throws IllegalArgumentException when a non-TinyType is given", "Get the information for a specified photoset.\n\nThis method does not require authentication.\n\n@param photosetId\nThe photoset ID\n@return The Photoset\n@throws FlickrException", "Set the directory and test that the directory exists and is contained within the Configuration\ndirectory.\n\n@param directory the new directory", "Only sets and gets that are by row and column are used.", "Removes file from your assembly.\n\n@param name field name of the file to remove.", "returns controller if a new device is found" ]
public static <T> T createProxy(final Class<T> proxyInterface) { if( proxyInterface == null ) { throw new NullPointerException("proxyInterface should not be null"); } return proxyInterface.cast(Proxy.newProxyInstance(proxyInterface.getClassLoader(), new Class[] { proxyInterface }, new BeanInterfaceProxy())); }
[ "Creates a proxy object which implements a given bean interface.\n\n@param proxyInterface\nthe interface the the proxy will implement\n@param <T>\nthe proxy implementation type\n@return the proxy implementation\n@throws NullPointerException\nif proxyInterface is null" ]
[ "Parse an extended attribute boolean value.\n\n@param value string representation\n@return boolean value", "Use this API to fetch all the lbsipparameters resources that are configured on netscaler.", "Gets a SerialMessage with the MULTI INSTANCE GET command.\nReturns the number of instances for this command class.\n@param the command class to return the number of instances for.\n@return the serial message.", "prefix the this class fk columns with the indirection table", "Read pattern information from the provided JSON object.\n@param patternJson the JSON object containing the pattern information.", "Create a HashSet with the given initial values.\n\n@param values The values\n@param <T> The type.", "Throws one RendererException if the viewType, layoutInflater or parent are null.", "Adds each required length, ensuring it isn't negative.\n\n@param requiredLengths\none or more required lengths\n@throws IllegalArgumentException\nif a supplied length is negative", "Store the versioned values\n\n@param values list of versioned bytes\n@return the list of versioned values rolled into an array of bytes" ]
public void updateStructure() { if (size() > 1) { Collections.sort(this); m_projectFile.getChildTasks().clear(); Task lastTask = null; int lastLevel = -1; boolean autoWbs = m_projectFile.getProjectConfig().getAutoWBS(); boolean autoOutlineNumber = m_projectFile.getProjectConfig().getAutoOutlineNumber(); for (Task task : this) { task.clearChildTasks(); Task parent = null; if (!task.getNull()) { int level = NumberHelper.getInt(task.getOutlineLevel()); if (lastTask != null) { if (level == lastLevel || task.getNull()) { parent = lastTask.getParentTask(); level = lastLevel; } else { if (level > lastLevel) { parent = lastTask; } else { while (level <= lastLevel) { parent = lastTask.getParentTask(); if (parent == null) { break; } lastLevel = NumberHelper.getInt(parent.getOutlineLevel()); lastTask = parent; } } } } lastTask = task; lastLevel = level; if (autoWbs || task.getWBS() == null) { task.generateWBS(parent); } if (autoOutlineNumber) { task.generateOutlineNumber(parent); } } if (parent == null) { m_projectFile.getChildTasks().add(task); } else { parent.addChildTask(task); } } } }
[ "This method is used to recreate the hierarchical structure of the\nproject file from scratch. The method sorts the list of all tasks,\nthen iterates through it creating the parent-child structure defined\nby the outline level field." ]
[ "Compute Cholesky decomposition of A\n\n@param A symmetric, positive definite matrix (only upper half is used)\n@return upper triangular matrix U such that A = U' * U", "Return a copy of the new fragment and set the variable above.", "Adds a parameter that requires a string argument to the argument list.\nIf the given argument is null, then the argument list remains unchanged.", "Gets a design document using the id and revision from the database.\n\n@param id the document id (optionally prefixed with \"_design/\")\n@param rev the document revision\n@return {@link DesignDocument}", "Retrieve the default number of minutes per month.\n\n@return minutes per month", "Read data from the table. Return a reference to the current\ninstance to allow method chaining.\n\n@return reader instance", "perform the actual matching", "Write all state items to the log file.\n\n@param fileRollEvent the event to log", "Populates a recurring task.\n\n@param record MPX record\n@param task recurring task\n@throws MPXJException" ]
@Deprecated public synchronized FailureDetectorConfig setNodes(Collection<Node> nodes) { Utils.notNull(nodes); this.nodes = new HashSet<Node>(nodes); return this; }
[ "Assigns a list of nodes in the cluster represented by this failure\ndetector configuration.\n\n@param nodes Collection of Node instances, usually determined from the\nCluster; must be non-null" ]
[ "Use this API to fetch all the nslimitselector resources that are configured on netscaler.", "Write objects to data store, but don't release the locks.\nI don't know what we should do if we are in a checkpoint and\nwe need to abort.", "Use this API to fetch all the nstimeout resources that are configured on netscaler.", "Obtain parameters from query\n\n@param query query to scan\n@return Map of parameters", "Populate a sorted list of custom fields to ensure that these fields\nare written to the file in a consistent order.", "Creates an observer\n\n@param method The observer method abstraction\n@param declaringBean The declaring bean\n@param manager The Bean manager\n@return An observer implementation built from the method abstraction", "Use this API to fetch all the systemcore resources that are configured on netscaler.", "A specific, existing section can be deleted by making a DELETE request\non the URL for that section.\n\nNote that sections must be empty to be deleted.\n\nThe last remaining section in a board view cannot be deleted.\n\nReturns an empty data block.\n\n@param section The section to delete.\n@return Request object", "This method is called by the client to load the most recent list of resources.\nThis method should only be called by the service client.\n\n@param result the most recent list of resources." ]
@VisibleForTesting protected static double getNearestNiceValue( final double value, final DistanceUnit scaleUnit, final boolean lockUnits) { DistanceUnit bestUnit = bestUnit(scaleUnit, value, lockUnits); double factor = scaleUnit.convertTo(1.0, bestUnit); // nearest power of 10 lower than value int digits = (int) Math.floor((Math.log(value * factor) / Math.log(10))); double pow10 = Math.pow(10, digits); // ok, find first character double firstChar = value * factor / pow10; // right, put it into the correct bracket int barLen; if (firstChar >= 10.0) { barLen = 10; } else if (firstChar >= 5.0) { barLen = 5; } else if (firstChar >= 2.0) { barLen = 2; } else { barLen = 1; } // scale it up the correct power of 10 return barLen * pow10 / factor; }
[ "Reduce the given value to the nearest smaller 1 significant digit number starting with 1, 2 or 5.\n\n@param value the value to find a nice number for.\n@param scaleUnit the unit of the value.\n@param lockUnits if set, the values are not scaled to a \"nicer\" unit." ]
[ "Shows a dialog with user information for given session.\n\n@param session to show information for", "Convert the continuous values into discrete values by chopping up\nthe distribution into several equally-sized intervals.", "Use this API to update spilloverpolicy.", "Read a text file from assets into a single string\n\n@param context\nA non-null Android Context\n@param asset\nThe asset file to read\n@return The contents or null on error.", "Not exposed directly - the Query object passed as parameter actually contains results...", "Call rollback on the underlying connection.", "Checks to see if a valid deployment parameter has been defined.\n\n@param operation the operation to check.\n\n@return {@code true} of the parameter is valid, otherwise {@code false}.", "Use this API to add linkset.", "This method extracts project extended attribute data from an MSPDI file.\n\n@param project Root node of the MSPDI file" ]
public static void validate(final License license) { // A license should have a name if(license.getName() == null || license.getName().isEmpty()){ throw new WebApplicationException(Response.status(Response.Status.BAD_REQUEST) .entity("License name should not be empty!") .build()); } // A license should have a long name if(license.getLongName() == null || license.getLongName().isEmpty()){ throw new WebApplicationException(Response.status(Response.Status.BAD_REQUEST) .entity("License long name should not be empty!") .build()); } // If there is a regexp, it should compile if(license.getRegexp() != null && !license.getRegexp().isEmpty()){ try{ Pattern.compile(license.getRegexp()); } catch (PatternSyntaxException e){ throw new WebApplicationException(Response.status(Response.Status.BAD_REQUEST) .entity("License regexp does not compile!").build()); } Pattern regex = Pattern.compile("[&%//]"); if(regex.matcher(license.getRegexp()).find()){ throw new WebApplicationException(Response.status(Response.Status.BAD_REQUEST) .entity("License regexp does not compile!").build()); } } }
[ "Checks if the provided license is valid and could be stored into the database\n\n@param license the license to test\n@throws WebApplicationException if the data is corrupted" ]
[ "Searches the type and its sub types for the nearest ojb-persistent type and returns its name.\n\n@param type The type to search\n@return The qualified name of the found type or <code>null</code> if no type has been found", "Parse a boolean.\n\n@param value boolean\n@return Boolean value", "Adds OPT_FORMAT option to OptionParser, with one argument.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional", "Calculate a cache key.\n@param sql to use\n@param columnIndexes to use\n@return cache key to use.", "Use this API to update rnatparam.", "Get the layer ID out of the request URL.\n\n@param request servlet request\n@return layer id", "Digest format to layer file name.\n\n@param digest\n@return", "Converts a number of bytes to a human-readable string\n@param bytes the bytes\n@return the human-readable string", "Creates a resource key with given id for bundle specified by given class.\n@param clazz the class owning the bundle.\n@param id value identifier\n@return the resource key" ]
public void setIndexBuffer(GVRIndexBuffer ibuf) { mIndices = ibuf; NativeMesh.setIndexBuffer(getNative(), (ibuf != null) ? ibuf.getNative() : 0L); }
[ "Changes the index buffer associated with this mesh.\n@param ibuf new index buffer to use\n@see #setIndices(int[])\n@see #getIndexBuffer()\n@see #getIntIndices()" ]
[ "Begin a \"track;\" that is, begin logging at one level deeper.\nChannels other than the FORCE channel are ignored.\n@param args The title of the track to begin, with an optional FORCE flag.", "Use this API to fetch systemuser resource of given name .", "Removes the supplied marker from the map.\n\n@param marker", "sets the row reader class name for thie class descriptor", "Handle http Request.\n\n@param request HttpRequest to be handled.\n@param responder HttpResponder to write the response.\n@param groupValues Values needed for the invocation.", "Extracts calendar data from a ConceptDraw PROJECT file.\n\n@param cdp ConceptDraw PROJECT file", "Compares the two comma-separated lists.\n\n@param list1 The first list\n@param list2 The second list\n@return <code>true</code> if the lists are equal", "Use this API to update nstimeout.", "we have only one implementation on classpath." ]
@Override public Set<String> paramKeys() { Set<String> set = new HashSet<String>(); set.addAll(C.<String>list(request.paramNames())); set.addAll(extraParams.keySet()); set.addAll(bodyParams().keySet()); set.remove("_method"); set.remove("_body"); return set; }
[ "Get all parameter keys.\n@return a set of parameter keys" ]
[ "Simple, high-level API to enable or disable eye picking for this scene\nobject.\n\nThe {@linkplain #attachCollider low-level\nAPI} gives you a lot of control over eye picking, but it does involve an\nawful lot of details. This method\n(and {@link #getPickingEnabled()}) provides a simple boolean property.\nIt attaches a GVRSphereCollider to the scene object. If you want more\naccurate picking, you can use {@link #attachComponent(GVRComponent)} to attach a\nmesh collider instead. The mesh collider is more accurate but also\ncosts more to compute.\n\n@param enabled\nShould eye picking 'see' this scene object?\n\n@since 2.0.2\n@see GVRSphereCollider\n@see GVRMeshCollider", "Computes the likelihood of the random draw\n\n@return The likelihood.", "Obtains a local date in Julian calendar system from the\nera, year-of-era and day-of-year fields.\n\n@param era the Julian era, not null\n@param yearOfEra the year-of-era\n@param dayOfYear the day-of-year\n@return the Julian local date, not null\n@throws DateTimeException if unable to create the date\n@throws ClassCastException if the {@code era} is not a {@code JulianEra}", "create a broker with given broker info\n\n@param id broker id\n@param brokerInfoString broker info format: <b>creatorId:host:port:autocreated</b>\n@return broker instance with connection config\n@see #getZKString()", "Returns a RowColumn following the current one\n\n@return RowColumn following this one", "Handle an end time change.\n@param event the change event.", "Write the table configuration to a buffered writer.", "Function to serialize the given Vector clock into a string. If something\ngoes wrong, it returns an empty string.\n\n@param vc The Vector clock to serialize\n@return The string (JSON) version of the specified Vector clock", "Wrap connection with a proxy.\n@param target connection handle\n@param connectionHandle originating bonecp connection\n@return Proxy to a connection." ]
public static AiScene importFile(String filename) throws IOException { return importFile(filename, EnumSet.noneOf(AiPostProcessSteps.class)); }
[ "Imports a file via assimp without post processing.\n\n@param filename the file to import\n@return the loaded scene\n@throws IOException if an error occurs" ]
[ "Handle a \"current till end\" change event.\n@param event the change event.", "Load the given configuration file.", "Returns s if it's at most maxWidth chars, otherwise chops right side to fit.", "Append data to JSON response.\n@param param\n@param value", "Use this API to fetch vpath resource of given name .", "Obtain override ID\n\n@param overrideIdentifier can be the override ID or class name\n@return\n@throws Exception", "Use this API to fetch the statistics of all tunnelip_stats resources that are configured on netscaler.", "Send ourselves \"updates\" about any tracks that were loaded before we started, or before we were requesting\ndetails, since we missed them.", "Convert given value to given target\n\n@param fromValue\nthe value to convert\n@param toType\ntarget target\n@param <T>\ntarget of the result\n@return the value converted to given target\n@throws TypeCastException\nif conversion was not possible" ]
public static double computeRowMax( ZMatrixRMaj A , int row , int col0 , int col1 ) { double max = 0; int indexA = A.getIndex(row,col0); double h[] = A.data; for (int i = col0; i < col1; i++) { double realVal = h[indexA++]; double imagVal = h[indexA++]; double magVal = realVal*realVal + imagVal*imagVal; if( max < magVal ) { max = magVal; } } return Math.sqrt(max); }
[ "Finds the magnitude of the largest element in the row\n@param A Complex matrix\n@param row Row in A\n@param col0 First column in A to be copied\n@param col1 Last column in A + 1 to be copied\n@return magnitude of largest element" ]
[ "Add a new check box.\n@param date the date for the check box\n@param checkState the initial check state.", "Use this API to fetch bridgegroup_vlan_binding resources of given name .", "Generate the next permutation and return a list containing\nthe elements in the appropriate order.\n@see #nextPermutationAsList(java.util.List)\n@see #nextPermutationAsArray()\n@return The next permutation as a list.", "return a new managed connection. This connection is wrapped around the real connection and delegates to it\nto get work done.\n@param subject\n@param info\n@return", "Checks if maintenance mode is enabled for the given app\n\n@param appName See {@link #listApps} for a list of apps that can be used.\n@return true if maintenance mode is enabled", "as it is daemon thread\n\nTODO when release external resources should shutdown the scheduler.", "Calculate a shift value that can be used to create a power-of-two value between\nthe specified maximum and minimum values.\n@param minimumValue the minimum value\n@param maximumValue the maximum value\n@return the calculated shift (use {@code 1 << shift} to obtain a value)", "Get the authentication info for this layer.\n\n@return authentication info.", "Read an optional boolean value form a JSON Object.\n@param json the JSON object to read from.\n@param key the key for the boolean value in the provided JSON object.\n@return the boolean or null if reading the boolean fails." ]
public static String encodeQueryParam(String queryParam, String encoding) throws UnsupportedEncodingException { return HierarchicalUriComponents.encodeUriComponent(queryParam, encoding, HierarchicalUriComponents.Type.QUERY_PARAM); }
[ "Encodes the given URI query parameter with the given encoding.\n@param queryParam the query parameter to be encoded\n@param encoding the character encoding to encode to\n@return the encoded query parameter\n@throws UnsupportedEncodingException when the given encoding parameter is not supported" ]
[ "Gets the value of the ppvItem property.\n\n<p>\nThis accessor method returns a reference to the live list,\nnot a snapshot. Therefore any modification you make to the\nreturned list will be present inside the JAXB object.\nThis is why there is not a <CODE>set</CODE> method for the ppvItem property.\n\n<p>\nFor example, to add a new item, do as follows:\n<pre>\ngetPPVItem().add(newItem);\n</pre>\n\n\n<p>\nObjects of the following type(s) are allowed in the list\n{@link PPVItemsType.PPVItem }", "Make sure the result index points to the next available key in the scan result, if exists.", "Calculate standart deviation.\n@param values Values.\n@param mean Mean.\n@return Standart deviation.", "digest message with MD5\n\n@param source message\n@return 32 bit MD5 value (lower case)", "Method to declare Video-VideoRenderer mapping.\nFavorite videos will be rendered using FavoriteVideoRenderer.\nLive videos will be rendered using LiveVideoRenderer.\nLiked videos will be rendered using LikeVideoRenderer.\n\n@param content used to map object-renderers.\n@return VideoRenderer subtype class.", "Update the name of a script\n\n@param id ID of script\n@param name new name\n@return updated script\n@throws Exception exception", "Returns the compact task records for all tasks within the given project,\nordered by their priority within the project. Tasks can exist in more than one project at a time.\n\n@param project The project in which to search for tasks.\n@return Request object", "Finds the missing value. Seems to lose a degree of freedom, but it\ndoesn't. That degree of freedom is already lost by the sensor.", "Provides a collection of all the nodes in the tree\nusing a depth first traversal.\n\n@return the list of (depth-first) ordered nodes" ]
void lockSharedInterruptibly(final Integer permit) throws InterruptedException { if (permit == null) { throw new IllegalArgumentException(); } sync.acquireSharedInterruptibly(permit); }
[ "Acquire the shared lock allowing the acquisition to be interrupted.\n@param permit - the permit Integer for this operation. May not be {@code null}.\n@throws InterruptedException - if the acquiring thread is interrupted.\n@throws IllegalArgumentException if {@code permit} is null." ]
[ "Returns this bar code's pattern, converted into a set of corresponding codewords.\nUseful for bar codes that encode their content as a pattern.\n\n@param size the number of digits in each codeword\n@return this bar code's pattern, converted into a set of corresponding codewords", "Request the list of all tracks in the specified slot, given a dbserver connection to a player that has already\nbeen set up.\n\n@param slot identifies the media slot we are querying\n@param client the dbserver client that is communicating with the appropriate player\n\n@return the retrieved track list entry items\n\n@throws IOException if there is a communication problem\n@throws InterruptedException if the thread is interrupted while trying to lock the client for menu operations\n@throws TimeoutException if we are unable to lock the client for menu operations", "Gets an exception reporting an unexpected XML element.\n\n@param reader a reference to the stream reader.\n@return the constructed {@link javax.xml.stream.XMLStreamException}.", "Write the configuration to a buffered writer.", "returns array with length 3 and optional entries version, encoding, standalone", "Sets the segment reject as a string. This method is for convenience\nto be able to set percent reject type just by calling with '3%' and\notherwise it uses rows. All this assuming that parsing finds '%' characher\nand is able to parse a raw reject number.\n\n@param reject the new segment reject", "Returns the name from the inverse side if the given property de-notes a one-to-one association.", "Load the given class using a specific class loader.\n\n@param className The name of the class\n@param cl The Class Loader to be used for finding the class.\n@return The class object", "Decodes a signed request, returning the payload of the signed request as a Map\n@param signedRequest the value of the signed_request parameter sent by Facebook.\n@return the payload of the signed request as a Map\n@throws SignedRequestException if there is an error decoding the signed request" ]
public ImmutableList<AbstractElement> getFirstSetGrammarElements() { if (firstSetGrammarElements == null) { firstSetGrammarElements = ImmutableList.copyOf(mutableFirstSetGrammarElements); } return firstSetGrammarElements; }
[ "The grammar elements that may occur at the given offset." ]
[ "Use this API to add route6.", "Flushes this output stream and forces any buffered output bytes to be written out to the stream. If propagate is\ntrue, the wrapped stream will also be flushed.\n\n@param propagate\nboolean flag to indicate whether the wrapped OutputStream should also be flushed.\n@throws IOException\nif an I/O error occurs.", "Gets the index of a ExpandableWrapper within the helper item list based on\nthe index of the ExpandableWrapper.\n\n@param parentPosition The index of the parent in the list of parents\n@return The index of the parent in the merged list of children and parents", "Exact conversion of displaced lognormal ATM volatiltiy to normal ATM volatility.\n\n@param forward The forward\n@param displacement The displacement (considering a displaced lognormal model, otherwise 0.\n@param maturity The maturity\n@param lognormalVolatiltiy The (implied) lognormal volatility.\n@return The (implied) normal volatility.\n@see <a href=\"http://papers.ssrn.com/sol3/papers.cfm?abstract_id=2687742\">Dimitroff, Fries, Lichtner and Rodi: Lognormal vs Normal Volatilities and Sensitivities in Practice</a>", "Returns true if required properties for MiniFluo are set", "Creates a new Box Developer Edition connection with enterprise token leveraging an access token cache.\n@param enterpriseId the enterprise ID to use for requesting access token.\n@param clientId the client ID to use when exchanging the JWT assertion for an access token.\n@param clientSecret the client secret to use when exchanging the JWT assertion for an access token.\n@param encryptionPref the encryption preferences for signing the JWT.\n@param accessTokenCache the cache for storing access token information (to minimize fetching new tokens)\n@return a new instance of BoxAPIConnection.", "Read an element which contains only a single boolean attribute.\n@param reader the reader\n@param attributeName the attribute name, usually \"value\"\n@return the boolean value\n@throws javax.xml.stream.XMLStreamException if an error occurs or if the\nelement does not contain the specified attribute, contains other\nattributes, or contains child elements.", "Update an object in the database to change its id to the newId parameter.", "Complete the current operation and persist the current state to the disk. This will also trigger the invalidation\nof outdated modules.\n\n@param modification the current modification\n@param callback the completion callback" ]
public static String getCorrelationId(Message message) { String correlationId = (String) message.get(CORRELATION_ID_KEY); if(null == correlationId) { correlationId = readCorrelationId(message); } if(null == correlationId) { correlationId = readCorrelationIdSoap(message); } return correlationId; }
[ "Get CorrelationId from message.\n\n@param message the message\n@return correlationId or null if not set" ]
[ "Use this API to fetch all the cacheobject resources that are configured on netscaler.", "Dumps the partition IDs per node in terms of zone n-ary type.\n\n@param cluster\n@param storeRoutingPlan\n@return pretty printed string of detailed zone n-ary type.", "This method retrieves the data at the given offset and returns\nit as a String, assuming the underlying data is composed of\nsingle byte characters.\n\n@param offset offset of required data\n@return string containing required data", "Use this API to fetch all the nsrollbackcmd resources that are configured on netscaler.", "append normal text\n\n@param text normal text\n@return SimplifySpanBuild", "Indicates whether or not an event ID is a duplicate.\n\n<p>This method can be overridden by a subclass in order to provide custom de-duping logic.</p>\n\n@param eventID the event ID.\n@return true if the event is a duplicate; otherwise false.", "Synchronize the required files to a slave HC from the master DC if this is required.\n@param fileRepository the HostFileRepository of the HC.\n@param contentRepository the ContentRepository of the HC.\n@param backup inidcates if this is a DC backup HC.\n@param oldHash the hash of the deployment to be replaced.\n@return true if the content should be pulled by the slave HC - false otherwise.", "A modified version of abs that always returns a non-negative value.\nMath.abs returns Integer.MIN_VALUE if a == Integer.MIN_VALUE and this\nmethod returns Integer.MAX_VALUE in that case.", "Analyzes the source code of an interface. The specified interface must not contain methods, that changes the\nstate of the corresponding object itself.\n\n@param code\nsource code of an interface which describes how to generate the <i>immutable</i>\n@return analysis result" ]
public static Cluster greedyShufflePartitions(final Cluster nextCandidateCluster, final int greedyAttempts, final int greedySwapMaxPartitionsPerNode, final int greedySwapMaxPartitionsPerZone, List<Integer> greedySwapZoneIds, List<StoreDefinition> storeDefs) { List<Integer> zoneIds = null; if(greedySwapZoneIds.isEmpty()) { zoneIds = new ArrayList<Integer>(nextCandidateCluster.getZoneIds()); } else { zoneIds = new ArrayList<Integer>(greedySwapZoneIds); } List<Integer> nodeIds = new ArrayList<Integer>(); Cluster returnCluster = Cluster.cloneCluster(nextCandidateCluster); double currentUtility = new PartitionBalance(returnCluster, storeDefs).getUtility(); for(int i = 0; i < greedyAttempts; i++) { // Iterate over zone ids to decide which node ids to include for // intra-zone swapping. // In future, if there is a need to support inter-zone swapping, // then just remove the // zone specific logic that populates nodeIdSet and add all nodes // from across all zones. int zoneIdOffset = i % zoneIds.size(); Set<Integer> nodeIdSet = nextCandidateCluster.getNodeIdsInZone(zoneIds.get(zoneIdOffset)); nodeIds = new ArrayList<Integer>(nodeIdSet); Collections.shuffle(zoneIds, new Random(System.currentTimeMillis())); Cluster shuffleResults = swapGreedyRandomPartitions(returnCluster, nodeIds, greedySwapMaxPartitionsPerNode, greedySwapMaxPartitionsPerZone, storeDefs); double nextUtility = new PartitionBalance(shuffleResults, storeDefs).getUtility(); System.out.println("Swap improved max-min ratio: " + currentUtility + " -> " + nextUtility + " (swap attempt " + i + " in zone " + zoneIds.get(zoneIdOffset) + ")"); returnCluster = shuffleResults; currentUtility = nextUtility; } return returnCluster; }
[ "Within a single zone, tries swapping some minimum number of random\npartitions per node with some minimum number of random partitions from\nother nodes within the zone. Chooses the best swap in each iteration.\nLarge values of the greedSwapMaxPartitions... arguments make this method\nequivalent to comparing every possible swap. This is very expensive.\n\nNormal case should be :\n\n#zones X #nodes/zone X max partitions/node X max partitions/zone\n\n@param nextCandidateCluster cluster object.\n@param greedyAttempts See RebalanceCLI.\n@param greedySwapMaxPartitionsPerNode See RebalanceCLI.\n@param greedySwapMaxPartitionsPerZone See RebalanceCLI.\n@param greedySwapZoneIds The set of zoneIds to consider. Each zone is done\nindependently.\n@param storeDefs\n@return updated cluster" ]
[ "Maps a field index to a ResourceField instance.\n\n@param fields array of fields used as the basis for the mapping.\n@param index required field index\n@return ResourceField instance", "Default settings set type loader to ClasspathTypeLoader if not set before.", "Get random geographical location\n@return 2-Tuple of ints (latitude, longitude)", "Expensive. Creates the plan for the specific settings.", "Read a field into our table configuration for field=value line.", "Wait until a range has no notifications.\n\n@return true if notifications were ever seen while waiting", "Returns the maximum magnitude of the complex numbers\n@param u Array of complex numbers\n@param startU first index to consider in u\n@param length Number of complex numebrs to consider\n@return magnitude", "Write the document object to a file.\n\n@param document the document object.\n@param filePathname the path name of the file to be written to.\n@param method the output method: for instance html, xml, text\n@param indent amount of indentation. -1 to use the default.\n@throws TransformerException if an exception occurs.\n@throws IOException if an IO exception occurs.", "Make all elements of a String array lower case.\n@param strings string array, may contain null item but can't be null\n@return array containing all provided elements lower case" ]
public List<MapRow> read() throws IOException { List<MapRow> result = new ArrayList<MapRow>(); int fileCount = m_stream.readInt(); if (fileCount != 0) { for (int index = 0; index < fileCount; index++) { // We use a LinkedHashMap to preserve insertion order in iteration // Useful when debugging the file format. Map<String, Object> map = new LinkedHashMap<String, Object>(); readBlock(map); result.add(new MapRow(map)); } } return result; }
[ "Read a list of fixed sized blocks from the input stream.\n\n@return List of MapRow instances representing the fixed size blocks" ]
[ "Sets a custom configuration attribute.\n@param attributeName the attribute name. Names starting with\n{@link #JDBC_PROPERTY_NAME_PREFIX} will be used (without the prefix) by the\nConnectionFactory when creating connections from DriverManager\n(not used for external DataSource connections). Names starting with\n{@link #DBCP_PROPERTY_NAME_PREFIX} to Commons DBCP (if used, also without prefix).\n@param attributeValue the attribute value", "Groups the current element according to the value\n\n@param answer the map containing the results\n@param element the element to be placed\n@param value the value according to which the element will be placed\n@since 1.5.0", "Get the bone index for the bone with the given name.\n\n@param bonename string identifying the bone whose index you want\n@return 0 based bone index or -1 if bone with that name is not found.", "Extract note text.\n\n@param row task data\n@return note text", "2-D Integer array to double array.\n\n@param array Integer array.\n@return Double array.", "Converts a sequence of unicode code points to a sequence of Java characters.\n\n@return the number of chars written to the destination buffer", "Makes a DocumentReaderAndWriter based on\nflags.plainTextReaderAndWriter. Useful for reading in\nuntokenized text documents or reading plain text from the command\nline. An example of a way to use this would be to return a\nedu.stanford.nlp.wordseg.Sighan2005DocumentReaderAndWriter for\nthe Chinese Segmenter.", "Read a list of fixed size blocks using an instance of the supplied reader class.\n\n@param readerClass reader class\n@return list of blocks", "Get log file\n\n@return log file" ]
private void saveLocalization() { SortedProperties localization = new SortedProperties(); for (Object itemId : m_container.getItemIds()) { Item item = m_container.getItem(itemId); String key = item.getItemProperty(TableProperty.KEY).getValue().toString(); String value = item.getItemProperty(TableProperty.TRANSLATION).getValue().toString(); if (!(key.isEmpty() || value.isEmpty())) { localization.put(key, value); } } m_keyset.updateKeySet(m_localizations.get(m_locale).keySet(), localization.keySet()); m_localizations.put(m_locale, localization); }
[ "Saves the current translations from the container to the respective localization." ]
[ "Get unique values form the array.\n\n@param values Array of values.\n@return Unique values.", "Gets an iterator to the EJB descriptors for an EJB implementation class\n\n@param beanClass The EJB class\n@return An iterator", "Returns the configured mappings of the current field.\n\n@return the configured mappings of the current field", "Retrieves the named calendar. This method will return\nnull if the named calendar is not located.\n\n@param calendarName name of the required calendar\n@return ProjectCalendar instance", "Encodes the given source into an encoded String using the rules specified\nby the given component and with the given options.\n@param source the source string\n@param encoding the encoding of the source string\n@param type the URI component for the source\n@return the encoded URI\n@throws IllegalArgumentException when the given uri parameter is not a valid URI", "Check the variable name and if not set, set it with the singleton variable name being on the top of the stack.", "Record the checkout wait time in us\n\n@param dest Destination of the socket to checkout. Will actually record\nif null. Otherwise will call this on self and corresponding child\nwith this param null.\n@param checkoutTimeUs The number of us to wait before getting a socket", "Helper method used to peel off spurious wrappings of DateTimeException\n\n@param e DateTimeException to peel\n\n@return DateTimeException that does not have another DateTimeException as its cause.", "Returns a map from a category path to the wrapper of all the sub-categories of the category with the path given as key.\n\n@return a map from a category path to all sub-categories of the path's category." ]
@Override public CompletableFuture<Map<String, Change<?>>> diff(Revision from, Revision to, String pathPattern) { final ServiceRequestContext ctx = context(); return CompletableFuture.supplyAsync(() -> { requireNonNull(from, "from"); requireNonNull(to, "to"); requireNonNull(pathPattern, "pathPattern"); failFastIfTimedOut(this, logger, ctx, "diff", from, to, pathPattern); final RevisionRange range = normalizeNow(from, to).toAscending(); readLock(); try (RevWalk rw = new RevWalk(jGitRepository)) { final RevTree treeA = rw.parseTree(commitIdDatabase.get(range.from())); final RevTree treeB = rw.parseTree(commitIdDatabase.get(range.to())); // Compare the two Git trees. // Note that we do not cache here because CachingRepository caches the final result already. return toChangeMap(blockingCompareTreesUncached(treeA, treeB, pathPatternFilterOrTreeFilter(pathPattern))); } catch (StorageException e) { throw e; } catch (Exception e) { throw new StorageException("failed to parse two trees: range=" + range, e); } finally { readUnlock(); } }, repositoryWorker); }
[ "Get the diff between any two valid revisions.\n\n@param from revision from\n@param to revision to\n@param pathPattern target path pattern\n@return the map of changes mapped by path\n@throws StorageException if {@code from} or {@code to} does not exist." ]
[ "Writes image files for all data that was collected and the statistics\nfile for all sites.", "Gets a list of any comments on this file.\n\n@return a list of comments on this file.", "Set the classpath for loading the driver.\n\n@param classpath the classpath", "Writes the body of this request to an HttpURLConnection.\n\n<p>Subclasses overriding this method must remember to close the connection's OutputStream after writing.</p>\n\n@param connection the connection to which the body should be written.\n@param listener an optional listener for monitoring the write progress.\n@throws BoxAPIException if an error occurs while writing to the connection.", "Parse the given file to obtains a Properties object.\n\n@param file\n@return a properties object containing all the properties present in the file.\n@throws InvalidDeclarationFileException", "This method lists all resource assignments defined in the file.\n\n@param file MPX file", "Tests whether a Row name occurs more than once in the list of rows\n@param name\n@return", "Read pattern information from the provided JSON object.\n@param patternJson the JSON object containing the pattern information.", "Given the initial and final cluster dumps it into the output directory\n\n@param currentCluster Initial cluster metadata\n@param finalCluster Final cluster metadata\n@param outputDirName Output directory where to dump this file\n@param filePrefix String to prepend to the initial & final cluster\nmetadata files\n@throws IOException" ]
private Class<?> beanType(String name) { Class<?> type = context.getType(name); if (ClassUtils.isCglibProxyClass(type)) { return AopProxyUtils.ultimateTargetClass(context.getBean(name)); } return type; }
[ "Return the bean type, untangling the proxy if needed\n\n@param name\nthe bean name\n@return The Class of the bean" ]
[ "Use this API to unset the properties of sslparameter resource.\nProperties that need to be unset are specified in args array.", "Get the class name without the package\n\n@param c The class name with package\n@return the class name without the package", "Returns the approximate size of slop to help in throttling\n\n@param slopVersioned The versioned slop whose size we want\n@return Size in bytes", "Notification that a state transition failed.\n\n@param state the failed transition", "Return a long value from a prepared query.", "Lists the formation info for an app\n\n@param appName See {@link #listApps} for a list of apps that can be used.", "Get the maximum width and height of the labels.\n\n@param settings Parameters for rendering the scalebar.", "Returns all the persistent id generators which potentially require the creation of an object in the schema.", "Puts value at given column\n\n@param value Will be encoded using UTF-8" ]
public static void doBatchEnqueue(final Jedis jedis, final String namespace, final String queue, final List<String> jobJsons) { Pipeline pipelined = jedis.pipelined(); pipelined.sadd(JesqueUtils.createKey(namespace, QUEUES), queue); for (String jobJson : jobJsons) { pipelined.rpush(JesqueUtils.createKey(namespace, QUEUE, queue), jobJson); } pipelined.sync(); }
[ "Helper method that encapsulates the minimum logic for adding jobs to a queue.\n\n@param jedis\nthe connection to Redis\n@param namespace\nthe Resque namespace\n@param queue\nthe Resque queue name\n@param jobJsons\na list of jobs serialized as JSON" ]
[ "Use this API to enable the mode on Netscaler.\n@param mode mode to be enabled.\n@return status of the operation performed.\n@throws Exception Nitro exception.", "Validations specific to PUT", "Retrieve the FeatureSource object from the data store.\n\n@return An OpenGIS FeatureSource object;\n@throws LayerException\noops", "Use this API to fetch sslcipher_individualcipher_binding resources of given name .", "Set the background color.\n\nIf you don't set the background color, the default is an opaque black:\n{@link Color#BLACK}, 0xff000000.\n\n@param color\nAn Android 32-bit (ARGB) {@link Color}, such as you get from\n{@link Resources#getColor(int)}", "Use this API to fetch dbdbprofile resource of given name .", "Return all scripts of a given type\n\n@param type integer value of type\n@return Array of scripts of the given type", "Parse work units.\n\n@param value work units value\n@return TimeUnit instance", "Deletes an individual alias\n\n@param alias\nthe alias to delete" ]
public static <T> List<T> toList(Iterator<? extends T> iterator) { return Lists.newArrayList(iterator); }
[ "Returns a list that contains all the entries of the given iterator in the same order.\n\n@param iterator\nthe iterator. May not be <code>null</code>.\n@return a list with the same entries as the given iterator. Never <code>null</code>." ]
[ "Create a clone of the Renderer. This method is the base of the prototype mechanism implemented\nto avoid create new objects from RendererBuilder. Pay an special attention implementing clone\nmethod in Renderer subtypes.\n\n@return a copy of the current renderer.", "Generate a PageMetadata object for the page represented by the specified pagination token.\n\n@param paginationToken opaque pagination token\n@param initialParameters the initial view query parameters (i.e. for the page 1 request).\n@param <K> the view key type\n@param <V> the view value type\n@return PageMetadata object for the given page", "Retrieve the ordinal text for a given integer.\n\n@param value integer value\n@return ordinal text", "Returns the earlier of two dates, handling null values. A non-null Date\nis always considered to be earlier than a null Date.\n\n@param d1 Date instance\n@param d2 Date instance\n@return Date earliest date", "Add resources to the tree.\n\n@param parentNode parent tree node\n@param file resource container", "callers of doLogin should be serialized before calling in.", "Cleans a multi-value property key.\n\n@param name Name of the property key\n@return The {@link ValidationResult} object containing the key,\nand the error code(if any)\n<p/>\nFirst calls cleanObjectKey\nKnown property keys are reserved for multi-value properties, subsequent validation is done for those", "Recursively read the WBS structure from a PEP file.\n\n@param parent parent container for tasks\n@param id initial WBS ID", "Use this API to fetch statistics of nsacl6_stats resource of given name ." ]
public static void deleteMetadataTemplate(BoxAPIConnection api, String scope, String template) { URL url = METADATA_TEMPLATE_URL_TEMPLATE.build(api.getBaseURL(), scope, template); BoxJSONRequest request = new BoxJSONRequest(api, url, "DELETE"); request.send(); }
[ "Deletes the schema of an existing metadata template.\n\n@param api the API connection to be used\n@param scope the scope of the object\n@param template Unique identifier of the template" ]
[ "Check if the the nodeId is present in the cluster managed by the metadata store\nor throw an exception.\n\n@param nodeId The nodeId to check existence of", "Converts the List to PagedList.\n@param list list to be converted in to paged list\n@param <InnerT> the wrapper inner type\n@return the Paged list for the inner type.", "This method takes the textual version of a constraint name\nand returns an appropriate class instance. Note that unrecognised\nvalues are treated as \"As Soon As Possible\" constraints.\n\n@param locale target locale\n@param type text version of the constraint type\n@return ConstraintType instance", "Sets the site root.\n\n@param siteRoot the site root", "Get the filters ExporterServiceFilter and ExportDeclarationFilter from the properties, stop the instance if one of.\nthem is invalid.", "Initializes the set of report implementation.", "Retrieves the amount of time represented by a calendar exception\nbefore or after an intersection point.\n\n@param exception calendar exception\n@param date intersection time\n@param after true to report time after intersection, false to report time before\n@return length of time in milliseconds", "Adds a column to this table definition.\n\n@param columnDef The new column", "Infer app name from scan package\n\n@param packageName\nthe package name\n@return\napp name inferred from the package name" ]
private static TransportType map2TransportType(String transportId) { TransportType type; if (CXF_HTTP_TRANSPORT_ID.equals(transportId) || SOAP_HTTP_TRANSPORT_ID.equals(transportId)) { type = TransportType.HTTP; } else { type = TransportType.OTHER; } return type; }
[ "Maps a transportId to its corresponding TransportType.\n@param transportId\n@return" ]
[ "Returns the text value of all of the elements in the collection.\n\n@return the text value of all the elements in the collection or null", "Reads the availability table from the file.\n\n@param resource MPXJ resource instance\n@param periods MSPDI availability periods", "Adds the class descriptor to this model.\n\n@param classDef The class descriptor\n@return The class descriptor or <code>null</code> if there is no such class in this model", "Get the best guess we have for the current track position on the specified player.\n\n@param player the player number whose position is desired\n\n@return the milliseconds into the track that we believe playback has reached, or -1 if we don't know\n\n@throws IllegalStateException if the TimeFinder is not running", "Restore the recorded state from the rollback xml.\n\n@param target the patchable target\n@param rollbackPatchId the rollback patch id\n@param patchType the the current patch type\n@param history the recorded history\n@throws PatchingException", "adds the qualified names to the require-bundle attribute, if not already\npresent.\n\n@param bundles - passing parameterized bundled (e.g. versions, etc.) is\nnot supported", "Performs a null edit on a property. This has some effects on Wikibase,\nsuch as refreshing the labels of the referred items in the UI.\n\n@param propertyId\nthe document to perform a null edit on\n@throws MediaWikiApiErrorException\nif the API returns errors\n@throws IOException\nif there are any IO errors, such as missing network connection", "Transposes an individual block inside a block matrix.", "Append the html-code to finish a html mail message to the given buffer.\n\n@param buffer The StringBuffer to add the html code to." ]
public void addRoute(String path, Class<? extends Actor> actorClass) throws RouteAlreadyMappedException { addRoute(new Route(path, false), actorClass); }
[ "Add an exact path to the routing table.\n\n@throws RouteAlreadyMappedException" ]
[ "Reloads the synchronization config. This wipes all in-memory synchronization settings.", "Use this API to fetch all the callhome resources that are configured on netscaler.", "adds the qualified names to the export-package attribute, if not already\npresent.\n\n@param packages - passing parameterized packages is not supported", "Ensure that all logs are replayed, any other logs can not be added before end of this function.", "Set a Java classname path to ignore when printing stack traces\n@param classToIgnoreInTraces The class name (with packages, etc) to ignore.\n@return this", "Only converts the B matrix and passes that onto solve. Te result is then copied into\nthe input 'X' matrix.\n\n@param B A matrix &real; <sup>m &times; p</sup>. Not modified.\n@param X A matrix &real; <sup>n &times; p</sup>, where the solution is written to. Modified.", "Replaces sequences of whitespaces with tabs.\n\n@param self A CharSequence to unexpand\n@param tabStop The number of spaces a tab represents\n@return an unexpanded String\n@since 1.8.2", "absolute for advancedJDBCSupport\n@param row", "Compress contiguous partitions into format \"e-i\" instead of\n\"e, f, g, h, i\". This helps illustrate contiguous partitions within a\nzone.\n\n@param cluster\n@param zoneId\n@return pretty string of partitions per zone" ]
public static int restrictRange(int value, int min, int max) { return Math.min((Math.max(value, min)), max); }
[ "If the specified value is not greater than or equal to the specified minimum and\nless than or equal to the specified maximum, adjust it so that it is.\n@param value The value to check.\n@param min The minimum permitted value.\n@param max The maximum permitted value.\n@return {@code value} if it is between the specified limits, {@code min} if the value\nis too low, or {@code max} if the value is too high.\n@since 1.2" ]
[ "Read an exception day for a calendar.\n\n@param mpxjCalendar ProjectCalendar instance\n@param day ConceptDraw PROJECT exception day", "Determines whether the specified permission is permitted.\n\n@param permission\n@return <tt>false<tt> if the specified permission is not permitted, based on the current security policy; <tt>true<tt> otherwise", "Given the current and final cluster dumps it into the output directory\n\n@param currentCluster Initial cluster metadata\n@param finalCluster Final cluster metadata\n@param outputDirName Output directory where to dump this file\n@throws IOException", "Sort and order steps to avoid unwanted generation", "Adds OPT_Z | OPT_ZONE option to OptionParser, with one argument.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional", "Undo a prior removal using the supplied undo key.\n\n@param removalKey - The key returned from the call to removeRoleMapping.\n@return true if the undo was successful, false otherwise.", "Given a layer ID, search for the WMS layer.\n\n@param layerId layer id\n@return WMS layer or null if layer is not a WMS layer", "Computes the p=1 norm. If A is a matrix then the induced norm is computed.\n\n@param A Matrix or vector.\n@return The norm.", "Sets an Integer attribute.\n\n@param key the key, non null.\n@param value the value\n@return the Builder, for chaining." ]
public JSONObject toJSON() { try { return new JSONObject(properties).putOpt("name", getName()); } catch (JSONException e) { e.printStackTrace(); Log.e(TAG, e, "toJSON()"); throw new RuntimeAssertion("NodeEntry.toJSON() failed for '%s'", this); } }
[ "Converts the node to JSON\n@return JSON object" ]
[ "Tests whether a Row name occurs more than once in the list of rows\n@param name\n@return", "Returns all entries in no particular order.", "Use this API to delete dnssuffix of given name.", "Utility function that fetches node ids.\n\n@param adminClient An instance of AdminClient points to given cluster\n@return Node ids in cluster", "Remove the listener active in this session.\n\n@param listenerId the id of the listener to remove", "This method extracts data for a single resource from a Planner file.\n\n@param plannerResource Resource data", "Returns the result of the performed spellcheck formatted in JSON.\n\n@param request The CmsSpellcheckingRequest.\n@return JSONObject that contains the result of the performed spellcheck.", "Register custom filter types especially for serializer of specification json file", "Write exceptions into the format used by MSPDI files from\nProject 2007 onwards.\n\n@param calendar parent calendar\n@param exceptions list of exceptions" ]
public void removeScript(int id) throws Exception { PreparedStatement statement = null; try (Connection sqlConnection = SQLService.getInstance().getConnection()) { statement = sqlConnection.prepareStatement( "DELETE FROM " + Constants.DB_TABLE_SCRIPT + " WHERE " + Constants.GENERIC_ID + " = ?" ); statement.setInt(1, id); statement.executeUpdate(); } catch (SQLException e) { e.printStackTrace(); } finally { try { if (statement != null) { statement.close(); } } catch (Exception e) { } } }
[ "Remove script for a given ID\n\n@param id ID of script\n@throws Exception exception" ]
[ "Sets the name of the designated bone.\n\n@param boneindex zero based index of bone to rotate.\n@param bonename string with name of bone.\n. * @see #getBoneName", "Run a task periodically, for a set number of times.\n\n@param task\nTask to run.\n@param delay\nThe first execution will happen in {@code delay} seconds.\n@param period\nSubsequent executions will happen every {@code period} seconds\nafter the first.\n@param repetitions\nRepeat count\n@return {@code null} if {@code repetitions < 1}; otherwise, an interface\nthat lets you query the status; cancel; or reschedule the event.", "Initialize the pattern controllers.", "Loads configuration from InputStream. Later loads have lower priority.\n\n@param in InputStream to load from\n@since 1.2.0", "Extract resource provider from a resource ID string.\n@param id the resource ID string\n@return the resource group name", "Finds the null space of A\n@param A (Input) Matrix. Modified\n@param numSingularValues Number of singular values\n@param nullspace Storage for null-space\n@return true if successful or false if it failed", "Use this API to fetch all the appfwhtmlerrorpage resources that are configured on netscaler.", "Move the SQL value to the next one for version processing.", "2-D Integer array to float array.\n\n@param array Integer array.\n@return Float array." ]
public void process(InputStream is) throws Exception { readHeader(is); readVersion(is); readTableData(readTableHeaders(is), is); }
[ "Extract raw table data from the input stream.\n\n@param is input stream" ]
[ "Clears the internal used cache for object materialization.", "Build filter for the request.\n\n@param layerFilter layer filter\n@param featureIds features to include in report (null for all)\n@return filter\n@throws GeomajasException filter could not be parsed/created", "Adds the value to the Collection mapped to by the key.", "Get a TokenizerFactory that does Penn Treebank tokenization.\nThis is now the recommended factory method to use.\n\n@param factory A TokenFactory that determines what form of token is returned by the Tokenizer\n@param options A String specifying options (see the class javadoc for details)\n@param <T> The type of the tokens built by the LexedTokenFactory\n@return A TokenizerFactory that does Penn Treebank tokenization", "Finds trajectory by ID\n@param t List of Trajectories\n@param id ID of the trajectorie\n@return Trajectory with ID=id", "Filters attributes from the HTML string.\n\n@param html The HTML to filter.\n@return The filtered HTML string.", "The fields returned by default. Typically the output is done via display formatters and hence nearly no\nfield is necessary. Returning all fields might cause performance problems.\n\n@return the default return fields.", "Use this API to add locationfile.", "Inserts the provided document. If the document is missing an identifier, the client should\ngenerate one.\n\n@param document the document to insert\n@return a task containing the result of the insert one operation" ]
public Weld addBeanDefiningAnnotations(Class<? extends Annotation>... annotations) { for (Class<? extends Annotation> annotation : annotations) { this.extendedBeanDefiningAnnotations.add(annotation); } return this; }
[ "Registers annotations which will be considered as bean defining annotations.\n\nNOTE - If used along with {@code <trim/>} bean archives and/or with Weld configuration key\n{@code org.jboss.weld.bootstrap.vetoTypesWithoutBeanDefiningAnnotation}, these annotations will be ignored.\n\n@param annotations annotations which will be considered as Bean Defining Annotations.\n@return self" ]
[ "Gets the date time str standard.\n\n@param d\nthe d\n@return the date time str standard", "Launches the client with the specified parameters.\n\n@param args\ncommand line parameters\n@throws ParseException\n@throws IOException", "Re-initializes the shader texture used to fill in\nthe Circle upon drawing.", "Transits a float propertyId from the start value to the end value.\n\n@param propertyId\n@param vals\n@return self", "Check whether we have diverged from what we would predict from the last update that was sent to a particular\ntrack position listener.\n\n@param lastUpdate the last update that was sent to the listener\n@param currentUpdate the latest update available for the same player\n\n@return {@code true }if the listener will have diverged by more than our permitted amount of slack, and so\nshould be updated", "Add a mapping of properties between two beans\n\n@param beanToBeanMapping", "This method returns the duplicated certificate mapped to the passed in cert, or\ncreates and returns one if no mapping has yet been performed. If a naked public\nkey has already been mapped that matches the key in the cert, the already mapped\nkeypair will be reused for the mapped cert.\n@param cert\n@return\n@throws CertificateEncodingException\n@throws InvalidKeyException\n@throws CertificateException\n@throws CertificateNotYetValidException\n@throws NoSuchAlgorithmException\n@throws NoSuchProviderException\n@throws SignatureException\n@throws KeyStoreException\n@throws UnrecoverableKeyException", "convert a param object to a multimap.\n\n@param objectParams the parameters to convert.\n@return the corresponding Multimap.", "Resolve temporary folder." ]