query
stringlengths 74
6.1k
| positive
sequencelengths 1
1
| negative
sequencelengths 9
9
|
---|---|---|
public void writeAuxiliaryTriples() throws RDFHandlerException {
for (PropertyRestriction pr : this.someValuesQueue) {
writeSomeValueRestriction(pr.propertyUri, pr.rangeUri, pr.subject);
}
this.someValuesQueue.clear();
this.valueRdfConverter.writeAuxiliaryTriples();
} | [
"Writes all auxiliary triples that have been buffered recently. This\nincludes OWL property restrictions but it also includes any auxiliary\ntriples required by complex values that were used in snaks.\n\n@throws RDFHandlerException\nif there was a problem writing the RDF triples"
] | [
"Use this API to apply nspbr6.",
"Get the multicast socket address.\n\n@return the multicast address",
"Initializes the bean name defaulted",
"Use this API to fetch authenticationvserver_authenticationnegotiatepolicy_binding resources of given name .",
"Method is called by spring and verifies that there is only one plugin per URI scheme.",
"Return true if the expression is a constructor call on a class that matches the supplied.\n@param expression - the expression\n@param classNamePattern - the possible List of class names\n@return as described",
"Write a duration field to the JSON file.\n\n@param fieldName field name\n@param value field value",
"Will spawn a thread for each type in rootEntities, they will all re-join\non endAllSignal when finished.\n\n@param backend\n\n@throws InterruptedException\nif interrupted while waiting for endAllSignal.",
"Configs created by this ConfigBuilder will have the given Redis hostname.\n\n@param host the Redis hostname\n@return this ConfigBuilder"
] |
public Collection<Service> getServices() throws FlickrException {
List<Service> list = new ArrayList<Service>();
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("method", METHOD_GET_SERVICES);
Response response = transportAPI.get(transportAPI.getPath(), parameters, apiKey, sharedSecret);
if (response.isError()) {
throw new FlickrException(response.getErrorCode(), response.getErrorMessage());
}
Element servicesElement = response.getPayload();
NodeList serviceNodes = servicesElement.getElementsByTagName("service");
for (int i = 0; i < serviceNodes.getLength(); i++) {
Element serviceElement = (Element) serviceNodes.item(i);
Service srv = new Service();
srv.setId(serviceElement.getAttribute("id"));
srv.setName(XMLUtilities.getValue(serviceElement));
list.add(srv);
}
return list;
} | [
"Return a list of Flickr supported blogging services.\n\nThis method does not require authentication.\n\n@return List of Services\n@throws FlickrException"
] | [
"Returns true if the activity is a start milestone.\n\n@param activity Phoenix activity\n@return true if the activity is a milestone",
"Process the response by reporting proper log and feeding failure\ndetectors\n\n@param response\n@param pipeline",
"Parameter validity check.",
"Detects if the current device is a mobile device.\nThis method catches most of the popular modern devices.\nExcludes Apple iPads and other modern tablets.\n@return detection of any mobile device using the quicker method",
"Method used to write the name of the scenarios methods\n\n@param word\n@return the same word starting with lower case",
"Creates the DAO if we have config information cached and caches the DAO.",
"creates a shape list containing all child shapes and set it to the\ncurrent shape new shape get added to the shape array\n@param shapes\n@param modelJSON\n@param current\n@throws org.json.JSONException",
"Returns the editable columns for the provided edit mode.\n@param mode the edit mode.\n@return the editable columns for the provided edit mode.",
"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"
] |
static void apply(final String patchId, final Collection<ContentModification> modifications, final PatchEntry patchEntry, final ContentItemFilter filter) {
for (final ContentModification modification : modifications) {
final ContentItem item = modification.getItem();
// Check if we accept the item
if (!filter.accepts(item)) {
continue;
}
final Location location = new Location(item);
final ContentEntry contentEntry = new ContentEntry(patchId, modification);
ContentTaskDefinition definition = patchEntry.get(location);
if (definition == null) {
definition = new ContentTaskDefinition(location, contentEntry, false);
patchEntry.put(location, definition);
} else {
definition.setTarget(contentEntry);
}
}
} | [
"Apply modifications to a content task definition.\n\n@param patchId the patch id\n@param modifications the modifications\n@param definitions the task definitions\n@param filter the content item filter"
] | [
"write CustomInfo list into table.\n\n@param event the event",
"depth- first search for any module - just to check that the suggestion has any chance of delivering correct result",
"Updates the R matrix to take in account the removed row.",
"Add a content modification.\n\n@param modification the content modification",
"Use this API to fetch nsrpcnode resources of given names .",
"Returns the configuration value with the specified name.",
"Checks to see if another AbstractTransition's states is isCompatible for merging.\n\n@param another\n@return",
"Triggers a replication request.",
"Use this API to delete dnstxtrec of given name."
] |
public void updateMetadataVersions() {
Properties versionProps = MetadataVersionStoreUtils.getProperties(this.systemStoreRepository.getMetadataVersionStore());
Long newVersion = fetchNewVersion(SystemStoreConstants.CLUSTER_VERSION_KEY,
null,
versionProps);
if(newVersion != null) {
this.currentClusterVersion = newVersion;
}
} | [
"Fetch the latest versions for cluster metadata"
] | [
"Add groups to the tree.\n\n@param parentNode parent tree node\n@param file group container",
"Converts to credentials for use in Grgit.\n@return {@code null} if both username and password are {@code null},\notherwise returns credentials in Grgit format.",
"Calculates the maximum text height which is possible based on the used Paint and its settings.\n\n@param _Paint Paint object which will be used to display a text.\n@param _Text The text which should be measured. If null, a default text is chosen, which\nhas a maximum possible height\n@return Maximum text height in px.",
"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 provided module is valid and could be stored into the database\n\n@param module the module to test\n@throws WebApplicationException if the data is corrupted",
"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.",
"Use this API to fetch dnssuffix resources of given names .",
"Retrieve a duration in the form required by Primavera.\n\n@param duration Duration instance\n@return formatted duration",
"Generate a schedule for the given start and end date.\n\n@param referenceDate The reference date (corresponds to \\( t = 0 \\).\n@param startDate The start date.\n@param endDate The end date.\n@return The schedule"
] |
public void update(Object feature) throws LayerException {
Session session = getSessionFactory().getCurrentSession();
session.update(feature);
} | [
"Update a feature object in the Hibernate session.\n\n@param feature feature object\n@throws LayerException oops"
] | [
"Returns the scene graph root.\n\nThis method is part of the wrapped API (see {@link AiWrapperProvider}\nfor details on wrappers).<p>\n\nThe built-in behavior is to return a {@link AiVector}.\n\n@param wrapperProvider the wrapper provider (used for type inference)\n@return the scene graph root",
"A slop is dead if the destination node or the store does not exist\nanymore on the cluster.\n\n@param slop\n@return",
"Try to set the value from the provided Json string.\n@param value the value to set.\n@throws Exception thrown if parsing fails.",
"The transform method for this DataTransformer\n@param cr a reference to DataPipe from which to read the current map",
"Called when a payload thread has ended. This also notifies the poller to poll once again.",
"Retrieve the default mapping between MPXJ assignment fields and Primavera assignment field names.\n\n@return mapping",
"Send JSON representation of given data object to all connections\nconnected to given URL\n\n@param data the data object\n@param url the url",
"Use this API to fetch appfwwsdl resource of given name .",
"For use on a slave HC to get all the server groups used by the host\n\n@param hostResource the host resource\n@return the server configs on this host"
] |
public void setDateOnly(boolean dateOnly) {
if (m_dateOnly != dateOnly) {
m_dateOnly = dateOnly;
if (m_dateOnly) {
m_time.removeFromParent();
m_am.removeFromParent();
m_pm.removeFromParent();
} else {
m_timeField.add(m_time);
m_timeField.add(m_am);
m_timeField.add(m_pm);
}
}
} | [
"Sets the value if the date only should be shown.\n@param dateOnly if the date only should be shown"
] | [
"use this method to construct the ChainingIterator\niterator by iterator.",
"Optionally specify the variable name to use for the output of this condition",
"Check from another ConcurrentGroupServerUpdatePolicy whose plans are meant to\nexecute once this policy's plans are successfully completed.\n\n@return <code>true</code> if the successor can proceed",
"Utility function that converts a list to a map.\n\n@param list The list in which even elements are keys and odd elements are\nvalues.\n@rturn The map container that maps even elements to odd elements, e.g.\n0->1, 2->3, etc.",
"running in App Engine",
"Calculates the static drift. Static means, that the drift does not change direction or intensity over time.\n\n@param tracks Tracks which seems to exhibit a local drift\n@return The static drift over all trajectories",
"Use this API to fetch aaauser_binding resource of given name .",
"Creates an immutable copy that we can cache.",
"Return the list of all the module submodules\n\n@param module\n@return List<DbModule>"
] |
public void delete(Object obj, boolean ignoreReferences) throws PersistenceBrokerException
{
if(isTxCheck() && !isInTransaction())
{
if(logger.isEnabledFor(Logger.ERROR))
{
String msg = "No running PB-tx found. Please, only delete objects in context of a PB-transaction" +
" to avoid side-effects - e.g. when rollback of complex objects.";
try
{
throw new Exception("** Delete object without active PersistenceBroker transaction **");
}
catch(Exception e)
{
logger.error(msg, e);
}
}
}
try
{
doDelete(obj, ignoreReferences);
}
finally
{
markedForDelete.clear();
}
} | [
"Deletes the concrete representation of the specified object in the underlying\npersistence system. This method is intended for use in top-level api or\nby internal calls.\n\n@param obj The object to delete.\n@param ignoreReferences With this flag the automatic deletion/unlinking\nof references can be suppressed (independent of the used auto-delete setting in metadata),\nexcept {@link org.apache.ojb.broker.metadata.SuperReferenceDescriptor}\nthese kind of reference (descriptor) will always be performed. If <em>true</em>\nall \"normal\" referenced objects will be ignored, only the specified object is handled.\n@throws PersistenceBrokerException"
] | [
"Sets the whole day flag.\n@param isWholeDay flag, indicating if the event lasts whole days.",
"Get the list of active tasks from the server.\n\n@return List of tasks\n@see <a href=\"https://console.bluemix.net/docs/services/Cloudant/api/active_tasks.html\">\nActive tasks</a>",
"The file we are working with has a byte order mark. Skip this and try again to read the file.\n\n@param stream schedule data\n@param length length of the byte order mark\n@param charset charset indicated by byte order mark\n@return ProjectFile instance",
"Start the socket server and waiting for finished\n\n@throws InterruptedException thread interrupted",
"Creates a new Box Developer Edition connection with App User token levaraging BoxConfig.\n@param userId the user ID to use for an App User.\n@param boxConfig box configuration settings object\n@return a new instance of BoxAPIConnection.",
"Deletes all of the Directories in root that match the FileFilter\n\n@param root\n@param filter",
"Reset the Where object so it can be re-used.",
"Returns the z-coordinate of a vertex position.\n\n@param vertex the vertex index\n@return the z coordinate",
"Appends the given string to the given StringBuilder, replacing '&',\n'<' and '>' by their respective HTML entities.\n\n@param out\nThe StringBuilder to append to.\n@param value\nThe string to append.\n@param offset\nThe character offset into value from where to start"
] |
public DynamicReportBuilder setProperty(String name, String value) {
this.report.setProperty(name, value);
return this;
} | [
"Adds a property to report design, this properties are mostly used by\nexporters to know if any specific configuration is needed\n\n@param name\n@param value\n@return A Dynamic Report Builder"
] | [
"Sets all padding for all cells in the row 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",
"Use this API to update nspbr6.",
"Provisions a new app user in an enterprise using Box Developer Edition.\n@param api the API connection to be used by the created user.\n@param name the name of the user.\n@return the created user's info.",
"Use this API to add snmpuser resources.",
"Use this API to fetch auditnslogpolicy_vpnvserver_binding resources of given name .",
"Use this API to fetch appfwpolicylabel_policybinding_binding resources of given name .",
"Add an exception to a calendar.\n\n@param parentNode parent node\n@param exception calendar exceptions",
"Acquires a read lock on a specific key.\n@param key The key to lock\n@param timeout in milliseconds; -1 means wait indefinitely, 0 means no wait.",
"Increment the version info associated with the given node\n\n@param node The node"
] |
public void flush() throws IOException {
checkMutable();
long startTime = System.currentTimeMillis();
channel.force(true);
long elapsedTime = System.currentTimeMillis() - startTime;
LogFlushStats.recordFlushRequest(elapsedTime);
logger.debug("flush time " + elapsedTime);
setHighWaterMark.set(getSizeInBytes());
logger.debug("flush high water mark:" + highWaterMark());
} | [
"Commit all written data to the physical disk\n\n@throws IOException any io exception"
] | [
"Get a log file and last relevant date, and check if the log file is relevant\n@param currentLogFile The log file\n@param lastRelevantDate The last date which files should be keeping since\n@return false if the file should be deleted, true if it does not.",
"Use this API to rename a nsacl6 resource.",
"Compute eigenvalues. This is a routine not in ATLAS, but in the original\nLAPACK.",
"Rethrows platform specific OperationCanceledExceptions and unwraps OperationCanceledErrors. Does nothing for any other type of Throwable.",
"Returns iterable containing assignments for this single legal hold policy.\n@param fields the fields to retrieve.\n@return an iterable containing assignments for this single legal hold policy.",
"Obtain the annotation associated with this type descriptor of the specified type.\n@param annotationType the annotation type\n@return the annotation, or {@code null} if no such annotation exists on this type descriptor",
"Issue the database statements to drop the table associated with a dao.\n\n@param dao\nAssociated dao.\n@return The number of statements executed to do so.",
"Parse a duration in minutes form a number of hours.\n\n@param value String representation\n@return Integer instance",
"Inserts the result of the migration into the migration table\n\n@param migration the migration that was executed\n@param wasSuccessful indicates if the migration was successful or not"
] |
public void addCell(TableLayoutCell cell) {
GridBagConstraints constraints = cell.getConstraints();
constraints.insets = new Insets(cellpadding, cellpadding, cellpadding, cellpadding);
add(cell.getComponent(), constraints);
} | [
"Adds a new cell to the current grid\n@param cell the td component"
] | [
"Returns the given collection persister for the inverse side in case the given persister represents the main side\nof a bi-directional many-to-many association.\n\n@param mainSidePersister the collection persister on the main side of a bi-directional many-to-many association\n@return the collection persister for the inverse side of the given persister or {@code null} in case it\nrepresents the inverse side itself or the association is uni-directional",
"given the groupId, and 2 string arrays, adds the name-responses pair to the table_override\n\n@param groupId ID of group\n@param methodName name of method\n@param className name of class\n@throws Exception exception",
"Checks length and compare order of field names with declared PK fields in metadata.",
"Sends the error to responder.",
"Use this API to Shutdown shutdown.",
"Log a fatal message with a throwable.",
"Additional bean deployment archives are used for extentions, synthetic annotated types and beans which do not come from a bean archive.\n\n@param beanClass\n@return the additional bean deployment archive",
"Write a double attribute.\n\n@param name attribute name\n@param value attribute value",
"returns controller if a new device is found"
] |
public static String encode(String value) throws UnsupportedEncodingException {
if (isNullOrEmpty(value)) return value;
return URLEncoder.encode(value, URL_ENCODING);
} | [
"used for encoding queries or form data"
] | [
"Removes the value connected to the given key\nfrom all levels of the cache. Will not throw an\nexception on fail.\n\n@param cacheKey",
"Assigns this retention policy to a metadata template, optionally with certain field values.\n@param templateID the ID of the metadata template to apply to.\n@param fieldFilters optional field value filters.\n@return info about the created assignment.",
"Use this API to fetch gslbvserver_spilloverpolicy_binding resources of given name .",
"This method is used to recreate the hierarchical structure of the\nproject file from scratch. The method sorts the list of all tasks,\nthen iterates through it creating the parent-child structure defined\nby the outline level field.",
"Create the index file that sets up the frameset.\n@param outputDirectory The target directory for the generated file(s).",
"Returns a new color with a new value of the specified HSL\ncomponent.",
"Cancel old waiting jobs.\n\n@param starttimeThreshold threshold for start time\n@param checkTimeThreshold threshold for last check time\n@param message the error message",
"Retrieve an activity status.\n\n@param mpxj MPXJ Task instance\n@return activity status",
"This method is called to alert project listeners to the fact that\na resource has been read from a project file.\n\n@param resource resource instance"
] |
public boolean addSsextension(String ssExt) {
if (this.ssextensions == null) {
this.ssextensions = new ArrayList<String>();
}
return this.ssextensions.add(ssExt);
} | [
"Add an additional SSExtension\n@param ssExt the ssextension to set"
] | [
"The sniffing Loggers are some special Loggers, whose level will be set to TRACE forcedly.\n@param logger",
"Sets the bounds of a UIObject, moving and sizing to match the\nbounds specified. Currently used for the itemhover and useful\nfor other absolutely positioned elements.",
"Returns the list of Solr fields a search result must have to initialize the gallery search result correctly.\n@return the list of Solr fields.",
"Update an existing feature. Made package private for testing purposes.\n\n@param feature feature to update\n@throws LayerException oops",
"Check that an array only contains null elements.\n@param values, can't be null\n@return",
"Little helper function that recursivly deletes a directory.\n\n@param dir The directory",
"Gets a method based on data in the override_db table\n\n@param overrideId ID of override\n@return Method found",
"Append the html-code to finish a html mail message to the given buffer.\n\n@param buffer The StringBuffer to add the html code to.",
"Sends a dummy statement to the server to keep the connection alive\n@param connection Connection handle to perform activity on\n@return true if test query worked, false otherwise"
] |
public synchronized void persistProperties() throws IOException {
beginPersistence();
// Read the properties file into memory
// Shouldn't be so bad - it's a small file
List<String> content = readFile(propertiesFile);
BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(propertiesFile), StandardCharsets.UTF_8));
try {
for (String line : content) {
String trimmed = line.trim();
if (trimmed.length() == 0) {
bw.newLine();
} else {
Matcher matcher = PROPERTY_PATTERN.matcher(trimmed);
if (matcher.matches()) {
final String key = cleanKey(matcher.group(1));
if (toSave.containsKey(key) || toSave.containsKey(key + DISABLE_SUFFIX_KEY)) {
writeProperty(bw, key, matcher.group(2));
toSave.remove(key);
toSave.remove(key + DISABLE_SUFFIX_KEY);
} else if (trimmed.startsWith(COMMENT_PREFIX)) {
// disabled user
write(bw, line, true);
}
} else {
write(bw, line, true);
}
}
}
endPersistence(bw);
} finally {
safeClose(bw);
}
} | [
"Saves changes in properties file. It reads the property file into memory, modifies it and saves it back to the file.\n\n@throws IOException"
] | [
"Exports json encoded content to CrashReport object\n\n@param json valid json body.\n@return new instance of CrashReport",
"Retrieves an integer value from the extended data.\n\n@param type Type identifier\n@return integer value",
"Obtains a local date in Ethiopic calendar system from the\nera, year-of-era, month-of-year and day-of-month fields.\n\n@param era the Ethiopic era, not null\n@param yearOfEra the year-of-era\n@param month the month-of-year\n@param dayOfMonth the day-of-month\n@return the Ethiopic local date, not null\n@throws DateTimeException if unable to create the date\n@throws ClassCastException if the {@code era} is not a {@code EthiopicEra}",
"Method indicating whether a day is a working or non-working day.\n\n@param day required day\n@return true if this is a working day",
"Decode a code from the stream s using huffman table h. Return the symbol or\na negative value if there is an error. If all of the lengths are zero, i.e.\nan empty code, or if the code is incomplete and an invalid code is received,\nthen -9 is returned after reading MAXBITS bits.\n\nFormat notes:\n\n- The codes as stored in the compressed data are bit-reversed relative to\na simple integer ordering of codes of the same lengths. Hence below the\nbits are pulled from the compressed data one at a time and used to\nbuild the code value reversed from what is in the stream in order to\npermit simple integer comparisons for decoding.\n\n- The first code for the shortest length is all ones. Subsequent codes of\nthe same length are simply integer decrements of the previous code. When\nmoving up a length, a one bit is appended to the code. For a complete\ncode, the last code of the longest length will be all zeros. To support\nthis ordering, the bits pulled during decoding are inverted to apply the\nmore \"natural\" ordering starting with all zeros and incrementing.\n\n@param h Huffman table\n@return status code",
"Tells it to process the submatrix at the next split. Should be called after the\ncurrent submatrix has been processed.",
"The way calendars are stored in an MPP14 file means that there\ncan be forward references between the base calendar unique ID for a\nderived calendar, and the base calendar itself. To get around this,\nwe initially populate the base calendar name attribute with the\nbase calendar unique ID, and now in this method we can convert those\nID values into the correct names.\n\n@param baseCalendars list of calendars and base calendar IDs\n@param map map of calendar ID values and calendar objects",
"This method is called to format a constraint type.\n\n@param type constraint type\n@return formatted constraint type",
"Return the number of days between startDate and endDate given the\nspecific daycount convention.\n\n@param startDate The start date given as a {@link org.threeten.bp.LocalDate}.\n@param endDate The end date given as a {@link org.threeten.bp.LocalDate}.\n@param convention A convention string.\n@return The number of days within the given period."
] |
@NonNull
@SuppressWarnings({"WeakerAccess", "unused"}) // For library users
public Searcher reset() {
lastResponsePage = 0;
lastRequestPage = 0;
lastResponseId = 0;
endReached = false;
clearFacetRefinements();
cancelPendingRequests();
numericRefinements.clear();
return this;
} | [
"Resets the helper's state.\n\n@return this {@link Searcher} for chaining."
] | [
"Use this API to fetch vpntrafficpolicy_aaagroup_binding resources of given name .",
"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",
"Use this API to fetch lbvserver_scpolicy_binding resources of given name .",
"Get a property as a string or throw an exception.\n\n@param key the property name",
"Process StepStartedEvent. New step will be created and added to\nstepStorage.\n\n@param event to process",
"Main method for testing fetching",
"Set a Java classname path to ignore when printing stack traces\n@param classToIgnoreInTraces The class name (with packages, etc) to ignore.\n@return this",
"Sets the specified short 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",
"Use this API to fetch the statistics of all appfwprofile_stats resources that are configured on netscaler."
] |
public static float smoothPulse(float a1, float a2, float b1, float b2, float x) {
if (x < a1 || x >= b2)
return 0;
if (x >= a2) {
if (x < b1)
return 1.0f;
x = (x - b1) / (b2 - b1);
return 1.0f - (x*x * (3.0f - 2.0f*x));
}
x = (x - a1) / (a2 - a1);
return x*x * (3.0f - 2.0f*x);
} | [
"A smoothed pulse function. A cubic function is used to smooth the step between two thresholds.\n@param a1 the lower threshold position for the start of the pulse\n@param a2 the upper threshold position for the start of the pulse\n@param b1 the lower threshold position for the end of the pulse\n@param b2 the upper threshold position for the end of the pulse\n@param x the input parameter\n@return the output value"
] | [
"Find the index of the first matching element in the list\n@param element the element value to find\n@return the index of the first matching element, or <code>-1</code> if none found",
"Sets the day of the month.\n@param day the day to set.",
"Calculates the legend positions and which legend title should be displayed or not.\n\nImportant: the LegendBounds in the _Models should be set and correctly calculated before this\nfunction is called!\n@param _Models The graph data which should have the BaseModel class as parent class.\n@param _StartX Left starting point on the screen. Should be the absolute pixel value!\n@param _Paint The correctly set Paint which will be used for the text painting in the later process",
"Converts an object to an XML file.\n\n@param object The object to convert.\n@param fileName The filename where to save it to.\n@throws FileNotFoundException On error.",
"RReturns the entity type of the id like \"item\" or \"property\"\n\n@param id\nthe identifier of the entity, such as \"Q42\"\n@throws IllegalArgumentException\nif the id is invalid",
"1-D Integer array to double array.\n\n@param array Integer array.\n@return Double array.",
"Helper function to bind script bundler to various targets",
"Retrieve a child that matches the given absolute path, starting from the current node.\n\n@param nodePath The path from the object root to the requested child node.\n@return The requested child node or <code>null</code>.",
"Closes off this connection\n@param connection to close"
] |
public PathElement getLastElement() {
final List<PathElement> list = pathAddressList;
return list.size() == 0 ? null : list.get(list.size() - 1);
} | [
"Gets the last element in the address.\n\n@return the element, or {@code null} if {@link #size()} is zero."
] | [
"generate random velocities in the given range\n@return",
"Use this API to fetch authenticationlocalpolicy_authenticationvserver_binding resources of given name .",
"Updates all inverse associations managed by a given entity.",
"Use this API to fetch the statistics of all service_stats resources that are configured on netscaler.",
"Plots the rotated trajectory, spline and support points.",
"If you register a CustomExpression with the name \"customExpName\", then this will create the text needed\nto invoke it in a JRDesignExpression\n\n@param customExpName\n@param usePreviousFieldValues\n@return",
"Sets the character translator for all cells in the table.\nIt will also remove any other translator set.\nNothing will happen if the argument is null.\n@param charTranslator translator\n@return this to allow chaining",
"Use this API to fetch all the inat resources that are configured on netscaler.",
"Run the configured crawl. This method blocks until the crawl is done.\n\n@return the CrawlSession once the crawl is done."
] |
@Override
public void stop()
{
synchronized (killHook)
{
jqmlogger.info("JQM engine " + this.node.getName() + " has received a stop order");
// Kill hook should be removed
try
{
if (!Runtime.getRuntime().removeShutdownHook(killHook))
{
jqmlogger.error("The engine could not unregister its shutdown hook");
}
}
catch (IllegalStateException e)
{
// This happens if the stop sequence is initiated by the shutdown hook itself.
jqmlogger.info("Stop order is due to an admin operation (KILL/INT)");
}
}
// Stop pollers
int pollerCount = pollers.size();
for (QueuePoller p : pollers.values())
{
p.stop();
}
// Scheduler
this.scheduler.stop();
// Jetty is closed automatically when all pollers are down
// Wait for the end of the world
if (pollerCount > 0)
{
try
{
this.ended.acquire();
}
catch (InterruptedException e)
{
jqmlogger.error("interrupted", e);
}
}
// Send a KILL signal to remaining job instances, and wait some more.
if (this.getCurrentlyRunningJobCount() > 0)
{
this.runningJobInstanceManager.killAll();
try
{
Thread.sleep(10000);
}
catch (InterruptedException e)
{
jqmlogger.error("interrupted", e);
}
}
jqmlogger.debug("Stop order was correctly handled. Engine for node " + this.node.getName() + " has stopped.");
} | [
"Gracefully stop the engine"
] | [
"Adds an HTTP header to this request.\n@param key the header key.\n@param value the header value.",
"Awaits at most 5 minutes until all pods meets the given predicate.\n\n@param filter used to wait to detect that a pod is up and running.",
"Use this API to update clusternodegroup resources.",
"Use this API to fetch all the responderpolicy resources that are configured on netscaler.",
"Accessor method used to retrieve a Number instance representing the\ncontents of an individual field. If the field does not exist in the\nrecord, null is returned.\n\n@param field the index number of the field to be retrieved\n@return the value of the required field\n@throws MPXJException normally thrown when parsing fails",
"Provides the scrollableList implementation for page scrolling\n@return {@link LayoutScroller.ScrollableList} implementation, passed to {@link LayoutScroller}\nfor the processing the scrolling",
"Converts the bytes that make up an internet address into the corresponding integer value to make\nit easier to perform bit-masking operations on them.\n\n@param address an address whose integer equivalent is desired\n\n@return the integer corresponding to that address",
"Calculate conversion map.\n\n@param inRange Input range.\n@param outRange Output range.\n@param map Conversion map.",
"Update the Target Filter of the ImporterService.\nApply the induce modifications on the links of the ImporterService\n\n@param serviceReference"
] |
public void set1Value(int index, String newValue) {
try {
value.set( index, newValue );
}
catch (IndexOutOfBoundsException e) {
Log.e(TAG, "X3D MFString set1Value(int index, ...) out of bounds." + e);
}
catch (Exception e) {
Log.e(TAG, "X3D MFString set1Value(int index, ...) exception " + e);
}
} | [
"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"
] | [
"Process each regex group matched substring of the given CharSequence. If the closure\nparameter takes one argument, an array with all match groups is passed to it.\nIf the closure takes as many arguments as there are match groups, then each\nparameter will be one match group.\n\n@param self the source CharSequence\n@param regex a Regex CharSequence\n@param closure a closure with one parameter or as much parameters as groups\n@return the source CharSequence\n@see #eachMatch(String, String, groovy.lang.Closure)\n@since 1.8.2",
"return the list of FormInputs that match this element\n\n@param element\n@return",
"cleanup tx and prepare for reuse",
"Writes all auxiliary triples that have been buffered recently. This\nincludes OWL property restrictions but it also includes any auxiliary\ntriples required by complex values that were used in snaks.\n\n@throws RDFHandlerException\nif there was a problem writing the RDF triples",
"Gets the positive integer.\n\n@param number the number\n@return the positive integer",
"Removes all documents from the collection that match the given query filter. If no documents\nmatch, the collection is not modified.\n\n@param filter the query filter to apply the the delete operation\n@return the result of the remove many operation",
"Size of a queue.\n\n@param jedis\n@param queueName\n@return",
"Create new logging action\nThis method check if there is an old instance for this thread-local\nIf not - Initialize new instance and set it as this thread-local's instance\n@param logger\n@param auditor\n@param instance\n@return whether new instance was set to thread-local",
"Returns a non-validating XML parser. The parser ignores both DTDs and XSDs.\n\n@return An XML parser in the form of a DocumentBuilder"
] |
private static Map<String, ServerGroupDeploymentPlanResult> buildServerGroupResults(Map<UUID, DeploymentActionResult> deploymentActionResults) {
Map<String, ServerGroupDeploymentPlanResult> serverGroupResults = new HashMap<String, ServerGroupDeploymentPlanResult>();
for (Map.Entry<UUID, DeploymentActionResult> entry : deploymentActionResults.entrySet()) {
UUID actionId = entry.getKey();
DeploymentActionResult actionResult = entry.getValue();
Map<String, ServerGroupDeploymentActionResult> actionResultsByServerGroup = actionResult.getResultsByServerGroup();
for (ServerGroupDeploymentActionResult serverGroupActionResult : actionResultsByServerGroup.values()) {
String serverGroupName = serverGroupActionResult.getServerGroupName();
ServerGroupDeploymentPlanResultImpl sgdpr = (ServerGroupDeploymentPlanResultImpl) serverGroupResults.get(serverGroupName);
if (sgdpr == null) {
sgdpr = new ServerGroupDeploymentPlanResultImpl(serverGroupName);
serverGroupResults.put(serverGroupName, sgdpr);
}
for (Map.Entry<String, ServerUpdateResult> serverEntry : serverGroupActionResult.getResultByServer().entrySet()) {
String serverName = serverEntry.getKey();
ServerUpdateResult sud = serverEntry.getValue();
ServerDeploymentPlanResultImpl sdpr = (ServerDeploymentPlanResultImpl) sgdpr.getServerResult(serverName);
if (sdpr == null) {
sdpr = new ServerDeploymentPlanResultImpl(serverName);
sgdpr.storeServerResult(serverName, sdpr);
}
sdpr.storeServerUpdateResult(actionId, sud);
}
}
}
return serverGroupResults;
} | [
"Builds the data structures that show the effects of the plan by server group"
] | [
"Checks if a property's type is valid to be included in the report.\n@param _property the property.\n@return true if the property is is of a valid type.",
"Tells it to process the submatrix at the next split. Should be called after the\ncurrent submatrix has been processed.",
"Closes off this connection\n@param connection to close",
"Load all string recognize.",
"read all brokers in the zookeeper\n\n@param zkClient zookeeper client\n@return all brokers",
"Throws an IllegalArgumentException when the given value is not true.\n@param value the value to assert if true\n@param message the message to display if the value is false\n@return the value",
"Obtain a connection asynchronously by queueing a request to obtain a connection in a separate thread.\n\nUse as follows:<p>\nFuture<Connection> result = pool.getAsyncConnection();<p>\n... do something else in your application here ...<p>\nConnection connection = result.get(); // get the connection<p>\n\n@return A Future task returning a connection.",
"We need to distinguish the case where we're newly available and the case\nwhere we're already available. So we check the node status before we\nupdate it and return it to the caller.\n\n@param isAvailable True to set to available, false to make unavailable\n\n@return Previous value of isAvailable",
"Returns all the retention policies.\n@param api the API connection to be used by the resource.\n@param fields the fields to retrieve.\n@return an iterable with all the retention policies."
] |
public void insertBefore(Vertex vtx, Vertex next) {
vtx.prev = next.prev;
if (next.prev == null) {
head = vtx;
} else {
next.prev.next = vtx;
}
vtx.next = next;
next.prev = vtx;
} | [
"Inserts a vertex into this list before another specificed vertex."
] | [
"Determines if entry is accepted. For normal usage, this means confirming that the key is\nneeded. For orphan usage, this simply means confirming the key belongs to the node.\n\n@param key\n@return true iff entry is accepted.",
"Update the installed identity using the modified state from the modification.\n\n@param name the identity name\n@param modification the modification\n@param state the installation state\n@return the installed identity",
"Convert event type.\n\n@param eventType the event type\n@return the event enum type",
"Determine which type of percent complete is used on on this task,\nand calculate the required value.\n\n@param row task data\n@return percent complete value",
"Add server redirect to a profile, using current active ServerGroup\n\n@param region region\n@param srcUrl source URL\n@param destUrl destination URL\n@param hostHeader host header\n@param profileId profile ID\n@return ID of added ServerRedirect\n@throws Exception exception",
"Convert a color to an angle.\n\n@param color The RGB value of the color to \"find\" on the color wheel.\n\n@return The angle (in rad) the \"normalized\" color is displayed on the\ncolor wheel.",
"Convert MPX day index to Day instance.\n\n@param day day index\n@return Day instance",
"Returns a new intern odmg-transaction for the current database.",
"Generate a new check box with the provided date and check state.\n@param date date for the check box.\n@param checkState the initial check state.\n@return the created check box"
] |
public void resetQuotaAndRecoverEnforcement() {
for(Integer nodeId: nodeIds) {
boolean quotaEnforcement = mapNodeToQuotaEnforcingEnabled.get(nodeId);
adminClient.metadataMgmtOps.updateRemoteMetadata(Arrays.asList(nodeId),
MetadataStore.QUOTA_ENFORCEMENT_ENABLED_KEY,
Boolean.toString(quotaEnforcement));
}
for(String storeName: storeNames) {
adminClient.quotaMgmtOps.rebalanceQuota(storeName);
}
} | [
"After cluster management operations, i.e. reset quota and recover quota\nenforcement settings"
] | [
"Creates a single property declaration.\n@param property Property name.\n@param term Property value.\n@return The resulting declaration.",
"return a HashMap with all properties, name as key, value as value\n@return the properties",
"FOR internal use. This method was called after the external transaction was completed.\n\n@see javax.transaction.Synchronization",
"Sets whether an individual list value is selected.\n\n@param value the value of the item to be selected or unselected\n@param selected <code>true</code> to select the item",
"Sets the stream for a resource.\nThis function allows you to provide a stream that is already open to\nan existing resource. It will throw an exception if that resource\nalready has an open stream.\n@param s InputStream currently open stream to use for I/O.",
"Populates the bean by mapping the processed columns to the fields of the bean.\n\n@param resultBean\nthe bean to populate\n@param nameMapping\nthe name mappings\n@return the populated bean\n@throws SuperCsvReflectionException\nif there was a reflection exception while populating the bean",
"Sets the ojbQuery, needed only as long we\ndon't support the soda constraint stuff.\n@param ojbQuery The ojbQuery to set",
"Parses a String email address to an IMAP address string.",
"makes object obj persistent to the Objectcache under the key oid."
] |
private void writeTasks(Project project)
{
Project.Tasks tasks = m_factory.createProjectTasks();
project.setTasks(tasks);
List<Project.Tasks.Task> list = tasks.getTask();
for (Task task : m_projectFile.getTasks())
{
list.add(writeTask(task));
}
} | [
"This method writes task data to an MSPDI file.\n\n@param project Root node of the MSPDI file"
] | [
"Saves a matrix to disk using Java binary serialization.\n\n@param A The matrix being saved.\n@param fileName Name of the file its being saved at.\n@throws java.io.IOException",
"Returns real unquoted value for a DisplayValue\n@param key\n@return",
"1-D Double array to integer array.\n\n@param array Double array.\n@return Integer array.",
"Starts this EventStream and begins long polling the API.\n@throws IllegalStateException if the EventStream is already started.",
"Return true if the expression is a constructor call on a class that matches the supplied.\n@param expression - the expression\n@param classNamePattern - the possible List of class names\n@return as described",
"Use this API to fetch auditnslogpolicy_systemglobal_binding resources of given name .",
"Is invoked on the leaf deletion only.\n\n@param left left page.\n@param right right page.\n@return true if the left page ought to be merged with the right one.",
"Update the list of buildpacks installed on an app\n\n@param appName See {@link #listApps} for a list of apps that can be used.\n@param buildpacks the new list of buildpack names or URLs.",
"Executes a batch plan.\n\n@param batchId Used as the ID of the batch plan. This allows related\ntasks on client- & server-side to pretty print messages in a\nmanner that debugging can track specific batch plans across the\ncluster.\n@param batchPlan The batch plan..."
] |
protected static String jacksonObjectToString(Object object) {
try {
return mapper.writeValueAsString(object);
} catch (JsonProcessingException e) {
logger.error("Failed to serialize JSON data: " + e.toString());
return null;
}
} | [
"Serializes the given object in JSON and returns the resulting string. In\ncase of errors, null is returned. In particular, this happens if the\nobject is not based on a Jackson-annotated class. An error is logged in\nthis case.\n\n@param object\nobject to serialize\n@return JSON serialization or null"
] | [
"Returns Task field name of supplied code no.\n\n@param key - the code no of required Task field\n@return - field name",
"Moves everything up so that the specified shift or latch character can be inserted.\n\n@param position the position beyond which everything needs to be shifted\n@param c the latch or shift character to insert at the specified position, after everything has been shifted",
"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",
"Get information about this database.\n\n@return DbInfo encapsulating the database info\n@see <a\nhref=\"https://console.bluemix.net/docs/services/Cloudant/api/database.html#getting-database-details\"\ntarget=\"_blank\">Databases - read</a>",
"Copies entries in the source map to target map.\n\n@param source source map\n@param target target map",
"dataType in weight descriptors and input descriptors is used to describe storage",
"Creates a Document that can be passed to the MongoDB batch insert function",
"An extension point so we can control how the query gets executed.\nThis exists for testing purposes, not because we believe it will\nactually be used for real.",
"Invoke an operation on an MBean by name.\nNote that only basic data types are supported for parameter values.\n@param operationName the operation name (can be URL-encoded).\n@param parameterMap the {@link Map} of parameter names and value arrays.\n@return the returned value from the operation.\n@throws JMException Java Management Exception\n@throws UnsupportedEncodingException if the encoding is not supported."
] |
public SelectStatement getPreparedSelectStatement(Query query, ClassDescriptor cld)
{
SelectStatement sql = new SqlSelectStatement(m_platform, cld, query, logger);
if (logger.isDebugEnabled())
{
logger.debug("SQL:" + sql.getStatement());
}
return sql;
} | [
"generate a select-Statement according to query\n\n@param query the Query\n@param cld the ClassDescriptor"
] | [
"Adds the headers.\n\n@param builder\nthe builder\n@param headerMap\nthe header map",
"Checks if there's exactly one option that exists among all opts.\n\n@param options OptionSet to checked\n@param opts List of options to be checked\n@throws VoldemortException",
"If needed, destroy the remaining conversation contexts after an HTTP session was invalidated within the current request.\n\n@param request",
"Returns a string that represents a valid Solr query range.\n\n@param from Lower bound of the query range.\n@param to Upper bound of the query range.\n@return String that represents a Solr query range.",
"Expensive. Creates the plan for the specific settings.",
"Removes all of the markers from the map.",
"Use this API to update systemuser resources.",
"Removes all pending broadcasts\n\n@param sessionIds to remove broadcast for (or null for all sessions)",
"Gets a list of any tasks on this file with requested fields.\n\n@param fields optional fields to retrieve for this task.\n@return a list of tasks on this file."
] |
public static ConsistencyLevel determineConsistency(Map<Value, Set<ClusterNode>> versionNodeSetMap,
int replicationFactor) {
boolean fullyConsistent = true;
Value latestVersion = null;
for (Map.Entry<Value, Set<ClusterNode>> versionNodeSetEntry : versionNodeSetMap.entrySet()) {
Value value = versionNodeSetEntry.getKey();
if (latestVersion == null) {
latestVersion = value;
} else if (value.isTimeStampLaterThan(latestVersion)) {
latestVersion = value;
}
Set<ClusterNode> nodeSet = versionNodeSetEntry.getValue();
fullyConsistent = fullyConsistent && (nodeSet.size() == replicationFactor);
}
if (fullyConsistent) {
return ConsistencyLevel.FULL;
} else {
// latest write consistent, effectively consistent
if (latestVersion != null && versionNodeSetMap.get(latestVersion).size() == replicationFactor) {
return ConsistencyLevel.LATEST_CONSISTENT;
}
// all other states inconsistent
return ConsistencyLevel.INCONSISTENT;
}
} | [
"Determine the consistency level of a key\n\n@param versionNodeSetMap A map that maps version to set of PrefixNodes\n@param replicationFactor Total replication factor for the set of clusters\n@return ConsistencyLevel Enum"
] | [
"Join the Collection of Strings using the specified delimter and optionally quoting each\n\n@param s\nThe String collection\n@param delimiter\nthe delimiter String\n@param doQuote\nwhether or not to quote the Strings\n@return The joined String",
"Determines total number of partition-stores moved across zones.\n\n@return number of cross zone partition-store moves",
"Rewrites the file passed to 'this' constructor so that the actual line numbers match the recipe passed to 'this'\nconstructor.",
"Retrieves the Material Shader ID associated with the\ngiven shader template class.\n\nA shader template is capable of generating multiple variants\nfrom a single shader source. The exact vertex and fragment\nshaders are generated by GearVRF based on the lights\nbeing used and the material attributes. you may subclass\nGVRShaderTemplate to create your own shader templates.\n\n@param shaderClass shader class to find (subclass of GVRShader)\n@return GVRShaderId associated with that shader template\n@see GVRShaderTemplate GVRShader",
"Add nodes to the workers list\n\n@param nodeIds list of node ids.",
"This method allows a predecessor relationship to be removed from this\ntask instance. It will only delete relationships that exactly match the\ngiven targetTask, type and lag time.\n\n@param targetTask the predecessor task\n@param type relation type\n@param lag relation lag\n@return returns true if the relation is found and removed",
"Returns the simplified name of the type of the specified object.",
"Helper. Current transaction is committed in some cases.",
"Creates a curator built using Application's zookeeper connection string. Root path will start\nat Fluo application chroot."
] |
private void handleHidden(FormInput input) {
String text = input.getInputValues().iterator().next().getValue();
if (null == text || text.length() == 0) {
return;
}
WebElement inputElement = browser.getWebElement(input.getIdentification());
JavascriptExecutor js = (JavascriptExecutor) browser.getWebDriver();
js.executeScript("arguments[0].setAttribute(arguments[1], arguments[2]);", inputElement,
"value", text);
} | [
"Enter information into the hidden input field.\n\n@param input The input to enter into the hidden field."
] | [
"Returns a UTMDetail object which consists of UTM parameters like source, medium & campaign\n@return The {@link UTMDetail} object",
"Checks whether the compilation has been canceled and reports the given work increment to the compiler progress.",
"Submit a command to the server.\n\n@param command The CLI command\n@return The DMR response as a ModelNode\n@throws CommandFormatException\n@throws IOException",
"LV morphology helper functions",
"changes an existing property with the same name, or adds a new one\n@param key property name with which the specified value is to be\nassociated\n@param value value to be associated with the specified property name\n@return the previous value associated with property name, or null if\nthere was no mapping for property name. (A null return can also\nindicate that the map previously associated null with key.)",
"Bean types of a session bean.",
"Installs a provider either in the scope or the pool of unbound providers.\n\n@param clazz the class for which to install the provider.\n@param bindingName the name, possibly {@code null}, for which to install the scoped provider.\n@param internalProvider the internal provider to install.\n@param isBound whether or not the provider is bound to the scope or belongs to the pool of unbound providers.\n@param isTestProvider whether or not is a test provider, installed through a Test Module that should override\nexisting providers for the same class-bindingname.\n@param <T> the type of {@code clazz}.\n\nNote to maintainers : we don't use this method directly, both {@link #installBoundProvider(Class, String, InternalProviderImpl, boolean)}\nand {@link #installUnBoundProvider(Class, String, InternalProviderImpl)}\nare a facade of this method and make the calls more clear.",
"Set the parent from which this week is derived.\n\n@param parent parent week",
"Allows direct access to the Undertow.Builder for custom configuration\n\n@param serverConfigurationFunction the serverConfigurationFunction"
] |
public static boolean containsOnlyNull(Object... values){
for(Object o : values){
if(o!= null){
return false;
}
}
return true;
} | [
"Check that an array only contains null elements.\n@param values, can't be null\n@return"
] | [
"Clean up the environment object for the given storage engine",
"Convert an object to another object with given type\n\n@param <T>\n@param source\nobject to convert\n@param typeReference\nreference to {@link java.lang.reflect.Type}\n@return the converted object if conversion failed\n@throws ConverterException",
"Use this API to delete cacheselector of given name.",
"Begin writing a named list attribute.\n\n@param name attribute name",
"Returns the orthogonal V matrix.\n\n@param V If not null then the results will be stored here. Otherwise a new matrix will be created.\n@return The extracted Q matrix.",
"Returns a BoxStoragePolicyAssignment information.\n@param api the API connection to be used by the resource.\n@param resolvedForType the assigned entity type for the storage policy.\n@param resolvedForID the assigned entity id for the storage policy.\n@return information about this {@link BoxStoragePolicyAssignment}.",
"handle white spaces.",
"Deserialize a javascript design document file to a DesignDocument object.\n\n@param file the design document javascript file (UTF-8 encoded)\n@return {@link DesignDocument}\n@throws FileNotFoundException if the file does not exist or cannot be read",
"Use this API to fetch all the cacheobject resources that are configured on netscaler.\nThis uses cacheobject_args which is a way to provide additional arguments while fetching the resources."
] |
public static void log(final String templateName, final Template template, final Values values) {
new ValuesLogger().doLog(templateName, template, values);
} | [
"Log the values for the provided template.\n\n@param templateName the name of the template the values came from\n@param template the template object\n@param values the resultant values"
] | [
"Triggers expansion of the parent.",
"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",
"Commits the working copy.\n\n@param commitMessage@return The commit info upon successful operation.\n@throws IOException On IO of SVN failure",
"Removes all the given tags from the document.\n\n@param dom the document object.\n@param tagName the tag name, examples: script, style, meta\n@return the changed dom.",
"response simple String\n\n@param response\n@param obj",
"Set the Log4j appender.\n\n@param appender the log4j appender",
"This essentially ensures that we only store a single Vertex for each unique \"Set\" of tags.",
"Hide the following channels.\n@param channels The names of the channels to hide.\n@return this",
"Saves the favorites.\n\n@param favorites the list of favorites to save\n@throws CmsException if something goes wrong"
] |
@Override
public ResourceStorageLoadable getOrCreateResourceStorageLoadable(final StorageAwareResource resource) {
try {
final ResourceStorageProviderAdapter stateProvider = IterableExtensions.<ResourceStorageProviderAdapter>head(Iterables.<ResourceStorageProviderAdapter>filter(resource.getResourceSet().eAdapters(), ResourceStorageProviderAdapter.class));
if ((stateProvider != null)) {
final ResourceStorageLoadable inputStream = stateProvider.getResourceStorageLoadable(resource);
if ((inputStream != null)) {
return inputStream;
}
}
InputStream _xifexpression = null;
boolean _exists = resource.getResourceSet().getURIConverter().exists(this.getBinaryStorageURI(resource.getURI()), CollectionLiterals.<Object, Object>emptyMap());
if (_exists) {
_xifexpression = resource.getResourceSet().getURIConverter().createInputStream(this.getBinaryStorageURI(resource.getURI()));
} else {
InputStream _xblockexpression = null;
{
final AbstractFileSystemAccess2 fsa = this.getFileSystemAccess(resource);
final String outputRelativePath = this.computeOutputPath(resource);
_xblockexpression = fsa.readBinaryFile(outputRelativePath);
}
_xifexpression = _xblockexpression;
}
final InputStream inputStream_1 = _xifexpression;
return this.createResourceStorageLoadable(inputStream_1);
} catch (Throwable _e) {
throw Exceptions.sneakyThrow(_e);
}
} | [
"Finds or creates a ResourceStorageLoadable for the given resource.\nClients should first call shouldLoadFromStorage to check whether there exists a storage version\nof the given resource.\n\n@return an IResourceStorageLoadable"
] | [
"Create a new instance for the specified host and encryption key.\n\n@see #create(String)",
"Returns the list of module dependencies regarding the provided filters\n\n@param moduleId String\n@param filters FiltersHolder\n@return List<Dependency>",
"Get a loader that lists the Files in the current path,\nand monitors changes.",
"Notifies that multiple content items are inserted.\n\n@param positionStart the position.\n@param itemCount the item count.",
"Checks the given field descriptor.\n\n@param fieldDef The field descriptor\n@param checkLevel The amount of checks to perform\n@exception ConstraintException If a constraint has been violated",
"Use this API to restore appfwprofile.",
"Deletes any empty directories under the output directory. These\ndirectories are created by TestNG for its own reports regardless\nof whether those reports are generated. If you are using the\ndefault TestNG reports as well as ReportNG, these directories will\nnot be empty and will be retained. Otherwise they will be removed.\n@param outputDirectory The directory to search for empty directories.",
"Use this API to fetch all the sslcertlink resources that are configured on netscaler.",
"Fill queue.\n\n@param item the item\n@param minStartPosition the min start position\n@param maxStartPosition the max start position\n@param minEndPosition the min end position\n@throws IOException Signals that an I/O exception has occurred."
] |
public static void main(String[] args) {
TreebankLanguagePack tlp = new PennTreebankLanguagePack();
System.out.println("Start symbol: " + tlp.startSymbol());
String start = tlp.startSymbol();
System.out.println("Should be true: " + (tlp.isStartSymbol(start)));
String[] strs = {"-", "-LLB-", "NP-2", "NP=3", "NP-LGS", "NP-TMP=3"};
for (String str : strs) {
System.out.println("String: " + str + " basic: " + tlp.basicCategory(str) + " basicAndFunc: " + tlp.categoryAndFunction(str));
}
} | [
"Prints a few aspects of the TreebankLanguagePack, just for debugging."
] | [
"Gets a list of any tasks on this file with requested fields.\n\n@param fields optional fields to retrieve for this task.\n@return a list of tasks on this file.",
"Reduce the given value to the nearest smaller 1 significant digit number starting with 1, 2 or 5.\n\n@param value the value to find a nice number for.\n@param scaleUnit the unit of the value.\n@param lockUnits if set, the values are not scaled to a \"nicer\" unit.",
"Wraps a StatisticsMatrix around 'm'. Does NOT create a copy of 'm' but saves a reference\nto it.",
"Stops the compressor.",
"Use this API to fetch all the callhome resources that are configured on netscaler.",
"Gets the path used for the results of XSLT Transforms.",
"Closes the connection to the Z-Wave controller.",
"Creates the final artifact name.\n\n@return the artifact name",
"Generate the next combination and return an array containing\nthe appropriate elements.\n@see #nextCombinationAsArray(Object[])\n@see #nextCombinationAsList()\n@return An array containing the elements that make up the next combination."
] |
private void addOp(String op, String path, String value) {
if (this.operations == null) {
this.operations = new JsonArray();
}
this.operations.add(new JsonObject()
.add("op", op)
.add("path", path)
.add("value", value));
} | [
"Adds a patch operation.\n@param op the operation type. Must be add, replace, remove, or test.\n@param path the path that designates the key. Must be prefixed with a \"/\".\n@param value the value to be set."
] | [
"Notifies that a footer item is changed.\n\n@param position the position.",
"Moves our current playback position to the specified beat; this will be reflected in any status and beat packets\nthat we are sending. An incoming value less than one will jump us to the first beat.\n\n@param beat the beat that we should pretend to be playing",
"Return a list of 'Files' of downloaded or uploaded files. Filters build files without local and remote paths.\n\n@param buildFilesStream - Stream of build Artifacts or Dependencies.\n@return - List of build files.",
"Creates a binary media type with the given type and subtype\n@throws com.tngtech.jgiven.exception.JGivenWrongUsageException if any of the given arguments is {@code null}",
"Add a simple property to the map file.\n\n@param writer xml stream writer\n@param name property name\n@param propertyType property type\n@param readMethod read method name\n@param writeMethod write method name\n@throws XMLStreamException",
"Convert given value to given target\n\n@param fromValue\nthe value to convert\n@param toType\ntarget target\n@param <T>\ntarget of the result\n@return the value converted to given target\n@throws TypeCastException\nif conversion was not possible",
"Builds a instance of the class for a map containing the values, without specifying the handler for differences\n\n@param clazz The class to build instance\n@param values The values map\n@return The 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",
"Creates a document for the resource without extracting the content. The aim is to get a content indexed,\neven if extraction runs into a timeout.\n\n@return the document for the resource generated if the content is discarded,\ni.e., only meta information are indexed.",
"Backup the current configuration as part of the patch history.\n\n@throws IOException for any error"
] |
private Observable<Indexable> invokeReadyTasksAsync(final InvocationContext context) {
TaskGroupEntry<TaskItem> readyTaskEntry = super.getNext();
final List<Observable<Indexable>> observables = new ArrayList<>();
// Enumerate the ready tasks (those with dependencies resolved) and kickoff them concurrently
//
while (readyTaskEntry != null) {
final TaskGroupEntry<TaskItem> currentEntry = readyTaskEntry;
final TaskItem currentTaskItem = currentEntry.data();
if (currentTaskItem instanceof ProxyTaskItem) {
observables.add(invokeAfterPostRunAsync(currentEntry, context));
} else {
observables.add(invokeTaskAsync(currentEntry, context));
}
readyTaskEntry = super.getNext();
}
return Observable.mergeDelayError(observables);
} | [
"Invokes the ready tasks.\n\n@param context group level shared context that need be passed to\n{@link TaskGroupEntry#invokeTaskAsync(boolean, InvocationContext)}\nmethod of each entry in the group when it is selected for execution\n\n@return an observable that emits the result of tasks in the order they finishes."
] | [
"Used to get PB, when no tx is running.",
"Returns the configured body or the default value.",
"gets the first non annotation line number of a node, taking into account annotations.",
"Use this API to add cachecontentgroup.",
"Reads the cost rate tables from the file.\n\n@param resource parent resource\n@param rates XML cot rate tables",
"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",
"Builds the table for the database results.\n\n@param results the database results\n@return the table",
"Read all task relationships from a GanttProject.\n\n@param gpProject GanttProject project",
"Use this API to fetch lbmonitor_binding resources of given names ."
] |
public static nstrafficdomain_binding[] get(nitro_service service, Long td[]) throws Exception{
if (td !=null && td.length>0) {
nstrafficdomain_binding response[] = new nstrafficdomain_binding[td.length];
nstrafficdomain_binding obj[] = new nstrafficdomain_binding[td.length];
for (int i=0;i<td.length;i++) {
obj[i] = new nstrafficdomain_binding();
obj[i].set_td(td[i]);
response[i] = (nstrafficdomain_binding) obj[i].get_resource(service);
}
return response;
}
return null;
} | [
"Use this API to fetch nstrafficdomain_binding resources of given names ."
] | [
"Computes the d and H parameters.\n\nd = J'*(f(x)-y) <--- that's also the gradient\nH = J'*J",
"Find out which method to call on the service bean.",
"Checks if a parameter exists. If it exists, it is left untouched. If it doesn't, it is created. Only works for parameters which key\nis unique. Must be called from within an open transaction.",
"Prints a few aspects of the TreebankLanguagePack, just for debugging.",
"gets a class from the class cache. This cache contains only classes loaded through\nthis class loader or an InnerLoader instance. If no class is stored for a\nspecific name, then the method should return null.\n\n@param name of the class\n@return the class stored for the given name\n@see #removeClassCacheEntry(String)\n@see #setClassCacheEntry(Class)\n@see #clearCache()",
"Removes a tag from the task. Returns an empty data block.\n\n@param task The task to remove a tag from.\n@return Request object",
"Append the given char as a decimal HTML entity.\n\n@param out\nThe StringBuilder to write to.\n@param value\nThe character.",
"Put features in a tile. This will assure all features are only added in one tile. When a feature's unique tile\nis different from this one a link is added in the tile.\n\n@param tile\ntile to put features in\n@param maxTileExtent\nthe maximum tile extent\n@throws GeomajasException oops",
"Set the end type as derived from other values."
] |
public void add(ServiceReference<S> declarationBinderRef) throws InvalidFilterException {
BinderDescriptor binderDescriptor = new BinderDescriptor(declarationBinderRef);
declarationBinders.put(declarationBinderRef, binderDescriptor);
} | [
"Add the declarationBinderRef to the ImportersManager, create the corresponding.\nBinderDescriptor.\n\n@param declarationBinderRef the ServiceReference<DeclarationBinder> of the DeclarationBinder\n@throws InvalidFilterException"
] | [
"This method retrieves the UID for a calendar associated with a task.\n\n@param mpx MPX Task instance\n@return calendar UID",
"IN Criteria with SubQuery\n@param attribute The field name to be used\n@param subQuery The subQuery",
"Get a bean value from the context.\n\n@param name bean name\n@return bean value or null",
"Send post request.\n\n@param url the url\n@param customHeaders the customHeaders\n@param params the params\n@return the string\n@throws IOException the io exception",
"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",
"Matches an array value if it contains all the elements of the argument array\n@param rhs The arguments\n@return PredicateExpression: $all rhs",
"Creates an immutable list that consists of the elements in the given array. A copy of the given array is used which means\nthat any modifications to the given array will not affect the immutable list.\n\n@param elements the given array of elements\n@return an immutable list",
"The method determines if the type can be resolved and if not, will try to guess the qualified name using the information from the imports.",
"Get a property as a json object or null.\n\n@param key the property name"
] |
private Object mapToId(Object tmp) {
if (tmp instanceof Double) {
return new Integer(((Double)tmp).intValue());
} else {
return Context.toString(tmp);
}
} | [
"map a property id. Property id can only be an Integer or String"
] | [
"Converts to a link-local Ipv6 address. Any MAC prefix length is ignored. Other elements of this address section are incorporated into the conversion.\nThis will provide the latter 4 segments of an IPv6 address, to be paired with the link-local IPv6 prefix of 4 segments.\n\n@return",
"Whether this association contains no rows.\n\n@return {@code true} if this association contains no rows, {@code false} otherwise",
"Creates the automata.\n\n@param prefix the prefix\n@param regexp the regexp\n@param automatonMap the automaton map\n@return the list\n@throws IOException Signals that an I/O exception has occurred.",
"Extract site path, base name and locale from the resource opened with the editor.",
"Update max.\n\n@param n the n\n@param c the c",
"Tells you if the expression is a null safe dereference.\n@param expression\nexpression\n@return\ntrue if is null safe dereference.",
"Unregister the mgmt channel.\n\n@param old the proxy controller to unregister\n@param shuttingDown whether the server inventory is shutting down\n@return whether the registration can be removed from the domain-controller",
"Calculate the finish variance.\n\n@return finish variance",
"Checks the given model.\n\n@param modelDef The model\n@param checkLevel The amount of checks to perform\n@exception ConstraintException If a constraint has been violated"
] |
public static int minutesDiff(Date earlierDate, Date laterDate) {
if (earlierDate == null || laterDate == null) {
return 0;
}
return (int) ((laterDate.getTime() / MINUTE_MILLIS) - (earlierDate.getTime() / MINUTE_MILLIS));
} | [
"Get the minutes difference"
] | [
"Add a IN clause so the column must be equal-to one of the objects from the list passed in.",
"Get the vector of regression coefficients.\n\n@param value The random variable to regress.\n@return The vector of regression coefficients.",
"Destroy the proxy & update the map containing the registration ref.\n\n@param importDeclaration",
"Computes the blend weights for the given time and\nupdates them in the target.",
"Returns true if\n- includeTags is not empty and tag is in includeTags\n- includeTags is empty and tag is not in excludeTags\n@param tags Hint tags\n@param includeTags Include tags\n@param excludeTags Exclude tags\n@return has tag match",
"Record operation for sync ops time\n\n@param dest Destination of the socket to connect to. Will actually record\nif null. Otherwise will call this on self and corresponding child\nwith this param null.\n@param opTimeUs The number of us for the op to finish",
"Finish initializing.\n\n@throws GeomajasException oops",
"Prepare a parallel HTTP GET Task.\n\n@param url\nthe UrlPostfix: e.g. in http://localhost:8080/index.html.,the url is \"/index.html\"\n@return the parallel task builder",
"Use this API to fetch all the lbroute resources that are configured on netscaler."
] |
public static void configureLogging() {
// Create the appender that will write log messages to the console.
ConsoleAppender consoleAppender = new ConsoleAppender();
// Define the pattern of log messages.
// Insert the string "%c{1}:%L" to also show class name and line.
String pattern = "%d{yyyy-MM-dd HH:mm:ss} %-5p - %m%n";
consoleAppender.setLayout(new PatternLayout(pattern));
// Change to Level.ERROR for fewer messages:
consoleAppender.setThreshold(Level.INFO);
consoleAppender.activateOptions();
Logger.getRootLogger().addAppender(consoleAppender);
} | [
"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."
] | [
"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)}",
"This method converts an offset value into an array index, which in\nturn allows the data present in the fixed block to be retrieved. Note\nthat if the requested offset is not found, then this method returns -1.\n\n@param offset Offset of the data in the fixed block\n@return Index of data item within the fixed data block",
"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.",
"Downloads this version of the file to a given OutputStream while reporting the progress to a ProgressListener.\n@param output the stream to where the file will be written.\n@param listener a listener for monitoring the download's progress.",
"Determines whether the given array only contains unbounded type variables or Object.class.\n\n@param types the given array of types\n@return true if and only if the given array only contains unbounded type variables or Object.class",
"Enable the use of the given controller type by\nadding it to the cursor controller types list.\n@param controllerType GVRControllerType to add to the list",
"Use this API to fetch all the nsrollbackcmd resources that are configured on netscaler.",
"Creates an upper triangular matrix whose values are selected from a uniform distribution. If hessenberg\nis greater than zero then a hessenberg matrix of the specified degree is created instead.\n\n@param dimen Number of rows and columns in the matrix..\n@param hessenberg 0 for triangular matrix and > 0 for hessenberg matrix.\n@param min minimum value an element can be.\n@param max maximum value an element can be.\n@param rand random number generator used.\n@return The randomly generated matrix.",
"Retrieves a long value from the extended data.\n\n@param type Type identifier\n@return long value"
] |
public void store(String gavc,
String action,
String commentText,
DbCredential credential,
String entityType) {
DbComment comment = new DbComment();
comment.setEntityId(gavc);
comment.setEntityType(entityType);
comment.setDbCommentedBy(credential.getUser());
comment.setAction(action);
if(!commentText.isEmpty()) {
comment.setDbCommentText(commentText);
}
comment.setDbCreatedDateTime(new Date());
repositoryHandler.store(comment);
} | [
"Store a comment based on comment text, gavc and user information\n\n@param gavc - entity id\n@param commentText - comment text\n@param credential - user credentials\n@param entityType - type of the entity"
] | [
"Returns true if this entity's primary key is not null, and for numeric\nfields, is non-zero.",
"This implementation does not support the 'offset' and 'maxResultSize' parameters.",
"Use this API to fetch vlan_interface_binding resources of given name .",
"This method extracts calendar data from an MSPDI file.\n\n@param project Root node of the MSPDI file\n@param map Map of calendar UIDs to names",
"Removes the specified entry point\n\n@param controlPoint The entry point",
"Create a Map composed of the entries of the first map minus the\nentries of the given map.\n\n@param self a map object\n@param removeMe the entries to remove from the map\n@return the resulting map\n@since 1.7.4",
"Throws one RendererException if the content parent or layoutInflater are null.",
"Exception handler if we are unable to parse a json value into a java representation\n\n@param expectedType Name of the expected Type\n@param type Type of the json node\n@return SpinJsonDataFormatException",
"Append a Handler to every parent of the given class\n@param parent The class of the parents to add the child to\n@param child The Handler to add."
] |
public static base_response update(nitro_service client, spilloverpolicy resource) throws Exception {
spilloverpolicy updateresource = new spilloverpolicy();
updateresource.name = resource.name;
updateresource.rule = resource.rule;
updateresource.action = resource.action;
updateresource.comment = resource.comment;
return updateresource.update_resource(client);
} | [
"Use this API to update spilloverpolicy."
] | [
"Add a row to the table. We have a limited understanding of the way\nBtrieve handles outdated rows, so we use what we think is a version number\nto try to ensure that we only have the latest rows.\n\n@param primaryKeyColumnName primary key column name\n@param map Map containing row data",
"Try to extract a numeric version from a collection of strings.\n\n@param versionStrings Collection of string properties.\n@return The version string if exists in the collection.",
"Makes the object unpickable and removes the touch handler for it\n@param sceneObject\n@return true if the handler has been successfully removed",
"This method performs database modification at the very and of transaction.",
"Does this procedure return any values to the 'caller'?\n\n@return <code>true</code> if the procedure returns at least 1\nvalue that is returned to the caller.",
"Sends a text message using given server setup for SMTP.\n\n@param to the to address.\n@param from the from address.\n@param subject the subject.\n@param msg the test message.\n@param setup the SMTP setup.",
"Use this API to update gslbsite.",
"Read a Synchro string from an input stream.\n\n@param is input stream\n@return String instance",
"Create a Task instance from a Phoenix activity.\n\n@param activity Phoenix activity data"
] |
public CrosstabBuilder useMainReportDatasource(boolean preSorted) {
DJDataSource datasource = new DJDataSource("ds",DJConstants.DATA_SOURCE_ORIGIN_REPORT_DATASOURCE,DJConstants.DATA_SOURCE_TYPE_JRDATASOURCE);
datasource.setPreSorted(preSorted);
crosstab.setDatasource(datasource);
return this;
} | [
"To use main report datasource. There should be nothing else in the detail band\n@param preSorted\n@return"
] | [
"This implementation returns whether the underlying asset exists.",
"Computes the householder vector used in QR decomposition.\n\nu = x / max(x)\nu(0) = u(0) + |u|\nu = u / u(0)\n\n@param x Input vector. Unmodified.\n@return The found householder reflector vector",
"Draw a rectangle's interior with this color.\n\n@param rect rectangle\n@param color colour",
"Wait for the template resources to come up after the test container has\nbeen started. This allows the test container and the template resources\nto come up in parallel.",
"Process stop.\n\n@param endpoint the endpoint\n@param eventType the event type",
"Divides the elements at the specified column by 'val'. Takes in account\nleading zeros and one.",
"This method is called to format a constraint type.\n\n@param type constraint type\n@return formatted constraint type",
"Sets the size of a UIObject",
"Indicates if a set of types are all proxyable\n\n@param types The types to test\n@return True if proxyable, false otherwise"
] |
private int determineForkedJvmCount(TestsCollection testCollection) {
int cores = Runtime.getRuntime().availableProcessors();
int jvmCount;
if (this.parallelism.equals(PARALLELISM_AUTO)) {
if (cores >= 8) {
// Maximum parallel jvms is 4, conserve some memory and memory bandwidth.
jvmCount = 4;
} else if (cores >= 4) {
// Make some space for the aggregator.
jvmCount = 3;
} else if (cores == 3) {
// Yes, three-core chips are a thing.
jvmCount = 2;
} else {
// even for dual cores it usually makes no sense to fork more than one
// JVM.
jvmCount = 1;
}
} else if (this.parallelism.equals(PARALLELISM_MAX)) {
jvmCount = Runtime.getRuntime().availableProcessors();
} else {
try {
jvmCount = Math.max(1, Integer.parseInt(parallelism));
} catch (NumberFormatException e) {
throw new BuildException("parallelism must be 'auto', 'max' or a valid integer: "
+ parallelism);
}
}
if (!testCollection.hasReplicatedSuites()) {
jvmCount = Math.min(testCollection.testClasses.size(), jvmCount);
}
return jvmCount;
} | [
"Determine how many forked JVMs to use."
] | [
"Create an instance from the given config.\n\n@param param Grid param from the request.",
"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.",
"Checks String to see if the parameter is null.\n@param paramValue Object that will be checked if null.\n@return this.true if the parameter that is being checked is not null",
"Query zipcode from Yahoo to find associated WOEID",
"If you register a CustomExpression with the name \"customExpName\", then this will create the text needed\nto invoke it in a JRDesignExpression\n\n@param customExpName\n@param usePreviousFieldValues\n@return",
"Controls whether we are currently staying in sync with the tempo master. Will only be meaningful if we are\nsending status packets.\n\n@param sync if {@code true}, our status packets will be tempo and beat aligned with the tempo master",
"Remove colProxy from list of pending collections and\nregister its contents with the transaction.",
"Sets the distance from the origin to the near clipping plane for the\nwhole camera rig.\n\n@param near\nDistance to the near clipping plane.",
"You should use the server's time here. Otherwise you might get unexpected results.\n\nThe typical use case is:\n\n\n<pre>\nHTTPResponse response = ....\nHTTPRequest request = createRequest();\nrequest = request.conditionals(new Conditionals().ifModifiedSince(response.getLastModified());\n</pre>\n\n@param time the time to check.\n@return the conditionals with the If-Modified-Since date set."
] |
public void loadModel(GVRAndroidResource avatarResource)
{
EnumSet<GVRImportSettings> settings = GVRImportSettings.getRecommendedSettingsWith(EnumSet.of(GVRImportSettings.OPTIMIZE_GRAPH, GVRImportSettings.NO_ANIMATION));
GVRContext ctx = mAvatarRoot.getGVRContext();
GVRResourceVolume volume = new GVRResourceVolume(ctx, avatarResource);
GVRSceneObject modelRoot = new GVRSceneObject(ctx);
mAvatarRoot.addChildObject(modelRoot);
ctx.getAssetLoader().loadModel(volume, modelRoot, settings, false, mLoadModelHandler);
} | [
"Load the avatar base model\n@param avatarResource resource with avatar model"
] | [
"Verify the given job types are all valid.\n\n@param jobTypes the given job types\n@throws IllegalArgumentException if any of the job types are invalid\n@see #checkJobType(String, Class)",
"If there is a zero on the diagonal element, the off diagonal element needs pushed\noff so that all the algorithms assumptions are two and so that it can split the matrix.",
"Create a patch element for the rollback patch.\n\n@param entry the entry\n@return the new patch element",
"Gets the element view.\n\n@return the element view",
"Writes triples to determine the statements with the highest rank.",
"Creates and returns a matrix which is idential to this one.\n\n@return A new identical matrix.",
"Creates a new broker instance.\n\n@param jcdAlias The jdbc connection descriptor name as defined in the repository\n@param user The user name to be used for connecting to the database\n@param password The password to be used for connecting to the database\n@return The persistence broker\n@see org.apache.ojb.broker.core.PersistenceBrokerFactoryIF#createPersistenceBroker(java.lang.String, java.lang.String, java.lang.String)",
"Format a cue countdown indicator in the same way as the CDJ would at this point in the track.\n\n@return the value that the CDJ would display to indicate the distance to the next cue\n@see #getCueCountdown()",
"Retrieve the state object associated with the specified interceptor instance and property\nname on this request context.\n\n@param interceptor the interceptor instance\n@param stateName the name key that the state object was stored under\n@param stateType class of the type the stored state should be returned as\n@param <T> the type the stored state should be returned as\n@return the stored state object\n@see #setState(HttpConnectionInterceptor, String, Object)\n@since 2.6.0"
] |
private void writePropertyData() {
try (PrintStream out = new PrintStream(openResultFileOuputStream(
resultDirectory, "properties.json"))) {
out.println("{");
int count = 0;
for (Entry<Integer, PropertyRecord> propertyEntry : this.propertyRecords
.entrySet()) {
if (count > 0) {
out.println(",");
}
out.print("\"" + propertyEntry.getKey() + "\":");
mapper.writeValue(out, propertyEntry.getValue());
count++;
}
out.println("\n}");
System.out.println(" Serialized information for " + count
+ " properties.");
} catch (IOException e) {
e.printStackTrace();
}
} | [
"Writes all data that was collected about properties to a json file."
] | [
"Use this API to update ipv6.",
"get the ClassTypeSignature corresponding to given parameterized type\n\n@param parameterizedType\n@return",
"Use this API to delete sslfipskey of given name.",
"Parse a filter expression.\n\n@param filter the filter expression\n@return compiled nodes",
"Returns the directory of the URL.\n\n@param urlString URL of the file.\n@return The directory string.\n@throws IllegalArgumentException if URL is malformed",
"Recursively scan the provided path and return a list of all Java packages contained therein.",
"Get the connectivity state as reported by the Android system\n\n@param context Android context\n@return the connectivity state as reported by the Android system",
"Iterates through the given CharSequence line by line, splitting each line using\nthe given regex delimiter. The list of tokens for each line is then passed to\nthe given closure.\n\n@param self a CharSequence\n@param regex the delimiting regular expression\n@param closure a closure\n@return the last value returned by the closure\n@throws java.io.IOException if an error occurs\n@throws java.util.regex.PatternSyntaxException if the regular expression's syntax is invalid\n@see #splitEachLine(CharSequence, java.util.regex.Pattern, groovy.lang.Closure)\n@since 1.8.2",
"Build resolution context in which message will be discovered and built\n@param components resolution components, used to identify message bundle\n@param messageParams message parameters will be substituted in message and used in pattern matching\n@since 3.1\n@return immutable resolution context instance for given parameters"
] |
public String toMixedString() {
String result;
if(hasNoStringCache() || (result = stringCache.mixedString) == null) {
if(hasZone()) {
stringCache.mixedString = result = toNormalizedString(IPv6StringCache.mixedParams);
} else {
result = getSection().toMixedString();//the cache is shared so no need to update it here
}
}
return result;
} | [
"Produces a string in which the lower 4 bytes are expressed as an IPv4 address and the remaining upper bytes are expressed in IPv6 format.\n\nThis the mixed IPv6/IPv4 format described in RFC 1884 https://tools.ietf.org/html/rfc1884\n\n@return"
] | [
"Handle a change in the weeks of month.\n@param week the changed weeks checkbox's internal value.\n@param value the new value of the changed checkbox.",
"One of facade methods for operating the Shell.\n\nRun the obtained Shell with commandLoop().\n\n@see org.gearvrf.debug.cli.Shell#Shell(org.gearvrf.debug.cli.Shell.Settings, org.gearvrf.debug.cli.CommandTable, java.util.List)\n\n@param prompt Prompt to be displayed\n@param appName The app name string\n@param handlers Command handlers\n@return Shell that can be either further customized or run directly by calling commandLoop().",
"Find the path to use .\nUses java annotations first and if not found, uses kubernetes annotations on the service object.\n\n@param service\nThe target service.\n@param qualifiers\nThe set of qualifiers.\n\n@return Returns the resolved path of '/' as a fallback.",
"Use this API to expire cachecontentgroup resources.",
"Returns the corresponding mac section, or null if this address section does not correspond to a mac section.\nIf this address section has a prefix length it is ignored.\n\n@param extended\n@return",
"A final cluster ought to be a super set of current cluster. I.e.,\nexisting node IDs ought to map to same server, but partition layout can\nhave changed and there may exist new nodes.\n\n@param currentCluster\n@param finalCluster",
"Creates a curator built using the given zookeeper connection string and timeout",
"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 TypeSignature corresponding to given class with given type\narguments\n\n@param clazz\n@param typeArgs\n@return"
] |
private void readResource(Document.Resources.Resource resource)
{
Resource mpxjResource = m_projectFile.addResource();
mpxjResource.setName(resource.getName());
mpxjResource.setResourceCalendar(m_calendarMap.get(resource.getCalendarID()));
mpxjResource.setStandardRate(new Rate(resource.getCost(), resource.getCostTimeUnit()));
mpxjResource.setEmailAddress(resource.getEMail());
mpxjResource.setGroup(resource.getGroup());
//resource.getHyperlinks()
mpxjResource.setUniqueID(resource.getID());
//resource.getMarkerID()
mpxjResource.setNotes(resource.getNote());
mpxjResource.setID(Integer.valueOf(resource.getOutlineNumber()));
//resource.getStyleProject()
mpxjResource.setType(resource.getSubType() == null ? resource.getType() : resource.getSubType());
} | [
"Reads a single resource from a ConceptDraw PROJECT file.\n\n@param resource ConceptDraw PROJECT resource"
] | [
"Remove the sequence for given sequence name.\n\n@param sequenceName Name of the sequence to remove.",
"Sets the bottom padding for all cells in the table.\n@param paddingBottom new padding, ignored if smaller than 0\n@return this to allow chaining",
"Execute a server task.\n\n@param listener the transactional server listener\n@param task the server task\n@return time to wait in ms for a response from the server, or {@code -1} if the task execution failed locally",
"Setting the type of Checkbox.",
"Execute a slave process. Pump events to the given event bus.",
"Returns the effective batch size. If the dialect is multiget capable and a batch size has been configured, use\nthat one, otherwise the default.",
"Display mode for output streams.",
"Facade method facilitating the creation of subshell.\nSubshell is created and run inside Command method and shares the same IO and naming strategy.\n\nRun the obtained Shell with commandLoop().\n\n@param pathElement sub-prompt\n@param parent Shell to be subshell'd\n@param appName The app name string\n@param mainHandler Command handler\n@param auxHandlers Aux handlers to be passed to all subshells.\n@return subshell",
"Retrieves or if necessary, creates a user alias to be used\nby a child criteria\n@param attribute The alias to set"
] |
public static boolean matches(Map<String, Object> nodeProperties, String[] keyColumnNames, Object[] keyColumnValues) {
for ( int i = 0; i < keyColumnNames.length; i++ ) {
String property = keyColumnNames[i];
Object expectedValue = keyColumnValues[i];
boolean containsProperty = nodeProperties.containsKey( property );
if ( containsProperty ) {
Object actualValue = nodeProperties.get( property );
if ( !sameValue( expectedValue, actualValue ) ) {
return false;
}
}
else if ( expectedValue != null ) {
return false;
}
}
return true;
} | [
"Check if the node matches the column values\n\n@param nodeProperties the properties on the node\n@param keyColumnNames the name of the columns to check\n@param keyColumnValues the value of the columns to check\n@return true if the properties of the node match the column names and values"
] | [
"Creates an temporary directory. The created directory will be deleted when\ncommand will ended.",
"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) }",
"Assigned action code",
"Unzip a file to a target directory.\n@param zip the path to the zip file.\n@param target the path to the target directory into which the zip file will be unzipped.\n@throws IOException",
"Add a Opacity bar to the color wheel.\n\n@param bar The instance of the Opacity bar.",
"Use this API to unset the properties of responderpolicy resource.\nProperties that need to be unset are specified in args array.",
"returns a unique String for given field.\nthe returned uid is unique accross all tables.",
"Add new control at the end of control bar with specified touch listener and resource.\nSize of control bar is updated based on new number of controls.\n@param name name of the control to remove\n@param resId the control face\n@param listener touch listener",
"Ensures that the given collection descriptor has the collection-class property if necessary.\n\n@param collDef The collection descriptor\n@param checkLevel The current check level (this constraint is checked in basic (partly) and strict)\n@exception ConstraintException If collection-class is given for an array or if no collection-class is given but required"
] |
public IntervalFrequency getRefreshFrequency() {
switch (mRefreshInterval) {
case REALTIME_REFRESH_INTERVAL:
return IntervalFrequency.REALTIME;
case HIGH_REFRESH_INTERVAL:
return IntervalFrequency.HIGH;
case LOW_REFRESH_INTERVAL:
return IntervalFrequency.LOW;
case MEDIUM_REFRESH_INTERVAL:
return IntervalFrequency.MEDIUM;
default:
return IntervalFrequency.NONE;
}
} | [
"Get the refresh frequency of this scene object.\n\n@return The refresh frequency of this TextViewSceneObject."
] | [
"Internal used method which start the real store work.",
"Converts the given hash code into an index into the\nhash table.",
"Returns the ARGB components for all pixels in this image\n\n@return an array containing an array for each ARGB components in that order.",
"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",
"Use this API to fetch lbvserver_servicegroupmember_binding resources of given name .",
"Creates the container for a bundle without descriptor.\n@return the container for a bundle without descriptor.\n@throws IOException thrown if reading the bundle fails.\n@throws CmsException thrown if reading the bundle fails.",
"Use this API to fetch dnstxtrec resources of given names .",
"Convert Day instance to MPX day index.\n\n@param day Day instance\n@return day index",
"Confirms a user with the given token and token id.\n\n@param token the confirmation token.\n@param tokenId the id of the confirmation token.\n@return A {@link Task} that completes when confirmation completes/fails."
] |
public static void permutationVector( DMatrixSparseCSC P , int[] vector) {
if( P.numCols != P.numRows ) {
throw new MatrixDimensionException("Expected a square matrix");
} else if( P.nz_length != P.numCols ) {
throw new IllegalArgumentException("Expected N non-zero elements in permutation matrix");
} else if( vector.length < P.numCols ) {
throw new IllegalArgumentException("vector is too short");
}
int M = P.numCols;
for (int i = 0; i < M; i++) {
if( P.col_idx[i+1] != i+1 )
throw new IllegalArgumentException("Unexpected number of elements in a column");
vector[P.nz_rows[i]] = i;
}
} | [
"Converts the permutation matrix into a vector\n@param P (Input) Permutation matrix\n@param vector (Output) Permutation vector"
] | [
"Resolve the disposal method for the given producer method. Any resolved\nbeans will be marked as such for the purpose of validating that all\ndisposal methods are used. For internal use.\n\n@param types the types\n@param qualifiers The binding types to match\n@param declaringBean declaring bean\n@return The set of matching disposal methods",
"Adds a new child widget to the panel, attaching its Element to the\nspecified container Element.\n\n@param child the child widget to be added\n@param container the element within which the child will be contained",
"Print a resource type.\n\n@param value ResourceType instance\n@return resource type value",
"Searches for all annotations of the given type on this method or on type level for all interfaces and superclasses\n\n@param method the method to scan\n@param annotation the annotation to search for\n@param <T> the type of the annotation\n@return the list of all method or type level annotations in the type hierarchy",
"Retrieves the timephased breakdown of cost.\n\n@return timephased cost",
"Extract data for a single calendar.\n\n@param row calendar data",
"Set OAuth 1 authentication credentials for the replication target\n\n@param consumerSecret client secret\n@param consumerKey client identifier\n@param tokenSecret OAuth server token secret\n@param token OAuth server issued token\n@return this Replication instance to set more options or trigger the replication",
"Gets or creates the a resource for the sub-deployment on the parent deployments resource.\n\n@param deploymentName the name of the deployment\n@param parent the parent deployment used to find the parent resource\n\n@return the already registered resource or a newly created resource",
"Start the timer."
] |
public LogSegment getLastView() {
List<LogSegment> views = getView();
return views.get(views.size() - 1);
} | [
"get the last segment at the moment\n\n@return the last segment"
] | [
"Use this API to fetch all the sslcertkey resources that are configured on netscaler.",
"Adds a slash to a path if it doesn't end with a slash.\n\n@param folderName The path to append a possible slash.\n@return The new, correct path.",
"Helper to read an optional Boolean value.\n@param path The XML path of the element to read.\n@return The Boolean value stored in the XML, or <code>null</code> if the value could not be read.",
"Checks if a document exist in the database.\n\n@param id The document _id field.\n@return true If the document is found, false otherwise.",
"Method to read our client's plain text\n\n@param file_name\n@return the filereader to translate client's plain text into our files\n@throws BeastException\nif any problem is found whit the file",
"Convenience method for retrieving a char resource.\n\n@param locale locale identifier\n@param key resource key\n@return resource value",
"Command line method to walk the directories provided on the command line\nand print out their contents\n\n@param args Directory names",
"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",
"Retrieves state and metrics information for individual node.\n\n@param name node name\n@return node information"
] |
public Map<String, CmsJspCategoryAccessBean> getSubCategories() {
if (m_subCategories == null) {
m_subCategories = CmsCollectionsGenericWrapper.createLazyMap(new Transformer() {
@SuppressWarnings("synthetic-access")
public Object transform(Object pathPrefix) {
return new CmsJspCategoryAccessBean(m_cms, m_categories, (String)pathPrefix);
}
});
}
return m_subCategories;
} | [
"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."
] | [
"Preloads a sound file.\n\n@param soundFile path/name of the file to be played.",
"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",
"Use this API to fetch wisite_binding resources of given names .",
"write CustomInfo list into table.\n\n@param event the event",
"Returns the full record for a single team.\n\n@param team Globally unique identifier for the team.\n@return Request object",
"Get the collection of public contacts for the specified user ID.\n\nThis method does not require authentication.\n\n@param userId\nThe user ID\n@return The Collection of Contact objects\n@throws FlickrException",
"Removes the duplicate node list.\n\n@param list\nthe list\n@return the int",
"Converts the given CharSequence into a List of Strings of one character.\n\n@param self a CharSequence\n@return a List of characters (a 1-character String)\n@see #toSet(String)\n@since 1.8.2",
"Checks if a given number is in the range of a byte.\n\n@param number\na number which should be in the range of a byte (positive or negative)\n\n@see java.lang.Byte#MIN_VALUE\n@see java.lang.Byte#MAX_VALUE\n\n@return number as a byte (rounding might occur)"
] |
public ItemRequest<Project> createInTeam(String team) {
String path = String.format("/teams/%s/projects", team);
return new ItemRequest<Project>(this, Project.class, path, "POST");
} | [
"Creates a project shared with the given team.\n\nReturns the full record of the newly created project.\n\n@param team The team to create the project in.\n@return Request object"
] | [
"This only gets half of the EnabledEndpoint from a JDBC ResultSet\nGetting the method for the override id requires an additional SQL query and needs to be called after\nthe SQL connection is released\n\n@param result result to scan for endpoint\n@return EnabledEndpoint\n@throws Exception exception",
"resolves a Field or Property node generics by using the current class and\nthe declaring class to extract the right meaning of the generics symbols\n@param an a FieldNode or PropertyNode\n@param type the origin type\n@return the new ClassNode with corrected generics",
"Main executable method of Crawljax CLI.\n\n@param args\nthe arguments.",
"Deletes a redirect by id\n\n@param id redirect ID",
"Serialize a map of objects to a JSON String.\n\n@param map The map of objects to serialize.\n@param jsonObjectClass The @JsonObject class of the list elements",
"Attaches the menu drawer to the content view.",
"Makes the object unpickable and removes the touch handler for it\n@param sceneObject\n@return true if the handler has been successfully removed",
"Flatten a list of test suite results into a collection of results grouped by test class.\nThis method basically strips away the TestNG way of organising tests and arranges\nthe results by test class.",
"Validate the configuration.\n\n@param validationErrors where to put the errors."
] |
@Deprecated
public Location resolvePlaceURL(String flickrPlacesUrl) throws FlickrException {
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("method", METHOD_RESOLVE_PLACE_URL);
parameters.put("url", flickrPlacesUrl);
Response response = transportAPI.get(transportAPI.getPath(), parameters, apiKey, sharedSecret);
if (response.isError()) {
throw new FlickrException(response.getErrorCode(), response.getErrorMessage());
}
Element locationElement = response.getPayload();
return parseLocation(locationElement);
} | [
"Find Flickr Places information by Place URL.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@deprecated This method has been deprecated. It won't be removed but you should use {@link PlacesInterface#getInfoByUrl(String)} instead.\n@param flickrPlacesUrl\n@return A Location\n@throws FlickrException"
] | [
"Set the given, single header value under the given name.\n@param headerName the header name\n@param headerValue the header value\n@throws UnsupportedOperationException if adding headers is not supported\n@see #put(String, List)\n@see #add(String, String)",
"I promise that this is always a collection of HazeltaskTasks",
"Read leaf tasks attached to the WBS.\n\n@param id initial WBS ID",
"Select item by it's position\n\n@param position int value of item position to select\n@param invokeListeners boolean value for invoking listeners",
"Set the pickers selection type.",
"A convenience method for creating an immutable map.\n\n@param self a Map\n@return an immutable Map\n@see java.util.Collections#unmodifiableMap(java.util.Map)\n@since 1.0",
"Remove the S3 file that contains the domain controller data.\n\n@param directoryName the name of the directory that contains the S3 file",
"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.",
"Removes all children"
] |
public static DMatrixSparseCSC rectangle(int numRows , int numCols , int nz_total ,
double min , double max , Random rand ) {
nz_total = Math.min(numCols*numRows,nz_total);
int[] selected = UtilEjml.shuffled(numRows*numCols, nz_total, rand);
Arrays.sort(selected,0,nz_total);
DMatrixSparseCSC ret = new DMatrixSparseCSC(numRows,numCols,nz_total);
ret.indicesSorted = true;
// compute the number of elements in each column
int hist[] = new int[ numCols ];
for (int i = 0; i < nz_total; i++) {
hist[selected[i]/numRows]++;
}
// define col_idx
ret.histogramToStructure(hist);
for (int i = 0; i < nz_total; i++) {
int row = selected[i]%numRows;
ret.nz_rows[i] = row;
ret.nz_values[i] = rand.nextDouble()*(max-min)+min;
}
return ret;
} | [
"Randomly generates matrix with the specified number of non-zero elements filled with values from min to max.\n\n@param numRows Number of rows\n@param numCols Number of columns\n@param nz_total Total number of non-zero elements in the matrix\n@param min Minimum element value, inclusive\n@param max Maximum element value, inclusive\n@param rand Random number generator\n@return Randomly generated matrix"
] | [
"DISPATCHING - COMMANDS",
"Returns all the Artifacts of the module\n\n@param module Module\n@return List<Artifact>",
"Read a four byte integer.\n\n@param data byte array\n@param offset offset into array\n@return integer value",
"Producers returned from this method are not validated. Internal use only.",
"Creates a collaboration whitelist for a Box User with a given ID.\n@param api the API connection to be used by the collaboration whitelist.\n@param userID the ID of the Box User to add to the collaboration whitelist.\n@return information about the collaboration whitelist created for user.",
"Indicates if this file represents a directory on the underlying file system.\n\n@param directoryPath\n@return",
"Picks out a File from `thriftFiles` corresponding to a given artifact ID\nand file name. Returns null if `artifactId` and `fileName` do not map to a\nthrift file path.\n\n@parameter artifactId The artifact ID of which to look up the path\n@parameter fileName the name of the thrift file for which to extract a path\n@parameter thriftFiles The set of Thrift files in which to lookup the\nartifact ID.\n@return The path of the directory containing Thrift files for the given\nartifact ID. null if artifact ID not found.",
"get children nodes name\n\n@param zkClient zkClient\n@param path full path\n@return children nodes name or null while path not exist",
"Finds all lazily-declared classes and methods and adds their definitions to the source."
] |
private boolean initCheckTypeModifiers() {
Class<?> classInfoclass = Reflections.loadClass(CLASSINFO_CLASS_NAME, new ClassLoaderResourceLoader(classFileServices.getClass().getClassLoader()));
if (classInfoclass != null) {
try {
Method setFlags = AccessController.doPrivileged(GetDeclaredMethodAction.of(classInfoclass, "setFlags", short.class));
return setFlags != null;
} catch (Exception exceptionIgnored) {
BootstrapLogger.LOG.usingOldJandexVersion();
return false;
}
} else {
return true;
}
} | [
"checking availability of ClassInfo.setFlags method is just workaround for JANDEX-37"
] | [
"Get the max extent as a envelop object.",
"Read custom property definitions for tasks.\n\n@param gpTasks GanttProject tasks",
"Converts a vector from eigen space into sample space.\n\n@param eigenData Eigen space data.\n@return Sample space projection.",
"Fancy print without a space added to positive numbers",
"Returns a Span that covers all rows beginning with a prefix String parameters will be encoded\nas UTF-8",
"Returns the organization of a given module\n\n@return Organization",
"Prep for a new connection\n@return if stats are enabled, return the nanoTime when this connection was requested.\n@throws SQLException",
"Code common to both XER and database readers to extract\ncurrency format data.\n\n@param row row containing currency data",
"Process a single outline code.\n\n@param parentRow outline code to task mapping table\n@throws SQLException"
] |
public static<T> SessionVar<T> vendSessionVar(T defValue) {
return (new VarsJBridge()).vendSessionVar(defValue, new Exception());
} | [
"Vend a SessionVar with the default value"
] | [
"Saves the project file displayed in this panel.\n\n@param file target file\n@param type file type",
"Get the collection of the server groups\n\n@return Collection of active server groups",
"Use this API to unset the properties of responderparam resource.\nProperties that need to be unset are specified in args array.",
"Calculate the name of the input value.\n\n@param inputPrefix a nullable prefix to prepend to the name if non-null and non-empty\n@param inputMapper the name mapper\n@param field the field containing the value",
"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",
"This method formats a time unit.\n\n@param timeUnit time unit instance\n@return formatted time unit instance",
"Sets no of currency digits.\n\n@param currDigs Available values, 0,1,2",
"Parses the list of query items for the query facet.\n@param queryFacetObject JSON object representing the node with the query facet.\n@return list of query options\n@throws JSONException if the list cannot be parsed.",
"1.0 version of parser is different at simple mapperParser"
] |
public Pixel[] pixels() {
Pixel[] pixels = new Pixel[count()];
Point[] points = points();
for (int k = 0; k < points.length; k++) {
pixels[k] = pixel(points[k]);
}
return pixels;
} | [
"Returns all the pixels for the image\n\n@return an array of pixels for this image"
] | [
"Determine the generic value type of the given Map field.\n@param mapField the map field to introspect\n@param nestingLevel the nesting level of the target type\n(typically 1; e.g. in case of a List of Lists, 1 would indicate the\nnested List, whereas 2 would indicate the element of the nested List)\n@return the generic type, or {@code null} if none",
"If a text contains double quotes, escape them.\n\n@param text the text to escape\n@return Escaped text or {@code null} if the text is null",
"Return the map bounds rotated with the set rotation. The bounds are adapted to rounding changes of the\nsize of the paint area.\n\n@param paintAreaPrecise The exact size of the paint area.\n@param paintArea The rounded size of the paint area.\n@return Rotated bounds.",
"Use this API to add nspbr6.",
"Set the start time.\n@param date the start time to set.",
"Write the configuration to a buffered writer.",
"Remove a partition from the node provided\n\n@param node The node from which we're removing the partition\n@param donatedPartition The partitions to remove\n@return The new node without the partition",
"Helper method to set a value in the internal header list.\n\n@param headers the headers to set the value in\n@param name the name to set\n@param value the value to set",
"Function to perform forward activation"
] |
public static int optionLength(String option) {
if(matchOption(option, "qualify", true) ||
matchOption(option, "qualifyGenerics", true) ||
matchOption(option, "hideGenerics", true) ||
matchOption(option, "horizontal", true) ||
matchOption(option, "all") ||
matchOption(option, "attributes", true) ||
matchOption(option, "enumconstants", true) ||
matchOption(option, "operations", true) ||
matchOption(option, "enumerations", true) ||
matchOption(option, "constructors", true) ||
matchOption(option, "visibility", true) ||
matchOption(option, "types", true) ||
matchOption(option, "autosize", true) ||
matchOption(option, "commentname", true) ||
matchOption(option, "nodefontabstractitalic", true) ||
matchOption(option, "postfixpackage", true) ||
matchOption(option, "noguillemot", true) ||
matchOption(option, "views", true) ||
matchOption(option, "inferrel", true) ||
matchOption(option, "useimports", true) ||
matchOption(option, "collapsible", true) ||
matchOption(option, "inferdep", true) ||
matchOption(option, "inferdepinpackage", true) ||
matchOption(option, "hideprivateinner", true) ||
matchOption(option, "compact", true))
return 1;
else if(matchOption(option, "nodefillcolor") ||
matchOption(option, "nodefontcolor") ||
matchOption(option, "nodefontsize") ||
matchOption(option, "nodefontname") ||
matchOption(option, "nodefontclasssize") ||
matchOption(option, "nodefontclassname") ||
matchOption(option, "nodefonttagsize") ||
matchOption(option, "nodefonttagname") ||
matchOption(option, "nodefontpackagesize") ||
matchOption(option, "nodefontpackagename") ||
matchOption(option, "edgefontcolor") ||
matchOption(option, "edgecolor") ||
matchOption(option, "edgefontsize") ||
matchOption(option, "edgefontname") ||
matchOption(option, "shape") ||
matchOption(option, "output") ||
matchOption(option, "outputencoding") ||
matchOption(option, "bgcolor") ||
matchOption(option, "hide") ||
matchOption(option, "include") ||
matchOption(option, "apidocroot") ||
matchOption(option, "apidocmap") ||
matchOption(option, "d") ||
matchOption(option, "view") ||
matchOption(option, "inferreltype") ||
matchOption(option, "inferdepvis") ||
matchOption(option, "collpackages") ||
matchOption(option, "nodesep") ||
matchOption(option, "ranksep") ||
matchOption(option, "dotexecutable") ||
matchOption(option, "link"))
return 2;
else if(matchOption(option, "contextPattern") ||
matchOption(option, "linkoffline"))
return 3;
else
return 0;
} | [
"Return the number of arguments associated with the specified option.\nThe return value includes the actual option.\nWill return 0 if the option is not supported."
] | [
"Merge another AbstractTransition's states into this object, such that the other AbstractTransition\ncan be discarded.\n\n@param another\n@return true if the merge is successful.",
"Sets the ojbQuery, needed only as long we\ndon't support the soda constraint stuff.\n@param ojbQuery The ojbQuery to set",
"Prepare a parallel HTTP OPTION Task.\n\n@param url\nthe UrlPostfix: e.g. in http://localhost:8080/index.html.,the url is \"/index.html\"\n@return the parallel task builder",
"Return a product descriptor for a specific strike.\n\n@param referenceDate The reference date (translating the maturity floating point date to dates.\n@param index The index corresponding to the strike grid.\n@return a product descriptor for a specific strike.\n@throws ArrayIndexOutOfBoundsException Thrown if index is out of bound.",
"Exit the Application",
"Comparator against other element.\n\n@param otherElement The other element.\n@param logging Whether to do logging.\n@return Whether the elements are equal.",
"<<<<<< measureUntilFull helper methods",
"Extract definition records from the table and divide into groups.",
"Return the discount factor within a given model context for a given maturity.\n@param model The model used as a context (not required for this class).\n@param maturity The maturity in terms of ACT/365 daycount form this curve reference date. Note that this parameter might get rescaled to a different time parameter.\n@see net.finmath.marketdata.model.curves.DiscountCurveInterface#getDiscountFactor(net.finmath.marketdata.model.AnalyticModelInterface, double)"
] |
static PlexusConfiguration convert(ModelNode configuration, ModelNode jsonSchema, String extensionId, String id) {
ConversionContext ctx = new ConversionContext();
ctx.currentSchema = jsonSchema;
ctx.rootSchema = jsonSchema;
ctx.pushTag(extensionId);
ctx.id = id;
return convert(configuration, ctx);
} | [
"visibility increased for testing"
] | [
"Creates an operation to read a resource.\n\n@param address the address to create the read for\n@param recursive whether to search recursively or not\n\n@return the operation",
"Called when remote end send a message to this connection\n@param receivedMessage the message received\n@return this context",
"Remove all unnecessary comments from a lexer or parser file",
"Use this API to fetch csvserver_cachepolicy_binding resources of given name .",
"Find out which field in the incoming message contains the payload that is.\ndelivered to the service method.",
"Get the TagsInterface for working with Flickr Tags.\n\n@return The TagsInterface",
"Calculates the column width according to its type.\n@param _property the property.\n@return the column width.",
"Generates a Map of query parameters for Module regarding the filters\n\n@return Map<String, Object>",
"characters callback."
] |
private void stopAllServersAndRemoveCamelContext(CamelContext camelContext) {
log.debug("Stopping all servers associated with {}", camelContext);
List<SingleBusLocatorRegistrar> registrars = locatorRegistrar.getAllRegistars(camelContext);
registrars.forEach(registrar -> registrar.stopAllServersAndRemoveCamelContext());
} | [
"Stops all servers linked with the current camel context\n\n@param camelContext"
] | [
"Creates a style definition used for the body element.\n@return The body style definition.",
"Update the BinderDescriptor of the declarationBinderRef.\n\n@param declarationBinderRef the ServiceReference<DeclarationBinder> of the DeclarationBinder",
"Use to generate a file based on generator node.",
"Create the exception assignment map.\n\n@param rows calendar rows\n@return exception assignment map",
"The only properties added to a relationship are the columns representing the index of the association.",
"Add the extra parameters which are passed as report parameters. The type of the parameter is \"guessed\" from the\nfirst letter of the parameter name.\n\n@param model view model\n@param request servlet request",
"Use this API to fetch appfwjsoncontenttype resource of given name .",
"Makes sure that the operation name and the address have been set and returns a ModelNode\nrepresenting the operation request.",
"Reads, stems, and prints the trees in the file.\n\n@param args Usage: WordStemmer file"
] |
public static boolean isAscii(Slice utf8)
{
int length = utf8.length();
int offset = 0;
// Length rounded to 8 bytes
int length8 = length & 0x7FFF_FFF8;
for (; offset < length8; offset += 8) {
if ((utf8.getLongUnchecked(offset) & TOP_MASK64) != 0) {
return false;
}
}
// Enough bytes left for 32 bits?
if (offset + 4 < length) {
if ((utf8.getIntUnchecked(offset) & TOP_MASK32) != 0) {
return false;
}
offset += 4;
}
// Do the rest one by one
for (; offset < length; offset++) {
if ((utf8.getByteUnchecked(offset) & 0x80) != 0) {
return false;
}
}
return true;
} | [
"Does the slice contain only 7-bit ASCII characters."
] | [
"Use this API to update onlinkipv6prefix.",
"compute Sin using Taylor Series.\n\n@param x An angle, in radians.\n@param nTerms Number of terms.\n@return Result.",
"Sets up this object to represent an argument that will be set to a\nconstant value.\n\n@param constantValue the constant value.",
"Reads an argument of type \"number\" from the request.",
"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",
"Get a list of people in a given photo.\n\n@param photoId\n@throws FlickrException",
"Use this API to unset the properties of Interface resource.\nProperties that need to be unset are specified in args array.",
"Reads numBytes bytes, and returns the corresponding string",
"True if deleted, false if not found."
] |
public void setDirectory(final String directory) {
this.directory = new File(this.configuration.getDirectory(), directory);
if (!this.directory.exists()) {
throw new IllegalArgumentException(String.format(
"Directory does not exist: %s.\n" +
"Configuration contained value %s which is supposed to be relative to " +
"configuration directory.",
this.directory, directory));
}
if (!this.directory.getAbsolutePath()
.startsWith(this.configuration.getDirectory().getAbsolutePath())) {
throw new IllegalArgumentException(String.format(
"All files and directories must be contained in the configuration directory the " +
"directory provided in the configuration breaks that contract: %s in config " +
"file resolved to %s.",
directory, this.directory));
}
} | [
"Set the directory and test that the directory exists and is contained within the Configuration\ndirectory.\n\n@param directory the new directory"
] | [
"Returns the total number of times the app has been launched\n@return Total number of app launches in int",
"Specify the class represented by this `ClassNode` is annotated\nby an annotation class specified by the name\n@param name the name of the annotation class\n@return this `ClassNode` instance",
"Obtains a local date in Discordian calendar system from the\nproleptic-year, month-of-year and day-of-month fields.\n\n@param prolepticYear the proleptic-year\n@param month the month-of-year\n@param dayOfMonth the day-of-month\n@return the Discordian local date, not null\n@throws DateTimeException if unable to create the date",
"Read a text stream into a single string.\n\n@param inputStream\nStream containing text. Will be closed on exit.\n@return The contents, or null on error.",
"Extract the subscription ID from a resource ID string.\n@param id the resource ID string\n@return the subscription ID",
"Converts the real matrix into a complex matrix.\n\n@param input Real matrix. Not modified.\n@param output Complex matrix. Modified.",
"Record a new event.",
"Create the time entry map.\n\n@param rows work pattern rows\n@return time entry map",
"Adds one or several attributes to facet on for the next queries.\n\n@param attributes one or more attribute names.\n@return this {@link Searcher} for chaining."
] |
public static synchronized ExecutionStatistics get()
{
Thread currentThread = Thread.currentThread();
if (stats.get(currentThread) == null)
{
stats.put(currentThread, new ExecutionStatistics());
}
return stats.get(currentThread);
} | [
"Gets the instance associated with the current thread."
] | [
"Sets the current switch index based on object name.\nThis function finds the child of the scene object\nthis component is attached to and sets the switch\nindex to reference it so this is the object that\nwill be displayed.\n\nIf it is out of range, none of the children will be shown.\n@param childName name of child to select\n@see GVRSceneObject#getChildByIndex(int)",
"Another method to force an input string into a fixed width field\nand set it on the right with the left side filled with space ' ' characters.\n\n@param input input string\n@param width required width\n@return formatted string",
"Returns the Set of entities recognized by this Classifier.\n\n@return The Set of entities recognized by this Classifier.",
"Execute JavaScript in the browser.\n\n@param code The code to execute.\n@return The return value of the JavaScript.\n@throws CrawljaxException when javascript execution failed.",
"Tries to stop the JLAN server and return after it is stopped, but will also return if the thread hasn't stopped after MAX_SHUTDOWN_WAIT_MILLIS.",
"Return true if the values of the two vectors are equal when cast as ints.\n\n@param a first vector to compare\n@param b second vector to compare\n@return true if the values of the two vectors are equal when cast as ints",
"return the workspace size needed for ctc",
"Filters a dot at the end of the passed package name if present.\n\n@param pkgName\na package name\n@return a filtered package name",
"Adds the specified serie column to the dataset with custom label expression.\n\n@param column the serie column\n@param labelExpression column the custom label expression"
] |
private void writeFields(String objectName, FieldContainer container, FieldType[] fields) throws IOException
{
m_writer.writeStartObject(objectName);
for (FieldType field : fields)
{
Object value = container.getCurrentValue(field);
if (value != null)
{
writeField(field, value);
}
}
m_writer.writeEndObject();
} | [
"Write a set of fields from a field container to a JSON file.\n@param objectName name of the object, or null if no name required\n@param container field container\n@param fields fields to write"
] | [
"Print the String features generated from a IN",
"Create a Task instance from a Phoenix activity.\n\n@param activity Phoenix activity data",
"Split string content into list\n@param content String content\n@return list",
"Generate a schedule for the given start and end date.\n\n@param referenceDate The reference date (corresponds to \\( t = 0 \\).\n@param startDate The start date.\n@param endDate The end date.\n@return The schedule",
"Use this API to fetch all the cacheobject resources that are configured on netscaler.",
"Checks to see if the matrix is symmetric to within tolerance.\n\n@param A Matrix being tested. Not modified.\n@param tol Tolerance that defines how similar two values must be to be considered identical\n@return true if symmetric or false if not",
"Restores a trashed folder back to its original location.\n@param folderID the ID of the trashed folder.\n@return info about the restored folder.",
"Marshal the assertion as a JSON object.\n\n@param assertion the assertion to marshal",
"Move the SQL value to the next one for version processing."
] |
@Nonnull
private static Properties findDefaultProperties() {
final InputStream in = SourceCodeFormatter.class.getClassLoader().getResourceAsStream(DEFAULT_PROPERTIES_PATH);
final Properties p = new Properties();
try {
p.load(in);
} catch (final IOException e) {
throw new RuntimeException(String.format("Can not load resource %s", DEFAULT_PROPERTIES_PATH));
}
return p;
} | [
"Gets the default options to be passed when no custom properties are given.\n\n@return properties with formatter options"
] | [
"Add a raw statement as part of the where that can be anything that the database supports. Using more structured\nmethods is recommended but this gives more control over the query and allows you to utilize database specific\nfeatures.\n\n@param rawStatement\nThe statement that we should insert into the WHERE.\n\n@param args\nOptional arguments that correspond to any ? specified in the rawStatement. Each of the arguments must\nhave either the corresponding columnName or the sql-type set. <b>WARNING,</b> you cannot use the\n{@code SelectArg(\"columnName\")} constructor since that sets the _value_, not the name. Use\n{@code new SelectArg(\"column-name\", null);}.",
"Determines the offset code of a forward contract from a schedule. Rounds the average period length to full months.\n\n@param schedule The schedule.\n@return The offset code as String",
"Cache key calculation.\n@param sql\n@param resultSetType\n@param resultSetConcurrency\n@return cache key",
"All the indexes defined in the database. Type widening means that the returned Index objects\nare limited to the name, design document and type of the index and the names of the fields.\n\n@return a list of defined indexes with name, design document, type and field names.",
"Create the label for a grid line.\n\n@param value the value of the line\n@param unit the unit that the value is in",
"Use this API to disable Interface resources of given names.",
"END ODO CHANGES",
"Map Synchro constraints to MPXJ constraints.\n\n@param task task\n@param row Synchro constraint data",
"Obtain matching paths for a request\n\n@param overrideType type of override\n@param client Client\n@param profile Profile\n@param uri URI\n@param requestType type of request\n@param pathTest If true this will also match disabled paths\n@return Collection of matching endpoints\n@throws Exception exception"
] |
private void checkAndAddForbiddenStrings(final List<String> forbiddenSubStrings) {
for( String forbidden : forbiddenSubStrings ) {
if( forbidden == null ) {
throw new NullPointerException("forbidden substring should not be null");
}
this.forbiddenSubStrings.add(forbidden);
}
} | [
"Adds each forbidden substring, checking that it's not null.\n\n@param forbiddenSubStrings\nthe forbidden substrings\n@throws NullPointerException\nif a forbidden substring is null"
] | [
"Applies the matrices computed from the scene object's\nlinked to the skeleton bones to the current pose.\n@see #applyPose(GVRPose, int)\n@see #setPose(GVRPose)",
"Parse the string representation of a timestamp.\n\n@param value string representation\n@return Java representation",
"returns a sorted array of enum constants",
"Transform the given bytes into an object.\n\n@param bytes The bytes to construct the object from\n@return The object constructed",
"handles when a member leaves and hazelcast partition data is lost. We want\nto find the Futures that are waiting on lost data and error them",
"Gets the actual key - will create a new row with the max key of table if it\ndoes not exist.\n@param field\n@return\n@throws SequenceManagerException",
"Get the subsystem deployment model root.\n\n<p>\nIf the subsystem resource does not exist one will be created.\n</p>\n\n@param subsystemName the subsystem name.\n\n@return the model",
"If the \"org.talend.esb.sam.agent.log.messageContent\" property value is \"true\" then log the message content\nIf it is \"false\" then skip the message content logging\nElse fall back to global property \"log.messageContent\"\n\n@param message\n@param logMessageContent\n@param logMessageContentOverride\n@return",
"calculate and set position to menu items"
] |
protected long getUniqueLong(FieldDescriptor field) throws SequenceManagerException
{
boolean needsCommit = false;
long result = 0;
/*
arminw:
use the associated broker instance, check if broker was in tx or
we need to commit used connection.
*/
PersistenceBroker targetBroker = getBrokerForClass();
if(!targetBroker.isInTransaction())
{
targetBroker.beginTransaction();
needsCommit = true;
}
try
{
// lookup sequence name
String sequenceName = calculateSequenceName(field);
try
{
result = buildNextSequence(targetBroker, field.getClassDescriptor(), sequenceName);
/*
if 0 was returned we assume that the stored procedure
did not work properly.
*/
if (result == 0)
{
throw new SequenceManagerException("No incremented value retrieved");
}
}
catch (Exception e)
{
// maybe the sequence was not created
log.info("Could not grab next key, message was " + e.getMessage() +
" - try to write a new sequence entry to database");
try
{
// on create, make sure to get the max key for the table first
long maxKey = SequenceManagerHelper.getMaxForExtent(targetBroker, field);
createSequence(targetBroker, field, sequenceName, maxKey);
}
catch (Exception e1)
{
String eol = SystemUtils.LINE_SEPARATOR;
throw new SequenceManagerException(eol + "Could not grab next id, failed with " + eol +
e.getMessage() + eol + "Creation of new sequence failed with " +
eol + e1.getMessage() + eol, e1);
}
try
{
result = buildNextSequence(targetBroker, field.getClassDescriptor(), sequenceName);
}
catch (Exception e1)
{
throw new SequenceManagerException("Could not grab next id although a sequence seems to exist", e);
}
}
}
finally
{
if(targetBroker != null && needsCommit)
{
targetBroker.commitTransaction();
}
}
return result;
} | [
"Gets the actual key - will create a new row with the max key of table if it\ndoes not exist.\n@param field\n@return\n@throws SequenceManagerException"
] | [
"Create a TableAlias for path or userAlias\n@param aTable\n@param aPath\n@param aUserAlias\n@return TableAlias",
"Convert subQuery to SQL\n@param subQuery the subQuery value of SelectionCriteria",
"Use this API to add policydataset.",
"Sets the request type for this ID. Defaults to GET\n\n@param pathId ID of path\n@param requestType type of request to service",
"Create a Map composed of the entries of the first map minus the\nentries of the given map.\n\n@param self a map object\n@param removeMe the entries to remove from the map\n@return the resulting map\n@since 1.7.4",
"Returns a resource wrapper created from the input.\n\nThe wrapped result of {@link #convertRawResource(CmsObject, Object)} is returned.\n\n@param cms the current OpenCms user context\n@param input the input to create a resource from\n\n@return a resource wrapper created from the given Object\n\n@throws CmsException in case of errors accessing the OpenCms VFS for reading the resource",
"Update the content of the tables.",
"Used for DI frameworks to inject values into stages.",
"Use this API to login into Netscaler.\n@param username Username\n@param password Password for the Netscaler.\n@param timeout timeout for netscaler session.Default is 1800secs\n@return status of the operation performed.\n@throws Exception nitro exception is thrown."
] |
private long getTime(Date start, Date end, long target, boolean after)
{
long total = 0;
if (start != null && end != null)
{
Date startTime = DateHelper.getCanonicalTime(start);
Date endTime = DateHelper.getCanonicalTime(end);
Date startDay = DateHelper.getDayStartDate(start);
Date finishDay = DateHelper.getDayStartDate(end);
//
// Handle the case where the end of the range is at midnight -
// this will show up as the start and end days not matching
//
if (startDay.getTime() != finishDay.getTime())
{
endTime = DateHelper.addDays(endTime, 1);
}
int diff = DateHelper.compare(startTime, endTime, target);
if (diff == 0)
{
if (after == true)
{
total = (endTime.getTime() - target);
}
else
{
total = (target - startTime.getTime());
}
}
else
{
if ((after == true && diff < 0) || (after == false && diff > 0))
{
total = (endTime.getTime() - startTime.getTime());
}
}
}
return (total);
} | [
"Calculates how much of a time range is before or after a\ntarget intersection point.\n\n@param start time range start\n@param end time range end\n@param target target intersection point\n@param after true if time after target required, false for time before\n@return length of time in milliseconds"
] | [
"Find all the node representing the entity.\n\n@param executionEngine the {@link GraphDatabaseService} used to run the query\n@return an iterator over the nodes representing an entity",
"Moves to the next step.",
"Removes double-quotes from around a string\n@param str\n@return",
"2-D Integer array to double array.\n\n@param array Integer array.\n@return Double array.",
"Handles the file deletions.\n\n@param cms the CMS context to use\n@param toDelete the resources to delete\n\n@throws CmsException if something goes wrong",
"Returns requested content types or default content type if none found.\n\n@return Requested content types or default content type if none found.",
"Converts Observable of list to Observable of Inner.\n@param innerList list to be converted.\n@param <InnerT> type of inner.\n@return Observable for list of inner.",
"Checks whether the specified event name is restricted. If it is,\nthen create a pending error, and abort.\n\n@param name The event name\n@return Boolean indication whether the event name is restricted",
"Checks the available space and sets max-height to the details field-set."
] |
public static String encodeUserInfo(String userInfo, String encoding) throws UnsupportedEncodingException {
return HierarchicalUriComponents.encodeUriComponent(userInfo, encoding, HierarchicalUriComponents.Type.USER_INFO);
} | [
"Encodes the given URI user info with the given encoding.\n@param userInfo the user info to be encoded\n@param encoding the character encoding to encode to\n@return the encoded user info\n@throws UnsupportedEncodingException when the given encoding parameter is not supported"
] | [
"Runs a method call with retries.\n@param pjp a {@link ProceedingJoinPoint} representing an annotated\nmethod call.\n@param retryableAnnotation the {@link org.fishwife.jrugged.aspects.Retryable}\nannotation that wrapped the method.\n@throws Throwable if the method invocation itself throws one during execution.\n@return The return value from the method call.",
"Presents the Cursor Settings to the User. Only works if scene is set.",
"Mark root of this task task group depends on the given task group's root.\nThis ensure this task group's root get picked for execution only after the completion\nof all tasks in the given group.\n\n@param dependencyTaskGroup the task group that this task group depends on",
"Parses the resource String id and get back the int res id\n@param context\n@param id String resource id\n@return int resource id",
"Sets the appropriate headers to response of this request.\n\n@param response The HttpServletResponse response object.",
"Throws an exception if at least one results directory is missing.",
"replace the counter for K1-index o by new counter c",
"Checks that excess arguments match the vararg signature parameter.\n@param params\n@param args\n@return -1 if no match, 0 if all arguments matches the vararg type and >0 if one or more vararg argument is\nassignable to the vararg type, but still not an exact match",
"Attempts to clear the global log context used for embedded servers."
] |
@Pure
public static <T> List<T> reverseView(List<T> list) {
return Lists.reverse(list);
} | [
"Provides a reverse view on the given list which is especially useful to traverse a list backwards in a for-each\nloop. The list itself is not modified by calling this method.\n\n@param list\nthe list whose elements should be traversed in reverse. May not be <code>null</code>.\n@return a list with the same elements as the given list, in reverse"
] | [
"Stop interpolating playback position for all active players.",
"Process hours in a working day.\n\n@param calendar project calendar\n@param dayRecord working day data",
"this remove the linebreak.\n\n@param input\nthe input\n@param patternStr\nthe pattern str\n@return the string",
"Use this API to fetch all the appqoepolicy resources that are configured on netscaler.",
"Compute singular values and U and V at the same time",
"Resize picture to desired size.\n\n@param width Desired width.\n@param height Desired height.\n@throws IllegalArgumentException if {@code width} or {@code height} is less than 0 or both are\n0.",
"Gets information about this user.\n@param fields the optional fields to retrieve.\n@return info about this user.",
"Start ssh session and obtain session.\n\n@return the session",
"get an AdminClient from the cache if exists, if not create new one\nand return it. This method is non-blocking.\n\nAll AdminClient returned from checkout, once after the completion of\nusage must be returned to the pool by calling checkin. If not,\nthere will be leak of AdminClients (connections, threads and file handles).\n\n@return AdminClient"
] |
public Object getRealValue()
{
if(valueRealSubject != null)
{
return valueRealSubject;
}
else
{
TransactionExt tx = getTransaction();
if((tx != null) && tx.isOpen())
{
prepareValueRealSubject(tx.getBroker());
}
else
{
if(getPBKey() != null)
{
PBCapsule capsule = new PBCapsule(getPBKey(), null);
try
{
prepareValueRealSubject(capsule.getBroker());
}
finally
{
capsule.destroy();
}
}
else
{
getLog().warn("No tx, no PBKey - can't materialise value with Identity " + getKeyOid());
}
}
}
return valueRealSubject;
} | [
"Returns the real value object."
] | [
"Get the collection of untagged photos.\n\nThis method requires authentication with 'read' permission.\n\n@param perPage\n@param page\n@return A Collection of Photos\n@throws FlickrException",
"Returns the bundle jar classpath element.",
"Calculate start dates for a weekly recurrence.\n\n@param calendar current date\n@param frequency frequency\n@param dates array of start dates",
"Open the event stream\n\n@return true if successfully opened, false if not",
"Takes the file, reads it in, and prints out the likelihood of each possible\nlabel at each point.\n\n@param filename\nThe path to the specified file",
"Adds an HTTP header to this request.\n@param key the header key.\n@param value the header value.",
"This method extracts project properties from a Phoenix file.\n\n@param phoenixSettings Phoenix settings\n@param storepoint Current storepoint",
"Gets the Symmetric Kullback-Leibler distance.\nThis metric is valid only for real and positive P and Q.\n\n@param p P vector.\n@param q Q vector.\n@return The Symmetric Kullback Leibler distance between p and q.",
"Specify the string and the int identifying which word shaper to\nuse and this returns the result of using that wordshaper on the String.\n\n@param inStr String to calculate word shape of\n@param wordShaper Constant for which shaping formula to use\n@param knownLCWords A Collection of known lowercase words, which some shapers use\nto decide the class of capitalized words.\n<i>Note: while this code works with any Collection, you should\nprovide a Set for decent performance.</i> If this parameter is\nnull or empty, then this option is not used (capitalized words\nare treated the same, regardless of whether the lowercased\nversion of the String has been seen).\n@return The wordshape String"
] |
@Pure
public static <P1, P2, RESULT> Function1<P2, RESULT> curry(final Function2<? super P1, ? super P2, ? extends RESULT> function,
final P1 argument) {
if (function == null)
throw new NullPointerException("function");
return new Function1<P2, RESULT>() {
@Override
public RESULT apply(P2 p) {
return function.apply(argument, p);
}
};
} | [
"Curries a function that takes two arguments.\n\n@param function\nthe original function. May not be <code>null</code>.\n@param argument\nthe fixed first argument of {@code function}.\n@return a function that takes one argument. Never <code>null</code>."
] | [
"Compare the controlDOM and testDOM and save and return the differences in a list.\n\n@return list with differences",
"Add a module to a module tree\n\n@param module\n@param tree",
"Creates the graphic element to be shown when the datasource is empty",
"Returns all methods for a specific group\n\n@param groupId group ID to remove methods from\n@param filters array of method types to filter by, null means no filter\n@return Collection of methods found\n@throws Exception exception",
"Use this API to fetch all the authenticationradiusaction resources that are configured on netscaler.",
"Parses whole value as list attribute\n@deprecated in favour of using {@link AttributeParser attribute parser}\n@param value String with \",\" separated string elements\n@param operation operation to with this list elements are added\n@param reader xml reader from where reading is be done\n@throws XMLStreamException if {@code value} is not valid",
"This main method provides an easy command line tool to compare two\nschemas.",
"Use this API to fetch vpnvserver_auditnslogpolicy_binding resources of given name .",
"Gets the progress from response.\n\n@param myResponse\nthe my response\n@return the progress from response"
] |
private void setExpressionForPrecalculatedTotalValue(
DJCrosstabColumn[] auxCols, DJCrosstabRow[] auxRows, JRDesignExpression measureExp, DJCrosstabMeasure djmeasure,
DJCrosstabColumn crosstabColumn, DJCrosstabRow crosstabRow, String meausrePrefix) {
String rowValuesExp = "new Object[]{";
String rowPropsExp = "new String[]{";
for (int i = 0; i < auxRows.length; i++) {
if (auxRows[i].getProperty()== null)
continue;
rowValuesExp += "$V{" + auxRows[i].getProperty().getProperty() +"}";
rowPropsExp += "\"" + auxRows[i].getProperty().getProperty() +"\"";
if (i+1<auxRows.length && auxRows[i+1].getProperty()!= null){
rowValuesExp += ", ";
rowPropsExp += ", ";
}
}
rowValuesExp += "}";
rowPropsExp += "}";
String colValuesExp = "new Object[]{";
String colPropsExp = "new String[]{";
for (int i = 0; i < auxCols.length; i++) {
if (auxCols[i].getProperty()== null)
continue;
colValuesExp += "$V{" + auxCols[i].getProperty().getProperty() +"}";
colPropsExp += "\"" + auxCols[i].getProperty().getProperty() +"\"";
if (i+1<auxCols.length && auxCols[i+1].getProperty()!= null){
colValuesExp += ", ";
colPropsExp += ", ";
}
}
colValuesExp += "}";
colPropsExp += "}";
String measureProperty = meausrePrefix + djmeasure.getProperty().getProperty();
String expText = "((("+DJCRosstabMeasurePrecalculatedTotalProvider.class.getName()+")$P{crosstab-measure__"+measureProperty+"_totalProvider}).getValueFor( "
+ colPropsExp +", "
+ colValuesExp +", "
+ rowPropsExp
+ ", "
+ rowValuesExp
+" ))";
if (djmeasure.getValueFormatter() != null){
String fieldsMap = ExpressionUtils.getTextForFieldsFromScriptlet();
String parametersMap = ExpressionUtils.getTextForParametersFromScriptlet();
String variablesMap = ExpressionUtils.getTextForVariablesFromScriptlet();
String stringExpression = "((("+DJValueFormatter.class.getName()+")$P{crosstab-measure__"+measureProperty+"_vf}).evaluate( "
+ "("+expText+"), " + fieldsMap +", " + variablesMap + ", " + parametersMap +" ))";
measureExp.setText(stringExpression);
measureExp.setValueClassName(djmeasure.getValueFormatter().getClassName());
} else {
// String expText = "((("+DJCRosstabMeasurePrecalculatedTotalProvider.class.getName()+")$P{crosstab-measure__"+djmeasure.getProperty().getProperty()+"_totalProvider}).getValueFor( "
// + colPropsExp +", "
// + colValuesExp +", "
// + rowPropsExp
// + ", "
// + rowValuesExp
// +" ))";
//
log.debug("text for crosstab total provider is: " + expText);
measureExp.setText(expText);
// measureExp.setValueClassName(djmeasure.getValueFormatter().getClassName());
String valueClassNameForOperation = ExpressionUtils.getValueClassNameForOperation(djmeasure.getOperation(),djmeasure.getProperty());
measureExp.setValueClassName(valueClassNameForOperation);
}
} | [
"set proper expression text invoking the DJCRosstabMeasurePrecalculatedTotalProvider for the cell\n@param auxRows\n@param auxCols\n@param measureExp\n@param djmeasure\n@param crosstabColumn\n@param crosstabRow\n@param meausrePrefix"
] | [
"Tests whether the ClassNode implements the specified method name\n\n@param classNode The ClassNode\n@param methodName The method name\n@param argTypes\n@return True if it implements the method",
"Use this API to fetch dnspolicy_dnsglobal_binding resources of given name .",
"Log original response\n\n@param httpServletResponse\n@param history\n@throws URIException",
"Adds all fields declared directly in the object's class to the output\n@return this",
"Adds an access constraint to the set used with the attribute\n@param accessConstraint the constraint\n@return a builder that can be used to continue building the attribute definition",
"Process stop.\n\n@param endpoint the endpoint\n@param eventType the event type",
"Populate the UDF values for this entity.\n\n@param tableName parent table name\n@param type entity type\n@param container entity\n@param uniqueID entity Unique ID",
"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.",
"this method mimics EMC behavior"
] |
public void processAnonymousField(Properties attributes) throws XDocletException
{
if (!attributes.containsKey(ATTRIBUTE_NAME))
{
throw new XDocletException(Translator.getString(XDocletModulesOjbMessages.class,
XDocletModulesOjbMessages.PARAMETER_IS_REQUIRED,
new String[]{ATTRIBUTE_NAME}));
}
String name = attributes.getProperty(ATTRIBUTE_NAME);
FieldDescriptorDef fieldDef = _curClassDef.getField(name);
String attrName;
if (fieldDef == null)
{
fieldDef = new FieldDescriptorDef(name);
_curClassDef.addField(fieldDef);
}
fieldDef.setAnonymous();
LogHelper.debug(false, OjbTagsHandler.class, "processAnonymousField", " Processing anonymous field "+fieldDef.getName());
attributes.remove(ATTRIBUTE_NAME);
for (Enumeration attrNames = attributes.propertyNames(); attrNames.hasMoreElements(); )
{
attrName = (String)attrNames.nextElement();
fieldDef.setProperty(attrName, attributes.getProperty(attrName));
}
fieldDef.setProperty(PropertyHelper.OJB_PROPERTY_ACCESS, "anonymous");
} | [
"Processes an anonymous field definition specified at the class level.\n\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\[email protected] type=\"content\"\[email protected] name=\"attributes\" optional=\"true\" description=\"Attributes of the field as name-value pairs 'name=value',\nseparated by commas\"\[email protected] name=\"autoincrement\" optional=\"true\" description=\"Whether the field is\nauto-incremented\" values=\"true,false\"\[email protected] name=\"column\" optional=\"true\" description=\"The column for the field\"\[email protected] name=\"conversion\" optional=\"true\" description=\"The fully qualified name of the\nconversion for the field\"\[email protected] name=\"default-fetch\" optional=\"true\" description=\"The default-fetch setting\"\nvalues=\"true,false\"\[email protected] name=\"documentation\" optional=\"true\" description=\"Documentation on the field\"\[email protected] name=\"id\" optional=\"true\" description=\"The position of the field in the class\ndescriptor\"\[email protected] name=\"indexed\" optional=\"true\" description=\"Whether the field is indexed\"\nvalues=\"true,false\"\[email protected] name=\"jdbc-type\" optional=\"true\" description=\"The jdbc type of the column\"\[email protected] name=\"length\" optional=\"true\" description=\"The length of the column\"\[email protected] name=\"locking\" optional=\"true\" description=\"Whether the field supports locking\"\nvalues=\"true,false\"\[email protected] name=\"name\" optional=\"false\" description=\"The name of the field\"\[email protected] name=\"nullable\" optional=\"true\" description=\"Whether the field is nullable\"\nvalues=\"true,false\"\[email protected] name=\"precision\" optional=\"true\" description=\"The precision of the column\"\[email protected] name=\"primarykey\" optional=\"true\" description=\"Whether the field is a primarykey\"\nvalues=\"true,false\"\[email protected] name=\"scale\" optional=\"true\" description=\"The scale of the column\"\[email protected] name=\"sequence-name\" optional=\"true\" description=\"The name of the sequence for\nincrementing the field\"\[email protected] name=\"table\" optional=\"true\" description=\"The table of the field (not implemented\nyet)\"\[email protected] name=\"update-lock\" optional=\"true\" description=\"Can be set to false if the persistent attribute is\nused for optimistic locking AND the dbms should update the lock column itself (default is true). Can only be set for\nTIMESTAMP and INTEGER columns\" values=\"true,false\""
] | [
"Removes the given service provider factory from the set of\nproviders for the service.\n\n@param serviceName\nThe fully qualified name of the service interface.\n@param factory\nA factory for creating a specific type of service\nprovider. May be <tt>null</tt> in which case this\nmethod does nothing.\n@throws IllegalArgumentException if serviceName is <tt>null</tt>",
"Transmits the SerialMessage to a single Z-Wave Node.\nSets the transmission options as well.\n@param serialMessage the Serial message to send.",
"Create a set 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 set.\n@return A set consisting of the items from the Iterable.",
"Pre API 11, this does an alpha animation.\n\n@param progress",
"Notify all WorkerListeners currently registered for the given WorkerEvent.\n@param event the WorkerEvent that occurred\n@param worker the Worker that the event occurred in\n@param queue the queue the Worker is processing\n@param job the Job related to the event (only supply for JOB_PROCESS, JOB_EXECUTE, JOB_SUCCESS, and\nJOB_FAILURE events)\n@param runner the materialized object that the Job specified (only supply for JOB_EXECUTE and\nJOB_SUCCESS events)\n@param result the result of the successful execution of the Job (only set for JOB_SUCCESS and if the Job was\na Callable that returned a value)\n@param t the Throwable that caused the event (only supply for JOB_FAILURE and ERROR events)",
"Extract a duration amount from the assignment, converting a percentage\ninto an actual duration.\n\n@param task parent task\n@param work duration from assignment\n@return Duration instance",
"Sets the maximum time to wait before a call to getConnection is timed out.\n\nSetting this to zero is similar to setting it to Long.MAX_VALUE\n\n@param connectionTimeout\n@param timeUnit the unit of the connectionTimeout argument",
"Creates the \"Add key\" button.\n@return the \"Add key\" button.",
"Trade the request token for an access token, this is step three of authorization.\n@param oAuthRequestToken\nthis is the token returned by the {@link AuthInterface#getRequestToken} call.\n@param verifier"
] |
public static base_responses unset(nitro_service client, String sitename[], String args[]) throws Exception {
base_responses result = null;
if (sitename != null && sitename.length > 0) {
gslbsite unsetresources[] = new gslbsite[sitename.length];
for (int i=0;i<sitename.length;i++){
unsetresources[i] = new gslbsite();
unsetresources[i].sitename = sitename[i];
}
result = unset_bulk_request(client, unsetresources,args);
}
return result;
} | [
"Use this API to unset the properties of gslbsite resources.\nProperties that need to be unset are specified in args array."
] | [
"Use this API to fetch all the appfwwsdl resources that are configured on netscaler.",
"Locate a child block by byte pattern and validate by\nchecking the length of the string we are expecting\nto follow the pattern.\n\n@param bufferIndex start index\n@return true if a child block starts at this point",
"Set the query parameter values overriding all existing query values for\nthe same parameter. If no values are given, the query parameter is removed.\n@param name the query parameter name\n@param values the query parameter values\n@return this UriComponentsBuilder",
"Checks the id value.\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",
"Clones the cluster by constructing a new one with same name, partition\nlayout, and nodes.\n\n@param cluster\n@return clone of Cluster cluster.",
"Set the dates for the specified photo.\n\nThis method requires authentication with 'write' permission.\n\n@param photoId\nThe photo ID\n@param datePosted\nThe date the photo was posted or null\n@param dateTaken\nThe date the photo was taken or null\n@param dateTakenGranularity\nThe granularity of the taken date or null\n@throws FlickrException",
"Enforces the correct srid on incoming features.\n\n@param feature\nobject to enforce srid on\n@throws LayerException\nproblem getting or setting srid",
"Creates the node corresponding to an entity.\n\n@param executionEngine the {@link GraphDatabaseService} used to run the query\n@param columnValues the values in {@link org.hibernate.ogm.model.key.spi.EntityKey#getColumnValues()}\n@return the corresponding node",
"Checks to see if a subsystem resource has already been registered for the deployment.\n\n@param subsystemName the name of the subsystem\n\n@return {@code true} if the subsystem exists on the deployment otherwise {@code false}"
] |
public static final Number parseExtendedAttributeCurrency(String value)
{
Number result;
if (value == null)
{
result = null;
}
else
{
result = NumberHelper.getDouble(Double.parseDouble(correctNumberFormat(value)) / 100);
}
return result;
} | [
"Parse an extended attribute currency value.\n\n@param value string representation\n@return currency value"
] | [
"Renames this file.\n\n@param newName the new name of the file.",
"returns an Array with an Identities PK VALUES\n@throws PersistenceBrokerException if there is an erros accessing o field values",
"Convert the continuous values into discrete values by chopping up\nthe distribution into several equally-sized intervals.",
"Check if a position is within a circle\n\n@param x x position\n@param y y position\n@param centerX center x of circle\n@param centerY center y of circle\n@return true if within circle, false otherwise",
"Curries a function that takes three arguments.\n\n@param function\nthe original function. May not be <code>null</code>.\n@param argument\nthe fixed first argument of {@code function}.\n@return a function that takes two arguments. Never <code>null</code>.",
"Decides and returns the preferred deployment credentials to use from this builder settings and selected server\n\n@param deployerOverrider Deploy-overriding capable builder\n@param server Selected Artifactory server\n@return Preferred deployment credentials",
"This method changes the value of an agent's belief through its external\naccess\n\n@param agent_name\nThe name of the agent to change a belief\n@param belief_name\nThe name of the belief to change\n@param new_value\nThe new value of the belief to be changed\n@param connector\nThe connector to get the external access",
"Renumbers all entity unique IDs.",
"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"
] |
public <Result, Param extends Resource> Result execWithTemporaryCaching(Param resource, IUnitOfWork<Result, Param> transaction) throws WrappedException {
CacheAdapter cacheAdapter = getOrCreate(resource);
IgnoreValuesMemento memento = cacheAdapter.ignoreNewValues();
try {
return transaction.exec(resource);
} catch (Exception e) {
throw new WrappedException(e);
} finally {
memento.done();
}
} | [
"The transaction will be executed with caching enabled. However, all newly cached values will be discarded as soon\nas the transaction is over.\n@since 2.1"
] | [
"Return cached object by key. The key will be concatenated with\ncurrent session id when fetching the cached object\n\n@param key\n@param <T>\nthe object type\n@return the cached object",
"Adds a listener to this collection.\n\n@param listener The listener to add",
"Add the steal information to the rebalancer state\n\n@param stealInfo The steal information to add",
"Given the key, figures out which partition on the local node hosts the key.\n\n@param key\n@return",
"Returns the default shared instance of the CleverTap SDK.\n\n@param context The Android context\n@return The {@link CleverTapAPI} object",
"Obtain collection of profiles\n\n@param model\n@return\n@throws Exception",
"Curries a procedure that takes three arguments.\n\n@param procedure\nthe original procedure. May not be <code>null</code>.\n@param argument\nthe fixed first argument of {@code procedure}.\n@return a procedure that takes two arguments. Never <code>null</code>.",
"Use picasso to render the video thumbnail into the thumbnail widget using a temporal\nplaceholder.\n\n@param video to get the rendered thumbnail.",
"This method writes resource data to an MSPDI file.\n\n@param project Root node of the MSPDI file"
] |
public static snmpmanager[] get(nitro_service service) throws Exception{
snmpmanager obj = new snmpmanager();
snmpmanager[] response = (snmpmanager[])obj.get_resources(service);
return response;
} | [
"Use this API to fetch all the snmpmanager resources that are configured on netscaler."
] | [
"Parse the XML for a collection as returned by getInfo call.\n\n@param collectionElement\n@return",
"There is a race condition that is not handled properly by the DialogFragment class.\nIf we don't check that this onDismiss callback isn't for the old progress dialog from before\nthe device orientation change, then this will cause the newly created dialog after the\norientation change to be dismissed immediately.",
"Returns the complete Grapes root URL\n\n@return String",
"Acquire a calendar instance.\n\n@return Calendar instance",
"Binds a script bundle to scene graph rooted at a scene object.\n@param scriptBundle\nThe {@code GVRScriptBundle} object containing script binding information.\n@param rootSceneObject\nThe root of the scene object tree to which the scripts are bound.\n@throws IOException if script bundle file cannot be read.\n@throws GVRScriptException if a script processing error occurs.",
"Calculate the arc length by angle and radius\n@param angle\n@return arc length",
"Handles the response of the SerialApiGetInitData request.\n@param incomingMlivessage the response message to process.",
"Queries a Search Index and returns grouped results in a map where key\nof the map is the groupName. In case the query didnt use grouping,\nan empty map is returned\n\n@param <T> Object type T\n@param query the Lucene query to be passed to the Search index\n@param classOfT The class of type T\n@return The result of the grouped search query as a ordered {@code Map<String,T> }",
"Creates necessary objects to make a chart an hyperlink\n\n@param design\n@param djlink\n@param chart\n@param name"
] |
private boolean isDepOfIdlArtifact(Artifact artifact, Map<String, Artifact> depsMap) {
List<String> depTrail = artifact.getDependencyTrail();
// depTrail can be null sometimes, which seems like a maven bug
if (depTrail != null) {
for (String name : depTrail) {
Artifact dep = depsMap.get(name);
if (dep != null && isIdlCalssifier(dep, classifier)) {
return true;
}
}
}
return false;
} | [
"Checks if the artifact is dependency of an dependent idl artifact\n@returns true if the artifact was a dependency of idl artifact"
] | [
"Checks if a property's type is valid to be included in the report.\n@param _property the property.\n@return true if the property is is of a valid type.",
"Log a warning for the resource at the provided address and a single attribute. The detail message is a default\n'Attributes are not understood in the target model version and this resource will need to be ignored on the target host.'\n\n@param address where warning occurred\n@param attribute attribute we are warning about",
"Prints and stores final result of the processing. This should be called\nafter finishing the processing of a dump. It will print the statistics\ngathered during processing and it will write a CSV file with usage counts\nfor every property.",
"Read remarks from a Gantt Designer file.\n\n@param gantt Gantt Designer file",
"Returns the currently scheduled job description identified by the given id.\n\n@param id the job id\n\n@return a job or <code>null</code> if not found",
"Convenience method to allow a cause. Grrrr.",
"Retrieve a finish date time in the form required by Phoenix.\n\n@param value Date instance\n@return formatted date time",
"Creates the row key of the given association row; columns present in the given association key will be obtained\nfrom there, all other columns from the given native association row.",
"List the greetings in the specified guestbook."
] |
protected Class getClassCacheEntry(String name) {
if (name == null) return null;
synchronized (classCache) {
return classCache.get(name);
}
} | [
"gets a class from the class cache. This cache contains only classes loaded through\nthis class loader or an InnerLoader instance. If no class is stored for a\nspecific name, then the method should return null.\n\n@param name of the class\n@return the class stored for the given name\n@see #removeClassCacheEntry(String)\n@see #setClassCacheEntry(Class)\n@see #clearCache()"
] | [
"Count the statements and property uses of an item or property document.\n\n@param usageStatistics\nstatistics object to store counters in\n@param statementDocument\ndocument to count the statements of",
"Converts from partitionId to nodeId. The list of partition IDs,\npartitionIds, is expected to be a \"replicating partition list\", i.e., the\nmapping from partition ID to node ID should be one to one.\n\n@param partitionIds List of partition IDs for which to find the Node ID\nfor the Node that owns the partition.\n@return List of node ids, one for each partition ID in partitionIds\n@throws VoldemortException If multiple partition IDs in partitionIds map\nto the same Node ID.",
"Send a beat grid update announcement to all registered listeners.\n\n@param player the player whose beat grid information has changed\n@param beatGrid the new beat grid associated with that player, if any",
"Returns a prefix length for which the range of this segment grouping matches the the block of addresses for that prefix.\n\nIf no such prefix exists, returns null\n\nIf this segment grouping represents a single value, returns the bit length\n\n@return the prefix length or null",
"It is required that T be Serializable",
"Starting with the given column index, will return the first column index\nwhich contains a colour that does not match the given color.",
"Flat the map of list of string to map of strings, with theoriginal values, seperated by comma",
"Add tags to a photo.\n\nThis method requires authentication with 'write' permission.\n\n@param photoId\nThe photo ID\n@param tags\nThe tags\n@throws FlickrException",
"Calculate the layout container size along the axis\n@param axis {@link Axis}\n@return size"
] |
public int color(Context ctx) {
if (mColorInt == 0 && mColorRes != -1) {
mColorInt = ContextCompat.getColor(ctx, mColorRes);
}
return mColorInt;
} | [
"a small helper to get the color from the colorHolder\n\n@param ctx\n@return"
] | [
"The local event will decide the next state of the document in question.\n\n@param <T> the type of class represented by the document in the change event.\n@return the local full document which may be null.",
"Takes an object and converts it to a string.\n\n@param mapper the object mapper\n@param object the object to convert\n@return json string",
"Sets currency symbol.\n\n@param symbol currency symbol",
"Returns true if the given candidate is a group that is filtered due to rule parameters in the current call graph.",
"Convert a Java String instance into the equivalent array of single or\ndouble bytes.\n\n@param value Java String instance representing text\n@param unicode true if double byte characters are required\n@return byte array representing the supplied text",
"Scans a single class for Swagger annotations - does not invoke ReaderListeners",
"called by timer thread",
"Read the file header data.\n\n@param is input stream",
"another media scan way"
] |
public static sslcipher[] get(nitro_service service) throws Exception{
sslcipher obj = new sslcipher();
sslcipher[] response = (sslcipher[])obj.get_resources(service);
return response;
} | [
"Use this API to fetch all the sslcipher resources that are configured on netscaler."
] | [
"Add a column to be set to a value for UPDATE statements. This will generate something like 'columnName =\nexpression' where the expression is built by the caller.\n\n<p>\nThe expression should have any strings escaped using the {@link #escapeValue(String)} or\n{@link #escapeValue(StringBuilder, String)} methods and should have any column names escaped using the\n{@link #escapeColumnName(String)} or {@link #escapeColumnName(StringBuilder, String)} methods.\n</p>",
"We have obtained metadata for a device, so store it and alert any listeners.\n\n@param update the update which caused us to retrieve this metadata\n@param data the metadata which we received",
"Set a new Cursor position if active and enabled.\n\n@param x x value of the position\n@param y y value of the position\n@param z z value of the position",
"Creates a new deployment for the path. If the path is a directory the content will be deployed exploded using\nthe file system location.\n\n@param content the path containing the content\n\n@return the deployment",
"Set an outline code value.\n\n@param index outline code index (1-10)\n@param value outline code value",
"Sets the bytecode compatibility mode\n\n@param version the bytecode compatibility mode",
"Transfer the data from the inputStream to the outputStream. Then close both streams.",
"Get the URI for the given statement.\n\n@param statement\nthe statement for which to create a URI\n@return the URI",
"Sinc function.\n\n@param x Value.\n@return Sinc of the value."
] |
public Model interpolateModel(Model model, File projectDir, ModelBuildingRequest config,
ModelProblemCollector problems) {
interpolateObject(model, model, projectDir, config, problems);
return model;
} | [
"Empirical data from 3.x, actual =40"
] | [
"Use this API to unset the properties of nsspparams resource.\nProperties that need to be unset are specified in args array.",
"returns a unique String for given field.\nthe returned uid is unique accross all tables.",
"Detailed request to track additional data about PUT, GET and GET_ALL\n\n@param timeNS The time in nanoseconds that the operation took to complete\n@param numEmptyResponses For GET and GET_ALL, how many keys were no values found\n@param valueBytes Total number of bytes across all versions of values' bytes\n@param keyBytes Total number of bytes in the keys\n@param getAllAggregatedCount Total number of keys returned for getAll calls",
"Prepares all files added for tus uploads.\n\n@param assemblyUrl the assembly url affiliated with the tus upload.\n@throws IOException when there's a failure with file retrieval.\n@throws ProtocolException when there's a failure with tus upload.",
"Returns an iterable containing the items in this folder and specifies which child fields to retrieve from the\nAPI.\n\n@param fields the fields to retrieve.\n@return an iterable containing the items in this folder.",
"Read holidays from the database and create calendar exceptions.",
"Get the bar size.\n\n@param settings Parameters for rendering the scalebar.",
"Dumps all properties of a material to stdout.\n\n@param material the material",
"Resamples a trajectory\n@param t Trajectory to resample\n@param n Resample rate\n@return Returns a resampled trajectory which contains every n'th position of t"
] |
@SuppressWarnings("unchecked")
public static <T> T getJlsDefaultValue(Class<T> type) {
if(!type.isPrimitive()) {
return null;
}
return (T) JLS_PRIMITIVE_DEFAULT_VALUES.get(type);
} | [
"See also JLS8, 4.12.5 Initial Values of Variables.\n\n@param type\n@return the default value for the given type as defined by JLS"
] | [
"Sets the whole day flag.\n@param isWholeDay flag, indicating if the event lasts whole days.",
"Promote a module in the Grapes server\n\n@param name\n@param version\n@throws GrapesCommunicationException\n@throws javax.naming.AuthenticationException",
"Optionally specify the variable name to use for the output of this condition",
"Format event to string buffer.\n\n@param sbuf\nstring buffer to receive formatted event, may not be null.\n@param event\nevent to format, may not be null.",
"Set the configuration property.\n\n@param key\n@param value\n@return self\n@see #ARCHIVE_ISOLATION_SYSTEM_PROPERTY\n@see #SHUTDOWN_HOOK_SYSTEM_PROPERTY\n@see #DEV_MODE_SYSTEM_PROPERTY\n@see ConfigurationKey",
"Use this API to add dnsview resources.",
"When all the elements in a sorted set are inserted with the same score, in order to force lexicographical\nordering, this command removes all elements in the sorted set between the lexicographical range specified.\n@param lexRange\n@return the number of elements removed.",
"Use this API to add ntpserver.",
"Determine whether or not a given serializedr is \"AVRO\" based\n\n@param serializerName\n@return"
] |
private void deliverDeviceUpdate(final DeviceUpdate update) {
for (DeviceUpdateListener listener : getUpdateListeners()) {
try {
listener.received(update);
} catch (Throwable t) {
logger.warn("Problem delivering device update to listener", t);
}
}
} | [
"Send a device update to all registered update listeners.\n\n@param update the device update that has just arrived"
] | [
"Send the message using the JavaMail session defined in the message\n\n@param mimeMessage Message to send",
"Calculates the Black-Scholes option value of a digital call option.\n\n@param initialStockValue The initial value of the underlying, i.e., the spot.\n@param riskFreeRate The risk free rate of the bank account numerarie.\n@param volatility The Black-Scholes volatility.\n@param optionMaturity The option maturity T.\n@param optionStrike The option strike.\n@return Returns the value of a European call option under the Black-Scholes model",
"Returns an empty model of a Dependency in Json\n\n@return String\n@throws IOException",
"Print a resource UID.\n\n@param value resource UID value\n@return resource UID string",
"Convert an Object to a Timestamp.",
"Compares two vectors and determines if they are numeric equals,\nindependent of its type.\n\n@param vector1\nthe first vector\n@param vector2\nthe second vector\n@return true if the vectors are numeric equals",
"Get the script for a given ID\n\n@param id ID of script\n@return Script if found, otherwise null",
"Set the property on the given object to the new value.\n\n@param object on which to set the property\n@param newValue the new value of the property\n@throws RuntimeException if the property could not be set",
"Creates a bridge accessory, capable of holding multiple child accessories. This has the\nadvantage over multiple standalone accessories of only requiring a single pairing from iOS for\nthe bridge.\n\n@param authInfo authentication information for this accessory. These values should be persisted\nand re-supplied on re-start of your application.\n@param label label for the bridge. This will show in iOS during pairing.\n@param manufacturer manufacturer of the bridge. This information is exposed to iOS for unknown\npurposes.\n@param model model of the bridge. This is also exposed to iOS for unknown purposes.\n@param serialNumber serial number of the bridge. Also exposed. Purposes also unknown.\n@return the bridge, from which you can {@link HomekitRoot#addAccessory add accessories} and\nthen {@link HomekitRoot#start start} handling requests.\n@throws IOException when mDNS cannot connect to the network"
] |
public static void printDocumentation() {
System.out
.println("********************************************************************");
System.out.println("*** Wikidata Toolkit: GenderRatioProcessor");
System.out.println("*** ");
System.out
.println("*** This program will download and process dumps from Wikidata.");
System.out
.println("*** It will compute the numbers of articles about humans across");
System.out
.println("*** Wikimedia projects, and in particular it will count the articles");
System.out
.println("*** for each sex/gender. Results will be stored in a CSV file.");
System.out.println("*** See source code for further details.");
System.out
.println("********************************************************************");
} | [
"Prints some basic documentation about this program."
] | [
"Write resource assignment workgroup.\n\n@param record resource assignment workgroup instance\n@throws IOException",
"Determines if a mouse event is inside a box.",
"Convert an array of column definitions into a map keyed by column name.\n\n@param columns array of column definitions\n@return map of column definitions",
"Update environment variables to an app.\n@param appName App name. See {@link #listApps} for a list of apps that can be used.\n@param config Key/Value pairs of environment variables.",
"Provisions a new app user in an enterprise with additional user information using Box Developer Edition.\n@param api the API connection to be used by the created user.\n@param name the name of the user.\n@param params additional user information.\n@return the created user's info.",
"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.",
"Shifts are performed based upon singular values computed previously. If it does not converge\nusing one of those singular values it uses a Wilkinson shift instead.",
"Use this API to fetch all the ntpserver resources that are configured on netscaler.",
"Starts a background thread which calls the controller every\ncheck_interval milliseconds. Returns immediately, leaving the\nbackground thread running."
] |
public Object copy(final Object obj, PersistenceBroker broker)
throws ObjectCopyException
{
ObjectOutputStream oos = null;
ObjectInputStream ois = null;
try
{
final ByteArrayOutputStream bos = new ByteArrayOutputStream();
oos = new ObjectOutputStream(bos);
// serialize and pass the object
oos.writeObject(obj);
oos.flush();
final ByteArrayInputStream bin =
new ByteArrayInputStream(bos.toByteArray());
ois = new ObjectInputStream(bin);
// return the new object
return ois.readObject();
}
catch (Exception e)
{
throw new ObjectCopyException(e);
}
finally
{
try
{
if (oos != null)
{
oos.close();
}
if (ois != null)
{
ois.close();
}
}
catch (IOException ioe)
{
// ignore
}
}
} | [
"This implementation will probably be slower than the metadata\nobject copy, but this was easier to implement.\n@see org.apache.ojb.otm.copy.ObjectCopyStrategy#copy(Object)"
] | [
"Log a warning for the given operation at the provided address for the given attributes, using the provided detail\nmessage.\n\n@param address where warning occurred\n@param operation where which problem occurred\n@param message custom error message to append\n@param attributes attributes we that have problems about",
"Use this API to count linkset_interface_binding resources configued on NetScaler.",
"find all accessibility object and set active true for enable talk back.",
"Checks to see if a subsystem resource has already been registered for the deployment.\n\n@param subsystemName the name of the subsystem\n\n@return {@code true} if the subsystem exists on the deployment otherwise {@code false}",
"Use this API to add nsacl6.",
"Returns true if the activity is a milestone.\n\n@param activity Phoenix activity\n@return true if the activity is a milestone",
"Helper method for formatting connection establishment messages.\n\n@param connectionName\nThe name of the connection\n@param host\nThe remote host\n@param connectionReason\nThe reason for establishing the connection\n@return A formatted message in the format:\n\"[<connectionName>] remote host[<host>] <connectionReason>\"\n<br/>\ne.g. [con1] remote host[123.123.123.123] connection to ECMG.",
"Retrieves the project start date. If an explicit start date has not been\nset, this method calculates the start date by looking for\nthe earliest task start date.\n\n@return project start date",
"This method extracts predecessor data from an MSPDI file.\n\n@param task Task data"
] |
public List<Release> listReleases(String appName) {
return connection.execute(new ReleaseList(appName), apiKey);
} | [
"List of releases for an app.\n@param appName App name. See {@link #listApps} for a list of apps that can be used.\n@return a list of releases"
] | [
"Prints some basic documentation about this program.",
"True if deleted, false if not found.",
"This method reads an eight byte integer from the input array.\n\n@param data the input array\n@param offset offset of integer data in the array\n@return integer value",
"Retrieve the number of minutes per day for this calendar.\n\n@return minutes per day",
"This method can be used by child classes to apply the configuration that is stored in config.",
"Adds OPT_FORMAT option to OptionParser, with one argument.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional",
"Convenience method for retrieving a Map resource.\n\n@param locale locale identifier\n@param key resource key\n@return resource value",
"This method is called to format a percentage value.\n\n@param value numeric value\n@return percentage value",
"Set the specific device class of the node.\n@param specificDeviceClass the specificDeviceClass to set\n@exception IllegalArgumentException thrown when the specific device class does not match\nthe generic device class."
] |
public GVRShader getTemplate(GVRContext ctx)
{
if (mShaderTemplate == null)
{
mShaderTemplate = makeTemplate(ID, ctx);
ctx.getShaderManager().addShaderID(this);
}
return mShaderTemplate;
} | [
"Gets the Java subclass of GVRShader which implements\nthis shader type.\n@param ctx GVRContext shader is associated with\n@return GVRShader class implementing the shader type"
] | [
"Get the configured hive.execution.engine. If not set it will default to the default value of HiveConf",
"Given a parameter, builds a new parameter for which the known generics placeholders are resolved.\n@param genericFromReceiver resolved generics from the receiver of the message\n@param placeholdersFromContext, resolved generics from the method context\n@param methodParameter the method parameter for which we want to resolve generic types\n@param paramType the (unresolved) type of the method parameter\n@return a new parameter with the same name and type as the original one, but with resolved generic types",
"Lookup the Gallery for the specified ID.\n\n@param galleryId\nThe user profile URL\n@return The Gallery\n@throws FlickrException",
"Returns angle in degrees between two points\n\n@param ax x of the point 1\n@param ay y of the point 1\n@param bx x of the point 2\n@param by y of the point 2\n@return angle in degrees between two points",
"Push docker image using the docker java client.\n\n@param imageTag\n@param username\n@param password\n@param host",
"Sets the body filter for this ID\n\n@param pathId ID of path\n@param bodyFilter Body filter to set",
"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",
"Create a Count-Query for QueryBySQL\n\n@param aQuery\n@return The count query",
"Internal used method to retrieve object based on Identity.\n\n@param id\n@return\n@throws PersistenceBrokerException"
] |
public <T> Method getSetMethod(final Object object, final String fieldName, final Class<?> argumentType) {
if( object == null ) {
throw new NullPointerException("object should not be null");
} else if( fieldName == null ) {
throw new NullPointerException("fieldName should not be null");
} else if( argumentType == null ) {
throw new NullPointerException("argumentType should not be null");
}
Method method = setMethodsCache.get(object.getClass(), argumentType, fieldName);
if( method == null ) {
method = ReflectionUtils.findSetter(object, fieldName, argumentType);
setMethodsCache.set(object.getClass(), argumentType, fieldName, method);
}
return method;
} | [
"Returns the setter method for the field on an object.\n\n@param object\nthe object\n@param fieldName\nthe field name\n@param argumentType\nthe type to be passed to the setter\n@param <T>\nthe object type\n@return the setter method associated with the field on the object\n@throws NullPointerException\nif object, fieldName or fieldType is null\n@throws SuperCsvReflectionException\nif the setter doesn't exist or is not visible"
] | [
"Remove a key for all language versions. If a descriptor is present, the key is only removed in the descriptor.\n\n@param key the key to remove.\n@return <code>true</code> if removing was successful, <code>false</code> otherwise.",
"Sets the max.\n\n@param n the new max",
"Checks if a Zip is valid navigating through the entries\n\n@param file File to validate\n@throws IOException I/O Error",
"Used to NOT the argument clause specified.",
"Create a new DateTime. To the last second. This will not create any\nextra-millis-seconds, which may cause bugs when writing to stores such as\ndatabases that round milli-seconds up and down.",
"Checks if the method being invoked should be wrapped by a service.\nIt looks the method name up in the methodList. If its in the list, then\nthe method should be wrapped. If the list is null, then all methods\nare wrapped.\n\n@param methodName The method being called\n\n@return boolean",
"Add the string representation of the given object to this sequence immediately. That is, all the trailing\nwhitespace of this sequence will be ignored and the string is appended directly after the last segment that\ncontains something besides whitespace. The given indentation will be prepended to each line except the first one\nif the object has a multi-line string representation.\n\n@param object\nthe to-be-appended object.\n@param indentation\nthe indentation string that should be prepended. May not be <code>null</code>.",
"Mark new or deleted reference elements\n@param broker",
"Clone a widget info map considering what may be copied to the client.\n\n@param widgetInfo widget info map\n@return cloned copy including only records which are not {@link ServerSideOnlyInfo}"
] |
public static Field read(DataInputStream is) throws IOException {
final byte tag = is.readByte();
final Field result;
switch (tag) {
case 0x0f:
case 0x10:
case 0x11:
result = new NumberField(tag, is);
break;
case 0x14:
result = new BinaryField(is);
break;
case 0x26:
result = new StringField(is);
break;
default:
throw new IOException("Unable to read a field with type tag " + tag);
}
logger.debug("..received> {}", result);
return result;
} | [
"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."
] | [
"This method reads a single byte from the input stream.\n\n@param is the input stream\n@return byte value\n@throws IOException on file read error or EOF",
"Accesses a property from the DB configuration for the selected DB.\n\n@param name the name of the property\n@return the value of the property",
"See if a range for assignment is specified. If so return the range, otherwise return null\n\nExample of assign range:\na(0:3,4:5) = blah\na((0+2):3,4:5) = blah",
"Use this API to add snmpuser.",
"Checks if request is intended for Gerrit host.",
"Will auto format the given string to provide support for pickadate.js formats.",
"Cut the message content to the configured length.\n\n@param event the event",
"Adds a new row after the given one.\n\n@param row the row after which a new one should be added",
"Use this API to unset the properties of sslservice resource.\nProperties that need to be unset are specified in args array."
] |
private Expression correctClassClassChain(PropertyExpression pe) {
LinkedList<Expression> stack = new LinkedList<Expression>();
ClassExpression found = null;
for (Expression it = pe; it != null; it = ((PropertyExpression) it).getObjectExpression()) {
if (it instanceof ClassExpression) {
found = (ClassExpression) it;
break;
} else if (!(it.getClass() == PropertyExpression.class)) {
return pe;
}
stack.addFirst(it);
}
if (found == null) return pe;
if (stack.isEmpty()) return pe;
Object stackElement = stack.removeFirst();
if (!(stackElement.getClass() == PropertyExpression.class)) return pe;
PropertyExpression classPropertyExpression = (PropertyExpression) stackElement;
String propertyNamePart = classPropertyExpression.getPropertyAsString();
if (propertyNamePart == null || !propertyNamePart.equals("class")) return pe;
found.setSourcePosition(classPropertyExpression);
if (stack.isEmpty()) return found;
stackElement = stack.removeFirst();
if (!(stackElement.getClass() == PropertyExpression.class)) return pe;
PropertyExpression classPropertyExpressionContainer = (PropertyExpression) stackElement;
classPropertyExpressionContainer.setObjectExpression(found);
return pe;
} | [
"and class as property"
] | [
"Returns the JSON datatype for the property datatype as represented by\nthe given WDTK datatype IRI string.\n\n@param datatypeIri\nthe WDTK datatype IRI string; case-sensitive\n@throws IllegalArgumentException\nif the given datatype string is not known",
"Writes an activity to a PM XML file.\n\n@param mpxj MPXJ Task instance",
"Should use as destroy method. Disconnects from a Service Locator server.\nAll endpoints that were registered before are removed from the server.\nSet property locatorClient to null.\n\n@throws InterruptedException\n@throws ServiceLocatorException",
"Adds one statement to the list of statements to be kept, possibly merging\nit with other statements to be kept if possible. When two existing\nstatements are merged, one of them will be updated and the other will be\nmarked for deletion.\n\n@param statement\nstatement to add\n@param isNew\nif true, the statement should be marked for writing; if false,\nthe statement already exists in the current data and is only\nadded to remove duplicates and avoid unnecessary writes",
"Send a get module request\n\n@param name\n@param version\n@return the targeted module\n@throws GrapesCommunicationException",
"Emit information about all of suite's tests.",
"Returns an ArrayList of String URLs of the Carousel Images\n@return ArrayList of Strings",
"bootstrap method for method calls with \"this\" as receiver\n@deprecated since Groovy 2.1.0",
"Shifts are performed based upon singular values computed previously. If it does not converge\nusing one of those singular values it uses a Wilkinson shift instead."
] |
@Override
public <VALUEBASE, VALUE extends VALUEBASE, KEY extends Key<CoreMap, VALUEBASE>>
VALUE set(Class<KEY> key, VALUE value) {
if (immutableKeys.contains(key)) {
throw new HashableCoreMapException("Attempt to change value " +
"of immutable field "+key.getSimpleName());
}
return super.set(key, value);
} | [
"Sets the value associated with the given key; if the the key is one\nof the hashable keys, throws an exception.\n\n@throws HashableCoreMapException Attempting to set the value for an\nimmutable, hashable key."
] | [
"Retrieves state and metrics information for individual client connection.\n\n@param name connection name\n@return connection information",
"Notifies that an existing content item is moved to another position.\n\n@param fromPosition the original position.\n@param toPosition the new position.",
"Deletes the inbox message for given messageId\n@param messageId String messageId\n@return boolean value based on success of operation",
"Read a list of fixed size blocks using an instance of the supplied reader class.\n\n@param readerClass reader class\n@return list of blocks",
"Gets information for a Box Storage Policy with optional fields.\n\n@param fields the fields to retrieve.\n@return info about this item containing only the specified fields, including storage policy.",
"Run the configured crawl. This method blocks until the crawl is done.\n\n@return the CrawlSession once the crawl is done.",
"Return the authorization URL which is used to perform the authorization_code based OAuth2 flow.\n@param clientID the client ID to use with the connection.\n@param redirectUri the URL to which Box redirects the browser when authentication completes.\n@param state the text string that you choose.\nBox sends the same string to your redirect URL when authentication is complete.\n@param scopes this optional parameter identifies the Box scopes available\nto the application once it's authenticated.\n@return the authorization URL",
"Get the list of active tasks from the server.\n\n@return List of tasks\n@see <a href=\"https://console.bluemix.net/docs/services/Cloudant/api/active_tasks.html\">\nActive tasks</a>",
"Called when a drawer has settled in a completely open state."
] |
public static boolean removeDefaultCustomResponse(String pathValue, String requestType) {
try {
JSONObject profile = getDefaultProfile();
String profileName = profile.getString("name");
PathValueClient client = new PathValueClient(profileName, false);
return client.removeCustomResponse(pathValue, requestType);
} catch (Exception e) {
e.printStackTrace();
}
return false;
} | [
"Remove any overrides for an endpoint on the default profile, client\n\n@param pathValue path (endpoint) value\n@param requestType path request type. \"GET\", \"POST\", etc\n@return true if success, false otherwise"
] | [
"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",
"Invalidate the item in layout\n@param dataIndex data index",
"Sets the origin and direction of the pick ray.\n\n@param ox X coordinate of origin.\n@param oy Y coordinate of origin.\n@param oz Z coordinate of origin.\n@param dx X coordinate of ray direction.\n@param dy Y coordinate of ray direction.\n@param dz Z coordinate of ray direction.\n\nThe coordinate system of the ray depends on the whether the\npicker is attached to a scene object or not. When attached\nto a scene object, the ray is in the coordinate system of\nthat object where (0, 0, 0) is the center of the scene object\nand (0, 0, 1) is it's positive Z axis. If not attached to an\nobject, the ray is in the coordinate system of the scene's\nmain camera with (0, 0, 0) at the viewer and (0, 0, -1)\nwhere the viewer is looking.\n@see #doPick()\n@see #getPickRay()\n@see #getWorldPickRay(Vector3f, Vector3f)",
"Bessel function of the second kind, of order 1.\n\n@param x Value.\n@return Y value.",
"Run a CLI script from a File.\n\n@param script The script file.",
"Flushes this output stream and forces any buffered output bytes to be written out to the stream. If propagate is\ntrue, the wrapped stream will also be flushed.\n\n@param propagate\nboolean flag to indicate whether the wrapped OutputStream should also be flushed.\n@throws IOException\nif an I/O error occurs.",
"Write the criteria elements, extracting the information of the sub-model.\n\n@param writer the xml stream writer\n@param subModel the interface model\n@param nested whether it the criteria elements are nested as part of <not /> or <any />\n@throws XMLStreamException",
"Validate the consistency of patches to the point we rollback.\n\n@param patchID the patch id which gets rolled back\n@param identity the installed identity\n@throws PatchingException",
"Links the given widget to InstantSearch according to the interfaces it implements.\n\n@param widget a widget implementing ({@link AlgoliaResultsListener} || {@link AlgoliaErrorListener} || {@link AlgoliaSearcherListener})."
] |
public static base_response update(nitro_service client, nsconfig resource) throws Exception {
nsconfig updateresource = new nsconfig();
updateresource.ipaddress = resource.ipaddress;
updateresource.netmask = resource.netmask;
updateresource.nsvlan = resource.nsvlan;
updateresource.ifnum = resource.ifnum;
updateresource.tagged = resource.tagged;
updateresource.httpport = resource.httpport;
updateresource.maxconn = resource.maxconn;
updateresource.maxreq = resource.maxreq;
updateresource.cip = resource.cip;
updateresource.cipheader = resource.cipheader;
updateresource.cookieversion = resource.cookieversion;
updateresource.securecookie = resource.securecookie;
updateresource.pmtumin = resource.pmtumin;
updateresource.pmtutimeout = resource.pmtutimeout;
updateresource.ftpportrange = resource.ftpportrange;
updateresource.crportrange = resource.crportrange;
updateresource.timezone = resource.timezone;
updateresource.grantquotamaxclient = resource.grantquotamaxclient;
updateresource.exclusivequotamaxclient = resource.exclusivequotamaxclient;
updateresource.grantquotaspillover = resource.grantquotaspillover;
updateresource.exclusivequotaspillover = resource.exclusivequotaspillover;
updateresource.nwfwmode = resource.nwfwmode;
return updateresource.update_resource(client);
} | [
"Use this API to update nsconfig."
] | [
"used for encoding queries or form data",
"Returns whether this address contains the non-zero host addresses in other.\n@param other\n@return",
"Retrieves state and metrics information for individual client connection.\n\n@param name connection name\n@return connection information",
"Use this API to fetch aaapreauthenticationpolicy_binding resource of given name .",
"Sets the bottom padding character for all cells in the row.\n@param paddingBottomChar new padding character, ignored if null\n@return this to allow chaining",
"Use this API to delete nsip6 of given name.",
"Returns the index of the eigenvalue which has the smallest magnitude.\n\n@return index of the smallest magnitude eigen value.",
"Detects if the current device is a mobile device.\nThis method catches most of the popular modern devices.\nExcludes Apple iPads and other modern tablets.\n@return detection of any mobile device using the quicker method",
"Returns the full path of the resource file with extension.\n\n@return path of the GVRAndroidResource. May return null if the\nresource is not associated with any file"
] |
public void delete() {
URL url = DEVICE_PIN_URL_TEMPLATE.build(this.getAPI().getBaseURL(), this.getID());
BoxAPIRequest request = new BoxAPIRequest(this.getAPI(), url, "DELETE");
BoxAPIResponse response = request.send();
response.disconnect();
} | [
"Deletes the device pin."
] | [
"Sets the bean store\n\n@param beanStore The bean store",
"Assigns the element in the Matrix to the specified value. Performs a bounds check to make sure\nthe requested element is part of the matrix.\n\n@param row The row of the element.\n@param col The column of the element.\n@param value The element's new value.",
"Provisions a new app user in an enterprise with additional user information using Box Developer Edition.\n@param api the API connection to be used by the created user.\n@param name the name of the user.\n@param params additional user information.\n@return the created user's info.",
"This utility displays a list of available task filters, and a\nlist of available resource filters.\n\n@param project project file",
"Converts a Map to an array of objects, adding only those entries whose key is in the nameMapping array.\n\n@param values\nthe Map of values to convert\n@param nameMapping\nthe keys to extract from the Map (elements in the target array will be added in this order)\n@return the array of Objects\n@throws NullPointerException\nif values or nameMapping is null",
"Remove an read lock.",
"Initializes the metadataCache for MetadataStore",
"Extract raw table data from the input stream.\n\n@param is input stream",
"Sets the current class definition derived from the current class, and optionally some attributes.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\[email protected] type=\"block\"\[email protected] name=\"accept-locks\" optional=\"true\" description=\"The accept locks setting\" values=\"true,false\"\[email protected] name=\"attributes\" optional=\"true\" description=\"Attributes of the class as name-value pairs 'name=value',\nseparated by commas\"\[email protected] name=\"determine-extents\" optional=\"true\" description=\"Whether to determine\npersistent direct sub types automatically\" values=\"true,false\"\[email protected] name=\"documentation\" optional=\"true\" description=\"Documentation on the class\"\[email protected] name=\"factory-method\" optional=\"true\" description=\"Specifies a no-argument factory method that is\nused to create instances (not yet implemented !)\"\[email protected] name=\"factory-class\" optional=\"true\" description=\"Specifies a factory class to be used for creating\nobjects of this class\"\[email protected] name=\"factory-method\" optional=\"true\" description=\"Specifies a static no-argument method in the factory class\"\[email protected] name=\"generate-repository-info\" optional=\"true\" description=\"Whether repository data should be\ngenerated for the class\" values=\"true,false\"\[email protected] name=\"generate-table-info\" optional=\"true\" description=\"Whether table data should be\ngenerated for the class\" values=\"true,false\"\[email protected] name=\"include-inherited\" optional=\"true\" description=\"Whether to include\nfields/references/collections of supertypes\" values=\"true,false\"\[email protected] name=\"initialization-method\" optional=\"true\" description=\"Specifies a no-argument instance method that is\ncalled right after an instance has been read from the database\"\[email protected] name=\"isolation-level\" optional=\"true\" description=\"The isolation level setting\"\[email protected] name=\"proxy\" optional=\"true\" description=\"The proxy setting for this class\"\[email protected] name=\"proxy-prefetching-limit\" optional=\"true\" description=\"Specifies the amount of objects of\nobjects of this class to prefetch in collections\"\[email protected] name=\"refresh\" optional=\"true\" description=\"Can be set to force OJB to refresh instances when\nloaded from the cache\" values=\"true,false\"\[email protected] name=\"row-reader\" optional=\"true\" description=\"The row reader for the class\"\[email protected] name=\"schema\" optional=\"true\" description=\"The schema for the type\"\[email protected] name=\"table\" optional=\"true\" description=\"The table for the class\"\[email protected] name=\"table-documentation\" optional=\"true\" description=\"Documentation on the table\""
] |
private List<Row> createWorkPatternAssignmentRowList(String workPatterns) throws ParseException
{
List<Row> list = new ArrayList<Row>();
String[] patterns = workPatterns.split(",|:");
int index = 1;
while (index < patterns.length)
{
Integer workPattern = Integer.valueOf(patterns[index + 1]);
Date startDate = DatatypeConverter.parseBasicTimestamp(patterns[index + 3]);
Date endDate = DatatypeConverter.parseBasicTimestamp(patterns[index + 4]);
Map<String, Object> map = new HashMap<String, Object>();
map.put("WORK_PATTERN", workPattern);
map.put("START_DATE", startDate);
map.put("END_DATE", endDate);
list.add(new MapRow(map));
index += 5;
}
return list;
} | [
"Extract a list of work pattern assignments.\n\n@param workPatterns string representation of work pattern assignments\n@return list of work pattern assignment rows"
] | [
"Reads the entity hosting the association from the datastore and applies any property changes from the server\nside.",
"Set the model used by the left table.\n\n@param model table model",
"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.",
"The ARP is additional request parameters, which must be sent once\nreceived after any HTTP call. This is sort of a proxy for cookies.\n\n@return A JSON object containing the ARP key/values. Can be null.",
"this method is basically checking whether we can return \"this\" for getNetworkSection",
"Use this API to disable nsacl6 resources of given names.",
"Creates the server bootstrap.",
"Provides a reverse view on the given list which is especially useful to traverse a list backwards in a for-each\nloop. The list itself is not modified by calling this method.\n\n@param list\nthe list whose elements should be traversed in reverse. May not be <code>null</code>.\n@return a list with the same elements as the given list, in reverse",
"Returns a new client id for the profileIdentifier\n\n@param model\n@param profileIdentifier\n@return json with a new client_id\n@throws Exception"
] |
private List<StyleFilter> initStyleFilters(List<FeatureStyleInfo> styleDefinitions) throws GeomajasException {
List<StyleFilter> styleFilters = new ArrayList<StyleFilter>();
if (styleDefinitions == null || styleDefinitions.size() == 0) {
styleFilters.add(new StyleFilterImpl()); // use default.
} else {
for (FeatureStyleInfo styleDef : styleDefinitions) {
StyleFilterImpl styleFilterImpl = null;
String formula = styleDef.getFormula();
if (null != formula && formula.length() > 0) {
styleFilterImpl = new StyleFilterImpl(filterService.parseFilter(formula), styleDef);
} else {
styleFilterImpl = new StyleFilterImpl(Filter.INCLUDE, styleDef);
}
styleFilters.add(styleFilterImpl);
}
}
return styleFilters;
} | [
"Build list of style filters from style definitions.\n\n@param styleDefinitions\nlist of style definitions\n@return list of style filters\n@throws GeomajasException"
] | [
"Convert one project file format to another.\n\n@param inputFile input file\n@param outputFile output file\n@throws Exception",
"Given a read-only store name and a directory, swaps it in while returning\nthe directory path being swapped out\n\n@param storeName The name of the read-only store\n@param directory The directory being swapped in\n@return The directory path which was swapped out\n@throws VoldemortException",
"Clones the given field.\n\n@param fieldDef The field descriptor\n@param prefix A prefix for the name\n@return The cloned field",
"Returns a set that contains all the unique entries of the given iterator in the order of their appearance.\nThe result set is a copy of the iterator with stable order.\n\n@param iterator\nthe iterator. May not be <code>null</code>.\n@return a set with the unique entries of the given iterator. Never <code>null</code>.",
"Get unique values form the array.\n\n@param values Array of values.\n@return Unique values.",
"Handle a whole day change event.\n@param event the change event.",
"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.",
"Returns the list of store defs as a map\n\n@param storeDefs\n@return",
"Get logs for an app by specifying additional parameters.\n@param logRequest See {LogRequestBuilder}\n@return log stream response"
] |
private ClassTypeSignature getClassTypeSignature(
ParameterizedType parameterizedType) {
Class<?> rawType = (Class<?>) parameterizedType.getRawType();
Type[] typeArguments = parameterizedType.getActualTypeArguments();
TypeArgSignature[] typeArgSignatures = new TypeArgSignature[typeArguments.length];
for (int i = 0; i < typeArguments.length; i++) {
typeArgSignatures[i] = getTypeArgSignature(typeArguments[i]);
}
String binaryName = rawType.isMemberClass() ? rawType.getSimpleName()
: rawType.getName();
ClassTypeSignature ownerTypeSignature = parameterizedType
.getOwnerType() == null ? null
: (ClassTypeSignature) getFullTypeSignature(parameterizedType
.getOwnerType());
ClassTypeSignature classTypeSignature = new ClassTypeSignature(
binaryName, typeArgSignatures, ownerTypeSignature);
return classTypeSignature;
} | [
"get the ClassTypeSignature corresponding to given parameterized type\n\n@param parameterizedType\n@return"
] | [
"Retrieves a specific range of items in this collection.\n@param offset the index of the first item to retrieve.\n@param limit the maximum number of items to retrieve after the offset.\n@param fields the fields to retrieve.\n@return a partial collection containing the specified range of items.",
"Writes an untagged OK response, with the supplied response code,\nand an optional message.\n\n@param responseCode The response code, included in [].\n@param message The message to follow the []",
"Sets the action label to be displayed, if any. Note that if this is not set, the action\nbutton will not be displayed\n\n@param actionButtonLabel\n@return",
"Use this API to add dospolicy.",
"Start the rendering of the scalebar.",
"Append environment variables and system properties from othre PipelineEvn object",
"Use this API to unset the properties of snmpalarm resources.\nProperties that need to be unset are specified in args array.",
"Flushes all changes to disk.",
"Checks, if all values necessary for a specific pattern are valid.\n@return a flag, indicating if all values required for the pattern are valid."
] |
public void postArtifact(final Artifact artifact, final String user, final String password) throws GrapesCommunicationException, AuthenticationException {
final Client client = getClient(user, password);
final WebResource resource = client.resource(serverURL).path(RequestUtils.artifactResourcePath());
final ClientResponse response = resource.type(MediaType.APPLICATION_JSON).post(ClientResponse.class, artifact);
client.destroy();
if(ClientResponse.Status.CREATED.getStatusCode() != response.getStatus()){
final String message = "Failed to POST artifact";
if(LOG.isErrorEnabled()) {
LOG.error(String.format(HTTP_STATUS_TEMPLATE_MSG, message, response.getStatus()));
}
throw new GrapesCommunicationException(message, response.getStatus());
}
} | [
"Post an artifact to the Grapes server\n\n@param artifact The artifact to post\n@param user The user posting the information\n@param password The user password\n@throws GrapesCommunicationException\n@throws javax.naming.AuthenticationException"
] | [
"Reads color table as 256 RGB integer values.\n\n@param ncolors int number of colors to read.\n@return int array containing 256 colors (packed ARGB with full alpha).",
"Utility function that constructs AdminClient.\n\n@param url URL pointing to the bootstrap node\n@return Newly constructed AdminClient",
"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",
"Return the project name or the default project name.",
"Writes the buffer contents to the given byte channel.\n\n@param channel\n@throws IOException",
"Adds the supplied marker to the map.\n\n@param marker",
"Performs an implicit double step using the values contained in the lower right hand side\nof the submatrix for the estimated eigenvector values.\n@param x1\n@param x2",
"Stop the service and end the program",
"Checks to see if matrix 'a' is the same as this matrix within the specified\ntolerance.\n\n@param a The matrix it is being compared against.\n@param tol How similar they must be to be equals.\n@return If they are equal within tolerance of each other."
] |
public static base_responses delete(nitro_service client, String acl6name[]) throws Exception {
base_responses result = null;
if (acl6name != null && acl6name.length > 0) {
nsacl6 deleteresources[] = new nsacl6[acl6name.length];
for (int i=0;i<acl6name.length;i++){
deleteresources[i] = new nsacl6();
deleteresources[i].acl6name = acl6name[i];
}
result = delete_bulk_request(client, deleteresources);
}
return result;
} | [
"Use this API to delete nsacl6 resources of given names."
] | [
"Analyze all source code using the specified RuleSet and return the report results.\n\n@param ruleSet - the RuleSet to apply to each source component; must not be null.\n@return the results from applying the RuleSet to all of the source",
"Return as a string the stereotypes associated with c\nterminated by the escape character term",
"Returns the editable columns for the provided edit mode.\n@param mode the edit mode.\n@return the editable columns for the provided edit mode.",
"Populate the container, converting raw data into Java types.\n\n@param field custom field to which these values belong\n@param values raw value data\n@param descriptions raw description data",
"Internal method used to retrieve a integer from an\nembedded data block.\n\n@param blocks list of data blocks\n@return int value",
"Static method to convert a binary operator into a string.\n\n@param oper is the binary comparison operator to be converted",
"Initialize elements from the duration panel.",
"List the indexes in the database. The returned object allows for listing indexes by type.\n\n@return indexes object with methods for getting indexes of a particular type",
"Get stream for URL only\n\n@param stringUrl URL to get content\n@return the input stream\n@throws IOException I/O error happened"
] |
Subsets and Splits