query
stringlengths
74
6.1k
positive
sequencelengths
1
1
negative
sequencelengths
9
9
public static base_responses add(nitro_service client, gslbservice resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { gslbservice addresources[] = new gslbservice[resources.length]; for (int i=0;i<resources.length;i++){ addresources[i] = new gslbservice(); addresources[i].servicename = resources[i].servicename; addresources[i].cnameentry = resources[i].cnameentry; addresources[i].ip = resources[i].ip; addresources[i].servername = resources[i].servername; addresources[i].servicetype = resources[i].servicetype; addresources[i].port = resources[i].port; addresources[i].publicip = resources[i].publicip; addresources[i].publicport = resources[i].publicport; addresources[i].maxclient = resources[i].maxclient; addresources[i].healthmonitor = resources[i].healthmonitor; addresources[i].sitename = resources[i].sitename; addresources[i].state = resources[i].state; addresources[i].cip = resources[i].cip; addresources[i].cipheader = resources[i].cipheader; addresources[i].sitepersistence = resources[i].sitepersistence; addresources[i].cookietimeout = resources[i].cookietimeout; addresources[i].siteprefix = resources[i].siteprefix; addresources[i].clttimeout = resources[i].clttimeout; addresources[i].svrtimeout = resources[i].svrtimeout; addresources[i].maxbandwidth = resources[i].maxbandwidth; addresources[i].downstateflush = resources[i].downstateflush; addresources[i].maxaaausers = resources[i].maxaaausers; addresources[i].monthreshold = resources[i].monthreshold; addresources[i].hashid = resources[i].hashid; addresources[i].comment = resources[i].comment; addresources[i].appflowlog = resources[i].appflowlog; } result = add_bulk_request(client, addresources); } return result; }
[ "Use this API to add gslbservice resources." ]
[ "Generates a License regarding the parameters.\n\n@param name String\n@param longName String\n@param comments String\n@param regexp String\n@param url String\n@return License", "Returns the value that has to be set for the dynamic attribute.\n\n@param file the file where the current content is stored\n@param value the content value that is represented by the attribute\n@param attributeName the attribute's name\n@param editedLocalEntity the entities that where edited last\n@return the value that has to be set for the dynamic attribute.", "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", "Populate the supplied response with the model representation of the certificates.\n\n@param result the response to populate.\n@param certificates the certificates to add to the response.\n@throws CertificateEncodingException\n@throws NoSuchAlgorithmException", "This method handles submitting and then waiting for the request from the\nserver. It uses the ClientRequest API to actually write the request and\nthen read back the response. This implementation will not block for a\nresponse from the server.\n\n@param <T> Return type\n\n@param clientRequest ClientRequest implementation used to write the\nrequest and read the response\n@param operationName Simple string representing the type of request\n\n@return Data returned by the individual requests", "Read a nested table. Instantiates the supplied reader class to\nextract the data.\n\n@param reader table reader class\n@return table rows", "This method tokenizes a string by space characters,\nbut ignores spaces in quoted parts,that are parts in\n'' or \"\". The method does allows the usage of \"\" in ''\nand '' in \"\". The space character between tokens is not\nreturned.\n\n@param s the string to tokenize\n@return the tokens", "remove all prefetching listeners", "Handles an initial response from a PUT or PATCH operation response by polling the status of the operation\nasynchronously, once the operation finishes emits the final response.\n\n@param observable the initial observable from the PUT or PATCH operation.\n@param resourceType the java.lang.reflect.Type of the resource.\n@param <T> the return type of the caller.\n@return the observable of which a subscription will lead to a final response." ]
public ILog getOrCreateLog(String topic, int partition) throws IOException { final int configPartitionNumber = getPartition(topic); if (partition >= configPartitionNumber) { throw new IOException("partition is bigger than the number of configuration: " + configPartitionNumber); } boolean hasNewTopic = false; Pool<Integer, Log> parts = getLogPool(topic, partition); if (parts == null) { Pool<Integer, Log> found = logs.putIfNotExists(topic, new Pool<Integer, Log>()); if (found == null) { hasNewTopic = true; } parts = logs.get(topic); } // Log log = parts.get(partition); if (log == null) { log = createLog(topic, partition); Log found = parts.putIfNotExists(partition, log); if (found != null) { Closer.closeQuietly(log, logger); log = found; } else { logger.info(format("Created log for [%s-%d], now create other logs if necessary", topic, partition)); final int configPartitions = getPartition(topic); for (int i = 0; i < configPartitions; i++) { getOrCreateLog(topic, i); } } } if (hasNewTopic && config.getEnableZookeeper()) { topicRegisterTasks.add(new TopicTask(TopicTask.TaskType.CREATE, topic)); } return log; }
[ "Create the log if it does not exist or return back exist log\n\n@param topic the topic name\n@param partition the partition id\n@return read or create a log\n@throws IOException any IOException" ]
[ "returns a proxy or a fully materialized Object from the current row of the\nunderlying resultset.", "Prints a suggestion to stderr for the argument based on the levenshtein distance metric\n\n@param arg the argument which could not be assigned to a flag\n@param co the {@link ConfigOption} List where every flag is stored", "Sets the model that the handling works on.\n\n@param databaseModel The database model\n@param objModel The object model", "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", "Detaches or removes the value from this context.\n\n@param key the key to the attachment.\n@param <V> the value type of the attachment.\n\n@return the attachment if found otherwise {@code null}.", "Set the content type of a photo.\n\nThis method requires authentication with 'write' permission.\n\n@see com.flickr4java.flickr.Flickr#CONTENTTYPE_PHOTO\n@see com.flickr4java.flickr.Flickr#CONTENTTYPE_SCREENSHOT\n@see com.flickr4java.flickr.Flickr#CONTENTTYPE_OTHER\n@param photoId\nThe photo ID\n@param contentType\nThe contentType to set\n@throws FlickrException", "Given a resource field name, this method returns the resource field number.\n\n@param field resource field name\n@return resource field number", "Retrieve the jdbc type for the field descriptor that is related\nto this argument.", "Sets the maxConnectionAge. Any connections older than this setting will be closed\noff whether it is idle or not. Connections currently in use will not be affected until they\nare returned to the pool.\n\n@param maxConnectionAge the maxConnectionAge to set.\n@param timeUnit the unit of the maxConnectionAge argument." ]
private String formatRelationList(List<Relation> value) { String result = null; if (value != null && value.size() != 0) { StringBuilder sb = new StringBuilder(); for (Relation relation : value) { if (sb.length() != 0) { sb.append(m_delimiter); } sb.append(formatRelation(relation)); } result = sb.toString(); } return (result); }
[ "This method is called to format a relation list.\n\n@param value relation list instance\n@return formatted relation list" ]
[ "Sort and order steps to avoid unwanted generation", "Update the id field of the object in the database.", "SuppressWarnings I really want to return HazeltaskTasks instead of Runnable", "Sends a message to the dbserver, first assembling it into a single byte buffer so that it can be sent as\na single packet.\n\n@param message the message to be sent\n\n@throws IOException if there is a problem sending it", "Return a string representation of the object.", "Add a polygon symbolizer definition to the rule.\n\n@param styleJson The old style.", "Creates a map of identifiers or page titles to documents retrieved via\nthe APIs.\n\n@param numOfEntities\nnumber of entities that should be retrieved\n@param properties\nWbGetEntitiesProperties object that includes all relevant\nparameters for the wbgetentities action\n@return map of document identifiers or titles to documents retrieved via\nthe API URL\n@throws MediaWikiApiErrorException\n@throws IOException", "Add a new value to the array map.\n@param key The key under which to store the value. <b>Must not be null.</b> If\nthis key already exists in the array, its value will be replaced.\n@param value The value to store for the given key.\n@return Returns the old value that was stored for the given key, or null if there\nwas no such key.", "Performs a single synchronization pass in both the local and remote directions; the order\nof which does not matter. If switching the order produces different results after one pass,\nthen there is a bug.\n\n@return whether or not the synchronization pass was successful." ]
public QueryBuilder<T, ID> groupByRaw(String rawSql) { addGroupBy(ColumnNameOrRawSql.withRawSql(rawSql)); return this; }
[ "Add a raw SQL \"GROUP BY\" clause to the SQL query statement. This should not include the \"GROUP BY\"." ]
[ "Retrieves the value of the given accessible field of the given receiver.\n\n@param receiver the container of the field, not <code>null</code>\n@param fieldName the field's name, not <code>null</code>\n@return the value of the field\n\n@throws NoSuchFieldException see {@link Class#getField(String)}\n@throws SecurityException see {@link Class#getField(String)}\n@throws IllegalAccessException see {@link Field#get(Object)}\n@throws IllegalArgumentException see {@link Field#get(Object)}", "Detect what has changed in the store definition and rewire BDB\nenvironments accordingly.\n\n@param storeDef updated store definition", "Given the comma separated list of properties as a string, splits it\nmultiple strings\n\n@param paramValue Concatenated string\n@param type Type of parameter ( to throw exception )\n@return List of string properties", "Sets the monitoring service.\n\n@param monitoringService the new monitoring service", "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.", "Wrapper to avoid throwing an exception over JMX", "Get all the handlers at a specific address.\n\n@param address the address\n@param inherited true to include the inherited operations\n@return the handlers", "Compares two double values up to some delta.\n\n@param a\n@param b\n@param delta\n@return The value 0 if a equals b, a value greater than 0 if if a > b, and a value less than 0 if a < b.", "Use this API to fetch all the nsfeature resources that are configured on netscaler." ]
private static I_CmsResourceBundle tryBundle(String localizedName) { I_CmsResourceBundle result = null; try { String resourceName = localizedName.replace('.', '/') + ".properties"; URL url = CmsResourceBundleLoader.class.getClassLoader().getResource(resourceName); I_CmsResourceBundle additionalBundle = m_permanentCache.get(localizedName); if (additionalBundle != null) { result = additionalBundle.getClone(); } else if (url != null) { // the resource was found on the file system InputStream is = null; String path = CmsFileUtil.normalizePath(url); File file = new File(path); try { // try to load the resource bundle from a file, NOT with the resource loader first // this is important since using #getResourceAsStream() may return cached results, // for example Tomcat by default does cache all resources loaded by the class loader // this means a changed resource bundle file is not loaded is = new FileInputStream(file); } catch (IOException ex) { // this will happen if the resource is contained for example in a .jar file is = CmsResourceBundleLoader.class.getClassLoader().getResourceAsStream(resourceName); } catch (AccessControlException acex) { // fixed bug #1550 // this will happen if the resource is contained for example in a .jar file // and security manager is turned on. is = CmsResourceBundleLoader.class.getClassLoader().getResourceAsStream(resourceName); } if (is != null) { result = new CmsPropertyResourceBundle(is); } } } catch (IOException ex) { // can't localized these message since this may lead to a chicken-egg problem MissingResourceException mre = new MissingResourceException( "Failed to load bundle '" + localizedName + "'", localizedName, ""); mre.initCause(ex); throw mre; } return result; }
[ "Tries to load a property file with the specified name.\n\n@param localizedName the name\n@return the resource bundle if it was loaded, otherwise the backup" ]
[ "Show multiple channels. All other channels will be unaffected.\n@param channels The channels to show", "Set a colspan in a group of columns. First add the cols to the report\n\n@param colNumber the index of the col\n@param colQuantity the number of cols how i will take\n@param colspanTitle colspan title\n@return a Dynamic Report Builder\n@throws ColumnBuilderException When the index of the cols is out of\nbounds.", "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", "This method handles submitting and then waiting for the request from the\nserver. It uses the ClientRequest API to actually write the request and\nthen read back the response. This implementation will not block for a\nresponse from the server.\n\n@param <T> Return type\n\n@param clientRequest ClientRequest implementation used to write the\nrequest and read the response\n@param operationName Simple string representing the type of request\n\n@return Data returned by the individual requests", "generate a message for loglevel FATAL\n\n@param pObject the message Object", "Initializes the set of report implementation.", "Removes the specified list of users from following the project, this will not affect project membership status.\nReturns the updated project record.\n\n@param project The project to remove followers from.\n@return Request object", "Use this API to fetch all the sslservice resources that are configured on netscaler.", "Use this API to count sslcipher_individualcipher_binding resources configued on NetScaler." ]
public void endRecord_() { // this is where we actually update the link database. basically, // all we need to do is to retract those links which weren't seen // this time around, and that can be done via assertLink, since it // can override existing links. // get all the existing links Collection<Link> oldlinks = linkdb.getAllLinksFor(getIdentity(current)); // build a hashmap so we can look up corresponding old links from // new links if (oldlinks != null) { Map<String, Link> oldmap = new HashMap(oldlinks.size()); for (Link l : oldlinks) oldmap.put(makeKey(l), l); // removing all the links we found this time around from the set of // old links. any links remaining after this will be stale, and need // to be retracted for (Link newl : new ArrayList<Link>(curlinks)) { String key = makeKey(newl); Link oldl = oldmap.get(key); if (oldl == null) continue; if (oldl.overrides(newl)) // previous information overrides this link, so ignore curlinks.remove(newl); else if (sameAs(oldl, newl)) { // there's no new information here, so just ignore this curlinks.remove(newl); oldmap.remove(key); // we don't want to retract the old one } else // the link is out of date, but will be overwritten, so remove oldmap.remove(key); } // all the inferred links left in oldmap are now old links we // didn't find on this pass. there is no longer any evidence // supporting them, and so we can retract them. for (Link oldl : oldmap.values()) if (oldl.getStatus() == LinkStatus.INFERRED) { oldl.retract(); // changes to retracted, updates timestamp curlinks.add(oldl); } } // okay, now we write it all to the database for (Link l : curlinks) linkdb.assertLink(l); }
[ "this method is called from the event methods" ]
[ "If converters are set on a table, this function tests if these can convert a cell value. The first\nconverter, which claims that it can convert, will be used to do the conversion.", "Load the available layers.\n\n@param image the installed image\n@param productConfig the product config to establish the identity\n@param moduleRoots the module roots\n@param bundleRoots the bundle roots\n@return the layers\n@throws IOException", "This method is called to try to catch any invalid tasks that may have sneaked past all our other checks.\nThis is done by validating the tasks by task ID.", "On key down we assume the key will go at the end. It's the most\ncommon case and not that distracting if that's not true.", "Cache key calculation.\n@param sql\n@param resultSetType\n@param resultSetConcurrency\n@return cache key", "Pushes a basic event.\n\n@param eventName The name of the event", "Updates the exceptions.\n@param exceptions the exceptions to set", "Sets the database dialect.\n\n@param dialect\nthe database dialect", "Split string content into list\n@param content String content\n@return list" ]
public static <T> T buildInstanceForMap(Class<T> clazz, Map<String, Object> values, MyReflectionDifferenceHandler differenceHandler) throws InstantiationException, IllegalAccessException, IntrospectionException, IllegalArgumentException, InvocationTargetException { log.debug("Building new instance of Class " + clazz.getName()); T instance = clazz.newInstance(); for (String key : values.keySet()) { Object value = values.get(key); if (value == null) { log.debug("Value for field " + key + " is null, so ignoring it..."); continue; } log.debug( "Invoke setter for " + key + " (" + value.getClass() + " / " + value.toString() + ")"); Method setter = null; try { setter = new PropertyDescriptor(key.replace('.', '_'), clazz).getWriteMethod(); } catch (Exception e) { throw new IllegalArgumentException("Setter for field " + key + " was not found", e); } Class<?> argumentType = setter.getParameterTypes()[0]; if (argumentType.isAssignableFrom(value.getClass())) { setter.invoke(instance, value); } else { Object newValue = differenceHandler.handleDifference(value, setter.getParameterTypes()[0]); setter.invoke(instance, newValue); } } return instance; }
[ "Builds a instance of the class for a map containing the values\n\n@param clazz Class to build\n@param values Values map\n@param differenceHandler The difference handler\n@return The created instance\n@throws InstantiationException Error instantiating\n@throws IllegalAccessException Access error\n@throws IntrospectionException Introspection error\n@throws IllegalArgumentException Argument invalid\n@throws InvocationTargetException Invalid target" ]
[ "Fills in the element with the InputValues for input\n\n@param element the node element\n@param input the input data", "Checks the foreignkeys of all references in the model.\n\n@param modelDef The model\n@param checkLevel The current check level (this constraint is checked in basic and strict)\n@exception ConstraintException If the value for foreignkey is invalid", "Extract the parameters from a method using the Jmx annotation if present,\nor just the raw types otherwise\n\n@param m The method to extract parameters from\n@return An array of parameter infos", "Recursively searches for formatting annotations.\n\n@param visitedTypes used to prevent an endless loop\n@param parameterName", "Build a request URL.\n\n@param host\nThe host\n@param port\nThe port\n@param path\nThe path\n@param parameters\nThe parameters\n@return The URL\n@throws MalformedURLException\n@deprecated use {@link #buildSecureUrl(java.lang.String, int, java.lang.String, java.util.Map) }", "Decide which donor node to steal from. This is a policy implementation.\nI.e., in the future, additional policies could be considered. At that\ntime, this method should be overridden in a sub-class, or a policy object\nought to implement this algorithm.\n\nCurrent policy:\n\n1) If possible, a stealer node that is the zone n-ary in the finalCluster\nsteals from the zone n-ary in the currentCluster in the same zone.\n\n2) If there are no partition-stores to steal in the same zone (i.e., this\nis the \"zone expansion\" use case), then a differnt policy must be used.\nThe stealer node that is the zone n-ary in the finalCluster determines\nwhich pre-existing zone in the currentCluster hosts the primary partition\nid for the partition-store. The stealer then steals the zone n-ary from\nthat pre-existing zone.\n\nThis policy avoids unnecessary cross-zone moves and distributes the load\nof cross-zone moves approximately-uniformly across pre-existing zones.\n\nOther policies to consider:\n\n- For zone expansion, steal all partition-stores from one specific\npre-existing zone.\n\n- Replace heuristic to approximately uniformly distribute load among\nexisting zones to something more concrete (i.e. track steals from each\npre-existing zone and forcibly balance them).\n\n- Select a single donor for all replicas in a new zone. This will require\ndonor-based rebalancing to be run (at least for this specific part of the\nplan). This would reduce the number of donor-side scans of data. (But\nstill send replication factor copies over the WAN.) This would require\napparatus in the RebalanceController to work.\n\n- Set up some sort of chain-replication in which a single stealer in the\nnew zone steals some replica from a pre-exising zone, and then other\nn-aries in the new zone steal from the single cross-zone stealer in the\nzone. This would require apparatus in the RebalanceController to work.\n\n@param currentSRP\n@param finalSRP\n@param stealerZoneId\n@param stealerNodeId\n@param stealerPartitionId\n@return the node id of the donor for this partition Id.", "Create and add model controller handler to an existing management channel handler.\n\n@param handler the channel handler\n@return the created client", "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", "Method to build Integration Flow for Mail. Suppress Warnings for\nMailInboundChannelAdapterSpec.\n@return Integration Flow object for Mail Source" ]
public static nstrafficdomain_bridgegroup_binding[] get(nitro_service service, Long td) throws Exception{ nstrafficdomain_bridgegroup_binding obj = new nstrafficdomain_bridgegroup_binding(); obj.set_td(td); nstrafficdomain_bridgegroup_binding response[] = (nstrafficdomain_bridgegroup_binding[]) obj.get_resources(service); return response; }
[ "Use this API to fetch nstrafficdomain_bridgegroup_binding resources of given name ." ]
[ "Determine whether the given element matches this element.\nAn element matches this element when keys are equal, values are equal\nor this element value is a wildcard.\n@param pe the element to check\n@return {@code true} if the element matches", "Updates the indices in the index buffer from a Java char array.\nAll of the entries of the input char array are copied into\nthe storage for the index buffer. The new indices must be the\nsame size as the old indices - the index buffer size cannot be changed.\n@param data char array containing the new values\n@throws IllegalArgumentException if char array is wrong size", "Get the group URL for the specified group ID\n\n@param groupId\nThe group ID\n@return The group URL\n@throws FlickrException", "Save a SVG graphic to the given path.\n\n@param graphics2d The SVG graphic to save.\n@param path The file.", "Parses a raw WBS value from the database and breaks it into\ncomponent parts ready for formatting.\n\n@param value raw WBS value", "set the layout which will host the ScrimInsetsFrameLayout and its layoutParams\n\n@param container\n@param layoutParams\n@return", "Get a bean value from the context.\n\n@param name bean name\n@return bean value or null", "Returns true if conversion between the sourceType and targetType can be bypassed.\nMore precisely this method will return true if objects of sourceType can be\nconverted to the targetType by returning the source object unchanged.\n@param sourceType context about the source type to convert from (may be null if source is null)\n@param targetType context about the target type to convert to (required)\n@return true if conversion can be bypassed\n@throws IllegalArgumentException if targetType is null", "Creates a new ServerDetails object for resolver, this will take URL and name from the deployer ServerDetails as a default behaviour" ]
public ProteusApplication setServerConfigurationFunction(Function<Undertow.Builder, Undertow.Builder> serverConfigurationFunction) { this.serverConfigurationFunction = serverConfigurationFunction; return this; }
[ "Allows direct access to the Undertow.Builder for custom configuration\n\n@param serverConfigurationFunction the serverConfigurationFunction" ]
[ "Caches the results of radix to the given power.\n\n@param radix\n@param power\n@return", "Converts a date to an instance date bean.\n@return the instance date bean.", "Given the key, figures out which partition on the local node hosts the key.\n\n@param key\n@return", "Return the structured backup data\n\n@return Backup of current configuration\n@throws Exception exception", "Append the data of another lattice to this lattice. If the other lattice follows a different quoting convention, it is automatically converted.\nHowever, this method does not check, whether the two lattices are aligned in terms of reference date, curve names and meta schedules.\nIf the two lattices have shared data points, the data from this lattice will be overwritten.\n\n@param other The lattice containing the data to be appended.\n@param model The model to use for context, in case the other lattice follows a different convention.\n\n@return The lattice with the combined swaption entries.", "Returns the full record for a single story.\n\n@param story Globally unique identifier for the story.\n@return Request object", "Generates a schedule based on some meta data. The schedule generation\nconsiders short periods.\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@param dateRollConvention Adjustment to be applied to the all dates.\n@param businessdayCalendar Businessday calendar (holiday calendar) to be used for date roll adjustment.\n@param fixingOffsetDays Number of business days to be added to period start to get the fixing date.\n@param paymentOffsetDays Number of business days to be added to period end to get the payment date.\n@return The corresponding schedule\n@deprecated Will be removed in version 2.3", "This method decodes a byte array with the given encryption code\nusing XOR encryption.\n\n@param data Source data\n@param encryptionCode Encryption code", "Uncheck all items in the list including all sub-items.\n@param list list of CmsTreeItem entries." ]
public boolean accept(String str) { int k = str.length() - 1; char c = str.charAt(k); while (k >= 0 && !Character.isDigit(c)) { k--; if (k >= 0) { c = str.charAt(k); } } if (k < 0) { return false; } int j = k; c = str.charAt(j); while (j >= 0 && Character.isDigit(c)) { j--; if (j >= 0) { c = str.charAt(j); } } j++; k++; String theNumber = str.substring(j, k); int number = Integer.parseInt(theNumber); for (Pair<Integer,Integer> p : ranges) { int low = p.first().intValue(); int high = p.second().intValue(); if (number >= low && number <= high) { return true; } } return false; }
[ "Checks whether a String satisfies the number range selection filter.\nThe test is evaluated based on the rightmost natural number found in\nthe String. Note that this is just evaluated on the String as given.\nIt is not trying to interpret it as a filename and to decide whether\nthe file exists, is a directory or anything like that.\n\n@param str The String to check for a number in\n@return true If the String is within the ranges filtered for" ]
[ "Given a String the method uses Regex to check if the String only contains punctuation characters\n\n@param s a String to check using regex\n@return true if the String is valid", "Walk project references recursively, building up a list of thrift files they provide, starting\nwith an empty file list.", "Creates a new fixed size ThreadPoolExecutor\n\n@param threads\nthe number of threads\n@param groupname\na label to identify the threadpool; useful for profiling.\n@param queueSize\nthe size of the queue to store Runnables when all threads are busy\n@return the new ExecutorService", "Visits an annotation on a local variable type.\n\n@param typeRef\na reference to the annotated type. The sort of this type\nreference must be {@link TypeReference#LOCAL_VARIABLE\nLOCAL_VARIABLE} or {@link TypeReference#RESOURCE_VARIABLE\nRESOURCE_VARIABLE}. See {@link TypeReference}.\n@param typePath\nthe path to the annotated type argument, wildcard bound, array\nelement type, or static inner type within 'typeRef'. May be\n<tt>null</tt> if the annotation targets 'typeRef' as a whole.\n@param start\nthe fist instructions corresponding to the continuous ranges\nthat make the scope of this local variable (inclusive).\n@param end\nthe last instructions corresponding to the continuous ranges\nthat make the scope of this local variable (exclusive). This\narray must have the same size as the 'start' array.\n@param index\nthe local variable's index in each range. This array must have\nthe same size as the 'start' array.\n@param desc\nthe class descriptor of the annotation class.\n@param visible\n<tt>true</tt> if the annotation is visible at runtime.\n@return a visitor to visit the annotation values, or <tt>null</tt> if\nthis visitor is not interested in visiting this annotation.", "Creates a new Box Developer Edition connection with enterprise token leveraging BoxConfig.\n@param boxConfig box configuration settings object\n@return a new instance of BoxAPIConnection.", "Load an animation for the current avatar.\n@param animResource resource with the animation\n@param boneMap optional bone map to map animation skeleton to avatar", "BuildInteractiveObjectFromAnchor is a special type of interactive object in that it does not get\nbuilt using ROUTE's.\n\n@param anchorSensor is the Sensor that describes the sensor set to an Anchor\n@param anchorDestination is either another Viewpoint, url to a web site or another x3d scene", "Use this API to fetch responderpolicy resource of given name .", "calculate arc angle between point a and point b\n\n@param center\n@param a\n@param b\n@param area\n@param radius\n@return" ]
public <T extends StatementDocument> void nullEdit(ItemIdValue itemId) throws IOException, MediaWikiApiErrorException { ItemDocument currentDocument = (ItemDocument) this.wikibaseDataFetcher .getEntityDocument(itemId.getId()); nullEdit(currentDocument); }
[ "Performs a null edit on an item. This has some effects on Wikibase,\nsuch as refreshing the labels of the referred items in the UI.\n\n@param itemId\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" ]
[ "Commits the writes to the remote collection.", "Parses the date or returns null if it fails to do so.", "Search for the second entry in the second database. Use this method for databases configured with no duplicates.\n\n@param second second key (value for first).\n@return null if no entry found, otherwise the value.", "Plots the MSD curve with the trajectory t and adds the fitted model for anomalous diffusion above.\n@param t\n@param lagMin Minimum timelag (e.g. 1,2,3..) lagMin*timelag = elapsed time in seconds\n@param lagMax lagMax Maximum timelag (e.g. 1,2,3..) lagMax*timelag = elapsed time in seconds\n@param timelag Elapsed time between two frames.\n@param a Exponent alpha of power law function\n@param D Diffusion coeffcient", "Returns the Map value of the field.\n\n@return the Map value of the field. It returns a reference of the value both for <code>MAP</code> and\n<code>LIST_MAP</code>.\n@throws IllegalArgumentException if the value cannot be converted to Map.", "Use this API to update autoscaleprofile.", "Construct a new instance.\n\n@return the new instance", "Check that each emitted notification is properly described by its source.", "Overridden to add transform." ]
private void checkOrMarkPrivateAccess(Expression source, FieldNode fn) { if (fn!=null && Modifier.isPrivate(fn.getModifiers()) && (fn.getDeclaringClass() != typeCheckingContext.getEnclosingClassNode() || typeCheckingContext.getEnclosingClosure()!=null) && fn.getDeclaringClass().getModule() == typeCheckingContext.getEnclosingClassNode().getModule()) { addPrivateFieldOrMethodAccess(source, fn.getDeclaringClass(), StaticTypesMarker.PV_FIELDS_ACCESS, fn); } }
[ "Given a field node, checks if we are calling a private field from an inner class." ]
[ "Get the bar size.\n\n@param settings Parameters for rendering the scalebar.", "Returns a PreparedStatementCreator that returns a count of the rows that\nthis creator would return.\n\n@param dialect\nDatabase dialect.", "Gets the actual type arguments of a class\n\n@param clazz The class to examine\n@return The type arguments", "Returns the getter method associated with the object's field.\n\n@param object\nthe object\n@param fieldName\nthe name of the field\n@return the getter method\n@throws NullPointerException\nif object or fieldName is null\n@throws SuperCsvReflectionException\nif the getter doesn't exist or is not visible", "Use this API to add nspbr6 resources.", "This method writes task data to an MSPDI file.\n\n@param project Root node of the MSPDI file", "Use this API to fetch appfwprofile_excluderescontenttype_binding resources of given name .", "Get all categories\nGet all tags marked as categories\n@return ApiResponse&lt;TagsEnvelope&gt;\n@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body", "A callback that handles requestComplete event from NIO selector manager\nWill try any possible nodes and pass itself as callback util all nodes\nare exhausted\n\n@param slopKey\n@param slopVersioned\n@param nodesToTry List of nodes to try to contact. Will become shorter\nafter each callback" ]
private Query getQueryBySqlCount(QueryBySQL aQuery) { String countSql = aQuery.getSql(); int fromPos = countSql.toUpperCase().indexOf(" FROM "); if(fromPos >= 0) { countSql = "select count(*)" + countSql.substring(fromPos); } int orderPos = countSql.toUpperCase().indexOf(" ORDER BY "); if(orderPos >= 0) { countSql = countSql.substring(0, orderPos); } return new QueryBySQL(aQuery.getSearchClass(), countSql); }
[ "Create a Count-Query for QueryBySQL\n\n@param aQuery\n@return The count query" ]
[ "2-D Double array to integer array.\n\n@param array Double array.\n@return Integer array.", "Shuts down a managed domain container. The servers are first stopped, then the host controller is shutdown.\n\n@param client the client used to communicate with the server\n@param timeout the graceful shutdown timeout, a value of {@code -1} will wait indefinitely and a value of\n{@code 0} will not attempt a graceful shutdown\n\n@throws IOException if an error occurs communicating with the server\n@throws OperationExecutionException if the operation used to shutdown the managed domain failed", "Detach a scope from its parent, this will trigger the garbage collection of this scope and it's\nsub-scopes\nif they are not referenced outside of Toothpick.\n\n@param name the name of the scope to close.", "gets the bytes, sharing the cached array and does not clone it", "Set the scrollbar used for vertical scrolling.\n\n@param scrollbar the scrollbar, or null to clear it\n@param width the width of the scrollbar in pixels", "Counts the amount of 'ch' at the start of this line optionally ignoring\nspaces.\n\n@param ch\nThe char to count.\n@param allowSpaces\nWhether to allow spaces or not\n@return Number of characters found.\n@since 0.12", "Creates the style definition used for a rectangle element based on the given properties of the rectangle\n@param x The X coordinate of the rectangle.\n@param y The Y coordinate of the rectangle.\n@param width The width of the rectangle.\n@param height The height of the rectangle.\n@param stroke Should there be a stroke around?\n@param fill Should the rectangle be filled?\n@return The resulting element style definition.", "Possibly coalesces the newest change event to match the user's original intent. For example,\nan unsynchronized insert and update is still an insert.\n\n@param lastUncommittedChangeEvent the last change event known about for a document.\n@param newestChangeEvent the newest change event known about for a document.\n@return the possibly coalesced change event.", "Get random geographical location\n@return 2-Tuple of ints (latitude, longitude)" ]
public static clusterinstance_binding get(nitro_service service, Long clid) throws Exception{ clusterinstance_binding obj = new clusterinstance_binding(); obj.set_clid(clid); clusterinstance_binding response = (clusterinstance_binding) obj.get_resource(service); return response; }
[ "Use this API to fetch clusterinstance_binding resource of given name ." ]
[ "Generates the build-info module for this docker image.\nAdditionally. this method tags the deployed docker layers with properties,\nsuch as build.name, build.number and custom properties defined in the Jenkins build.\n@param build\n@param listener\n@param config\n@param buildName\n@param buildNumber\n@param timestamp\n@return\n@throws IOException", "Read a field from the supplied stream, starting with the tag that identifies the type, and reading enough\nto collect the corresponding value.\n\n@param is the stream on which a type tag is expected to be the next byte, followed by the field value.\n\n@return the field that was found on the stream.\n\n@throws IOException if there is a problem reading the field.", "Moves the cursor to the given row number in the iterator. If the row\nnumber is positive, the cursor moves to the given row number with\nrespect to the beginning of the iterator. The first row is row 1, the\nsecond is row 2, and so on.\n\n@param row the row to move to in this iterator, by absolute number", "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", "We have received notification that a device is no longer on the network, so clear out its artwork.\n\n@param announcement the packet which reported the device’s disappearance", "Converts a tab delimited string into an object with given fields\nRequires the object has setXxx functions for the specified fields\n\n@param objClass Class of object to be created\n@param str string to convert\n@param delimiterRegex delimiter regular expression\n@param fieldNames fieldnames\n@param <T> type to return\n@return Object created from string", "Retrieves the text value for the baseline duration.\n\n@return baseline duration text", "Sets the distance from the origin to the far clipping plane for the\nwhole camera rig.\n\n@param far\nDistance to the far clipping plane.", "The service name to be removed. Can be overridden for unusual service naming patterns\n@param name The name of the resource being removed\n@return The service name to remove. May return {@code null} if only removal based on {@code unavailableCapabilities}\npassed to the constructor are to be performed" ]
private static IndexedTypeSet toRootEntities(ExtendedSearchIntegrator extendedIntegrator, Class<?>... selection) { Set<Class<?>> entities = new HashSet<Class<?>>(); //first build the "entities" set containing all indexed subtypes of "selection". for ( Class<?> entityType : selection ) { IndexedTypeSet targetedClasses = extendedIntegrator.getIndexedTypesPolymorphic( IndexedTypeSets.fromClass( entityType ) ); if ( targetedClasses.isEmpty() ) { String msg = entityType.getName() + " is not an indexed entity or a subclass of an indexed entity"; throw new IllegalArgumentException( msg ); } entities.addAll( targetedClasses.toPojosSet() ); } Set<Class<?>> cleaned = new HashSet<Class<?>>(); Set<Class<?>> toRemove = new HashSet<Class<?>>(); //now remove all repeated types to avoid duplicate loading by polymorphic query loading for ( Class<?> type : entities ) { boolean typeIsOk = true; for ( Class<?> existing : cleaned ) { if ( existing.isAssignableFrom( type ) ) { typeIsOk = false; break; } if ( type.isAssignableFrom( existing ) ) { toRemove.add( existing ); } } if ( typeIsOk ) { cleaned.add( type ); } } cleaned.removeAll( toRemove ); log.debugf( "Targets for indexing job: %s", cleaned ); return IndexedTypeSets.fromClasses( cleaned.toArray( new Class[cleaned.size()] ) ); }
[ "From the set of classes a new set is built containing all indexed\nsubclasses, but removing then all subtypes of indexed entities.\n\n@param selection\n\n@return a new set of entities" ]
[ "Creates a descriptor for the bundle in the same folder where the bundle files are located.\n@throws CmsException thrown if creation fails.", "Use this API to fetch the statistics of all authenticationvserver_stats resources that are configured on netscaler.", "Retrieve the number of minutes per day for this calendar.\n\n@return minutes per day", "Saves the list of currently displayed favorites.", "Return a String of length a minimum of totalChars characters by\npadding the input String str at the right end with spaces.\nIf str is already longer\nthan totalChars, it is returned unchanged.", "Get a property as a json array or default.\n\n@param key the property name\n@param defaultValue default", "Set the buttons size.", "Returns new instance of OptionalString with given key and value\n@param key key of the returned OptionalString\n@param value wrapped string\n@return given object wrapped in OptionalString with given key", "Remove a part of a CharSequence by replacing the first occurrence\nof target within self with '' and returns the result.\n\n@param self a CharSequence\n@param target an object representing the part to remove\n@return a String containing the original minus the part to be removed\n@see #minus(String, Object)\n@since 1.8.2" ]
public static final String printTaskUID(Integer value) { ProjectFile file = PARENT_FILE.get(); if (file != null) { file.getEventManager().fireTaskWrittenEvent(file.getTaskByUniqueID(value)); } return (value.toString()); }
[ "Print a task UID.\n\n@param value task UID\n@return task UID string" ]
[ "Add UDFType objects to a PM XML file.\n\n@author kmahan\n@date 2014-09-24\n@author lsong\n@date 2015-7-24", "Use this API to fetch all the sslparameter resources that are configured on netscaler.", "This method is called to format a percentage value.\n\n@param value numeric value\n@return percentage value", "Guess whether given file is binary. Just checks for anything under 0x09.", "Encrypt a string with HMAC-SHA1 using the specified key.\n\n@param message Input string.\n@param key Encryption key.\n@return Encrypted output.", "Calculate start dates for a weekly recurrence.\n\n@param calendar current date\n@param frequency frequency\n@param dates array of start dates", "Prepare our statement for the subclasses.\n\n@param limit\nLimit for queries. Can be null if none.", "Returns a resource description resolver that uses common descriptions for some attributes.\n\n@param keyPrefix the prefix to be appended to the {@link LoggingExtension#SUBSYSTEM_NAME}\n\n@return the resolver", "Checks whether the given set of properties is available.\n\n@param keys the keys to check\n@return true if all properties are available, false otherwise" ]
@Deprecated public static URL buildUrl(String host, int port, String path, Map<String, String> parameters) throws MalformedURLException { return buildUrl("http", port, path, parameters); }
[ "Build a request URL.\n\n@param host\nThe host\n@param port\nThe port\n@param path\nThe path\n@param parameters\nThe parameters\n@return The URL\n@throws MalformedURLException\n@deprecated use {@link #buildSecureUrl(java.lang.String, int, java.lang.String, java.util.Map) }" ]
[ "Gets all Checkable widgets in the group\n@return list of Checkable widgets", "Apply the remote read domain model result.\n\n@param result the domain model result\n@return whether it was applied successfully or not", "Replaces an existing metadata value.\n@param path the path that designates the key. Must be prefixed with a \"/\".\n@param value the value.\n@return this metadata object.", "Retrieves the table structure for an Asta PP file. Subclasses determine the exact contents of the structure\nfor a specific version of the Asta PP file.\n\n@return PP file table structure", "Invoked when an action occurs.", "Obtain newline-delimited headers from response\n\n@param response HttpServletResponse to scan\n@return newline-delimited headers", "Get the authentication method to use.\n\n@return authentication method", "Returns the WDTK datatype IRI for the property datatype as represented by\nthe given JSON datatype string.\n\n@param jsonDatatype\nthe JSON datatype string; case-sensitive\n@throws IllegalArgumentException\nif the given datatype string is not known", "Given a method node, checks if we are calling a private method from an inner class." ]
static String tokenize(PageMetadata<?, ?> pageMetadata) { try { Gson g = getGsonWithKeyAdapter(pageMetadata.pageRequestParameters); return new String(Base64.encodeBase64URLSafe(g.toJson(new PaginationToken (pageMetadata)).getBytes("UTF-8")), Charset.forName("UTF-8")); } catch (UnsupportedEncodingException e) { //all JVMs should support UTF-8 throw new RuntimeException(e); } }
[ "Generate an opaque pagination token from the supplied PageMetadata.\n\n@param pageMetadata page metadata of the page for which the token should be generated\n@return opaque pagination token" ]
[ "Use this API to update snmpuser.", "Pretty prints the given source code.\n\n@param code\nsource code to format\n@param options\nformatter options\n@param lineEnding\ndesired line ending\n@return formatted source code", "calculate the difference of the two maps, so we know what was added, removed & updated\n@param left\n@param right\n@param onlyOnLeft\n@param onlyOnRight\n@param updated", "Returns the probability that the records v1 and v2 came from\nrepresent the same entity, based on high and low probability\nsettings etc.", "Changes the given filenames suffix from the current suffix to the provided suffix.\n\n<b>Directly exposed for JSP EL</b>, not through {@link org.opencms.jsp.util.CmsJspElFunctions}.<p>\n\n@param filename the filename to be changed\n@param suffix the new suffix of the file\n\n@return the filename with the replaced suffix", "Computes FPS average", "Internal method that adds a metadata provider to the set associated with a particular hash key, creating the\nset if needed.\n\n@param key the hashKey identifying the media for which this provider can offer metadata (or the empty string if\nit can offer metadata for all media)\n@param provider the metadata provider to be added to the active set", "set custom request for the default profile's default client\n\n@param pathName friendly name of path\n@param customData custom response/request data\n@return true if success, false otherwise", "Perform the given work with a Jedis connection from the given pool.\nWraps any thrown checked exceptions in a RuntimeException.\n\n@param pool the resource pool\n@param work the work to perform\n@param <V> the result type\n@return the result of the given work" ]
public IGoal[] getAgentGoals(final String agent_name, Connector connector) { ((IExternalAccess) connector.getAgentsExternalAccess(agent_name)) .scheduleStep(new IComponentStep<Plan>() { public IFuture<Plan> execute(IInternalAccess ia) { IBDIInternalAccess bia = (IBDIInternalAccess) ia; goals = bia.getGoalbase().getGoals(); return null; } }).get(new ThreadSuspendable()); return goals; }
[ "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" ]
[ "Returns the perma link for the current page based on the URI and detail content id stored in the CmsObject passed as a parameter.<p<\n\n@param cms the CMS context to use to generate the permalink\n\n@return the permalink", "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...)}", "Returns value as it appeared on the command line with escape sequences\nand system properties not resolved. The variables, though, are resolved\nduring the initial parsing of the command line.\n\n@param parsedLine parsed command line\n@param required whether the argument is required\n@return argument value as it appears on the command line\n@throws CommandFormatException in case the required argument is missing", "Returns true if the information in this link should take\nprecedence over the information in the other link.", "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", "Add the dependencies if the deployment contains a service activator loader entry.\n@param phaseContext the deployment unit context\n@throws DeploymentUnitProcessingException", "Notifies that an existing footer item is moved to another position.\n\n@param fromPosition the original position.\n@param toPosition the new position.", "Turn map into string\n\n@param propMap Map to be converted\n@return", "Answer the search class.\nThis is the class of the example object or\nthe class represented by Identity.\n@return Class" ]
public BoxFile.Info uploadLargeFile(InputStream inputStream, String fileName, long fileSize) throws InterruptedException, IOException { URL url = UPLOAD_SESSION_URL_TEMPLATE.build(this.getAPI().getBaseUploadURL()); return new LargeFileUpload(). upload(this.getAPI(), this.getID(), inputStream, url, fileName, fileSize); }
[ "Creates a new file.\n\n@param inputStream the stream instance that contains the data.\n@param fileName the name of the file to be created.\n@param fileSize the size of the file that will be uploaded.\n@return the created file instance.\n@throws InterruptedException when a thread execution is interrupted.\n@throws IOException when reading a stream throws exception." ]
[ "Use this API to enable Interface of given name.", "Gets the index to use in the search.\n\n@return the index to use in the search", "Rotate root widget to make it facing to the front of the scene", "Use this API to fetch clusterinstance resource of given name .", "Adds not Null criteria,\ncustomer_id is not Null\nThe attribute will NOT be translated into column name\n\n@param column The column name to be used without translation", "Bessel function of the first kind, of order n.\n\n@param n Order.\n@param x Value.\n@return I value.", "Support the range subscript operator for String with IntRange\n\n@param text a String\n@param range an IntRange\n@return the resulting String\n@since 1.0", "Gets the project name for a favorite entry.\n\n@param cms the CMS context\n@param entry the favorite entry\n@return the project name for the favorite entry\n@throws CmsException if something goes wrong", "Send a data to Incoming Webhook endpoint." ]
private String tail(String moduleName) { if (moduleName.indexOf(MODULE_NAME_SEPARATOR) > 0) { return moduleName.substring(moduleName.indexOf(MODULE_NAME_SEPARATOR) + 1); } else { return ""; } }
[ "get all parts of module name apart from first" ]
[ "Calculate the first argument raised to the power of the second.\nThis method only supports non-negative powers.\n@param value The number to be raised.\n@param power The exponent (must be positive).\n@return {@code value} raised to {@code power}.", "This is needed when running on slaves.", "Isn't there a method for this in GeoTools?\n\n@param crs\nCRS string in the form of 'EPSG:<srid>'.\n@return SRID as integer.", "Returns the encoding of the file.\nEncoding is read from the content-encoding property and defaults to the systems default encoding.\nSince properties can change without rewriting content, the actual encoding can differ.\n\n@param cms {@link CmsObject} used to read properties of the given file.\n@param file the file for which the encoding is requested\n@return the file's encoding according to the content-encoding property, or the system's default encoding as default.", "Filter that's either negated or normal as specified.", "Push docker image using the docker java client.\n\n@param imageTag\n@param username\n@param password\n@param host", "Patches the product module names\n\n@param name String\n@param moduleNames List<String>", "Attempts to checkout a resource so that one queued request can be\nserviced.\n\n@param key The key for which to process the requestQueue\n@return true iff an item was processed from the Queue.", "Creates a new tag in a workspace or organization.\n\nEvery tag is required to be created in a specific workspace or\norganization, and this cannot be changed once set. Note that you can use\nthe `workspace` parameter regardless of whether or not it is an\norganization.\n\nReturns the full record of the newly created tag.\n\n@param workspace The workspace or organization to create the tag in.\n@return Request object" ]
public GVRAndroidResource openResource(String filePath) throws IOException { // Error tolerance: Remove initial '/' introduced by file::///filename // In this case, the path is interpreted as relative to defaultPath, // which is the root of the filesystem. if (filePath.startsWith(File.separator)) { filePath = filePath.substring(File.separator.length()); } filePath = adaptFilePath(filePath); String path; int resourceId; GVRAndroidResource resourceKey; switch (volumeType) { case ANDROID_ASSETS: // Resolve '..' and '.' path = getFullPath(defaultPath, filePath); path = new File(path).getCanonicalPath(); if (path.startsWith(File.separator)) { path = path.substring(1); } resourceKey = new GVRAndroidResource(gvrContext, path); break; case ANDROID_RESOURCE: path = FileNameUtils.getBaseName(filePath); resourceId = gvrContext.getContext().getResources().getIdentifier(path, "raw", gvrContext.getContext().getPackageName()); if (resourceId == 0) { throw new FileNotFoundException(filePath + " resource not found"); } resourceKey = new GVRAndroidResource(gvrContext, resourceId); break; case LINUX_FILESYSTEM: resourceKey = new GVRAndroidResource( getFullPath(defaultPath, filePath)); break; case ANDROID_SDCARD: String linuxPath = Environment.getExternalStorageDirectory() .getAbsolutePath(); resourceKey = new GVRAndroidResource( getFullPath(linuxPath, defaultPath, filePath)); break; case INPUT_STREAM: resourceKey = new GVRAndroidResource(getFullPath(defaultPath, filePath), volumeInputStream); break; case NETWORK: resourceKey = new GVRAndroidResource(gvrContext, getFullURL(defaultPath, filePath), enableUrlLocalCache); break; default: throw new IOException( String.format("Unrecognized volumeType %s", volumeType)); } return addResource(resourceKey); }
[ "Opens a file from the volume. The filePath is relative to the\ndefaultPath.\n\n@param filePath\nFile path of the resource to open.\n\n@throws IOException" ]
[ "Displays a sample model for the report request.\n@return A string describing the structure of a certain report execution", "Calculates Tangent value of the complex number.\n\n@param z1 A ComplexNumber instance.\n@return Returns new ComplexNumber instance containing the Tangent value of the specified complex number.", "Add a new check box.\n@param date the date for the check box\n@param checkState the initial check state.", "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.", "Converts any path into something that can be placed in an Android directory.\n\nTraverses any subdirectories and flattens it all into a single filename. Also\ngets rid of commonly seen illegal characters in tz identifiers, and lower cases\nthe entire thing.\n\n@param path the path to convert\n@return a flat path with no directories (and lower-cased)", "returns a Logger.\n\n@param loggerName the name of the Logger\n@return Logger the returned Logger", "Capture stdout and route them through Redwood\n@return this", "Scales a process type\n\n@param appName See {@link #listApps} for a list of apps that can be used.\n@param processType type of process to maintain\n@param quantity number of processes to maintain", "copy all fields from the \"from\" object to the \"to\" object.\n\n@param from source object\n@param to from's clone\n@param fields fields to be populated\n@param accessible 'true' if all 'fields' have been made accessible during\ntraversal" ]
private void processHyperlinkData(Task task, byte[] data) { if (data != null) { int offset = 12; String hyperlink; String address; String subaddress; offset += 12; hyperlink = MPPUtility.getUnicodeString(data, offset); offset += ((hyperlink.length() + 1) * 2); offset += 12; address = MPPUtility.getUnicodeString(data, offset); offset += ((address.length() + 1) * 2); offset += 12; subaddress = MPPUtility.getUnicodeString(data, offset); task.setHyperlink(hyperlink); task.setHyperlinkAddress(address); task.setHyperlinkSubAddress(subaddress); } }
[ "This method is used to extract the task hyperlink attributes\nfrom a block of data and call the appropriate modifier methods\nto configure the specified task object.\n\n@param task task instance\n@param data hyperlink data block" ]
[ "Adds the specified type to this frame, and returns a new object that implements this type.", "Method used as dynamical parameter converter", "Sets the specified long attribute to the specified value.\n\n@param name name of the attribute\n@param value value of the attribute\n@since 1.9.0", "Returns the export format indicated in the result-type parameter \"layoutManager\"\n@param _invocation\n@return", "Checks that arguments and parameter types match.\n@param params method parameters\n@param args type arguments\n@return -1 if arguments do not match, 0 if arguments are of the exact type and >0 when one or more argument is\nnot of the exact type but still match", "Given a set of versions, constructs a resolved list of versions based on\nthe compare function above\n\n@param values\n@return list of values after resolution", "Creates the parents of nested XML elements if necessary.\n@param xmlContent the XML content that is edited.\n@param xmlPath the path of the (nested) element, for which the parents should be created\n@param l the locale for which the XML content is edited.", "Converts a class into a signature token.\n\n@param c class\n@return signature token text", "This method retrieves the UID for a calendar associated with a task.\n\n@param mpx MPX Task instance\n@return calendar UID" ]
public static <K, V> Map<K, V> of(K key, V value) { return new ImmutableMapEntry<K, V>(key, value); }
[ "Creates an immutable singleton instance.\n\n@param key\n@param value\n@return" ]
[ "Returns iban's country code and check digit.\n\n@param iban String\n@return countryCodeAndCheckDigit String", "This method writes task data to an MSPDI file.\n\n@param project Root node of the MSPDI file", "Puts a new document in the service. The generate key is globally unique.\n\n@param document document\n@return key unique key to reference the document", "Compute eigenvalues. This is a routine not in ATLAS, but in the original\nLAPACK.", "Initializes data structures", "Use this API to fetch a vpnglobal_vpntrafficpolicy_binding resources.", "Accessor method used to retrieve a char representing the\ncontents of an individual field. If the field does not exist in the\nrecord, the default character is returned.\n\n@param field the index number of the field to be retrieved\n@return the value of the required field", "Moves the drawer to the position passed.\n\n@param position The position the content is moved to.\n@param velocity Optional velocity if called by releasing a drag event.\n@param animate Whether the move is animated.", "Discards any tracks from the hot cache that were loaded from a now-unmounted media slot, because they are no\nlonger valid." ]
private static JsonArray getJsonArray(List<String> keys) { JsonArray array = new JsonArray(); for (String key : keys) { array.add(key); } return array; }
[ "Gets the Json Array representation of the given list of strings.\n@param keys List of strings\n@return the JsonArray represents the list of keys" ]
[ "Processes an index descriptor tag.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException If an error occurs\[email protected] type=\"content\"\[email protected] name=\"documentation\" optional=\"true\" description=\"Documentation on the index\"\[email protected] name=\"fields\" optional=\"false\" description=\"The fields making up the index separated by commas\"\[email protected] name=\"name\" optional=\"false\" description=\"The name of the index descriptor\"\[email protected] name=\"unique\" optional=\"true\" description=\"Whether the index descriptor is unique\" values=\"true,false\"", "This method will be intercepted by the proxy if it is enabled to return the internal target.\n@return the target.", "Pretty print a progress update after each batch complete.\n\n@param batchCount current batch\n@param numBatches total number of batches\n@param partitionStoreCount partition stores migrated\n@param numPartitionStores total number of partition stores to migrate\n@param totalTimeMs total time, in milliseconds, of execution thus far.", "Read a single outline code field extended attribute.\n\n@param entityID parent entity\n@param row field data", "Parse a percent complete value.\n\n@param value sting representation of a percent complete value.\n@return Double instance", "Configure column aliases.", "Write each predecessor for a task.\n\n@param record Task instance", "Use this API to delete sslcipher resources of given names.", "Tests whether the given string is the name of a java.lang type." ]
public static Type getDeclaredBeanType(Class<?> clazz) { Type[] actualTypeArguments = Reflections.getActualTypeArguments(clazz); if (actualTypeArguments.length == 1) { return actualTypeArguments[0]; } else { return null; } }
[ "Gets the declared bean type\n\n@return The bean type" ]
[ "Abort and close the transaction.\nCalling abort abandons all persistent object modifications and releases the\nassociated locks.\nIf transaction is not in progress a TransactionNotInProgressException is thrown", "Adds a step to the steps.\n\n@param name {@link String} name of the step\n@param robot {@link String} name of the robot used by the step.\n@param options {@link Map} extra options required for the step.", "Stop interpolating playback position for all active players.", "Use this API to fetch appfwjsoncontenttype resources of given names .", "Execute all recorded tasks.\n\n@param context the patch context\n@param callback the finalization callback\n@throws Exception", "The Baseline Start field shows the planned beginning date for a task at\nthe time you saved a baseline. Information in this field becomes available\nwhen you set a baseline.\n\n@return Date", "Generates the context diagram for a single class", "This method permanently removes a webhook. Note that it may be possible\nto receive a request that was already in flight after deleting the\nwebhook, but no further requests will be issued.\n\n@param webhook The webhook to delete.\n@return Request object", "Use this API to update clusterinstance resources." ]
public static GregorianCalendar millisToCalendar(long millis) { GregorianCalendar result = new GregorianCalendar(); result.setTimeZone(TimeZone.getTimeZone("GMT")); result.setTimeInMillis((long)(Math.ceil(millis / 1000) * 1000)); return result; }
[ "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" ]
[ "Main method of this class related to ListView widget. This method is the responsible of\nrecycle or create a new Renderer instance with all the needed information to implement the\nrendering. This method will validate all the attributes passed in the builder constructor and\nwill check if can recycle or has to create a new Renderer instance.\n\nThis method is used with ListView because the view recycling mechanism is implemented in this\nclass. RecyclerView widget will use buildRendererViewHolder method.\n\n@return ready to use Renderer instance.", "Use this API to renumber nspbr6.", "Set the active view.\nIf the mdActiveIndicator attribute is set, this View will have the indicator drawn next to it.\n\n@param v The active view.\n@param position Optional position, usually used with ListView. v.setTag(R.id.mdActiveViewPosition, position)\nmust be called first.", "Checks if the date is a holiday\n\n@param dateString the date\n@return true if it is a holiday, false otherwise", "Setting the type of Checkbox.", "Set the model used by the left table.\n\n@param model table model", "Checks that locking and update-lock are only used for fields of TIMESTAMP or INTEGER type.\n\n@param fieldDef The field descriptor\n@param checkLevel The current check level (this constraint is checked in basic and strict)\n@exception ConstraintException If the constraint has been violated", "This method is called to try to catch any invalid tasks that may have sneaked past all our other checks.\nThis is done by validating the tasks by task ID.", "Creates a style definition used for the body element.\n@return The body style definition." ]
public static base_responses update(nitro_service client, nslimitselector resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { nslimitselector updateresources[] = new nslimitselector[resources.length]; for (int i=0;i<resources.length;i++){ updateresources[i] = new nslimitselector(); updateresources[i].selectorname = resources[i].selectorname; updateresources[i].rule = resources[i].rule; } result = update_bulk_request(client, updateresources); } return result; }
[ "Use this API to update nslimitselector resources." ]
[ "Walk project references recursively, adding thrift files to the provided list.", "Parse a string representation of password spec.\n\nA password spec string should be `<trait spec><length spec>`.\n\nWhere \"trait spec\" should be a composition of\n\n* `a` - indicate lowercase letter required\n* `A` - indicate uppercase letter required\n* `0` - indicate digit letter required\n* `#` - indicate special character required\n\n\"length spec\" should be `[min,max]` where `max` can be omitted.\n\nHere are examples of valid \"length spec\":\n\n* `[6,20]` // min length: 6, max length: 20\n* `[8,]` // min length: 8, max length: unlimited\n\nAnd examples of invalid \"length spec\":\n\n* `[8]` // \",\" required after min part\n* `[a,f]` // min and max part needs to be decimal digit(s)\n* `[3,9)` // length spec must be started with `[` and end with `]`\n\n@param spec a string representation of password spec\n@return a {@link PasswordSpec} instance", "Returns an Array with an Objects PK VALUES if convertToSql is true, any\nassociated java-to-sql conversions are applied. If the Object is a Proxy\nor a VirtualProxy NO conversion is necessary.\n\n@param objectOrProxy\n@param convertToSql\n@return Object[]\n@throws PersistenceBrokerException", "Set the offsets in the compressed data area for each mip-map level.\n@param offsets array of offsets", "Appends the query part for the facet to the query string.\n@param query The current query string.\n@param name The name of the facet parameter, e.g. \"limit\", \"order\", ....\n@param value The value to set for the parameter specified by name.", "Set the values of a set of knots.\n@param x the knot positions\n@param y the knot colors\n@param types the knot types\n@param offset the first knot to set\n@param count the number of knots", "Add a LIKE clause so the column must mach the value using '%' patterns.", "Adds parameters contained in the annotation into the annotation type reference\n\n@param typeRef\n@param node", "Get range around median containing specified percentage of values.\n@param values Values.\n@param percent Values percentage around median.\n@return Returns the range which containes specifies percentage of values." ]
public static ipset[] get(nitro_service service) throws Exception{ ipset obj = new ipset(); ipset[] response = (ipset[])obj.get_resources(service); return response; }
[ "Use this API to fetch all the ipset resources that are configured on netscaler." ]
[ "Retrieves the timephased breakdown of actual cost.\n\n@return timephased actual cost", "Calculate the units percent complete.\n\n@param row task data\n@return percent complete", "The sniffing Loggers are some special Loggers, whose level will be set to TRACE forcedly.\n@param logger", "Reads and consumes a number of characters from the underlying reader,\nfilling the byte array provided.\n\n@param holder A byte array which will be filled with bytes read from the underlying reader.\n@throws ProtocolException If a char can't be read into each array element.", "Returns the Java command to use.\n\n@param javaHome the Java Home, if {@code null} an attempt to determine the command will be done\n\n@return the Java executable command", "Use this API to fetch appqoepolicy resource of given name .", "Initializes class data structures and parameters", "Returns the Field for a given parent class and a dot-separated path of\nfield names.\n\n@param clazz\nParent class.\n@param path\nPath to the desired field.", "Gets the appropriate cache dir\n\n@param ctx\n@return" ]
public void setOuterConeAngle(float angle) { setFloat("outer_cone_angle", (float) Math.cos(Math.toRadians(angle))); mChanged.set(true); }
[ "Set the inner angle of the spotlight cone in degrees.\n\nBeyond the outer cone angle there is no illumination.\nThe underlying uniform \"outer_cone_angle\" is the cosine\nof this input angle. If the inner cone angle is larger than the outer cone angle\nthere will be unexpected results.\n@see #setInnerConeAngle(float)\n@see #getOuterConeAngle()" ]
[ "Use this API to delete gslbservice of given name.", "Prints the error message as log message.\n\n@param level the log level", "Manual check because introducing a capability can't be done without a full refactoring.\nThis has to go as soon as the management interfaces are redesigned.\n@param context the OperationContext\n@param otherManagementEndpoint : the address to check that may provide an exposed jboss-remoting endpoint.\n@throws OperationFailedException in case we can't remove the management resource.", "Print a booking type.\n\n@param value BookingType instance\n@return booking type value", "Creates a code location URL from a URL\n\n@param url the URL external form\n@return A URL created from URL\n@throws InvalidCodeLocation if URL creation fails", "Creates SLD rules for each old style.", "Returns the coordinates of the vertex points of this hull.\n\n@param coords\nreturns the x, y, z coordinates of each vertex. This length of\nthis array must be at least three times the number of\nvertices.\n@return the number of vertices\n@see QuickHull3D#getVertices()\n@see QuickHull3D#getFaces()", "Saves the loaded XML bundle as property bundle.\n@throws UnsupportedEncodingException thrown if localizations from the XML bundle could not be loaded correctly.\n@throws CmsException thrown if any of the interactions with the VFS fails.\n@throws IOException thrown if localizations from the XML bundle could not be loaded correctly.", "Deletes a product from the database\n\n@param name String" ]
public static responderparam get(nitro_service service) throws Exception{ responderparam obj = new responderparam(); responderparam[] response = (responderparam[])obj.get_resources(service); return response[0]; }
[ "Use this API to fetch all the responderparam resources that are configured on netscaler." ]
[ "Get the status of the upload session. It contains the number of parts that are processed so far,\nthe total number of parts required for the commit and expiration date and time of the upload session.\n@return the status.", "Compute morse.\n\n@param term the term\n@return the string", "Utility function to zip the content of an entire folder, but not the folder itself.\n@param folder\n@param fileName optional\n@return success or not", "Will scale the image down before processing for\nperformance enhancement and less memory usage\nsacrificing image quality.\n\n@param scaleInSample value greater than 1 will scale the image width/height, so 2 will getFromDiskCache you 1/4\nof the original size and 4 will getFromDiskCache you 1/16 of the original size - this just sets\nthe inSample size in {@link android.graphics.BitmapFactory.Options#inSampleSize } and\nbehaves exactly the same, so keep the value 2^n for least scaling artifacts", "invoked from the jelly file\n\n@throws Exception Any exception", "Returns the real key object.", "Use this API to fetch csvserver_appflowpolicy_binding resources of given name .", "Use this API to fetch rnat6_nsip6_binding resources of given name .", "Return the basis functions for the regression suitable for this product.\n\n@param fixingDate The condition time.\n@param model The model\n@return The basis functions for the regression suitable for this product.\n@throws net.finmath.exception.CalculationException Thrown if the valuation fails, specific cause may be available via the <code>cause()</code> method." ]
public List<Gallery> getList(String userId, int perPage, int page) throws FlickrException { Map<String, Object> parameters = new HashMap<String, Object>(); parameters.put("method", METHOD_GET_LIST); parameters.put("user_id", userId); if (perPage > 0) { parameters.put("per_page", String.valueOf(perPage)); } if (page > 0) { parameters.put("page", String.valueOf(page)); } Response response = transport.post(transport.getPath(), parameters, apiKey, sharedSecret); if (response.isError()) { throw new FlickrException(response.getErrorCode(), response.getErrorMessage()); } Element element = response.getPayload(); GalleryList<Gallery> galleries = new GalleryList<Gallery>(); galleries.setPage(element.getAttribute("page")); galleries.setPages(element.getAttribute("pages")); galleries.setPerPage(element.getAttribute("per_page")); galleries.setTotal(element.getAttribute("total")); NodeList galleryNodes = element.getElementsByTagName("gallery"); for (int i = 0; i < galleryNodes.getLength(); i++) { Element galleryElement = (Element) galleryNodes.item(i); Gallery gallery = new Gallery(); gallery.setId(galleryElement.getAttribute("id")); gallery.setUrl(galleryElement.getAttribute("url")); User owner = new User(); owner.setId(galleryElement.getAttribute("owner")); gallery.setOwner(owner); gallery.setCreateDate(galleryElement.getAttribute("date_create")); gallery.setUpdateDate(galleryElement.getAttribute("date_update")); gallery.setPrimaryPhotoId(galleryElement.getAttribute("primary_photo_id")); gallery.setPrimaryPhotoServer(galleryElement.getAttribute("primary_photo_server")); gallery.setPrimaryPhotoFarm(galleryElement.getAttribute("primary_photo_farm")); gallery.setPrimaryPhotoSecret(galleryElement.getAttribute("primary_photo_secret")); gallery.setPhotoCount(galleryElement.getAttribute("count_photos")); gallery.setVideoCount(galleryElement.getAttribute("count_videos")); galleries.add(gallery); } return galleries; }
[ "Return the list of galleries created by a user. Sorted from newest to oldest.\n\n@param userId\nThe user you want to check for\n@param perPage\nNumber of galleries per page\n@param page\nThe page number\n@return gallery\n@throws FlickrException\n\n@see <a hrerf=\"http://www.flickr.com/services/api/flickr.galleries.getList.html\">flickr.galleries.getList</a>" ]
[ "Runs the command session.\nCreate the Shell, then run this method to listen to the user,\nand the Shell will invoke Handler's methods.\n@throws java.io.IOException when can't readLine() from input.", "Deletes a template.\n\n@param id id of the template to delete.\n@return {@link Response}\n\n@throws RequestException if request to transloadit server fails.\n@throws LocalOperationException if something goes wrong while running non-http operations.", "Render the scalebar.\n\n@param mapContext The context of the map for which the scalebar is created.\n@param scalebarParams The scalebar parameters.\n@param tempFolder The directory in which the graphic file is created.\n@param template The template that containts the scalebar processor", "Returns a byte array containing a copy of the bytes", "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.", "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", "Delete a record.\n\n@param referenceId the reference ID.", "Log a fatal message with a throwable.", "Returns the name of the current member which is the name in the case of a field, or the property name for an\naccessor method.\n\n@return The member name\n@exception XDocletException if an error occurs" ]
public BoxFileUploadSession.Info getStatus() { URL statusURL = this.sessionInfo.getSessionEndpoints().getStatusEndpoint(); BoxJSONRequest request = new BoxJSONRequest(this.getAPI(), statusURL, HttpMethod.GET); BoxJSONResponse response = (BoxJSONResponse) request.send(); JsonObject jsonObject = JsonObject.readFrom(response.getJSON()); this.sessionInfo.update(jsonObject); return this.sessionInfo; }
[ "Get the status of the upload session. It contains the number of parts that are processed so far,\nthe total number of parts required for the commit and expiration date and time of the upload session.\n@return the status." ]
[ "This method retrieves an integer of the specified type,\nbelonging to the item with the specified unique ID.\n\n@param id unique ID of entity to which this data belongs\n@param type data type identifier\n@return required integer data", "This must be called with the write lock held.\n@param requirement the requirement", "Sets up Log4J to write log messages to the console. Low-priority messages\nare logged to stdout while high-priority messages go to stderr.", "Do the search, called as a \"page action\"", "The Critical field indicates whether a task has any room in the schedule\nto slip, or if a task is on the critical path. The Critical field contains\nYes if the task is critical and No if the task is not critical.\n\n@return boolean", "Compares two annotated parameters and returns true if they are equal", "Write flow id.\n\n@param message the message\n@param flowId the flow id", "Combines weighted crf with this crf\n\n@param crf\n@param weight", "Adds the specified class to the internal class graph along with its\nrelations and dependencies, eventually inferring them, according to the\nOptions specified for this matcher\n@param cd" ]
protected long preConnection() throws SQLException{ long statsObtainTime = 0; if (this.pool.poolShuttingDown){ throw new SQLException(this.pool.shutdownStackTrace); } if (this.pool.statisticsEnabled){ statsObtainTime = System.nanoTime(); this.pool.statistics.incrementConnectionsRequested(); } return statsObtainTime; }
[ "Prep for a new connection\n@return if stats are enabled, return the nanoTime when this connection was requested.\n@throws SQLException" ]
[ "This method log given exception in specified listener", "Get the rate types set.\n\n@return the rate types set, or an empty array, but never null.", "Use this API to fetch aaauser_aaagroup_binding resources of given name .", "Delete a record.\n\n@param referenceId the reference ID.", "Sets the protocol.\n@param protocol The protocol to be set.", "Return the index associated to the Renderer.\n\n@param renderer used to search in the prototypes collection.\n@return the prototype index associated to the renderer passed as argument.", "removes an Object from the cache.\n\n@param oid the Identity of the object to be removed.", "Return a list of place IDs for a query string.\n\nThe flickr.places.find method is not a geocoder. It will round \"up\" to the nearest place type to which place IDs apply. For example, if you pass it a\nstreet level address it will return the city that contains the address rather than the street, or building, itself.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@param query\n@return PlacesList\n@throws FlickrException", "Sends a user a password reset email for the given email.\n\n@param email the email of the user.\n@return A {@link Task} that completes when the reqest request completes/fails." ]
public void ifHasMemberWithTag(String template, Properties attributes) throws XDocletException { ArrayList allMemberNames = new ArrayList(); HashMap allMembers = new HashMap(); boolean hasTag = false; addMembers(allMemberNames, allMembers, getCurrentClass(), null, null, null); for (Iterator it = allMemberNames.iterator(); it.hasNext(); ) { XMember member = (XMember) allMembers.get(it.next()); if (member instanceof XField) { setCurrentField((XField)member); if (hasTag(attributes, FOR_FIELD)) { hasTag = true; } setCurrentField(null); } else if (member instanceof XMethod) { setCurrentMethod((XMethod)member); if (hasTag(attributes, FOR_METHOD)) { hasTag = true; } setCurrentMethod(null); } if (hasTag) { generate(template); break; } } }
[ "Evaluates the body if the current class has at least one member with at least one tag with the specified name.\n\n@param template The body of the block tag\n@param attributes The attributes of the template tag\n@exception XDocletException Description of Exception\[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=\"error\" description=\"Show this error message if no tag found.\"" ]
[ "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)}", "Reads all sub-categories below the provided category.\n@return The map from the provided category to it's sub-categories in a {@link CmsJspCategoryAccessBean}.", "This method takes the value of an agent's belief through its external\naccess\n\n@param agent_name\nThe name of the agent\n@param belief_name\nThe name of the belief inside agent's adf\n@param connector\nThe connector to get the external access\n@return belief_value The value of the requested belief", "Set default values for the TimeAndSizeRollingAppender appender\n\n@param appender", "Writes assignment baseline data.\n\n@param xml MSPDI assignment\n@param mpxj MPXJ assignment", "If needed declares and sets up internal data structures.\n\n@param A Matrix being decomposed.", "Await service container stability ignoring thread interruption.\n\n@param timeout maximum period to wait for service container stability\n@param timeUnit unit in which {@code timeout} is expressed\n\n@throws java.util.concurrent.TimeoutException if service container stability is not reached before the specified timeout", "Computes the mean or average of all the elements.\n\n@return mean", "Find and return the appropriate getter method for field.\n\n@return Get method or null (or throws IllegalArgumentException) if none found." ]
private void getYearlyAbsoluteDates(Calendar calendar, List<Date> dates) { long startDate = calendar.getTimeInMillis(); calendar.set(Calendar.DAY_OF_MONTH, 1); calendar.set(Calendar.MONTH, NumberHelper.getInt(m_monthNumber) - 1); int requiredDayNumber = NumberHelper.getInt(m_dayNumber); while (moreDates(calendar, dates)) { int useDayNumber = requiredDayNumber; int maxDayNumber = calendar.getActualMaximum(Calendar.DAY_OF_MONTH); if (useDayNumber > maxDayNumber) { useDayNumber = maxDayNumber; } calendar.set(Calendar.DAY_OF_MONTH, useDayNumber); if (calendar.getTimeInMillis() < startDate) { calendar.add(Calendar.YEAR, 1); } dates.add(calendar.getTime()); calendar.set(Calendar.DAY_OF_MONTH, 1); calendar.add(Calendar.YEAR, 1); } }
[ "Calculate start dates for a yearly absolute recurrence.\n\n@param calendar current date\n@param dates array of start dates" ]
[ "Remove a variable in the top variables layer.", "Load the entity activating the persistence context execution boundaries\n\n@param session the session\n@param qp the query parameters\n@param ogmLoadingContext the loading context\n@param returnProxies when {@code true}, get an existing proxy for each collection element (if there is one)\n@return the result of the query", "Unlink the specified reference from this object.\nMore info see OJB doc.\n\n@param obj Object with reference\n@param ord the ObjectReferenceDescriptor of the reference\n@param insert flag signals insert operation", "Use this API to fetch appqoepolicy resource of given name .", "Set default values for the TimeAndSizeRollingAppender appender\n\n@param appender", "This method lists any notes attached to resources.\n\n@param file MPX file", "Before cluster management operations, i.e. remember and disable quota\nenforcement settings", "Add a new column\n\n@param columnName the name of the column\n@param searchable whether the column is searchable or not\n@param orderable whether the column is orderable or not\n@param searchValue if any, the search value to apply", "Load a test file, run the classifier on it, and then write a Viterbi search\ngraph for each sequence.\n\n@param testFile\nThe file to test on." ]
public static String format(final String code, final Properties options, final LineEnding lineEnding) { Check.notEmpty(code, "code"); Check.notEmpty(options, "options"); Check.notNull(lineEnding, "lineEnding"); final CodeFormatter formatter = ToolFactory.createCodeFormatter(options); final String lineSeparator = LineEnding.find(lineEnding, code); TextEdit te = null; try { te = formatter.format(CodeFormatter.K_COMPILATION_UNIT, code, 0, code.length(), 0, lineSeparator); } catch (final Exception formatFailed) { LOG.warn("Formatting failed", formatFailed); } String formattedCode = code; if (te == null) { LOG.info("Code cannot be formatted. Possible cause is unmatched source/target/compliance version."); } else { final IDocument doc = new Document(code); try { te.apply(doc); } catch (final Exception e) { LOG.warn(e.getLocalizedMessage(), e); } formattedCode = doc.get(); } return formattedCode; }
[ "Pretty prints the given source code.\n\n@param code\nsource code to format\n@param options\nformatter options\n@param lineEnding\ndesired line ending\n@return formatted source code" ]
[ "File URLs whose protocol are in these list will be processed as jars\ncontaining classes\n\n@param fileProtocols\nComma separated list of file protocols that will be considered\nas jar files and scanned", "Allocates a new next buffer and pending fetch.", "Creates a new instance of this class.\n\n@param variableName\nname of the instance variable to search aliases for. Must\nneither be {@code null} nor empty.\n@param controlFlowBlockToExamine\na {@link ControlFlowBlock} which possibly contains the setup\nof an alias for a lazy variable. This method thereby examines\npredecessors of {@code block}, too. This parameter must not be\n{@code null}.\n@return a new instance of this class.", "Merges individual days together into time spans where the\nsame work is undertaken each day.\n\n@param list assignment data", "Gets the visibility cache weight\n\n@param conf The FluoConfiguration\n@return The size of the cache value from the property value {@value #VISIBILITY_CACHE_WEIGHT}\nif it is set, else the value of the default value\n{@value #VISIBILITY_CACHE_WEIGHT_DEFAULT}", "Create a Count-Query for QueryByCriteria", "Returns the context the view is running in, through which it can\naccess the current theme, resources, etc.\n\n@return The view's Context.", "Run a task periodically and indefinitely.\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@return An interface that lets you query the status; cancel; or\nreschedule the event.", "This method allows a predecessor relationship to be added to this\ntask instance.\n\n@param targetTask the predecessor task\n@param type relation type\n@param lag relation lag\n@return relationship" ]
public static Thread newThread(String name, Runnable runnable, boolean daemon) { Thread thread = new Thread(runnable, name); thread.setDaemon(daemon); return thread; }
[ "Create a new thread\n\n@param name The name of the thread\n@param runnable The work for the thread to do\n@param daemon Should the thread block JVM shutdown?\n@return The unstarted thread" ]
[ "Visit an exported package of the current module.\n\n@param packaze the qualified name of the exported package.\n@param access the access flag of the exported package,\nvalid values are among {@code ACC_SYNTHETIC} and\n{@code ACC_MANDATED}.\n@param modules the qualified names of the modules that can access to\nthe public classes of the exported package or\n<tt>null</tt>.", "Check if the given class represents an array of primitive wrappers,\ni.e. Boolean, Byte, Character, Short, Integer, Long, Float, or Double.\n@param clazz the class to check\n@return whether the given class is a primitive wrapper array class", "Pseudo-Inverse of a matrix calculated in the least square sense.\n\n@param matrix The given matrix A.\n@return pseudoInverse The pseudo-inverse matrix P, such that A*P*A = A and P*A*P = P", "Obtain newline-delimited headers from response\n\n@param response HttpServletResponse to scan\n@return newline-delimited headers", "Read the project data and return a ProjectFile instance.\n\n@return ProjectFile instance", "Called to update the cached formats when something changes.", "Determines if the queue identified by the given key is a delayed queue.\n\n@param jedis\nconnection to Redis\n@param key\nthe key that identifies a queue\n@return true if the key identifies a delayed queue, false otherwise", "Return a list of unique namespace and predicate pairs, optionally limited by predicate or namespace, in alphabetical order.\n\nThis method does not require authentication.\n\n@param namespace\noptional, can be null\n@param predicate\noptional, can be null\n@param perPage\nThe number of photos to show per page\n@param page\nThe page offset\n@return NamespacesList containing Pair-objects\n@throws FlickrException", "Checks if the path leads to an embedded property or association.\n\n@param targetTypeName 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 an embedded, {@code false} otherwise." ]
@Override public void registerAttributes(ManagementResourceRegistration resourceRegistration) { for (AttributeAccess attr : attributes.values()) { resourceRegistration.registerReadOnlyAttribute(attr.getAttributeDefinition(), null); } }
[ "Register operations associated with this resource.\n\n@param resourceRegistration a {@link org.jboss.as.controller.registry.ManagementResourceRegistration} created from this definition" ]
[ "Gets the persistence broker used by this indirection handler.\nIf no PBKey is available a runtime exception will be thrown.\n\n@return a PersistenceBroker", "Establish connection to the ChromeCast device", "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.", "Converts a time in UTC to a gwt Date object which is in the timezone of\nthe current browser.\n\n@return The Date corresponding to the time, adjusted for the timezone of\nthe current browser. null if the specified time is null or\nrepresents a negative number.", "Defines how messages should be logged. This method can be modified to\nrestrict the logging messages that are shown on the console or to change\ntheir formatting. See the documentation of Log4J for details on how to do\nthis.", "Start the host controller services.\n\n@throws Exception", "Returns a vector from the PCA's basis.\n\n@param which Which component's vector is to be returned.\n@return Vector from the PCA basis.", "Obtain the profile name associated with a profile ID\n\n@param id ID of profile\n@return Name of corresponding profile", "Processes the most recent dump of the given type using the given dump\nprocessor.\n\n@see DumpProcessingController#processMostRecentMainDump()\n@see DumpProcessingController#processAllRecentRevisionDumps()\n\n@param dumpContentType\nthe type of dump to process\n@param dumpFileProcessor\nthe processor to use\n@deprecated Use {@link #getMostRecentDump(DumpContentType)} and\n{@link #processDump(MwDumpFile)} instead; method will vanish\nin WDTK 0.5" ]
private void updateScheduleSource(ProjectProperties properties) { // Rudimentary identification of schedule source if (properties.getCompany() != null && properties.getCompany().equals("Synchro Software Ltd")) { properties.setFileApplication("Synchro"); } else { if (properties.getAuthor() != null && properties.getAuthor().equals("SG Project")) { properties.setFileApplication("Simple Genius"); } else { properties.setFileApplication("Microsoft"); } } properties.setFileType("MSPDI"); }
[ "Populate the properties indicating the source of this schedule.\n\n@param properties project properties" ]
[ "Sets the protocol.\n@param protocol The protocol to be set.", "Validates the input parameters.", "Stop a managed server.", "This is a convenience method to add a default derived\ncalendar to the project.\n\n@return new ProjectCalendar instance", "Multiply scalar value to a complex number.\n\n@param z1 Complex Number.\n@param scalar Scalar value.\n@return Returns new ComplexNumber instance containing the multiply of specified complex number with the scalar value.", "Get http response", "Get a list of the members of a group. The call must be signed on behalf of a Flickr member, and the ability to see the group membership will be\ndetermined by the Flickr member's group privileges.\n\n@param groupId\nReturn a list of members for this group. The group must be viewable by the Flickr member on whose behalf the API call is made.\n@param memberTypes\nA set of Membertypes as available as constants in {@link Member}.\n@param perPage\nNumber of records per page.\n@param page\nResult-section.\n@return A members-list\n@throws FlickrException\n@see <a href=\"http://www.flickr.com/services/api/flickr.groups.members.getList.html\">API Documentation</a>", "This one picks up on Dan2 ideas, but seeks to make less distinctions\nmid sequence by sorting for long words, but to maintain extra\ndistinctions for short words, by always recording the class of the\nfirst and last two characters of the word.\nCompared to chris2 on which it is based,\nit uses more Unicode classes, and so collapses things like\npunctuation more, and might work better with real unicode.\n\n@param s The String to find the word shape of\n@param omitIfInBoundary If true, character classes present in the\nfirst or last two (i.e., BOUNDARY_SIZE) letters\nof the word are not also registered\nas classes that appear in the middle of the word.\n@param knownLCWords If non-null and non-empty, tag with a \"k\" suffix words\nthat are in this list when lowercased (representing\nthat the word is \"known\" as a lowercase word).\n@return A word shape for the word.", "Processes a row of the sites table and stores the site information found\ntherein.\n\n@param siteRow\nstring serialisation of a sites table row as found in the SQL\ndump" ]
@SuppressWarnings("unchecked") public Map<String, Field> getValueAsMap() { return (Map<String, Field>) type.convert(getValue(), Type.MAP); }
[ "Returns the Map value of the field.\n\n@return the Map value of the field. It returns a reference of the value both for <code>MAP</code> and\n<code>LIST_MAP</code>.\n@throws IllegalArgumentException if the value cannot be converted to Map." ]
[ "Creates a sorted list that contains the items of the given iterable. The resulting list is in ascending order,\naccording to the natural ordering of the elements in the iterable.\n\n@param iterable\nthe items to be sorted. May not be <code>null</code>.\n@return a sorted list as a shallow copy of the given iterable.\n@see Collections#sort(List)\n@see #sort(Iterable, Comparator)\n@see #sortBy(Iterable, org.eclipse.xtext.xbase.lib.Functions.Function1)\n@see ListExtensions#sortInplace(List)", "Use this API to fetch appfwlearningsettings resource of given name .", "Use this API to fetch all the appfwprofile resources that are configured on netscaler.", "Optimized version of the Wagner & Fischer algorithm that only\nkeeps a single column in the matrix in memory at a time. It\nimplements the simple cutoff, but otherwise computes the entire\nmatrix. It is roughly twice as fast as the original function.", "Adds the List of Lists of CRFDatums to the data and labels arrays, treating\neach datum as if it were its own document. Adds context labels in addition\nto the target label for each datum, meaning that for a particular document,\nthe number of labels will be windowSize-1 greater than the number of\ndatums.\n\n@param processedData\na List of Lists of CRFDatums", "Calls the specified Stitch function, and decodes the response into an instance of the specified\ntype. The response will be decoded using the codec registry given.\n\n@param name the name of the Stitch function to call.\n@param args the arguments to pass to the Stitch function.\n@param requestTimeout the number of milliseconds the client should wait for a response from the\nserver before failing with an error.\n@param resultClass the class that the Stitch response should be decoded as.\n@param <T> the type into which the Stitch response will be decoded.\n@param codecRegistry the codec registry that will be used to encode/decode the function call.\n@return the decoded value.", "Resolves the package type from the maven project.\n\n@param project the maven project\n\n@return the package type", "Adds a clause that checks whether ANY set bits in a bitmask are present\nin a numeric expression.\n\n@param expr\nSQL numeric expression to check.\n@param bits\nInteger containing the bits for which to check.", "Returns the list of atlas information necessary to map\nthe texture atlas to each scene object.\n\n@return List of atlas information." ]
public void setWeekDay(String weekDayStr) { final WeekDay weekDay = WeekDay.valueOf(weekDayStr); if ((m_model.getWeekDay() != null) || !m_model.getWeekDay().equals(weekDay)) { removeExceptionsOnChange(new Command() { public void execute() { m_model.setWeekDay(weekDay); onValueChange(); } }); } }
[ "Set the week day.\n@param weekDayStr the week day to set." ]
[ "Use this API to add clusterinstance.", "Set the Log4j appender.\n\n@param appender the log4j appender", "Adds format information to eval.", "Remove a misc file.\n\n@param name the file name\n@param path the relative path\n@param existingHash the existing hash\n@param isDirectory whether the file is a directory or not\n@return the builder", "Sends a message to the dbserver, first assembling it into a single byte buffer so that it can be sent as\na single packet.\n\n@param message the message to be sent\n\n@throws IOException if there is a problem sending it", "get bearer token returned by IAM in JSON format", "Creates a new Terms of Services.\n@param api the API connection to be used by the resource.\n@param termsOfServiceStatus the current status of the terms of services. Set to \"enabled\" or \"disabled\".\n@param termsOfServiceType the scope of terms of service. Set to \"external\" or \"managed\".\n@param text the text field of terms of service containing terms of service agreement info.\n@return information about the Terms of Service created.", "Adds the parent package to the java.protocol.handler.pkgs system property.", "Cosine interpolation.\n\n@param x1 X1 Value.\n@param x2 X2 Value.\n@param a Value.\n@return Value." ]
private JSONArray datesToJson(Collection<Date> individualDates) { if (null != individualDates) { JSONArray result = new JSONArray(); for (Date d : individualDates) { result.put(dateToJson(d)); } return result; } return null; }
[ "Converts a list of dates to a Json array with the long representation of the dates as strings.\n@param individualDates the list to convert.\n@return Json array with long values of dates as string" ]
[ "Throws an exception if the request can for security reasons not be performed.\nSecurity restrictions can be set via parameters of the index.\n\n@param cms the current context.\n@param query the query.\n@param isSpell flag, indicating if the spellcheck handler is requested.\n@throws CmsSearchException thrown if the query cannot be executed due to security reasons.", "Associate the specified value with the specified key in this map.\nIf the map previously contained a mapping for this key, the old\nvalue is replaced and returned.\n\n@param key the key with which the value is to be associated\n@param value the value to be associated with this key\n@return the value previously mapped to the key, or null", "Returns the primarykey fields.\n\n@return The field descriptors of the primarykey fields", "Use this API to fetch responderpolicy resource of given name .", "Returns the index of the median of the three indexed chars.", "Notify our own event listeners of a Z-Wave event.\n@param event the event to send.", "Reads a combined date and time value expressed in tenths of a minute.\n\n@param data byte array of data\n@param offset location of data as offset into the array\n@return time value", "Load and run the OnBrowserCreatedPlugins, this call has been made from the browser pool when a\nnew browser has been created and ready to be used by the Crawler. The PreCrawling plugins are\nexecuted before these plugins are executed except that the pre-crawling plugins are only\nexecuted on the first created browser.\n\n@param newBrowser the new created browser object", "sets the row reader class name for thie class descriptor" ]
private String getName(CommandContext ctx, boolean failInBatch) throws CommandLineException { final ParsedCommandLine args = ctx.getParsedCommandLine(); final String name = this.name.getValue(args, true); if (name == null) { throw new CommandFormatException(this.name + " is missing value."); } if (!ctx.isBatchMode() || failInBatch) { if (!Util.isValidPath(ctx.getModelControllerClient(), Util.DEPLOYMENT_OVERLAY, name)) { throw new CommandFormatException("Deployment overlay " + name + " does not exist."); } } return name; }
[ "Validate that the overlay exists. If it doesn't exist, throws an\nexception if not in batch mode or if failInBatch is true. In batch mode,\nwe could be in the case that the overlay doesn't exist yet." ]
[ "Check real offset.\n\n@return the boolean", "Returns an array of all declared fields in the given class and all\nsuper-classes.", "Executes the given supplier within the context of a read lock.\n\n@param <E> The result type.\n@param sup The supplier.\n@return The result of {@link Supplier#get()}.", "Search for photos which match the given search parameters.\n\n@param params\nThe search parameters\n@param perPage\nThe number of photos to show per page\n@param page\nThe page offset\n@return A PhotoList\n@throws FlickrException", "Returns the current download state for a download request.\n\n@param downloadId\n@return", "Reads OAuth 2.0 with JWT app configurations from the reader. The file should be in JSON format.\n\n@param reader a reader object which points to a JSON formatted configuration file\n@return a new Instance of BoxConfig\n@throws IOException when unable to access the mapping file's content of the reader", "Creates typed parser\n@param contentType class of parsed object\n@param <T> type of parsed object\n@return parser of objects of given type", "Finds out which dump files of the given type have been downloaded\nalready. The result is a list of objects that describe the available dump\nfiles, in descending order by their date. Not all of the dumps included\nmight be actually available.\n\n@param dumpContentType\nthe type of dump to consider\n@return list of objects that provide information on available dumps", "This method lists all tasks defined in the file.\n\n@param file MPX file" ]
public void setSourceUrl(String newUrl, int id) { PreparedStatement statement = null; try (Connection sqlConnection = sqlService.getConnection()) { statement = sqlConnection.prepareStatement( "UPDATE " + Constants.DB_TABLE_SERVERS + " SET " + Constants.SERVER_REDIRECT_SRC_URL + " = ?" + " WHERE " + Constants.GENERIC_ID + " = ?" ); statement.setString(1, newUrl); statement.setInt(2, id); statement.executeUpdate(); statement.close(); } catch (Exception e) { e.printStackTrace(); } finally { try { if (statement != null) { statement.close(); } } catch (Exception e) { } } }
[ "Set source url for a server\n\n@param newUrl new URL\n@param id Server ID" ]
[ "Open the event stream\n\n@return true if successfully opened, false if not", "Is portlet env supported.\n\n@return true if portlet env is supported, false otherwise", "Places a connection back in the originating partition.\n@param connectionHandle to place back\n@throws SQLException on error", "Declares a fresh Builder to copy default property values from.\n\n<p>Reuses an existing fresh Builder instance if one was already declared in this scope.\n\n@returns a variable holding a fresh Builder, if a no-args factory method is available to\ncreate one with", "Initialize elements of the panel displayed for the deactivated widget.", "Deletes the metadata on this folder associated with a specified scope and template.\n\n@param templateName the metadata template type name.\n@param scope the scope of the template (usually \"global\" or \"enterprise\").", "Apply clipping to the features in a tile. The tile and its features should already be in map space.\n\n@param tile\ntile to put features in\n@param scale\nscale\n@param panOrigin\nWhen panning on the client, only this parameter changes. So we need to be aware of it as we calculate\nthe maxScreenEnvelope.\n@throws GeomajasException oops", "Returns the position of the specified value in the specified array.\n\n@param value the value to search for\n@param array the array to search in\n@return the position of the specified value in the specified array", "Assembles an avro format string of single store config from store\nproperties\n\n@param props Store properties\n@return String in avro format that contains single store configs" ]
public static Type[] getActualTypeArguments(Type type) { Type resolvedType = Types.getCanonicalType(type); if (resolvedType instanceof ParameterizedType) { return ((ParameterizedType) resolvedType).getActualTypeArguments(); } else { return EMPTY_TYPES; } }
[ "Gets the actual type arguments of a Type\n\n@param type The type to examine\n@return The type arguments" ]
[ "Answer true if an Iterator for a Table is already available\n@param aTable\n@return", "Configure high fps settings in the camera for VR mode\n\n@param fpsMode integer indicating the desired fps: 0 means 30 fps, 1 means 60\nfps, and 2 means 120 fps. Any other value is invalid.\n@return A boolean indicating the status of the method call. It may be false due\nto multiple reasons including: 1) supplying invalid fpsMode as the input\nparameter, 2) VR mode not supported.", "This may cost twice what it would in the original Map because we have to find\nthe original value for this key.\n\n@param key key with which the specified value is to be associated.\n@param value value to be associated with the specified key.\n@return previous value associated with specified key, or <tt>null</tt>\nif there was no mapping for key. A <tt>null</tt> return can\nalso indicate that the map previously associated <tt>null</tt>\nwith the specified key, if the implementation supports\n<tt>null</tt> values.", "Add an additional SSExtension\n@param ssExt the ssextension to set", "If the deployment has a module attached it will ask the module to load the ServiceActivator services.\n\n@param phaseContext the deployment unit context", "Gets a first data set value.\n\n@param dataSet\nIIM record and dataset code (See constants in {@link IIM})\n@return data set value\n@throws SerializationException\nif value can't be deserialized from binary representation", "This returns all profiles associated with a server name\n\n@param serverName server Name\n@return profile UUID\n@throws Exception exception", "Creates a Bytes object by copying the value of the given String", "adds all json extension to an diagram\n@param modelJSON\n@param current\n@throws org.json.JSONException" ]
public static Artifact getIdlArtifact(Artifact artifact, ArtifactFactory artifactFactory, ArtifactResolver artifactResolver, ArtifactRepository localRepository, List<ArtifactRepository> remoteRepos, String classifier) throws MojoExecutionException { Artifact idlArtifact = artifactFactory.createArtifactWithClassifier( artifact.getGroupId(), artifact.getArtifactId(), artifact.getVersion(), "jar", classifier); try { artifactResolver.resolve(idlArtifact, remoteRepos, localRepository); return idlArtifact; } catch (final ArtifactResolutionException e) { throw new MojoExecutionException( "Failed to resolve one or more idl artifacts:\n\n" + e.getMessage(), e); } catch (final ArtifactNotFoundException e) { throw new MojoExecutionException( "Failed to resolve one or more idl artifacts:\n\n" + e.getMessage(), e); } }
[ "Resolves an idl jar for the artifact.\n@return Returns idl artifact\n@throws MojoExecutionException is idl jar is not present for the artifact." ]
[ "Get http response", "Splits up value into multiple versioned values\n\n@param value\n@return\n@throws IOException", "Attempts to detect the provided pattern as an exact match.\n@param pattern the pattern to find in the reader stream\n@return the number of times the pattern is found,\nor an error code\n@throws MalformedPatternException if the pattern is invalid\n@throws Exception if a generic error is encountered", "If converters are set on a table, this function tests if these can convert a cell value. The first\nconverter, which claims that it can convert, will be used to do the conversion.", "Check, if all values used for calculating the series for a specific pattern are valid.\n@return <code>null</code> if the pattern is valid, a suitable error message otherwise.", "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.", "Get the account knowing his title\n@param title the title of the account (it can change at runtime!)\n@return the account founded or null if the account not exists", "Close all HTTP clients created by this factory\n@throws IOException if an I/O error occurs", "mark a node as blacklisted\n\n@param nodeId Integer node id of the node to be blacklisted" ]
public int getLinkId(@NotNull final PersistentStoreTransaction txn, @NotNull final String linkName, final boolean allowCreate) { return allowCreate ? linkIds.getOrAllocateId(txn, linkName) : linkIds.getId(txn, linkName); }
[ "Gets id of a link and creates the new one if necessary.\n\n@param linkName name of the link.\n@param allowCreate if set to true and if there is no link named as linkName,\ncreate the new id for the linkName.\n@return < 0 if there is no such link and create=false, else id of the link" ]
[ "Returns the version of Jenkins Artifactory Plugin or empty string if not found\n\n@return the version of Jenkins Artifactory Plugin or empty string if not found", "Checks if the path leads to an embedded property or association.\n\n@param targetTypeName 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 an embedded, {@code false} otherwise.", "Visits a method instruction. A method instruction is an instruction that\ninvokes a method.\n\n@param opcode\nthe opcode of the type instruction to be visited. This opcode\nis either INVOKEVIRTUAL, INVOKESPECIAL, INVOKESTATIC or\nINVOKEINTERFACE.\n@param owner\nthe internal name of the method's owner class (see\n{@link Type#getInternalName() getInternalName}).\n@param name\nthe method's name.\n@param desc\nthe method's descriptor (see {@link Type Type}).\n@param itf\nif the method's owner class is an interface.", "The nullity of the decomposed matrix.\n\n@see SingularOps_DDRM#nullity(SingularValueDecomposition_F64, double)\n\n@return The matrix's nullity", "Read all top level tasks.", "Internal used method which start the real store work.", "Clears the dest ColumnBuffer and inserts all entries in dest where the timestamp passes the\ntimestampTest.\n\n@param dest Destination ColumnBuffer\n@param timestampTest Test to determine which timestamps get added to dest", "Mark new or deleted reference elements\n@param broker", "Adds OPT_D | OPT_DIR 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" ]
public void addComparator(Comparator<T> comparator, boolean ascending) { this.comparators.add(new InvertibleComparator<T>(comparator, ascending)); }
[ "Add a Comparator to the end of the chain using the provided sort order.\n@param comparator the Comparator to add to the end of the chain\n@param ascending the sort order: ascending (true) or descending (false)" ]
[ "Convert a given date to a floating point date using a given reference date.\n\n@param referenceDate The reference date associated with \\( t=0 \\).\n@param date The given date to be associated with the return value \\( T \\).\n@return The value T measuring the distance of reference date and date by ACT/365 with SECONDS_PER_DAY seconds used as the smallest time unit and SECONDS_PER_DAY is a constant 365*24*60*60.", "Read flow id from message.\n\n@param message the message\n@return the FlowId as string", "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.", "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)", "Logs binary string as hexadecimal", "Logs all properties", "Given a file name and read-only storage format, tells whether the file\nname format is correct\n\n@param fileName The name of the file\n@param format The RO format\n@return true if file format is correct, else false", "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.", "Uncompresses the given textual content and writes it to the given file.\n\n@param file The file to write to\n@param compressedContent The content\n@throws IOException If an error occurred" ]
private int getItemViewType(Class prototypeClass) { int itemViewType = -1; for (Renderer renderer : prototypes) { if (renderer.getClass().equals(prototypeClass)) { itemViewType = getPrototypeIndex(renderer); break; } } if (itemViewType == -1) { throw new PrototypeNotFoundException( "Review your RendererBuilder implementation, you are returning one" + " prototype class not found in prototypes collection"); } return itemViewType; }
[ "Return the Renderer class associated to the prototype.\n\n@param prototypeClass used to search the renderer in the prototypes collection.\n@return the prototype index associated to the prototypeClass." ]
[ "Gets the JVM memory usage.\n\n@return the JVM memory usage", "Reverse Engineers an XPath Expression of a given Node in the DOM.\n\n@param node the given node.\n@return string xpath expression (e.g., \"/html[1]/body[1]/div[3]\").", "Determines whether or not two axially aligned bounding boxes in\nthe same coordinate space intersect.\n@param bv1 first bounding volume to test.\n@param bv2 second bounding volume to test.\n@return true if the boxes intersect, false if not.", "Adds the headers.\n\n@param builder\nthe builder\n@param headerMap\nthe header map", "Returns a List of all of the values in the Map whose key matches an entry in the nameMapping array.\n\n@param map\nthe map\n@param nameMapping\nthe keys of the Map values to add to the List\n@return a List of all of the values in the Map whose key matches an entry in the nameMapping array\n@throws NullPointerException\nif map or nameMapping is null", "Use this API to fetch all the systemcollectionparam resources that are configured on netscaler.", "Returns a new color that has the hue adjusted by the specified\namount.", "returns an Array with an Identities PK VALUES\n@throws PersistenceBrokerException if there is an erros accessing o field values", "request token from GCM" ]
public static BufferedImage resizeToHeight(BufferedImage originalImage, int heightOut) { int width = originalImage.getWidth(); int height = originalImage.getHeight(); int heightPercent = (heightOut * 100) / height; int newWidth = (width * heightPercent) / 100; BufferedImage resizedImage = new BufferedImage(newWidth, heightOut, BufferedImage.TYPE_INT_ARGB); Graphics2D g = resizedImage.createGraphics(); g.drawImage(originalImage, 0, 0, newWidth, heightOut, null); g.dispose(); return resizedImage; }
[ "Resizes an image to the specified height, changing width in the same proportion\n@param originalImage Image in memory\n@param heightOut The height to resize\n@return New Image in memory" ]
[ "This one picks up on Dan2 ideas, but seeks to make less distinctions\nmid sequence by sorting for long words, but to maintain extra\ndistinctions for short words, by always recording the class of the\nfirst and last two characters of the word.\nCompared to chris2 on which it is based,\nit uses more Unicode classes, and so collapses things like\npunctuation more, and might work better with real unicode.\n\n@param s The String to find the word shape of\n@param omitIfInBoundary If true, character classes present in the\nfirst or last two (i.e., BOUNDARY_SIZE) letters\nof the word are not also registered\nas classes that appear in the middle of the word.\n@param knownLCWords If non-null and non-empty, tag with a \"k\" suffix words\nthat are in this list when lowercased (representing\nthat the word is \"known\" as a lowercase word).\n@return A word shape for the word.", "Tries to load a class using the specified ResourceLoader. Returns null if the class is not found.\n@param className\n@param resourceLoader\n@return the loaded class or null if the given class cannot be loaded", "For each node in specified zones, tries swapping some minimum number of\nrandom partitions per node with some minimum number of random partitions\nfrom other specified nodes. Chooses the best swap in each iteration.\nLarge values of the greedSwapMaxPartitions... arguments make this method\nequivalent to comparing every possible swap. This may get very expensive.\n\nSo if a node had partitions P1, P2, P3 and P4 and the other partitions\nset was Q1, Q2, Q3, Q4, Q5 The combinations that will be tried for\nswapping will be the cartesian product of the two sets. That is, {P1,\nQ1}, {P2, Q2}...{P2,Q1}, {P2,Q2}, in total 20 such swap pairs will be\ngenerated. The best among these swap pairs will be chosen.\n\n@param nextCandidateCluster\n@param nodeIds Node IDs within which to shuffle partitions\n@param greedySwapMaxPartitionsPerNode See RebalanceCLI.\n@param greedySwapMaxPartitionsPerZone See RebalanceCLI.\n@param storeDefs\n@return updated cluster", "Adds multiple observers using unique integer prefixes for each.\n\n@deprecated since 1.1.0. Replaced by {@link #setObserverProvider(String)} and\n{@link #getObserverProvider()}", "read a producer request from buffer\n\n@param buffer data buffer\n@return parsed producer request", "Check if the right-hand side type may be assigned to the left-hand side\ntype following the Java generics rules.\n@param lhsType the target type\n@param rhsType the value type that should be assigned to the target type\n@return true if rhs is assignable to lhs", "Sets no of currency digits.\n\n@param currDigs Available values, 0,1,2", "Returns whether the given host matches this one. For hosts to match, they must represent the same addresses or have the same host names.\nHosts are not resolved when matching. Also, hosts must have the same port and service. They must have the same masks if they are host names.\nEven if two hosts are invalid, they match if they have the same invalid string.\n\n@param host\n@return", "Arrange to become the tempo master. Starts a sequence of interactions with the other players that should end\nup with us in charge of the group tempo and beat alignment.\n\n@throws IllegalStateException if we are not sending status updates\n@throws IOException if there is a problem sending the master yield request" ]
public <T extends Widget & Checkable> List<Integer> getCheckedWidgetIndexes() { List<Integer> checked = new ArrayList<>(); List<Widget> children = getChildren(); final int size = children.size(); for (int i = 0, j = -1; i < size; ++i) { Widget c = children.get(i); if (c instanceof Checkable) { ++j; if (((Checkable) c).isChecked()) { checked.add(j); } } } return checked; }
[ "Gets all checked widget indexes in the group. The indexes are counted from 0 to size -1,\nwhere size is the number of Checkable widgets in the group. It does not take into account\nany non-Checkable widgets added to the group widget.\n\n@return list of checked widget indexes" ]
[ "Return the BundleCapability of a bundle exporting the package packageName.\n\n@param context The BundleContext\n@param packageName The package name\n@return the BundleCapability of a bundle exporting the package packageName", "this remove the linebreak.\n\n@param input\nthe input\n@param patternStr\nthe pattern str\n@return the string", "Finds the parent address, everything before the last address part.\n\n@param address the address to get the parent\n\n@return the parent address\n\n@throws IllegalArgumentException if the address is not of type {@link ModelType#LIST} or is empty", "To be called at node startup - it purges all job instances associated to this node.\n\n@param cnx\n@param node", "Run a task periodically, with a callback.\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 callback\nCallback that lets you cancel the task. {@code null} means run\nindefinitely.\n@return An interface that lets you query the status; cancel; or\nreschedule the event.", "Report all Java ClassFile files available on the class path within\nthe specified packages and sub packages.\n\n@see #detect(File...)", "Set the value for a custom request\n\n@param pathId ID of path\n@param customRequest value of custom request\n@param clientUUID UUID of client", "Check if this is a redeployment triggered after the removal of a link.\n@param operation the current operation.\n@return true if this is a redeploy after the removal of a link.\n@see org.jboss.as.server.deploymentoverlay.DeploymentOverlayDeploymentRemoveHandler", "Returns the query string currently in the text field.\n\n@return the query string" ]
public ItemRequest<Tag> findById(String tag) { String path = String.format("/tags/%s", tag); return new ItemRequest<Tag>(this, Tag.class, path, "GET"); }
[ "Returns the complete tag record for a single tag.\n\n@param tag The tag to get.\n@return Request object" ]
[ "Use this API to flush cachecontentgroup resources.", "Resolve all files from a given path and simplify its definition.", "Use this API to fetch sslcertkey_crldistribution_binding resources of given name .", "Updates value of entity in the table.", "Updates the date and time formats.\n\n@param properties project properties", "Private recursive helper function to actually do the type-safe checking\nof assignability.", "Alternate version of autoGeneratedKeys.\n@param sql\n@param autoGeneratedKeys\n@return cache key to use.", "To use main report datasource. There should be nothing else in the detail band\n@param preSorted\n@return", "Classify stdin by senteces seperated by blank line\n@param readerWriter\n@return\n@throws IOException" ]
public void setLeftTableModel(TableModel model) { TableModel old = m_leftTable.getModel(); m_leftTable.setModel(model); firePropertyChange("leftTableModel", old, model); }
[ "Set the model used by the left table.\n\n@param model table model" ]
[ "Add assignments to the tree.\n\n@param parentNode parent tree node\n@param file assignments container", "Load a properties file from a file path\n\n@param gradlePropertiesFilePath The file path where the gradle.properties is located.\n@return The loaded properties.\n@throws IOException In case an error occurs while reading the properties file, this exception is thrown.", "Sets the SCXML model with an InputStream\n\n@param inputFileStream the model input stream", "Set the view frustum to pick against from the field of view, aspect\nratio and near, far clip planes. The viewpoint of the frustum\nis the center of the scene object the picker is attached to.\nThe view direction is the forward direction of that scene object.\nThe frustum will pick what a camera attached to the scene object\nwith that view frustum would see. If the frustum is not attached\nto a scene object, it defaults to the view frustum of the main camera of the scene.\n\n@param fovy vertical field of view in degrees\n@param aspect aspect ratio (width / height)", "This method returns the mapped certificate for a hostname, or generates a \"standard\"\nSSL server certificate issued by the CA to the supplied subject if no mapping has been\ncreated. This is not a true duplication, just a shortcut method\nthat is adequate for web browsers.\n\n@param hostname\n@return\n@throws CertificateParsingException\n@throws InvalidKeyException\n@throws CertificateExpiredException\n@throws CertificateNotYetValidException\n@throws SignatureException\n@throws CertificateException\n@throws NoSuchAlgorithmException\n@throws NoSuchProviderException\n@throws KeyStoreException\n@throws UnrecoverableKeyException", "Get the photo or ticket id from the response.\n\n@param async\n@param response\n@return", "Makes it possible to uniquify a collection of objects which are normally\nnon-hashable. Alternatively, it lets you define an alternate hash function\nfor them for limited-use hashing.", "Iterates through this file line by line, splitting each line using\nthe given regex separator. For each line, the given closure is called with\na single parameter being the list of strings computed by splitting the line\naround matches of the given regular expression.\nFinally the resources used for processing the file are closed.\n\n@param self a File\n@param regex the delimiting regular expression\n@param closure a closure\n@return the last value returned by the closure\n@throws IOException if an IOException occurs.\n@throws java.util.regex.PatternSyntaxException\nif the regular expression's syntax is invalid\n@see IOGroovyMethods#splitEachLine(java.io.Reader, java.lang.String, groovy.lang.Closure)\n@since 1.5.5", "This method is called to alert project listeners to the fact that\na resource assignment has been written to a project file.\n\n@param resourceAssignment resourceAssignment instance" ]
private ProjectCalendarDateRanges getRanges(Date date, Calendar cal, Day day) { ProjectCalendarDateRanges ranges = getException(date); if (ranges == null) { ProjectCalendarWeek week = getWorkWeek(date); if (week == null) { week = this; } if (day == null) { if (cal == null) { cal = Calendar.getInstance(); cal.setTime(date); } day = Day.getInstance(cal.get(Calendar.DAY_OF_WEEK)); } ranges = week.getHours(day); } return ranges; }
[ "Retrieves the working hours on the given date.\n\n@param date required date\n@param cal optional calendar instance\n@param day optional day instance\n@return working hours" ]
[ "Find the latest task finish date. We treat this as the\nfinish date for the project.\n\n@return finish date", "Upload a photo from a byte-array.\n\n@param data\nThe photo data as a byte array\n@param metaData\nThe meta data\n@return photoId or ticketId\n@throws FlickrException", "Updates an existing enum option. Enum custom fields require at least one enabled enum option.\n\nReturns the full record of the updated enum option.\n\n@param enumOption Globally unique identifier for the enum option.\n@return Request object", "Inserts the specified array into the specified original array at the specified index.\n\n@param original the original array into which we want to insert another array\n@param index the index at which we want to insert the array\n@param inserted the array that we want to insert\n@return the combined array", "Write the patch.xml\n\n@param rollbackPatch the patch\n@param file the target file\n@throws IOException", "This method writes data for a single calendar to a Planner file.\n\n@param mpxjCalendar MPXJ calendar instance\n@param plannerCalendar Planner calendar instance\n@throws JAXBException on xml creation errors", "Use this API to fetch all the appfwprofile resources that are configured on netscaler.", "Use this API to update nspbr6 resources.", "Use this API to fetch statistics of scpolicy_stats resource of given name ." ]
public void setAttribute(final String name, final Attribute attribute) { if (name.equals("datasource")) { this.allAttributes.putAll(((DataSourceAttribute) attribute).getAttributes()); } else if (this.copyAttributes.contains(name)) { this.allAttributes.put(name, attribute); } }
[ "All the sub-level attributes.\n\n@param name the attribute name.\n@param attribute the attribute." ]
[ "Add working days and working time to a calendar.\n\n@param mpxjCalendar MPXJ calendar\n@param gpCalendar GanttProject calendar", "Handle content length.\n\n@param event\nthe event", "Calls all initializers of the bean\n\n@param instance The bean instance", "Emit an enum event with parameters and force all listener to be called synchronously.\n\n@param event\nthe target event\n@param args\nthe arguments passed in\n@see #emit(Enum, Object...)", "Initialize new instance\n@param instance\n@param logger\n@param auditor", "Retrieve the default aliases to be applied to MPXJ task and resource fields.\n\n@return map of aliases", "Use this API to update gslbsite resources.", "Returns the value stored for the given key at the point of call.\n@param key a non null key\n@return the value stored in the map for the given key", "Compute the CRC32 of the segment of the byte array given by the\nspecificed size and offset\n\n@param bytes The bytes to checksum\n@param offset the offset at which to begin checksumming\n@param size the number of bytes to checksum\n@return The CRC32" ]
public void useNewRESTService(String address) throws Exception { List<Object> providers = createJAXRSProviders(); org.customer.service.CustomerService customerService = JAXRSClientFactory .createFromModel(address, org.customer.service.CustomerService.class, "classpath:/model/CustomerService-jaxrs.xml", providers, null); System.out.println("Using new RESTful CustomerService with new client"); customer.v2.Customer customer = createNewCustomer("Smith New REST"); customerService.updateCustomer(customer); customer = customerService.getCustomerByName("Smith New REST"); printNewCustomerDetails(customer); }
[ "New REST client uses new REST service" ]
[ "Returns the latest change events for a given namespace.\n\n@param namespace the namespace to get events for.\n@return the latest change events for a given namespace.", "Injects bound fields\n\n@param instance The instance to inject into", "Increases the maximum number of columns in the matrix.\n@param desiredColumns Desired number of columns.\n@param preserveValue If the array needs to be expanded should it copy the previous values?", "Retrieves the constructor that is used by OJB to create instances of the given collection proxy\nclass.\n\n@param proxyClass The proxy class\n@param baseType The required base type of the proxy class\n@param typeDesc The type of collection proxy\n@return The constructor", "Returns the text for the JSONObject of Link provided\nThe JSONObject of Link provided should be of the type \"copy\"\n@param jsonObject of Link\n@return String", "If a policy already exists on a folder, this will apply that policy to all existing files and sub folders within\nthe target folder.\n\n@param conflictResolution the desired behavior for conflict-resolution. Set to either none or overwrite.", "Returns the undo collection representing the given namespace for recording documents that\nmay need to be reverted after a system failure.\n\n@param namespace the namespace referring to the undo collection.\n@return the undo collection representing the given namespace for recording documents that\nmay need to be reverted after a system failure.", "Update max.\n\n@param n the n\n@param c the c", "Method handle a change on the cluster members set\n@param event" ]
public static int daysDiff(Date earlierDate, Date laterDate) { if (earlierDate == null || laterDate == null) { return 0; } return (int) ((laterDate.getTime() / DAY_MILLIS) - (earlierDate.getTime() / DAY_MILLIS)); }
[ "Get the days difference" ]
[ "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", "Creates a field map for relations.\n\n@param props props data", "Parses a record containing hours and add them to a container.\n\n@param ranges hours container\n@param hoursRecord hours record", "Removes all items from the list box.", "Close off the connection.\n\n@throws SQLException", "Writes the data collected about properties to a file.", "Set a status message in the JTextComponent passed to this\nmodel.\n@param message The message that should be displayed.", "Log column data.\n\n@param column column data", "Only meant to be called once\n\n@throws Exception exception" ]
public StandaloneCommandBuilder setDebug(final boolean suspend, final int port) { debugArg = String.format(DEBUG_FORMAT, (suspend ? "y" : "n"), port); return this; }
[ "Sets the debug JPDA remote socket debugging argument.\n\n@param suspend {@code true} to suspend otherwise {@code false}\n@param port the port to listen on\n\n@return the builder" ]
[ "Reads the availability table from the file.\n\n@param resource MPXJ resource instance\n@param periods MSPDI availability periods", "As part of checking whether a metadata cache can be auto-mounted for a particular media slot, this method\nlooks up the track at the specified offset within the player's track list, and returns its rekordbox ID.\n\n@param slot the slot being considered for auto-attaching a metadata cache\n@param client the connection to the database server on the player holding that slot\n@param offset an index into the list of all tracks present in the slot\n\n@throws IOException if there is a problem communicating with the player", "Converts a TimeUnit instance to an integer value suitable for\nwriting to an MPX file.\n\n@param recurrence RecurringTask instance\n@return integer value", "Returns if this has any mapping for the specified cell.\n\n@param cell the cell name\n@return {@code true} if there is any mapping for the cell, {@code false} otherwise", "Determines the feature state\n\n@param context the template context\n@param tag the tag\n@param attributeName the attribute name\n@param attributeValue the attribute value\n@param defaultState the default state if the expression evaluates to null\n@return the feature state", "Determines the offset code of a forward contract from the name of a forward curve.\nThis method will extract a group of one or more digits together with the first letter behind them, if any.\nIf there are multiple groups of digits in the name, this method will extract the last.\nIf there is no number in the string, this method will return null.\n\n@param curveName The name of the curve.\n@return The offset code as String", "Returns first resolver that accepts the given resolverId.\nIn case none is found null is returned.\n@param resolverId identifier of the resolver\n@return found resolver or null otherwise", "Iterates over all tags of current member and evaluates the template for each one.\n\n@param template The template to be evaluated\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\" optional=\"true\" description=\"The parameter name.\"", "Get an Iterator based on the ReportQuery\n\n@param query\n@return Iterator" ]
public static void enableHost(String hostName) throws Exception { Registry myRegistry = LocateRegistry.getRegistry("127.0.0.1", port); com.groupon.odo.proxylib.hostsedit.rmi.Message impl = (com.groupon.odo.proxylib.hostsedit.rmi.Message) myRegistry.lookup(SERVICE_NAME); impl.enableHost(hostName); }
[ "Enable a host\n\n@param hostName\n@throws Exception" ]
[ "submit the adminClient after usage is completed.\nBehavior is undefined, if checkin is called with objects not retrieved\nfrom checkout.\n\n@param client AdminClient retrieved from checkout", "Returns the y-coordinate of a vertex normal.\n\n@param vertex the vertex index\n@return the y coordinate", "Process UDFs for a specific object.\n\n@param mpxj field container\n@param udfs UDF values", "Convert MPX day index to Day instance.\n\n@param day day index\n@return Day instance", "A property tied to the map, updated when the idle state event is fired.\n\n@return", "Use this API to update tmtrafficaction.", "Creates an object from the given JSON data.\n\n@param data the JSON data\n@param clazz the class object for the content of the JSON data\n@param <T> the type of the class object extending {@link InterconnectObject}\n@return the object contained in the given JSON data\n@throws JsonParseException if a the JSON data could not be parsed\n@throws JsonMappingException if the mapping of the JSON data to the IVO failed\n@throws IOException if an I/O related problem occurred", "Specifies the maximum capacity of the counter.\n\n@param capacity\n<code>long</code>\n@throws IllegalArgumentException\nif windowMillis is less than 1.", "Starts asynchronous check. Result will be delivered to the listener on the main thread.\n\n@param context\n@param appId application id from the oculus dashboard\n@param listener listener to invoke when the result is available\n@throws IllegalStateException in case the platform sdk cannot be initialized\n@throws IllegalArgumentException if listener is null" ]
public static double[] toDouble(int[] array) { double[] n = new double[array.length]; for (int i = 0; i < array.length; i++) { n[i] = (double) array[i]; } return n; }
[ "1-D Integer array to double array.\n\n@param array Integer array.\n@return Double array." ]
[ "Handles incoming Send Data Request. Send Data request are used\nto acknowledge or cancel failed messages.\n@param incomingMessage the request message to process.", "adds a TTL index to the given collection. The TTL must be a positive integer.\n\n@param collection the collection to use for the TTL index\n@param field the field to use for the TTL index\n@param ttl the TTL to set on the given field\n@throws IllegalArgumentException if the TTL is less or equal 0", "Add a source and destination.\n\n@param source Source path to be routed. Routed path can have named wild-card pattern with braces \"{}\".\n@param destination Destination of the path.", "Post boolean flag \"DO_NOT_USE\" to an artifact\n\n@param gavc\n@param doNotUse\n@param user\n@param password\n@throws GrapesCommunicationException", "Converts the given string to a clob object\n\n@param stringName string name to clob\n@param sqlConnection Connection object\n@return Clob object or NULL", "Writes references that have been added recently. Auxiliary triples that\nare generated for serializing snaks in references will be written right\nafterwards. This will also trigger any other auxiliary triples to be\nwritten that the snak converter object may have buffered.\n\n@throws RDFHandlerException\nif there was a problem writing the restrictions", "Obtain collection of Parameters from request\n\n@param dataArray request parameters\n@return Map of parameters\n@throws Exception exception", "Use this API to add dnstxtrec resources.", "Use this API to fetch sslpolicy_lbvserver_binding resources of given name ." ]
private static String getColumnTitle(final PropertyDescriptor _property) { final StringBuilder buffer = new StringBuilder(); final String name = _property.getName(); buffer.append(Character.toUpperCase(name.charAt(0))); for (int i = 1; i < name.length(); i++) { final char c = name.charAt(i); if (Character.isUpperCase(c)) { buffer.append(' '); } buffer.append(c); } return buffer.toString(); }
[ "Calculates a column title using camel humps to separate words.\n@param _property the property descriptor.\n@return the column title for the given property." ]
[ "Initializes the editor states for the different modes, depending on the type of the opened file.", "Get the next available ordinal for a method ID\n\n@param methodId ID of method\n@return value of next ordinal\n@throws Exception exception", "Given a rebalance-task info, convert it into the protobuf equivalent\n\n@param stealInfo Rebalance task info\n@return Protobuf equivalent of the same", "Adds this handler to the widget.\n\n@param <H> the type of handler to add\n@param type the event type\n@param handler the handler\n@return {@link HandlerRegistration} used to remove the handler", "Creates the container for a bundle descriptor.\n@return the container for a bundle descriptor.", "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.", "Removes from this set all of its elements that are contained in the specified members array\n@param members the members to remove\n@return the number of members actually removed", "Sets all padding to the same value.\n@param padding new padding for top, bottom, left, and right, ignored if smaller than 0\n@return this to allow chaining", "Add a misc file.\n\n@param name the file name\n@param path the relative path\n@param newHash the new hash of the added content\n@param isDirectory whether the file is a directory or not\n@return the builder" ]
public static base_response unset(nitro_service client, nstimeout resource, String[] args) throws Exception{ nstimeout unsetresource = new nstimeout(); return unsetresource.unset_resource(client,args); }
[ "Use this API to unset the properties of nstimeout resource.\nProperties that need to be unset are specified in args array." ]
[ "Given a rebalance-task info, convert it into the protobuf equivalent\n\n@param stealInfo Rebalance task info\n@return Protobuf equivalent of the same", "Gets the invalid message.\n\n@param key the key\n@return the invalid message", "Generates a toString method using concatenation or a StringBuilder.", "Bhattacharyya distance between two normalized histograms.\n\n@param histogram1 Normalized histogram.\n@param histogram2 Normalized histogram.\n@return The Bhattacharyya distance between the two histograms.", "Utility function to find the first index of a value in a\nListBox.", "Shortcut for mapping an arbitrary observable to void, using the IO scheduler.\n@param fromObservable the source observable\n@return a void-emitting observable", "Use this API to delete locationfile.", "Returns the last node that appears to be part of the prefix. This will be used to determine the current model\nobject that'll be the most special context instance in the proposal provider.", "Create and add model controller handler to an existing management channel handler.\n\n@param handler the channel handler\n@return the created client" ]
public static base_response add(nitro_service client, dbdbprofile resource) throws Exception { dbdbprofile addresource = new dbdbprofile(); addresource.name = resource.name; addresource.interpretquery = resource.interpretquery; addresource.stickiness = resource.stickiness; addresource.kcdaccount = resource.kcdaccount; addresource.conmultiplex = resource.conmultiplex; return addresource.add_resource(client); }
[ "Use this API to add dbdbprofile." ]
[ "Unmarshals the XML content and adds the file to the bundle files.\n@throws CmsException thrown if reading the file or unmarshaling fails.", "Replies the elements of the given map except the pairs with the given keys.\n\n<p>\nThe replied map is a view on the given map. It means that any change\nin the original map is reflected to the result of this operation.\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 keys the keys of the pairs to remove.\n@return the map with the content of the map except the pairs.\n@since 2.15", "Retrieve and validate the timeout value from the REST request.\n\"X_VOLD_REQUEST_TIMEOUT_MS\" is the timeout header.\n\n@return true if present, false if missing", "Performs the actual spell check query using Solr.\n\n@param request the spell check request\n\n@return Results of the Solr spell check of type SpellCheckResponse or null if something goes wrong.", "Use this API to update rnatparam.", "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.", "Get the pickers date.", "Assign FK value to all n-side objects referenced by given object.\n\n@param obj real object with 1:n reference\n@param cod {@link CollectionDescriptor} of referenced 1:n objects\n@param insert flag signal insert operation, false signals update operation", "Checks all data sets in a given record for constraint violations.\n\n@param record\nIIM record (1,2,3, ...) to check\n\n@return list of constraint violations, empty set if IIM file is valid" ]
public static base_responses update(nitro_service client, nsacl6 resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { nsacl6 updateresources[] = new nsacl6[resources.length]; for (int i=0;i<resources.length;i++){ updateresources[i] = new nsacl6(); updateresources[i].acl6name = resources[i].acl6name; updateresources[i].aclaction = resources[i].aclaction; updateresources[i].srcipv6 = resources[i].srcipv6; updateresources[i].srcipop = resources[i].srcipop; updateresources[i].srcipv6val = resources[i].srcipv6val; updateresources[i].srcport = resources[i].srcport; updateresources[i].srcportop = resources[i].srcportop; updateresources[i].srcportval = resources[i].srcportval; updateresources[i].destipv6 = resources[i].destipv6; updateresources[i].destipop = resources[i].destipop; updateresources[i].destipv6val = resources[i].destipv6val; updateresources[i].destport = resources[i].destport; updateresources[i].destportop = resources[i].destportop; updateresources[i].destportval = resources[i].destportval; updateresources[i].srcmac = resources[i].srcmac; updateresources[i].protocol = resources[i].protocol; updateresources[i].protocolnumber = resources[i].protocolnumber; updateresources[i].icmptype = resources[i].icmptype; updateresources[i].icmpcode = resources[i].icmpcode; updateresources[i].vlan = resources[i].vlan; updateresources[i].Interface = resources[i].Interface; updateresources[i].priority = resources[i].priority; updateresources[i].established = resources[i].established; } result = update_bulk_request(client, updateresources); } return result; }
[ "Use this API to update nsacl6 resources." ]
[ "judge a->b is ordered clockwise\n\n@param center\n@param a\n@param b\n@return", "Returns an iban with replaced check digit.\n\n@param iban The iban\n@return The iban without the check digit", "The only difference between version 1.5 and 1.6 of the schema were to make is possible to define discovery options, this\nresulted in the host and port attributes becoming optional -this method also indicates if discovery options are required\nwhere the host and port were not supplied.\n\n@param allowDiscoveryOptions i.e. are host and port potentially optional?\n@return true if discovery options are required, i.e. no host and port set and the admin policy requires a config.", "Returns the formula for the percentage\n@param group\n@param type\n@return", "Returns the corresponding ModuleSpec service name for the given module.\n\n@param identifier The module identifier\n@return The service name of the ModuleSpec service", "Sets the value of the setting with the specified key.\n\n@param key name of the setting\n@param value the setting value\n@return this {@code EnvironmentConfig} instance", "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.", "Searches the variables layers, top to bottom, for given name, and returns if found; null otherwise.\n\nIf maxDepth is set to {@link Variables#SEARCH_ALL_LAYERS}, then search all layers.", "Method is called by spring and verifies that there is only one plugin per URI scheme." ]
InputStream openContentStream(final ContentItem item) throws IOException { final File file = getFile(item); if (file == null) { throw new IllegalStateException(); } return new FileInputStream(file); }
[ "Open a new content stream.\n\n@param item the content item\n@return the content stream" ]
[ "Get an InputStream for the original image. Callers must close the stream upon completion.\n\n@deprecated\n@see PhotosInterface#getImageAsStream(Photo, int)\n@return The InputStream\n@throws IOException", "Compute 2-dimensional Perlin noise.\n@param x the x coordinate\n@param y the y coordinate\n@return noise value at (x,y)", "Returns all base types.\n\n@return An iterator of the base types", "Remove the group and all references to it\n\n@param groupId ID of group", "Finish initialization of state object.\n\n@param geoService geo service\n@param converterService converter service\n@throws GeomajasException oops", "Get the property name of a method name. For example the property name of\nsetSomeValue would be someValue. Names not beginning with set or get are\nnot changed.\n\n@param name The name to process\n@return The property name", "Add the elements that all values objects require from the provided values object.\n\n@param sourceValues the values object containing the required elements", "Create the index and associate it with all project models in the Application", "parse the target resource and add it to the current shape\n@param shapes\n@param modelJSON\n@param current\n@throws org.json.JSONException" ]
public MethodKey createCopy() { int size = getParameterCount(); Class[] paramTypes = new Class[size]; for (int i = 0; i < size; i++) { paramTypes[i] = getParameterType(i); } return new DefaultMethodKey(sender, name, paramTypes, isCallToSuper); }
[ "Creates an immutable copy that we can cache." ]
[ "Get the value of a Annotation in a class declaration.\n@param classType\n@param annotationType\n@param attributeName\n@return the value of the annotation as String or null if something goes wrong", "Mark for creation all objects that were included into dependent collections.\nMark for deletion all objects that were excluded from dependent collections.", "Log a message with a throwable at the provided level.", "Set the duration option.\n@param value the duration option to set ({@link EndType} as string).", "Use this API to update Interface.", "This method must be called on the stop of the component. Stop the directory monitor and unregister all the\ndeclarations.", "Parses a record containing hours and add them to a container.\n\n@param ranges hours container\n@param hoursRecord hours record", "Treats the object as iterable, iterating through the values it represents and returns the first non-null result obtained from calling the closure, otherwise returns the defaultResult.\n\n@param self an Object with an iterator returning its values\n@param defaultResult an Object that should be returned if all closure results are null\n@param closure a closure that returns a non-null value when processing should stop\n@return the first non-null result of the closure, otherwise the default value\n@since 1.7.5", "This method writes task data to a Planner file.\n\n@throws JAXBException on xml creation errors" ]
public static int copyAllBytes(InputStream in, OutputStream out) throws IOException { int byteCount = 0; byte[] buffer = new byte[BUFFER_SIZE]; while (true) { int read = in.read(buffer); if (read == -1) { break; } out.write(buffer, 0, read); byteCount += read; } return byteCount; }
[ "Copies all available data from in to out without closing any stream.\n\n@return number of bytes copied" ]
[ "Use this API to delete nsip6 resources of given names.", "Use this API to update nsrpcnode.", "Returns a predicate that takes no parameters. The given SQL expression is\nused directly.\n\n@param sql\nSQL text of the expression", "Formats event output by key, usually equal to the method name.\n\n@param key the event key\n@param defaultPattern the default pattern to return if a custom pattern\nis not found\n@param args the args used to format output\n@return A formatted event output", "Use this API to update nsconfig.", "Returns the type of the current member which is the type in the case of a field, the return type for a getter\nmethod, or the type of the parameter for a setter method.\n\n@return The member type\n@exception XDocletException if an error occurs", "delete topic never used\n\n@param topic topic name\n@param password password\n@return number of partitions deleted\n@throws IOException if an I/O error", "Invoke the operation.\n@param parameterMap the {@link Map} of parameter names to value arrays.\n@return the {@link Object} return value from the operation.\n@throws JMException Java Management Exception", "Returns s if it's at most maxWidth chars, otherwise chops right side to fit." ]
private void clearBeatGrids(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) { deliverBeatGridUpdate(player, null); // Inform listeners the beat grid is gone. } } } }
[ "We have received notification that a device is no longer on the network, so clear out all its beat grids.\n\n@param announcement the packet which reported the device’s disappearance" ]
[ "Adds an option to the JVM arguments to enable JMX connection\n\n@param jvmArgs the JVM args\n@return a new list of JVM args", "Use this API to add route6 resources.", "remove a converted object from the pool\n\n@param converter\n@param sourceObject\n@param destinationType", "Adds steps types from given injector and recursively its parent\n\n@param injector the current Inject\n@param types the List of steps types", "Look up all recorded playback state information.\n\n@return the playback state recorded for any player\n@since 0.5.0", "Calculate which pie slice is under the pointer, and set the current item\nfield accordingly.", "Add the given query parameters.\n@param params the params\n@return this UriComponentsBuilder", "Verifies if the new value is different from the field's old value. It's\nuseful, for example, in NoSQL databases that replicates data between\nservers. This verification prevents to mark a field as modified and to be\nreplicated needlessly.\n\n@param field\nthe field that we are checking before to be modified\n@param value\nthe new value\n@return true if the new and the old values are different and the value\nwas changed.", "refresh credentials if CredentialProvider set" ]
public void append(String str, String indentation) { if (indentation.isEmpty()) { append(str); } else if (str != null) append(indentation, str, segments.size()); }
[ "Add the given string to this sequence. The given indentation will be prepended to\neach line except the first one if the object has a multi-line string representation.\n\n@param str\nthe appended string.\n@param indentation\nthe indentation string that should be prepended. May not be <code>null</code>.\n@since 2.11" ]
[ "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", "dispatch to gravity state", "Prints associations recovered from the fields of a class. An association is inferred only\nif another relation between the two classes is not already in the graph.\n@param classes", "TestNG returns a compound thread ID that includes the thread name and its numeric ID,\nseparated by an 'at' sign. We only want to use the thread name as the ID is mostly\nunimportant and it takes up too much space in the generated report.\n@param threadId The compound thread ID.\n@return The thread name.", "Run the configured crawl. This method blocks until the crawl is done.\n\n@return the CrawlSession once the crawl is done.", "Gets the or create protocol header.\n\n@param message the message\n@return the message headers map", "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.", "Unlocks a file.", "Updates the existing cluster such that we remove partitions mentioned\nfrom the stealer node and add them to the donor node\n\n@param currentCluster Existing cluster metadata. Both stealer and donor\nnode should already exist in this metadata\n@param stealerNodeId Id of node for which we are stealing the partitions\n@param donatedPartitions List of partitions we are moving\n@return Updated cluster metadata" ]
public static void validateZip(File file) throws IOException { ZipInputStream zipInput = new ZipInputStream(new FileInputStream(file)); ZipEntry zipEntry = zipInput.getNextEntry(); while (zipEntry != null) { zipEntry = zipInput.getNextEntry(); } try { if (zipInput != null) { zipInput.close(); } } catch (IOException e) { } }
[ "Checks if a Zip is valid navigating through the entries\n\n@param file File to validate\n@throws IOException I/O Error" ]
[ "Gets all the enterprise events that occurred within a specified date range.\n@param api the API connection to use.\n@param after the lower bound on the timestamp of the events returned.\n@param before the upper bound on the timestamp of the events returned.\n@param types an optional list of event types to filter by.\n@return a log of all the events that met the given criteria.", "Returns the default conversion for the given java type.\n\n@param javaType The qualified java type\n@return The default conversion or <code>null</code> if there is no default conversion for the type", "From three tagNames, if one is under sectorTag and one under rowTag, returns the remaining one, which is supposedly the a box label. Otherwise,\nreturns null.", "Return a replica of this instance with the quality value of the given MediaType.\n@return the same instance if the given MediaType doesn't have a quality value, or a new one otherwise", "Executes the supplied cell processors on the last row of CSV that was read and populates the supplied List of\nprocessed columns.\n\n@param processedColumns\nthe List to populate with processed columns\n@param processors\nthe cell processors\n@return the updated List\n@throws NullPointerException\nif processedColumns or processors is null\n@throws SuperCsvConstraintViolationException\nif a CellProcessor constraint failed\n@throws SuperCsvException\nif the wrong number of processors are supplied, or CellProcessor execution failed", "Fetch a value from the Hashmap .\n\n@param firstKey\nfirst key\n@param secondKey\nsecond key\n@return the element or null.", "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", "Sets the first occurence.\n\n@param min the min\n@param max the max\n@throws ParseException the parse exception", "Get the correct google api key.\nTries to read a workplace key first.\n\n@param cms CmsObject\n@param sitePath site path\n@return key value\n@throws CmsException exception" ]
private void initialize(Handler callbackHandler) { int processors = Runtime.getRuntime().availableProcessors(); mDownloadDispatchers = new DownloadDispatcher[processors]; mDelivery = new CallBackDelivery(callbackHandler); }
[ "Perform construction.\n\n@param callbackHandler" ]
[ "Returns a JSONObject keyed with the lastId retrieved and a value of a JSONArray of the retrieved JSONObject events\n\n@param table the table to read from\n@return JSONObject containing the max row ID and a JSONArray of the JSONObject events or null", "Use this API to delete cacheselector resources of given names.", "Deletes a redirect by id\n\n@param id redirect ID", "Creates the container for a bundle with descriptor.\n@return the container for a bundle with descriptor.\n@throws IOException thrown if reading the bundle fails.\n@throws CmsException thrown if reading the bundle fails.", "Adds a data set with date-time value to IIM file.\n\n@param ds\ndata set id (see constants in IIM class)\n@param date\ndate to set. Null values are silently ignored.\n@throws SerializationException\nif value can't be serialized by data set's serializer\n@throws InvalidDataSetException\nif data set isn't defined", "Set the pickers selection type.", "Returns a list of metadata property paths.\n@return the list of metdata property paths.", "Load model from file\n\n@param gvrContext Valid {@link GVRContext} instance\n@param modelFile Path to the model's file, relative to the {@code assets} directory\n@return root object The root {@link GVRSceneObject} of the model\n@throws IOException If reading the model file fails", "This method writes assignment data to an MSPDI file.\n\n@param project Root node of the MSPDI file" ]
public Replication targetOauth(String consumerSecret, String consumerKey, String tokenSecret, String token) { targetOauth = new JsonObject(); this.consumerSecret = consumerSecret; this.consumerKey = consumerKey; this.tokenSecret = tokenSecret; this.token = token; return this; }
[ "Authenticate with the target database using OAuth.\n\n@param consumerSecret consumer secret\n@param consumerKey consumer key\n@param tokenSecret token secret\n@param token token\n@return this Replication instance to set more options\n@deprecated OAuth 1.0 implementation has been <a href=\"http://docs.couchdb.org/en/stable/whatsnew/2.1.html?highlight=oauth#upgrade-notes\"\ntarget=\"_blank\">removed in CouchDB 2.1</a>" ]
[ "Deletes the device pin.", "This method is called to format a time value.\n\n@param value time value\n@return formatted time value", "Load assertion from the provided json or throw exception if not possible.\n\n@param encodedAssertion the assertion as it was encoded in JSON.", "Support the subscript operator for String.\n\n@param text a String\n@param index the index of the Character to get\n@return the Character at the given index\n@since 1.0", "Extract information from a resource ID string with the resource type\nas the identifier.\n\n@param id the resource ID\n@param identifier the identifier to match, e.g. \"resourceGroups\", \"storageAccounts\"\n@return the information extracted from the identifier", "Adjusts the site root and returns a cloned CmsObject, iff the module has set an import site that differs\nfrom the site root of the CmsObject provided as argument. Otherwise returns the provided CmsObject unchanged.\n@param cms The original CmsObject.\n@param module The module where the import site is read from.\n@return The original CmsObject, or, if necessary, a clone with adjusted site root\n@throws CmsException see {@link OpenCms#initCmsObject(CmsObject)}", "FOR internal use. This method was called before the external transaction was completed.\n\nThis method was called by the JTA-TxManager before the JTA-tx prepare call. Within this method\nwe prepare odmg for commit and pass all modified persistent objects to DB and release/close the used\nconnection. We have to close the connection in this method, because the TxManager does prepare for commit\nafter this method and all used DataSource-connections have to be closed before.\n\n@see javax.transaction.Synchronization", "Fetches a list of available photo licenses for Flickr.\n\nThis method does not require authentication.\n\n@return A collection of License objects\n@throws FlickrException", "Modify a bundle.\n\n@param moduleName the module name\n@param slot the module slot\n@param existingHash the existing hash\n@param newHash the new hash of the modified content\n@return the builder" ]
public IdRange[] parseIdRange(ImapRequestLineReader request) throws ProtocolException { CharacterValidator validator = new MessageSetCharValidator(); String nextWord = consumeWord(request, validator); int commaPos = nextWord.indexOf(','); if (commaPos == -1) { return new IdRange[]{IdRange.parseRange(nextWord)}; } List<IdRange> rangeList = new ArrayList<>(); int pos = 0; while (commaPos != -1) { String range = nextWord.substring(pos, commaPos); IdRange set = IdRange.parseRange(range); rangeList.add(set); pos = commaPos + 1; commaPos = nextWord.indexOf(',', pos); } String range = nextWord.substring(pos); rangeList.add(IdRange.parseRange(range)); return rangeList.toArray(new IdRange[rangeList.size()]); }
[ "Reads a \"message set\" argument, and parses into an IdSet.\nCurrently only supports a single range of values." ]
[ "Formats a logging event to a writer.\n\n@param event\nlogging event to be formatted.", "Processes the original class rather than the current class definition.\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\"", "Launch Application Setting to grant permission.", "The transaction will be executed. While it is running, any semantic state change\nin the given resource will be ignored and the cache will not be cleared.", "Load and run the OnBrowserCreatedPlugins, this call has been made from the browser pool when a\nnew browser has been created and ready to be used by the Crawler. The PreCrawling plugins are\nexecuted before these plugins are executed except that the pre-crawling plugins are only\nexecuted on the first created browser.\n\n@param newBrowser the new created browser object", "Utility function that fetches all stores on a node.\n\n@param adminClient An instance of AdminClient points to given cluster\n@param nodeId Node id to fetch stores from\n@return List of all store names", "binds the Identities Primary key values to the statement", "Read configuration from zookeeper", "This method works as the one above, adding some properties to the message\n\n@param agent_name\nThe id of the agents that receive the message\n@param msgtype\n@param message_content\nThe content of the message\n@param properties\nto be added to the message\n@param connector\nThe connector to get the external access" ]
private static RemoteWebDriver buildRemoteWebDriver(String hubUrl) { DesiredCapabilities capabilities = new DesiredCapabilities(); capabilities.setPlatform(Platform.ANY); URL url; try { url = new URL(hubUrl); } catch (MalformedURLException e) { LOGGER.error("The given hub url of the remote server is malformed can not continue!", e); return null; } HttpCommandExecutor executor = null; try { executor = new HttpCommandExecutor(url); } catch (Exception e) { // TODO Stefan; refactor this catch, this will definitely result in // NullPointers, why // not throw RuntimeException direct? LOGGER.error( "Received unknown exception while creating the " + "HttpCommandExecutor, can not continue!", e); return null; } return new RemoteWebDriver(executor, capabilities); }
[ "Private used static method for creation of a RemoteWebDriver. Taking care of the default\nCapabilities and using the HttpCommandExecutor.\n\n@param hubUrl the url of the hub to use.\n@return the RemoteWebDriver instance." ]
[ "Creates a new random symmetric matrix that will have the specified real eigenvalues.\n\n@param num Dimension of the resulting matrix.\n@param rand Random number generator.\n@param eigenvalues Set of real eigenvalues that the matrix will have.\n@return A random matrix with the specified eigenvalues.", "private multi-value handlers and helpers", "Set the custom projection matrix with individual matrix elements.", "Adds a JSON string representing to the DB.\n\n@param obj the JSON to record\n@return the number of rows in the table, or DB_OUT_OF_MEMORY_ERROR/DB_UPDATE_ERROR", "Convert this object to a json array.", "Gets a JSON string containing any pending changes to this object that can be sent back to the Box API.\n@return a JSON string containing the pending changes.", "Reads the configuration of a field facet.\n@param pathPrefix The XML Path that leads to the field facet configuration, or <code>null</code> if the XML was not correctly structured.\n@return The read configuration, or <code>null</code> if the XML was not correctly structured.", "Find the latest task finish date. We treat this as the\nfinish date for the project.\n\n@return finish date", "Populates date time settings.\n\n@param record MPX record\n@param properties project properties" ]
public static<Z> Function0<Z> lift(Callable<Z> f) { return bridge.lift(f); }
[ "Lift a Java Callable to a Scala Function0\n\n@param f the function to lift\n\n@returns the Scala function" ]
[ "Sets orientation of loopbar\n\n@param orientation int value of orientation. Must be one of {@link Orientation}", "Returns an java object read from the specified ResultSet column.", "Create a structured Record instance from the flat text data.\nNull is returned if errors are encountered during parse.\n\n@param text flat text data\n@return Record instance", "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.", "absolute for basicJDBCSupport\n@param row", "Determines the mutator method name based on a field name.\n\n@param fieldName\na field name\n@return the resulting method name", "Update server mapping's host header\n\n@param serverMappingId ID of server mapping\n@param hostHeader value of host header\n@return updated ServerRedirect", "Append Join for SQL92 Syntax", "Generate a results file for each test in each suite.\n@param outputDirectory The target directory for the generated file(s)." ]
public TFuture<JsonResponse<AdvertiseResponse>> advertise() { final AdvertiseRequest advertiseRequest = new AdvertiseRequest(); advertiseRequest.addService(service, 0); // TODO: options for hard fail, retries etc. final JsonRequest<AdvertiseRequest> request = new JsonRequest.Builder<AdvertiseRequest>( HYPERBAHN_SERVICE_NAME, HYPERBAHN_ADVERTISE_ENDPOINT ) .setBody(advertiseRequest) .setTimeout(REQUEST_TIMEOUT) .setRetryLimit(4) .build(); final TFuture<JsonResponse<AdvertiseResponse>> future = hyperbahnChannel.send(request); future.addCallback(new TFutureCallback<JsonResponse<AdvertiseResponse>>() { @Override public void onResponse(JsonResponse<AdvertiseResponse> response) { if (response.isError()) { logger.error("Failed to advertise to Hyperbahn: {} - {}", response.getError().getErrorType(), response.getError().getMessage()); } if (destroyed.get()) { return; } scheduleAdvertise(); } }); return future; }
[ "Starts advertising on Hyperbahn at a fixed interval.\n\n@return a future that resolves to the response of the first advertise request" ]
[ "Use this API to fetch systemsession resource of given name .", "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", "called when we are completed finished with using the TcpChannelHub", "Generate a schedule descriptor for the given start and end date.\n\n@param startDate The start date.\n@param endDate The end date.\n@return The schedule descriptor", "Checks if Docker Machine is installed by running docker-machine and inspect the result.\n\n@param cliPathExec\nlocation of docker-machine or null if it is on PATH.\n\n@return true if it is installed, false otherwise.", "If there are any observer methods, they must be static or business\nmethods.", "Use this API to clear gslbldnsentries resources.", "Apply all attributes on the given context, hereby existing entries are preserved.\n\n@param context the context to be applied, not null.\n@return this Builder, for chaining\n@see #importContext(AbstractContext, boolean)", "Get the root build which triggered the current build. The build root is considered to be the one furthest one\naway from the current build which has the isPassIdentifiedDownstream active, if no parent build exists, check\nthat the current build needs an upstream identifier, if it does return it.\n\n@param currentBuild The current build.\n@return The root build with isPassIdentifiedDownstream active. Null if no upstream or non is found." ]
private void writeTaskBaselines(Project.Tasks.Task xmlTask, Task mpxjTask) { Project.Tasks.Task.Baseline baseline = m_factory.createProjectTasksTaskBaseline(); boolean populated = false; Number cost = mpxjTask.getBaselineCost(); if (cost != null && cost.intValue() != 0) { populated = true; baseline.setCost(DatatypeConverter.printCurrency(cost)); } Duration duration = mpxjTask.getBaselineDuration(); if (duration != null && duration.getDuration() != 0) { populated = true; baseline.setDuration(DatatypeConverter.printDuration(this, duration)); baseline.setDurationFormat(DatatypeConverter.printDurationTimeUnits(duration, false)); } Date date = mpxjTask.getBaselineFinish(); if (date != null) { populated = true; baseline.setFinish(date); } date = mpxjTask.getBaselineStart(); if (date != null) { populated = true; baseline.setStart(date); } duration = mpxjTask.getBaselineWork(); if (duration != null && duration.getDuration() != 0) { populated = true; baseline.setWork(DatatypeConverter.printDuration(this, duration)); } if (populated) { baseline.setNumber(BigInteger.ZERO); xmlTask.getBaseline().add(baseline); } for (int loop = 1; loop <= 10; loop++) { baseline = m_factory.createProjectTasksTaskBaseline(); populated = false; cost = mpxjTask.getBaselineCost(loop); if (cost != null && cost.intValue() != 0) { populated = true; baseline.setCost(DatatypeConverter.printCurrency(cost)); } duration = mpxjTask.getBaselineDuration(loop); if (duration != null && duration.getDuration() != 0) { populated = true; baseline.setDuration(DatatypeConverter.printDuration(this, duration)); baseline.setDurationFormat(DatatypeConverter.printDurationTimeUnits(duration, false)); } date = mpxjTask.getBaselineFinish(loop); if (date != null) { populated = true; baseline.setFinish(date); } date = mpxjTask.getBaselineStart(loop); if (date != null) { populated = true; baseline.setStart(date); } duration = mpxjTask.getBaselineWork(loop); if (duration != null && duration.getDuration() != 0) { populated = true; baseline.setWork(DatatypeConverter.printDuration(this, duration)); } if (populated) { baseline.setNumber(BigInteger.valueOf(loop)); xmlTask.getBaseline().add(baseline); } } }
[ "Writes task baseline data.\n\n@param xmlTask MSPDI task\n@param mpxjTask MPXJ task" ]
[ "Converts an image in BINARY mode to RGB mode\n\n@param img image\n@return new MarvinImage instance in RGB mode", "This method takes the textual version of a priority\nand returns an appropriate instance of this class. Note that unrecognised\nvalues are treated as medium priority.\n\n@param locale target locale\n@param priority text version of the priority\n@return Priority class instance", "Split string of comma-delimited ints into an a int array\n\n@param str\n@return\n@throws IllegalArgumentException", "Sets the left padding character for all cells in the table.\n@param paddingLeftChar new padding character, ignored if null\n@return this to allow chaining", "As we merge several operations into one operation, we need to be sure the write concern applied to the aggregated\noperation respects all the requirements expressed for each separate operation.\n\nThus, for each parameter of the write concern, we keep the stricter one for the resulting merged write concern.", "Unmarshal the XML content with auto-correction.\n@param file the file that contains the XML\n@return the XML read from the file\n@throws CmsXmlException thrown if the XML can't be read.", "Post a module to the server\n\n@param module\n@param user\n@param password\n@throws GrapesCommunicationException\n@throws javax.naming.AuthenticationException", "Run through all maps and remove any references that have been null'd out by the GC.", "Based on the current request represented by the HttpExchange construct a complete URL for the supplied path.\n\n@param exchange - The current HttpExchange\n@param path - The path to include in the constructed URL\n@return The constructed URL" ]
public InputStream getInstance(DirectoryEntry directory, String name) throws IOException { DocumentEntry entry = (DocumentEntry) directory.getEntry(name); InputStream stream; if (m_encrypted) { stream = new EncryptedDocumentInputStream(entry, m_encryptionCode); } else { stream = new DocumentInputStream(entry); } return stream; }
[ "Method used to instantiate the appropriate input stream reader,\na standard one, or one which can deal with \"encrypted\" data.\n\n@param directory directory entry\n@param name file name\n@return new input stream\n@throws IOException" ]
[ "Return the basis functions for the regression suitable for this product.\n\n@param fixingDate The condition time.\n@param model The model\n@return The basis functions for the regression suitable for this product.\n@throws net.finmath.exception.CalculationException Thrown if the valuation fails, specific cause may be available via the <code>cause()</code> method.", "Resolve the targeted license thanks to the license ID\nReturn null if no license is matching the licenseId\n\n@param licenseId\n@return DbLicense", "Get a unique reference to a place where a track is currently loaded in a player.\n\n@param player the player in which the track is loaded\n@param hotCue hot cue number in which the track is loaded, or 0 if it is actively loaded on the playback deck\n\n@return the instance that will always represent a reference to the specified player and hot cue", "Tries to load a property file with the specified name.\n\n@param localizedName the name\n@return the resource bundle if it was loaded, otherwise the backup", "Determines whether the given list contains a descriptor with the same name.\n\n@param defs The list to search\n@param obj The object that is searched for\n@return <code>true</code> if the list contains a descriptor with the same name", "Recursively add files to a ZipOutputStream\n\n@param parent Parent file\n@param zout ZipOutputStream to append\n@param fileSource The file source\n@throws IOException I/O Error", "We have received an update that invalidates any previous metadata for that player, so clear it out, and alert\nany listeners if this represents a change. This does not affect the hot cues; they will stick around until the\nplayer loads a new track that overwrites one or more of them.\n\n@param update the update which means we can have no metadata for the associated player", "get the underlying wrapped connection\n@return OTMConnection raw connection to the OTM.", "Creates the server setup, depending on the protocol flags.\n\n@return the configured server setups." ]
public static Map<String, Automaton> createAutomatonMap(String prefix, List<String> valueList, Boolean filter) { HashMap<String, Automaton> automatonMap = new HashMap<>(); if (valueList != null) { for (String item : valueList) { if (filter) { item = item.replaceAll("([\\\"\\)\\(\\<\\>\\.\\@\\#\\]\\[\\{\\}])", "\\\\$1"); } automatonMap.put(item, new RegExp(prefix + MtasToken.DELIMITER + item + "\u0000*") .toAutomaton()); } } return automatonMap; }
[ "Creates the automaton map.\n\n@param prefix the prefix\n@param valueList the value list\n@param filter the filter\n@return the map" ]
[ "Returns the index of each elem in a List.\n@param elems The list of items\n@return An array of indices", "If the file is compressed, handle this so that the stream is ready to read.\n\n@param stream input stream\n@return uncompressed input stream", "Return the IP address as text such as \"192.168.1.15\".", "Reads a single byte from the input stream.", "Returns all model classes registered on this datasource\n\n@return model classes talk to this datasource", "Process this deployment for annotations. This will use an annotation indexer to create an index of all annotations\nfound in this deployment and attach it to the deployment unit context.\n\n@param phaseContext the deployment unit context\n@throws DeploymentUnitProcessingException", "Set the group name\n\n@param name new name of server group\n@param id ID of group", "Webkit based browsers require that we set the webkit-user-drag style\nattribute to make an element draggable.", "Creates a status instance from the given serviceReferences.\nThe given list is copied to a new set made immutable.\n\n@param serviceReferencesBound the set of ServiceReference which are bound to the declaration.\n@param serviceReferencesHandled the set of ServiceReference which are handling the declaration.\n@return the new instance of status" ]
public byte[] toBytes(T object) { try { ByteArrayOutputStream stream = new ByteArrayOutputStream(); ObjectOutputStream out = new ObjectOutputStream(stream); out.writeObject(object); return stream.toByteArray(); } catch(IOException e) { throw new SerializationException(e); } }
[ "Transform the given object into an array of bytes\n\n@param object The object to be serialized\n@return The bytes created from serializing the object" ]
[ "This implementation returns whether the underlying asset exists.", "Populate a resource assignment.\n\n@param record MPX record\n@param assignment resource assignment\n@throws MPXJException", "Describes the scenario. Must be called before any step invocation.\n@param description the description\n@return this for a fluent interface", "This method finds the start of the next working period.\n\n@param cal current Calendar instance", "Use this API to add tmtrafficaction.", "Returns true if required properties for FluoClient are set", "Retrieves the real subject from the underlying RDBMS. Override this\nmethod if the object is to be materialized in a specific way.\n\n@return The real subject of the proxy", "Used for unit tests only.\n\nFIXME: Refactor test code with dependency injection or scope restrictions so this function is not public.\n\n@deprecated Do not use for production code, use {@link #fetch(String, String, voldemort.server.protocol.admin.AsyncOperationStatus, String, long, voldemort.store.metadata.MetadataStore, Long diskQuotaSizeInKB)} instead.", "Returns the default safety level preference for the user.\n\n@see com.flickr4java.flickr.Flickr#SAFETYLEVEL_MODERATE\n@see com.flickr4java.flickr.Flickr#SAFETYLEVEL_RESTRICTED\n@see com.flickr4java.flickr.Flickr#SAFETYLEVEL_SAFE\n@return The current users safety-level\n@throws FlickrException" ]
public static void initializeDomainRegistry(final TransformerRegistry registry) { //The chains for transforming will be as follows //For JBoss EAP: 8.0.0 -> 5.0.0 -> 4.0.0 -> 1.8.0 -> 1.7.0 -> 1.6.0 -> 1.5.0 registerRootTransformers(registry); registerChainedManagementTransformers(registry); registerChainedServerGroupTransformers(registry); registerProfileTransformers(registry); registerSocketBindingGroupTransformers(registry); registerDeploymentTransformers(registry); }
[ "Initialize the domain registry.\n\n@param registry the domain registry" ]
[ "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 get operation with the specified composite request object\n\n@param requestWrapper A composite request object containing the key (and\n/ or default value) and timeout.\n@return The Versioned value corresponding to the key", "Returns the text for the JSONObject of Link provided\nThe JSONObject of Link provided should be of the type \"url\"\n@param jsonObject of Link\n@return String", "Compares two fields given by their names.\n\n@param objA The name of the first field\n@param objB The name of the second field\n@return\n@see java.util.Comparator#compare(java.lang.Object, java.lang.Object)", "Returns the corresponding module resolved service name for the given module.\n\nThe module resolved service is basically a latch that prevents the module from being loaded\nuntil all the transitive dependencies that it depends upon have have their module spec services\ncome up.\n\n@param identifier The module identifier\n@return The service name of the ModuleSpec service", "Implement the persistence handler for storing the user properties.", "Implement this to do your drawing.\n\n@param canvas the canvas on which the background will be drawn", "Update the value of an embedded node property.\n\n@param executionEngine the {@link GraphDatabaseService} used to run the query\n@param keyValues the columns representing the identifier in the entity owning the embedded\n@param embeddedColumn the column on the embedded node (dot-separated properties)\n@param value the new value for the property", "Ask the specified player for the album art 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 artReference uniquely identifies the desired album art\n@param trackType the kind of track that owns the art\n@param failIfPassive will prevent the request from taking place if we are in passive mode, so that automatic\nartwork updates will use available caches only\n\n@return the album art found, if any" ]
public Object getProperty(Object object) { MetaMethod getter = getGetter(); if (getter == null) { if (field != null) return field.getProperty(object); //TODO: create a WriteOnlyException class? throw new GroovyRuntimeException("Cannot read write-only property: " + name); } return getter.invoke(object, MetaClassHelper.EMPTY_ARRAY); }
[ "Get the property of the given object.\n\n@param object which to be got\n@return the property of the given object\n@throws RuntimeException if the property could not be evaluated" ]
[ "Use this API to delete nsip6 resources of given names.", "Adds a class to the unit.", "Guess the type of the given dump from its filename.\n\n@param fileName\n@return dump type, defaulting to JSON if no type was found", "Meant to execute assertions in tests only\n@return a read-only view of the map containing the relations between entities", "Get the service name of a top-level deployment unit.\n\n@param name the simple name of the deployment\n@param phase the deployment phase\n@return the service name", "Convert a SSE to a Stitch SSE\n@param event SSE to convert\n@param decoder decoder for decoding data\n@param <T> type to decode data to\n@return a Stitch server-sent event", "Internal method that finds the matching enum for a configured field that has the name argument.\n\n@return The matching enum value or null if blank enum name.\n@throws IllegalArgumentException\nIf the enum name is not known.", "Insert entity object. The caller must first initialize the primary key\nfield.", "Refresh this context with the specified configuration locations.\n\n@param configLocations\nlist of configuration resources (see implementation for specifics)\n@throws GeomajasException\nindicates a problem with the new location files (see cause)" ]
public static Double checkLatitude(String name, Double latitude) { if (latitude == null) { throw new IndexException("{} required", name); } else if (latitude < MIN_LATITUDE || latitude > MAX_LATITUDE) { throw new IndexException("{} must be in range [{}, {}], but found {}", name, MIN_LATITUDE, MAX_LATITUDE, latitude); } return latitude; }
[ "Checks if the specified latitude is correct.\n\n@param name the name of the latitude field\n@param latitude the value of the latitude field\n@return the latitude" ]
[ "Gets read-only metadata.\n\n@param adminClient An instance of AdminClient points to given cluster\n@param nodeIds Node ids to fetch read-only metadata from\n@param storeNames Stores names to fetch read-only metadata from\n@param metaKeys List of read-only metadata to fetch\n@throws IOException", "Print a a basic type t", "Throw fault.\n\n@param code the fault code\n@param message the message\n@param t the throwable type\n@throws PutEventsFault", "Use this API to add dospolicy resources.", "Removes file from your assembly.\n\n@param name field name of the file to remove.", "Create a list out of the items in the Iterable.\n\n@param <T>\nThe type of items in the Iterable.\n@param items\nThe items to be made into a list.\n@return A list consisting of the items of the Iterable, in the same order.", "Converts an object to an object, with squiggly filters applied.\n\n@param mapper the object mapper\n@param source the source to convert\n@return target instance\n@see SquigglyUtils#objectify(ObjectMapper, Object, Class)", "Write all state items to the log file.\n\n@param fileRollEvent the event to log", "Returns an attribute's value from a non-main section of this JAR's manifest.\n\n@param section the manifest's section\n@param name the attribute's name" ]
public int count(String key) { ConcurrentMap<WebSocketConnection, WebSocketConnection> bag = registry.get(key); return null == bag ? 0 : bag.size(); }
[ "Returns the connection count by key specified in this registry\n\nNote it might count connections that are closed but not removed from registry yet\n\n@param key\nthe key\n@return connection count by key" ]
[ "Emit information about a single suite and all of its tests.", "Signals that the processor to finish and waits until it finishes.", "Return the value from the field in the object that is defined by this FieldType. If the field is a foreign object\nthen the ID of the field is returned instead.", "Sets the specified starting partition key.\n\n@param paging a paging state", "Set the weeks of the month the events should occur.\n@param weeksOfMonth the weeks of month to set (first to fifth, where fifth means last).", "Operations to do after all subthreads finished their work on index\n\n@param backend", "Retrieves the real subject from the underlying RDBMS. Override this\nmethod if the object is to be materialized in a specific way.\n\n@return The real subject of the proxy", "Use this API to rename a nsacl6 resource.", "Returns the curve resulting from the local linear regression with discrete kernel.\n\n@return The regression curve." ]
public static clusterinstance[] get(nitro_service service) throws Exception{ clusterinstance obj = new clusterinstance(); clusterinstance[] response = (clusterinstance[])obj.get_resources(service); return response; }
[ "Use this API to fetch all the clusterinstance resources that are configured on netscaler." ]
[ "Deserialize an `AppDescriptor` from byte array\n\n@param bytes\nthe byte array\n@return\nan `AppDescriptor` instance", "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", "Creates a field map for relations.\n\n@param props props data", "Insert syntax for our special table\n@param sequenceName\n@param maxKey\n@return sequence insert statement", "Returns true if required properties for MiniFluo are set", "Use this API to delete snmpmanager.", "Translate a path that has previously been unescaped and unquoted.\nThat is called at command execution when the calue is retrieved prior to be\nused as ModelNode value.\n@param path The unquoted, unescaped path.\n@return A path with ~ and default dir expanded.", "This method retrieves the UID for a calendar associated with a task.\n\n@param mpx MPX Task instance\n@return calendar UID", "Edit the co-ordinates that the user shows in\n\n@param photoId\n@param userId\n@param bounds\n@throws FlickrException" ]
public void postProcess() { if (foreignColumnName != null) { foreignAutoRefresh = true; } if (foreignAutoRefresh && maxForeignAutoRefreshLevel == NO_MAX_FOREIGN_AUTO_REFRESH_LEVEL_SPECIFIED) { maxForeignAutoRefreshLevel = DatabaseField.DEFAULT_MAX_FOREIGN_AUTO_REFRESH_LEVEL; } }
[ "Process the settings when we are going to consume them." ]
[ "Use this API to fetch all the vpath resources that are configured on netscaler.", "Creates the style definition used for a rectangle element based on the given properties of the rectangle\n@param x The X coordinate of the rectangle.\n@param y The Y coordinate of the rectangle.\n@param width The width of the rectangle.\n@param height The height of the rectangle.\n@param stroke Should there be a stroke around?\n@param fill Should the rectangle be filled?\n@return The resulting element style definition.", "Appends a line separator node that will only be effective if the current line contains non-whitespace text.\n\n@return the given parent node", "Construct a new instance.\n\n@return the new instance", "Internally undo recorded changes we did so far.\n\n@return whether the state required undo actions", "Checks if the specified longitude is correct.\n\n@param name the name of the longitude field\n@param longitude the value of the longitude field\n@return the longitude", "Adds to this set all of the elements in the specified map of members and their score.\n@param scoredMember the members to add together with their scores\n@return the number of members actually added", "Iterates over the elements of an iterable collection of items, starting\nfrom a specified startIndex, and returns the index of the last item that\nmatches the condition specified in the closure.\n\n@param self the iteration object over which to iterate\n@param startIndex start matching from this index\n@param closure the filter to perform a match on the collection\n@return an integer that is the index of the last matched object or -1 if no match was found\n@since 1.5.2", "Retrieve a boolean field.\n\n@param type field type\n@return field data" ]
@Override public void start(String[] arguments) { boolean notStarted = !started.getAndSet(true); if (notStarted) { start(new SingleInstanceWorkloadStrategy(job, name, arguments, endpointRegistry, execService)); } }
[ "Starts the one and only job instance in a separate Thread. Should be called exactly one time before\nthe operation is stopped.\n\n@param arguments {@inheritDoc}" ]
[ "Whether the given grid dialect implements the specified facet or not.\n\n@param gridDialect the dialect of interest\n@param facetType the dialect facet type of interest\n@return {@code true} in case the given dialect implements the specified facet, {@code false} otherwise", "Append a Handler to a portion of the handler tree\n@param parent The parent to add the child to\n@param child The Handler to add.", "Replace a single value at the appropriate location in the existing value array.\n@param index - location in the array list\n@param newValue - the new String", "Use this API to fetch gslbservice resource of given name .", "Get information about a partition in this database.\n\n@param partitionKey database partition key\n@return {@link com.cloudant.client.api.model.PartitionInfo} encapsulating the database partition info.\n@throws UnsupportedOperationException if called with {@code null} partition key.", "Returns the name of the current member which is the name in the case of a field, or the property name for an\naccessor method.\n\n@return The member name\n@exception XDocletException if an error occurs", "Create the exception assignment map.\n\n@param rows calendar rows\n@return exception assignment map", "Run through the map and remove any references that have been null'd out by the GC.", "Use this API to count sslcipher_individualcipher_binding resources configued on NetScaler." ]
@DELETE @Path("/{name}" + ServerAPI.GET_CORPORATE_GROUPIDS) public Response removeCorporateGroupIdPrefix(@Auth final DbCredential credential, @PathParam("name") final String organizationId, final String corporateGroupId){ LOG.info("Got an remove a corporate groupId prefix request for organization " + organizationId +"."); if(!credential.getRoles().contains(DbCredential.AvailableRoles.DATA_UPDATER)){ throw new WebApplicationException(Response.status(Response.Status.UNAUTHORIZED).build()); } if(corporateGroupId == null || corporateGroupId.isEmpty()){ LOG.error("No corporate GroupId to remove!"); return Response.serverError().status(HttpStatus.BAD_REQUEST_400).build(); } getOrganizationHandler().removeCorporateGroupId(organizationId, corporateGroupId); return Response.ok("done").build(); }
[ "Remove an existing Corporate GroupId from an organization.\n\n@return Response" ]
[ "Load resource content from given path into variable with\ntype specified by `spec`.\n\n@param resourcePath the resource path\n@param spec {@link BeanSpec} specifies the return value type\n@return the resource content in a specified type or `null` if resource not found\n@throws UnexpectedException if return value type not supported", "Returns the bounding box of the vertices.\n@param corners destination array to get corners of bounding box.\nThe first three entries are the minimum X,Y,Z values\nand the next three are the maximum X,Y,Z.\n@return true if bounds are not empty, false if empty (no vertices)", "Gets id of a property and creates the new one if necessary.\n\n@param txn transaction\n@param propertyName name of the property.\n@param allowCreate if set to true and if there is no property named as propertyName,\ncreate the new id for the propertyName.\n@return < 0 if there is no such property and create=false, else id of the property", "This method is called to format a constraint type.\n\n@param type constraint type\n@return formatted constraint type", "Returns iterable with all assignments of this retention policy.\n@param limit the limit of entries per response. The default value is 100.\n@param fields the fields to retrieve.\n@return an iterable containing all assignments.", "Given a particular key, first converts its to the storage format and then\ndetermines which chunk it belongs to\n\n@param key Byte array of keys\n@return Chunk id\n@throws IllegalStateException if unable to find the chunk id for the given key", "Return the list of module ancestors\n\n@param moduleName\n@param moduleVersion\n@return List<Dependency>\n@throws GrapesCommunicationException", "Undeletes the selected files\n\n@return the ids of the modified resources\n\n@throws CmsException if something goes wrong", "Get a configured database connection via JNDI." ]
public static <T> Collection<MemberResponse<T>> executeOptimistic(IExecutorService execSvc, Set<Member> members, Callable<T> callable, long maxWaitTime, TimeUnit unit) { Collection<MemberResponse<T>> result = new ArrayList<MemberResponse<T>>(members.size()); Map<Member, Future<T>> resultFutures = execSvc.submitToMembers(callable, members); for(Entry<Member, Future<T>> futureEntry : resultFutures.entrySet()) { Future<T> future = futureEntry.getValue(); Member member = futureEntry.getKey(); try { if(maxWaitTime > 0) { result.add(new MemberResponse<T>(member, future.get(maxWaitTime, unit))); } else { result.add(new MemberResponse<T>(member, future.get())); } //ignore exceptions... return what you can } catch (InterruptedException e) { Thread.currentThread().interrupt(); //restore interrupted status and return what we have return result; } catch (MemberLeftException e) { log.warn("Member {} left while trying to get a distributed callable result", member); } catch (ExecutionException e) { if(e.getCause() instanceof InterruptedException) { //restore interrupted state and return Thread.currentThread().interrupt(); return result; } else { log.warn("Unable to execute callable on "+member+". There was an error.", e); } } catch (TimeoutException e) { log.error("Unable to execute task on "+member+" within 10 seconds."); } catch (RuntimeException e) { log.error("Unable to execute task on "+member+". An unexpected error occurred.", e); } } return result; }
[ "We will always try to gather as many results as possible and never throw an exception.\n\nTODO: Make MemberResponse hold an exception that we can populate if something bad happens so we always\nget to return something for a member in order to indicate a failure. Getting the result when there\nis an error should throw an exception.\n\n@param execSvc\n@param members\n@param callable\n@param maxWaitTime - a value of 0 indicates forever\n@param unit\n@return" ]
[ "Launches the client with the specified parameters.\n\n@param args\ncommand line parameters\n@throws ParseException\n@throws IOException", "Create a canonical represenation of the data type value. Defaults to the value converter.\n\n@since 2.9", "Check if this applies to the provided authorization scope and return the credentials for that scope or\nnull if it doesn't apply to the scope.\n\n@param authscope the scope to test against.", "Set the amount of offset between child objects and parent.\n@param axis {@link Axis}\n@param offset", "Use this API to delete lbroute.", "Validates given external observer method.\n\n@param observerMethod the given observer method\n@param beanManager\n@param originalObserverMethod observer method replaced by given observer method (this parameter is optional)", "Write exceptions in the format used by MSPDI files prior to Project 2007.\n\n@param dayList list of calendar days\n@param exceptions list of exceptions", "Set the default styles. the case of the keys are not important. The retrieval will be case\ninsensitive.\n\n@param defaultStyle the mapping from geometry type name (point, polygon, etc...) to the style\nto use for that type.", "Add a module.\n\n@param moduleName the module name\n@param slot the module slot\n@param newHash the new hash of the added content\n@return the builder" ]
@Override public String upload(File file, UploadMetaData metaData) throws FlickrException { Payload payload = new Payload(file); return sendUploadRequest(metaData, payload); }
[ "Upload a photo from a File.\n\n@param file\nthe photo file\n@param metaData\nThe meta data\n@return photoId or ticketId\n@throws FlickrException" ]
[ "Creates a random diagonal matrix where the diagonal elements are selected from a uniform\ndistribution that goes from min to max.\n\n@param N Dimension of the matrix.\n@param min Minimum value of a diagonal element.\n@param max Maximum value of a diagonal element.\n@param rand Random number generator.\n@return A random diagonal matrix.", "Adds an additional alias to the constructed document.\n\n@param text\nthe text of the alias\n@param languageCode\nthe language code of the alias\n@return builder object to continue construction", "Use this API to fetch authenticationvserver_binding resource of given name .", "Closing will only skip to the end of this fixed length input stream and\nnot call the parent's close method.\n@throws IOException if an I/O error occurs while closing stream", "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", "Creates a new form session to edit the file with the given name using the given form configuration.\n\n@param configPath the site path of the form configuration\n@param fileName the name (not path) of the XML content to edit\n@return the id of the newly created form session\n\n@throws CmsUgcException if something goes wrong", "Obtain the path ID for a profile\n\n@param identifier Can be the path ID, or friendly name\n@param profileId\n@return\n@throws Exception", "Returns the corresponding ModuleSpec service name for the given module.\n\n@param identifier The module identifier\n@return The service name of the ModuleSpec service", "Read leaf tasks attached to the WBS.\n\n@param id initial WBS ID" ]
private boolean absoluteBasic(int row) { boolean retval = false; if (row > m_current_row) { try { while (m_current_row < row && getRsAndStmt().m_rs.next()) { m_current_row++; } if (m_current_row == row) { retval = true; } else { setHasCalledCheck(true); setHasNext(false); retval = false; autoReleaseDbResources(); } } catch (Exception ex) { setHasCalledCheck(true); setHasNext(false); retval = false; } } else { logger.info("Your driver does not support advanced JDBC Functionality, " + "you cannot call absolute() with a position < current"); } return retval; }
[ "absolute for basicJDBCSupport\n@param row" ]
[ "Use this API to unset the properties of rnatparam resource.\nProperties that need to be unset are specified in args array.", "Utility function that constructs AdminClient.\n\n@param url URL pointing to the bootstrap node\n@return Newly constructed AdminClient", "Returns the screen height in pixels\n\n@param context is the context to get the resources\n@return the screen height in pixels", "Use this API to fetch lbmonitor_binding resources of given names .", "Bind a prepared statment that represents a call to a procedure or\nuser-defined function.\n\n@param stmt the statement to bind.\n@param cld the class descriptor of the object that triggered the\ninvocation of the procedure or user-defined function.\n@param obj the object that triggered the invocation of the procedure\nor user-defined function.\n@param proc the procedure descriptor that provides information about\nthe arguments that shoudl be passed to the procedure or\nuser-defined function", "Checks if the provided duration information is valid.\n@return <code>null</code> if the information is valid, the key of the suitable error message otherwise.", "1-D Gaussian kernel.\n\n@param size Kernel size (should be odd), [3, 101].\n@return Returns 1-D Gaussian kernel of the specified size.", "Returns an identity matrix", "Pretty prints the given source code.\n\n@param code\nsource code to format\n@param options\nformatter options\n@param lineEnding\ndesired line ending\n@return formatted source code" ]
void handleAddKey() { String key = m_addKeyInput.getValue(); if (m_listener.handleAddKey(key)) { Notification.show( key.isEmpty() ? m_messages.key(Messages.GUI_NOTIFICATION_MESSAGEBUNDLEEDITOR_EMPTY_KEY_SUCCESSFULLY_ADDED_0) : m_messages.key(Messages.GUI_NOTIFICATION_MESSAGEBUNDLEEDITOR_KEY_SUCCESSFULLY_ADDED_1, key)); } else { CmsMessageBundleEditorTypes.showWarning( m_messages.key(Messages.GUI_NOTIFICATION_MESSAGEBUNDLEEDITOR_KEY_ALREADEY_EXISTS_CAPTION_0), m_messages.key(Messages.GUI_NOTIFICATION_MESSAGEBUNDLEEDITOR_KEY_ALREADEY_EXISTS_DESCRIPTION_1, key)); } m_addKeyInput.focus(); m_addKeyInput.selectAll(); }
[ "Handles adding a key. Calls the registered listener and wraps it's method in some GUI adjustments." ]
[ "Adds a license to an artifact if the license exist into the database\n\n@param gavc String\n@param licenseId String", "Unmarshals the XML content and adds the file to the bundle files.\n@throws CmsException thrown if reading the file or unmarshaling fails.", "Returns the WDTK datatype IRI for the property datatype as represented by\nthe given JSON datatype string.\n\n@param jsonDatatype\nthe JSON datatype string; case-sensitive\n@throws IllegalArgumentException\nif the given datatype string is not known", "Returns a RowColumn following the current one\n\n@return RowColumn following this one", "Splits data into blocks, adds error correction and then interleaves the blocks and error correction data.", "Import user from file.", "Print a class's relations", "Will start the HiveServer.\n\n@param testConfig Specific test case properties. Will be merged with the HiveConf of the context\n@param hiveVars HiveVars to pass on to the HiveServer for this session", "Fills in the element with the InputValues for input\n\n@param element the node element\n@param input the input data" ]
public AT_Row setPaddingTopChar(Character paddingTopChar) { if(this.hasCells()){ for(AT_Cell cell : this.getCells()){ cell.getContext().setPaddingTopChar(paddingTopChar); } } return this; }
[ "Sets the top padding character for all cells in the row.\n@param paddingTopChar new padding character, ignored if null\n@return this to allow chaining" ]
[ "Goes through all the RO Stores in the plan and swaps it\n\n@param swappedStoreNames Names of stores already swapped\n@param useSwappedStoreNames Swap only the previously swapped stores (\nHappens during error )", "Read all child tasks for a given parent.\n\n@param parentTask parent task", "Convert custom info.\n\n@param customInfo the custom info map\n@return the custom info type", "Returns the simplified name of the type of the specified object.", "Creates a code location URL from a URL\n\n@param url the URL external form\n@return A URL created from URL\n@throws InvalidCodeLocation if URL creation fails", "Determine whether the given method is a \"readString\" method.\n\n@see Object#toString()", "Evaluates the body if current member has no tag with the specified name.\n\n@param template The body of the block tag\n@param attributes The attributes of the template tag\n@exception XDocletException Description of Exception\[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=\"error\" description=\"Show this error message if no tag found.\"", "Push an event which describes a purchase made.\n\n@param eventName Has to be specified as \"Charged\". Anything other than this\nwill result in an {@link InvalidEventNameException} being thrown.\n@param chargeDetails A {@link HashMap}, with keys as strings, and values as {@link String},\n{@link Integer}, {@link Long}, {@link Boolean}, {@link Float}, {@link Double},\n{@link java.util.Date}, or {@link Character}\n@param items An {@link ArrayList} which contains up to 15 {@link HashMap} objects,\nwhere each HashMap object describes a particular item purchased\n@throws InvalidEventNameException Thrown if the event name is not \"Charged\"\n@deprecated use {@link CleverTapAPI#pushChargedEvent(HashMap chargeDetails, ArrayList items)}", "Support the range subscript operator for GString\n\n@param text a GString\n@param range a Range\n@return the String of characters corresponding to the provided range\n@since 2.3.7" ]
private void deliverSyncCommand(byte command) { for (final SyncListener listener : getSyncListeners()) { try { switch (command) { case 0x01: listener.becomeMaster(); case 0x10: listener.setSyncMode(true); break; case 0x20: listener.setSyncMode(false); break; } } catch (Throwable t) { logger.warn("Problem delivering sync command to listener", t); } } }
[ "Send a sync command to all registered listeners.\n\n@param command the byte which identifies the type of sync command we received" ]
[ "Create a container in the platform\n\n@param container\nThe name of the container", "This filter permit to return an image sized exactly as requested wherever is its ratio by\nfilling with chosen color the missing parts. Usually used with \"fit-in\" or \"adaptive-fit-in\"\n\n@param color integer representation of color.", "Computes the WordNet 2.0 POS tag corresponding to the PTB POS tag s.\n\n@param s a Penn TreeBank POS tag.", "Returns the address for the operation.\n\n@param op the operation\n\n@return the operation address or a new undefined model node", "Returns true if the query result has at least one row.", "Generate a module graph regarding the filters\n\n@param moduleId String\n@return AbstractGraph", "Adds the parent package to the java.protocol.handler.pkgs system property.", "Access the customInfo of a message using this accessor. The CustomInfo\nmap will be automatically created and stored in the event if it is not yet present\n\n@param message\n@return", "Set the offsets in the compressed data area for each mip-map level.\n@param offsets array of offsets" ]
public int getPathId(String pathName, int profileId) { PreparedStatement queryStatement = null; ResultSet results = null; // first get the pathId for the pathName/profileId int pathId = -1; try (Connection sqlConnection = sqlService.getConnection()) { queryStatement = sqlConnection.prepareStatement( "SELECT " + Constants.GENERIC_ID + " FROM " + Constants.DB_TABLE_PATH + " WHERE " + Constants.PATH_PROFILE_PATHNAME + "= ? " + " AND " + Constants.GENERIC_PROFILE_ID + "= ?" ); queryStatement.setString(1, pathName); queryStatement.setInt(2, profileId); results = queryStatement.executeQuery(); if (results.next()) { pathId = results.getInt(Constants.GENERIC_ID); } } catch (Exception e) { e.printStackTrace(); } finally { try { if (results != null) { results.close(); } } catch (Exception e) { } try { if (queryStatement != null) { queryStatement.close(); } } catch (Exception e) { } } return pathId; }
[ "Get path ID for a given profileId and pathName\n\n@param pathName Name of path\n@param profileId ID of profile\n@return ID of path" ]
[ "Read a Synchro date from an input stream.\n\n@param is input stream\n@return Date instance", "Print a work contour.\n\n@param value WorkContour instance\n@return work contour value", "Deletes this collaboration.", "Processes and computes column counts of A\n\n@param A (Input) Upper triangular matrix\n@param parent (Input) Elimination tree.\n@param post (Input) Post order permutation of elimination tree. See {@link TriangularSolver_DSCC#postorder}\n@param counts (Output) Storage for column counts.", "Sets the site root.\n\n@param siteRoot the site root", "This method is used to finalize the configuration\nafter the configuration items have been set.", "Count the number of occurrences of a sub CharSequence.\n\n@param self a CharSequence\n@param text a sub CharSequence\n@return the number of occurrences of the given CharSequence inside this CharSequence\n@see #count(String, String)\n@since 1.8.2", "Returns an iterable containing all the enterprise users that matches the filter and specifies which child fields\nto retrieve from the API.\n@param api the API connection to be used when retrieving the users.\n@param filterTerm used to filter the results to only users starting with this string in either the name or the\nlogin. Can be null to not filter the results.\n@param fields the fields to retrieve. Leave this out for the standard fields.\n@return an iterable containing all the enterprise users that matches the filter.", "This method sends the same message to many agents.\n\n@param agent_name\nThe id of the agents that receive the message\n@param msgtype\n@param message_content\nThe content of the message\n@param connector\nThe connector to get the external access" ]
public static base_response unset(nitro_service client, sslparameter resource, String[] args) throws Exception{ sslparameter unsetresource = new sslparameter(); return unsetresource.unset_resource(client,args); }
[ "Use this API to unset the properties of sslparameter resource.\nProperties that need to be unset are specified in args array." ]
[ "Use this API to clear nssimpleacl.", "Generate a schedule descriptor for the given start and end date.\n\n@param startDate The start date.\n@param endDate The end date.\n@return The schedule descriptor", "Validates that this string is a valid host name or IP address, and if not, throws an exception with a descriptive message indicating why it is not.\n@throws HostNameException", "Sets orientation of loopbar\n\n@param orientation int value of orientation. Must be one of {@link Orientation}", "Log modified request\n\n@param httpMethodProxyRequest\n@param httpServletResponse\n@param history", "Calls afterMaterialization on all registered listeners in the reverse\norder of registration.", "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", "Stop finding signatures for all active players.", "Use this API to unset the properties of ntpserver resource.\nProperties that need to be unset are specified in args array." ]
Document convertSelectorToDocument(Document selector) { Document document = new Document(); for (String key : selector.keySet()) { if (key.startsWith("$")) { continue; } Object value = selector.get(key); if (!Utils.containsQueryExpression(value)) { Utils.changeSubdocumentValue(document, key, value, (AtomicReference<Integer>) null); } } return document; }
[ "convert selector used in an upsert statement into a document" ]
[ "Extract data for a single predecessor.\n\n@param task parent task\n@param row Synchro predecessor data", "Returns the screen width in pixels\n\n@param context is the context to get the resources\n@return the screen width in pixels", "Fluent API builder.\n\n@param cronExpression\n@return", "Returns the value of the matrix at the specified index of the 1D row major array.\n\n@see DMatrixRMaj#get(int)\n\n@param index The element's index whose value is to be returned\n@return The value of the specified element.", "Moves the given row up.\n\n@param row the row to move", "Generates a mapping between attribute names and data types.\n\n@param name name of the map\n@param types types to write", "This method is called by the ++ operator for the class CharSequence.\nIt increments the last character in the given CharSequence. If the last\ncharacter in the CharSequence is Character.MAX_VALUE a Character.MIN_VALUE\nwill be appended. The empty CharSequence is incremented to a string\nconsisting of the character Character.MIN_VALUE.\n\n@param self a CharSequence\n@return a value obtained by incrementing the toString() of the CharSequence\n@since 1.8.2", "Insert a value into the right bucket of the histogram. If the value is\nlarger than any bound, insert into the last bucket. If the value is less\nthan zero, then ignore it.\n\n@param data The value to insert into the histogram", "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" ]
public void showCurrentDates(Collection<CmsPair<Date, Boolean>> dates) { m_overviewList.setDatesWithCheckState(dates); m_overviewPopup.center(); }
[ "Shows the provided list of dates as current dates.\n@param dates the current dates to show, accompanied with the information if they are exceptions or not." ]
[ "creates option map for remoting connections\n@param resolver\n@param model\n@param defaults\n@return\n@throws OperationFailedException\n@deprecated configuring xnio worker options is no longer supported and should be replaced for referencing IO subsystem", "Resets all member fields that hold information about the revision that is\ncurrently being processed.", "Adds OPT_U | OPT_URL 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", "Returns the master mode's editor state for editing a bundle with descriptor.\n@return the master mode's editor state for editing a bundle with descriptor.", "a small static helper to set the text color to a textView null save\n\n@param colorHolder\n@param textView\n@param colorDefault", "Session connect generate channel.\n\n@param session\nthe session\n@return the channel\n@throws JSchException\nthe j sch exception", "Indicates that all of the packages within an archive are \"known\" by the package mapper. Generally\nthis indicates that the archive does not contain customer code.", "Parses a code block with no parentheses and no commas. After it is done there should be a single token left,\nwhich is returned.", "Use this API to add dnspolicylabel resources." ]
final public void setRealOffset(Integer start, Integer end) { if ((start == null) || (end == null)) { // do nothing } else if (start > end) { throw new IllegalArgumentException( "Start real offset after end real offset"); } else { tokenRealOffset = new MtasOffset(start, end); } }
[ "Sets the real offset.\n\n@param start the start\n@param end the end" ]
[ "Converts a duration to duration time units.\n\n@param value duration value\n@return duration time units", "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.", "Set an attribute.\n\n@param name attribute name.\n@param value attribute value.", "Use this API to fetch bridgegroup_nsip_binding resources of given name .", "Pseudo-Inverse of a matrix calculated in the least square sense.\n\n@param matrix The given matrix A.\n@return pseudoInverse The pseudo-inverse matrix P, such that A*P*A = A and P*A*P = P", "Check whether the patch can be applied to a given target.\n\n@param condition the conditions\n@param target the target\n@throws PatchingException", "Returns the AirMapView implementation as requested by the mapType argument. Use this method if\nyou need to request a specific AirMapView implementation that is not necessarily the preferred\ntype. For example, you can use it to explicit request a web-based map implementation.\n\n@param mapType Map type for the requested AirMapView implementation.\n@return An {@link AirMapViewBuilder} for the requested {@link AirMapViewTypes} mapType.", "Formats a date or a time according to the local conventions.\n\nSince ReadablePartials don't support all fields, we fill in any blanks\nneeded for formatting by using the epoch (1970-01-01T00:00:00Z).\n\nSee {@link android.text.format.DateUtils#formatDateTime} for full docs.\n\n@param context the context is required only if the time is shown\n@param time a point in time\n@param flags a bit mask of formatting options\n@return a string containing the formatted date/time.", "Find any standard methods the user has 'underridden' in their type." ]