query
stringlengths 74
6.1k
| positive
sequencelengths 1
1
| negative
sequencelengths 9
9
|
---|---|---|
public ItemRequest<Webhook> deleteById(String webhook) {
String path = String.format("/webhooks/%s", webhook);
return new ItemRequest<Webhook>(this, Webhook.class, path, "DELETE");
} | [
"This method permanently removes a webhook. Note that it may be possible\nto receive a request that was already in flight after deleting the\nwebhook, but no further requests will be issued.\n\n@param webhook The webhook to delete.\n@return Request object"
] | [
"Append the text at the end of the Path.\n\n@param self a Path\n@param text the text to append at the end of the Path\n@throws java.io.IOException if an IOException occurs.\n@since 2.3.0",
"judge a->b is ordered clockwise\n\n@param center\n@param a\n@param b\n@return",
"Convenience method for retrieving an Object resource.\n\n@param locale locale identifier\n@param key resource key\n@return resource value",
"Returns the average event value in the current interval",
"Returns an empty map with expected size matching the iterable size if\nit's of type Collection. Otherwise, an empty map with the default size is\nreturned.",
"Use this API to fetch appfwjsoncontenttype resource of given name .",
"Use this API to unset the properties of nsspparams resource.\nProperties that need to be unset are specified in args array.",
"This method is used to extract the task hyperlink attributes\nfrom a block of data and call the appropriate modifier methods\nto configure the specified task object.\n\n@param task task instance\n@param data hyperlink data block",
"Ensure that all logs are replayed, any other logs can not be added before end of this function."
] |
public CollectionRequest<Team> findByOrganization(String organization) {
String path = String.format("/organizations/%s/teams", organization);
return new CollectionRequest<Team>(this, Team.class, path, "GET");
} | [
"Returns the compact records for all teams in the organization visible to\nthe authorized user.\n\n@param organization Globally unique identifier for the workspace or organization.\n@return Request object"
] | [
"Tells you if the expression is the false expression, either literal or constant.\n@param expression\nexpression\n@return\nas described",
"View that redirects the top level window to the URL defined in postDeclineUrl property after user declines to authorize application.\nMay be overridden for custom views, particularly in the case where the post-decline view should be rendered in-canvas.\n@return a view to display after a user declines authoriation. Defaults as a redirect to postDeclineUrl",
"Calculates ATM Bachelier implied volatilities.\n\n@see net.finmath.functions.AnalyticFormulas#bachelierOptionImpliedVolatility(double, double, double, double, double)\n\n@param optionValue RandomVarable representing the value of the option\n@param optionMaturity Time to maturity.\n@param swapAnnuity The swap annuity as seen on valuation time.\n@return The Bachelier implied volatility.",
"Gets a SerialMessage with the SENSOR_ALARM_SUPPORTED_GET command\n@return the serial message, or null if the supported command is not supported.",
"Runs a Story with the given steps factory, applying the given meta\nfilter, and staring from given state.\n\n@param configuration the Configuration used to run story\n@param stepsFactory the InjectableStepsFactory used to created the\ncandidate steps methods\n@param story the Story to run\n@param filter the Filter to apply to the story Meta\n@param beforeStories the State before running any of the stories, if not\n<code>null</code>\n\n@throws Throwable if failures occurred and FailureStrategy dictates it to\nbe re-thrown.",
"Set the timeout for idle connections. Voldemort client caches all\nconnections to the Voldemort server. This setting allows the a connection\nto be dropped, if it is idle for more than this time.\n\nThis could be useful in the following cases 1) Voldemort client is not\ndirectly connected to the server and is connected via a proxy or\nfirewall. The Proxy or firewall could drop the connection silently. If\nthe connection is dropped, then client will see operations fail with a\ntimeout. Setting this property enables the Voldemort client to tear down\nthe connection before a firewall could drop it. 2) Voldemort server\ncaches the connection and each connection has an associated memory cost.\nSetting this property on all clients, enable the clients to prune the\nconnections and there by freeing up the server connections.\n\nthrows IllegalArgumentException if the timeout is less than 10 minutes.\n\nCurrently it can't be set below 10 minutes to avoid the racing risk of\ncontention between connection checkout and selector trying to close it.\nThis is intended for low throughput scenarios.\n\n@param idleConnectionTimeout\nzero or negative number to disable the feature ( default -1)\ntimeout\n@param unit {@link TimeUnit}\n@return ClientConfig object for chained set\n\nthrows {@link IllegalArgumentException} if the timeout is greater\nthan 0, but less than 10 minutes.",
"Parse the string representation of a double.\n\n@param value string representation\n@return Java representation\n@throws ParseException",
"Mark the given TaskItem depends on this taskGroup.\n\n@param dependentTaskItem the task item that depends on this task group\n@return key to be used as parameter to taskResult(string) method to retrieve result of\ninvocation of given task item.",
"Gets the global and adds it ot the BatchExecutionresults using the alternative outIdentifier.\n\n@param identifier\nThe identifier of the global\n@param outIdentifier\nThe identifier used in the ExecutionResults to store the global.\n@return"
] |
protected void afterMaterialization()
{
if (_listeners != null)
{
MaterializationListener listener;
// listeners may remove themselves during the afterMaterialization
// callback.
// thus we must iterate through the listeners vector from back to
// front
// to avoid index problems.
for (int idx = _listeners.size() - 1; idx >= 0; idx--)
{
listener = (MaterializationListener) _listeners.get(idx);
listener.afterMaterialization(this, _realSubject);
}
}
} | [
"Calls afterMaterialization on all registered listeners in the reverse\norder of registration."
] | [
"When it is time to actually close a client, do so, and clean up the related data structures.\n\n@param client the client which has been idle for long enough to be closed",
"Is the user password reset?\n\n@param user User to check\n@return boolean",
"Creates a curator built using Application's zookeeper connection string. Root path will start\nat Fluo application chroot.",
"Answer true if an Iterator for a Table is already available\n@param aTable\n@return",
"Makes the object unpickable and removes the touch handler for it\n@param sceneObject\n@return true if the handler has been successfully removed",
"Search for photos which match the given search parameters.\n\n@param params\nThe search parameters\n@param perPage\nThe number of photos to show per page\n@param page\nThe page offset\n@return A PhotoList\n@throws FlickrException",
"convert object into another class using the JSON mapper\n\n@param <C> the generic target type\n@param object the object to convert\n@param targetClass the class of the target object\n@return the converted object\n@throws IllegalArgumentException if conversion fails",
"Obtains a local date in Ethiopic 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 Ethiopic local date, not null\n@throws DateTimeException if unable to create the date",
"This method extracts assignment data from a Planner file.\n\n@param plannerProject Root node of the Planner file"
] |
private boolean keyAlreadyExists(String newKey) {
Collection<?> itemIds = m_table.getItemIds();
for (Object itemId : itemIds) {
if (m_table.getItem(itemId).getItemProperty(TableProperty.KEY).getValue().equals(newKey)) {
return true;
}
}
return false;
} | [
"Checks if a key already exists.\n@param newKey the key to check for.\n@return <code>true</code> if the key already exists, <code>false</code> otherwise."
] | [
"Close the connection atomically.\n\n@return true if state changed to closed; false if nothing changed.",
"Try to get the line number associated with the given member.\n\nThe reflection API does not expose such an info and so we need to analyse the bytecode. Unfortunately, it seems there is no way to get this kind of\ninformation for fields. Moreover, the <code>LineNumberTable</code> attribute is just optional, i.e. the compiler is not required to store this\ninformation at all. See also <a href=\"http://docs.oracle.com/javase/specs/jvms/se8/html/jvms-4.html#jvms-4.1\">Java Virtual Machine Specification</a>\n\nImplementation note: it wouldn't be appropriate to add a bytecode scanning dependency just for this functionality, therefore Apache BCEL included in\nOracle JDK 1.5+ and OpenJDK 1.6+ is used. Other JVMs should not crash as we only use it if it's on the classpath and by means of reflection calls.\n\n@param member\n@param resourceLoader\n@return the line number or 0 if it's not possible to find it",
"Check if new license pattern is valid and doesn't match any existing one\n@param newComer License being added or edited\n@throws WebApplicationException if conflicts involving the newComer are detected",
"Write the domain controller's data to an output stream.\n\n@param outstream the output stream\n@throws Exception",
"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",
"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",
"Populate a task from a Row instance.\n\n@param row Row instance\n@param task Task instance",
"use this method to construct the ChainingIterator\niterator by iterator.",
"Method used as dynamical parameter converter"
] |
public static DMatrixRMaj symmetricWithEigenvalues(int num, Random rand , double ...eigenvalues ) {
DMatrixRMaj V = RandomMatrices_DDRM.orthogonal(num,num,rand);
DMatrixRMaj D = CommonOps_DDRM.diag(eigenvalues);
DMatrixRMaj temp = new DMatrixRMaj(num,num);
CommonOps_DDRM.mult(V,D,temp);
CommonOps_DDRM.multTransB(temp,V,D);
return D;
} | [
"Creates a new random symmetric matrix that will have the specified real eigenvalues.\n\n@param num Dimension of the resulting matrix.\n@param rand Random number generator.\n@param eigenvalues Set of real eigenvalues that the matrix will have.\n@return A random matrix with the specified eigenvalues."
] | [
"Creates the container for a bundle descriptor.\n@return the container for a bundle descriptor.",
"The main method called from the command line.\n\n@param args the command line arguments",
"will trigger workers to cancel then wait for it to report back.",
"calculate and set position to menu items",
"Set the pointer on the bar. With the Value value.\n\n@param value float between 0 and 1",
"Processes the template for all procedures of the current class definition.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\[email protected] type=\"block\"",
"Sets the texture this render target will render to.\nIf no texture is provided, the render target will\nnot render anything.\n@param texture GVRRenderTexture to render to.",
"To populate the dropdown list from the jelly",
"Use this API to fetch all the responderhtmlpage resources that are configured on netscaler."
] |
public static Iterable<BoxUser.Info> getAllEnterpriseUsers(final BoxAPIConnection api, final String filterTerm,
final String... fields) {
return getUsersInfoForType(api, filterTerm, null, null, fields);
} | [
"Returns an iterable containing all the enterprise users that matches the filter and specifies which child fields\nto retrieve from the API.\n@param api the API connection to be used when retrieving the users.\n@param filterTerm used to filter the results to only users starting with this string in either the name or the\nlogin. Can be null to not filter the results.\n@param fields the fields to retrieve. Leave this out for the standard fields.\n@return an iterable containing all the enterprise users that matches the filter."
] | [
"Sets the position of the currency symbol.\n\n@param posn currency symbol position.",
"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",
"Returns the dimension of the type of the current member.\n\n@return The member dimension\n@exception XDocletException if an error occurs\n@see OjbMemberTagsHandler#getMemberType()",
"Called when the pattern has changed.",
"Post a build info to the server\n\n@param moduleName String\n@param moduleVersion String\n@param buildInfo Map<String,String>\n@param user String\n@param password String\n@throws GrapesCommunicationException\n@throws javax.naming.AuthenticationException",
"Writes an activity to a PM XML file.\n\n@param mpxj MPXJ Task instance",
"Processes the template for all index descriptors of the current class definition.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\[email protected] type=\"block\"",
"Curries a procedure that takes one argument.\n\n@param procedure\nthe original procedure. May not be <code>null</code>.\n@param argument\nthe fixed argument.\n@return a procedure that takes no arguments. Never <code>null</code>.",
"Adds each required substring, checking that it's not null.\n\n@param requiredSubStrings\nthe required substrings\n@throws NullPointerException\nif a required substring is null"
] |
public boolean canBeLinked(D declaration, ServiceReference<S> declarationBinderRef) {
// Evaluate the target filter of the ImporterService on the Declaration
Filter filter = bindersManager.getTargetFilter(declarationBinderRef);
return filter.matches(declaration.getMetadata());
} | [
"Return true if the Declaration can be linked to the ImporterService.\n\n@param declaration The Declaration\n@param declarationBinderRef The ServiceReference<ImporterService> of the ImporterService\n@return true if the Declaration can be linked to the ImporterService"
] | [
"Checks to see if the submatrix has its boundaries along inner blocks.\n\n@param blockLength Size of an inner block.\n@param A Submatrix.\n@return If it is block aligned or not.",
"Use this API to update appfwlearningsettings.",
"Propagates node table of given DAG to all of it ancestors.",
"Use this API to update cmpparameter.",
"Reads data from a single page of the database file.\n\n@param buffer page from the database file\n@param table Table instance",
"Calculate matrix exponential of a square matrix.\n\nA scaled Pade approximation algorithm is used.\nThe algorithm has been directly translated from Golub & Van Loan \"Matrix Computations\",\nalgorithm 11.3.1. Special Horner techniques from 11.2 are also used to minimize the number\nof matrix multiplications.\n\n@param A square matrix\n@return matrix exponential of A",
"Returns the docker version.\n\n@param serverUrl\nThe serverUrl to use.",
"Write the given number of bytes out to the array\n\n@param bytes The array to write to\n@param value The value to write from\n@param offset the offset into the array\n@param numBytes The number of bytes to write",
"Resets the helper's state.\n\n@return this {@link Searcher} for chaining."
] |
public Build createBuild(String appName, Build build) {
return connection.execute(new BuildCreate(appName, build), apiKey);
} | [
"Creates a build\n\n@param appName See {@link #listApps} for a list of apps that can be used.\n@param build the build information"
] | [
"Initialize the service with a context\n@param context the servlet context to initialize the profile.",
"Converts the positions to a 2D double array\n@return 2d double array [i][j], i=Time index, j=coordinate index",
"Called by subclasses that initialize collections\n\n@param session the session\n@param id the collection identifier\n@param type collection type\n@throws HibernateException if an error occurs",
"Converts this IPv6 address segment into smaller segments,\ncopying them into the given array starting at the given index.\n\nIf a segment does not fit into the array because the segment index in the array is out of bounds of the array,\nthen it is not copied.\n\n@param segs\n@param index",
"Plots the MSD curve with the trajectory t and adds the fitted model for directed motion above.\n@param t\n@param lagMin Minimum timelag (e.g. 1,2,3..) lagMin*timelag = elapsed time in seconds\n@param lagMax lagMax Maximum timelag (e.g. 1,2,3..) lagMax*timelag = elapsed time in seconds\n@param timelag Elapsed time between two frames.\n@param diffusionCoefficient Diffusion coefficient\n@param velocity velocity of the active transport",
"Returns the JRDesignGroup for the DJGroup passed\n@param jd\n@param layoutManager\n@param group\n@return",
"See convertToSQL92.\n\n@return SQL like sub-expression\n@throws IllegalArgumentException oops",
"Use this API to delete ntpserver.",
"Merge the contents of the given plugin.xml into this one."
] |
@Override
public InternationalFixedDate dateYearDay(Era era, int yearOfEra, int dayOfYear) {
return dateYearDay(prolepticYear(era, yearOfEra), dayOfYear);
} | [
"Obtains a local date in International Fixed calendar system from the\nera, year-of-era and day-of-year fields.\n\n@param era the International Fixed era, not null\n@param yearOfEra the year-of-era\n@param dayOfYear the day-of-year\n@return the International Fixed local date, not null\n@throws DateTimeException if unable to create the date\n@throws ClassCastException if the {@code era} is not a {@code InternationalFixedEra}"
] | [
"Load entries from the storage.\nOverriding methods should first delegate to super before adding their own entries.",
"Runs the example program.\n\n@param args\n@throws IOException\nif there was a problem in writing the output file",
"The Total Slack field contains the amount of time a task can be\ndelayed without delaying the project's finish date.\n\n@return string representing duration",
"Utility function that pauses and asks for confirmation on dangerous\noperations.\n\n@param confirm User has already confirmed in command-line input\n@param opDesc Description of the dangerous operation\n@throws IOException\n@return True if user confirms the operation in either command-line input\nor here.",
"Appends the indentation string at the current position of the parent and adds a new composite node, indicating the same indentation for\nsubsequent lines.\n\n@return an indentation node, using the given indentString, appended as a child on the given parent",
"This method is used to finalize the configuration\nafter the configuration items have been set.",
"Marks inbox message as read for given messageId\n@param messageId String messageId\n@return boolean value depending on success of operation",
"Formats an IPTC string for this reference using information obtained from\nSubject Reference System.\n\n@param srs\nreference subject reference system\n@return IPTC formatted reference",
"Get the script for a given ID\n\n@param id ID of script\n@return Script if found, otherwise null"
] |
public float getBitangentY(int vertex) {
if (!hasTangentsAndBitangents()) {
throw new IllegalStateException("mesh has no bitangents");
}
checkVertexIndexBounds(vertex);
return m_bitangents.getFloat((vertex * 3 + 1) * SIZEOF_FLOAT);
} | [
"Returns the y-coordinate of a vertex tangent.\n\n@param vertex the vertex index\n@return the y coordinate"
] | [
"Retrieves the amount of working time represented by\na calendar exception.\n\n@param exception calendar exception\n@return length of time in milliseconds",
"Rebuild logging systems with updated mode\n@param newMode log mode",
"Add a marker so we can recognize this as a metadata archive. I would use the ZipFile comment, but\nthat is not available until Java 7, and Beat Link is supposed to be backwards compatible with Java 6.\nSince we are doing this anyway, we can also provide information about the nature of the cache, and\nhow many metadata entries it contains, which is useful for auto-attachment.\n\n@param trackListEntries the tracks contained in the cache, so we can record the number\n@param playlistId the playlist contained in the cache, or 0 if it is all tracks from the media\n@param zos the stream to which the ZipFile is being written\n\n@throws IOException if there is a problem creating the format entry",
"Copies the jdb log files, with additional verification of the checksums.\n\n@param sourceFile\n@param destFile\n@throws IOException",
"With the Batik SVG library it is only possible to create new SVG graphics, but you can not modify an\nexisting graphic. So, we are loading the SVG file as plain XML and doing the modifications by hand.",
"Returns the configured sort options, or the empty list if no such options are configured.\n@return The configured sort options, or the empty list if no such options are configured.",
"characters callback.",
"Sign in a group of connections to the registry by key\n\n@param key\nthe key\n@param connections\na collection of websocket connections",
"OR operation which takes the previous clause and the next clause and OR's them together."
] |
private void checkQueryCustomizer(CollectionDescriptorDef collDef, String checkLevel) throws ConstraintException
{
if (!CHECKLEVEL_STRICT.equals(checkLevel))
{
return;
}
String queryCustomizerName = collDef.getProperty(PropertyHelper.OJB_PROPERTY_QUERY_CUSTOMIZER);
if (queryCustomizerName == null)
{
return;
}
try
{
InheritanceHelper helper = new InheritanceHelper();
if (!helper.isSameOrSubTypeOf(queryCustomizerName, QUERY_CUSTOMIZER_INTERFACE))
{
throw new ConstraintException("The class "+queryCustomizerName+" specified as query-customizer of collection "+collDef.getName()+" in class "+collDef.getOwner().getName()+" does not implement the interface "+QUERY_CUSTOMIZER_INTERFACE);
}
}
catch (ClassNotFoundException ex)
{
throw new ConstraintException("The class "+ex.getMessage()+" specified as query-customizer of collection "+collDef.getName()+" in class "+collDef.getOwner().getName()+" was not found on the classpath");
}
} | [
"Checks the query-customizer setting of the given collection descriptor.\n\n@param collDef The collection descriptor\n@param checkLevel The current check level (this constraint is only checked in strict)\n@exception ConstraintException If the constraint has been violated"
] | [
"Processes the template for all procedure arguments of the current procedure.\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\"",
"Retrieve a map of custom document properties.\n\n@return the Document Summary Information Map",
"Returns a matrix of StatisticsMatrix type so that SimpleMatrix functions create matrices\nof the correct type.",
"Use this API to apply nspbr6.",
"Read filename from spec.",
"Returns current selenium version from JAR set in classpath.\n\n@return Version of Selenium.",
"takes the pixels from a BufferedImage and stores them in an array",
"Read the top level tasks from GanttProject.\n\n@param gpProject GanttProject project",
"Initialize the key set for an xml bundle."
] |
public static CuratorFramework newCurator(String zookeepers, int timeout, String secret) {
final ExponentialBackoffRetry retry = new ExponentialBackoffRetry(1000, 10);
if (secret.isEmpty()) {
return CuratorFrameworkFactory.newClient(zookeepers, timeout, timeout, retry);
} else {
return CuratorFrameworkFactory.builder().connectString(zookeepers)
.connectionTimeoutMs(timeout).sessionTimeoutMs(timeout).retryPolicy(retry)
.authorization("digest", ("fluo:" + secret).getBytes(StandardCharsets.UTF_8))
.aclProvider(new ACLProvider() {
@Override
public List<ACL> getDefaultAcl() {
return CREATOR_ALL_ACL;
}
@Override
public List<ACL> getAclForPath(String path) {
switch (path) {
case ZookeeperPath.ORACLE_GC_TIMESTAMP:
// The garbage collection iterator running in Accumulo tservers needs to read this
// value w/o authenticating.
return PUBLICLY_READABLE_ACL;
default:
return CREATOR_ALL_ACL;
}
}
}).build();
}
} | [
"Creates a curator built using the given zookeeper connection string and timeout"
] | [
"Removes the given value to the set.\n\n@return true if the value was actually removed",
"Handle http Request.\n\n@param request HttpRequest to be handled.\n@param responder HttpResponder to write the response.\n@param groupValues Values needed for the invocation.",
"Prepare the baseURL to make a request.\n\n@param matrixId matrixId\n@param row row\n@param col cold\n@param layerParam layerParam",
"Use this API to fetch the statistics of all nslimitidentifier_stats resources that are configured on netscaler.",
"Merge all reports in reportOverall.\n@param reportOverall destination file of merge.\n@param reports files to be merged.",
"Initializes the external child resource collection.",
"Retrieve the number of minutes per month for this calendar.\n\n@return minutes per month",
"Closes the outbound socket binding connection.\n\n@throws IOException",
"Print formatted string in the center of 80 chars line, left and right padded.\n\n@param format\nThe string format pattern\n@param args\nThe string format arguments"
] |
private void emitStatusLine(AggregatedResultEvent result, TestStatus status, long timeMillis) throws IOException {
final StringBuilder line = new StringBuilder();
line.append(shortTimestamp(result.getStartTimestamp()));
line.append(Strings.padEnd(statusNames.get(status), 8, ' '));
line.append(formatDurationInSeconds(timeMillis));
if (forkedJvmCount > 1) {
line.append(String.format(Locale.ROOT, jvmIdFormat, result.getSlave().id));
}
line.append(" | ");
line.append(formatDescription(result.getDescription()));
if (!result.isSuccessful()) {
line.append(FAILURE_MARKER);
}
line.append("\n");
if (showThrowable) {
// GH-82 (cause for ignored tests).
if (status == TestStatus.IGNORED && result instanceof AggregatedTestResultEvent) {
final StringWriter sw = new StringWriter();
PrefixedWriter pos = new PrefixedWriter(indent, sw, DEFAULT_MAX_LINE_WIDTH);
pos.write("Cause: ");
pos.write(((AggregatedTestResultEvent) result).getCauseForIgnored());
pos.completeLine();
line.append(sw.toString());
}
final List<FailureMirror> failures = result.getFailures();
if (!failures.isEmpty()) {
final StringWriter sw = new StringWriter();
PrefixedWriter pos = new PrefixedWriter(indent, sw, DEFAULT_MAX_LINE_WIDTH);
int count = 0;
for (FailureMirror fm : failures) {
count++;
if (fm.isAssumptionViolation()) {
pos.write(String.format(Locale.ROOT,
"Assumption #%d: %s",
count, MoreObjects.firstNonNull(fm.getMessage(), "(no message)")));
} else {
pos.write(String.format(Locale.ROOT,
"Throwable #%d: %s",
count,
showStackTraces ? filterStackTrace(fm.getTrace()) : fm.getThrowableString()));
}
}
pos.completeLine();
if (sw.getBuffer().length() > 0) {
line.append(sw.toString());
}
}
}
logShort(line);
} | [
"Emit status line for an aggregated event."
] | [
"Use this API to update cachecontentgroup.",
"Deletes the device pin.",
"Helper method to track storage operations & time via StreamingStats.\n\n@param startNs",
"Unregister the mbean with the given name, if there is one registered\n\n@param name The mbean name to unregister\n@see #registerMBean(Object, String)",
"Get a collection of methods declared on this object by method name.\n\n@param name the name of the method\n@return the (possibly empty) collection of methods with the given name",
"Returns an array of the enabled endpoints as Integer IDs\n\n@param pathId ID of path\n@param clientUUID UUID of client\n@param filters If supplied, only endpoints ending with values in filters are returned\n@return Collection of endpoints\n@throws Exception exception",
"Escapes args' string values according to format\n\n@param format the Format used by the PrintStream\n@param args the array of args to escape\n@return The cloned and escaped array of args",
"Generates a usable test specification for a given test definition\nUses the first bucket as the fallback value\n\n@param testDefinition a {@link TestDefinition}\n@return a {@link TestSpecification} which corresponding to given test definition.",
"return a prepared Insert Statement fitting for the given ClassDescriptor"
] |
public static boolean isBeanProxyable(Bean<?> bean, BeanManagerImpl manager) {
if (bean instanceof RIBean<?>) {
return ((RIBean<?>) bean).isProxyable();
} else {
return Proxies.isTypesProxyable(bean.getTypes(), manager.getServices());
}
} | [
"Indicates if a bean is proxyable\n\n@param bean The bean to test\n@return True if proxyable, false otherwise"
] | [
"Initializes the editor states for the different modes, depending on the type of the opened file.",
"Establish connection to the ChromeCast device",
"Add BoxMetaDataFilter to the JsonArray boxMetadataFilterRequestArray.\n@param @param bmf accepts a filter that has templateKey, scope, and filters populated.\n@return JsonArray that is formated Json request",
"Split input text into sentences.\n\n@param text Input text.\n@return List of Sentence objects.",
"Set the payload to the fileModel of the given instance even though the variable is not directly of it's type. This is mainly to simplify the\ncreation of the rule, when the FileModel itself is not being iterated but just a model referencing it.",
"Read activities.",
"Declares additional internal data structures.",
"Uploads chunk of a stream to an open upload session.\n@param stream the stream that is used to read the chunck using the offset and part size.\n@param offset the byte position where the chunk begins in the file.\n@param partSize the part size returned as part of the upload session instance creation.\nOnly the last chunk can have a lesser value.\n@param totalSizeOfFile The total size of the file being uploaded.\n@return the part instance that contains the part id, offset and part size.",
"2-D Integer array to double array.\n\n@param array Integer array.\n@return Double array."
] |
public Resource addReference(Reference reference) {
Resource resource = this.rdfWriter.getUri(Vocabulary.getReferenceUri(reference));
this.referenceQueue.add(reference);
this.referenceSubjectQueue.add(resource);
return resource;
} | [
"Adds the given reference to the list of references that should still be\nserialized, and returns the RDF resource that will be used as a subject.\n\n@param reference\nthe reference to be serialized\n@return RDF resource that represents this reference"
] | [
"todo move to commonops",
"adds a CmsJspImageBean as hi-DPI variant to this image\n@param factor the variant multiplier, e.g. \"2x\" (the common retina multiplier)\n@param image the image to be used for this variant",
"Use this API to fetch all the transformpolicy resources that are configured on netscaler.",
"Sets the value of the setting with the specified key.\n\n@param key name of the setting\n@param value the setting value\n@return this {@code EnvironmentConfig} instance",
"Push docker image using the docker java client.\n\n@param imageTag\n@param username\n@param password\n@param host",
"add a new producer, either synchronous or asynchronous, connecting\nto the specified broker\n\n@param broker broker to producer",
"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",
"Creates new metadata template.\n@param api the API connection to be used.\n@param scope the scope of the object.\n@param templateKey a unique identifier for the template.\n@param displayName the display name of the field.\n@param hidden whether this template is hidden in the UI.\n@param fields the ordered set of fields for the template\n@return the metadata template returned from the server.",
"Convert an operation for deployment overlays to be executed on local servers.\nSince this might be called in the case of redeployment of affected deployments, we need to take into account\nthe composite op resulting from such a transformation\n@see AffectedDeploymentOverlay#redeployLinksAndTransformOperationForDomain\n@param operation\n@param host\n@return"
] |
public Where<T, ID> ne(String columnName, Object value) throws SQLException {
addClause(new SimpleComparison(columnName, findColumnFieldType(columnName), value,
SimpleComparison.NOT_EQUAL_TO_OPERATION));
return this;
} | [
"Add a '<>' clause so the column must be not-equal-to the value."
] | [
"Retrieve the ordinal text for a given integer.\n\n@param value integer value\n@return ordinal text",
"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",
"Runs the currently entered query and displays the results.",
"This logic is shared for all actual types i.e. raw types, parameterized types and generic array types.",
"Applies the > operator to each element in A. Results are stored in a boolean matrix.\n\n@param A Input matrx\n@param value value each element is compared against\n@param output (Optional) Storage for results. Can be null. Is reshaped.\n@return Boolean matrix with results",
"Wrap an operation's parameters in a simple encapsulating object\n@param operation the operation\n@param messageHandler the message handler\n@param attachments the attachments\n@return the encapsulating object",
"Handles reports by consumers\n\n@param name the name of the reporting consumer\n@param report the number of lines the consumer has written since last report\n@return \"exit\" if maxScenarios has been reached, \"ok\" otherwise",
"Adds a path to the request response table with the specified values\n\n@param profileId ID of profile\n@param clientUUID UUID of client\n@param pathId ID of path\n@throws Exception exception",
"Make a copy of this Area of Interest."
] |
static void processFile(final IdentityPatchContext context, final File file, final PatchingTaskContext.Mode mode) throws IOException {
if (mode == PatchingTaskContext.Mode.APPLY) {
if (ENABLE_INVALIDATION) {
updateJar(file, GOOD_ENDSIG_PATTERN, BAD_BYTE_SKIP, CRIPPLED_ENDSIG, GOOD_ENDSIG);
backup(context, file);
}
} else if (mode == PatchingTaskContext.Mode.ROLLBACK) {
updateJar(file, CRIPPLED_ENDSIG_PATTERN, BAD_BYTE_SKIP, GOOD_ENDSIG, CRIPPLED_ENDSIG);
restore(context, file);
} else {
throw new IllegalStateException();
}
} | [
"Process a file.\n\n@param file the file to be processed\n@param mode the patching mode\n@throws IOException"
] | [
"Creates a single property declaration.\n@param property Property name.\n@param term Property value.\n@return The resulting declaration.",
"Generate a call to the delegate object.",
"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",
"Start the timer.",
"checks if the 2 triangles shares a segment\n@author Doron Ganel & Eyal Roth(2009)\n@param t2 - a second triangle\n@return boolean",
"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.",
"Adds mappings for each declared field in the mapped class. Any fields\nalready mapped by addColumn are skipped.",
"Given a binary expression corresponding to an assignment, will check that the type of the RHS matches one\nof the possible setters and if not, throw a type checking error.\n@param expression the assignment expression\n@param leftExpression left expression of the assignment\n@param rightExpression right expression of the assignment\n@param setterInfo possible setters\n@return true if type checking passed",
"Gets the filename from a path or URL.\n@param path or url.\n@return the file name."
] |
private String addPathProperty(final List<String> command, final String typeName, final String propertyName, final Map<String, String> properties, final DirectoryGrouping directoryGrouping,
final File typeDir, File serverDir) {
final String result;
final String value = properties.get(propertyName);
if (value == null) {
switch (directoryGrouping) {
case BY_TYPE:
result = getAbsolutePath(typeDir, "servers", serverName);
break;
case BY_SERVER:
default:
result = getAbsolutePath(serverDir, typeName);
break;
}
properties.put(propertyName, result);
} else {
final File dir = new File(value);
switch (directoryGrouping) {
case BY_TYPE:
result = getAbsolutePath(dir, "servers", serverName);
break;
case BY_SERVER:
default:
result = getAbsolutePath(dir, serverName);
break;
}
}
command.add(String.format("-D%s=%s", propertyName, result));
return result;
} | [
"Adds the absolute path to command.\n\n@param command the command to add the arguments to.\n@param typeName the type of directory.\n@param propertyName the name of the property.\n@param properties the properties where the path may already be defined.\n@param directoryGrouping the directory group type.\n@param typeDir the domain level directory for the given directory type; to be used for by-type grouping\n@param serverDir the root directory for the server, to be used for 'by-server' grouping\n@return the absolute path that was added."
] | [
"This method takes a calendar of MPXJ library type, then returns a String of the\ngeneral working days USACE format. For example, the regular 5-day work week is\nNYYYYYN\n\nIf you get Fridays off work, then the String becomes NYYYYNN\n\n@param input ProjectCalendar instance\n@return work days string",
"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",
"Use this API to fetch all the sslaction resources that are configured on netscaler.",
"Set the color at \"index\" to \"color\". Entries are interpolated linearly from\nthe existing entries at \"firstIndex\" and \"lastIndex\" to the new entry.\nfirstIndex < index < lastIndex must hold.\n@param index the position to set\n@param firstIndex the position of the first color from which to interpolate\n@param lastIndex the position of the second color from which to interpolate\n@param color the color to set",
"Checks whether the given field definition is used as the primary key of a class referenced by\na reference.\n\n@param modelDef The model\n@param fieldDef The current field descriptor def\n@return The reference that uses the field or <code>null</code> if the field is not used in this way",
"Registers the Columngroup Buckets and creates the header cell for the columns",
"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",
"Create a new service activator for the domain server communication services.\n\n@param endpointConfig the endpoint configuration\n@param managementURI the management connection URI\n@param serverName the server name\n@param serverProcessName the server process name\n@param authKey the authentication key\n@param managementSubsystemEndpoint whether to use the mgmt subsystem endpoint or not\n@return the service activator",
"Returns the compact records for all teams in the organization visible to\nthe authorized user.\n\n@param organization Globally unique identifier for the workspace or organization.\n@return Request object"
] |
public void addFile(File file) {
String name = "file";
files.put(normalizeDuplicateName(name), file);
} | [
"Adds a file to your assembly but automatically generates the field name of the file.\n\n@param file {@link File} the file to be uploaded."
] | [
"Extracts a house holder vector from the column of A and stores it in u\n@param A Complex matrix with householder vectors stored in the lower left triangle\n@param row0 first row in A (implicitly assumed to be r + i0)\n@param row1 last row + 1 in A\n@param col Column in A\n@param u Output array storage\n@param offsetU first index in U",
"Use this API to update vridparam.",
"Get the features collection from a GeoJson inline string or URL.\n\n@param template the template\n@param features what to parse\n@return the feature collection\n@throws IOException",
"Returns a \"clean\" version of the given filename in which spaces have\nbeen converted to dashes and all non-alphanumeric chars are underscores.",
"Generate the global CSS style for the whole document.\n@return the CSS code used in the generated document header",
"Perform a one-off scan during boot to establish deployment tasks to execute during boot",
"Converts assignment duration values from minutes to hours.\n\n@param list assignment data",
"Returns the start position of the indicator.\n\n@return The start position of the indicator.",
"set the textColor of the ColorHolder to a view\n\n@param view"
] |
private Project.Tasks.Task.PredecessorLink writePredecessor(Integer taskID, RelationType type, Duration lag)
{
Project.Tasks.Task.PredecessorLink link = m_factory.createProjectTasksTaskPredecessorLink();
link.setPredecessorUID(NumberHelper.getBigInteger(taskID));
link.setType(BigInteger.valueOf(type.getValue()));
link.setCrossProject(Boolean.FALSE); // SF-300: required to keep P6 happy when importing MSPDI files
if (lag != null && lag.getDuration() != 0)
{
double linkLag = lag.getDuration();
if (lag.getUnits() != TimeUnit.PERCENT && lag.getUnits() != TimeUnit.ELAPSED_PERCENT)
{
linkLag = 10.0 * Duration.convertUnits(linkLag, lag.getUnits(), TimeUnit.MINUTES, m_projectFile.getProjectProperties()).getDuration();
}
link.setLinkLag(BigInteger.valueOf((long) linkLag));
link.setLagFormat(DatatypeConverter.printDurationTimeUnits(lag.getUnits(), false));
}
else
{
// SF-329: default required to keep Powerproject happy when importing MSPDI files
link.setLinkLag(BIGINTEGER_ZERO);
link.setLagFormat(DatatypeConverter.printDurationTimeUnits(m_projectFile.getProjectProperties().getDefaultDurationUnits(), false));
}
return (link);
} | [
"This method writes a single predecessor link to the MSPDI file.\n\n@param taskID The task UID\n@param type The predecessor type\n@param lag The lag duration\n@return A new link to be added to the MSPDI file"
] | [
"Print an extended attribute date value.\n\n@param value date value\n@return string representation",
"Creates an empty block style definition.\n@return",
"Plots the MSD curve for trajectory t\n@param t Trajectory to calculate the msd curve\n@param lagMin Minimum timelag (e.g. 1,2,3..) lagMin*timelag = elapsed time in seconds\n@param lagMax Maximum timelag (e.g. 1,2,3..) lagMax*timelag = elapsed time in seconds\n@param msdeval Evaluates the mean squared displacment",
"a small static helper to set the color to a GradientDrawable null save\n\n@param colorHolder\n@param ctx\n@param gradientDrawable",
"Write a size prefixed string where the size is stored as a 2 byte\nshort\n\n@param buffer The buffer to write to\n@param s The string to write",
"Expands the directories from the given list and and returns a list of subfiles.\nFiles from the original list are kept as is.",
"Run the OnInvariantViolation plugins when an Invariant is violated. Invariant are checked\nwhen the state machine is updated that is when the dom is changed after a click on a\nclickable. When a invariant fails this kind of plugins are executed. Warning the session is\nnot a clone, changing the session can cause strange behaviour of Crawljax.\n\n@param invariant the failed invariants\n@param context the current {@link CrawlerContext} for this crawler.",
"Convert a Java date into a Planner time.\n\n0800\n\n@param value Java Date instance\n@return Planner time value",
"Get the metadata cache files that are currently configured to be automatically attached when matching media is\nmounted in a player on the network.\n\n@return the current auto-attache cache files, sorted by name"
] |
public static String simpleTypeName(Object obj) {
if (obj == null) {
return "null";
}
return simpleTypeName(obj.getClass(), false);
} | [
"Returns the simplified name of the type of the specified object."
] | [
"Delete old jobs.\n\n@param checkTimeThreshold threshold for last check time\n@return the number of jobs deleted",
"Converts the results to CSV data.\n\n@return the CSV data",
"Map message info.\n\n@param messageInfoType the message info type\n@return the message info",
"Get a project according to its full name.\n\n@param fullName The full name of the project.\n@return The project which answers the full name.",
"Utility function to get the current value.",
"marks the message as read",
"Returns if a request should be retried based on the retry count, current response,\nand the current strategy.\n\n@param retryCount The current retry attempt count.\n@param response The exception that caused the retry conditions to occur.\n@return true if the request should be retried; false otherwise.",
"Computes the inverse permutation vector\n\n@param original Original permutation vector\n@param inverse It's inverse",
"Stop Redwood, closing all tracks and prohibiting future log messages."
] |
public void onSplashScreenCreated(GVRSceneObject splashScreen) {
GVRTransform transform = splashScreen.getTransform();
transform.setPosition(0, 0, DEFAULT_SPLASH_Z);
} | [
"Override this method to change the default splash screen size or\nposition.\n\nThis method will be called <em>before</em> {@link #onInit(GVRContext)\nonInit()} and before the normal render pipeline starts up. In particular,\nthis means that any {@linkplain GVRAnimation animations} will not start\nuntil the first {@link #onStep()} and normal rendering starts.\n\n@param splashScreen\nThe splash object created from\n{@link #getSplashTexture(GVRContext)},\n{@link #getSplashMesh(GVRContext)}, and\n{@link #getSplashShader(GVRContext)}.\n\n@since 1.6.4"
] | [
"Detokenize the input list of words.\n\n@param tokens List of words.\n@return Detokenized string.",
"Reads the detail container resources which are connected by relations to the given resource.\n\n@param cms the current CMS context\n@param res the detail content\n\n@return the list of detail only container resources\n\n@throws CmsException if something goes wrong",
"Compute costs.",
"Writes the JavaScript code describing the tags as Tag classes to given writer.",
"Checks if user exists.\n\n@param userId the user id, which can be an email or the login.\n@return true, if user exists.",
"Retrieve and validate the key from the REST request.\n\n@return true if present, false if missing",
"This method retrieves all security permissions contained within the specified node.\n\n@param context the {@link OperationContext} used to resolve the permission attributes.\n@param node the {@link ModelNode} that might contain security permissions metadata.\n@return a {@link List} containing the retrieved permissions. They are wrapped as {@link PermissionFactory} instances.\n@throws OperationFailedException if an error occurs while retrieving the security permissions.",
"Initializes the metadataCache for MetadataStore",
"Create a new GP entry in the database. No commit performed."
] |
public synchronized static <D extends Dao<T, ?>, T> D lookupDao(ConnectionSource connectionSource, Class<T> clazz) {
if (connectionSource == null) {
throw new IllegalArgumentException("connectionSource argument cannot be null");
}
ClassConnectionSource key = new ClassConnectionSource(connectionSource, clazz);
Dao<?, ?> dao = lookupDao(key);
@SuppressWarnings("unchecked")
D castDao = (D) dao;
return castDao;
} | [
"Helper method to lookup a DAO if it has already been associated with the class. Otherwise this returns null."
] | [
"Use this API to fetch the statistics of all appfwpolicy_stats resources that are configured on netscaler.",
"Retrieve the number of minutes per day for this calendar.\n\n@return minutes per day",
"Gets the node meta data.\n\n@param key - the meta data key\n@return the node meta data value for this key",
"Use this API to update spilloverpolicy.",
"Apply a filter to the list of all tasks, and show the results.\n\n@param project project file\n@param filter filter",
"Sets the the time of day\n\n@param hours the hours to set. Must be guaranteed to parse as an\ninteger between 0 and 23\n\n@param minutes the minutes to set. Must be guaranteed to parse as\nan integer between 0 and 59\n\n@param seconds the optional seconds to set. Must be guaranteed to parse as\nan integer between 0 and 59\n\n@param amPm the meridian indicator to use. Must be either 'am' or 'pm'\n\n@param zoneString the time zone to use in one of two formats:\n- zoneinfo format (America/New_York, America/Los_Angeles, etc)\n- GMT offset (+05:00, -0500, +5, etc)",
"Use this API to update sslparameter.",
"Returns the compact task records for all tasks with the given tag.\nTasks can have more than one tag at a time.\n\n@param tag The tag to fetch tasks from.\n@return Request object",
"This method extracts project properties from a GanttProject file.\n\n@param ganttProject GanttProject file"
] |
protected boolean setChannel(final Channel newChannel) {
if(newChannel == null) {
return false;
}
synchronized (lock) {
if(state != State.OPEN || channel != null) {
return false;
}
this.channel = newChannel;
this.channel.addCloseHandler(new CloseHandler<Channel>() {
@Override
public void handleClose(final Channel closed, final IOException exception) {
synchronized (lock) {
if(FutureManagementChannel.this.channel == closed) {
FutureManagementChannel.this.channel = null;
}
lock.notifyAll();
}
}
});
lock.notifyAll();
return true;
}
} | [
"Set the channel. This will return whether the channel could be set successfully or not.\n\n@param newChannel the channel\n@return whether the operation succeeded or not"
] | [
"Load in a number of database configuration entries from a buffered reader.",
"Returns a query filter for the given document _id and version. The version is allowed to be\nnull. The query will match only if there is either no version on the document in the database\nin question if we have no reference of the version or if the version matches the database's\nversion.\n\n@param documentId the _id of the document.\n@param version the expected version of the document, if any.\n@return a query filter for the given document _id and version for a remote operation.",
"The only indication that a task is a SubProject is the contents\nof the subproject file name field. We test these here then add a skeleton\nsubproject structure to match the way we do things with MPP files.",
"Compares two avro strings which contains multiple store configs\n\n@param configAvro1\n@param configAvro2\n@return true if two config avro strings have same content",
"Return the List of VariableExpression objects referenced by the specified DeclarationExpression.\n@param declarationExpression - the DeclarationExpression\n@return the List of VariableExpression objects",
"Update the state of the picker. If it has an owner, the picker\nwill use that object to derive its position and orientation.\nThe \"active\" state of this controller is used to indicate touch.\nThe cursor position is updated after picking.",
"Use this API to fetch all the ntpserver resources that are configured on netscaler.",
"Forceful cleanup the logs",
"Notify the widget that refresh state has changed. Do not call this when\nrefresh is triggered by a swipe gesture.\n\n@param refreshing Whether or not the view should show refresh progress."
] |
public void setNodeMetaData(Object key, Object value) {
if (key==null) throw new GroovyBugError("Tried to set meta data with null key on "+this+".");
if (metaDataMap == null) {
metaDataMap = new ListHashMap();
}
Object old = metaDataMap.put(key,value);
if (old!=null) throw new GroovyBugError("Tried to overwrite existing meta data "+this+".");
} | [
"Sets the node meta data.\n\n@param key - the meta data key\n@param value - the meta data value\n@throws GroovyBugError if key is null or there is already meta\ndata under that key"
] | [
"Converts an XML file to an object.\n\n@param fileName The filename where to save it to.\n@return The object.\n@throws FileNotFoundException On error.",
"The quick way to detect for a tier of devices.\nThis method detects for devices which are likely to be capable\nof viewing CSS content optimized for the iPhone,\nbut may not necessarily support JavaScript.\nExcludes all iPhone Tier devices.\n@return detection of any device in the 'Rich CSS' Tier",
"Determines total number of partition-stores moved across zones.\n\n@return number of cross zone partition-store moves",
"Complete the current operation and persist the current state to the disk. This will also trigger the invalidation\nof outdated modules.\n\n@param modification the current modification\n@param callback the completion callback",
"Marshal the assertion as a JSON object.\n\n@param assertion the assertion to marshal",
"Creates a slice for directly a raw memory address. This is\ninherently unsafe as it may be used to access arbitrary memory.\n\n@param address the raw memory address base\n@param size the size of the slice\n@return the unsafe slice",
"Update a feature object in the Hibernate session.\n\n@param feature feature object\n@throws LayerException oops",
"Generic version of getting value by key from the JobContext of current thread\n@param key the key\n@param clz the val class\n@param <T> the val type\n@return the value",
"Returns a diagonal matrix with the specified diagonal elements.\n@param values values of diagonal elements\n@return A diagonal matrix"
] |
public StringBuilder getSQLCondition(StringBuilder builder, String columnName) {
String string = networkString.getString();
if(isEntireAddress) {
matchString(builder, columnName, string);
} else {
matchSubString(
builder,
columnName,
networkString.getTrailingSegmentSeparator(),
networkString.getTrailingSeparatorCount() + 1,
string);
}
return builder;
} | [
"Get an SQL condition to match this address section representation\n\n@param builder\n@param columnName\n@return the condition"
] | [
"Use this API to fetch lbmonbindings_servicegroup_binding resources of given name .",
"Get a timer of the given string name and todos for the current thread. If\nno such timer exists yet, then it will be newly created.\n\n@param timerName\nthe name of the timer\n@param todoFlags\n@return timer",
"Replies the elements of the given map except the pairs with the given keys.\n\n<p>\nThe replied map is a view on the given map. It means that any change\nin the original map is reflected to the result of this operation.\n</p>\n\n@param <K> type of the map keys.\n@param <V> type of the map values.\n@param map the map to update.\n@param keys the keys of the pairs to remove.\n@return the map with the content of the map except the pairs.\n@since 2.15",
"Creates a decorator bean\n\n@param <T> The type\n@param clazz The class\n@param beanManager the current manager\n@return a Bean",
"Flush this log file to the physical disk\n\n@throws IOException file read error",
"Determine if the buffer, when expressed as text, matches a fingerprint regular expression.\n\n@param buffer bytes from file\n@param fingerprint fingerprint regular expression\n@return true if the file matches the fingerprint",
"Start a process using the given parameters.\n\n@param processId\n@param parameters\n@return",
"Reads data from a single page of the database file.\n\n@param buffer page from the database file\n@param table Table instance",
"Returns a signed string representation of the given number.\n\n@param number\n@return String for BigDecimal value"
] |
private void registerRequirement(RuntimeRequirementRegistration requirement) {
assert writeLock.isHeldByCurrentThread();
CapabilityId dependentId = requirement.getDependentId();
if (!capabilities.containsKey(dependentId)) {
throw ControllerLogger.MGMT_OP_LOGGER.unknownCapabilityInContext(dependentId.getName(),
dependentId.getScope().getName());
}
Map<CapabilityId, Map<String, RuntimeRequirementRegistration>> requirementMap =
requirement.isRuntimeOnly() ? runtimeOnlyRequirements : requirements;
Map<String, RuntimeRequirementRegistration> dependents = requirementMap.get(dependentId);
if (dependents == null) {
dependents = new HashMap<>();
requirementMap.put(dependentId, dependents);
}
RuntimeRequirementRegistration existing = dependents.get(requirement.getRequiredName());
if (existing == null) {
dependents.put(requirement.getRequiredName(), requirement);
} else {
existing.addRegistrationPoint(requirement.getOldestRegistrationPoint());
}
modified = true;
} | [
"This must be called with the write lock held.\n@param requirement the requirement"
] | [
"Gets the path used for the results of XSLT Transforms.",
"Write the work weeks associated with this calendar.\n\n@param xmlCalendar XML calendar instance\n@param mpxjCalendar MPXJ calendar instance",
"Load physics information for the current avatar\n@param filename name of physics file\n@param scene scene the avatar is part of\n@throws IOException if physics file cannot be parsed",
"Find the path.\n\n@param start key of first node in the path\n@param end key of last node in the path\n@return string containing the nodes keys in the path separated by arrow symbol",
"Determine whether the given method is a \"readString\" method.\n\n@see Object#toString()",
"Creates necessary objects to make a chart an hyperlink\n\n@param design\n@param djlink\n@param chart\n@param name",
"Iterates through the range of prefixes in this range instance using the given prefix length.\n\n@param prefixLength\n@return",
"Start unmarshalling using the parser.\n@param parser\n@param preProcessingData\n@return the root element of a bpmn2 document.\n@throws java.io.IOException",
"Get the service implementations for a given type name.\n\n@param serviceTypeName the type name\n@return the possibly empty list of services"
] |
public static String readFlowId(Message message) {
String flowId = null;
Map<String, List<String>> headers = getOrCreateProtocolHeader(message);
List<String> flowIds = headers.get(FLOWID_HTTP_HEADER_NAME);
if (flowIds != null && flowIds.size() > 0) {
flowId = flowIds.get(0);
if (LOG.isLoggable(Level.FINE)) {
LOG.fine("HTTP header '" + FLOWID_HTTP_HEADER_NAME + "' found: " + flowId);
}
} else {
if (LOG.isLoggable(Level.FINE)) {
LOG.fine("No HTTP header '" + FLOWID_HTTP_HEADER_NAME + "' found");
}
}
return flowId;
} | [
"Read flow id from message.\n\n@param message the message\n@return the FlowId as string"
] | [
"Sets the currency code, or the regular expression to select codes.\n\n@param codes the currency codes or code expressions, not null.\n@return the query for chaining.",
"Remove all of the audio sources from the audio manager.\nThis will stop all sound from playing.",
"Serialize specified object to directory with specified name.\n\n@param directory write to\n@param name serialize object with specified name\n@param obj object to serialize\n@return number of bytes written to directory",
"Ensure the current throughput levels for the tracked operation does not\nexceed set quota limits. Throws an exception if exceeded quota.\n\n@param quotaKey\n@param trackedOp",
"Gets the uuid from response.\n\n@param myResponse\nthe my response\n@return the uuid from response",
"Returns the optional query modifier.\n@return the optional query modifier.",
"Deletes the given directory.\n\n@param directory The directory to delete.",
"Returns the plugins classpath elements.",
"Return the basis functions for the regression suitable for this product.\n\n@param fixingDate The condition time.\n@param model The model\n@return The basis functions for the regression suitable for this product.\n@throws net.finmath.exception.CalculationException Thrown if the valuation fails, specific cause may be available via the <code>cause()</code> method."
] |
public void processDefaultCurrency(Row row)
{
ProjectProperties properties = m_project.getProjectProperties();
properties.setCurrencySymbol(row.getString("curr_symbol"));
properties.setSymbolPosition(CURRENCY_SYMBOL_POSITION_MAP.get(row.getString("pos_curr_fmt_type")));
properties.setCurrencyDigits(row.getInteger("decimal_digit_cnt"));
properties.setThousandsSeparator(row.getString("digit_group_symbol").charAt(0));
properties.setDecimalSeparator(row.getString("decimal_symbol").charAt(0));
} | [
"Code common to both XER and database readers to extract\ncurrency format data.\n\n@param row row containing currency data"
] | [
"If the deployment has a module attached it will ask the module to load the ServiceActivator services.\n\n@param phaseContext the deployment unit context",
"Add a property.",
"Write a date field to the JSON file.\n\n@param fieldName field name\n@param value field value",
"Performs a Bulk Documents insert request.\n\n@param objects The {@link List} of objects.\n@param allOrNothing Indicates whether the request has <tt>all-or-nothing</tt> semantics.\n@return {@code List<Response>} Containing the resulted entries.",
"Give an embedded association, creates all the nodes and relationships required to represent it.\nIt assumes that the entity node containing the association already exists in the db.\n\n@param executionEngine the {@link GraphDatabaseService} to run the query\n@param associationKey the {@link AssociationKey} identifying the association\n@param embeddedKey the {@link EntityKey} identifying the embedded component\n@return the created {@link Relationship} that represents the association",
"Build and return the complete URI containing values\nsuch as the document ID, attachment ID, and query syntax.",
"Returns an array of the names of all atributes of this descriptor.\n\n@return The list of attribute names (will not be <code>null</code>)",
"Unzip a file or a folder\n@param zipFile\n@param unzippedFolder optional, if null the file/folder will be extracted in the same folder as zipFile\n@return",
"Delete a database for a given path and userId.\n@param appInfo the info for this application\n@param serviceName the name of the associated service\n@param clientFactory the associated factory that creates clients\n@param userId the id of the user's to delete\n@return true if successfully deleted, false if not"
] |
private void writeDurationField(String fieldName, Object value) throws IOException
{
if (value instanceof String)
{
m_writer.writeNameValuePair(fieldName + "_text", (String) value);
}
else
{
Duration val = (Duration) value;
if (val.getDuration() != 0)
{
Duration minutes = val.convertUnits(TimeUnit.MINUTES, m_projectFile.getProjectProperties());
long seconds = (long) (minutes.getDuration() * 60.0);
m_writer.writeNameValuePair(fieldName, seconds);
}
}
} | [
"Write a duration field to the JSON file.\n\n@param fieldName field name\n@param value field value"
] | [
"Non-supported in JadeAgentIntrospector",
"Read data for a single table and store it.\n\n@param is input stream\n@param table table header",
"Open the log file for writing.",
"Use this API to add gslbsite.",
"generate a message for loglevel DEBUG\n\n@param pObject the message Object",
"Performs a get all operation with the specified composite request object\n\n@param requestWrapper Composite request object containing a reference to\nthe Iterable keys\n\n@return Map of the keys to the corresponding versioned values",
"Possibly coalesces the newest change event to match the user's original intent. For example,\nan unsynchronized insert and update is still an insert.\n\n@param lastUncommittedChangeEvent the last change event known about for a document.\n@param newestChangeEvent the newest change event known about for a document.\n@return the possibly coalesced change event.",
"Returns the default output for functions without configured JSPs.\n\n@param request the current request\n@return the default HTML output",
"I pulled this out of internal store so that when doing multiple table\ninheritance, i can recurse this function.\n\n@param obj\n@param cld\n@param oid BRJ: what is it good for ???\n@param insert\n@param ignoreReferences"
] |
public Rule CriteriaOnlyFindQuery() {
return Sequence( !peek().isCliQuery(), JsonParameter( JsonObject() ) , peek().setOperation( Operation.FIND ), peek().setCriteria( match() ) );
} | [
"A find query only given as criterion. Leave it to MongoDB's own parser to handle it.\n\n@return the {@link Rule} to identify a find query only"
] | [
"Reads the NTriples file from the reader, pushing statements into\nthe handler.",
"Write file creation record.\n\n@throws IOException",
"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.",
"Add all elements in the iterator to the collection.\n\n@param target\n@param iterator\n@return true if the target was modified, false otherwise",
"This method lists any notes attached to tasks.\n\n@param file MPX file",
"Use this API to fetch all the systementitydata resources that are configured on netscaler.\nThis uses systementitydata_args which is a way to provide additional arguments while fetching the resources.",
"Retrieve a flag value.\n\n@param index flag index (1-20)\n@return flag value",
"Sets the occurence.\n\n@param min the min\n@param max the max\n@throws ParseException the parse exception",
"Set the week days the events should occur.\n@param weekDays the week days to set."
] |
private void initComponents(List<CmsSetupComponent> components) {
for (CmsSetupComponent component : components) {
CheckBox checkbox = new CheckBox();
checkbox.setValue(component.isChecked());
checkbox.setCaption(component.getName() + " - " + component.getDescription());
checkbox.setDescription(component.getDescription());
checkbox.setData(component);
checkbox.setWidth("100%");
m_components.addComponent(checkbox);
m_componentCheckboxes.add(checkbox);
m_componentMap.put(component.getId(), component);
}
} | [
"Initializes the components.\n\n@param components the components"
] | [
"Use this API to fetch tmsessionpolicy_binding resource of given name .",
"Method used to write the name of the scenarios\n\n@param word\n@return the same word starting with capital letter",
"This version assumes relativeIndices array no longer needs to\nbe copied. Further it is assumed that it has already been\nchecked or assured by construction that relativeIndices\nis sorted.",
"Clears all checked widgets in the group",
"Runs a Story with the given configuration and steps, applying the given\nmeta filter.\n\n@param configuration the Configuration used to run story\n@param candidateSteps the List of CandidateSteps containing the candidate\nsteps methods\n@param story the Story to run\n@param filter the Filter to apply to the story Meta\n@throws Throwable if failures occurred and FailureStrategy dictates it to\nbe re-thrown.",
"Return a String with linefeeds and carriage returns normalized to linefeeds.\n\n@param self a CharSequence object\n@return the normalized toString() for the CharSequence\n@see #normalize(String)\n@since 1.8.2",
"Constructs a camera rig with cameras attached. An owner scene object is automatically\ncreated for the camera rig.\n\nDo not try to change the owner object of the camera rig - not supported currently and will\nlead to native crashes.",
"Add a polygon symbolizer definition to the rule.\n\n@param styleJson The old style.",
"returns null if no device is found."
] |
public void process(ProjectProperties properties, FilterContainer filters, FixedData fixedData, Var2Data varData)
{
int filterCount = fixedData.getItemCount();
boolean[] criteriaType = new boolean[2];
CriteriaReader criteriaReader = getCriteriaReader();
for (int filterLoop = 0; filterLoop < filterCount; filterLoop++)
{
byte[] filterFixedData = fixedData.getByteArrayValue(filterLoop);
if (filterFixedData == null || filterFixedData.length < 4)
{
continue;
}
Filter filter = new Filter();
filter.setID(Integer.valueOf(MPPUtility.getInt(filterFixedData, 0)));
filter.setName(MPPUtility.removeAmpersands(MPPUtility.getUnicodeString(filterFixedData, 4)));
byte[] filterVarData = varData.getByteArray(filter.getID(), getVarDataType());
if (filterVarData == null)
{
continue;
}
//System.out.println(ByteArrayHelper.hexdump(filterVarData, true, 16, ""));
List<GenericCriteriaPrompt> prompts = new LinkedList<GenericCriteriaPrompt>();
filter.setShowRelatedSummaryRows(MPPUtility.getByte(filterVarData, 4) != 0);
filter.setCriteria(criteriaReader.process(properties, filterVarData, 0, -1, prompts, null, criteriaType));
filter.setIsTaskFilter(criteriaType[0]);
filter.setIsResourceFilter(criteriaType[1]);
filter.setPrompts(prompts);
filters.addFilter(filter);
//System.out.println(filter);
}
} | [
"Entry point for processing filter definitions.\n\n@param properties project properties\n@param filters project filters\n@param fixedData filter fixed data\n@param varData filter var data"
] | [
"Set the draw mode for this mesh. Default is GL_TRIANGLES.\n\n@param drawMode",
"Performs the actual spell check query using Solr.\n\n@param request the spell check request\n\n@return Results of the Solr spell check of type SpellCheckResponse or null if something goes wrong.",
"Writes a resource assignment to a PM XML file.\n\n@param mpxj MPXJ ResourceAssignment instance",
"Use this API to update appfwlearningsettings resources.",
"Log warning for the resource at the provided address and single attribute, using the provided detail\nmessage.\n\n@param address where warning occurred\n@param message custom error message to append\n@param attribute attribute we are warning about",
"Inserts a Serializable value into the mapping of the underlying Bundle, replacing any existing\nvalue for the given key. Either key or value may be null.\n\n@param key a String, or null\n@param value a Serializable object, or null\n@return this bundler instance to chain method calls",
"Set the value of one or more fields based on the contents of a database row.\n\n@param map column to field map\n@param row database row\n@param container field container",
"Print the lead string followed by centered formatted string. The whole\nlength of the line is 80 chars.\n\nExample:\n\n```java\nprintCenterWithLead(\" *\", \"Hello %s\", \"World\");\n```\n\nwill print something like\n\n```\n* Hello World\n```\n\nNote the above is just a demo, the exact number of whitespace might not be correct.\n\n\n@param lead\nthe lead string\n@param format\nThe string format pattern\n@param args\nThe string format arguments",
"Use this API to fetch all the authenticationradiusaction resources that are configured on netscaler."
] |
public static int validateGeohashMaxLevels(Integer userMaxLevels, int defaultMaxLevels) {
int maxLevels = userMaxLevels == null ? defaultMaxLevels : userMaxLevels;
if (maxLevels < 1 || maxLevels > GeohashPrefixTree.getMaxLevelsPossible()) {
throw new IndexException("max_levels must be in range [1, {}], but found {}",
GeohashPrefixTree.getMaxLevelsPossible(),
maxLevels);
}
return maxLevels;
} | [
"Checks if the specified max levels is correct.\n\n@param userMaxLevels the maximum number of levels in the tree\n@param defaultMaxLevels the default max number of levels\n@return the validated max levels"
] | [
"Get parent digest of an image.\n\n@param digest\n@param host\n@return",
"Returns a string to resolve apostrophe issue in xpath\n\n@param text\n@return the apostrophe resolved xpath value string",
"Add a new column\n\n@param columnName the name of the column\n@param searchable whether the column is searchable or not\n@param orderable whether the column is orderable or not\n@param searchValue if any, the search value to apply",
"Method to declare Video-VideoRenderer mapping.\nFavorite videos will be rendered using FavoriteVideoRenderer.\nLive videos will be rendered using LiveVideoRenderer.\nLiked videos will be rendered using LikeVideoRenderer.\n\n@param content used to map object-renderers.\n@return VideoRenderer subtype class.",
"Adds format information to eval.",
"Responsible for executing file rolls as and when required, in addition to\ndelegating to the super class to perform the actual append operation.\nSynchronized for safety during enforced file roll.\n\n@see org.apache.log4j.WriterAppender#subAppend(org.apache.log4j.spi.LoggingEvent)",
"returns the total count of objects in the GeneralizedCounter.",
"Use this API to fetch snmpuser resource of given name .",
"Instantiates the templates specified by @Template within @Templates"
] |
protected BoxWatermark applyWatermark(URLTemplate itemUrl, String imprint) {
URL watermarkUrl = itemUrl.build(this.getAPI().getBaseURL(), this.getID());
URL url = WATERMARK_URL_TEMPLATE.build(watermarkUrl.toString());
BoxJSONRequest request = new BoxJSONRequest(this.getAPI(), url, "PUT");
JsonObject body = new JsonObject()
.add(BoxWatermark.WATERMARK_JSON_KEY, new JsonObject()
.add(BoxWatermark.WATERMARK_IMPRINT_JSON_KEY, imprint));
request.setBody(body.toString());
BoxJSONResponse response = (BoxJSONResponse) request.send();
return new BoxWatermark(response.getJSON());
} | [
"Used to apply or update the watermark for the item.\n@param itemUrl url template for the item.\n@param imprint the value must be \"default\", as custom watermarks is not yet supported.\n@return the watermark associated with the item."
] | [
"Send a device update to all registered update listeners.\n\n@param update the device update that has just arrived",
"Read the header data for a single file.\n\n@param header header data\n@return SynchroTable instance",
"Initialize dates panel elements.",
"Add tasks to the tree.\n\n@param parentNode parent tree node\n@param parent parent task container",
"Create a new DirectByteBuffer from a given address and size.\nThe returned DirectByteBuffer does not release the memory by itself.\n\n@param addr\n@param size\n@param att object holding the underlying memory to attach to the buffer.\nThis will prevent the garbage collection of the memory area that's\nassociated with the new <code>DirectByteBuffer</code>\n@return",
"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",
"Returns the configured page size, or the default page size if it is not configured.\n@return The configured page size, or the default page size if it is not configured.",
"Returns a list of bindings where provided queue is the destination.\n\n@param vhost vhost of the exchange\n@param queue destination queue name\n@return list of bindings",
"Retrieves the column title for the given locale.\n\n@param locale required locale for the default column title\n@return column title"
] |
public List<List<IN>> classify(String str) {
ObjectBank<List<IN>> documents =
makeObjectBankFromString(str, plainTextReaderAndWriter);
List<List<IN>> result = new ArrayList<List<IN>>();
for (List<IN> document : documents) {
classify(document);
List<IN> sentence = new ArrayList<IN>();
for (IN wi : document) {
// TaggedWord word = new TaggedWord(wi.word(), wi.answer());
// sentence.add(word);
sentence.add(wi);
}
result.add(sentence);
}
return result;
} | [
"Classify the tokens in a String. Each sentence becomes a separate document.\n\n@param str\nA String with tokens in one or more sentences of text to be\nclassified.\n@return {@link List} of classified sentences (each a List of something that\nextends {@link CoreMap})."
] | [
"This method writes project extended attribute data into an MSPDI file.\n\n@param project Root node of the MSPDI file",
"BuildInteractiveObjectFromAnchor is a special type of interactive object in that it does not get\nbuilt using ROUTE's.\n\n@param anchorSensor is the Sensor that describes the sensor set to an Anchor\n@param anchorDestination is either another Viewpoint, url to a web site or another x3d scene",
"Sets the upper limits for the \"moving\" body translation relative to joint point.\n\n@param limitX the X upper lower translation limit\n@param limitY the Y upper lower translation limit\n@param limitZ the Z upper lower translation limit",
"Read pattern information from the provided JSON object.\n@param patternJson the JSON object containing the pattern information.",
"Create a unique signature for this shader.\nThe signature for simple shaders is just the class name.\nFor the more complex shaders generated by GVRShaderTemplate\nthe signature includes information about the vertex attributes,\nuniforms, textures and lights used by the shader variant.\n\n@param defined\nnames to be defined for this shader\n@return string signature for shader\n@see GVRShaderTemplate",
"Provides the results of a QR decomposition. These will be modified by adding or removing\nrows from the original 'A' matrix.\n\n@param Q The Q matrix which is to be modified. Is modified later and reference saved.\n@param R The R matrix which is to be modified. Is modified later and reference saved.",
"Returns the index of the given name.\n\n@param name The name of the index (null or empty string for the default index)\n@return The index def or <code>null</code> if it does not exist",
"Use this API to add sslcertkey resources.",
"Use this API to fetch filtered set of vpnglobal_auditnslogpolicy_binding resources.\nset the filter parameter values in filtervalue object."
] |
public static Trajectory combineTrajectory(Trajectory a, Trajectory b){
if(a.getDimension()!=b.getDimension()){
throw new IllegalArgumentException("Combination not possible: The trajectorys does not have the same dimension");
}
if(a.size()!=b.size()){
throw new IllegalArgumentException("Combination not possible: The trajectorys does not "
+ "have the same number of steps a="+a.size() + " b="+b.size());
}
Trajectory c = new Trajectory(a.getDimension());
for(int i = 0 ; i < a.size(); i++){
Point3d pos = new Point3d(a.get(i).x+b.get(i).x,
a.get(i).y+b.get(i).y,
a.get(i).z+b.get(i).z);
c.add(pos);
}
return c;
} | [
"Combines two trajectories by adding the corresponding positions. The trajectories have to have the same length.\n@param a The first trajectory\n@param b The second trajectory\n@return The combined trajectory"
] | [
"Sets the position of a UIObject",
"Checks the query-customizer setting of the given collection descriptor.\n\n@param collDef The collection descriptor\n@param checkLevel The current check level (this constraint is only checked in strict)\n@exception ConstraintException If the constraint has been violated",
"Starts closing the keyboard when the hits are scrolled.",
"Returns the bounding sphere of the vertices.\n@param sphere destination array to get bounding sphere.\nThe first entry is the radius, the next\nthree are the center.\n@return radius of bounding sphere or 0.0 if no vertices",
"Called when app's singleton registry has been initialized",
"Classify the contents of a file.\n\n@param filename\nContains the sentence(s) to be classified.\n@return {@link List} of classified List of IN.",
"Returns an integer array that contains the current values for all the\ntexture parameters.\n\n@return an integer array that contains the current values for all the\ntexture parameters.",
"Creates a curator built using Application's zookeeper connection string. Root path will start\nat Fluo application chroot.",
"Clean obsolete contents from the content repository. It will first mark contents as obsolete then after some time\nif these contents are still obsolete they will be removed.\n\n@return a map containing the list of marked contents and the list of deleted contents."
] |
public Date getTimestamp(FastTrackField dateName, FastTrackField timeName)
{
Date result = null;
Date date = getDate(dateName);
if (date != null)
{
Calendar dateCal = DateHelper.popCalendar(date);
Date time = getDate(timeName);
if (time != null)
{
Calendar timeCal = DateHelper.popCalendar(time);
dateCal.set(Calendar.HOUR_OF_DAY, timeCal.get(Calendar.HOUR_OF_DAY));
dateCal.set(Calendar.MINUTE, timeCal.get(Calendar.MINUTE));
dateCal.set(Calendar.SECOND, timeCal.get(Calendar.SECOND));
dateCal.set(Calendar.MILLISECOND, timeCal.get(Calendar.MILLISECOND));
DateHelper.pushCalendar(timeCal);
}
result = dateCal.getTime();
DateHelper.pushCalendar(dateCal);
}
return result;
} | [
"Retrieve a timestamp field.\n\n@param dateName field containing the date component\n@param timeName field containing the time component\n@return Date instance"
] | [
"1-D Gabor function.\n\n@param x Value.\n@param mean Mean.\n@param amplitude Amplitude.\n@param position Position.\n@param width Width.\n@param phase Phase.\n@param frequency Frequency.\n@return Gabor response.",
"Called every frame if the picker is enabled\nto generate pick events.\n@param frameTime starting time of the current frame",
"returns a sorted array of nested classes and interfaces",
"Dumps all properties of a material to stdout.\n\n@param material the material",
"Add a note to a photo. The Note object bounds and text must be specified.\n\n@param photoId\nThe photo ID\n@param note\nThe Note object\n@return The updated Note object",
"Use this API to fetch all the sslcertkey resources that are configured on netscaler.",
"Retrieves a string value from the extended data.\n\n@param type Type identifier\n@return string value",
"Removes top of thread-local shell stack.",
"Create a temporary directory with the same attributes as its parent directory.\n@param dir\nthe path to directory in which to create the directory\n@param prefix\nthe prefix string to be used in generating the directory's name;\nmay be {@code null}\n@return the path to the newly created directory that did not exist before\nthis method was invoked\n@throws IOException"
] |
public int compare(Object objA, Object objB)
{
String idAStr = _table.getColumn((String)objA).getProperty("id");
String idBStr = _table.getColumn((String)objB).getProperty("id");
int idA;
int idB;
try {
idA = Integer.parseInt(idAStr);
}
catch (Exception ex) {
return 1;
}
try {
idB = Integer.parseInt(idBStr);
}
catch (Exception ex) {
return -1;
}
return idA < idB ? -1 : (idA > idB ? 1 : 0);
} | [
"Compares two columns given by their names.\n\n@param objA The name of the first column\n@param objB The name of the second column\n@return\n@see java.util.Comparator#compare(java.lang.Object, java.lang.Object)"
] | [
"This method maps the encoded height of a Gantt bar to\nthe height in pixels.\n\n@param height encoded height\n@return height in pixels",
"Extract the field types from the fieldConfigs if they have not already been configured.",
"returns the bytesize of the give bitmap",
"Set the pattern scheme to either \"by weekday\" or \"by day of month\".\n@param isByWeekDay flag, indicating if the pattern \"by weekday\" should be set.\n@param fireChange flag, indicating if a value change event should be fired.",
"Write the patch.xml\n\n@param rollbackPatch the patch\n@param file the target file\n@throws IOException",
"Adds all rows from the TSV file specified, using the provided delimiter and null value.\n\n@param file The file to read the data from.\n@param delimiter A column delimiter.\n@param nullValue Value to be treated as null in the source data.\n@return {@code this}",
"A document that is paused no longer has remote updates applied to it.\nAny local updates to this document cause it to be resumed. An example of pausing a document\nis when a conflict is being resolved for that document and the handler throws an exception.\n\nThis method allows you to resume sync for a document.\n\n@param namespace namespace for the document\n@param documentId the id of the document to resume syncing\n@return true if successfully resumed, false if the document\ncould not be found or there was an error resuming",
"Calculate start dates for a yearly absolute recurrence.\n\n@param calendar current date\n@param dates array of start dates",
"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"
] |
protected boolean isSlopDead(Cluster cluster, Set<String> storeNames, Slop slop) {
// destination node , no longer exists
if(!cluster.getNodeIds().contains(slop.getNodeId())) {
return true;
}
// destination store, no longer exists
if(!storeNames.contains(slop.getStoreName())) {
return true;
}
// else. slop is alive
return false;
} | [
"A slop is dead if the destination node or the store does not exist\nanymore on the cluster.\n\n@param slop\n@return"
] | [
"Creates an endpoint reference from a given adress.\n@param address\n@param props\n@return",
"Validates for non-conflicting roles",
"Returns an empty model of a Dependency in Json\n\n@return String\n@throws IOException",
"Associate a type with the given resource model.",
"Gets the value of the resourceRequestCriterion property.\n\n<p>\nThis accessor method returns a reference to the live list,\nnot a snapshot. Therefore any modification you make to the\nreturned list will be present inside the JAXB object.\nThis is why there is not a <CODE>set</CODE> method for the resourceRequestCriterion property.\n\n<p>\nFor example, to add a new item, do as follows:\n<pre>\ngetResourceRequestCriterion().add(newItem);\n</pre>\n\n\n<p>\nObjects of the following type(s) are allowed in the list\n{@link ResourceRequestType.ResourceRequestCriterion }",
"removes an Object from the cache.\n\n@param oid the Identity of the object to be removed.",
"Setting the type of Checkbox.",
"Utility function to find the first index of a value in a\nListBox.",
"Use this API to fetch statistics of cmppolicy_stats resource of given name ."
] |
protected boolean hasContentType() {
boolean result = false;
if(this.request.getHeader(RestMessageHeaders.CONTENT_TYPE) != null) {
result = true;
} else {
logger.error("Error when validating put request. Missing Content-Type header.");
RestErrorHandler.writeErrorResponse(this.messageEvent,
HttpResponseStatus.BAD_REQUEST,
"Missing Content-Type header");
}
return result;
} | [
"Retrieves and validates the content type from the REST requests\n\n@return true if has content type."
] | [
"Maps a field index to an AssignmentField instance.\n\n@param fields array of fields used as the basis for the mapping.\n@param index required field index\n@return AssignmnetField instance",
"private multi-value handlers and helpers",
"Returns iterable with all enterprise assignments of this retention policy.\n@param limit the limit of entries per response. The default value is 100.\n@param fields the fields to retrieve.\n@return an iterable containing all enterprise assignments.",
"Adds a data set to IIM file.\n\n@param ds\ndata set id (see constants in IIM class)\n@param value\ndata set value. Null values are silently ignored.\n@throws SerializationException\nif value can't be serialized by data set's serializer\n@throws InvalidDataSetException\nif data set isn't defined",
"Read an individual Phoenix task relationship.\n\n@param relation Phoenix task relationship",
"Adds a resource collection with execution hints.",
"Retuns the Windows UNC style path with backslashs intead of forward slashes.\n\n@return The UNC path.",
"Report on the filtered data in DMR .",
"Sets the file-pointer offset, measured from the beginning of this file,\nat which the next read or write occurs."
] |
private static long asciidump(InputStream is, PrintWriter pw) throws Exception
{
byte[] buffer = new byte[BUFFER_SIZE];
long byteCount = 0;
char c;
int loop;
int count;
StringBuilder sb = new StringBuilder();
while (true)
{
count = is.read(buffer);
if (count == -1)
{
break;
}
byteCount += count;
sb.setLength(0);
for (loop = 0; loop < count; loop++)
{
c = (char) buffer[loop];
if (c > 200 || c < 27)
{
c = ' ';
}
sb.append(c);
}
pw.print(sb.toString());
}
return (byteCount);
} | [
"This method dumps the entire contents of a file to an output\nprint writer as ascii data.\n\n@param is Input Stream\n@param pw Output PrintWriter\n@return number of bytes read\n@throws Exception Thrown on file read errors"
] | [
"Adds a class entry to this JAR.\n\n@param clazz the class to add to the JAR.\n@return {@code this}",
"Logs all the canidate elements so that the plugin knows which elements were the candidate\nelements.",
"Use this API to add clusternodegroup.",
"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",
"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",
"Loads all localizations not already loaded.\n@throws CmsException thrown if locking a file fails.\n@throws UnsupportedEncodingException thrown if reading a file fails.\n@throws IOException thrown if reading a file fails.",
"Entry point for the example.\n\n@param args Command-line arguments for the example. To use samplemachine.xml from resources, send\nno arguments. To use other file, send a filename without xml extension).",
"Returns a list of metadata property paths.\n@return the list of metdata property paths.",
"Triggers expansion of the parent."
] |
public WaveformDetail requestWaveformDetailFrom(final DataReference dataReference) {
ensureRunning();
for (WaveformDetail cached : detailHotCache.values()) {
if (cached.dataReference.equals(dataReference)) { // Found a hot cue hit, use it.
return cached;
}
}
return requestDetailInternal(dataReference, false);
} | [
"Ask the specified player for the specified waveform detail from the specified media slot, first checking if we\nhave a cached copy.\n\n@param dataReference uniquely identifies the desired waveform detail\n\n@return the waveform detail, if it was found, or {@code null}\n\n@throws IllegalStateException if the WaveformFinder is not running"
] | [
"Scans a single class for Swagger annotations - does not invoke ReaderListeners",
"Returns the log message id used by this checker. This is used to group it so that all attributes failing a type of rejction\nend up in the same error message. This default implementation uses the formatted log message with an empty attribute map as the id.\n\n@return the log message id",
"Check if a given string is a template path or template content\n\nIf the string contains anyone the following characters then we assume it\nis content, otherwise it is path:\n\n* space characters\n* non numeric-alphabetic characters except:\n** dot \".\"\n** dollar: \"$\"\n\n@param string\nthe string to be tested\n@return `true` if the string literal is template content or `false` otherwise",
"Use this API to delete nsip6 resources of given names.",
"Use this API to fetch a vpnglobal_intranetip_binding resources.",
"Returns the adapter position of the Parent associated with this ChildViewHolder\n\n@return The adapter position of the Parent if it still exists in the adapter.\nRecyclerView.NO_POSITION if item has been removed from the adapter,\nRecyclerView.Adapter.notifyDataSetChanged() has been called after the last\nlayout pass or the ViewHolder has already been recycled.",
"Plots the rotated trajectory, spline and support points.",
"Get the names of the paths that would apply to the request\n\n@param requestUrl URL of the request\n@param requestType Type of the request: GET, POST, PUT, or DELETE as integer\n@return JSONArray of path names\n@throws Exception",
"Check whether the URL start with one of the given prefixes.\n\n@param uri URI\n@param patterns possible prefixes\n@return true when URL starts with one of the prefixes"
] |
private void readZookeeperConfig() {
try (CuratorFramework curator = CuratorUtil.newAppCurator(config)) {
curator.start();
accumuloInstance =
new String(curator.getData().forPath(ZookeeperPath.CONFIG_ACCUMULO_INSTANCE_NAME),
StandardCharsets.UTF_8);
accumuloInstanceID =
new String(curator.getData().forPath(ZookeeperPath.CONFIG_ACCUMULO_INSTANCE_ID),
StandardCharsets.UTF_8);
fluoApplicationID =
new String(curator.getData().forPath(ZookeeperPath.CONFIG_FLUO_APPLICATION_ID),
StandardCharsets.UTF_8);
table = new String(curator.getData().forPath(ZookeeperPath.CONFIG_ACCUMULO_TABLE),
StandardCharsets.UTF_8);
observers = ObserverUtil.load(curator);
config = FluoAdminImpl.mergeZookeeperConfig(config);
// make sure not to include config passed to env, only want config from zookeeper
appConfig = config.getAppConfiguration();
} catch (Exception e) {
throw new IllegalStateException(e);
}
} | [
"Read configuration from zookeeper"
] | [
"Destroys dependent instance\n\n@param instance\n@return true if the instance was destroyed, false otherwise",
"Generate and return the list of statements to drop a database table.",
"Gets a string attribute from a json object given a path to traverse.\n\n@param record a JSONObject to traverse.\n@param path the json path to follow.\n@return the attribute as a {@link String}, or null if it was not found.",
"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",
"Get object by identity. First lookup among objects registered in the\ntransaction, then in persistent storage.\n@param id The identity\n@return The object\n@throws PersistenceBrokerException",
"Delete the given file in a separate thread\n\n@param file The file to delete",
"Adds a leaf node, which could be a task or a milestone.\n\n@param parentName parent bar name\n@param row row to add\n@param task task to populate with data from the row",
"Returns a new iterator filtering any null references.\n\n@param unfiltered\nthe unfiltered iterator. May not be <code>null</code>.\n@return an unmodifiable iterator containing all elements of the original iterator without any <code>null</code>\nreferences. Never <code>null</code>.",
"Navigate to this address in the given model node.\n\n@param model the model node\n@param create {@code true} to create the last part of the node if it does not exist\n@return the submodel\n@throws NoSuchElementException if the model contains no such element\n\n@deprecated manipulating a deep DMR node tree via PathAddress is no longer how the management layer works\ninternally, so this method has become legacy cruft. Management operation handlers\nshould obtain a {@link org.jboss.as.controller.registry.Resource Resource} from the\n{@link org.jboss.as.controller.OperationContext#readResource(PathAddress) OperationContext}\nand use the {@code Resource} API to access child resources"
] |
static List<NamedArgument> getNamedArgs( ExtensionContext context ) {
List<NamedArgument> namedArgs = new ArrayList<>();
if( context.getTestMethod().get().getParameterCount() > 0 ) {
try {
if( context.getClass().getCanonicalName().equals( METHOD_EXTENSION_CONTEXT ) ) {
Field field = context.getClass().getSuperclass().getDeclaredField( "testDescriptor" );
Object testDescriptor = ReflectionUtil.getFieldValueOrNull( field, context, ERROR );
if( testDescriptor != null
&& testDescriptor.getClass().getCanonicalName().equals( TEST_TEMPLATE_INVOCATION_TEST_DESCRIPTOR ) ) {
Object invocationContext = ReflectionUtil.getFieldValueOrNull( "invocationContext", testDescriptor, ERROR );
if( invocationContext != null
&& invocationContext.getClass().getCanonicalName().equals( PARAMETERIZED_TEST_INVOCATION_CONTEXT ) ) {
Object arguments = ReflectionUtil.getFieldValueOrNull( "arguments", invocationContext, ERROR );
List<Object> args = Arrays.asList( (Object[]) arguments );
namedArgs = ParameterNameUtil.mapArgumentsWithParameterNames( context.getTestMethod().get(), args );
}
}
}
} catch( Exception e ) {
log.warn( ERROR, e );
}
}
return namedArgs;
} | [
"This is a very ugly workaround to get the method arguments from the JUnit 5 context via reflection."
] | [
"Visit all child nodes but not this one.\n\n@param visitor The visitor to use.",
"Returns the time elapsed by the user on the app\n@return Time elapsed by user on the app in int",
"Computes the eigenvalues of a 2 by 2 matrix using a faster but more prone to errors method. This\nis the typical method.",
"Get a signature for a list of parameters using the given shared secret.\n\n@param sharedSecret\nThe shared secret\n@param params\nThe parameters\n@return The signature String",
"Use this API to fetch netbridge_vlan_binding resources of given name .",
"Sets the text alignment for all cells in the table.\n@param textAlignment new text alignment\n@throws NullPointerException if the argument was null\n@return this to allow chaining\n@throws {@link NullPointerException} if the argument was null",
"Replaces the translations in an existing container with the translations for the provided locale.\n@param locale the locale for which translations should be loaded.\n@return <code>true</code> if replacing succeeded, <code>false</code> otherwise.",
"Closes a Closeable and swallows any exceptions that might occur in the\nprocess.\n\n@param closeable",
"Return a list of photos for a user at a specific latitude, longitude and accuracy.\n\n@param location\n@param extras\n@param perPage\n@param page\n@return The collection of Photo objects\n@throws FlickrException\n@see com.flickr4java.flickr.photos.Extras"
] |
public static void doPriorityEnqueue(final Jedis jedis, final String namespace, final String queue, final String jobJson) {
jedis.sadd(JesqueUtils.createKey(namespace, QUEUES), queue);
jedis.lpush(JesqueUtils.createKey(namespace, QUEUE, queue), jobJson);
} | [
"Helper method that encapsulates the minimum logic for adding a high\npriority job to a queue.\n\n@param jedis\nthe connection to Redis\n@param namespace\nthe Resque namespace\n@param queue\nthe Resque queue name\n@param jobJson\nthe job serialized as JSON"
] | [
"Configure all UI elements in the exceptions panel.",
"Returns the names of the involved fields when post processing.\n\n@return the names of the involved fields",
"Adds a shutdown hook for the process.\n\n@param process the process to add a shutdown hook for\n\n@return the thread set as the shutdown hook\n\n@throws java.lang.SecurityException If a security manager is present and it denies {@link\njava.lang.RuntimePermission <code>RuntimePermission(\"shutdownHooks\")</code>}",
"Use this API to fetch lbvserver_auditnslogpolicy_binding resources of given name .",
"Generate random time stamps from the current time upto the next one second.\nPassed as texture coordinates to the vertex shader, an unused field is present\nwith every pair passed.\n\n@param totalTime\n@return",
"Use this API to fetch inat resource of given name .",
"convert Event bean to EventType manually.\n\n@param event the event\n@return the event type",
"process all messages in this batch, provided there is plenty of output space.",
"Performs the actual spell check query using Solr.\n\n@param request the spell check request\n\n@return Results of the Solr spell check of type SpellCheckResponse or null if something goes wrong."
] |
public static authenticationradiusaction[] get_filtered(nitro_service service, filtervalue[] filter) throws Exception{
authenticationradiusaction obj = new authenticationradiusaction();
options option = new options();
option.set_filter(filter);
authenticationradiusaction[] response = (authenticationradiusaction[]) obj.getfiltered(service, option);
return response;
} | [
"Use this API to fetch filtered set of authenticationradiusaction resources.\nset the filter parameter values in filtervalue object."
] | [
"Converts the suggestions from the Solrj format to JSON format.\n\n@param response The SpellCheckResponse object containing the spellcheck results.\n@return The spellcheck suggestions as JSON object or null if something goes wrong.",
"Gets currently visible user.\n\n@return List of user",
"Associate the batched Children with their owner object.\nLoop over owners",
"Fires the event.\n\n@param source the event source\n@param date the date\n@param isTyping true if event was caused by user pressing key that may have changed the value",
"Manipulates a string by cutting of a prefix, if present, and adding a new prefix.\n\n@param word the string to be manipulated\n@param oldPrefix the old prefix that should be replaced\n@param newPrefix the new prefix that is added\n@return the manipulated string",
"convert selector used in an upsert statement into a document",
"Sets a JSON String as a request entity.\n\n@param connnection The request of {@link HttpConnection}\n@param body The JSON String to set.",
"Resets the handler data to a basic state.",
"Trim and append a file separator to the string"
] |
public static boolean isIdentity(DMatrix a , double tol )
{
for( int i = 0; i < a.getNumRows(); i++ ) {
for( int j = 0; j < a.getNumCols(); j++ ) {
if( i == j ) {
if( Math.abs(a.get(i,j)-1.0) > tol )
return false;
} else {
if( Math.abs(a.get(i,j)) > tol )
return false;
}
}
}
return true;
} | [
"Returns true if the provided matrix is has a value of 1 along the diagonal\nelements and zero along all the other elements.\n\n@param a Matrix being inspected.\n@param tol How close to zero or one each element needs to be.\n@return If it is within tolerance to an identity matrix."
] | [
"Click handler for bottom drawer items.",
"Split input text into sentences.\n\n@param text Input text.\n@return List of Sentence objects.",
"Runs the print.\n\n@param args the cli arguments\n@throws Exception",
"Create a clone of this LevenbergMarquardt optimizer with a new vector for the\ntarget values and weights.\n\nThe clone will use the same objective function than this implementation,\ni.e., the implementation of {@link #setValues(RandomVariable[], RandomVariable[])} and\nthat of {@link #setDerivatives(RandomVariable[], RandomVariable[][])} is reused.\n\nThe initial values of the cloned optimizer will either be the original\ninitial values of this object or the best parameters obtained by this\noptimizer, the latter is used only if this optimized signals a {@link #done()}.\n\n@param newTargetVaues New list of target values.\n@param newWeights New list of weights.\n@param isUseBestParametersAsInitialParameters If true and this optimizer is done(), then the clone will use this.{@link #getBestFitParameters()} as initial parameters.\n@return A new LevenbergMarquardt optimizer, cloning this one except modified target values and weights.\n@throws CloneNotSupportedException Thrown if this optimizer cannot be cloned.",
"Checks whether a String satisfies the number range selection filter.\nThe test is evaluated based on the rightmost natural number found in\nthe String. Note that this is just evaluated on the String as given.\nIt is not trying to interpret it as a filename and to decide whether\nthe file exists, is a directory or anything like that.\n\n@param str The String to check for a number in\n@return true If the String is within the ranges filtered for",
"This method validates all relationships for a task, removing\nany which have been incorrectly read from the MPP file and\npoint to a parent task.\n\n@param task task under test",
"This method is called to format a rate.\n\n@param value rate value\n@return formatted rate",
"Replace error msg.\n\n@param origMsg\nthe orig msg\n@return the string",
"Tries to guess the packaging of the archive - whether it's an EAR, WAR, JAR.\nMaybe not needed as we can rely on the suffix?"
] |
public static String[] addStringToArray(String[] array, String str) {
if (isEmpty(array)) {
return new String[]{str};
}
String[] newArr = new String[array.length + 1];
System.arraycopy(array, 0, newArr, 0, array.length);
newArr[array.length] = str;
return newArr;
} | [
"Append the given String to the given String array, returning a new array\nconsisting of the input array contents plus the given String.\n\n@param array the array to append to (can be <code>null</code>)\n@param str the String to append\n@return the new array (never <code>null</code>)"
] | [
"Delete the proxy history for the active profile\n\n@throws Exception exception",
"Helper method to find Strings of form \"all digits\" and \"digits-comma-digits\"",
"Constructs credentials for the given account and key file.\n\n@param serviceAccountId service account ID (typically an e-mail address).\n@param privateKeyFile the file name from which to get the private key.\n@param serviceAccountScopes Collection of OAuth scopes to use with the the service\naccount flow or {@code null} if not.\n@return valid credentials or {@code null}",
"Generates the body of a toString method that uses a StringBuilder.\n\n<p>Conventionally, we join properties with comma separators. If all of the properties are\noptional, we have no choice but to track the separators at runtime, but if any of them will\nalways be present, we can actually do the hard work at compile time. Specifically, we can pick\nthe first such and output it without a comma; any property before it will have a comma\n<em>appended</em>, and any property after it will have a comma <em>prepended</em>. This gives\nus the right number of commas in the right places in all circumstances.\n\n<p>As well as keeping track of whether we are <b>prepending commas</b> yet (initially false),\nwe also keep track of whether we have just finished an if-then block for an optional property,\nor if we are in the <b>middle of an append chain</b>, and if so, whether we are in the\n<b>middle of a string literal</b>. This lets us output the fewest literals and statements,\nmuch as a mildly compulsive programmer would when writing the same code.",
"Create a new service activator for the domain server communication services.\n\n@param endpointConfig the endpoint configuration\n@param managementURI the management connection URI\n@param serverName the server name\n@param serverProcessName the server process name\n@param authKey the authentication key\n@param managementSubsystemEndpoint whether to use the mgmt subsystem endpoint or not\n@return the service activator",
"Prepare a parallel SSH Task.\n\n@return the parallel task builder",
"Calculate start dates for a monthly relative recurrence.\n\n@param calendar current date\n@param frequency frequency\n@param dates array of start dates",
"Update the background color of the mBgCircle image view.",
"This method displays the resource assignments for each task. This time\nrather than just iterating through the list of all assignments in\nthe file, we extract the assignments on a task-by-task basis.\n\n@param file MPX file"
] |
@Override
public QueryBuilderFind excludingType(final Class<? extends WindupVertexFrame> type)
{
pipelineCriteria.add(new QueryGremlinCriterion()
{
@Override
public void query(GraphRewrite event, GraphTraversal<?, Vertex> pipeline)
{
pipeline.filter(it -> !GraphTypeManager.hasType(type, it.get()));
}
});
return this;
} | [
"Excludes Vertices that are of the provided type."
] | [
"Non-blocking call\n\n@param key\n@param value\n@return",
"Retrieve the default number of minutes per year.\n\n@return minutes per year",
"Use this API to add nsacl6 resources.",
"Call the constructor for the given class, inferring the correct types for\nthe arguments. This could be confusing if there are multiple constructors\nwith the same number of arguments and the values themselves don't\ndisambiguate.\n\n@param klass The class to construct\n@param args The arguments\n@return The constructed value",
"Add a text symbolizer definition to the rule.\n\n@param styleJson The old style.",
"Use this API to fetch auditsyslogpolicy_systemglobal_binding resources of given name .",
"get the TypeArgSignature corresponding to given type\n\n@param type\n@return",
"Determines if the queue identified by the given key is used.\n\n@param jedis\nconnection to Redis\n@param key\nthe key that identifies a queue\n@return true if the key is used, false otherwise",
"Use this API to fetch aaauser_auditsyslogpolicy_binding resources of given name ."
] |
public void add(Vector3d v1) {
x += v1.x;
y += v1.y;
z += v1.z;
} | [
"Adds this vector to v1 and places the result in this vector.\n\n@param v1\nright-hand vector"
] | [
"Returns the value associated with the given key, if any.\n\n@return the value associated with the given key, or <Code>null</Code>\nif the key maps to no value",
"Utility method to retrieve the previous working date finish time, given\na date and time as a starting point.\n\n@param date date and time start point\n@return date and time of previous work finish",
"Ping route Ping the ESI routers\n\n@return ApiResponse<String>\n@throws ApiException\nIf fail to call the API, e.g. server error or cannot\ndeserialize the response body",
"When all the elements in a sorted set are inserted with the same score, in order to force lexicographical\nordering, this command returns the number of elements in the sorted set with a value in the given range.\n@param lexRange\n@return the number of elements in the specified range.",
"Create a model mbean from an object using the description given in the\nJmx annotation if present. Only operations are supported so far, no\nattributes, constructors, or notifications\n\n@param o The object to create an MBean for\n@return The ModelMBean for the given object",
"Set editable state on an attribute. This needs to also set the state on the associated attributes.\n\n@param attribute attribute for which the editable state needs to be set\n@param editable new editable state",
"Validates that we only have allowable filters.\n\n<p>Note that equality and ancestor filters are allowed, however they may result in\ninefficient sharding.",
"Return whether or not the field value passed in is the default value for the type of the field. Null will return\ntrue.",
"Constructs a camera rig with cameras attached. An owner scene object is automatically\ncreated for the camera rig.\n\nDo not try to change the owner object of the camera rig - not supported currently and will\nlead to native crashes."
] |
public static List<Map<String, Object>> listify(ObjectMapper mapper, Object source) {
return (List<Map<String, Object>>) collectify(mapper, source, List.class);
} | [
"Convert an object to a list of maps.\n\n@param mapper the object mapper\n@param source the source object\n@return list"
] | [
"Resolve the single type argument of the given generic interface against the given\ntarget method which is assumed to return the given interface or an implementation\nof it.\n@param method the target method to check the return type of\n@param genericIfc the generic interface or superclass to resolve the type argument from\n@return the resolved parameter type of the method return type, or {@code null}\nif not resolvable or if the single argument is of type {@link WildcardType}.",
"Read a task from a ConceptDraw PROJECT file.\n\n@param projectIdentifier parent project identifier\n@param map outline number to task map\n@param task ConceptDraw PROJECT task",
"Replies to this comment with another message.\n@param message the message for the reply.\n@return info about the newly created reply comment.",
"Deregister shutdown hook and execute it immediately",
"Tells you if the expression is a spread operator call\n@param expression\nexpression\n@return\ntrue if is spread expression",
"Use this API to restart dbsmonitors.",
"Reads characters into a portion of an array, then replace invalid XML characters\n\n@throws IOException If an I/O error occurs\n@see ru.yandex.qatools.allure.config.AllureNamingUtils#isBadXmlCharacter(char) by space",
"returns a unique String for given field.\nthe returned uid is unique accross all tables.",
"Create the patching task based on the definition.\n\n@param definition the task description\n@param provider the content provider\n@param context the task context\n@return the created task"
] |
public static File newFile(File baseDir, String... segments) {
File f = baseDir;
for (String segment : segments) {
f = new File(f, segment);
}
return f;
} | [
"Return a new File object based on the baseDir and the segments.\n\nThis method does not perform any operation on the file system."
] | [
"Rewrites the file passed to 'this' constructor so that the actual line numbers match the recipe passed to 'this'\nconstructor.",
"Constructs a Google APIs HTTP client with the associated credentials.",
"Move sections relative to each other in a board view. One of\n`before_section` or `after_section` is required.\n\nSections cannot be moved between projects.\n\nAt this point in time, moving sections is not supported in list views, only board views.\n\nReturns an empty data block.\n\n@param project The project in which to reorder the given section\n@return Request object",
"Get the last non-white X point\n@param img Image in memory\n@return the trimmed width",
"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",
"Non-blocking call that will throw any Exceptions in the traditional\nmanner on access\n\n@param key\n@param value\n@return",
"Sets the request body to the contents of a String.\n\n<p>If the contents of the body are large, then it may be more efficient to use an {@link InputStream} instead of\na String. Using a String requires that the entire body be in memory before sending the request.</p>\n\n@param body a String containing the contents of the body.",
"Use this API to update spilloverpolicy.",
"Specify the class represented by this `ClassNode` implements\nan interface specified by the given name\n\n@param name the name of the interface class\n@return this `ClassNode` instance"
] |
private void handleMultiInstanceEncapResponse(
SerialMessage serialMessage, int offset) {
logger.trace("Process Multi-instance Encapsulation");
int instance = serialMessage.getMessagePayloadByte(offset);
int commandClassCode = serialMessage.getMessagePayloadByte(offset + 1);
CommandClass commandClass = CommandClass.getCommandClass(commandClassCode);
if (commandClass == null) {
logger.error(String.format("Unsupported command class 0x%02x", commandClassCode));
return;
}
logger.debug(String.format("Node %d Requested Command Class = %s (0x%02x)", this.getNode().getNodeId(), commandClass.getLabel() , commandClassCode));
ZWaveCommandClass zwaveCommandClass = this.getNode().getCommandClass(commandClass);
if (zwaveCommandClass == null) {
logger.error(String.format("Unsupported command class %s (0x%02x)", commandClass.getLabel(), commandClassCode));
return;
}
logger.debug(String.format("Node %d, Instance = %d, calling handleApplicationCommandRequest.", this.getNode().getNodeId(), instance));
zwaveCommandClass.handleApplicationCommandRequest(serialMessage, offset+ 3, instance);
} | [
"Handles Multi Instance Encapsulation message. Decapsulates\nan Application Command message and handles it using the right\ninstance.\n@param serialMessage the serial message to process.\n@param offset the offset at which to start procesing."
] | [
"Obtains a Pax zoned date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Pax zoned date-time, not null\n@throws DateTimeException if unable to create the date-time",
"Adds an additional statement to the constructed document.\n\n@param statement\nthe additional statement\n@return builder object to continue construction",
"Returns status message.\n\n@param user CmsUser\n@param disabled boolean\n@param newUser boolean\n@return String",
"Create a canonical represenation of the data type value. Defaults to the value converter.\n\n@since 2.9",
"Add columns to be returned by the SELECT query. If no columns are selected then all columns are returned by\ndefault. For classes with id columns, the id column is added to the select list automagically. This can be called\nmultiple times to add more columns to select.\n\n<p>\n<b>WARNING:</b> If you specify any columns to return, then any foreign-collection fields will be returned as null\n<i>unless</i> their {@link ForeignCollectionField#columnName()} is also in the list.\n</p>",
"Function to perform backward pooling",
"Reflection API to find the method corresponding to the default implementation of a trait, given a bridge method.\n@param someMethod a method node\n@return null if it is not a method implemented in a trait. If it is, returns the method from the trait class.",
"A specific, existing section can be deleted by making a DELETE request\non the URL for that section.\n\nNote that sections must be empty to be deleted.\n\nThe last remaining section in a board view cannot be deleted.\n\nReturns an empty data block.\n\n@param section The section to delete.\n@return Request object",
"Returns a List of all of the values in the Map whose key matches an entry in the nameMapping array.\n\n@param map\nthe map\n@param nameMapping\nthe keys of the Map values to add to the List\n@return a List of all of the values in the Map whose key matches an entry in the nameMapping array\n@throws NullPointerException\nif map or nameMapping is null"
] |
private static void transposeBlock(DMatrixRBlock A , DMatrixRBlock A_tran,
int indexA , int indexC ,
int width , int height )
{
for( int i = 0; i < height; i++ ) {
int rowIndexC = indexC + i;
int rowIndexA = indexA + width*i;
int end = rowIndexA + width;
for( ; rowIndexA < end; rowIndexC += height, rowIndexA++ ) {
A_tran.data[ rowIndexC ] = A.data[ rowIndexA ];
}
}
} | [
"Transposes an individual block inside a block matrix."
] | [
"Use this API to fetch statistics of appfwpolicylabel_stats resource of given name .",
"The connection timeout for making a connection to Twitter.",
"Return a stream of resources from a response\n\n@param response the response\n@param <R> the resource type\n@param <U> the response type\n@return a stream of resources from the response",
"Tests that the area is valid geojson, the style ref is valid or null and the display is non-null.",
"Load a table configuration in from a text-file reader.\n\n@return A config if any of the fields were set otherwise null if we reach EOF.",
"Select a List of values from a Matcher using a Collection\nto identify the indices to be selected.\n\n@param self a Matcher\n@param indices a Collection of indices\n@return a String of the values at the given indices\n@since 1.6.0",
"Generate node data map.\n\n@param task\nthe job info",
"Use this API to change appfwsignatures.",
"Load in a number of database configuration entries from a buffered reader."
] |
public int[] executeBatch(PreparedStatement stmt) throws PlatformException
{
// Check for Oracle batching support
final Method methodSendBatch = (Method) m_batchStatementsInProgress.remove(stmt);
final boolean statementBatchingSupported = methodSendBatch != null;
int[] retval = null;
if (statementBatchingSupported)
{
try
{
// sendBatch() returns total row count as an Integer
methodSendBatch.invoke(stmt, null);
}
catch (Exception e)
{
throw new PlatformException(e.getLocalizedMessage(), e);
}
}
else
{
retval = super.executeBatch(stmt);
}
return retval;
} | [
"Try Oracle update batching and call sendBatch or revert to\nJDBC update batching.\n@param stmt the batched prepared statement about to be executed\n@return always <code>null</code> if Oracle update batching is used,\nsince it is impossible to dissolve total row count into distinct\nstatement counts. If JDBC update batching is used, an int array is\nreturned containing number of updated rows for each batched statement.\n@throws PlatformException upon JDBC failure"
] | [
"Converts an object into a tab delimited string with given fields\nRequires the object has public access for the specified fields\n\n@param object Object to convert\n@param delimiter delimiter\n@param fieldNames fieldnames\n@return String representing object",
"Returns the number of vertex indices for a single face.\n\n@param face the face\n@return the number of indices",
"Create a model controller client which is exclusively receiving messages on an existing channel.\n\n@param channel the channel\n@param executorService an executor\n@return the created client",
"Builds IMAP envelope String from pre-parsed data.",
"Remove the sequence for given sequence name.\n\n@param sequenceName Name of the sequence to remove.",
"Pretty print a progress update after each batch complete.\n\n@param batchCount current batch\n@param numBatches total number of batches\n@param partitionStoreCount partition stores migrated\n@param numPartitionStores total number of partition stores to migrate\n@param totalTimeMs total time, in milliseconds, of execution thus far.",
"Adds the value to the Collection mapped to by the key.",
"Called just before the thread finishes, regardless of status, to take any necessary action on\nthe downloaded file with mDownloadedCacheSize file.\n\n@param forceClean - It will delete downloaded cache, Even streaming is enabled, If user intentionally cancelled.",
"Release the broker instance."
] |
public void build(Set<Bean<?>> beans) {
if (isBuilt()) {
throw new IllegalStateException("BeanIdentifier index is already built!");
}
if (beans.isEmpty()) {
index = new BeanIdentifier[0];
reverseIndex = Collections.emptyMap();
indexHash = 0;
indexBuilt.set(true);
return;
}
List<BeanIdentifier> tempIndex = new ArrayList<BeanIdentifier>(beans.size());
for (Bean<?> bean : beans) {
if (bean instanceof CommonBean<?>) {
tempIndex.add(((CommonBean<?>) bean).getIdentifier());
} else if (bean instanceof PassivationCapable) {
tempIndex.add(new StringBeanIdentifier(((PassivationCapable) bean).getId()));
}
}
Collections.sort(tempIndex, new Comparator<BeanIdentifier>() {
@Override
public int compare(BeanIdentifier o1, BeanIdentifier o2) {
return o1.asString().compareTo(o2.asString());
}
});
index = tempIndex.toArray(new BeanIdentifier[tempIndex.size()]);
ImmutableMap.Builder<BeanIdentifier, Integer> builder = ImmutableMap.builder();
for (int i = 0; i < index.length; i++) {
builder.put(index[i], i);
}
reverseIndex = builder.build();
indexHash = Arrays.hashCode(index);
if(BootstrapLogger.LOG.isDebugEnabled()) {
BootstrapLogger.LOG.beanIdentifierIndexBuilt(getDebugInfo());
}
indexBuilt.set(true);
} | [
"Note that the index can only be built once.\n\n@param beans The set of beans the index should be built from, only instances of {@link CommonBean} and implementations of {@link PassivationCapable} are\nincluded\n@throws IllegalStateException If the index is built already"
] | [
"Return total number of connections created in all partitions.\n\n@return number of created connections",
"Use this API to update autoscaleaction resources.",
"Processes the template for all reference definitions of the current class definition.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\[email protected] type=\"block\"",
"Create a style from a list of rules.\n\n@param styleRules the rules",
"Create an `AppDescriptor` with appName and entry class specified.\n\nIf `appName` is `null` or blank, it will try the following\napproach to get app name:\n\n1. check the {@link Version#getArtifactId() artifact id} and use it unless\n2. if artifact id is null or empty, then infer app name using {@link AppNameInferer}\n\n@param appName\nthe app name\n@param entryClass\nthe entry class\n@return\nan `AppDescriptor` instance",
"Patch provided by Avril Kotzen ([email protected])\nDB2 handles TINYINT (for mapping a byte).",
"Add the value to list of values to be used as part of the\nevaluation of this indicator.\n\n@param index position in the list\n@param value evaluation value",
"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.",
"TestNG returns a compound thread ID that includes the thread name and its numeric ID,\nseparated by an 'at' sign. We only want to use the thread name as the ID is mostly\nunimportant and it takes up too much space in the generated report.\n@param threadId The compound thread ID.\n@return The thread name."
] |
public Value get(Object key) {
/* If the length is under and we are asking for the key, then just look for the key. Don't build the map. */
if (map == null && items.length < 20) {
for (Object item : items) {
MapItemValue miv = (MapItemValue) item;
if (key.equals(miv.name.toValue())) {
return miv.value;
}
}
return null;
} else {
if (map == null) buildIfNeededMap();
return map.get(key);
}
} | [
"Get the items for the key.\n\n@param key\n@return the items for the given key"
] | [
"This method converts a node to text.\n\nLeading and trailing text from hidden tokens (whitespace/comments) is removed. Text from hidden tokens that is\nsurrounded by text from non-hidden tokens is summarized to a single whitespace.\n\nThe preferred use case of this method is to convert the {@link ICompositeNode} that has been created for a data\ntype rule to text.\n\nThis is also the recommended way to convert a node to text if you want to invoke\n{@link org.eclipse.xtext.conversion.IValueConverterService#toValue(String, String, INode)}",
"This method maps the encoded height of a Gantt bar to\nthe height in pixels.\n\n@param height encoded height\n@return height in pixels",
"Sets the specified double 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",
"Retrieves the parent task for a Phoenix activity.\n\n@param activity Phoenix activity\n@return parent task",
"Determines run length for each 'initial' partition ID. Note that a\ncontiguous run may \"wrap around\" the end of the ring.\n\n@param cluster\n@param zoneId\n@return map of initial partition Id to length of contiguous run of\npartition IDs within the same zone..",
"Handle a \"current till end\" change event.\n@param event the change event.",
"Print a resource type.\n\n@param value ResourceType instance\n@return resource type value",
"Get the element as a boolean.\n\n@param i the index of the element to access",
"Given the current and final cluster dumps it into the output directory\n\n@param currentCluster Initial cluster metadata\n@param finalCluster Final cluster metadata\n@param outputDirName Output directory where to dump this file\n@throws IOException"
] |
public List<EnabledEndpoint> getEnabledEndpoints(int pathId, String clientUUID, String[] filters) throws Exception {
ArrayList<EnabledEndpoint> enabledOverrides = new ArrayList<EnabledEndpoint>();
PreparedStatement query = null;
ResultSet results = null;
try (Connection sqlConnection = sqlService.getConnection()) {
query = sqlConnection.prepareStatement(
"SELECT * FROM " + Constants.DB_TABLE_ENABLED_OVERRIDE +
" WHERE " + Constants.ENABLED_OVERRIDES_PATH_ID + "=?" +
" AND " + Constants.GENERIC_CLIENT_UUID + "=?" +
" ORDER BY " + Constants.ENABLED_OVERRIDES_PRIORITY
);
query.setInt(1, pathId);
query.setString(2, clientUUID);
results = query.executeQuery();
while (results.next()) {
EnabledEndpoint endpoint = this.getPartialEnabledEndpointFromResultset(results);
com.groupon.odo.proxylib.models.Method m = PathOverrideService.getInstance().getMethodForOverrideId(endpoint.getOverrideId());
// this is an errant entry.. perhaps a method got deleted from a plugin
// we'll also remove it from the endpoint
if (m == null) {
PathOverrideService.getInstance().removeOverride(endpoint.getOverrideId());
continue;
}
// check filters and see if any match
boolean addOverride = false;
if (filters != null) {
for (String filter : filters) {
if (m.getMethodType().endsWith(filter)) {
addOverride = true;
break;
}
}
} else {
// if there are no filters then we assume that the requester wants all enabled overrides
addOverride = true;
}
if (addOverride) {
enabledOverrides.add(endpoint);
}
}
} catch (Exception e) {
e.printStackTrace();
} finally {
try {
if (results != null) {
results.close();
}
} catch (Exception e) {
}
try {
if (query != null) {
query.close();
}
} catch (Exception e) {
}
}
// now go through the ArrayList and get the method for all of the endpoints
// have to do this so we don't have overlapping SQL queries
ArrayList<EnabledEndpoint> enabledOverridesWithMethods = new ArrayList<EnabledEndpoint>();
for (EnabledEndpoint endpoint : enabledOverrides) {
if (endpoint.getOverrideId() >= 0) {
com.groupon.odo.proxylib.models.Method m = PathOverrideService.getInstance().getMethodForOverrideId(endpoint.getOverrideId());
endpoint.setMethodInformation(m);
}
enabledOverridesWithMethods.add(endpoint);
}
return enabledOverridesWithMethods;
} | [
"Returns an array of the enabled endpoints as Integer IDs\n\n@param pathId ID of path\n@param clientUUID UUID of client\n@param filters If supplied, only endpoints ending with values in filters are returned\n@return Collection of endpoints\n@throws Exception exception"
] | [
"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",
"Adds OPT_U | OPT_URL option to OptionParser, with one argument.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional",
"Convert the holiday format from EquivalenceClassTransformer into a date format\n\n@param holiday the date\n@return a date String in the format yyyy-MM-dd",
"Enable or disable this component.\n@param flag true to enable, false to disable.\n@see #enable()\n@see #disable()\n@see #isEnabled()",
"Releases a database connection, and cleans up any resources\nassociated with that connection.",
"Removes the given object from the cache\n\n@param oid oid of the object to remove",
"Finishes the current box - empties the text line buffer and creates a DOM element from it.",
"Sets the node meta data.\n\n@param key - the meta data key\n@param value - the meta data value\n@throws GroovyBugError if key is null or there is already meta\ndata under that key",
"Converts the provided object to a date, if possible.\n\n@param date the date.\n\n@return the date as {@link java.util.Date}"
] |
public void racRent() {
pos = pos - 1;
String userName = CarSearch.getLastSearchParams()[0];
String pickupDate = CarSearch.getLastSearchParams()[1];
String returnDate = CarSearch.getLastSearchParams()[2];
this.searcher.search(userName, pickupDate, returnDate);
if (searcher!=null && searcher.getCars()!= null && pos < searcher.getCars().size() && searcher.getCars().get(pos) != null) {
RESStatusType resStatus = reserver.reserveCar(searcher.getCustomer()
, searcher.getCars().get(pos)
, pickupDate
, returnDate);
ConfirmationType confirm = reserver.getConfirmation(resStatus
, searcher.getCustomer()
, searcher.getCars().get(pos)
, pickupDate
, returnDate);
RESCarType car = confirm.getCar();
CustomerDetailsType customer = confirm.getCustomer();
System.out.println(MessageFormat.format(CONFIRMATION
, confirm.getDescription()
, confirm.getReservationId()
, customer.getName()
, customer.getEmail()
, customer.getCity()
, customer.getStatus()
, car.getBrand()
, car.getDesignModel()
, confirm.getFromDate()
, confirm.getToDate()
, padl(car.getRateDay(), 10)
, padl(car.getRateWeekend(), 10)
, padl(confirm.getCreditPoints().toString(), 7)));
} else {
System.out.println("Invalid selection: " + (pos+1)); //$NON-NLS-1$
}
} | [
"Rent a car available in the last serach result\n@param intp - the command interpreter instance"
] | [
"Get cached value that is dynamically loaded by the Acacia content editor.\n\n@param attribute the attribute to load the value to\n@return the cached value",
"Sets the color of the drop shadow.\n\n@param color The color of the drop shadow.",
">>>>>> measureUntilFull helper methods",
"Mbeans for SLOP_UPDATE",
"Return a list of place IDs for a query string.\n\nThe flickr.places.find method is not a geocoder. It will round \"up\" to the nearest place type to which place IDs apply. For example, if you pass it a\nstreet level address it will return the city that contains the address rather than the street, or building, itself.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@param query\n@return PlacesList\n@throws FlickrException",
"Use this API to fetch dnssuffix resources of given names .",
"Use this API to fetch tmtrafficpolicy_tmglobal_binding resources of given name .",
"Creates SLD rules for each old style.",
"Returns all scripts\n\n@param model\n@param type - optional to specify type of script to return\n@return\n@throws Exception"
] |
@Override
protected void denyImportDeclaration(ImportDeclaration importDeclaration) {
LOG.debug("CXFImporter destroy a proxy for " + importDeclaration);
ServiceRegistration serviceRegistration = map.get(importDeclaration);
serviceRegistration.unregister();
// set the importDeclaration has unhandled
super.unhandleImportDeclaration(importDeclaration);
map.remove(importDeclaration);
} | [
"Destroy the proxy & update the map containing the registration ref.\n\n@param importDeclaration"
] | [
"Given a json node, find a nested node using given composed key.\n\n@param jsonNode the parent json node\n@param composedKey a key combines multiple keys using flattening dots.\nFlattening dots are dot character '.' those are not preceded by slash '\\'\nEach flattening dot represents a level with following key as field key in that level\n@return nested json node located using given composed key",
"Return the most appropriate log type. This should _never_ return null.",
"Visit an open package of the current module.\n\n@param packaze the qualified name of the opened package.\n@param access the access flag of the opened package,\nvalid values are among {@code ACC_SYNTHETIC} and\n{@code ACC_MANDATED}.\n@param modules the qualified names of the modules that can use deep\nreflection to the classes of the open package or\n<tt>null</tt>.",
"Start pushing the element off to the right.",
"Run a query on the datastore.\n\n@return The entities returned by the query.\n@throws DatastoreException on error",
"Releases a database connection, and cleans up any resources\nassociated with that connection.",
"Enables or disables auto closing when selecting a date.",
"Scales the weights of this crfclassifier by the specified weight\n\n@param scale",
"Retrieves a CodePage instance. Defaults to ANSI.\n\n@param field the index number of the field to be retrieved\n@return the value of the required field"
] |
public RuleEnvelope getRule(String ruleId) throws ApiException {
ApiResponse<RuleEnvelope> resp = getRuleWithHttpInfo(ruleId);
return resp.getData();
} | [
"Get Rule\nGet a rule using the Rule ID\n@param ruleId Rule ID. (required)\n@return RuleEnvelope\n@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body"
] | [
"Update the value of an embedded node property.\n\n@param executionEngine the {@link GraphDatabaseService} used to run the query\n@param keyValues the columns representing the identifier in the entity owning the embedded\n@param embeddedColumn the column on the embedded node (dot-separated properties)\n@param value the new value for the property",
"Set RGB output range.\n\n@param outRGB Range.",
"Create a host target.\n\n@param hostName the host name\n@param client the connected controller client to the master host.\n@return the remote target",
"Writes the results of the processing to a file.",
"Returns the property value read from the given JavaBean.\n\n@param bean the JavaBean to read the property from\n@param property the property to read\n\n@return the property value read from the given JavaBean",
"Creates the graphic element to be shown when the datasource is empty",
"Generate a weighted score based on position for matches of URI parts.\nThe matches are weighted in descending order from left to right.\nExact match is weighted higher than group match, and group match is weighted higher than wildcard match.\n\n@param requestUriParts the parts of request URI\n@param destUriParts the parts of destination URI\n@return weighted score",
"Extract calendar data.",
"Return true only if the node has the named annotation\n@param node - the AST Node to check\n@param name - the name of the annotation\n@return true only if the node has the named annotation"
] |
public void loadClassifier(InputStream in, Properties props) throws IOException, ClassCastException,
ClassNotFoundException {
loadClassifier(new ObjectInputStream(in), props);
} | [
"Load a classifier from the specified InputStream. The classifier is\nreinitialized from the flags serialized in the classifier. This does not\nclose the InputStream.\n\n@param in\nThe InputStream to load the serialized classifier from\n@param props\nThis Properties object will be used to update the\nSeqClassifierFlags which are read from the serialized classifier\n\n@throws IOException\nIf there are problems accessing the input stream\n@throws ClassCastException\nIf there are problems interpreting the serialized data\n@throws ClassNotFoundException\nIf there are problems interpreting the serialized data"
] | [
"Set new list data set\n@param list new data set",
"Asynchronous call that begins execution of the task\nand returns immediately.",
"Append the path to the StringBuilder.\n\n@param result the string builder to add the path to.",
"Configures the log context.\n\n@param configFile the configuration file\n@param classLoader the class loader to use for the configuration\n@param logContext the log context to configure\n\n@return {@code true} if the log context was successfully configured, otherwise {@code false}\n\n@throws DeploymentUnitProcessingException if the configuration fails",
"Use this API to add sslaction.",
"Determine the current state the server is in.\n\n@return the server status",
"Checks the preconditions for creating a new StrRegExReplace processor.\n\n@param regex\nthe supplied regular expression\n@param replacement\nthe supplied replacement text\n@throws IllegalArgumentException\nif regex is empty\n@throws NullPointerException\nif regex or replacement is null",
"Returns all the dependencies of a module\n\n@param module Module\n@return List<Dependency>",
"Retrieve a calendar exception which applies to this date.\n\n@param date target date\n@return calendar exception, or null if none match this date"
] |
public void pushDryRun() throws Exception {
if (releaseAction.isCreateVcsTag()) {
if (scmManager.isTagExists(scmManager.getRemoteConfig(releaseAction.getTargetRemoteName()), releaseAction.getTagUrl())) {
throw new Exception(String.format("Tag with name '%s' already exists", releaseAction.getTagUrl()));
}
}
String testTagName = releaseAction.getTagUrl() + "_test";
try {
scmManager.testPush(scmManager.getRemoteConfig(releaseAction.getTargetRemoteName()), testTagName);
} catch (Exception e) {
throw new Exception(String.format("Failed while attempting push dry-run: %s", e.getMessage()), e);
} finally {
if (scmManager.isTagExists(scmManager.getRemoteConfig(releaseAction.getTargetRemoteName()), testTagName)) {
scmManager.deleteLocalTag(testTagName);
}
}
} | [
"This method uses the configured git credentials and repo, to test its validity.\nIn addition, in case the user requested creation of a new tag, it checks that\nanother tag with the same name doesn't exist"
] | [
"In managed environment do internal close the used connection",
"This method writes task data to a JSON file.\nNote that we write the task hierarchy in order to make rebuilding the hierarchy easier.",
"Send JSON representation of given data object to all connections tagged with all give tag labels\n@param data the data object\n@param labels the tag labels",
"Reads all text up to next XML tag and returns it as a String.\n\n@return the String of the text read, which may be empty.",
"Triggers expansion of the parent.",
"Use this API to restore appfwprofile resources.",
"Fixed length fancy formatting for doubles. If possible decimal notation is used. If all the significant digits\ncan't be shown then it will switch to exponential notation. If not all the space is needed then it will\nbe filled in to ensure it has the specified length.\n\n@param value value being formatted\n@param format default format before exponential\n@param length Maximum number of characters it can take.\n@param significant Number of significant decimal digits to show at a minimum.\n@return formatted string",
"Copy one Gradient into another.\n@param g the Gradient to copy into",
"Creates a Resque backtrace from a Throwable's stack trace. Includes\ncauses.\n\n@param t\nthe Exception to use\n@return a list of strings that represent how the exception's stacktrace\nappears."
] |
public static String getDumpFileDirectoryName(
DumpContentType dumpContentType, String dateStamp) {
return dumpContentType.toString().toLowerCase() + "-" + dateStamp;
} | [
"Returns the name of the directory where the dumpfile of the given type\nand date should be stored.\n\n@param dumpContentType\nthe type of the dump\n@param dateStamp\nthe date of the dump in format YYYYMMDD\n@return the local directory name for the dumpfile"
] | [
"Determines the constraints relating to a task.\n\n@param row row data\n@param task Task instance",
"Set the payload to the fileModel of the given instance even though the variable is not directly of it's type. This is mainly to simplify the\ncreation of the rule, when the FileModel itself is not being iterated but just a model referencing it.",
"Use this API to fetch dospolicy resource of given name .",
"Adds all pairs from 'fromMap' to 'toMap' excluding once that matching the pattern",
"Send message to socket's output stream.\n\n@param messageToSend message to send.\n\n@return {@code true} if message was sent successfully, {@code false} otherwise.",
"Interfaces, enums, annotations, and abstract classes cannot be\ninstantiated.\n\n@param actionClass\nclass to check\n@return returns true if the class cannot be instantiated or should be\nignored",
"Get a property as a json array or default.\n\n@param key the property name\n@param defaultValue default",
"Try to obtain the value that is cached for the given key in the given resource.\nIf no value is cached, the provider is used to compute it and store it afterwards.\n@param resource the resource. If it is <code>null</code>, the provider will be used to compute the value.\n@param key the cache key. May not be <code>null</code>.\n@param provider the strategy to compute the value if necessary. May not be <code>null</code>.",
"Returns the number of consecutive trailing one or zero bits.\nIf network is true, returns the number of consecutive trailing zero bits.\nOtherwise, returns the number of consecutive trailing one bits.\n\n@param network\n@return"
] |
public Object getProperty(Object object) {
return java.lang.reflect.Array.getLength(object);
} | [
"Get this property from the given object.\n@param object an array\n@return the length of the array object\n@throws IllegalArgumentException if object is not an array"
] | [
"Generates a HashMap used to store expanded state for items in the list\non configuration change or whenever onResume is called.\n\n@return A HashMap containing the expanded state of all parents",
"Start the chain of execution running.\n\n@throws IllegalStateException\nif the chain of execution has already been started.",
"Add some of the release build properties to a map.",
"The specified interface must not contain methods, that changes the state of this object itself.\n\n@param code\nsource code of an interface which describes how to generate the <i>immutable</i>\n@param settings\nsettings to generate code\n@return generated source code as string in a result wrapper",
"page breaks should be near the bottom of the band, this method used while adding subreports\nwhich has the \"start on new page\" option.\n@param band",
"Add roles for given role parent item.\n\n@param ouItem group parent item",
"Get the bar size.\n\n@param settings Parameters for rendering the scalebar.",
"Method to service public recording APIs\n\n@param op Operation being tracked\n@param timeNS Duration of operation\n@param numEmptyResponses Number of empty responses being sent back,\ni.e.: requested keys for which there were no values (GET and GET_ALL only)\n@param valueSize Size in bytes of the value\n@param keySize Size in bytes of the key\n@param getAllAggregateRequests Total of amount of keys requested in the operation (GET_ALL only)",
"Register the DAO with the cache. This will allow folks to build a DAO externally and then register so it can be\nused internally as necessary.\n\n<p>\n<b>NOTE:</b> By default this registers the DAO to be associated with the class that it uses. If you need to\nregister multiple dao's that use different {@link DatabaseTableConfig}s then you should use\n{@link #registerDaoWithTableConfig(ConnectionSource, Dao)}.\n</p>\n\n<p>\n<b>NOTE:</b> You should maybe use the {@link DatabaseTable#daoClass()} and have the DaoManager construct the DAO\nif possible.\n</p>"
] |
private Task readTask(ChildTaskContainer parent, Integer id)
{
Table a0 = getTable("A0TAB");
Table a1 = getTable("A1TAB");
Table a2 = getTable("A2TAB");
Table a3 = getTable("A3TAB");
Table a4 = getTable("A4TAB");
Task task = parent.addTask();
MapRow a1Row = a1.find(id);
MapRow a2Row = a2.find(id);
setFields(A0TAB_FIELDS, a0.find(id), task);
setFields(A1TAB_FIELDS, a1Row, task);
setFields(A2TAB_FIELDS, a2Row, task);
setFields(A3TAB_FIELDS, a3.find(id), task);
setFields(A5TAB_FIELDS, a4.find(id), task);
task.setStart(task.getEarlyStart());
task.setFinish(task.getEarlyFinish());
if (task.getName() == null)
{
task.setName(task.getText(1));
}
m_eventManager.fireTaskReadEvent(task);
return task;
} | [
"Read data for an individual task from the tables in a PEP file.\n\n@param parent parent task\n@param id task ID\n@return task instance"
] | [
"Get a collection of tags used by the specified user.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@param userId\nThe User ID\n@return The User object\n@throws FlickrException",
"Auto re-initialize external resourced\nif resources have been already released.",
"Returns true if the given method has a possibly matching instance method with the given name and arguments.\n\n@param name the name of the method of interest\n@param arguments the arguments to match against\n@return true if a matching method was found",
"calculate arc angle between point a and point b\n\n@param center\n@param a\n@param b\n@param area\n@param radius\n@return",
"Create a document that parses the tile's labelFragment, using GraphicsWriter classes.\n\n@param writer\nwriter\n@param labelStyleInfo\nlabel style info\n@return graphics document\n@throws RenderException\ncannot render",
"calculate and set position to menu items",
"Checks to see if either the diagonal element or off diagonal element is zero. If one is\nthen it performs a split or pushes it off the matrix.\n\n@return True if there was a zero.",
"Converts url path to the Transloadit full url.\nReturns the url passed if it is already full.\n\n@param url\n@return String",
"Returns an array of all endpoints\n\n@param profileId ID of profile\n@param clientUUID UUID of client\n@param filters filters to apply to endpoints\n@return Collection of endpoints\n@throws Exception exception"
] |
@Nullable
public ByteIterable get(@NotNull final Transaction txn, @NotNull final ByteIterable first) {
return this.first.get(txn, first);
} | [
"Search for the first entry in the first database. Use this method for databases configured with no duplicates.\n\n@param txn enclosing transaction\n@param first first key.\n@return null if no entry found, otherwise the value."
] | [
"Encodes the given URI path with the given encoding.\n@param path the path to be encoded\n@param encoding the character encoding to encode to\n@return the encoded path\n@throws UnsupportedEncodingException when the given encoding parameter is not supported",
"Finds the last entry of the address list and returns it as a property.\n\n@param address the address to get the last part of\n\n@return the last part of the address\n\n@throws IllegalArgumentException if the address is not of type {@link ModelType#LIST} or is empty",
"Extracts baseline cost from the MPP file for a specific baseline.\nReturns null if no baseline cost is present, otherwise returns\na list of timephased work items.\n\n@param calendar baseline calendar\n@param normaliser normaliser associated with this data\n@param data timephased baseline work data block\n@param raw flag indicating if this data is to be treated as raw\n@return timephased work",
"Returns all found resolvers\n@return",
"Get the FieldDescriptors of the extent based on the FieldDescriptors of the parent.",
"Checks whether the folder exists for fileName, and creates it if necessary.\n\n@param fileName folder name.\n@throws IOException an IO exception.",
"Adds a rule row to the table with a given style.\n@param style the rule style, must not be null nor {@link TableRowStyle#UNKNOWN}\n@throws {@link NullPointerException} if style was null\n@throws {@link IllegalArgumentException} if style was {@link TableRowStyle#UNKNOWN}",
"Use this API to update responderpolicy resources.",
"Adds a rule row to the table with a given style.\n@param style the rule style, must not be null nor {@link TableRowStyle#UNKNOWN}\n@throws {@link NullPointerException} if style was null\n@throws {@link IllegalArgumentException} if style was {@link TableRowStyle#UNKNOWN}"
] |
protected Object getObjectFromResultSet() throws PersistenceBrokerException
{
try
{
// if all primitive attributes of the object are contained in the ResultSet
// the fast direct mapping can be used
return super.getObjectFromResultSet();
}
// if the full loading failed we assume that at least PK attributes are contained
// in the ResultSet and perform a slower Identity based loading...
// This may of course also fail and can throw another PersistenceBrokerException
catch (PersistenceBrokerException e)
{
Identity oid = getIdentityFromResultSet();
return getBroker().getObjectByIdentity(oid);
}
} | [
"returns a proxy or a fully materialized Object from the current row of the\nunderlying resultset."
] | [
"Returns the body of the request. This method is used to read posted JSON data.\n\n@param request The request.\n\n@return String representation of the request's body.\n\n@throws IOException in case reading the request fails",
"Returns the screen height in pixels\n\n@param context is the context to get the resources\n@return the screen height in pixels",
"If needed, destroy the remaining conversation contexts after an HTTP session was invalidated within the current request.\n\n@param request",
"Retrieves list of inbox messages based on given userId\n@param userId String userid\n@return ArrayList of {@link CTMessageDAO}",
"Processes a runtime procedure argument tag.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException If an error occurs\[email protected] type=\"content\"\[email protected] name=\"attributes\" optional=\"true\" description=\"Attributes of the procedure as name-value pairs 'name=value',\nseparated by commas\"\[email protected] name=\"documentation\" optional=\"true\" description=\"Documentation on the procedure\"\[email protected] name=\"field-ref\" optional=\"true\" description=\"Identifies the field that provides the value\nif a runtime argument; if not set, then null is used\"\[email protected] name=\"name\" optional=\"false\" description=\"The identifier of the argument tag\"\[email protected] name=\"return\" optional=\"true\" description=\"Whether this is a return value (if a runtime argument)\"\nvalues=\"true,false\"\[email protected] name=\"value\" optional=\"false\" description=\"The value if a constant argument\"",
"Copy one Gradient into another.\n@param g the Gradient to copy into",
"Return a list of unique values for a namespace and predicate.\n\nThis method does not require authentication.\n\n@param namespace\nThe namespace that all values should be restricted to.\n@param predicate\nThe predicate that all values should be restricted to.\n@param perPage\nThe number of photos to show per page\n@param page\nThe page offset\n@return NamespacesList\n@throws FlickrException",
"Set the model used by the left table.\n\n@param model table model",
"Set the model used by the left table.\n\n@param model table model"
] |
public static Pool<Jedis> createJedisPool(final Config jesqueConfig, final GenericObjectPoolConfig poolConfig) {
if (jesqueConfig == null) {
throw new IllegalArgumentException("jesqueConfig must not be null");
}
if (poolConfig == null) {
throw new IllegalArgumentException("poolConfig must not be null");
}
if (jesqueConfig.getMasterName() != null && !"".equals(jesqueConfig.getMasterName())
&& jesqueConfig.getSentinels() != null && jesqueConfig.getSentinels().size() > 0) {
return new JedisSentinelPool(jesqueConfig.getMasterName(), jesqueConfig.getSentinels(), poolConfig,
jesqueConfig.getTimeout(), jesqueConfig.getPassword(), jesqueConfig.getDatabase());
} else {
return new JedisPool(poolConfig, jesqueConfig.getHost(), jesqueConfig.getPort(),
jesqueConfig.getTimeout(), jesqueConfig.getPassword(), jesqueConfig.getDatabase());
}
} | [
"A simple helper method that creates a pool of connections to Redis using\nthe supplied configurations.\n\n@param jesqueConfig the config used to create the pooled Jedis connections\n@param poolConfig the config used to create the pool\n@return a configured Pool of Jedis connections"
] | [
"Use this API to fetch all the ipv6 resources that are configured on netscaler.",
"Creates the string mappings.\n\n@param mtasTokenIdFactory\nthe mtas token id factory\n@param level\nthe level\n@param stringValue\nthe string value\n@param offsetStart\nthe offset start\n@param offsetEnd\nthe offset end\n@param position\nthe position\n@throws IOException\nSignals that an I/O exception has occurred.",
"Transforms user name and icon size into the rfs image path.\n\n@param name the user name\n@param size IconSize to get icon for\n\n@return the path",
"Get the collection of configured blogs for the calling user.\n\n@return The Collection of configured blogs",
"When all the elements in a sorted set are inserted with the same score, in order to force lexicographical\nordering, this command returns the number of elements in the sorted set with a value in the given range.\n@param lexRange\n@return the number of elements in the specified range.",
"Parse request parameters and files.\n@param request\n@param response",
"Populates currency settings.\n\n@param record MPX record\n@param properties project properties",
"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",
"Use this API to fetch dnssuffix resources of given names ."
] |
public ParallelTaskBuilder preparePing() {
reinitIfClosed();
ParallelTaskBuilder cb = new ParallelTaskBuilder();
cb.setProtocol(RequestProtocol.PING);
return cb;
} | [
"Prepare a parallel PING Task.\n\n@return the parallel task builder"
] | [
"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.",
"This method works as the one above, adding some properties to the message\n\n@param agent_name\nThe id of the agents that receive the message\n@param msgtype\n@param message_content\nThe content of the message\n@param properties\nto be added to the message\n@param connector\nThe connector to get the external access",
"Execute all recorded tasks.\n\n@param context the patch context\n@param callback the finalization callback\n@throws Exception",
"Rollback the last applied patch.\n\n@param contentPolicy the content policy\n@param resetConfiguration whether to reset the configuration\n@param modification the installation modification\n@return the patching result\n@throws PatchingException",
"Expands all tabs into spaces. Assumes the CharSequence represents a single line of text.\n\n@param self A line to expand\n@param tabStop The number of spaces a tab represents\n@return The expanded toString() of this CharSequence\n@see #expandLine(String, int)\n@since 1.8.2",
"Returns the matrix's rank. Automatic selection of threshold\n\n@param A Matrix. Not modified.\n@return The rank of the decomposed matrix.",
"Called to update the cached formats when something changes.",
"Performs a get all operation with the specified composite request object\n\n@param requestWrapper Composite request object containing a reference to\nthe Iterable keys\n\n@return Map of the keys to the corresponding versioned values",
"Gets an entry point for the given deployment. If one does not exist it will be created. If the request controller is disabled\nthis will return null.\n\nEntry points are reference counted. If this method is called n times then {@link #removeControlPoint(ControlPoint)}\nmust also be called n times to clean up the entry points.\n\n@param deploymentName The top level deployment name\n@param entryPointName The entry point name\n@return The entry point, or null if the request controller is disabled"
] |
public static String readCorrelationId(Message message) {
if (!(message instanceof SoapMessage)) {
return null;
}
String correlationId = null;
Header hdCorrelationId = ((SoapMessage) message).getHeader(CORRELATION_ID_QNAME);
if (hdCorrelationId != null) {
if (hdCorrelationId.getObject() instanceof String) {
correlationId = (String) hdCorrelationId.getObject();
} else if (hdCorrelationId.getObject() instanceof Node) {
Node headerNode = (Node) hdCorrelationId.getObject();
correlationId = headerNode.getTextContent();
} else {
LOG.warning("Found CorrelationId soap header but value is not a String or a Node! Value: "
+ hdCorrelationId.getObject().toString());
}
}
return correlationId;
} | [
"Read correlation id.\n\n@param message the message\n@return correlation id from the message"
] | [
"Use this API to update autoscaleprofile.",
"these are the iterators used by MACAddress",
"Stores an new entry in the cache.",
"Gets the argument names of a method call. If the arguments are not VariableExpressions then a null\nwill be returned.\n@param methodCall\nthe method call to search\n@return\na list of strings, never null, but some elements may be null",
"Adds a string reference, a class reference, a method type, a module\nor a package to the constant pool of the class being build.\nDoes nothing if the constant pool already contains a similar item.\n\n@param type\na type among STR, CLASS, MTYPE, MODULE or PACKAGE\n@param value\nstring value of the reference.\n@return a new or already existing reference item.",
"Method to initialize the list.\n\n@param resList a given instance or null\n@return an instance",
"This method tokenizes a string by space characters,\nbut ignores spaces in quoted parts,that are parts in\n'' or \"\". The method does allows the usage of \"\" in ''\nand '' in \"\". The space character between tokens is not\nreturned.\n\n@param s the string to tokenize\n@return the tokens",
"Returns the current version info for a provided remote document.\n@param remoteDocument the remote BSON document from which to extract version info\n@return a DocumentVersionInfo",
"Parses the input stream to read the header\n\n@param input data input to read from\n@return the parsed protocol header\n@throws IOException"
] |
private ProjectFile readProjectFile(ProjectReader reader, File file) throws MPXJException
{
addListeners(reader);
return reader.read(file);
} | [
"Adds listeners and reads from a file.\n\n@param reader reader for file type\n@param file schedule data\n@return ProjectFile instance"
] | [
"Serializes Number value and writes it into specified buffer.",
"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.",
"Returns the configured mappings of the current field.\n\n@return the configured mappings of the current field",
"Use this API to unset the properties of ntpserver resource.\nProperties that need to be unset are specified in args array.",
"Drop down selected view\n\n@param position position of selected item\n@param convertView View of selected item\n@param parent parent of selected view\n@return convertView",
"Gets a JsonObject containing any pending changes to this object that can be sent back to the Box API.\n@return a JsonObject containing the pending changes.",
"Add a shutdown listener, which gets called when all requests completed on shutdown.\n\n@param listener the shutdown listener",
"Add \"GROUP BY\" clause to the SQL query statement. This can be called multiple times to add additional \"GROUP BY\"\nclauses.\n\n<p>\nNOTE: Use of this means that the resulting objects may not have a valid ID column value so cannot be deleted or\nupdated.\n</p>",
"add some validation to see if this miss anything.\n\n@return true, if successful\n@throws ParallelTaskInvalidException\nthe parallel task invalid exception"
] |
void lockInterruptibly(final Integer permit) throws InterruptedException {
if (permit == null) {
throw new IllegalArgumentException();
}
sync.acquireInterruptibly(permit);
} | [
"Acquire the exclusive 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."
] | [
"Get the authorization uri, where the user logs in.\n\n@param redirectUri\nUri the user is redirected to, after successful authorization.\nThis must be the same as specified at the Eve Online developer\npage.\n@param scopes\nScopes of the Eve Online SSO.\n@param state\nThis should be some secret to prevent XRSF, please read:\nhttp://www.thread-safe.com/2014/05/the-correct-use-of-state-\nparameter-in.html\n@return",
"gets the first non annotation line number of a node, taking into account annotations.",
"MPP14 files seem to exhibit some occasional weirdness\nwith duplicate ID values which leads to the task structure\nbeing reported incorrectly. The following method attempts to correct this.\nThe method uses ordering data embedded in the file to reconstruct\nthe correct ID order of the tasks.",
"Use this API to fetch all the dnstxtrec resources that are configured on netscaler.",
"Find the the qualified container port of the target service\nUses java annotations first or returns the container port.\n\n@param service\nThe target service.\n@param qualifiers\nThe set of qualifiers.\n\n@return Returns the resolved containerPort of '0' as a fallback.",
"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",
"Get the bone index for the bone with the given name.\n\n@param bonename string identifying the bone whose index you want\n@return 0 based bone index or -1 if bone with that name is not found.",
"Called to update the cached formats when something changes.",
"Calculate the value of a caplet assuming the Black'76 model.\n\n@param forward The forward (spot).\n@param volatility The Black'76 volatility.\n@param optionMaturity The option maturity\n@param optionStrike The option strike.\n@param periodLength The period length of the underlying forward rate.\n@param discountFactor The discount factor corresponding to the payment date (option maturity + period length).\n@return Returns the value of a caplet under the Black'76 model"
] |
synchronized void removeUserProfile(String id) {
if (id == null) return;
final String tableName = Table.USER_PROFILES.getName();
try {
final SQLiteDatabase db = dbHelper.getWritableDatabase();
db.delete(tableName, "_id = ?", new String[]{id});
} catch (final SQLiteException e) {
getConfigLogger().verbose("Error removing user profile from " + tableName + " Recreating DB");
dbHelper.deleteDatabase();
} finally {
dbHelper.close();
}
} | [
"remove the user profile with id from the db."
] | [
"Record the checkout queue length\n\n@param dest Destination of the socket to checkout. Will actually record\nif null. Otherwise will call this on self and corresponding child\nwith this param null.\n@param queueLength The number of entries in the \"synchronous\" checkout\nqueue.",
"get the TypeArgSignature corresponding to given type\n\n@param type\n@return",
"Display web page, but no user interface - close",
"Detect what has changed in the store definition and rewire BDB\nenvironments accordingly.\n\n@param storeDef updated store definition",
"Sets the lower limits for the \"moving\" body translation relative to joint point.\n\n@param limitX the X axis lower translation limit\n@param limitY the Y axis lower translation limit\n@param limitZ the Z axis lower translation limit",
"Updates event definitions for all throwing events.\n@param def Definitions",
"Process events in the order as they were received.\n\n<p/>\n\nThe overall time to process the events must be within the bounds of the\ntimeout or an {@link InsufficientOperationalNodesException} will be\nthrown.",
"If a given x is into an interval of the partition, this method returns the reference point of the corresponding interval.\nIf the given x is not contained in any interval of the partition, this method returns x.\n\n@param x The point of interest.\n@return The discretized value.",
"Signals that the processor to finish and waits until it finishes."
] |
@Override
public final float getFloat(final int i) {
double val = this.array.optDouble(i, Double.MAX_VALUE);
if (val == Double.MAX_VALUE) {
throw new ObjectMissingException(this, "[" + i + "]");
}
return (float) val;
} | [
"Get the element at the index as a float.\n\n@param i the index of the element to access"
] | [
"Executes a query using the given parameters. The query results will be added to the\nExecutionResults using the given identifier.\n\n@param identifier\nThe identifier to be used for the results when added to the ExecutionResults\n@param name\nThe name of the query to execute\n@param arguments\nThe arguments to be used for the query parameters\n@return",
"Transits a float propertyId from the start value to the end value.\n\n@param propertyId\n@param vals\n@return self",
"Sets the indirection handler class.\n\n@param indirectionHandlerClass The class for indirection handlers",
"Creates PollingState from the json string.\n\n@param serializedPollingState polling state as json string\n@param <ResultT> the result that the poll operation produces\n@return the polling state",
"delegate to each contained OJBIterator and release\nits resources.",
"Sets the RegExp pattern for the TextBox\n@param pattern\n@param invalidCharactersInNameErrorMessage",
"Provides the scrollableList implementation for page scrolling\n@return {@link LayoutScroller.ScrollableList} implementation, passed to {@link LayoutScroller}\nfor the processing the scrolling",
"Use this API to unset the properties of gslbservice resources.\nProperties that need to be unset are specified in args array.",
"Copies information between specified streams and then closes\nboth of the streams.\n@throws java.io.IOException"
] |
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"
] | [
"Returns a JSONObject keyed with the lastId retrieved and a value of a JSONArray of the retrieved JSONObject events\n\n@param table the table to read from\n@return JSONObject containing the max row ID and a JSONArray of the JSONObject events or null",
"Retrieves the time at which work finishes on the given date, or returns\nnull if this is a non-working day.\n\n@param date Date instance\n@return finish time, or null for non-working day",
"Runs the example program.\n\n@param args\n@throws IOException\nif there was a problem in writing the output file",
"Print classes that were parts of relationships, but not parsed by javadoc",
"This method is called by the client to load the most recent list of resources.\nThis method should only be called by the service client.\n\n@param result the most recent list of resources.",
"Retrieve the date range at the specified index.\nThe index is zero based, and this method will return\nnull if the requested date range does not exist.\n\n@param index range index\n@return date range instance",
"This method takes the textual version of a constraint name\nand returns an appropriate class instance. Note that unrecognised\nvalues are treated as \"As Soon As Possible\" constraints.\n\n@param locale target locale\n@param type text version of the constraint type\n@return ConstraintType instance",
"make a copy of the criteria\n@param includeGroupBy if true\n@param includeOrderBy if ture\n@param includePrefetchedRelationships if true\n@return a copy of the criteria",
"Saves a screenshot of every new state."
] |
public void createEnvironment(@Observes(precedence = 10) BeforeClass event, OpenShiftAdapter client,
CubeOpenShiftConfiguration cubeOpenShiftConfiguration) {
final TestClass testClass = event.getTestClass();
log.info(String.format("Creating environment for %s", testClass.getName()));
OpenShiftResourceFactory.createResources(testClass.getName(), client, testClass.getJavaClass(),
cubeOpenShiftConfiguration.getProperties());
classTemplateProcessor = new ClassTemplateProcessor(client, cubeOpenShiftConfiguration, testClass);
final List<? extends OpenShiftResource> templateResources = classTemplateProcessor.processTemplateResources();
templateDetailsProducer.set(() -> templateResources);
} | [
"Create the environment as specified by @Template or\narq.extension.ce-cube.openshift.template.* properties.\n<p>\nIn the future, this might be handled by starting application Cube\nobjects, e.g. CreateCube(application), StartCube(application)\n<p>\nNeeds to fire before the containers are started."
] | [
"Read an individual remark type from a Gantt Designer file.\n\n@param remark remark type",
"Calculate the start variance.\n\n@return start variance",
"Inserts a Parcelable value into the mapping of the underlying Bundle, replacing any existing\nvalue for the given key. Either key or value may be null.\n\n@param key a String, or null\n@param value a Parcelable object, or null\n@return this bundler instance to chain method calls",
"Sets the replacement var map.\n\n@param replacementVarMap\nthe replacement var map\n@return the parallel task builder",
"Processes the template for all column definitions of the current table.\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\"",
"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.",
"Prints the results of the equation to standard out. Useful for debugging",
"get the getter method corresponding to given property",
"Sets the replacement var map node specific.\n\n@param replacementVarMapNodeSpecific\nthe replacement var map node specific\n@return the parallel task builder"
] |
public History[] filterHistory(String... filters) throws Exception {
BasicNameValuePair[] params;
if (filters.length > 0) {
params = new BasicNameValuePair[filters.length];
for (int i = 0; i < filters.length; i++) {
params[i] = new BasicNameValuePair("source_uri[]", filters[i]);
}
} else {
return refreshHistory();
}
return constructHistory(params);
} | [
"Retrieve the request History based on the specified filters.\nIf no filter is specified, return the default size history.\n\n@param filters filters to be applied\n@return array of History items\n@throws Exception exception"
] | [
"Returns the absolute directory on the Web site where dumpfiles of the\ngiven type can be found.\n\n@param dumpContentType\nthe type of dump\n@return relative web directory for the current dumpfiles\n@throws IllegalArgumentException\nif the given dump file type is not known",
"Use this API to update nd6ravariables resources.",
"Get the first controller of a specified type\n@param type controller type to search for\n@return controller found or null if no controllers of the given type",
"Delivers the correct JSON Object for the Stencilset\n\n@param stencilSet\n@throws org.json.JSONException",
"Use this API to fetch dnsview resource of given name .",
"Processes the template for all foreignkeys of the current table.\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\"",
"Get an extent aware RsIterator based on the Query\n\n@param query\n@param cld\n@param factory the Factory for the RsIterator\n@return OJBIterator",
"Load a classifier from the specified InputStream. The classifier is\nreinitialized from the flags serialized in the classifier. This does not\nclose the InputStream.\n\n@param in\nThe InputStream to load the serialized classifier from\n@param props\nThis Properties object will be used to update the\nSeqClassifierFlags which are read from the serialized classifier\n\n@throws IOException\nIf there are problems accessing the input stream\n@throws ClassCastException\nIf there are problems interpreting the serialized data\n@throws ClassNotFoundException\nIf there are problems interpreting the serialized data",
"Locates a task within a child task container which matches the supplied UUID.\n\n@param parent child task container\n@param uuid required UUID\n@return Task instance or null if the task is not found"
] |
protected int getDonorId(StoreRoutingPlan currentSRP,
StoreRoutingPlan finalSRP,
int stealerZoneId,
int stealerNodeId,
int stealerPartitionId) {
int stealerZoneNAry = finalSRP.getZoneNaryForNodesPartition(stealerZoneId,
stealerNodeId,
stealerPartitionId);
int donorZoneId;
if(currentSRP.zoneNAryExists(stealerZoneId, stealerZoneNAry, stealerPartitionId)) {
// Steal from local n-ary (since one exists).
donorZoneId = stealerZoneId;
} else {
// Steal from zone that hosts primary partition Id.
int currentMasterNodeId = currentSRP.getNodeIdForPartitionId(stealerPartitionId);
donorZoneId = currentCluster.getNodeById(currentMasterNodeId).getZoneId();
}
return currentSRP.getNodeIdForZoneNary(donorZoneId, stealerZoneNAry, stealerPartitionId);
} | [
"Decide which donor node to steal from. This is a policy implementation.\nI.e., in the future, additional policies could be considered. At that\ntime, this method should be overridden in a sub-class, or a policy object\nought to implement this algorithm.\n\nCurrent policy:\n\n1) If possible, a stealer node that is the zone n-ary in the finalCluster\nsteals from the zone n-ary in the currentCluster in the same zone.\n\n2) If there are no partition-stores to steal in the same zone (i.e., this\nis the \"zone expansion\" use case), then a differnt policy must be used.\nThe stealer node that is the zone n-ary in the finalCluster determines\nwhich pre-existing zone in the currentCluster hosts the primary partition\nid for the partition-store. The stealer then steals the zone n-ary from\nthat pre-existing zone.\n\nThis policy avoids unnecessary cross-zone moves and distributes the load\nof cross-zone moves approximately-uniformly across pre-existing zones.\n\nOther policies to consider:\n\n- For zone expansion, steal all partition-stores from one specific\npre-existing zone.\n\n- Replace heuristic to approximately uniformly distribute load among\nexisting zones to something more concrete (i.e. track steals from each\npre-existing zone and forcibly balance them).\n\n- Select a single donor for all replicas in a new zone. This will require\ndonor-based rebalancing to be run (at least for this specific part of the\nplan). This would reduce the number of donor-side scans of data. (But\nstill send replication factor copies over the WAN.) This would require\napparatus in the RebalanceController to work.\n\n- Set up some sort of chain-replication in which a single stealer in the\nnew zone steals some replica from a pre-exising zone, and then other\nn-aries in the new zone steal from the single cross-zone stealer in the\nzone. This would require apparatus in the RebalanceController to work.\n\n@param currentSRP\n@param finalSRP\n@param stealerZoneId\n@param stealerNodeId\n@param stealerPartitionId\n@return the node id of the donor for this partition Id."
] | [
"look for zero after country code, and remove if present",
"Use this API to convert sslpkcs8.",
"Get the photo or ticket id from the response.\n\n@param async\n@param response\n@return",
"Updates all inverse associations managed by a given entity.",
"Initialize the service with a context\n@param context the servlet context to initialize the profile.",
"A specific, existing project can be deleted by making a DELETE request\non the URL for that project.\n\nReturns an empty data record.\n\n@param project The project to delete.\n@return Request object",
"Invoked when an action occurs.",
"Use this API to fetch appfwprofile_crosssitescripting_binding resources of given name .",
"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"
] |
public static Iterable<BoxFileVersionRetention.Info> getAll(BoxAPIConnection api, String ... fields) {
return getRetentions(api, new QueryFilter(), fields);
} | [
"Retrieves all file version retentions.\n@param api the API connection to be used by the resource.\n@param fields the fields to retrieve.\n@return an iterable contains information about all file version retentions."
] | [
"use the design parameters to compute the constraint equation to get the value",
"Returns the zero rates for a given vector maturities.\n\n@param maturities The given maturities.\n@return The zero rates.",
"Converts days of the week into a bit field.\n\n@param data recurring data\n@return bit field",
"Use this API to change sslcertkey.",
"Adds an additional site link to the constructed document.\n\n@param title\nthe title of the linked page\n@param siteKey\nidentifier of the site, e.g., \"enwiki\"\n@param badges\none or more badges",
"Adds a file with the provided description.",
"Sets a custom configuration attribute.\n@param attributeName the attribute name. Names starting with\n{@link #JDBC_PROPERTY_NAME_PREFIX} will be used (without the prefix) by the\nConnectionFactory when creating connections from DriverManager\n(not used for external DataSource connections). Names starting with\n{@link #DBCP_PROPERTY_NAME_PREFIX} to Commons DBCP (if used, also without prefix).\n@param attributeValue the attribute value",
"Returns an iterator over the items in the trash.\n@return an iterator over the items in the trash.",
"return the list of FormInputs that match this element\n\n@param element\n@return"
] |
private static boolean validateLocalFileRecord(FileChannel channel, long startLocRecord, long compressedSize) throws IOException {
ByteBuffer lfhBuffer = getByteBuffer(LOCLEN);
read(lfhBuffer, channel, startLocRecord);
if (lfhBuffer.limit() < LOCLEN || getUnsignedInt(lfhBuffer, 0) != LOCSIG) {
return false;
}
if (compressedSize == -1) {
// We can't further evaluate
return true;
}
int fnLen = getUnsignedShort(lfhBuffer, LOC_FILENAMELEN);
int extFieldLen = getUnsignedShort(lfhBuffer, LOC_EXTFLDLEN);
long nextSigPos = startLocRecord + LOCLEN + compressedSize + fnLen + extFieldLen;
read(lfhBuffer, channel, nextSigPos);
long header = getUnsignedInt(lfhBuffer, 0);
return header == LOCSIG || header == EXTSIG || header == CENSIG;
} | [
"Checks that the data starting at startLocRecord looks like a local file record header.\n\n@param channel the channel\n@param startLocRecord offset into channel of the start of the local record\n@param compressedSize expected compressed size of the file, or -1 to indicate this isn't known"
] | [
"Check, if the current user has permissions on the document's resource.\n@param cms the context\n@param doc the solr document (from the search result)\n@param filter the resource filter to use for checking permissions\n@return <code>true</code> iff the resource mirrored by the search result can be read by the current user.",
"Adds a data set with date-time value to IIM file.\n\n@param ds\ndata set id (see constants in IIM class)\n@param date\ndate to set. Null values are silently ignored.\n@throws SerializationException\nif value can't be serialized by data set's serializer\n@throws InvalidDataSetException\nif data set isn't defined",
"Use this API to fetch csvserver_cachepolicy_binding resources of given name .",
"Makes an spatial shape representing the time range defined by the two specified dates.\n\n@param from the start {@link Date}\n@param to the end {@link Date}\n@return a shape",
"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",
"Retrieve a UUID in the form required by Primavera PMXML.\n\n@param guid UUID instance\n@return formatted UUID",
"Read metadata by populating an instance of the target class\nusing SAXParser.",
"Creates a sorted list that contains the items of the given iterable. The resulting list is sorted according to\nthe order induced by the specified comparator.\n\n@param iterable\nthe items to be sorted. May not be <code>null</code>.\n@param comparator\nthe comparator to be used. May be <code>null</code> to indicate that the natural ordering of the\nelements should be used.\n@return a sorted list as a shallow copy of the given iterable.\n@see Collections#sort(List, Comparator)\n@see #sort(Iterable)\n@see #sortBy(Iterable, org.eclipse.xtext.xbase.lib.Functions.Function1)\n@see ListExtensions#sortInplace(List, Comparator)\n@since 2.7",
"Returns the deployment names with the specified runtime names at the specified deploymentRootAddress.\n\n@param deploymentRootResource\n@param runtimeNames\n@return the deployment names with the specified runtime names at the specified deploymentRootAddress."
] |
public static BoxItem.Info getSharedItem(BoxAPIConnection api, String sharedLink, String password) {
BoxAPIConnection newAPI = new SharedLinkAPIConnection(api, sharedLink, password);
URL url = SHARED_ITEM_URL_TEMPLATE.build(newAPI.getBaseURL());
BoxAPIRequest request = new BoxAPIRequest(newAPI, url, "GET");
BoxJSONResponse response = (BoxJSONResponse) request.send();
JsonObject json = JsonObject.readFrom(response.getJSON());
return (BoxItem.Info) BoxResource.parseInfo(newAPI, json);
} | [
"Gets an item that was shared with a password-protected shared link.\n@param api the API connection to be used by the shared item.\n@param sharedLink the shared link to the item.\n@param password the password for the shared link.\n@return info about the shared item."
] | [
"We add typeRefs without Nodes on the fly, so we should remove them before relinking.",
"Check if a dependency matches the filters\n\n@param dependency\n\n@return boolean",
"private int numCalls = 0;",
"Read remarks from a Gantt Designer file.\n\n@param gantt Gantt Designer file",
"Adds NOT BETWEEN criteria,\ncustomer_id not between 1 and 10\n\n@param attribute The field name to be used\n@param value1 The lower boundary\n@param value2 The upper boundary",
"common utility method for adding a statement to a record",
"Find the index of the specified name in field name array.",
"Upload a photo from a File.\n\n@param file\nthe photo file\n@param metaData\nThe meta data\n@return photoId or ticketId\n@throws FlickrException",
"Rebuild logging systems with updated mode\n@param newMode log mode"
] |
public static appfwglobal_auditnslogpolicy_binding[] get(nitro_service service) throws Exception{
appfwglobal_auditnslogpolicy_binding obj = new appfwglobal_auditnslogpolicy_binding();
appfwglobal_auditnslogpolicy_binding response[] = (appfwglobal_auditnslogpolicy_binding[]) obj.get_resources(service);
return response;
} | [
"Use this API to fetch a appfwglobal_auditnslogpolicy_binding resources."
] | [
"Method to initialize the list.\n\n@param resList a given instance or null\n@return an instance",
"Adds OPT_U | OPT_URL option to OptionParser, with one argument.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional",
"The users element defines users within the domain model, it is a simple authentication for some out of the box users.",
"Extract the parent WBS from a WBS.\n\n@param wbs current WBS\n@return parent WBS",
"Get an ObjectReferenceDescriptor by name BRJ\n@param name\n@return ObjectReferenceDescriptor or null",
"Convert gallery name to title key.\n@param gallery gallery name for example \"downloadgallery\"\n@return key as string \"ERR_REASON_NO_DOWNLOADGALLERY_0\"",
"returns all methods not in the group\n\n@param groupId Id of group\n@return List of Methods for a group\n@throws Exception exception",
"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.",
"Determine the enum value corresponding to the track source slot found in the packet.\n\n@return the proper value"
] |
public static String getGetterName(String propertyName, Class type) {
String prefix = type == boolean.class || type == Boolean.class ? "is" : "get";
return prefix + MetaClassHelper.capitalize(propertyName);
} | [
"Gets the name for the getter for this property\n\n@return The name of the property. The name is \"get\"+ the capitalized propertyName\nor, in the case of boolean values, \"is\" + the capitalized propertyName"
] | [
"Gets a SerialMessage with the SENSOR_ALARM_GET command\n@return the serial message",
"Gets all checked widgets in the group\n@return list of checked widgets",
"If the `invokerClass` specified is singleton, or without field or all fields are\nstateless, then return an instance of the invoker class. Otherwise, return null\n@param invokerClass the invoker class\n@param app the app\n@return an instance of the invokerClass or `null` if invoker class is stateful class",
"Adapt a file path to the current file system.\n@param filePath The input file path string.\n@return File path compatible with the file system of this {@link GVRResourceVolume}.",
"Returns a list of the rekordbox IDs of the tracks contained in the cache.\n\n@return a list containing the rekordbox ID for each track present in the cache, in the order they appear",
"To be used with AutoText class constants ALIGMENT_LEFT, ALIGMENT_CENTER and ALIGMENT_RIGHT\n@param aligment\n@return",
"Gets the metrics as a map whose keys are the metric name and whose values are the metric values.\n\n@return map",
"Invokes the exit logger if and only if no ExitLogger was previously invoked.\n@param logger the logger. Cannot be {@code null}",
"Called when remote end send a message to this connection\n@param receivedMessage the message received\n@return this context"
] |
public <T extends CoreLabel> Datum<String, String> makeDatum(List<IN> info, int loc, FeatureFactory featureFactory) {
PaddedList<IN> pInfo = new PaddedList<IN>(info, pad);
Collection<String> features = new ArrayList<String>();
List<Clique> cliques = featureFactory.getCliques();
for (Clique c : cliques) {
Collection<String> feats = featureFactory.getCliqueFeatures(pInfo, loc, c);
feats = addOtherClasses(feats, pInfo, loc, c);
features.addAll(feats);
}
printFeatures(pInfo.get(loc), features);
CoreLabel c = info.get(loc);
return new BasicDatum<String, String>(features, c.get(AnswerAnnotation.class));
} | [
"Make an individual Datum out of the data list info, focused at position\nloc.\n@param info A List of WordInfo objects\n@param loc The position in the info list to focus feature creation on\n@param featureFactory The factory that constructs features out of the item\n@return A Datum (BasicDatum) representing this data instance"
] | [
"Use this method to enable device network-related information tracking, including IP address.\nThis reporting is disabled by default. To re-disable tracking call this method with enabled set to false.\n\n@param value boolean Whether device network info reporting should be enabled/disabled.",
"Start watching the fluo app uuid. If it changes or goes away then halt the process.",
"Sets the currency code, or the regular expression to select codes.\n\n@param codes the currency codes or code expressions, not null.\n@return the query for chaining.",
"Note that the index can only be built once.\n\n@param beans The set of beans the index should be built from, only instances of {@link CommonBean} and implementations of {@link PassivationCapable} are\nincluded\n@throws IllegalStateException If the index is built already",
"Read a two byte integer from the data.\n\n@param offset current offset into data block\n@param data data block\n@return int value",
"Check whether the given is is matched by one of the include expressions.\n\n@param id id to check\n@param includes list of include regular expressions\n@return true when id is included",
"Resolve an operation transformer entry.\n\n@param address the address\n@param operationName the operation name\n@param placeholderResolver a placeholder resolver used to resolve children of a placeholder registration\n@return the transformer entry",
"Adds an additional description to the constructed document.\n\n@param text\nthe text of the description\n@param languageCode\nthe language code of the description\n@return builder object to continue construction",
"Get a list of destinations and the values matching templated parameter for the given path.\nReturns an empty list when there are no destinations that are matched.\n\n@param path path to be routed.\n@return List of Destinations matching the given route."
] |
@Override
public void addVariable(String varName, Object value) {
synchronized (mGlobalVariables) {
mGlobalVariables.put(varName, value);
}
refreshGlobalBindings();
} | [
"Add a variable to the scripting context.\n\n@param varName The variable name.\n@param value The variable value."
] | [
"returns a dynamic Proxy that implements all interfaces of the\nclass described by this ClassDescriptor.\n\n@return Class the dynamically created proxy class",
"Checks if request is intended for Gerrit host.",
"Produces all tuples of size n chosen from a list of variable names\n\n@param variables the list of variable names to make tuples of\n@param nWise the size of the desired tuples\n@return all tuples of size nWise",
"Get a random sample of k out of n elements.\n\nSee Algorithm S, D. E. Knuth, The Art of Computer Programming, Vol. 2, p.142.",
"Reset autoCommit state.",
"Set the amount of padding between child objects.\n@param axis {@link Axis}\n@param padding",
"Terminates with a help message if the parse is not successful\n\n@param args command line arguments to\n@return the format in a correct state",
"returns array with all allowed values\n@return allowed values",
"Build a valid datastore URL."
] |
public void addNotIn(String attribute, Query subQuery)
{
// PAW
// addSelectionCriteria(ValueCriteria.buildNotInCriteria(attribute, subQuery, getAlias()));
addSelectionCriteria(ValueCriteria.buildNotInCriteria(attribute, subQuery, getUserAlias(attribute)));
} | [
"NOT IN Criteria with SubQuery\n@param attribute The field name to be used\n@param subQuery The subQuery"
] | [
"Get a string property, or, if no such property is defined, return\nthe given default value\n\n@param props the properties\n@param name the key in the properties\n@param defaultValue the default value if the key not exists\n@return value in the props or defaultValue while name not exist",
"Use this API to fetch all the rnatparam resources that are configured on netscaler.",
"Search for interesting photos using the Flickr Interestingness algorithm.\n\n@param params\nAny search parameters\n@param perPage\nNumber of items per page\n@param page\nThe page to start on\n@return A PhotoList\n@throws FlickrException",
"prevent too many refreshes happening one after the other.",
"Set the week day.\n@param weekDayStr the week day to set.",
"Scans given directory for files passing given filter, adds the results into given list.",
"We have obtained album art for a device, so store it and alert any listeners.\n\n@param update the update which caused us to retrieve this art\n@param art the album art which we retrieved",
"Build the context name.\n\n@param objs the objects\n@return the global context name",
"Return all Clients for a profile\n\n@param profileId ID of profile clients belong to\n@return collection of the Clients found\n@throws Exception exception"
] |
protected float transformLength(float w)
{
Matrix ctm = getGraphicsState().getCurrentTransformationMatrix();
Matrix m = new Matrix();
m.setValue(2, 0, w);
return m.multiply(ctm).getTranslateX();
} | [
"Transforms a length according to the current transformation matrix."
] | [
"Process the module and bundle roots and cross check with the installed information.\n\n@param conf the installed configuration\n@param moduleRoots the module roots\n@param bundleRoots the bundle roots\n@return the processed layers\n@throws IOException",
"Checks to see if all the diagonal elements in the matrix are positive.\n\n@param a A matrix. Not modified.\n@return true if all the diagonal elements are positive, false otherwise.",
"Declares a fresh Builder to copy default property values from.\n\n<p>Reuses an existing fresh Builder instance if one was already declared in this scope.\n\n@returns a variable holding a fresh Builder, if a no-args factory method is available to\ncreate one with",
"Add a comment to a photoset. This method requires authentication with 'write' permission.\n\n@param photosetId\nThe id of the photoset to add a comment to.\n@param commentText\nText of the comment\n@return the comment id\n@throws FlickrException",
"Record a Screen View event\n@param screenName String, the name of the screen",
"This method allows nested tasks to be added, with the WBS being\ncompleted automatically.\n\n@return new task",
"Write a single resource.\n\n@param mpxj Resource instance",
"Notifies that a content item is changed.\n\n@param position the position.",
"Test for equality.\n@param obj1 the first object\n@param obj2 the second object\n@return true if both are null or the two objects are equal"
] |
public static String readTag(Reader r) throws IOException {
if ( ! r.ready()) {
return null;
}
StringBuilder b = new StringBuilder("<");
int c = r.read();
while (c >= 0) {
b.append((char) c);
if (c == '>') {
break;
}
c = r.read();
}
if (b.length() == 1) {
return null;
}
return b.toString();
} | [
"Reads all text of the XML tag and returns it as a String.\nAssumes that a '<' character has already been read.\n\n@param r The reader to read from\n@return The String representing the tag, or null if one couldn't be read\n(i.e., EOF). The returned item is a complete tag including angle\nbrackets, such as <code><TXT></code>"
] | [
"Updates a path table value for column columnName\n\n@param columnName name of the column to update\n@param newData new content to set\n@param path_id ID of the path to update",
"Builds a string that serializes a list of objects separated by the pipe\ncharacter. The toString methods are used to turn objects into strings.\nThis operation is commonly used to build parameter lists for API\nrequests.\n\n@param objects\nthe objects to implode\n@return string of imploded objects",
"Override this method to change the default splash screen size or\nposition.\n\nThis method will be called <em>before</em> {@link #onInit(GVRContext)\nonInit()} and before the normal render pipeline starts up. In particular,\nthis means that any {@linkplain GVRAnimation animations} will not start\nuntil the first {@link #onStep()} and normal rendering starts.\n\n@param splashScreen\nThe splash object created from\n{@link #getSplashTexture(GVRContext)},\n{@link #getSplashMesh(GVRContext)}, and\n{@link #getSplashShader(GVRContext)}.\n\n@since 1.6.4",
"Create a temporary directory under a given workspace",
"Determines the median value of the data set.\n@return If the number of elements is odd, returns the middle element.\nIf the number of elements is even, returns the midpoint of the two\nmiddle elements.\n@since 1.0.1",
"Helper to read a line from the config file.\n@param propValue the property value\n@return the value of the variable set at this line.",
"Generate a map file from a jar file.\n\n@param jarFile jar file\n@param mapFileName map file name\n@param mapClassMethods true if we want to produce .Net style class method names\n@throws XMLStreamException\n@throws IOException\n@throws ClassNotFoundException\n@throws IntrospectionException",
"Test whether the operation has a defined criteria attribute.\n\n@param operation the operation\n@return",
"Remove any mapping for this key, and return any previously\nmapped value.\n\n@param key the key whose mapping is to be removed\n@return the value removed, or null"
] |
protected void addSpecialMethods(ClassFile proxyClassType, ClassMethod staticConstructor) {
try {
// Add special methods for interceptors
for (Method method : LifecycleMixin.class.getMethods()) {
BeanLogger.LOG.addingMethodToProxy(method);
MethodInformation methodInfo = new RuntimeMethodInformation(method);
createInterceptorBody(proxyClassType.addMethod(method), methodInfo, false, staticConstructor);
}
Method getInstanceMethod = TargetInstanceProxy.class.getMethod("weld_getTargetInstance");
Method getInstanceClassMethod = TargetInstanceProxy.class.getMethod("weld_getTargetClass");
generateGetTargetInstanceBody(proxyClassType.addMethod(getInstanceMethod));
generateGetTargetClassBody(proxyClassType.addMethod(getInstanceClassMethod));
Method setMethodHandlerMethod = ProxyObject.class.getMethod("weld_setHandler", MethodHandler.class);
generateSetMethodHandlerBody(proxyClassType.addMethod(setMethodHandlerMethod));
Method getMethodHandlerMethod = ProxyObject.class.getMethod("weld_getHandler");
generateGetMethodHandlerBody(proxyClassType.addMethod(getMethodHandlerMethod));
} catch (Exception e) {
throw new WeldException(e);
}
} | [
"Adds methods requiring special implementations rather than just\ndelegation.\n\n@param proxyClassType the Javassist class description for the proxy type"
] | [
"Re-reads the given entity, refreshing any properties updated on the server-side during insert or update.",
"Assigns a retention policy to all items with a given metadata template, optionally matching on fields.\n@param api the API connection to be used by the created assignment.\n@param policyID id of the assigned retention policy.\n@param templateID the ID of the metadata template to assign the policy to.\n@param filter optional fields to match against in the metadata template.\n@return info about the created assignment.",
"Instantiates a new event collector.",
"Get the best guess we have for the current track position on the specified player.\n\n@param player the player number whose position is desired\n\n@return the milliseconds into the track that we believe playback has reached, or -1 if we don't know\n\n@throws IllegalStateException if the TimeFinder is not running",
"Use this API to fetch all the onlinkipv6prefix resources that are configured on netscaler.",
"Group results by the specified field.\n\n@param fieldName by which to group results\n@param isNumber whether field isNumeric.\n@return this for additional parameter setting or to query",
"Finds the Widget in hierarchy\n@param name Name of the child to find\n@return The named child {@link Widget} or {@code null} if not found.",
"Start a server.\n\n@return the http server\n@throws Exception the exception",
"Samples with replacement from a collection\n\n@param c\nThe collection to be sampled from\n@param n\nThe number of samples to take\n@return a new collection with the sample"
] |
public int getSridFromCrs(String crs) {
int crsInt;
if (crs.indexOf(':') != -1) {
crsInt = Integer.parseInt(crs.substring(crs.indexOf(':') + 1));
} else {
try {
crsInt = Integer.parseInt(crs);
} catch (NumberFormatException e) {
crsInt = 0;
}
}
return crsInt;
} | [
"Isn't there a method for this in GeoTools?\n\n@param crs\nCRS string in the form of 'EPSG:<srid>'.\n@return SRID as integer."
] | [
"Extracts the words from a string. Words are seperated by a space character.\n\n@param line The line that is being parsed.\n@return A list of words contained on the line.",
"Use this API to fetch all the nsrollbackcmd resources that are configured on netscaler.",
"scans right to left until max to maintain latest max values for the multi-value property specified by key.\n\n@param key the property key\n@param left original list\n@param right new list\n@param remove if remove new list from original\n@param vr ValidationResult for error and merged list return",
"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().",
"Gets the estimated time remaining in milliseconds based upon the total number of work units, the start time, and how many units have been done\nso far.\n\nThis should not be called before any work units have been done.",
"If the given result is not cudnnStatus.CUDNN_STATUS_SUCCESS\nand exceptions have been enabled, this method will throw a\nCudaException with an error message that corresponds to the\ngiven result code. Otherwise, the given result is simply\nreturned.\n\n@param result The result to check\n@return The result that was given as the parameter\n@throws CudaException If exceptions have been enabled and\nthe given result code is not cudnnStatus.CUDNN_STATUS_SUCCESS",
"Gets the gradient at the current point, computed on the given batch of examples.\n@param batch A set of indices indicating the examples over which the gradient should be computed.\n@param gradient The output gradient, a vector of partial derivatives.",
"Set HTTP headers to allow caching for the given number of seconds.\n\n@param response where to set the caching settings\n@param seconds number of seconds into the future that the response should be cacheable for",
"Add an individual class to the map file.\n\n@param loader jar file class loader\n@param jarEntry jar file entry\n@param writer XML stream writer\n@param mapClassMethods true if we want to produce .Net style class method names\n@throws ClassNotFoundException\n@throws XMLStreamException\n@throws IntrospectionException"
] |
public void clear() {
for (Bean bean : beans.values()) {
if (null != bean.destructionCallback) {
bean.destructionCallback.run();
}
}
beans.clear();
} | [
"Clear all beans and call the destruction callback."
] | [
"Set the locking values\n@param cld\n@param obj\n@param oldLockingValues",
"Add a cause to the backtrace.\n\n@param cause\nthe cause\n@param bTrace\nthe backtrace list",
"Read data from the table. Return a reference to the current\ninstance to allow method chaining.\n\n@return reader instance",
"Obtains a International Fixed local date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the International Fixed local date-time, not null\n@throws DateTimeException if unable to create the date-time",
"Adds OPT_P | OPT_PARTITION option to OptionParser, with multiple\narguments.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional",
"Gets any previous versions of this file. Note that only users with premium accounts will be able to retrieve\nprevious versions of their files.\n\n@return a list of previous file versions.",
"Creates a new Collaboration Whitelist for a domain.\n@param api the API connection to be used by the resource.\n@param domain the domain to be added to a collaboration whitelist for a Box Enterprise.\n@param direction an enum representing the direction of the collaboration whitelist. Can be set to\ninbound, outbound, or both.\n@return information about the collaboration whitelist created.",
"Returns the supplied string with any trailing '\\n' removed.",
"Edit the co-ordinates that the user shows in\n\n@param photoId\n@param userId\n@param bounds\n@throws FlickrException"
] |
boolean hasNoAlternativeWildcardRegistration() {
return parent == null || PathElement.WILDCARD_VALUE.equals(valueString) || !parent.getChildNames().contains(PathElement.WILDCARD_VALUE);
} | [
"Gets whether this registration has an alternative wildcard registration"
] | [
"Converts a value to the appropriate type.\n\n@param type target type\n@param value input value\n@return output value",
"Initialize all components of this URI builder with the components of the given URI.\n@param uri the URI\n@return this UriComponentsBuilder",
"Calculate entropy value.\n@param values Values.\n@return Returns entropy value of the specified histogram array.",
"Gets the time warp.\n\n@return the time warp",
"Displays a localized warning.\n@param caption the caption of the warning.\n@param description the description of the warning.",
"Use this API to fetch dnstxtrec resources of given names .",
"returns null if no device is found.",
"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.",
"Want to make arbitrary probability queries? Then this is the method for\nyou. Given the filename, it reads it in and breaks it into documents, and\nthen makes a CRFCliqueTree for each document. you can then ask the clique\ntree for marginals and conditional probabilities of almost anything you\nwant."
] |
public List<TimephasedWork> getTimephasedBaselineWork(int index)
{
return m_timephasedBaselineWork[index] == null ? null : m_timephasedBaselineWork[index].getData();
} | [
"Retrieve timephased baseline work. Note that index 0 represents \"Baseline\",\nindex 1 represents \"Baseline1\" and so on.\n\n@param index baseline index\n@return timephased work, or null if no baseline is present"
] | [
"Checks that all the qualifiers in the set requiredQualifiers are in the set of qualifiers. Qualifier equality rules for\nannotation members are followed.\n\n@param requiredQualifiers The required qualifiers\n@param qualifiers The set of qualifiers to check\n@return True if all matches, false otherwise",
"Gets the info for a running build\n\n@param appName See {@link #listApps} for a list of apps that can be used.\n@param buildId the unique identifier of the build",
"Returns the counters with keys as the first key and count as the\ntotal count of the inner counter for that key\n\n@return counter of type K1",
"Returns the supplied string with any trailing '\\n' removed.",
"Sets an argument to the collection of arguments. This guarantees only one value will be assigned to the\nargument key.\n\n@param argument the argument to add",
"Get the configured hive.execution.engine. If not set it will default to the default value of HiveConf",
"This method processes a single deferred relationship list.\n\n@param dr deferred relationship list data\n@throws MPXJException",
"On key down we assume the key will go at the end. It's the most\ncommon case and not that distracting if that's not true.",
"Reset the Where object so it can be re-used."
] |
public static <V> Map<V, V> convertListToMap(List<V> list) {
Map<V, V> map = new HashMap<V, V>();
if(list.size() % 2 != 0)
throw new VoldemortException("Failed to convert list to map.");
for(int i = 0; i < list.size(); i += 2) {
map.put(list.get(i), list.get(i + 1));
}
return map;
} | [
"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."
] | [
"Normalizes the matrix such that the Frobenius norm is equal to one.\n\n@param A The matrix that is to be normalized.",
"Get a list of destinations and the values matching templated parameter for the given path.\nReturns an empty list when there are no destinations that are matched.\n\n@param path path to be routed.\n@return List of Destinations matching the given route.",
"Return a copy of the result as a String.\n\n<p>The default version of this method copies the result into a temporary byte array and then\ntries to decode it using the configured encoding.\n\n@return string version of the result.\n@throws IOException if the data cannot be produced or could not be decoded to a String.",
"Add the option specifying if the categories should be displayed collapsed\nwhen the dialog opens.\n\n@see org.opencms.ui.actions.I_CmsADEAction#getParams()",
"This adds to the feature name the name of classes that are other than\nthe current class that are involved in the clique. In the CMM, these\nother classes become part of the conditioning feature, and only the\nclass of the current position is being predicted.\n\n@return A collection of features with extra class information put\ninto the feature name.",
"Check if we still need more nodes from the given zone and reduce the\nzoneReplicationFactor count accordingly.\n\n@param requiredRepFactor\n@param zoneId\n@return",
"Parses server section of Zookeeper connection string",
"Use this API to fetch wisite_binding resources of given names .",
"Gets the task from in progress map.\n\n@param jobId\nthe job id\n@return the task from in progress map"
] |
public static SimpleMatrix wrap( Matrix internalMat ) {
SimpleMatrix ret = new SimpleMatrix();
ret.setMatrix(internalMat);
return ret;
} | [
"Creates a new SimpleMatrix with the specified DMatrixRMaj used as its internal matrix. This means\nthat the reference is saved and calls made to the returned SimpleMatrix will modify the passed in DMatrixRMaj.\n\n@param internalMat The internal DMatrixRMaj of the returned SimpleMatrix. Will be modified."
] | [
"Helper method that creates a Velocity context and initialises it\nwith a reference to the ReportNG utils, report metadata and localised messages.\n@return An initialised Velocity context.",
"Sets the body filter for this ID\n\n@param pathId ID of path\n@param bodyFilter Body filter to set",
"Update the background color of the mBgCircle image view.",
"Retrieve the routing type value from the REST request.\n\"X_VOLD_ROUTING_TYPE_CODE\" is the routing type header.\n\nBy default, the routing code is set to NORMAL\n\nTODO REST-Server 1. Change the header name to a better name. 2. Assumes\nthat integer is passed in the header",
"Replace known tags in the current data values with actual values as appropriate\n\n@param cr a reference to DataPipe from which to read the current map",
"Write each predecessor for a task.\n\n@param record Task instance",
"Adds a single value to the data set and updates any\nstatistics that are calculated cumulatively.\n@param value The value to add.",
"Deletes the disabled marker file in the directory of the specified version.\n\n@param version to enable\n@throws PersistenceFailureException if the marker file could not be deleted (can happen if\nthe storage system has become read-only or is otherwise\ninaccessible).",
"Method to service public recording APIs\n\n@param op Operation being tracked\n@param timeNS Duration of operation\n@param numEmptyResponses Number of empty responses being sent back,\ni.e.: requested keys for which there were no values (GET and GET_ALL only)\n@param valueSize Size in bytes of the value\n@param keySize Size in bytes of the key\n@param getAllAggregateRequests Total of amount of keys requested in the operation (GET_ALL only)"
] |
public int[] getCurrentValuesArray() {
int[] currentValues = new int[5];
currentValues[0] = getMinFilterType().getFilterValue(); // MIN FILTER
currentValues[1] = getMagFilterType().getFilterValue(); // MAG FILTER
currentValues[2] = getAnisotropicValue(); // ANISO FILTER
currentValues[3] = getWrapSType().getWrapValue(); // WRAP S
currentValues[4] = getWrapTType().getWrapValue(); // WRAP T
return currentValues;
} | [
"Returns an integer array that contains the current values for all the\ntexture parameters.\n\n@return an integer array that contains the current values for all the\ntexture parameters."
] | [
"defines the KEY in the parent report parameters map where to get the subreport parameters map.\n@param path where to get the parameter map for the subrerpot.\n@return",
"Subtracts v1 from this vector and places the result in this vector.\n\n@param v1\nright-hand vector",
"Returns whether this address contains the non-zero host addresses in other.\n@param other\n@return",
"Update an existing feature. Made package private for testing purposes.\n\n@param feature feature to update\n@throws LayerException oops",
"Deletes the metadata on this folder associated with a specified template.\n\n@param templateName the metadata template type name.",
"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",
"Use this API to add gslbsite resources.",
"Add server redirect to a profile\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@param groupId group ID\n@return ID of added ServerRedirect\n@throws Exception exception",
"Create a request for elevations for samples along a path.\n\n@param req\n@param callback"
] |
public static vpnclientlessaccesspolicy[] get(nitro_service service) throws Exception{
vpnclientlessaccesspolicy obj = new vpnclientlessaccesspolicy();
vpnclientlessaccesspolicy[] response = (vpnclientlessaccesspolicy[])obj.get_resources(service);
return response;
} | [
"Use this API to fetch all the vpnclientlessaccesspolicy resources that are configured on netscaler."
] | [
"Use this API to fetch all the systemuser resources that are configured on netscaler.",
"Adds the task to the specified project, in the optional location\nspecified. If no location arguments are given, the task will be added to\nthe end of the project.\n\n`addProject` can also be used to reorder a task within a project or section that\nalready contains it.\n\nAt most one of `insert_before`, `insert_after`, or `section` should be\nspecified. Inserting into a section in an non-order-dependent way can be\ndone by specifying `section`, otherwise, to insert within a section in a\nparticular place, specify `insert_before` or `insert_after` and a task\nwithin the section to anchor the position of this task.\n\nReturns an empty data block.\n\n@param task The task to add to a project.\n@return Request object",
"Build the context name.\n\n@param objs the objects\n@return the global context name",
"Restore backup data\n\n@param fileData - json file with restore data\n@return\n@throws Exception",
"Writes the JavaScript code describing the tags as Tag classes to given writer.",
"Reads any exceptions present in the file. This is only used in MSPDI\nfile versions saved by Project 2007 and later.\n\n@param calendar XML calendar\n@param bc MPXJ calendar",
"Return a list of Flickr supported blogging services.\n\nThis method does not require authentication.\n\n@return List of Services\n@throws FlickrException",
"Convert a string value into the appropriate Java field value.",
"Creates a new Box Developer Edition connection with enterprise token leveraging an access token cache.\n@param enterpriseId the enterprise ID to use for requesting access token.\n@param clientId the client ID to use when exchanging the JWT assertion for an access token.\n@param clientSecret the client secret to use when exchanging the JWT assertion for an access token.\n@param encryptionPref the encryption preferences for signing the JWT.\n@param accessTokenCache the cache for storing access token information (to minimize fetching new tokens)\n@return a new instance of BoxAPIConnection."
] |
public static base_response clear(nitro_service client, nsconfig resource) throws Exception {
nsconfig clearresource = new nsconfig();
clearresource.force = resource.force;
clearresource.level = resource.level;
return clearresource.perform_operation(client,"clear");
} | [
"Use this API to clear nsconfig."
] | [
"Rethrows OperationCanceledErrors and wraps platform specific OperationCanceledExceptions. Does nothing for any other type of Throwable.",
"Forceful cleanup the logs",
"This is the main entry point used to convert the internal representation\nof timephased work into an external form which can\nbe displayed to the user.\n\n@param projectCalendar calendar used by the resource assignment\n@param work timephased resource assignment data\n@param rangeUnits timescale units\n@param dateList timescale date ranges\n@return list of durations, one per timescale date range",
"Disables all the overrides for a specific profile\n\n@param model\n@param profileID\n@param clientUUID\n@return",
"Creates a Span that covers an exact row. String parameters will be encoded as UTF-8",
"Process calendar hours.\n\n@param calendar parent calendar\n@param row calendar hours data\n@param dayIndex day index",
"Put the core auto-code algorithm here so an external class can call it",
"Remove a key from the given map.\n\n@param <K> type of the map keys.\n@param <V> type of the map values.\n@param map the map to update.\n@param key the key to remove.\n@return the removed value, or <code>null</code> if the key was not\npresent in the map.\n@since 2.15",
"replaces the old with the new item. The new item will not be added when the old one is not\nfound.\n\n@param oldObject will be removed\n@param newObject is added only when hte old item is removed"
] |
Subsets and Splits
No saved queries yet
Save your SQL queries to embed, download, and access them later. Queries will appear here once saved.