query
stringlengths
74
6.1k
positive
sequencelengths
1
1
negative
sequencelengths
9
9
public static String getClassName(Class<?> c) { String name = c.getName(); return name.substring(name.lastIndexOf('.') + 1, name.length()); }
[ "Get the class name without the package\n\n@param c The class name with package\n@return the class name without the package" ]
[ "Retrieve the default mapping between MPXJ assignment fields and Primavera assignment field names.\n\n@return mapping", "Write throwable as attachment.\n\n@param throwable to write\n@param title title of attachment\n@return Created {@link ru.yandex.qatools.allure.model.Attachment}", "Computes either the vector p-norm or the induced matrix p-norm depending on A\nbeing a vector or a matrix respectively.\n\n@param A Vector or matrix whose norm is to be computed.\n@param p The p value of the p-norm.\n@return The computed norm.", "Checks that locking and update-lock are only used for fields of TIMESTAMP or INTEGER type.\n\n@param fieldDef The field descriptor\n@param checkLevel The current check level (this constraint is checked in basic and strict)\n@exception ConstraintException If the constraint has been violated", "Return the count of all objects found\nfor given class, using the PB-api within\nODMG - this may change in further versions.", "Constructs the convex hull of a set of points whose coordinates are given\nby an array of doubles.\n\n@param coords\nx, y, and z coordinates of each input point. The length of\nthis array must be at least three times <code>nump</code>.\n@param nump\nnumber of input points\n@throws IllegalArgumentException\nthe number of input points is less than four or greater than\n1/3 the length of <code>coords</code>, or the points appear\nto be coincident, colinear, or coplanar.", "Sets a property on this Javascript object for which the value is a\nJavascript object itself.\n\n@param propertyName The name of the property.\n@param propertyValue The value of the property.", "Split string of comma-delimited ints into an a int array\n\n@param str\n@return\n@throws IllegalArgumentException", "Calculate a shift value that can be used to create a power-of-two value between\nthe specified maximum and minimum values.\n@param minimumValue the minimum value\n@param maximumValue the maximum value\n@return the calculated shift (use {@code 1 << shift} to obtain a value)" ]
@Deprecated public ModelNode navigate(ModelNode model, boolean create) throws NoSuchElementException { final Iterator<PathElement> i = pathAddressList.iterator(); while (i.hasNext()) { final PathElement element = i.next(); if (create && !i.hasNext()) { if (element.isMultiTarget()) { throw new IllegalStateException(); } model = model.require(element.getKey()).get(element.getValue()); } else { model = model.require(element.getKey()).require(element.getValue()); } } return model; }
[ "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" ]
[ "Guess the date of the dump from the given dump file name.\n\n@param fileName\n@return 8-digit date stamp or YYYYMMDD if none was found", "Write the config to the writer.", "Calculate the layout container size along the axis\n@param axis {@link Axis}\n@return size", "Copies file from a resource to a local temp file\n\n@param sourceResource\n@return Absolute filename of the temp file\n@throws Exception", "Helper to read a mandatory String value.\n@param path The XML path of the element to read.\n@return The String value stored in the XML.\n@throws Exception thrown if the value could not be read.", "Reads Phoenix resource assignments.\n\n@param mpxjResource MPXJ resource\n@param res Phoenix resource", "Checks if the categoryfolder setting needs to be updated.\n\n@return true if the categoryfolder setting needs to be updated", "Sets whether an individual list value is selected.\n\n@param value the value of the item to be selected or unselected\n@param selected <code>true</code> to select the item", "Parse a filter expression.\n\n@param filter the filter expression\n@return compiled nodes" ]
public static StringTemplateGroup readStringTemplateGroup(InputStream stream) { try { return new StringTemplateGroup( new InputStreamReader(stream, "UTF-8"), DefaultTemplateLexer.class, new StringTemplateErrorListener() { @SuppressWarnings("synthetic-access") public void error(String arg0, Throwable arg1) { LOG.error(arg0 + ": " + arg1.getMessage(), arg1); } @SuppressWarnings("synthetic-access") public void warning(String arg0) { LOG.warn(arg0); } }); } catch (Exception e) { LOG.error(e.getLocalizedMessage(), e); return new StringTemplateGroup("dummy"); } }
[ "Reads a stringtemplate group from a stream.\n\nThis will always return a group (empty if necessary), even if reading it from the stream fails.\n\n@param stream the stream to read from\n@return the string template group" ]
[ "Reports a dependency of this node has been faulted.\n\n@param dependencyKey the id of the dependency node\n@param throwable the reason for unsuccessful resolution", "of the unbound provider (", "Get by index is used here.", "Redirect standard streams so that the output can be passed to listeners.", "Unmark a PersistenceBroker as preferred choice for current Thread\n\n@param key The PBKey the broker is associated to\n@param broker The PersistenceBroker to unmark", "If there is a SubReport on a Group, we do the layout here\n@param columnsGroup\n@param jgroup", "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", "Uses current variable assignments and info in an NWiseActionTag to expand on an n wise combinatorial set\n\n@param action an NWiseAction Action\n@param possibleStateList a current list of possible states produced so far from expanding a model state\n@return every input possible state expanded on an n wise combinatorial set defined by that input possible state", "Determine whether we should use the normal repaint process, or delegate that to another component that is\nhosting us in a soft-loaded manner to save memory.\n\n@param x the left edge of the region that we want to have redrawn\n@param y the top edge of the region that we want to have redrawn\n@param width the width of the region that we want to have redrawn\n@param height the height of the region that we want to have redrawn" ]
private String type(Options opt, Type t, boolean generics) { return ((generics ? opt.showQualifiedGenerics : opt.showQualified) ? // t.qualifiedTypeName() : t.typeName()) // + (opt.hideGenerics ? "" : typeParameters(opt, t.asParameterizedType())); }
[ "Print a a basic type t" ]
[ "Use this API to fetch responderpolicy_binding resource of given name .", "A convenience method for creating an immutable sorted set.\n\n@param self a SortedSet\n@return an immutable SortedSet\n@see java.util.Collections#unmodifiableSortedSet(java.util.SortedSet)\n@since 1.0", "Load an animation for the current avatar.\n@param animResource resource with the animation\n@param boneMap optional bone map to map animation skeleton to avatar", "Create a Build retention object out of the build\n\n@param build The build to create the build retention out of\n@param discardOldArtifacts Flag whether to discard artifacts of those builds that are to be discarded.\n@return a new Build retention", "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.", "The list of device types on which this application can run.", "Use this API to fetch ipset resource of given name .", "Ends the transition", "Use this API to add gslbsite resources." ]
public final TagConfiguration.Builder configureTag( Class<? extends Annotation> tagAnnotation ) { TagConfiguration configuration = new TagConfiguration( tagAnnotation ); tagConfigurations.put( tagAnnotation, configuration ); return new TagConfiguration.Builder( configuration ); }
[ "Configures the given annotation as a tag.\n\nThis is useful if you want to treat annotations as tags in JGiven that you cannot or want not\nto be annotated with the {@link com.tngtech.jgiven.annotation.IsTag} annotation.\n\n@param tagAnnotation the tag to be configured\n@return a configuration builder for configuring the tag" ]
[ "Provides a method that compares two comparables using Groovy's\ndefault number aware comparator.\n\n@param self a Comparable\n@param other another Comparable\n@return a -ve number, 0 or a +ve number according to Groovy's compareTo contract\n@since 1.6.0", "Adds OPT_N | OPT_NODE option to OptionParser, with multiple arguments.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional", "Use this API to fetch appfwpolicylabel_policybinding_binding resources of given name .", "Convenience method for first removing all enum style constants and then adding the single one.\n\n@see #removeEnumStyleNames(UIObject, Class)\n@see #addEnumStyleName(UIObject, Style.HasCssName)", "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", "Use this API to rename a responderpolicy resource.", "Un-serialize a Json into BuildInfo\n@param buildInfo String\n@return Map<String,String>\n@throws IOException", "URL-Decodes a given string using ISO-8859-1. No UnsupportedEncodingException to handle as it is dealt with in\nthis method.", "Adds one or several attributes to facet on for the next queries.\n\n@param attributes one or more attribute names.\n@return this {@link Searcher} for chaining." ]
public boolean isIdentical(T a, double tol) { if( a.getType() != getType() ) return false; return ops.isIdentical(mat,a.mat,tol); }
[ "Checks to see if matrix 'a' is the same as this matrix within the specified\ntolerance.\n\n@param a The matrix it is being compared against.\n@param tol How similar they must be to be equals.\n@return If they are equal within tolerance of each other." ]
[ "Returns the latest change events, and clears them from the change stream listener.\n\n@return the latest change events.", "This method retrieves the data at the given offset and returns\nit as a String, assuming the underlying data is composed of\nsingle byte characters.\n\n@param offset offset of required data\n@return string containing required data", "Use this API to disable Interface of given name.", "Create the index file that sets up the frameset.\n@param outputDirectory The target directory for the generated file(s).", "Writes OWL declarations for all basic vocabulary elements used in the\ndump.\n\n@throws RDFHandlerException", "Get the filters ImporterServiceFilter and ImportDeclarationFilter from the properties, stop the instance if one of.\nthem is invalid.", "Use this API to add sslocspresponder resources.", "Checks the day, month and year are equal.", "Simple info message for status\n\n@param tag Message to print out at start of info message" ]
public IPAddressSeqRange[] subtract(IPAddressSeqRange other) { IPAddress otherLower = other.getLower(); IPAddress otherUpper = other.getUpper(); IPAddress lower = this.getLower(); IPAddress upper = this.getUpper(); if(compareLowValues(lower, otherLower) < 0) { if(compareLowValues(upper, otherUpper) > 0) { // l ol ou u return createPair(lower, otherLower.increment(-1), otherUpper.increment(1), upper); } else { int comp = compareLowValues(upper, otherLower); if(comp < 0) { // l u ol ou return createSingle(); } else if(comp == 0) { // l u == ol ou return createSingle(lower, upper.increment(-1)); } return createSingle(lower, otherLower.increment(-1)); // l ol u ou } } else if(compareLowValues(otherUpper, upper) >= 0) { // ol l u ou return createEmpty(); } else { int comp = compareLowValues(otherUpper, lower); if(comp < 0) { return createSingle(); // ol ou l u } else if(comp == 0) { return createSingle(lower.increment(1), upper); //ol ou == l u } return createSingle(otherUpper.increment(1), upper); // ol l ou u } }
[ "Subtracts the given range from this range, to produce either zero, one, or two address ranges that contain the addresses in this range and not in the given range.\nIf the result has length 2, the two ranges are in increasing order.\n\n@param other\n@return" ]
[ "Gets the message payload.\n\n@param message the message\n@return the payload", "This produces the dotted hexadecimal format aaaa.bbbb.cccc", "Return the area polygon as the only feature in the feature collection.\n\n@param mapAttributes the attributes that this aoi is part of.", "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", "Logs all properties", "Gets the element view.\n\n@return the element view", "Creates a block matrix the same size as A_inv, inverts the matrix and copies the results back\nonto A_inv.\n\n@param A_inv Where the inverted matrix saved. Modified.", "Alternative implementation for the drift. For experimental purposes.\n\n@param timeIndex\n@param componentIndex\n@param realizationAtTimeIndex\n@param realizationPredictor\n@return", "end AnchorImplementation class" ]
public boolean projectExists(String name) throws IllegalArgumentException { if (name == null || name.isEmpty()) { throw new IllegalArgumentException("Project name cannot be empty"); } return listProjects().stream() .map(p -> p.getMetadata().getName()) .anyMatch(Predicate.isEqual(name)); }
[ "Checks if the given project exists or not.\n\n@param name project name\n@return true/false\n@throws IllegalArgumentException" ]
[ "Convenience method dispatches the specified event to the source appender,\nwhich will result in the custom event data being appended to the new file.\n\n@param customLoggingEvent\nThe custom Log4J event to be appended.", "Validates specialization if this bean specializes another bean.", "performs a SELECT operation against RDBMS.\n@param query the query string.\n@param cld ClassDescriptor providing JDBC information.", "Use this API to fetch filtered set of authenticationradiusaction resources.\nset the filter parameter values in filtervalue object.", "Retrieve list of resource extended attributes.\n\n@return list of extended attributes", "get the setter method corresponding to given property", "Acquire a calendar instance.\n\n@return Calendar instance", "Loads configuration from InputStream. Later loads have lower priority.\n\n@param in InputStream to load from\n@since 1.2.0", "Returns the configured page sizes, or the default page size if no core is configured.\n@return The configured page sizes, or the default page size if no core is configured." ]
public static String getVcsRevision(Map<String, String> env) { String revision = env.get("SVN_REVISION"); if (StringUtils.isBlank(revision)) { revision = env.get(GIT_COMMIT); } if (StringUtils.isBlank(revision)) { revision = env.get("P4_CHANGELIST"); } return revision; }
[ "Get the VCS revision from the Jenkins build environment. The search will one of \"SVN_REVISION\", \"GIT_COMMIT\",\n\"P4_CHANGELIST\" in the environment.\n\n@param env Th Jenkins build environment.\n@return The vcs revision for supported VCS" ]
[ "Find a Constructor on the given type that matches the given arguments.\n\n@param <T> the object type\n@param clazz\nthe type to create\n@param args\nthe arguments to the constructor\n@return a Constructor from the given type that matches the given\narguments\n@throws NoSuchConstructorException\nif there is not a constructor that matches the given\narguments\n@throws AmbiguousConstructorException\nif there is more than one constructor that matches the given\narguments", "Returns the configured request parameter for the query string, or the default parameter if no core is configured.\n@return The configured request parameter for the query string, or the default parameter if no core is configured.", "Checks that excess arguments match the vararg signature parameter.\n@param params\n@param args\n@return -1 if no match, 0 if all arguments matches the vararg type and >0 if one or more vararg argument is\nassignable to the vararg type, but still not an exact match", "Replaces each substring of this CharSequence that matches the given\nregular expression with the given replacement.\n\n@param self a CharSequence\n@param regex the capturing regex\n@param replacement the string to be substituted for each match\n@return the toString() of the CharSequence with content replaced\n@throws java.util.regex.PatternSyntaxException if the regular expression's syntax is invalid\n@see String#replaceAll(String, String)\n@since 1.8.2", "Get an extent aware Iterator based on the ReportQuery\n\n@param query\n@param cld\n@return OJBIterator", "Remove all of the audio sources from the audio manager.\nThis will stop all sound from playing.", "If a and b are not null, returns a new duration of a + b.\nIf a is null and b is not null, returns b.\nIf a is not null and b is null, returns a.\nIf a and b are null, returns null.\nIf needed, b is converted to a's time unit using the project properties.\n\n@param a first duration\n@param b second duration\n@param defaults project properties containing default values\n@return a + b", "Use this API to fetch nstrafficdomain_bridgegroup_binding resources of given name .", "Configures the player whose current track waveforms and status will automatically be reflected. Whenever a new\ntrack is loaded on that player, the waveform and metadata will be updated, and the current playback position and\nstate of the player will be reflected by the component.\n\n@param player the player number to monitor, or zero if monitoring should stop" ]
protected void statusInfoMessage(final String tag) { if(logger.isInfoEnabled()) { logger.info(tag + " : [partition: " + currentPartition + ", partitionFetched: " + currentPartitionFetched + "] for store " + storageEngine.getName()); } }
[ "Simple info message for status\n\n@param tag Message to print out at start of info message" ]
[ "Use this API to Import application.", "Retrieve a list of the available P3 project names from a directory.\n\n@param directory directory containing P3 files\n@return list of project names", "Use this API to fetch the statistics of all cmppolicy_stats resources that are configured on netscaler.", "Sets the matrix 'inv' equal to the inverse of the matrix that was decomposed.\n\n@param inv Where the value of the inverse will be stored. Modified.", "Returns the output directory for reporting.", "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", "Start pushing the element off to the right.", "Use this API to fetch sslocspresponder resource of given name .", "Create the grid feature type.\n\n@param mapContext the map context containing the information about the map the grid will be\nadded to.\n@param geomClass the geometry type" ]
private void appendJoinSQL92(Join join, StringBuffer where, StringBuffer buf) { if (join.isOuter) { buf.append(" LEFT OUTER JOIN "); } else { buf.append(" INNER JOIN "); } if (join.right.hasJoins()) { buf.append("("); appendTableWithJoins(join.right, where, buf); buf.append(")"); } else { appendTableWithJoins(join.right, where, buf); } buf.append(" ON "); join.appendJoinEqualities(buf); }
[ "Append Join for SQL92 Syntax" ]
[ "Wraps a StatisticsMatrix around 'm'. Does NOT create a copy of 'm' but saves a reference\nto it.", "Get a value from a multiselect metadata field.\n@param path the key path in the metadata object. Must be prefixed with a \"/\".\n@return the list of values set in the field.", "Return the item view type used by the adapter to implement recycle mechanism.\n\n@param content to be rendered.\n@return an integer that represents the renderer inside the adapter.", "Use this API to disable nsacl6 resources of given names.", "Returns the compact records for all attachments on the task.\n\n@param task Globally unique identifier for the task.\n@return Request object", "Get a log file and last relevant date, and check if the log file is relevant\n@param currentLogFile The log file\n@param lastRelevantDate The last date which files should be keeping since\n@return false if the file should be deleted, true if it does not.", "Read an optional Date value form a JSON value.\n@param val the JSON value that should represent the Date as long value in a string.\n@return the Date from the JSON or null if reading the date fails.", "Add a shutdown listener, which gets called when all requests completed on shutdown.\n\n@param listener the shutdown listener", "Function to perform forward softmax" ]
public PatchingResult rollbackLast(final ContentVerificationPolicy contentPolicy, final boolean resetConfiguration, InstallationManager.InstallationModification modification) throws PatchingException { // Determine the patch id to rollback String patchId; final List<String> oneOffs = modification.getPatchIDs(); if (oneOffs.isEmpty()) { patchId = modification.getCumulativePatchID(); if (patchId == null || Constants.NOT_PATCHED.equals(patchId)) { throw PatchLogger.ROOT_LOGGER.noPatchesApplied(); } } else { patchId = oneOffs.get(0);//oneOffs.get(oneOffs.size() - 1); } return rollbackPatch(patchId, contentPolicy, false, resetConfiguration, modification); }
[ "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" ]
[ "Use this API to fetch all the snmpmanager resources that are configured on netscaler.", "If there are any observer methods, they must be static or business\nmethods.", "Append the WHERE part of the statement to the StringBuilder.", "Solve the using the lower triangular matrix in LU. Diagonal elements are assumed\nto be 1", "Calculate the name of the output value.\n\n@param outputPrefix a nullable prefix to prepend to the name if non-null and non-empty\n@param outputMapper the name mapper\n@param field the field containing the value", "Check that an array only contains null elements.\n@param values, can't be null\n@return", "Add a date with a certain check state.\n@param date the date to add.\n@param checkState the check state.", "Returns an iterator that iterates over all elements greater or equal to key in ascending order\n\n@param key key\n@return iterator", "Feeds input stream to data consumer using metadata from tar entry.\n@param consumer the consumer\n@param inputStream the stream to feed\n@param entry the entry to use for metadata\n@throws IOException on consume error" ]
private int collectCandidates(Map<Long, Score> candidates, List<Bucket> buckets, int threshold) { int ix; for (ix = 0; ix < threshold && candidates.size() < (CUTOFF_FACTOR_1 * max_search_hits); ix++) { Bucket b = buckets.get(ix); long[] ids = b.records; double score = b.getScore(); for (int ix2 = 0; ix2 < b.nextfree; ix2++) { Score s = candidates.get(ids[ix2]); if (s == null) { s = new Score(ids[ix2]); candidates.put(ids[ix2], s); } s.score += score; } if (DEBUG) System.out.println("Bucket " + b.nextfree + " -> " + candidates.size()); } return ix; }
[ "Goes through the first buckets, picking out candidate records and\ntallying up their scores.\n@return the index of the first bucket we did not process" ]
[ "Checks if two parameterized types are exactly equal, under the variable\nreplacement described in the typeVarMap.", "Retrieves and validates the content length from the REST request.\n\n@return true if has content length", "Encode a path in a manner suitable for a GET request\n@param in The path to encode, eg \"a/document\"\n@return The encoded path eg \"a%2Fdocument\"", "Specifies the ARM resource id of the user assigned managed service identity resource that\nshould be used to retrieve the access token.\n\n@param identityId the ARM resource id of the user assigned identity resource\n@return MSICredentials", "Compares the two comma-separated lists.\n\n@param list1 The first list\n@param list2 The second list\n@return <code>true</code> if the lists are equal", "The max possible width can be calculated doing the sum of of the inner cells and its totals\n@param crosstabColumn\n@return", "get the real data without message header\n@return message data(without header)", "Will make the thread ready to run once again after it has stopped.", "Finds the most recent dump of the given type that is actually available.\n\n@param dumpContentType\nthe type of the dump to look for\n@return most recent main dump or null if no such dump exists" ]
private void fillWeekPanel() { addCheckBox(WeekOfMonth.FIRST.toString(), Messages.GUI_SERIALDATE_WEEKDAYNUMBER_1_0); addCheckBox(WeekOfMonth.SECOND.toString(), Messages.GUI_SERIALDATE_WEEKDAYNUMBER_2_0); addCheckBox(WeekOfMonth.THIRD.toString(), Messages.GUI_SERIALDATE_WEEKDAYNUMBER_3_0); addCheckBox(WeekOfMonth.FOURTH.toString(), Messages.GUI_SERIALDATE_WEEKDAYNUMBER_4_0); addCheckBox(WeekOfMonth.LAST.toString(), Messages.GUI_SERIALDATE_WEEKDAYNUMBER_5_0); }
[ "Fills the week panel with checkboxes." ]
[ "Handles the response of the getVersion request.\n@param incomingMessage the response message to process.", "Function to delete the specified store from Metadata store. This involves\n\n1. Remove entry from the ConfigurationStorageEngine for STORES.\n\n2. Update the metadata cache.\n\n3. Re-create the 'stores.xml' key\n\n@param storeName specifies name of the store to be deleted.", "Updates the polling state from a DELETE or POST operation.\n\n@param response the response from Retrofit REST call\n@throws IOException thrown by deserialization", "Gets the i-th half-edge associated with the face.\n\n@param i\nthe half-edge index, in the range 0-2.\n@return the half-edge", "Use this API to unset the properties of responderparam resource.\nProperties that need to be unset are specified in args array.", "Non-zero counts of Householder vectors and computes a permutation\nmatrix that ensures diagonal entires are all structurally nonzero.\n\n@param parent elimination tree\n@param ll linked list for each row that specifies elements that are not zero", "Wrap PreparedStatement with a proxy.\n@param target statement handle\n@param connectionHandle originating bonecp connection\n@return Proxy to a Preparedstatement.", "Removes metadata related to rebalancing.\n\n@param adminClient An instance of AdminClient points to given cluster\n@param nodeIds Node ids to clear metadata after rebalancing", "Add a property with the given name and the given list of values to this Properties object. Name\nand values are trimmed before the property is added.\n\n@param name the name of the property, must not be <code>null</code>.\n@param values the values of the property, must no be <code>null</code>,\nnone of the values must be <code>null</code>" ]
private void validateAsMongoDBFieldName(String fieldName) { if ( fieldName.startsWith( "$" ) ) { throw log.fieldNameHasInvalidDollarPrefix( fieldName ); } else if ( fieldName.contains( "\u0000" ) ) { throw log.fieldNameContainsNULCharacter( fieldName ); } }
[ "Validates a String to be a valid name to be used in MongoDB for a field name.\n\n@param fieldName" ]
[ "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", "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", "Recursively construct a LblTree from DOM tree\n\n@param walker tree walker for DOM tree traversal\n@return tree represented by DOM tree", "Try to unlink the declaration from the importerService referenced by the ServiceReference,.\nreturn true if they have been cleanly unlink, false otherwise.\n\n@param declaration The Declaration\n@param declarationBinderRef The ServiceReference of the ImporterService\n@return true if they have been cleanly unlink, false otherwise.", "Reads a markdown link ID.\n\n@param out\nThe StringBuilder to write to.\n@param in\nInput String.\n@param start\nStarting position.\n@return The new position or -1 if this is no valid markdown link ID.", "Process an update packet from one of the CDJs. See if it has a valid track loaded; if not, clear any\nmetadata we had stored for that player. If so, see if it is the same track we already know about; if not,\nrequest the metadata associated with that track.\n\nAlso clears out any metadata caches that were attached for slots that no longer have media mounted in them,\nand updates the sets of which players have media mounted in which slots.\n\nIf any of these reflect a change in state, any registered listeners will be informed.\n\n@param update an update packet we received from a CDJ", "calculate the difference of the two maps, so we know what was added, removed & updated\n@param left\n@param right\n@param onlyOnLeft\n@param onlyOnRight\n@param updated", "Returns the cost rate table index for this assignment.\n\n@return cost rate table index", "Utility method to retrieve the next working date start 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 next work start" ]
@SuppressWarnings("unchecked") private boolean isFieldPopulated(Task task, TaskField field) { boolean result = false; if (field != null) { Object value = task.getCachedValue(field); switch (field) { case PREDECESSORS: case SUCCESSORS: { result = value != null && !((List<Relation>) value).isEmpty(); break; } default: { result = value != null; break; } } } return result; }
[ "Determine if a task field contains data.\n\n@param task task instance\n@param field target field\n@return true if the field contains data" ]
[ "Use this API to count bridgegroup_vlan_binding resources configued on NetScaler.", "Process a SQLite database PP file.\n\n@param inputStream file input stream\n@return ProjectFile instance", "All the attributes needed either by the processors for each datasource row or by the jasper template.\n\n@param attributes the attributes.", "Helper method to check that we got the right size packet.\n\n@param packet a packet that has been received\n@param expectedLength the number of bytes we expect it to contain\n@param name the description of the packet in case we need to report issues with the length\n\n@return {@code true} if enough bytes were received to process the packet", "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.", "Returns the connection count by key specified in this registry\n\nNote it might count connections that are closed but not removed from registry yet\n\n@param key\nthe key\n@return connection count by key", "Apply the AAD algorithm to this very variable\n\nNOTE: in this case it is indeed correct to assume that the output dimension is \"one\"\nmeaning that there is only one {@link RandomVariableUniqueVariable} as an output.\n\n@return gradient for the built up function", "Get a writer implementation to push data into Canvas.\n@param type Interface type you wish to get an implementation for\n@param oauthToken An OAuth token to use for authentication when making API calls\n@param <T> A writer implementation\n@return A writer implementation class", "Implement the persistence handler for storing the user properties." ]
public void setPlaying(boolean playing) { if (this.playing.get() == playing) { return; } this.playing.set(playing); if (playing) { metronome.jumpToBeat(whereStopped.get().getBeat()); if (isSendingStatus()) { // Need to also start the beat sender. beatSender.set(new BeatSender(metronome)); } } else { final BeatSender activeSender = beatSender.get(); if (activeSender != null) { // We have a beat sender we need to stop. activeSender.shutDown(); beatSender.set(null); } whereStopped.set(metronome.getSnapshot()); } }
[ "Controls whether we report that we are playing. This will only have an impact when we are sending status and\nbeat packets.\n\n@param playing {@code true} if we should seem to be playing" ]
[ "Get a collection of Photo objects for the specified Photoset.\n\nThis method does not require authentication.\n\n@see com.flickr4java.flickr.photos.Extras\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_NO_FILTER\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_PUBLIC\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FRIENDS\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FRIENDS_FAMILY\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FAMILY\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FRIENDS\n@param photosetId\nThe photoset ID\n@param extras\nSet of extra-fields\n@param privacy_filter\nfilter value for authenticated calls\n@param perPage\nThe number of photos per page\n@param page\nThe page offset\n@return PhotoList The Collection of Photo objects\n@throws FlickrException", "Use this API to change responderhtmlpage.", "Creates metadata on this file in the specified template type.\n\n@param typeName the metadata template type name.\n@param metadata the new metadata values.\n@return the metadata returned from the server.", "Register custom filter types especially for serializer of specification json file", "Extract data for a single resource assignment.\n\n@param task parent task\n@param row Synchro resource assignment", "Loads the given class, respecting the given classloader.\n@param clazz class to load\n@return Loaded class\n@throws ClassNotFoundException", "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", "Assigns retention policy with givenID to the folder.\n@param api the API connection to be used by the created assignment.\n@param policyID id of the assigned retention policy.\n@param folderID id of the folder to assign policy to.\n@return info about created assignment.", "All tests completed." ]
@Override public boolean accept(File file) { //All directories are added in the least that can be read by the Application if (file.isDirectory()&&file.canRead()) { return true; } else if(properties.selection_type==DialogConfigs.DIR_SELECT) { /* True for files, If the selection type is Directory type, ie. * Only directory has to be selected from the list, then all files are * ignored. */ return false; } else { /* Check whether name of the file ends with the extension. Added if it * does. */ String name = file.getName().toLowerCase(Locale.getDefault()); for (String ext : validExtensions) { if (name.endsWith(ext)) { return true; } } } return false; }
[ "Function to filter files based on defined rules." ]
[ "Locates the services in the context classloader of the current thread.\n\n@param serviceType the type of the services to locate\n@param <X> the type of the service\n@return the service type loader", "Read the data for all of the tables we're interested in.\n\n@param tables list of all available tables\n@param is input stream", "Processes graphical indicator definitions for each column.", "Returns the key for the best matching local-specific property version.\n\n@param propertiesMap the \"raw\" property map\n@param key the name of the property to search for\n@param locale the locale to search for\n\n@return the key for the best matching local-specific property version.", "convenience factory method for the most usual case.", "Set the week of month.\n@param weekOfMonthStr the week of month to set.", "Get a property as a int or null.\n\n@param key the property name", "Unregister all servlets registered by this exporter.", "Get a list of referrers from a given domain to a photo.\n\n@param date\n(Required) Stats will be returned for this date. A day according to Flickr Stats starts at midnight GMT for all users, and timestamps will\nautomatically be rounded down to the start of the day.\n@param domain\n(Required) The domain to return referrers for. This should be a hostname (eg: \"flickr.com\") with no protocol or pathname.\n@param photoId\n(Optional) The id of the photo to get stats for. If not provided, stats for all photos will be returned.\n@param perPage\n(Optional) Number of domains to return per page. If this argument is omitted, it defaults to 25. The maximum allowed value is 100.\n@param page\n(Optional) The page of results to return. If this argument is omitted, it defaults to 1.\n@see \"http://www.flickr.com/services/api/flickr.stats.getPhotoReferrers.html\"" ]
public void lock(Object obj, int lockMode) throws LockNotGrantedException { if (log.isDebugEnabled()) log.debug("lock object was called on tx " + this + ", object is " + obj.toString()); checkOpen(); RuntimeObject rtObject = new RuntimeObject(obj, this); lockAndRegister(rtObject, lockMode, isImplicitLocking(), getRegistrationList()); // if(isImplicitLocking()) moveToLastInOrderList(rtObject.getIdentity()); }
[ "Upgrade the lock on the given object to the given lock mode. The call has\nno effect if the object's current lock is already at or above that level of\nlock mode.\n\n@param obj object to acquire a lock on.\n@param lockMode lock mode to acquire. The lock modes\nare <code>READ</code> , <code>UPGRADE</code> , and <code>WRITE</code> .\n\n@exception LockNotGrantedException Description of Exception" ]
[ "Checks that native primarykey fields have readonly access, and warns if not.\n\n@param fieldDef The field descriptor\n@param checkLevel The current check level (this constraint is checked in basic and strict)", "Determines if this connection's access token has expired and needs to be refreshed.\n@return true if the access token needs to be refreshed; otherwise false.", "Return the raw source line corresponding to the specified AST node\n\n@param node - the Groovy AST node", "Get the cached ETag for the given host and file\n@param host the host\n@param file the file\n@return the cached ETag or null if there is no ETag in the cache", "Ensures that the given collection descriptor has a valid element-class-ref property.\n\n@param collDef The collection descriptor\n@param checkLevel The current check level (this constraint is checked in basic and strict)\n@exception ConstraintException If element-class-ref could not be determined or is invalid", "Generate a Jongo query regarding a set of parameters.\n\n@param params Map<queryKey, queryValue> of query parameters\n@return String", "Return the class of one of the properties of another class from which the Hibernate metadata is given.\n\n@param meta\nThe parent class to search a property in.\n@param propertyName\nThe name of the property in the parent class (provided by meta)\n@return Returns the class of the property in question.\n@throws HibernateLayerException\nThrows an exception if the property name could not be retrieved.", "Set a knot type.\n@param n the knot index\n@param type the type\n@see #getKnotType", "Either a single file extension or a comma-separated list of extensions for which the language\nshall be registered." ]
public Weld addExtension(Extension extension) { extensions.add(new MetadataImpl<Extension>(extension, SYNTHETIC_LOCATION_PREFIX + extension.getClass().getName())); return this; }
[ "Add an extension to the set of extensions.\n\n@param extension an extension" ]
[ "Assigns the provided square matrix to be a random Hermitian matrix with elements from min to max value.\n\n@param A The matrix that is to be modified. Must be square. Modified.\n@param min Minimum value an element can have.\n@param max Maximum value an element can have.\n@param rand Random number generator.", "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", "Creates the automata.\n\n@param prefix the prefix\n@param regexp the regexp\n@param automatonMap the automaton map\n@return the list\n@throws IOException Signals that an I/O exception has occurred.", "Get the group URL for the specified group ID\n\n@param groupId\nThe group ID\n@return The group URL\n@throws FlickrException", "Internal method used to retrieve a byte array from one\nor more embedded data blocks. Consecutive data blocks may\nneed to be concatenated by this method in order to retrieve\nthe complete set of data.\n\n@param blocks list of data blocks\n@param length expected length of the data\n@return byte array", "Should only called on a column that is being set to null.\n\nReturns the most outer embeddable containing {@code column} that is entirely null.\nReturn null otherwise i.e. not embeddable.\n\nThe implementation lazily compute the embeddable state and caches it.\nThe idea behind the lazy computation is that only some columns will be set to null\nand only in some situations.\nThe idea behind caching is that an embeddable contains several columns, no need to recompute its state.", "Configures a RequestBuilder to send an RPC request.\n\n@param <T> return type for the AsyncCallback\n@param responseReader instance used to read the return value of the\ninvocation\n@param requestData payload that encodes the addressing and arguments of the\nRPC call\n@param callback callback handler\n\n@return a RequestBuilder object that is ready to have its\n{@link RequestBuilder#send()} method invoked.", "Deploys application reading resources from specified InputStream\n\n@param inputStream where resources are read\n@throws IOException", "helper to calculate the navigationBar height\n\n@param context\n@return" ]
public void addChildTask(Task child) { child.m_parent = this; m_children.add(child); setSummary(true); if (getParentFile().getProjectConfig().getAutoOutlineLevel() == true) { child.setOutlineLevel(Integer.valueOf(NumberHelper.getInt(getOutlineLevel()) + 1)); } }
[ "This method is used to associate a child task with the current\ntask instance. It has been designed to\nallow the hierarchical outline structure of tasks in an MPX\nfile to be updated once all of the task data has been read.\n\n@param child child task" ]
[ "touch event without ripple support", "Renders a given graphic into a new image, scaled to fit the new size and rotated.", "Read the relationships for an individual GanttProject task.\n\n@param gpTask GanttProject task", "Returns the result of calling a closure with the first occurrence of a regular expression found within a CharSequence.\nIf the regex doesn't match, the closure will not be called and find will return null.\n\n@param self a CharSequence\n@param regex the capturing regex CharSequence\n@param closure the closure that will be passed the full match, plus each of the capturing groups (if any)\n@return a String containing the result of calling the closure (calling toString() if needed), or null if the regex pattern doesn't match\n@see #find(String, java.util.regex.Pattern, groovy.lang.Closure)\n@since 1.8.2", "Removes all the given tags from the document.\n\n@param dom the document object.\n@param tagName the tag name, examples: script, style, meta\n@return the changed dom.", "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>.", "Create a style from a list of rules.\n\n@param styleRules the rules", "Transforms each character from this reader by passing it to the given\nclosure. The Closure should return each transformed character, which\nwill be passed to the Writer. The reader and writer will be both be\nclosed before this method returns.\n\n@param self a Reader object\n@param writer a Writer to receive the transformed characters\n@param closure a closure that performs the required transformation\n@throws IOException if an IOException occurs.\n@since 1.5.0", "alert, prompt, and confirm behave as if the OK button is always clicked." ]
public static ZMatrixRMaj householderVector(ZMatrixRMaj x ) { ZMatrixRMaj u = x.copy(); double max = CommonOps_ZDRM.elementMaxAbs(u); CommonOps_ZDRM.elementDivide(u, max, 0, u); double nx = NormOps_ZDRM.normF(u); Complex_F64 c = new Complex_F64(); u.get(0,0,c); double realTau,imagTau; if( c.getMagnitude() == 0 ) { realTau = nx; imagTau = 0; } else { realTau = c.real/c.getMagnitude()*nx; imagTau = c.imaginary/c.getMagnitude()*nx; } u.set(0,0,c.real + realTau,c.imaginary + imagTau); CommonOps_ZDRM.elementDivide(u,u.getReal(0,0),u.getImag(0,0),u); return u; }
[ "Computes the householder vector used in QR decomposition.\n\nu = x / max(x)\nu(0) = u(0) + |u|\nu = u / u(0)\n\n@param x Input vector. Unmodified.\n@return The found householder reflector vector" ]
[ "Update artifact provider\n\n@param gavc String\n@param provider String", "Get the class name without the package\n\n@param c The class name with package\n@return the class name without the package", "helper to calculate the navigationBar height\n\n@param context\n@return", "Creates a copy of a matrix but swaps the rows as specified by the order array.\n\n@param order Specifies which row in the dest corresponds to a row in the src. Not modified.\n@param src The original matrix. Not modified.\n@param dst A Matrix that is a row swapped copy of src. Modified.", "Maps all views that don't start with \"android\" namespace.\n\n@param names All shared element names.\n@return The obsolete shared element names.", "Adds an item to the list box, specifying an initial value for the item.\n\n@param value the item's value, to be submitted if it is part of a\n{@link FormPanel}; cannot be <code>null</code>\n@param text the text of the item to be added\n@param reload perform a 'material select' reload to update the DOM.", "Process the requestJsonAttributes using the attributes and the MapfishParser and add all resulting\nvalues to this values object.\n\n@param template the template of the current request.\n@param attributes the attributes that will be used to add values to this values object\n@param requestJsonAttributes the json data for populating the attribute values", "Installs a remoting stream server for a domain instance\n@param serviceTarget the service target to install the services into\n@param endpointName the name of the endpoint to install the stream server into\n@param networkInterfaceBinding the network interface binding\n@param port the port\n@param securityRealm the security real name\n@param options the remoting options", "Sets the RegExp pattern for the TextBox\n@param pattern\n@param invalidCharactersInNameErrorMessage" ]
public X509Certificate getMappedCertificateForHostname(String hostname) throws CertificateParsingException, InvalidKeyException, CertificateExpiredException, CertificateNotYetValidException, SignatureException, CertificateException, NoSuchAlgorithmException, NoSuchProviderException, KeyStoreException, UnrecoverableKeyException { String subject = getSubjectForHostname(hostname); String thumbprint = _subjectMap.get(subject); if(thumbprint == null) { KeyPair kp = getRSAKeyPair(); X509Certificate newCert = CertificateCreator.generateStdSSLServerCertificate(kp.getPublic(), getSigningCert(), getSigningPrivateKey(), subject); addCertAndPrivateKey(hostname, newCert, kp.getPrivate()); thumbprint = ThumbprintUtil.getThumbprint(newCert); _subjectMap.put(subject, thumbprint); if(persistImmediately) { persist(); } return newCert; } return getCertificateByAlias(thumbprint); }
[ "This method returns the mapped certificate for a hostname, or generates a \"standard\"\nSSL server certificate issued by the CA to the supplied subject if no mapping has been\ncreated. This is not a true duplication, just a shortcut method\nthat is adequate for web browsers.\n\n@param hostname\n@return\n@throws CertificateParsingException\n@throws InvalidKeyException\n@throws CertificateExpiredException\n@throws CertificateNotYetValidException\n@throws SignatureException\n@throws CertificateException\n@throws NoSuchAlgorithmException\n@throws NoSuchProviderException\n@throws KeyStoreException\n@throws UnrecoverableKeyException" ]
[ "Returns a list of the compact representation of all of the custom fields in a workspace.\n\n@param workspace The workspace or organization to find custom field definitions in.\n@return Request object", "Search for rectangles which have the same width and x position, and\nwhich join together vertically and merge them together to reduce the\nnumber of rectangles needed to describe a symbol.", "Performs the filtering of the expired entries based on retention time.\nOptionally, deletes them also\n\n@param key the key whose value is to be deleted if needed\n@param vals set of values to be filtered out\n@return filtered list of values which are currently valid", "This method changes the value of an agent's belief through its external\naccess\n\n@param agent_name\nThe name of the agent to change a belief\n@param belief_name\nThe name of the belief to change\n@param new_value\nThe new value of the belief to be changed\n@param connector\nThe connector to get the external access", "The third method to write caseManager. Its task is to write the call to\nthe story to be run.\n\n@param caseManager\nthe file where the test must be written\n@param storyName\nthe name of the story\n@param test_path\nthe path where the story can be found\n@param user\nthe user requesting the story\n@param feature\nthe feature requested by the user\n@param benefit\nthe benefit provided by the feature\n@throws BeastException", "Add the string representation of the given object to this sequence. The given indentation will be prepended to\neach line except the first one if the object has a multi-line string representation.\n\n@param object\nthe appended object.\n@param indentation\nthe indentation string that should be prepended. May not be <code>null</code>.", "Count the number of working hours in a day, based in the\ninteger representation of the working hours.\n\n@param hours working hours\n@return number of hours", "Show a toast-like message for the specified duration\n\n@param message\n@param duration in seconds", "Return the par FRA rate for a given curve.\n\n@param model A given model.\n@return The par FRA rate." ]
private int[] changeColor() { int[] changedPixels = new int[pixels.length]; double frequenz = 2 * Math.PI / 1020; for (int i = 0; i < pixels.length; i++) { int argb = pixels[i]; int a = (argb >> 24) & 0xff; int r = (argb >> 16) & 0xff; int g = (argb >> 8) & 0xff; int b = argb & 0xff; r = (int) (255 * Math.sin(frequenz * r)); b = (int) (-255 * Math.cos(frequenz * b) + 255); changedPixels[i] = (a << 24) | (r << 16) | (g << 8) | b; } return changedPixels; }
[ "changes the color of the image - more red and less blue\n\n@return new pixel array" ]
[ "Handler for week of month changes.\n@param event the change event.", "Set an outline code value.\n\n@param index outline code index (1-10)\n@param value outline code value", "Obtain a connection asynchronously by queueing a request to obtain a connection in a separate thread.\n\nUse as follows:<p>\nFuture&lt;Connection&gt; result = pool.getAsyncConnection();<p>\n... do something else in your application here ...<p>\nConnection connection = result.get(); // get the connection<p>\n\n@return A Future task returning a connection.", "Iterates through this file line by line, splitting each line using\nthe given regex separator. For each line, the given closure is called with\na single parameter being the list of strings computed by splitting the line\naround matches of the given regular expression.\nFinally the resources used for processing the file are closed.\n\n@param self a File\n@param regex the delimiting regular expression\n@param closure a closure\n@return the last value returned by the closure\n@throws IOException if an IOException occurs.\n@throws java.util.regex.PatternSyntaxException\nif the regular expression's syntax is invalid\n@see IOGroovyMethods#splitEachLine(java.io.Reader, java.lang.String, groovy.lang.Closure)\n@since 1.5.5", "Use this API to create sslfipskey.", "Check if the given color string can be parsed.\n\n@param colorString The color to parse.", "Return a list of contacts for a user who have recently uploaded photos along with the total count of photos uploaded.\n\n@param lastUpload\nLimits the resultset to contacts that have uploaded photos since this date. The date should be in the form of a Unix timestamp. The default,\nand maximum, offset is (1) hour. (Optional, can be null)\n@param filter\nLimit the result set to all contacts or only those who are friends or family.<br/>\nValid options are: <b>ff</b> -&gt; friends and family, <b>all</b> -&gt; all your contacts. (Optional, can be null)\n\n@return List of Contacts\n@throws FlickrException", "Get all the names of inputs that are required to be in the Values object when this graph is executed.", "Function to perform forward pooling" ]
public Metadata add(String path, List<String> values) { JsonArray arr = new JsonArray(); for (String value : values) { arr.add(value); } this.values.add(this.pathToProperty(path), arr); this.addOp("add", path, arr); return this; }
[ "Adds a new metadata value of array type.\n@param path the path to the field.\n@param values the collection of values.\n@return the metadata object for chaining." ]
[ "Answer the SQL-Clause for a FieldCriteria\n\n@param c FieldCriteria\n@param cld ClassDescriptor", "Start with specifying the groupId", "A disposer method is bound to a producer if the producer is assignable to the disposed parameter.\n\n@param enhancedDisposedParameter\n@return the set of required qualifiers for the given disposed parameter", "Use this API to unset the properties of tmsessionparameter resource.\nProperties that need to be unset are specified in args array.", "Checks whether a built of the indices is necessary.\n@param cms The appropriate CmsObject instance.\n@return true, if the spellcheck indices have to be rebuilt, otherwise false", "It will look for all the deployments under the deploymentsRootAddress with a runtimeName in the specified list of\nruntime names and then transform the operation so that every server having those deployments will redeploy the\naffected deployments.\n\n@see #transformOperation\n@param removeOperation\n@param context\n@param deploymentsRootAddress\n@param runtimeNames\n@throws OperationFailedException", "Select item by it's position\n\n@param position int value of item position to select\n@param invokeListeners boolean value for invoking listeners", "Apply aliases to task and resource fields.\n\n@param aliases map of aliases", "Reports that a node is resolved hence other nodes depends on it can consume it.\n\n@param completed the node ready to be consumed" ]
private boolean isAllNumeric(TokenStream stream) { List<Token> tokens = ((NattyTokenSource) stream.getTokenSource()).getTokens(); for(Token token:tokens) { try { Integer.parseInt(token.getText()); } catch(NumberFormatException e) { return false; } } return true; }
[ "Determines if a token stream contains only numeric tokens\n@param stream\n@return true if all tokens in the given stream can be parsed as an integer" ]
[ "Put the core auto-code algorithm here so an external class can call it", "Replace a single value at the appropriate location in the existing value array.\n@param index - location in the array list\n@param newValue - the new String", "Creates a polling state.\n\n@param response the response from Retrofit REST call that initiate the long running operation.\n@param lroOptions long running operation options.\n@param defaultRetryTimeout the long running operation retry timeout.\n@param resourceType the type of the resource the long running operation returns\n@param serializerAdapter the adapter for the Jackson object mapper\n@param <T> the result type\n@return the polling state\n@throws IOException thrown by deserialization", "Enable a custom response\n\n@param custom custom response\n@param path_id path ID of the response\n@param client_uuid client UUID\n@throws Exception exception", "Set a bean in the context.\n\n@param name bean name\n@param object bean value", "Dump data for all non-summary tasks to stdout.\n\n@param name file name", "Print the common class node's properties", "Use this API to fetch all the nsspparams resources that are configured on netscaler.", "Check that the range resulting from the mask is contiguous, otherwise we cannot represent it.\n\nFor instance, for the range 0 to 3 (bits are 00 to 11), if we mask all 4 numbers from 0 to 3 with 2 (ie bits are 10),\nthen we are left with 1 and 3. 2 is not included. So we cannot represent 1 and 3 as a contiguous range.\n\nThe underlying rule is that mask bits that are 0 must be above the resulting range in each segment.\n\nAny bit in the mask that is 0 must not fall below any bit in the masked segment range that is different between low and high.\n\nAny network mask must eliminate the entire segment range. Any host mask is fine.\n\n@param maskValue\n@param segmentPrefixLength\n@return\n@throws PrefixLenException" ]
public static void skip(InputStream stream, long skip) throws IOException { long count = skip; while (count > 0) { count -= stream.skip(count); } }
[ "The documentation for InputStream.skip indicates that it can bail out early, and not skip\nthe requested number of bytes. I've encountered this in practice, hence this helper method.\n\n@param stream InputStream instance\n@param skip number of bytes to skip" ]
[ "The amount of time to keep an idle client thread alive\n\n@param threadIdleTime", "Parse a list of objects from a JsonParser.\n\n@param jsonParser The JsonParser, preconfigured to be at the START_ARRAY token.", "Create a random permutation of the numbers 0, ..., size - 1.\n\nsee Algorithm P, D.E. Knuth: The Art of Computer Programming, Vol. 2, p. 145", "Mark content as obsolete. If content was already marked for obsolescenceTimeout ms then it is removed.\n\n@param ref the content refrence to be marked as obsolete.\n\n@return true if the content refrence is removed, fale otherwise.", "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.", "Check that the parameter array has exactly the right number of elements.\n\n@param parameterName\nThe name of the user-supplied parameter that we are validating\nso that the user can easily find the error in their code.\n@param actualLength\nThe actual array length\n@param expectedLength\nThe expected array length", "Get the column name from the indirection table.\n@param mnAlias\n@param path", "Adds a new Site matcher object to the map of server names.\n\n@param matcher the SiteMatcher of the server\n@param site the site to add", "Sets the upper limits for the \"moving\" body rotation relative to joint point.\n\n@param limitX the X axis upper rotation limit (in radians)\n@param limitY the Y axis upper rotation limit (in radians)\n@param limitZ the Z axis upper rotation limit (in radians)" ]
public static base_responses add(nitro_service client, clusternodegroup resources[]) throws Exception { base_responses result = null; if (resources != null && resources.length > 0) { clusternodegroup addresources[] = new clusternodegroup[resources.length]; for (int i=0;i<resources.length;i++){ addresources[i] = new clusternodegroup(); addresources[i].name = resources[i].name; addresources[i].strict = resources[i].strict; } result = add_bulk_request(client, addresources); } return result; }
[ "Use this API to add clusternodegroup resources." ]
[ "Marks inbox message as read for given messageId\n@param messageId String messageId\n@return boolean value depending on success of operation", "Use this API to fetch all the nsacl6 resources that are configured on netscaler.", "Read an exception day for a calendar.\n\n@param mpxjCalendar ProjectCalendar instance\n@param day ConceptDraw PROJECT exception day", "Unlock all edited resources.", "determine the what state a transaction is in by inspecting the primary column", "Determines whether the given list contains a descriptor with the same name.\n\n@param defs The list to search\n@param obj The object that is searched for\n@return <code>true</code> if the list contains a descriptor with the same name", "Register the given Converter objects with the given target ConverterRegistry.\n@param converters the converter objects: implementing {@link Converter},\n{@link ConverterFactory}, or {@link GenericConverter}\n@param registry the target registry", "If the specified value is not greater than or equal to the specified minimum and\nless than or equal to the specified maximum, adjust it so that it is.\n@param value The value to check.\n@param min The minimum permitted value.\n@param max The maximum permitted value.\n@return {@code value} if it is between the specified limits, {@code min} if the value\nis too low, or {@code max} if the value is too high.\n@since 1.2", "Runs a query that returns a single int." ]
private static String convertPathToResource(String path) { File file = new File(path); List<String> parts = new ArrayList<String>(); do { parts.add(file.getName()); file = file.getParentFile(); } while (file != null); StringBuffer sb = new StringBuffer(); int size = parts.size(); for (int a = size - 1; a >= 0; a--) { if (sb.length() > 0) { sb.append("_"); } sb.append(parts.get(a)); } // TODO: Better regex replacement return sb.toString().replace('-', '_').replace("+", "plus").toLowerCase(Locale.US); }
[ "Converts any path into something that can be placed in an Android directory.\n\nTraverses any subdirectories and flattens it all into a single filename. Also\ngets rid of commonly seen illegal characters in tz identifiers, and lower cases\nthe entire thing.\n\n@param path the path to convert\n@return a flat path with no directories (and lower-cased)" ]
[ "Update the selection state of the item\n@param dataIndex data set index\n@param select if it is true the item is marked as selected, otherwise - unselected\n@return true if the selection state has been changed successfully, otherwise - false", "Was the CDJ playing a track when this update was sent?\n\n@return true if the play flag was set, or, if this seems to be a non-nexus player, if <em>P<sub>1</sub></em>\nhas a value corresponding to a playing state.", "A callback that handles requestComplete event from NIO selector manager\nWill try any possible nodes and pass itself as callback util all nodes\nare exhausted\n\n@param slopKey\n@param slopVersioned\n@param nodesToTry List of nodes to try to contact. Will become shorter\nafter each callback", "Helper method to check if log4j is already configured", "Sets the jdbc connection to use.\n\n@param jcd The connection to use\n@throws PlatformException If the target database cannot be handled with torque", "Creates a simple, annotation defined Enterprise Web Bean using the annotations specified on type\n\n@param <T> The type\n@param beanManager the current manager\n@param type the AnnotatedType to use\n@return An Enterprise Web Bean", "Calculates the size based constraint width and height if present, otherwise from children sizes.", "Get the Upper triangular factor.\n\n@return U.", "Waits for a job V3 to complete\n\n@param cloudFoundryClient the client to use to request job status\n@param completionTimeout the amount of time to wait for the job to complete.\n@param jobId the id of the job\n@return {@code onComplete} once job has completed" ]
private void deleteDir(File dir) { if (dir.exists() && dir.isDirectory()) { File[] files = dir.listFiles(); for (int idx = 0; idx < files.length; idx++) { if (!files[idx].exists()) { continue; } if (files[idx].isDirectory()) { deleteDir(files[idx]); } else { files[idx].delete(); } } dir.delete(); } }
[ "Little helper function that recursivly deletes a directory.\n\n@param dir The directory" ]
[ "Start a task. The id is needed to end the task\n\n@param id\n@param taskName", "Returns an Object array of all FK field values of the specified object.\nIf the specified object is an unmaterialized Proxy, it will be materialized\nto read the FK values.\n\n@throws MetadataException if an error occours while accessing ForeingKey values on obj", "Applies the given codec registry to be used alongside the default codec registry.\n\n@param codecRegistry the codec registry to merge in.\n@return an {@link StitchObjectMapper} with the merged codec registries.", "Bessel function of the first kind, of order n.\n\n@param n Order.\n@param x Value.\n@return I value.", "Reads a duration value. This method relies on the fact that\nthe units of the duration have been specified elsewhere.\n\n@param value Duration value\n@param type type of units of the duration\n@return Duration instance", "Say whether this character is an annotation introducing\ncharacter.\n\n@param ch The character to check\n@return Whether it is an annotation introducing character", "Writes and reads the XOP attachment using a CXF JAX-RS Proxy\nThe proxy automatically sets the \"mtom-enabled\" property by checking\nthe CXF EndpointProperty set on the XopAttachment interface.\n\n@throws Exception", "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", "Use this API to fetch all the policydataset resources that are configured on netscaler." ]
public static base_response add(nitro_service client, clusternodegroup resource) throws Exception { clusternodegroup addresource = new clusternodegroup(); addresource.name = resource.name; addresource.strict = resource.strict; return addresource.add_resource(client); }
[ "Use this API to add clusternodegroup." ]
[ "Determine which math transform to use when creating the coordinate of the label.\n\n@param mapCrs the crs of the map, used if the {@link #labelProjection} is not defined.", "Convert the Phoenix representation of a duration into a Duration instance.\n\n@param value Phoenix duration\n@return Duration instance", "Send message to all connections tagged with all given tags\n@param message the message\n@param labels the tag labels", "This method extracts project extended attribute data from an MSPDI file.\n\n@param project Root node of the MSPDI file", "Utility method to register a proxy has a Service in OSGi.", "Signal that this thread will not log any more messages in the multithreaded\nenvironment", "Extract the generic return type from the given method.\n@param method the method to check the return type for\n@param source the source class/interface defining the generic parameter types\n@param typeIndex the index of the type (e.g. 0 for Collections,\n0 for Map keys, 1 for Map values)\n@param nestingLevel the nesting level of the target type\n@return the generic type, or {@code null} if none", "Get prototype name.\n\n@return prototype name", "Add a list of enums to the options map\n@param key The key for the options map (ex: \"include[]\")\n@param list A list of enums" ]
public static base_response add(nitro_service client, responderpolicy resource) throws Exception { responderpolicy addresource = new responderpolicy(); addresource.name = resource.name; addresource.rule = resource.rule; addresource.action = resource.action; addresource.undefaction = resource.undefaction; addresource.comment = resource.comment; addresource.logaction = resource.logaction; addresource.appflowaction = resource.appflowaction; return addresource.add_resource(client); }
[ "Use this API to add responderpolicy." ]
[ "Log a byte array.\n\n@param label label text\n@param data byte array", "Print duration in tenths of minutes.\n\n@param duration Duration instance\n@return duration in tenths of minutes", "Translates the Fluo row, column, and value set into the persistent format that is stored in\nAccumulo.\n\n<p>\nThe objects returned by this method are reused each time its called. So each time this is\ncalled it invalidates what was returned by previous calls to this method.\n\n@return A an array of Accumulo key values in correct sorted order.", "Solve the using the lower triangular matrix in LU. Diagonal elements are assumed\nto be 1", "Execute pull docker image on agent\n\n@param launcher\n@param imageTag\n@param username\n@param password\n@param host\n@return\n@throws IOException\n@throws InterruptedException", "Post-configure retreival of server engine.", "Compiles the allowable actions for a file or folder.\n\n@param cms the current CMS context\n@param file the resource for which we want the allowable actions\n\n@return the allowable actions for the given resource", "Stops the compressor.", "Sets allowed values for attribute\n\n@param allowedValues values that are legal as part in this attribute\n@return a builder that can be used to continue building the attribute definition" ]
public void fire(StepEvent event) { Step step = stepStorage.getLast(); event.process(step); notifier.fire(event); }
[ "Process any StepEvent. You can change last added to stepStorage\nstep using this method.\n\n@param event to process" ]
[ "Builds the table for the database results.\n\n@param results the database results\n@return the table", "Reads a row of a CSV file and populates the bean, using the supplied name mapping to map column values to the\nappropriate fields. If processors are supplied then they are used, otherwise the raw String values will be used.\n\n@param bean\nthe bean to populate\n@param nameMapping\nthe name mapping array\n@param processors\nthe (optional) cell processors\n@return the populated bean, or null if EOF was reached\n@throws IllegalArgumentException\nif nameMapping.length != number of CSV columns read\n@throws IOException\nif an I/O error occurred\n@throws NullPointerException\nif bean or nameMapping are null\n@throws SuperCsvConstraintViolationException\nif a CellProcessor constraint failed\n@throws SuperCsvException\nif there was a general exception while reading/processing\n@throws SuperCsvReflectionException\nif there was an reflection exception while mapping the values to the bean", "Print a duration represented by an arbitrary fraction of minutes.\n\n@param duration Duration instance\n@param factor required factor\n@return duration represented as an arbitrary fraction of minutes", "Transform a TMS layer description object into a raster layer info object.\n\n@param tileMap\nThe TMS layer description object.\n@return The raster layer info object as used by Geomajas.", "Generate a sql where-clause matching the contraints defined by the array of fields\n\n@param columns array containing all columns used in WHERE clause", "Get the title and read the Title property according the provided locale.\n@return The map from locales to the locale specific titles.", "Patch provided by Avril Kotzen ([email protected])\nDB2 handles TINYINT (for mapping a byte).", "Check the version to assure it is allowed.\n\n@param pluginName plugin name which needs the dependency\n@param dependency dependency which needs to be verified\n@param requestedVersion requested/minimum version\n@param availableVersion available version\n@return version check problem or empty string when all is fine", "Consumes a produced result. Calls every transformer in sequence, then\ncalls every dataWriter in sequence.\n\n@param initialVars a map containing the initial variables assignments\n@return the number of lines written" ]
public static String join(final Collection<?> collection, final String separator) { StringBuffer buffer = new StringBuffer(); boolean first = true; Iterator<?> iter = collection.iterator(); while (iter.hasNext()) { Object next = iter.next(); if (first) { first = false; } else { buffer.append(separator); } buffer.append(next); } return buffer.toString(); }
[ "joins a collection of objects together as a String using a separator" ]
[ "Starts a background thread which calls the controller every\ncheck_interval milliseconds. Returns immediately, leaving the\nbackground thread running.", "Locks the bundle descriptor.\n@throws CmsException thrown if locking fails.", "Returns all the deployment runtime names associated with an overlay.\n\n@param context the current OperationContext.\n@param overlayAddress the address for the averlay.\n@return all the deployment runtime names associated with an overlay.", "Set the buttons size.", "seeks to a specified day of the week in the past or future.\n\n@param direction the direction to seek: two possibilities\n'<' go backward\n'>' go forward\n\n@param seekType the type of seek to perform (by_day or by_week)\nby_day means we seek to the very next occurrence of the given day\nby_week means we seek to the first occurrence of the given day week in the\nnext (or previous,) week (or multiple of next or previous week depending\non the seek amount.)\n\n@param seekAmount the amount to seek. Must be guaranteed to parse as an integer\n\n@param dayOfWeek the day of the week to seek to, represented as an integer from\n1 to 7 (1 being Sunday, 7 being Saturday.) Must be guaranteed to parse as an Integer", "The handling method.", "Print out the template information that the client needs for performing a request.\n\n@param json the writer to write the information to.", "Only match if the TypeReference is at the specified location within the file.", "Clears all checked widgets in the group" ]
public static aaauser_intranetip_binding[] get(nitro_service service, String username) throws Exception{ aaauser_intranetip_binding obj = new aaauser_intranetip_binding(); obj.set_username(username); aaauser_intranetip_binding response[] = (aaauser_intranetip_binding[]) obj.get_resources(service); return response; }
[ "Use this API to fetch aaauser_intranetip_binding resources of given name ." ]
[ "High-accuracy Complementary normal distribution function.\n\n@param x Value.\n@return Result.", "Overridden 'consume' method. Corresponding parent method will be called necessary number of times\n\n@param initialVars - a map containing the initial variables assignments\n@return the number of lines written", "Returns the later of two dates, handling null values. A non-null Date\nis always considered to be later than a null Date.\n\n@param d1 Date instance\n@param d2 Date instance\n@return Date latest date", "This implementation checks whether a File can be opened,\nfalling back to whether an InputStream can be opened.\nThis will cover both directories and content resources.", "Updates metadata versions on stores.\n\n@param adminClient An instance of AdminClient points to given cluster\n@param oldStoreDefs List of old store definitions\n@param newStoreDefs List of new store definitions", "Load a cube map texture asynchronously.\n\nThis is the implementation of\n{@link GVRAssetLoader#loadCubemapTexture(GVRAndroidResource)} - it will\nusually be more convenient (and more efficient) to call that directly.\n\n@param gvrContext\nThe GVRF context\n@param textureCache\nTexture cache - may be {@code null}\n@param resource\nA steam containing a zip file which contains six bitmaps. The\nsix bitmaps correspond to +x, -x, +y, -y, +z, and -z faces of\nthe cube map texture respectively. The default names of the\nsix images are \"posx.png\", \"negx.png\", \"posy.png\", \"negx.png\",\n\"posz.png\", and \"negz.png\", which can be changed by calling\n{@link GVRCubemapImage#setFaceNames(String[])}.\n@param priority\nThis request's priority. Please see the notes on asynchronous\npriorities in the <a href=\"package-summary.html#async\">package\ndescription</a>.\n@return A {@link Future} that you can pass to methods like\n{@link GVRShaderData#setMainTexture(Future)}", "Mark content as obsolete. If content was already marked for obsolescenceTimeout ms then it is removed.\n\n@param ref the content refrence to be marked as obsolete.\n\n@return true if the content refrence is removed, fale otherwise.", "Helper method used to peel off spurious wrappings of DateTimeException\n\n@param e DateTimeException to peel\n\n@return DateTimeException that does not have another DateTimeException as its cause.", "Use this API to add vpnclientlessaccesspolicy." ]
@PostConstruct protected void checkPluginDependencies() throws GeomajasException { if ("true".equals(System.getProperty("skipPluginDependencyCheck"))) { return; } if (null == declaredPlugins) { return; } // start by going through all plug-ins to build a map of versions for plug-in keys // includes verification that each key is only used once Map<String, String> versions = new HashMap<String, String>(); for (PluginInfo plugin : declaredPlugins.values()) { String name = plugin.getVersion().getName(); String version = plugin.getVersion().getVersion(); // check for multiple plugin with same name but different versions (duplicates allowed for jar+source dep) if (null != version) { String otherVersion = versions.get(name); if (null != otherVersion) { if (!version.startsWith(EXPR_START)) { if (!otherVersion.startsWith(EXPR_START) && !otherVersion.equals(version)) { throw new GeomajasException(ExceptionCode.DEPENDENCY_CHECK_INVALID_DUPLICATE, name, version, versions.get(name)); } versions.put(name, version); } } else { versions.put(name, version); } } } // Check dependencies StringBuilder message = new StringBuilder(); String backendVersion = versions.get("Geomajas"); for (PluginInfo plugin : declaredPlugins.values()) { String name = plugin.getVersion().getName(); message.append(checkVersion(name, "Geomajas back-end", plugin.getBackendVersion(), backendVersion)); List<PluginVersionInfo> dependencies = plugin.getDependencies(); if (null != dependencies) { for (PluginVersionInfo dependency : plugin.getDependencies()) { String depName = dependency.getName(); message.append(checkVersion(name, depName, dependency.getVersion(), versions.get(depName))); } } dependencies = plugin.getOptionalDependencies(); if (null != dependencies) { for (PluginVersionInfo dependency : dependencies) { String depName = dependency.getName(); String availableVersion = versions.get(depName); if (null != availableVersion) { message.append(checkVersion(name, depName, dependency.getVersion(), versions.get(depName))); } } } } if (message.length() > 0) { throw new GeomajasException(ExceptionCode.DEPENDENCY_CHECK_FAILED, message.toString()); } recorder.record(GROUP, VALUE); }
[ "Finish initializing.\n\n@throws GeomajasException oops" ]
[ "Use this API to fetch the statistics of all aaa_stats resources that are configured on netscaler.", "Merge a subtree.\n\n@param targetRegistry the target registry\n@param subTree the subtree", "Extracts the row from a matrix.\n@param a Input matrix\n@param row Which row is to be extracted\n@param out output. Storage for the extracted row. If null then a new vector will be returned.\n@return The extracted row.", "Return the inverse cumulative distribution function at x.\n\n@param x Argument\n@return Inverse cumulative distribution function at x.", "Inserts a vertex into this list before another specificed vertex.", "Helper to read an optional String value.\n@param path The XML path of the element to read.\n@return The String value stored in the XML, or <code>null</code> if the value could not be read.", "Method used to write the name of the scenarios\n\n@param word\n@return the same word starting with capital letter", "Obtains a local date in Pax calendar system from the\nera, year-of-era and day-of-year fields.\n\n@param era the Pax era, not null\n@param yearOfEra the year-of-era\n@param dayOfYear the day-of-year\n@return the Pax local date, not null\n@throws DateTimeException if unable to create the date\n@throws ClassCastException if the {@code era} is not a {@code PaxEra}", "Called when a ParentViewHolder has triggered a collapse for it's parent\n\n@param flatParentPosition the position of the parent that is calling to be collapsed" ]
public static int[][] toInt(double[][] array) { int[][] n = new int[array.length][array[0].length]; for (int i = 0; i < array.length; i++) { for (int j = 0; j < array[0].length; j++) { n[i][j] = (int) array[i][j]; } } return n; }
[ "2-D Double array to integer array.\n\n@param array Double array.\n@return Integer array." ]
[ "Button onClick listener.\n\n@param v", "Reads a \"date-time\" argument from the request.", "Add a column to be set to a value for UPDATE statements. This will generate something like 'columnName =\nexpression' where the expression is built by the caller.\n\n<p>\nThe expression should have any strings escaped using the {@link #escapeValue(String)} or\n{@link #escapeValue(StringBuilder, String)} methods and should have any column names escaped using the\n{@link #escapeColumnName(String)} or {@link #escapeColumnName(StringBuilder, String)} methods.\n</p>", "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.", "Check whether the URL contains one of the patterns.\n\n@param uri URI\n@param patterns possible patterns\n@return true when URL contains one of the patterns", "This method is very similar to addMainHandler, except ShellFactory\nwill pass all handlers registered with this method to all this shell's subshells.\n\n@see org.gearvrf.debug.cli.Shell#addMainHandler(java.lang.Object, java.lang.String)\n\n@param handler Object which should be registered as handler.\n@param prefix Prefix that should be prepended to all handler's command names.", "Add the string representation of the given object to this sequence immediately. That is, all the trailing\nwhitespace of this sequence will be ignored and the string is appended directly after the last segment that\ncontains something besides whitespace. The given indentation will be prepended to each line except the first one\nif the object has a multi-line string representation.\n\n@param object\nthe to-be-appended object.\n@param indentation\nthe indentation string that should be prepended. May not be <code>null</code>.", "Parses int value and returns the provided default if the value can't be parsed.\n@param value the int to parse.\n@param defaultValue the default value.\n@return the parsed int, or the default value if parsing fails.", "Set RGB input range.\n\n@param inRGB Range." ]
public List<ConnectionInfo> getConnections() { final URI uri = uriWithPath("./connections/"); return Arrays.asList(this.rt.getForObject(uri, ConnectionInfo[].class)); }
[ "Retrieves state and metrics information for all client connections across the cluster.\n\n@return list of connections across the cluster" ]
[ "Creates the tcpClient with proper handler.\n\n@return the bound request builder\n@throws HttpRequestCreateException\nthe http request create exception", "Obtains a Coptic zoned date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Coptic zoned date-time, not null\n@throws DateTimeException if unable to create the date-time", "This method only overrides properties that are specific from Cube like await strategy or before stop events.\n\n@param overrideDockerCompositions\nthat contains information to override.", "Returns the invocation handler object of the given proxy object.\n\n@param obj The object\n@return The invocation handler if the object is an OJB proxy, or <code>null</code>\notherwise", "Check local saved copy first ??. If Auth by username is available, then we will not need to make the API call.\n\n@throws FlickrException", "Use this API to export application.", "Adds a row for the given component at the end of the group.\n\n@param component the component to wrap in the row to be added", "Compares two double values up to some delta.\n\n@param a\n@param b\n@param delta\n@return The value 0 if a equals b, a value greater than 0 if if a > b, and a value less than 0 if a < b.", "Loads the file content in the properties collection\n@param filePath The path of the file to be loaded" ]
public boolean hasUser(String userId) { String normalized = normalizerUserName(userId); return loginToUser.containsKey(normalized) || emailToUser.containsKey(normalized); }
[ "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." ]
[ "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 fetch all the systemcore resources that are configured on netscaler.\nThis uses systemcore_args which is a way to provide additional arguments while fetching the resources.", "Use this API to delete route6 resources of given names.", "Two stage promotion, dry run and actual promotion to verify correctness.\n\n@param promotion\n@param client\n@param listener\n@param buildName\n@param buildNumber\n@throws IOException", "Computes the square root of the complex number.\n\n@param input Input complex number.\n@param root Output. The square root of the input", "generate a prepared SELECT-Statement for the Class\ndescribed by cld\n@param cld the ClassDescriptor", "Package-protected method used to initiate operation execution.\n@return the result action", "Use this API to fetch vpnvserver_cachepolicy_binding resources of given name .", "Logic for timestamp\n@param time Epoch date of creation\n@return String timestamp" ]
public static gslbldnsentries[] get(nitro_service service) throws Exception{ gslbldnsentries obj = new gslbldnsentries(); gslbldnsentries[] response = (gslbldnsentries[])obj.get_resources(service); return response; }
[ "Use this API to fetch all the gslbldnsentries resources that are configured on netscaler." ]
[ "Add a number of days to the supplied date.\n\n@param date start date\n@param days number of days to add\n@return new date", "Use this API to add vlan resources.", "If you want to stop recorded events from being sent to the server, use this method to set the SDK instance to offline.\nOnce offline, events will be recorded and queued locally but will not be sent to the server until offline is disabled.\nCalling this method again with offline set to false will allow events to be sent to server and the SDK instance will immediately attempt to send events that have been queued while offline.\n\n@param value boolean, true sets the sdk offline, false sets the sdk back online", "Calculates the tiles width and height.\n\n@param code\nThe unique tile code. Determines what tile we're talking about.\n@param maxExtent\nThe maximum extent of the grid to which this tile belongs.\n@param scale\nThe current client side scale.\n@return Returns an array of double values where the first value is the tile width and the second value is the\ntile height.", "Set the model used by the right table.\n\n@param model table model", "Gets the Symmetric Kullback-Leibler distance.\nThis metric is valid only for real and positive P and Q.\n\n@param p P vector.\n@param q Q vector.\n@return The Symmetric Kullback Leibler distance between p and q.", "Creates an immutable singleton instance.\n\n@param key\n@param value\n@return", "Register custom filter types especially for serializer of specification json file", "Add groups to the tree.\n\n@param parentNode parent tree node\n@param file group container" ]
protected List<String> parseWords(String line) { List<String> words = new ArrayList<String>(); boolean insideWord = !isSpace(line.charAt(0)); int last = 0; for( int i = 0; i < line.length(); i++) { char c = line.charAt(i); if( insideWord ) { // see if its at the end of a word if( isSpace(c)) { words.add( line.substring(last,i) ); insideWord = false; } } else { if( !isSpace(c)) { last = i; insideWord = true; } } } // if the line ended add the final word if( insideWord ) { words.add( line.substring(last)); } return words; }
[ "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." ]
[ "Extract calendar data.", "Returns the y-coordinate of a vertex normal.\n\n@param vertex the vertex index\n@return the y coordinate", "Lookup an object via its name.\n@param name The name of an object.\n@return The object with that name.\n@exception ObjectNameNotFoundException There is no object with the specified name.\nObjectNameNotFoundException", "Pauses the file upload. This is a blocking function that would try to wait till the assembly file uploads\nhave actually been paused if possible.\n\n@throws LocalOperationException if the method is called while no upload is going on.", "Use this API to fetch all the sslcipher resources that are configured on netscaler.", "Add a row to the table if it does not already exist\n\n@param cells String...", "creates a shape list containing all child shapes and set it to the\ncurrent shape new shape get added to the shape array\n@param shapes\n@param modelJSON\n@param current\n@throws org.json.JSONException", "Join N sets.", "Retrieve a UUID from an input stream.\n\n@param is input stream\n@return UUID instance" ]
public void visitMethodInsn(int opcode, String owner, String name, String desc, boolean itf) { if (mv != null) { mv.visitMethodInsn(opcode, owner, name, desc, itf); } }
[ "Visits a method instruction. A method instruction is an instruction that\ninvokes a method.\n\n@param opcode\nthe opcode of the type instruction to be visited. This opcode\nis either INVOKEVIRTUAL, INVOKESPECIAL, INVOKESTATIC or\nINVOKEINTERFACE.\n@param owner\nthe internal name of the method's owner class (see\n{@link Type#getInternalName() getInternalName}).\n@param name\nthe method's name.\n@param desc\nthe method's descriptor (see {@link Type Type}).\n@param itf\nif the method's owner class is an interface." ]
[ "This takes into account objects that breaks the JavaBean convention\nand have as getter for Boolean objects an \"isXXX\" method.\n@param dest\n@param orig", "Called by determineHead and may be overridden in subclasses\nif special treatment is necessary for particular categories.", "Export the modules that should be checked in into git.", "Answer the SQL-Clause for a LikeCriteria\n\n@param c\n@param buf", "Creates a new Logger instance for the specified name.", "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.", "Use this API to delete sslcertkey resources of given names.", "Converts a sequence of unicode code points to a sequence of Java characters.\n\n@return the number of chars written to the destination buffer", "Returns the command line options to be used for scalaxb, excluding the\ninput file names." ]
public static URL codeLocationFromPath(String filePath) { try { return new File(filePath).toURI().toURL(); } catch (Exception e) { throw new InvalidCodeLocation(filePath); } }
[ "Creates a code location URL from a file path\n\n@param filePath the file path\n@return A URL created from File\n@throws InvalidCodeLocation if URL creation fails" ]
[ "Shuffle an array.\n\n@param array Array.\n@param seed Random seed.", "Adds OPT_J | OPT_JSON option to OptionParser, with multiple arguments.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional", "Caches the results of radix to the given power.\n\n@param radix\n@param power\n@return", "Creates an element that represents a rectangle drawn at the specified coordinates in the page.\n@param x the X coordinate of the rectangle\n@param y the Y coordinate of the rectangle\n@param width the width of the rectangle\n@param height the height of the rectangle\n@param stroke should there be a stroke around?\n@param fill should the rectangle be filled?\n@return the resulting DOM element", "Set the specular intensity of the light.\n\nThis designates the color of the specular reflection.\nIt is multiplied by the material specular color to derive\nthe hue of the specular reflection for that material.\nThe built-in phong shader {@link GVRPhongShader} uses a {@code vec4} uniform named\n{@code specular_intensity} to control the specular intensity.\n\n@param r red component (0 to 1)\n@param g green component (0 to 1)\n@param b blue component (0 to 1)\n@param a alpha component (0 to 1)", "Shortcut for mapping an arbitrary observable to void, using the IO scheduler.\n@param fromObservable the source observable\n@return a void-emitting observable", "Validations specific to PUT", "Creates a polling state.\n\n@param response the response from Retrofit REST call that initiate the long running operation.\n@param lroOptions long running operation options.\n@param defaultRetryTimeout the long running operation retry timeout.\n@param resourceType the type of the resource the long running operation returns\n@param serializerAdapter the adapter for the Jackson object mapper\n@param <T> the result type\n@return the polling state\n@throws IOException thrown by deserialization", "Use the jgrapht cycle checker to detect any cycles in the provided dependency graph." ]
void execute(ExecutableBuilder builder, int timeout, TimeUnit unit) throws CommandLineException, InterruptedException, ExecutionException, TimeoutException { Future<Void> task = executorService.submit(() -> { builder.build().execute(); return null; }); try { if (timeout <= 0) { //Synchronous task.get(); } else { // Guarded execution try { task.get(timeout, unit); } catch (TimeoutException ex) { // First make the context unusable CommandContext c = builder.getCommandContext(); if (c instanceof TimeoutCommandContext) { ((TimeoutCommandContext) c).timeout(); } // Then cancel the task. task.cancel(true); throw ex; } } } catch (InterruptedException ex) { // Could have been interrupted by user (Ctrl-C) Thread.currentThread().interrupt(); cancelTask(task, builder.getCommandContext(), null); // Interrupt running operation. CommandContext c = builder.getCommandContext(); if (c instanceof TimeoutCommandContext) { ((TimeoutCommandContext) c).interrupted(); } throw ex; } }
[ "The CommandContext can be retrieved thatnks to the ExecutableBuilder." ]
[ "Calculate delta with another vector\n@param v another vector\n@return delta vector", "Read the role definitions from a GanttProject project.\n\n@param gpProject GanttProject project", "Verify that cluster is congruent to store def wrt zones.", "Deletes a redirect by id\n\n@param id redirect ID", "Adjust submatrices and helper data structures for the input matrix. Must be called\nbefore the decomposition can be computed.\n\n@param orig", "Calculate a cache key.\n@param sql to use\n@param columnIndexes to use\n@return cache key to use.", "Extracts the column from a matrix.\n@param a Input matrix\n@param column Which column is to be extracted\n@param out output. Storage for the extracted column. If null then a new vector will be returned.\n@return The extracted column.", "Add a new script\n\n@param model\n@param name\n@param script\n@return\n@throws Exception", "Gets the instance associated with the current thread." ]
public static Transformers.ResourceIgnoredTransformationRegistry createServerIgnoredRegistry(final RequiredConfigurationHolder rc, final Transformers.ResourceIgnoredTransformationRegistry delegate) { return new Transformers.ResourceIgnoredTransformationRegistry() { @Override public boolean isResourceTransformationIgnored(PathAddress address) { final int length = address.size(); if (length == 0) { return false; } else if (length >= 1) { if (delegate.isResourceTransformationIgnored(address)) { return true; } final PathElement element = address.getElement(0); final String type = element.getKey(); switch (type) { case ModelDescriptionConstants.EXTENSION: // Don't ignore extensions for now return false; // if (local) { // return false; // Always include all local extensions // } else if (rc.getExtensions().contains(element.getValue())) { // return false; // } // break; case ModelDescriptionConstants.PROFILE: if (rc.getProfiles().contains(element.getValue())) { return false; } break; case ModelDescriptionConstants.SERVER_GROUP: if (rc.getServerGroups().contains(element.getValue())) { return false; } break; case ModelDescriptionConstants.SOCKET_BINDING_GROUP: if (rc.getSocketBindings().contains(element.getValue())) { return false; } break; } } return true; } }; }
[ "Create the ResourceIgnoredTransformationRegistry when fetching missing content, only including relevant pieces\nto a server-config.\n\n@param rc the resolution context\n@param delegate the delegate ignored resource transformation registry for manually ignored resources\n@return" ]
[ "Check the given JWT\n\n@param jwtString the JSON Web Token\n@return the parsed and verified token or null if token is invalid\n@throws ParseException if the token cannot be parsed", "Computes the inverse permutation vector\n\n@param original Original permutation vector\n@param inverse It's inverse", "Update artifact download url of an artifact\n\n@param gavc String\n@param downLoadUrl String", "Delete a server group by id\n\n@param id server group ID", "Update a note.\n\n@param note\nThe Note to update\n@throws FlickrException", "Return all URI schemes that are supported in the system.", "Use this API to fetch nstrafficdomain_binding resource of given name .", "Performs any needed operation on subreports after they are built like ensuring proper subreport with\nif \"fitToParentPrintableArea\" flag is set to true\n\n@param dr\n@param _parameters\n@throws JRException", "Gets display duration for specified frame.\n\n@param n int index of frame.\n@return delay in milliseconds." ]
private static final String correctNumberFormat(String value) { String result; int index = value.indexOf(','); if (index == -1) { result = value; } else { char[] chars = value.toCharArray(); chars[index] = '.'; result = new String(chars); } return result; }
[ "Detect numbers using comma as a decimal separator and replace with period.\n\n@param value original numeric value\n@return corrected numeric value" ]
[ "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", "This method recursively descends the directory structure, dumping\ndetails of any files it finds to the output file.\n\n@param pw Output PrintWriter\n@param dir DirectoryEntry to dump\n@param prefix prefix used to identify path to this object\n@param showData flag indicating if data is dumped, or just structure\n@param hex set to true if hex output is required\n@param indent indent used if displaying structure only\n@throws Exception Thrown on file read errors", "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}.", "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", "This method retrieves the offset of a given entry in the Var2Data block.\nEach entry can be uniquely located by the identifier of the object to\nwhich the data belongs, and the type of the data.\n\n@param id unique identifier of an entity\n@param type data type identifier\n@return offset of requested item", "Cleans up a extension module's subsystems from the resource registration model.\n\n@param rootResource the model root resource\n@param moduleName the name of the extension's module. Cannot be {@code null}\n@throws IllegalStateException if the extension still has subsystems present in {@code rootResource} or its children", "Unlinks a set of dependencies from this task.\n\n@param task The task to remove dependencies from.\n@return Request object", "Gets a property with a default value.\n@param key\nThe key string.\n@param defaultValue\nThe default value.\n@return The property string.", "This method is used to automatically generate a value\nfor the WBS field of this task.\n\n@param parent Parent Task" ]
public static File guessKeyRingFile() throws FileNotFoundException { final Collection<String> possibleLocations = getKnownPGPSecureRingLocations(); for (final String location : possibleLocations) { final File candidate = new File(location); if (candidate.exists()) { return candidate; } } final StringBuilder message = new StringBuilder("Could not locate secure keyring, locations tried: "); final Iterator<String> it = possibleLocations.iterator(); while (it.hasNext()) { message.append(it.next()); if (it.hasNext()) { message.append(", "); } } throw new FileNotFoundException(message.toString()); }
[ "Tries to guess location of the user secure keyring using various\nheuristics.\n\n@return path to the keyring file\n@throws FileNotFoundException if no keyring file found" ]
[ "Reconstructs a number that is represented by more than one byte in a network packet in little-endian order, for\nthe very few protocol values that are sent in this quirky way.\n\n@param buffer the byte array containing the packet data\n@param start the index of the first byte containing a numeric value\n@param length the number of bytes making up the value\n@return the reconstructed number", "Write exceptions into the format used by MSPDI files from\nProject 2007 onwards.\n\n@param calendar parent calendar\n@param exceptions list of exceptions", "Removes all candidates from this collection which are not\nassociated with an initialising method.\n\n@return a {@code Collection} containing the removed\nunassociated candidates. This list is empty if none\nwere removed, i. e. the result is never {@code null}.", "Read assignment data.", "Set the permission for who may view the geo data associated with a photo.\n\nThis method requires authentication with 'write' permission.\n\n@param photoId\nThe id of the photo to set permissions for.\n@param perms\nPermissions, who can see the geo data of this photo\n@throws FlickrException", "Set an enterprise text value.\n\n@param index text index (1-40)\n@param value text value", "Option check, forwards options to the standard doclet, if that one refuses them,\nthey are sent to UmlGraph", "Create a table model from an object's properties.\n\n@param object target object\n@param excludedMethods method names to exclude\n@return table model", "Read a four byte integer.\n\n@param data byte array\n@param offset offset into array\n@return integer value" ]
private int getTaskCode(String field) throws MPXJException { Integer result = m_taskNumbers.get(field.trim()); if (result == null) { throw new MPXJException(MPXJException.INVALID_TASK_FIELD_NAME + " " + field); } return (result.intValue()); }
[ "Returns code number of Task field supplied.\n\n@param field - name\n@return - code no" ]
[ "Use this API to fetch auditnslogpolicy_vpnvserver_binding resources of given name .", "Returns the local collection representing the given namespace for raw document operations.\n\n@param namespace the namespace referring to the local collection.\n@return the local collection representing the given namespace for raw document operations.", "Cosine interpolation.\n\n@param x1 X1 Value.\n@param x2 X2 Value.\n@param a Value.\n@return Value.", "Multiplies all positions with a factor v\n@param v Multiplication factor", "This method is called to format an accrue type value.\n\n@param type accrue type\n@return formatted accrue type", "Add groups for given group parent item.\n\n@param type the tree type\n@param ouItem group parent item", "End a \"track;\" that is, return to logging at one level shallower.\n@param title A title that should match the beginning of this track.", "Wrapper to avoid throwing an exception over JMX", "Read the projects from a ConceptDraw PROJECT file as top level tasks.\n\n@param cdp ConceptDraw PROJECT file" ]
private SpellCheckResponse performSpellcheckQuery(CmsSpellcheckingRequest request) { if ((null == request) || !request.isInitialized()) { return null; } final String[] wordsToCheck = request.m_wordsToCheck; final ModifiableSolrParams params = new ModifiableSolrParams(); params.set("spellcheck", "true"); params.set("spellcheck.dictionary", request.m_dictionaryToUse); params.set("spellcheck.extendedResults", "true"); // Build one string from array of words and use it as query. final StringBuilder builder = new StringBuilder(); for (int i = 0; i < wordsToCheck.length; i++) { builder.append(wordsToCheck[i] + " "); } params.set("spellcheck.q", builder.toString()); final SolrQuery query = new SolrQuery(); query.setRequestHandler("/spell"); query.add(params); try { QueryResponse qres = m_solrClient.query(query); return qres.getSpellCheckResponse(); } catch (Exception e) { LOG.debug("Exception while performing spellcheck query...", e); } return null; }
[ "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." ]
[ "static expansion helpers", "Process the timephased resource assignment data to work out the\nsplit structure of the task.\n\n@param task parent task\n@param timephasedComplete completed resource assignment work\n@param timephasedPlanned planned resource assignment work", "Set the named roles which may be defined.\n\n@param roles map with roles, keys are the values for {@link #rolesAttribute}, probably DN values\n@since 1.10.0", "Inverts the value of the bit at the specified index.\n@param index The bit to flip (0 is the least-significant bit).\n@throws IndexOutOfBoundsException If the specified index is not a bit\nposition in this bit string.", "Convert a Identification to a By used in WebDriver Drivers.\n\n@return the correct By specification of the current Identification.", "Closes the HTTP client and recycles the resources associated. The threads will\nbe recycled after 60 seconds of inactivity.", "Get a patch entry for either a layer or add-on.\n\n@param name the layer name\n@param addOn whether the target is an add-on\n@return the patch entry, {@code null} if it there is no such layer", "is there a faster algorithm out there? This one is a bit sluggish", "Returns the proxies real subject. The subject will be materialized if\nnecessary.\n\n@return The subject" ]
private int getDaysToNextMatch(WeekDay weekDay) { for (WeekDay wd : m_weekDays) { if (wd.compareTo(weekDay) > 0) { return wd.toInt() - weekDay.toInt(); } } return (m_weekDays.iterator().next().toInt() + (m_interval * I_CmsSerialDateValue.NUM_OF_WEEKDAYS)) - weekDay.toInt(); }
[ "Returns the number of days from the given weekday to the next weekday the event should occur.\n@param weekDay the current weekday.\n@return the number of days to the next weekday an event could occur." ]
[ "Sets the HTML entity translator for all cells in the row.\nIt will also remove any other translator set.\nNothing will happen if the argument is null.\n@param htmlElementTranslator translator\n@return this to allow chaining", "add converter at given index. The index can be changed during conversion\nif canReorder is true\n\n@param index\n@param converter", "Writes one or more String columns as a line to the CsvWriter.\n\n@param columns\nthe columns to write\n@throws IllegalArgumentException\nif columns.length == 0\n@throws IOException\nIf an I/O error occurs\n@throws NullPointerException\nif columns is null", "This method extracts predecessor data from a Planner file.\n\n@param plannerTask Task data", "Create a Vendor from a Func0", "The handling method.", "OR operation which takes 2 arguments and OR's them together.\n\n<p>\n<b>NOTE:</b> There is no guarantee of the order of the clauses that are generated in the final query.\n</p>\n<p>\n<b>NOTE:</b> I can't remove the generics code warning that can be associated with this method. You can instead\nuse the {@link #or(int)} method.\n</p>", "append multi clickable SpecialUnit or String\n\n@param specialClickableUnit SpecialClickableUnit\n@param specialUnitOrStrings Unit Or String\n@return", "Sets the bottom padding for all cells in the row.\n@param paddingBottom new padding, ignored if smaller than 0\n@return this to allow chaining" ]
private void checkOrderby(CollectionDescriptorDef collDef, String checkLevel) throws ConstraintException { if (CHECKLEVEL_NONE.equals(checkLevel)) { return; } String orderbySpec = collDef.getProperty(PropertyHelper.OJB_PROPERTY_ORDERBY); if ((orderbySpec == null) || (orderbySpec.length() == 0)) { return; } ClassDescriptorDef ownerClass = (ClassDescriptorDef)collDef.getOwner(); String elementClassName = collDef.getProperty(PropertyHelper.OJB_PROPERTY_ELEMENT_CLASS_REF).replace('$', '.'); ClassDescriptorDef elementClass = ((ModelDef)ownerClass.getOwner()).getClass(elementClassName); FieldDescriptorDef fieldDef; String token; String fieldName; String ordering; int pos; for (CommaListIterator it = new CommaListIterator(orderbySpec); it.hasNext();) { token = it.getNext(); pos = token.indexOf('='); if (pos == -1) { fieldName = token; ordering = null; } else { fieldName = token.substring(0, pos); ordering = token.substring(pos + 1); } fieldDef = elementClass.getField(fieldName); if (fieldDef == null) { throw new ConstraintException("The field "+fieldName+" specified in the orderby attribute of the collection "+collDef.getName()+" in class "+ownerClass.getName()+" hasn't been found in the element class "+elementClass.getName()); } if ((ordering != null) && (ordering.length() > 0) && !"ASC".equals(ordering) && !"DESC".equals(ordering)) { throw new ConstraintException("The ordering "+ordering+" specified in the orderby attribute of the collection "+collDef.getName()+" in class "+ownerClass.getName()+" is invalid"); } } }
[ "Checks the orderby attribute.\n\n@param collDef The collection descriptor\n@param checkLevel The current check level (this constraint is checked in basic and strict)\n@exception ConstraintException If the value for orderby is invalid (unknown field or ordering)" ]
[ "Use this API to fetch filtered set of lbvserver resources.\nset the filter parameter values in filtervalue object.", "Parses coordinates into a Spatial4j point shape.", "Loads the currently known phases from Furnace to the map.", "Called by implementation class once websocket connection established\nat networking layer.\n@param context the websocket context", "List all the environment variables for an app.\n@param appName App name. See {@link #listApps} for a list of apps that can be used.\n@return map of config vars", "Returns the time elapsed by the user on the app\n@return Time elapsed by user on the app in int", "Use this API to update vridparam.", "Method used to update fields with values received from API.\n@param jsonObject JSON-encoded info about File Version object.", "set proper expression text invoking the DJCRosstabMeasurePrecalculatedTotalProvider for the cell\n@param auxRows\n@param auxCols\n@param measureExp\n@param djmeasure\n@param crosstabColumn\n@param crosstabRow\n@param meausrePrefix" ]
public OperationBuilder addInputStream(final InputStream in) { Assert.checkNotNullParam("in", in); if (inputStreams == null) { inputStreams = new ArrayList<InputStream>(); } inputStreams.add(in); return this; }
[ "Associate an input stream with the operation. Closing the input stream\nis the responsibility of the caller.\n\n@param in the input stream. Cannot be {@code null}\n@return a builder than can be used to continue building the operation" ]
[ "Returns whether this host should ignore operations from the master domain controller that target\nthe given address.\n\n@param address the resource address. Cannot be {@code null}\n\n@return {@code true} if the operation should be ignored; {@code false} otherwise", "Calcs the bonding size of given mesh.\n\n@param mesh Mesh to calc its bouding size.\n@return The bounding size for x, y and z axis.", "Moves everything up so that the specified shift or latch character can be inserted.\n\n@param position the position beyond which everything needs to be shifted\n@param c the latch or shift character to insert at the specified position, after everything has been shifted", "See page 385 of Fundamentals of Matrix Computations 2nd", "Writes this JAR to an output stream, and closes the stream.", "Use this API to add snmpmanager.", "Use this API to fetch all the responderhtmlpage resources that are configured on netscaler.", "Get a value from a date metadata field.\n@param path the key path in the metadata object. Must be prefixed with a \"/\".\n@return the metadata value as a Date.\n@throws ParseException when the value cannot be parsed as a valid date", "Sets a new config and clears the previous cache" ]
protected void switchTab() { Component tab = m_tab.getSelectedTab(); int pos = m_tab.getTabPosition(m_tab.getTab(tab)); if (m_isWebOU) { if (pos == 0) { pos = 1; } } m_tab.setSelectedTab(pos + 1); }
[ "Switches to the next tab." ]
[ "Gets information about all of the group memberships for this user.\nDoes not support paging.\n\n<p>Note: This method is only available to enterprise admins.</p>\n\n@return a collection of information about the group memberships for this user.", "Read the role definitions from a GanttProject project.\n\n@param gpProject GanttProject project", "Returns iterable with all assignments of given type of this retention policy.\n@param type the type of the retention policy assignment to retrieve. Can either be \"folder\" or \"enterprise\".\n@param limit the limit of entries per response. The default value is 100.\n@param fields the fields to retrieve.\n@return an iterable containing all assignments of given type.", "Pool configuration.\n@param props\n@throws HibernateException", "Use this API to enable clusterinstance resources of given names.", "Set the time and value of the key at the given index\n@param keyIndex 0 based index of key\n@param time key time in seconds\n@param values key values", "2-D Gaussian kernel.\n\n@param size Kernel size (should be odd), [3, 101].\n@return Returns 2-D Gaussian kernel of specified size.", "Load the view port execution.\n\n@param then callback when the view port is detected.\n@param fallback fallback when no view port detected or failure to detect the given\n{@link Boundary} (using {@link #propagateFallback(boolean)})", "appends a HAVING-clause to the Statement\n@param having\n@param crit\n@param stmt" ]
public static <T> List<T> toList(Iterable<T> items) { List<T> list = new ArrayList<T>(); addAll(list, items); return list; }
[ "Create a list out of the items in the Iterable.\n\n@param <T>\nThe type of items in the Iterable.\n@param items\nThe items to be made into a list.\n@return A list consisting of the items of the Iterable, in the same order." ]
[ "flushes log queue, this actually writes combined log message into system log", "Sets the character translator.\nIt will also remove any other translator set.\nNothing will happen if the argument is null.\n@param charTranslator translator", "Calculates Tangent value of the complex number.\n\n@param z1 A ComplexNumber instance.\n@return Returns new ComplexNumber instance containing the Tangent value of the specified complex number.", "Use this API to add vpnclientlessaccesspolicy.", "Converts url path to the Transloadit full url.\nReturns the url passed if it is already full.\n\n@param url\n@return String", "Use this API to update csparameter.", "This method returns the value of the product using a Black-Scholes model for the swap rate\nThe model is determined by a discount factor curve and a swap rate volatility.\n\n@param forwardCurve The forward curve on which to value the swap.\n@param swaprateVolatility The Black volatility.\n@return Value of this product", "Creates a new Logger instance for the specified name.", "This method extracts project properties from a Phoenix file.\n\n@param phoenixSettings Phoenix settings\n@param storepoint Current storepoint" ]
public static URI setPath(final URI initialUri, final String path) { String finalPath = path; if (!finalPath.startsWith("/")) { finalPath = '/' + path; } try { if (initialUri.getHost() == null && initialUri.getAuthority() != null) { return new URI(initialUri.getScheme(), initialUri.getAuthority(), finalPath, initialUri.getQuery(), initialUri.getFragment()); } else { return new URI(initialUri.getScheme(), initialUri.getUserInfo(), initialUri.getHost(), initialUri.getPort(), finalPath, initialUri.getQuery(), initialUri.getFragment()); } } catch (URISyntaxException e) { throw ExceptionUtils.getRuntimeException(e); } }
[ "Set the replace of the uri and return the new URI.\n\n@param initialUri the starting URI, the URI to update\n@param path the path to set on the baeURI" ]
[ "Close a transaction and do all the cleanup associated with it.", "Renumbers all entity unique IDs.", "Use this API to unset the properties of bridgetable resources.\nProperties that need to be unset are specified in args array.", "Returns the primary message codewords for mode 3.\n\n@param postcode the postal code\n@param country the country code\n@param service the service code\n@return the primary message, as codewords", "Set an enterprise date value.\n\n@param index date index (1-30)\n@param value date value", "Get the literal value for an expression.\n\n@param expression expression\n@return literal value", "Get the raw data bytes of the device update packet.\n\n@return the data sent by the device to update its status", "The point that is the GOLDEN_SECTION along the way from a to b.\na may be less or greater than b, you find the point 60-odd percent\nof the way from a to b.\n\n@param a Interval minimum\n@param b Interval maximum\n@return The GOLDEN_SECTION along the way from a to b.", "a small helper to set the text color to a textView null save\n\n@param textView\n@param colorDefault" ]
public void recordAsyncOpTimeNs(SocketDestination dest, long opTimeNs) { if(dest != null) { getOrCreateNodeStats(dest).recordAsyncOpTimeNs(null, opTimeNs); recordAsyncOpTimeNs(null, opTimeNs); } else { this.asynOpTimeRequestCounter.addRequest(opTimeNs); } }
[ "Record operation for async ops time\n\n@param dest Destination of the socket to connect to. Will actually record\nif null. Otherwise will call this on self and corresponding child\nwith this param null.\n@param opTimeUs The number of us for the op to finish" ]
[ "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.", "Fetch the outermost Hashmap.\n\n@param firstKey\nfirst key\n@return the the innermost hashmap", "An extension point so we can control how the query gets executed.\nThis exists for testing purposes, not because we believe it will\nactually be used for real.", "List the slack values for each task.\n\n@param file ProjectFile instance", "This solution is based on an absolute path", "Find the index of this animation if it is in this animator.\n\n@param findme {@link GVRAnimation} to find.\n@returns 0 based index of animation or -1 if not found\n@see GVRAnimator#addAnimation(GVRAnimation)", "Internal utility to dump relationship lists in a structured format\nthat can easily be compared with the tabular data in MS Project.\n\n@param relations relation list", "Gets the filename from a path or URL.\n@param path or url.\n@return the file name.", "Read an int from the byte array starting at the given offset\n\n@param bytes The byte array to read from\n@param offset The offset to start reading at\n@return The int read" ]
public static <T> JacksonParser<T> json(Class<T> contentType) { return new JacksonParser<>(null, contentType); }
[ "Creates typed parser\n@param contentType class of parsed object\n@param <T> type of parsed object\n@return parser of objects of given type" ]
[ "Set the enum representing the type of this column.\n\n@param tableType type of table to which this column belongs", "Returns the site path for the edited bundle file.\n\n@return the site path for the edited bundle file.", "Returns the bounding box of the vertices.\n@param corners destination array to get corners of bounding box.\nThe first three entries are the minimum X,Y,Z values\nand the next three are the maximum X,Y,Z.\n@return true if bounds are not empty, false if empty (no vertices)", "Iterates through the given InputStream line by line using the specified\nencoding, splitting each line using the given separator. The list of tokens\nfor each line is then passed to the given closure. Finally, the stream\nis closed.\n\n@param stream an InputStream\n@param regex the delimiting regular expression\n@param charset opens the stream with a specified charset\n@param closure a closure\n@return the last value returned by the closure\n@throws IOException if an IOException occurs.\n@throws java.util.regex.PatternSyntaxException\nif the regular expression's syntax is invalid\n@see #splitEachLine(java.io.Reader, java.lang.String, groovy.lang.Closure)\n@since 1.5.5", "Add a property with the given name and the given list of values to this Properties object. Name\nand values are trimmed before the property is added.\n\n@param name the name of the property, must not be <code>null</code>.\n@param values the values of the property, must no be <code>null</code>,\nnone of the values must be <code>null</code>", "Add the set of partitions to the node provided\n\n@param node The node to which we'll add the partitions\n@param donatedPartitions The list of partitions to add\n@return The new node with the new partitions", "Print all relations for a given's class's tag\n@param tagname the tag containing the given relation\n@param from the source class\n@param edgetype the dot edge specification", "Use this API to fetch all the sslservice resources that are configured on netscaler.\nThis uses sslservice_args which is a way to provide additional arguments while fetching the resources.", "Converts the passed list of inners to unmodifiable map of impls.\n@param innerList list of the inners.\n@return map of the impls" ]
public static MetadataTemplate createMetadataTemplate(BoxAPIConnection api, String scope, String templateKey, String displayName, boolean hidden, List<Field> fields) { JsonObject jsonObject = new JsonObject(); jsonObject.add("scope", scope); jsonObject.add("displayName", displayName); jsonObject.add("hidden", hidden); if (templateKey != null) { jsonObject.add("templateKey", templateKey); } JsonArray fieldsArray = new JsonArray(); if (fields != null && !fields.isEmpty()) { for (Field field : fields) { JsonObject fieldObj = getFieldJsonObject(field); fieldsArray.add(fieldObj); } jsonObject.add("fields", fieldsArray); } URL url = METADATA_TEMPLATE_SCHEMA_URL_TEMPLATE.build(api.getBaseURL()); BoxJSONRequest request = new BoxJSONRequest(api, url, "POST"); request.setBody(jsonObject.toString()); BoxJSONResponse response = (BoxJSONResponse) request.send(); JsonObject responseJSON = JsonObject.readFrom(response.getJSON()); return new MetadataTemplate(responseJSON); }
[ "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." ]
[ "Provides a type-specific Meta class for the given TinyType.\n\n@param <T> the TinyType class type\n@param candidate the TinyType class to obtain a Meta for\n@return a Meta implementation suitable for the candidate\n@throws IllegalArgumentException for null or a non-TinyType", "This method writes calendar data to an MSPDI file.\n\n@param project Root node of the MSPDI file", "Tries to load a class using the specified ResourceLoader. Returns null if the class is not found.\n@param className\n@param resourceLoader\n@return the loaded class or null if the given class cannot be loaded", "Computes the WordNet 2.0 POS tag corresponding to the PTB POS tag s.\n\n@param s a Penn TreeBank POS tag.", "Parses a String comprised of 0 or more comma-delimited key=value pairs.\n\n@param s the string to parse\n@return the Map of parsed key value pairs", "Returns the zip entry for a file in the archive.\n@param filename the file name\n@return the zip entry for the file with the provided name\n@throws ZipException thrown if the file is not in the zip archive", "This looks at the servlet attributes to get the list of response headers to remove while the response object gets created by the servlet", "Return the filesystem path needed to mount the NFS filesystem associated with a particular media slot.\n\n@param slot the slot whose filesystem is desired\n\n@return the path to use in the NFS mount request to access the files mounted in that slot\n\n@throws IllegalArgumentException if it is a slot that we don't know how to handle", "Converts string to UUID and returns it, or null if the conversion is not possible.\n\n@param uuid the potential UUID string\n@return the UUID, or null if conversion is not possible" ]
public void addBeanToBeanMapping(BeanToBeanMapping beanToBeanMapping) { beanToBeanMappings.put(ClassPair.get(beanToBeanMapping .getSourceClass(), beanToBeanMapping.getDestinationClass()), beanToBeanMapping); }
[ "Add a mapping of properties between two beans\n\n@param beanToBeanMapping" ]
[ "Extracts calendar data from a ConceptDraw PROJECT file.\n\n@param cdp ConceptDraw PROJECT file", "blocks until there is a connection", "Check whether the given id is included in the list of includes and not excluded.\n\n@param id id to check\n@param includes list of include regular expressions\n@param excludes list of exclude regular expressions\n@return true when id included and not excluded", "Returns the accrued interest of the bond for a given time.\n\n@param time The time of interest as double.\n@param model The model under which the product is valued.\n@return The accrued interest.", "This method processes a single deferred relationship list.\n\n@param dr deferred relationship list data\n@throws MPXJException", "Awaits at most 5 minutes until all pods meets the given predicate.\n\n@param filter used to wait to detect that a pod is up and running.", "This method is called to format a priority.\n\n@param value priority instance\n@return formatted priority value", "Write the domain controller data to an S3 file.\n\n@param data the domain controller data\n@param domainName the name of the directory in the bucket to write the S3 file to\n@throws IOException", "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" ]
public double[][] Kernel2D(int size) { if (((size % 2) == 0) || (size < 3) || (size > 101)) { try { throw new Exception("Wrong size"); } catch (Exception e) { e.printStackTrace(); } } int r = size / 2; double[][] kernel = new double[size][size]; // compute kernel double sum = 0; for (int y = -r, i = 0; i < size; y++, i++) { for (int x = -r, j = 0; j < size; x++, j++) { kernel[i][j] = Function2D(x, y); sum += kernel[i][j]; } } for (int i = 0; i < kernel.length; i++) { for (int j = 0; j < kernel[0].length; j++) { kernel[i][j] /= sum; } } return kernel; }
[ "2-D Gaussian kernel.\n\n@param size Kernel size (should be odd), [3, 101].\n@return Returns 2-D Gaussian kernel of specified size." ]
[ "Transforms root paths to site paths.\n\n@return lazy map from root paths to site paths.\n\n@see CmsRequestContext#removeSiteRoot(String)", "Retrieves an object that has been attached to this context.\n\n@param key the key to the attachment.\n@param <V> the value type of the attachment.\n\n@return the attachment if found otherwise {@code null}.", "Use this API to fetch nstrafficdomain_binding resources of given names .", "Stops the current connection. No reconnecting will occur. Kills thread + cleanup.\nWaits for the loop to end", "Creates a pattern choice radio button and adds it where necessary.\n@param pattern the pattern that should be chosen by the button.\n@param messageKey the message key for the button's label.", "If any of the given list of properties are not found, returns the\nname of that property. Otherwise, returns null.", "Loads the favorite list.\n\n@return the list of favorites\n\n@throws CmsException if something goes wrong", "Returns an iterator of all direct and indirect extents of this class.\n\n@return The extents iterator", "Sets the HTTP poller processor to handle Async API.\nWill auto enable the pollable mode with this call\n\n@param httpPollerProcessor\nthe http poller processor\n@return the parallel task builder" ]
public ItemRequest<Attachment> createOnTask(String task, InputStream fileContent, String fileName, String fileType) { MultipartContent.Part part = new MultipartContent.Part() .setContent(new InputStreamContent(fileType, fileContent)) .setHeaders(new HttpHeaders().set( "Content-Disposition", String.format("form-data; name=\"file\"; filename=\"%s\"", fileName) // TODO: escape fileName? )); MultipartContent content = new MultipartContent() .setMediaType(new HttpMediaType("multipart/form-data").setParameter("boundary", UUID.randomUUID().toString())) .addPart(part); String path = String.format("/tasks/%s/attachments", task); return new ItemRequest<Attachment>(this, Attachment.class, path, "POST") .data(content); }
[ "Upload a file and attach it to a task\n\n@param task Globally unique identifier for the task.\n@param fileContent Content of the file to be uploaded\n@param fileName Name of the file to be uploaded\n@param fileType MIME type of the file to be uploaded\n@return Request object" ]
[ "Map the given region of the given file descriptor into memory.\nReturns a Pointer to the newly mapped memory throws an\nIOException on error.", "Drives the unit test.", "Gets the addresses of the child resources under the given resource.\n\n@param context the operation context\n@param registry registry entry representing the resource\n@param resource the current resource\n@param validChildType a single child type to which the results should be limited. If {@code null} the result\nshould include all child types\n@return map where the keys are the child types and the values are a set of child names associated with a type", "Extract the subscription ID from a resource ID string.\n@param id the resource ID string\n@return the subscription ID", "Map the currency separator character to a symbol name.\n\n@param c currency separator character\n@return symbol name", "Adds a license to an artifact if the license exist into the database\n\n@param gavc String\n@param licenseId String", "Computes the p=2 norm. If A is a matrix then the induced norm is computed. This\nimplementation is faster, but more prone to buffer overflow or underflow problems.\n\n@param A Matrix or vector.\n@return The norm.", "Use this API to update filterhtmlinjectionparameter.", "Returns next and previous favorites for a photo in a user's favorites\n\n@param photoId\nThe photo id\n@param userId\nThe user's ID\n@see <a href=\"http://www.flickr.com/services/api/flickr.favorites.getContext.html\">flickr.favorites.getContext</a>" ]
public <A extends Collection<? super ResultT>> A into(final A target) { forEach(new Block<ResultT>() { @Override public void apply(@Nonnull final ResultT t) { target.add(t); } }); return target; }
[ "Iterates over all the documents, adding each to the given target.\n\n@param target the collection to insert into\n@param <A> the collection type\n@return the target" ]
[ "This method writes project property data to a JSON file.", "Gracefully stop the engine", "Evaluates the body if value for the member tag equals the specified value.\n\n@param template The body of the block tag\n@param attributes The attributes of the template tag\n@exception XDocletException If an error occurs\[email protected] type=\"block\"\[email protected] name=\"tagName\" optional=\"false\" description=\"The tag name.\"\[email protected] name=\"paramName\" description=\"The parameter name. If not specified, then the raw\ncontent of the tag is returned.\"\[email protected] name=\"paramNum\" description=\"The zero-based parameter number. It's used if the user\nused the space-separated format for specifying parameters.\"\[email protected] name=\"value\" optional=\"false\" description=\"The expected value.\"", "Use this API to unset the properties of ntpserver resource.\nProperties that need to be unset are specified in args array.", "Used by Pipeline jobs only", "Use this API to delete dnstxtrec of given name.", "Applies the matrices computed from the scene object's\nlinked to the skeleton bones to the current pose.\n@see #applyPose(GVRPose, int)\n@see #setPose(GVRPose)", "Obtains the Constructor specified from the given Class and argument types\n\n@throws NoSuchMethodException", "slave=true" ]
public int count() { int n = 0; for (ConcurrentMap<?, ?> bag : registry.values()) { n += bag.size(); } return n; }
[ "Returns the connection count in this registry.\n\nNote it might count connections that are closed but not removed from registry yet\n\n@return the connection count" ]
[ "Use this API to update autoscaleprofile resources.", "Handle interval change.\n@param event the change event.", "Returns the URL of a classpath resource.\n\n@param resourceName\nThe name of the resource.\n\n@return The URL.", "Insert a new value prior to the index location in the existing value array,\nincreasing the field length accordingly.\n@param index - where the new values in an SFVec2f object will be placed in the array list\n@param newValue - the new x, y value for the array list", "waits for all async mutations that were added before this was called to be flushed. Does not\nwait for async mutations added after call.", "When all the elements in a sorted set are inserted with the same score, in order to force lexicographical\nordering, this command returns all the elements in the sorted set with a value in the given range.\n@param lexRange\n@return the range of elements", "Attaches a pre-existing set of hours to the correct\nday within the calendar.\n\n@param hours calendar hours instance", "Loads the favorite list.\n\n@return the list of favorites\n\n@throws CmsException if something goes wrong", "Creates an immutable list that consists of the elements in the given collection. If the given collection is already an immutable list,\nit is returned directly.\n\n@param source the given collection\n@return an immutable list" ]
public static long getVisibilityCacheWeight(FluoConfiguration conf) { long size = conf.getLong(VISIBILITY_CACHE_WEIGHT, VISIBILITY_CACHE_WEIGHT_DEFAULT); if (size <= 0) { throw new IllegalArgumentException( "Cache size must be positive for " + VISIBILITY_CACHE_WEIGHT); } return size; }
[ "Gets the visibility cache weight\n\n@param conf The FluoConfiguration\n@return The size of the cache value from the property value {@value #VISIBILITY_CACHE_WEIGHT}\nif it is set, else the value of the default value\n{@value #VISIBILITY_CACHE_WEIGHT_DEFAULT}" ]
[ "Set the values of all the knots.\nThis version does not require the \"extra\" knots at -1 and 256\n@param x the knot positions\n@param rgb the knot colors\n@param types the knot types", "Total count of partition-stores moved in this task.\n\n@return number of partition stores moved in this task.", "Initializes unspecified sign properties using available defaults\nand global settings.", "Add a misc file.\n\n@param name the file name\n@param path the relative path\n@param newHash the new hash of the added content\n@param isDirectory whether the file is a directory or not\n@return the builder", "Add a given factory to the list of factories at the BEGINNING.\n\n@param factory The factory to be added.\n@return Cascade with amended factory list.", "Copies file from a resource to a local temp file\n\n@param sourceResource\n@return Absolute filename of the temp file\n@throws Exception", "Check if a given string is a valid java package or class name.\n\nThis method use the technique documented in\n[this SO question](https://stackoverflow.com/questions/13557195/how-to-check-if-string-is-a-valid-class-identifier)\nwith the following extensions:\n\n* if the string does not contain `.` then assume it is not a valid package or class name\n\n@param s\nthe string to be checked\n@return\n`true` if `s` is a valid java package or class name", "Returns the corporate dependencies of a module\n\n@param module Module\n@param corporateFilters List<String>\n@return List<Dependency>", "Converts an image in BINARY mode to RGB mode\n\n@param img image\n@return new MarvinImage instance in RGB mode" ]
public static boolean containsAllQualifiers(Set<QualifierInstance> requiredQualifiers, Set<QualifierInstance> qualifiers) { return qualifiers.containsAll(requiredQualifiers); }
[ "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" ]
[ "convert Event bean to EventType manually.\n\n@param event the event\n@return the event type", "This method calculates the absolute number of days between two dates.\nNote that where two date objects are provided that fall on the same\nday, this method will return one not zero. Note also that this method\nassumes that the dates are passed in the correct order, i.e.\nstartDate < endDate.\n\n@param startDate Start date\n@param endDate End date\n@return number of days in the date range", "Sends a server command continuation request '+' back to the client,\nrequesting more data to be sent.", "Serialize a content into a targeted file, checking that the parent directory exists.\n\n@param folder File\n@param content String\n@param fileName String", "Start listening for device announcements and keeping track of the DJ Link devices visible on the network.\nIf already listening, has no effect.\n\n@throws SocketException if the socket to listen on port 50000 cannot be created", "Returns a description String based on the defined command and options.\nUseful when printing \"help\" info etc.", "Read resource baseline values.\n\n@param row result set row", "Convert a color to an angle.\n\n@param color The RGB value of the color to \"find\" on the color wheel.\n\n@return The angle (in rad) the \"normalized\" color is displayed on the\ncolor wheel.", "Converts from a bitmap to individual day flags for a weekly recurrence,\nusing the array of masks.\n\n@param days bitmap\n@param masks array of mask values" ]
@Override public void addExtraState(EntityEntryExtraState extraState) { if ( next == null ) { next = extraState; } else { next.addExtraState( extraState ); } }
[ "state chain management ops below" ]
[ "Parse a filter expression.\n\n@param filter the filter expression\n@return compiled nodes", "Use this API to fetch dnsview resources of given names .", "Returns the AirMapView implementation as requested by the mapType argument. Use this method if\nyou need to request a specific AirMapView implementation that is not necessarily the preferred\ntype. For example, you can use it to explicit request a web-based map implementation.\n\n@param mapType Map type for the requested AirMapView implementation.\n@return An {@link AirMapViewBuilder} for the requested {@link AirMapViewTypes} mapType.", "Returns server group by ID\n\n@param id ID of server group\n@return ServerGroup\n@throws Exception exception", "Returns iterable containing assignments for this single legal hold policy.\nParameters can be used to filter retrieved assignments.\n@param type filter assignments of this type only.\nCan be \"file_version\", \"file\", \"folder\", \"user\" or null if no type filter is necessary.\n@param id filter assignments to this ID only. Can be null if no id filter is necessary.\n@param limit the limit of entries per page. Default limit is 100.\n@param fields the fields to retrieve.\n@return an iterable containing assignments for this single legal hold policy.", "get the TypeArgSignature corresponding to given type\n\n@param type\n@return", "Generate a sql where-clause matching the contraints defined by the array of fields\n\n@param columns array containing all columns used in WHERE clause", "Determine the generic value type of the given Map field.\n@param mapField the map field to introspect\n@param nestingLevel the nesting level of the target type\n(typically 1; e.g. in case of a List of Lists, 1 would indicate the\nnested List, whereas 2 would indicate the element of the nested List)\n@return the generic type, or {@code null} if none", "Start and configure GreenMail using given properties.\n\n@param properties the properties such as System.getProperties()" ]
public Duration getWorkVariance() { Duration variance = (Duration) getCachedValue(ResourceField.WORK_VARIANCE); if (variance == null) { Duration work = getWork(); Duration baselineWork = getBaselineWork(); if (work != null && baselineWork != null) { variance = Duration.getInstance(work.getDuration() - baselineWork.convertUnits(work.getUnits(), getParentFile().getProjectProperties()).getDuration(), work.getUnits()); set(ResourceField.WORK_VARIANCE, variance); } } return (variance); }
[ "Retrieves the work variance.\n\n@return work variance" ]
[ "Sets the value associated with the given key; if the the key is one\nof the hashable keys, throws an exception.\n\n@throws HashableCoreMapException Attempting to set the value for an\nimmutable, hashable key.", "Creates a map of identifiers or page titles to documents retrieved via\nthe APIs.\n\n@param numOfEntities\nnumber of entities that should be retrieved\n@param properties\nWbGetEntitiesProperties object that includes all relevant\nparameters for the wbgetentities action\n@return map of document identifiers or titles to documents retrieved via\nthe API URL\n@throws MediaWikiApiErrorException\n@throws IOException", "Use this API to unset the properties of ntpserver resource.\nProperties that need to be unset are specified in args array.", "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.", "Resets the generator state.", "Set the occurrences. If the String is invalid, the occurrences will be set to \"-1\" to cause server-side validation to fail.\n@param occurrences the interval to set.", "Load the view port execution.\n\n@param then callback when the view port is detected.\n@param fallback fallback when no view port detected or failure to detect the given\n{@link Boundary} (using {@link #propagateFallback(boolean)})", "Print time unit.\n\n@param value TimeUnit instance\n@return time unit value", "Populate the container, converting raw data into Java types.\n\n@param field custom field to which these values belong\n@param values raw value data\n@param descriptions raw description data" ]
public JSONObject getPathFromEndpoint(String pathValue, String requestType) throws Exception { int type = getRequestTypeFromString(requestType); String url = BASE_PATH; JSONObject response = new JSONObject(doGet(url, null)); JSONArray paths = response.getJSONArray("paths"); for (int i = 0; i < paths.length(); i++) { JSONObject path = paths.getJSONObject(i); if (path.getString("path").equals(pathValue) && path.getInt("requestType") == type) { return path; } } return null; }
[ "Retrieves the path using the endpoint value\n\n@param pathValue - path (endpoint) value\n@param requestType - \"GET\", \"POST\", etc\n@return Path or null\n@throws Exception exception" ]
[ "Updates the information about this weblink with any info fields that have been modified locally.\n\n<p>The only fields that will be updated are the ones that have been modified locally. For example, the following\ncode won't update any information (or even send a network request) since none of the info's fields were\nchanged:</p>\n\n<pre>BoxWebLink webLink = new BoxWebLink(api, id);\nBoxWebLink.Info info = webLink.getInfo();\nwebLink.updateInfo(info);</pre>\n\n@param info the updated info.", "Provide Jersey client for the targeted Grapes server\n\n@return webResource", "Checks the given collection descriptor.\n\n@param collDef The collection descriptor\n@param checkLevel The amount of checks to perform\n@exception ConstraintException If a constraint has been violated", "Accessor method used to retrieve an Duration object representing the\ncontents of an individual field. If the field does not exist in the\nrecord, null is returned.\n\n@param field the index number of the field to be retrieved\n@return the value of the required field\n@throws MPXJException normally thrown when parsing fails", "If the workspace for your project _is_ an organization, you must also\nsupply a `team` to share the project with.\n\nReturns the full record of the newly created project.\n\n@param workspace The workspace or organization to create the project in.\n@return Request object", "Returns a new color that has the hue adjusted by the specified\namount.", "Use this API to fetch cacheselector resources of given names .", "Use this API to change appfwsignatures.", "Removes all resources deployed using this class." ]
private EnabledEndpoint getPartialEnabledEndpointFromResultset(ResultSet result) throws Exception { EnabledEndpoint endpoint = new EnabledEndpoint(); endpoint.setId(result.getInt(Constants.GENERIC_ID)); endpoint.setPathId(result.getInt(Constants.ENABLED_OVERRIDES_PATH_ID)); endpoint.setOverrideId(result.getInt(Constants.ENABLED_OVERRIDES_OVERRIDE_ID)); endpoint.setPriority(result.getInt(Constants.ENABLED_OVERRIDES_PRIORITY)); endpoint.setRepeatNumber(result.getInt(Constants.ENABLED_OVERRIDES_REPEAT_NUMBER)); endpoint.setResponseCode(result.getString(Constants.ENABLED_OVERRIDES_RESPONSE_CODE)); ArrayList<Object> args = new ArrayList<Object>(); try { JSONArray arr = new JSONArray(result.getString(Constants.ENABLED_OVERRIDES_ARGUMENTS)); for (int x = 0; x < arr.length(); x++) { args.add(arr.get(x)); } } catch (Exception e) { // ignore it.. this means the entry was null/corrupt } endpoint.setArguments(args.toArray(new Object[0])); return endpoint; }
[ "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" ]
[ "a small static helper to set a multi state drawable on a view\n\n@param icon\n@param iconColor\n@param selectedIcon\n@param selectedIconColor\n@param tinted\n@param imageView", "Reads a combined date and time value expressed in tenths of a minute.\n\n@param data byte array of data\n@param offset location of data as offset into the array\n@return time value", "This method is very similar to addMainHandler, except ShellFactory\nwill pass all handlers registered with this method to all this shell's subshells.\n\n@see org.gearvrf.debug.cli.Shell#addMainHandler(java.lang.Object, java.lang.String)\n\n@param handler Object which should be registered as handler.\n@param prefix Prefix that should be prepended to all handler's command names.", "Get the property name of a method name. For example the property name of\nsetSomeValue would be someValue. Names not beginning with set or get are\nnot changed.\n\n@param name The name to process\n@return The property name", "Check that the scope type is allowed by the stereotypes on the bean and\nthe bean type", "Validate the Combination filter field in Multi configuration jobs", "Adds a new gender item and an initial name.\n\n@param entityIdValue\nthe item representing the gender\n@param name\nthe label to use for representing the gender", "Extract a slice [from, to) of this buffer. This methods creates a copy of the specified region.\n@param from\n@param to\n@return", "Convert a Planner time into a Java date.\n\n0800\n\n@param value Planner time\n@return Java Date instance" ]
public static int getXPathLocation(String dom, String xpath) { String dom_lower = dom.toLowerCase(); String xpath_lower = xpath.toLowerCase(); String[] elements = xpath_lower.split("/"); int pos = 0; int temp; int number; for (String element : elements) { if (!element.isEmpty() && !element.startsWith("@") && !element.contains("()")) { if (element.contains("[")) { try { number = Integer.parseInt(element.substring(element.indexOf("[") + 1, element.indexOf("]"))); } catch (NumberFormatException e) { return -1; } } else { number = 1; } for (int i = 0; i < number; i++) { // find new open element temp = dom_lower.indexOf("<" + stripEndSquareBrackets(element), pos); if (temp > -1) { pos = temp + 1; // if depth>1 then goto end of current element if (number > 1 && i < number - 1) { pos = getCloseElementLocation(dom_lower, pos, stripEndSquareBrackets(element)); } } } } } return pos - 1; }
[ "returns position of xpath element which match the expression xpath in the String dom.\n\n@param dom the Document to search in\n@param xpath the xpath query\n@return position of xpath element, if fails returns -1" ]
[ "Use this API to fetch all the sslcipher resources that are configured on netscaler.", "Returns a Span that covers all rows beginning with a prefix.", "Record a device announcement in the devices map, so we know whe saw it.\n\n@param announcement the announcement to be recorded", "Use this API to fetch rnat6_nsip6_binding resources of given name .", "Control whether the Virtual CDJ sends status packets to the other players. Most uses of Beat Link will not\nrequire this level of activity. However, if you want to be able to take over the tempo master role, and control\nthe tempo and beat alignment of other players, you will need to turn on this feature, which also requires that\nyou are using one of the standard player numbers, 1-4.\n\n@param send if {@code true} we will send status packets, and can participate in (and control) tempo and beat sync\n\n@throws IllegalStateException if the virtual CDJ is not running, or if it is not using a device number in the\nrange 1 through 4\n@throws IOException if there is a problem starting the {@link BeatFinder}", "Retrieves the timephased breakdown of actual cost.\n\n@return timephased actual cost", "Returns status help message.\n\n@param user CmsUser\n@param disabled boolean\n@param newUser boolean\n@return String", "Re-Tag the websocket connection hold by this context with label specified.\nThis method will remove all previous tags on the websocket connection and then\ntag it with the new label.\n@param label the label.\n@return this websocket conext.", "Fired whenever a browser event is received.\n@param event Event to process" ]
private Map<StandardMethod, UnderrideLevel> findUnderriddenMethods( Iterable<ExecutableElement> methods) { Map<StandardMethod, ExecutableElement> standardMethods = new LinkedHashMap<>(); for (ExecutableElement method : methods) { Optional<StandardMethod> standardMethod = maybeStandardMethod(method); if (standardMethod.isPresent() && isUnderride(method)) { standardMethods.put(standardMethod.get(), method); } } if (standardMethods.containsKey(StandardMethod.EQUALS) != standardMethods.containsKey(StandardMethod.HASH_CODE)) { ExecutableElement underriddenMethod = standardMethods.containsKey(StandardMethod.EQUALS) ? standardMethods.get(StandardMethod.EQUALS) : standardMethods.get(StandardMethod.HASH_CODE); messager.printMessage(ERROR, "hashCode and equals must be implemented together on FreeBuilder types", underriddenMethod); } ImmutableMap.Builder<StandardMethod, UnderrideLevel> result = ImmutableMap.builder(); for (StandardMethod standardMethod : standardMethods.keySet()) { if (standardMethods.get(standardMethod).getModifiers().contains(Modifier.FINAL)) { result.put(standardMethod, UnderrideLevel.FINAL); } else { result.put(standardMethod, UnderrideLevel.OVERRIDEABLE); } } return result.build(); }
[ "Find any standard methods the user has 'underridden' in their type." ]
[ "Use this API to update nspbr6.", "Use this API to fetch lbmonitor_binding resource of given name .", "This method returns the installed identity with the requested name and version.\nIf the product name is null, the default identity will be returned.\n\nIf the product name was recognized and the requested version was not null,\nthe version comparison will take place. If the version of the currently installed product\ndoesn't match the requested one, the exception will be thrown.\nIf the requested version is null, the currently installed identity with the requested name\nwill be returned.\n\nIf the product name was not recognized among the registered ones, a new installed identity\nwith the requested name will be created and returned. (This is because the patching system\nis not aware of how many and what the patching streams there are expected).\n\n@param productName\n@param productVersion\n@return\n@throws PatchingException", "Write a message to the console.\n\n@param pattern\nA {@link String#format(String, Object...)} pattern\n@param parameters\nOptional parameters to plug into the pattern", "This is a convenience method used to add a calendar called\n\"Standard\" to the project, and populate it with a default working week\nand default working hours.\n\n@return a new default calendar", "Post-configure retreival of server engine.", "If the String argument locatorSelectionStrategy is as key in the map representing the locatorSelectionStrategies, the\ncorresponding strategy is selected, else it remains unchanged.\n@param locatorSelectionStrategy", "Use this API to fetch all the clusterinstance resources that are configured on netscaler.", "returns a collection of Reader LockEntries for object obj.\nIf now LockEntries could be found an empty Vector is returned." ]
private void applyAliases() { CustomFieldContainer fields = m_projectFile.getCustomFields(); for (Map.Entry<FieldType, String> entry : ALIASES.entrySet()) { fields.getCustomField(entry.getKey()).setAlias(entry.getValue()); } }
[ "Configure column aliases." ]
[ "Add the string representation of the given object to this sequence immediately. That is, all the trailing\nwhitespace of this sequence will be ignored and the string is appended directly after the last segment that\ncontains something besides whitespace. The given indentation will be prepended to each line except the first one\nif the object has a multi-line string representation.\n\n@param object\nthe to-be-appended object.\n@param indentation\nthe indentation string that should be prepended. May not be <code>null</code>.", "Retrieve the jdbc type for the field descriptor that is related\nto this argument.", "returns true if a job was queued within a timeout", "Counts the packages prefixes appearing in this project and if some of them make more than half of the total of existing packages, this prefix\nis returned. Otherwise, returns null.\n\nThis is just a helper, it isn't something really hard-setting the package. It's something to use if the user didn't specify using\n--mavenize.groupId, and the archive or project name is something insane, like few sencences paragraph (a description) or a number or such.", "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", "Appends the String representation of the given operand to this CharSequence.\n\n@param left a CharSequence\n@param value any Object\n@return the original toString() of the CharSequence with the object appended\n@since 1.8.2", "Copied from original SeleniumProxyHandler\nChanged SslRelay to SslListener and getSslRelayOrCreateNew to getSslRelayOrCreateNewOdo\nNo other changes to the function\n\n@param pathInContext\n@param pathParams\n@param request\n@param response\n@throws HttpException\n@throws IOException", "Generate a report about the targeted module dependencies\n\n@param moduleId String\n@param filters FiltersHolder\n@return DependencyReport", "Gets the last element in the address.\n\n@return the element, or {@code null} if {@link #size()} is zero." ]
public Collection<Contact> getList() throws FlickrException { ContactList<Contact> contacts = new ContactList<Contact>(); Map<String, Object> parameters = new HashMap<String, Object>(); parameters.put("method", METHOD_GET_LIST); Response response = transportAPI.get(transportAPI.getPath(), parameters, apiKey, sharedSecret); if (response.isError()) { throw new FlickrException(response.getErrorCode(), response.getErrorMessage()); } Element contactsElement = response.getPayload(); contacts.setPage(contactsElement.getAttribute("page")); contacts.setPages(contactsElement.getAttribute("pages")); contacts.setPerPage(contactsElement.getAttribute("perpage")); contacts.setTotal(contactsElement.getAttribute("total")); NodeList contactNodes = contactsElement.getElementsByTagName("contact"); for (int i = 0; i < contactNodes.getLength(); i++) { Element contactElement = (Element) contactNodes.item(i); Contact contact = new Contact(); contact.setId(contactElement.getAttribute("nsid")); contact.setUsername(contactElement.getAttribute("username")); contact.setRealName(contactElement.getAttribute("realname")); contact.setFriend("1".equals(contactElement.getAttribute("friend"))); contact.setFamily("1".equals(contactElement.getAttribute("family"))); contact.setIgnored("1".equals(contactElement.getAttribute("ignored"))); String lPathAlias = contactElement.getAttribute("path_alias"); contact.setPathAlias(lPathAlias == null || "".equals(lPathAlias) ? null : lPathAlias); contact.setOnline(OnlineStatus.fromType(contactElement.getAttribute("online"))); contact.setIconFarm(contactElement.getAttribute("iconfarm")); contact.setIconServer(contactElement.getAttribute("iconserver")); if (contact.getOnline() == OnlineStatus.AWAY) { contactElement.normalize(); contact.setAwayMessage(XMLUtilities.getValue(contactElement)); } contacts.add(contact); } return contacts; }
[ "Get the collection of contacts for the calling user.\n\n@return The Collection of Contact objects" ]
[ "generate a prepared INSERT-Statement for the Class\ndescribed by cld.\n\n@param cld the ClassDescriptor", "Extract schema of the key field", "Returns a BSON version document representing a new version with a new instance ID, and\nversion counter of zero.\n@return a BsonDocument representing a synchronization version", "Build a String representation of given arguments.", "Write the classifications of the Sequence classifier out to a writer in a\nformat determined by the DocumentReaderAndWriter used.\n\n@param doc Documents to write out\n@param printWriter Writer to use for output\n@throws IOException If an IO problem", "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", "Load model from file\n\n@param gvrContext Valid {@link GVRContext} instance\n@param modelFile Path to the model's file, relative to the {@code assets} directory\n@return root object The root {@link GVRSceneObject} of the model\n@throws IOException If reading the model file fails", "Detect what has changed in the store definition and rewire BDB\nenvironments accordingly.\n\n@param storeDef updated store definition", "Format the label text.\n\n@param scaleUnit The unit used for the scalebar.\n@param value The scale value.\n@param intervalUnit The scaled unit for the intervals." ]
private void cleanupLogs() throws IOException { logger.trace("Beginning log cleanup..."); int total = 0; Iterator<Log> iter = getLogIterator(); long startMs = System.currentTimeMillis(); while (iter.hasNext()) { Log log = iter.next(); total += cleanupExpiredSegments(log) + cleanupSegmentsToMaintainSize(log); } if (total > 0) { logger.warn("Log cleanup completed. " + total + " files deleted in " + (System.currentTimeMillis() - startMs) / 1000 + " seconds"); } else { logger.trace("Log cleanup completed. " + total + " files deleted in " + (System.currentTimeMillis() - startMs) / 1000 + " seconds"); } }
[ "Runs through the log removing segments older than a certain age\n\n@throws IOException" ]
[ "Checks that index is valid an throw an exception if not.\n\n@param type the type\n@param index the index to check", "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", "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.", "Reset the combination generator.", "Randomize the gradient.", "Stops the background data synchronization thread.", "Validate that the Unique IDs for the entities in this container are valid for MS Project.\nIf they are not valid, i.e one or more of them are too large, renumber them.", "This method populates the task model from data read from an MPX file.\n\n@param record data read from an MPX file\n@param isText flag indicating whether the textual or numeric data is being supplied", "Render a zero Double as null.\n\n@param value double value\n@return null if the double value is zero" ]
@Override public void validate() throws AddressStringException { if(isValidated()) { return; } synchronized(this) { if(isValidated()) { return; } //we know nothing about this address. See what it is. try { parsedAddress = getValidator().validateAddress(this); isValid = true; } catch(AddressStringException e) { cachedException = e; isValid = false; throw e; } } }
[ "Validates this string is a valid address, and if not, throws an exception with a descriptive message indicating why it is not.\n@throws AddressStringException" ]
[ "The users element defines users within the domain model, it is a simple authentication for some out of the box users.", "Sets the current switch index based on object name.\nThis function finds the child of the scene object\nthis component is attached to and sets the switch\nindex to reference it so this is the object that\nwill be displayed.\n\nIf it is out of range, none of the children will be shown.\n@param childName name of child to select\n@see GVRSceneObject#getChildByIndex(int)", "Handles the response of the SendData request.\n@param incomingMessage the response message to process.", "Used to load a classifier stored as a resource inside a jar file. THIS\nFUNCTION WILL ONLY WORK IF THE CODE WAS LOADED FROM A JAR FILE WHICH HAS A\nSERIALIZED CLASSIFIER STORED INSIDE IT.\n\n@param resourceName\nName of clasifier resource inside the jar file.\n@return A CRFClassifier stored in the jar file", "Converts plan text into anonymous text. Preserves upper case, lower case,\npunctuation, whitespace and digits while making the text unreadable.\n\n@param oldText text to replace\n@param replacements map of find/replace pairs", "Determines if the queue identified by the given key can be used as a delayed queue.\n\n@param jedis\nconnection to Redis\n@param key\nthe key that identifies a queue\n@return true if the key already is a delayed queue or is not currently used, false otherwise", "Return the list of galleries created by a user. Sorted from newest to oldest.\n\n@param userId\nThe user you want to check for\n@param perPage\nNumber of galleries per page\n@param page\nThe page number\n@return gallery\n@throws FlickrException\n\n@see <a hrerf=\"http://www.flickr.com/services/api/flickr.galleries.getList.html\">flickr.galleries.getList</a>", "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.", "Creates a text box with the given parent and text node assigned.\n@param contblock The parent node (and the containing block in the same time)\n@param n The corresponding text node in the DOM tree.\n@return The new text box." ]
public T modifyModule(final String moduleName, final String slot, final byte[] existingHash, final byte[] newHash) { final ContentItem item = createModuleItem(moduleName, slot, newHash); addContentModification(createContentModification(item, ModificationType.MODIFY, existingHash)); return returnThis(); }
[ "Modify a module.\n\n@param moduleName the module name\n@param slot the module slot\n@param existingHash the existing hash\n@param newHash the new hash of the modified content\n@return the builder" ]
[ "This function compares style ID's between features. Features are usually sorted by style.", "Pull docker image using the docker java client.\n\n@param imageTag\n@param username\n@param password\n@param host", "Will start the HiveServer.\n\n@param testConfig Specific test case properties. Will be merged with the HiveConf of the context\n@param hiveVars HiveVars to pass on to the HiveServer for this session", "get current total used capacity.\n\n@return the total used capacity", "Defers an event for processing in a later phase of the current\ntransaction.\n\n@param metadata The event object", "Return key Values of an Identity\n@param cld\n@param oid\n@param convertToSql\n@return Object[]\n@throws PersistenceBrokerException", "Sets orientation of loopbar\n\n@param orientation int value of orientation. Must be one of {@link Orientation}", "Retrieves the Material Shader ID associated with the\ngiven shader template class.\n\nA shader template is capable of generating multiple variants\nfrom a single shader source. The exact vertex and fragment\nshaders are generated by GearVRF based on the lights\nbeing used and the material attributes. you may subclass\nGVRShaderTemplate to create your own shader templates.\n\n@param shaderClass shader class to find (subclass of GVRShader)\n@return GVRShaderId associated with that shader template\n@see GVRShaderTemplate GVRShader", "Returns iban's country code and check digit.\n\n@param iban String\n@return countryCodeAndCheckDigit String" ]
private static JSONObject parseStencil(String stencilId) throws JSONException { JSONObject stencilObject = new JSONObject(); stencilObject.put("id", stencilId.toString()); return stencilObject; }
[ "Delivers the correct JSON Object for the stencilId\n\n@param stencilId\n@throws org.json.JSONException" ]
[ "Specifies convergence criteria\n\n@param maxIterations Maximum number of iterations\n@param ftol convergence based on change in function value. try 1e-12\n@param gtol convergence based on residual magnitude. Try 1e-12", "Create a list of operations required to a boot a managed server.\n\n@param serverName the server name\n@param domainModel the complete domain model\n@param hostModel the local host model\n@param domainController the domain controller\n@return the list of boot operations", "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", "gets a class from the class cache. This cache contains only classes loaded through\nthis class loader or an InnerLoader instance. If no class is stored for a\nspecific name, then the method should return null.\n\n@param name of the class\n@return the class stored for the given name\n@see #removeClassCacheEntry(String)\n@see #setClassCacheEntry(Class)\n@see #clearCache()", "Reconnect the sequence flows and the flow nodes.\nDone after the initial pass so that we have all the target information.", "Adds the correct load instruction based on the type descriptor\n\n@param code the bytecode to add the instruction to\n@param type the type of the variable\n@param variable the variable number", "Convert a field value to something suitable to be stored in the database.", "Called every frame if the picker is enabled\nto generate pick events.\n@param frameTime starting time of the current frame", "Creates the container for a bundle with descriptor.\n@return the container for a bundle with descriptor.\n@throws IOException thrown if reading the bundle fails.\n@throws CmsException thrown if reading the bundle fails." ]
private void populateCalendarHours(Record record, ProjectCalendarHours hours) throws MPXJException { hours.setDay(Day.getInstance(NumberHelper.getInt(record.getInteger(0)))); addDateRange(hours, record.getTime(1), record.getTime(2)); addDateRange(hours, record.getTime(3), record.getTime(4)); addDateRange(hours, record.getTime(5), record.getTime(6)); }
[ "Populates a calendar hours instance.\n\n@param record MPX record\n@param hours calendar hours instance\n@throws MPXJException" ]
[ "Painter the tile, by building a URL where the image can be found.\n\n@param tile\nMust be an instance of {@link InternalTile}, and must have a non-null {@link RasterUrlBuilder}.\n@return Returns a {@link InternalTile}.", "Lookup an object instance from JNDI context.\n\n@param jndiName JNDI lookup name\n@return Matching object or <em>null</em> if none found.", "Removes the given object from the cache\n\n@param oid oid of the object to remove", "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", "Invoked when an action occurs.", "Returns a list of all parts that have been uploaded to an upload session.\n@param offset paging marker for the list of parts.\n@param limit maximum number of parts to return.\n@return the list of parts.", "Iterate through dependencies", "Use this API to rename a cmppolicylabel resource.", "Return the position of an element inside an array\n\n@param array the array where it looks for an element\n@param element the element to find in the array\n@param <T> the type of elements in the array\n@return the position of the element if it's found in the array, -1 otherwise" ]
public void loadModel(GVRAndroidResource avatarResource) { EnumSet<GVRImportSettings> settings = GVRImportSettings.getRecommendedSettingsWith(EnumSet.of(GVRImportSettings.OPTIMIZE_GRAPH, GVRImportSettings.NO_ANIMATION)); GVRContext ctx = mAvatarRoot.getGVRContext(); GVRResourceVolume volume = new GVRResourceVolume(ctx, avatarResource); GVRSceneObject modelRoot = new GVRSceneObject(ctx); mAvatarRoot.addChildObject(modelRoot); ctx.getAssetLoader().loadModel(volume, modelRoot, settings, false, mLoadModelHandler); }
[ "Load the avatar base model\n@param avatarResource resource with avatar model" ]
[ "Constructs a full capability name from a static base name and a dynamic element.\n\n@param baseName the base name. Cannot be {@code null}\n@param dynamicNameElement the dynamic portion of the name. Cannot be {@code null}\n@return the full capability name. Will not return {@code null}", "Read file content to string.\n\n@param filePath\nthe file path\n@return the string\n@throws IOException\nSignals that an I/O exception has occurred.", "Read tasks representing the WBS.", "Specify the address of the SOCKS proxy the connection should\nuse.\n\n<p>Read the <a href=\"http://java.sun.com/javase/6/docs/technotes/guides/net/proxies.html\">\nJava Networking and Proxies</a> guide to understand the\nproxies complexity.\n\n<p>Be aware that this method only handles SOCKS proxies, not\nHTTPS proxies. Use {@link #withProxy(Proxy)} instead.\n\n@param host the hostname of the SOCKS proxy\n@param port the port of the SOCKS proxy server\n@return this", "Invoked when an action occurs.", "Locates the services in the context classloader of the current thread.\n\n@param serviceType the type of the services to locate\n@param <X> the type of the service\n@return the service type loader", "Populate a resource assignment.\n\n@param record MPX record\n@param assignment resource assignment\n@throws MPXJException", "Returns the full record for a single attachment.\n\n@param attachment Globally unique identifier for the attachment.\n@return Request object", "Merge the contents of the given plugin.xml into this one." ]
public Object getRealSubject() throws PersistenceBrokerException { if (_realSubject == null) { beforeMaterialization(); _realSubject = materializeSubject(); afterMaterialization(); } return _realSubject; }
[ "Returns the proxies real subject. The subject will be materialized if\nnecessary.\n\n@return The subject" ]
[ "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.", "Set the directory and test that the directory exists and is contained within the Configuration\ndirectory.\n\n@param directory the new directory", "Builds the path for an open arc based on a PolylineOptions.\n\n@param center\n@param start\n@param end\n@return PolylineOptions with the paths element populated.", "General API\n-> compile each of supplied files\n-> recompile any required types for which we have an incomplete principle structure", "Return all tenors for which data exists.\n\n@return The tenors in months.", "Create new logging action\nThis method check if there is an old instance for this thread-local\nIf not - Initialize new instance and set it as this thread-local's instance\n@param logger\n@param auditor\n@param instance\n@return whether new instance was set to thread-local", "This method is currently in use only by the SvnCoordinator", "Solve the using the lower triangular matrix in LU. Diagonal elements are assumed\nto be 1", "Get the sub registry for the domain.\n\n@param range the version range\n@return the sub registry" ]
public boolean addDescriptor() { saveLocalization(); IndexedContainer oldContainer = m_container; try { createAndLockDescriptorFile(); unmarshalDescriptor(); updateBundleDescriptorContent(); m_hasMasterMode = true; m_container = createContainer(); m_editorState.put(EditMode.DEFAULT, getDefaultState()); m_editorState.put(EditMode.MASTER, getMasterState()); } catch (CmsException | IOException e) { LOG.error(e.getLocalizedMessage(), e); if (m_descContent != null) { m_descContent = null; } if (m_descFile != null) { m_descFile = null; } if (m_desc != null) { try { m_cms.deleteResource(m_desc, CmsResourceDeleteMode.valueOf(1)); } catch (CmsException ex) { LOG.error(ex.getLocalizedMessage(), ex); } m_desc = null; } m_hasMasterMode = false; m_container = oldContainer; return false; } m_removeDescriptorOnCancel = true; return true; }
[ "Creates a descriptor for the currently edited message bundle.\n@return <code>true</code> if the descriptor could be created, <code>false</code> otherwise." ]
[ "Return given duration in a human-friendly format. For example, \"4\nminutes\" or \"1 second\". Returns only largest meaningful unit of time,\nfrom seconds up to hours.\n\nThe longest duration it supports is hours.\n\nThis method assumes that there are 60 minutes in an hour,\n60 seconds in a minute and 1000 milliseconds in a second.\nAll currently supplied chronologies use this definition.", "Login for a specific authentication, creating a specific token if given.\n\n@param token token to use\n@param authentication authentication to assign to token\n@return token", "Click handler for bottom drawer items.", "Parse the XML for a collection as returned by getTree call.\n\n@param collectionElement\n@return", "Use this API to update inatparam.", "copy all fields from the \"from\" object to the \"to\" object.\n\n@param from source object\n@param to from's clone\n@param fields fields to be populated\n@param accessible 'true' if all 'fields' have been made accessible during\ntraversal", "return null if the operation has no params to validate", "Write a Date attribute.\n\n@param name attribute name\n@param value attribute value", "Inserts a CharSequence array value into the mapping of the underlying Bundle, replacing any\nexisting value for the given key. Either key or value may be null.\n\n@param key a String, or null\n@param value a CharSequence array object, or null\n@return this bundler instance to chain method calls" ]
public void forceApply(String conflictResolution) { URL url = FORCE_METADATA_CASCADE_POLICIES_URL_TEMPLATE.build(this.getAPI().getBaseURL(), this.getID()); BoxJSONRequest request = new BoxJSONRequest(this.getAPI(), url, "POST"); JsonObject requestJSON = new JsonObject() .add("conflict_resolution", conflictResolution); request.setBody(requestJSON.toString()); request.send(); }
[ "If a policy already exists on a folder, this will apply that policy to all existing files and sub folders within\nthe target folder.\n\n@param conflictResolution the desired behavior for conflict-resolution. Set to either none or overwrite." ]
[ "The indices space is ignored for reduce ops other than min or max.", "Populate the authenticated user profiles in the Shiro subject.\n\n@param profiles the linked hashmap of profiles", "Returns the value of the primitive type from the given string value.\n\n@param value the value to parse\n@param cls the primitive type class\n@return the boxed type value or {@code null} if the given class is not a primitive type", "Sets a listener to inform when the user closes the SearchView.\n\n@param listener the listener to call when the user closes the SearchView.", "Gets the favorite entries corresponding to the currently displayed favorite widgets.\n\n@return the list of favorite entries", "Send ourselves \"updates\" about any tracks that were loaded before we started, since we missed them.", "Returns the number of consecutive leading one or zero bits.\nIf network is true, returns the number of consecutive leading one bits.\nOtherwise, returns the number of consecutive leading zero bits.\n\n@param network\n@return", "Wrapper delayed emission, based on delayProvider.\n\n@param event the event to emit\n@param milliseconds the delay in milliseconds\n@param <T> the type of event\n@return delayed observable", "Normalizes the name so it can be used as Maven artifactId or groupId." ]
public Set<CoreDocumentSynchronizationConfig> getSynchronizedDocuments( final MongoNamespace namespace ) { this.waitUntilInitialized(); try { ongoingOperationsGroup.enter(); return this.syncConfig.getSynchronizedDocuments(namespace); } finally { ongoingOperationsGroup.exit(); } }
[ "Returns the set of synchronized documents in a namespace.\n\n@param namespace the namespace to get synchronized documents for.\n@return the set of synchronized documents in a namespace." ]
[ "This filter permit to return an image sized exactly as requested wherever is its ratio by\nfilling with chosen color the missing parts. Usually used with \"fit-in\" or \"adaptive-fit-in\"\n\n@param color integer representation of color.", "Write exceptions in the format used by MSPDI files prior to Project 2007.\n\n@param dayList list of calendar days\n@param exceptions list of exceptions", "Returns all the retention policies with specified filters.\n@param name a name to filter the retention policies by. A trailing partial match search is performed.\nSet to null if no name filtering is required.\n@param type a policy type to filter the retention policies by. Set to null if no type filtering is required.\n@param userID a user id to filter the retention policies by. Set to null if no type filtering is required.\n@param limit the limit of items per single response. The default value is 100.\n@param api the API connection to be used by the resource.\n@param fields the fields to retrieve.\n@return an iterable with all the retention policies met search conditions.", "List app dynos for an app\n\n@param appName See {@link #listApps} for a list of apps that can be used.", "Adds a Statement to a given collection of statement groups.\nIf the statement id is not null and matches that of an existing statement,\nthis statement will be replaced.\n\n@param statement\n@param claims\n@return", "Kicks off an animation that will result in the pointer being centered in the\npie slice of the currently selected item.", "Returns the first 24 photos for a given tag cluster.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@param tag\n@param clusterId\n@return PhotoList\n@throws FlickrException", "Accessor method used to retrieve an Duration object representing the\ncontents of an individual field. If the field does not exist in the\nrecord, null is returned.\n\n@param field the index number of the field to be retrieved\n@return the value of the required field\n@throws MPXJException normally thrown when parsing fails", "This method extracts resource data from a Phoenix file.\n\n@param phoenixProject parent node for resources" ]
public static void registerDeploymentResource(final DeploymentResourceSupport deploymentResourceSupport, final LoggingConfigurationService service) { final PathElement base = PathElement.pathElement("configuration", service.getConfiguration()); deploymentResourceSupport.getDeploymentSubModel(LoggingExtension.SUBSYSTEM_NAME, base); final LogContextConfiguration configuration = service.getValue(); // Register the child resources if the configuration is not null in cases where a log4j configuration was used if (configuration != null) { registerDeploymentResource(deploymentResourceSupport, base, HANDLER, configuration.getHandlerNames()); registerDeploymentResource(deploymentResourceSupport, base, LOGGER, configuration.getLoggerNames()); registerDeploymentResource(deploymentResourceSupport, base, FORMATTER, configuration.getFormatterNames()); registerDeploymentResource(deploymentResourceSupport, base, FILTER, configuration.getFilterNames()); registerDeploymentResource(deploymentResourceSupport, base, POJO, configuration.getPojoNames()); registerDeploymentResource(deploymentResourceSupport, base, ERROR_MANAGER, configuration.getErrorManagerNames()); } }
[ "Registers the deployment resources needed.\n\n@param deploymentResourceSupport the deployment resource support\n@param service the service, which may be {@code null}, used to find the resource names that need to be registered" ]
[ "Retrieve a FieldType instance based on an ID value from\nan MPP9 or MPP12 file.\n\n@param fieldID field ID\n@return FieldType instance", "Call batch tasks inside of a connection which may, or may not, have been \"saved\".", "Initializes the persistence strategy to be used when accessing the datastore. In particular, all the required\ncaches will be configured and initialized.\n\n@param cacheMappingType the {@link org.hibernate.ogm.datastore.keyvalue.options.CacheMappingType} to be used\n@param entityTypes meta-data of all the entity types registered with the current session factory\n@param associationTypes meta-data of all the association types registered with the current session factory\n@param idSourceTypes meta-data of all the id source types registered with the current session factory\n@param namespaces from the database currently in use", "Obtains a local date in Symmetry454 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 Symmetry454 local date, not null\n@throws DateTimeException if unable to create the date", "Returns all the elements in the sorted set with a score in the given range.\nIn contrary to the default ordering of sorted sets, for this command the elements are considered to be ordered\nfrom high to low scores.\nThe elements having the same score are returned in reverse lexicographical order.\n@param scoreRange\n@return elements in the specified score range", "Parses the result and returns the failure description. If the result was successful, an empty string is\nreturned.\n\n@param result the result of executing an operation\n\n@return the failure message or an empty string", "Returns the currently set filters in a map column -> filter.\n\n@return the currently set filters in a map column -> filter.", "Set RGB input range.\n\n@param inRGB Range.", "Check whether error handling works. If it works, you should see an\nok, otherwise, you might see the actual error message and then\nthe program exits." ]
@SuppressWarnings("unchecked") public static <E> E getObject(String className) { if (className == null) { return (E) null; } try { return (E) Class.forName(className).newInstance(); } catch (InstantiationException e) { throw new RuntimeException(e); } catch (IllegalAccessException e) { throw new RuntimeException(e); } catch (ClassNotFoundException e) { throw new RuntimeException(e); } }
[ "create an instance from the className\n@param <E> class of object\n@param className full class name\n@return an object or null if className is null" ]
[ "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", "Delete a path recursively, not throwing Exception if it fails or if the path is null.\n@param path a Path pointing to a file or a directory that may not exists anymore.", "Lookup the data-type associated with the class.\n\n@return The associated data-type interface or null if none found.", "Obtains a Symmetry010 local date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Symmetry010 local date-time, not null\n@throws DateTimeException if unable to create the date-time", "Get content of a file as a Map&lt;String, String&gt;, using separator to split values\n@param file File to get content\n@param separator The separator\n@return The map with the values\n@throws IOException I/O Error", "Removes an accessory from being handled or advertised by this root. Any existing Homekit\nconnections will be terminated to allow the clients to reconnect and see the updated accessory\nlist.\n\n@param accessory accessory to cease advertising and handling", "Store an Object.\n@see org.apache.ojb.broker.PersistenceBroker#store(Object)", "For each node, checks if the store exists and then verifies that the remote schema\nmatches the new one. If the remote store doesn't exist, it creates it.", "Registers Jersey HeaderDelegateProviders for the specified TinyTypes.\n\n@param head a TinyType\n@param tail other TinyTypes\n@throws IllegalArgumentException when a non-TinyType is given" ]
public static base_response update(nitro_service client, aaaparameter resource) throws Exception { aaaparameter updateresource = new aaaparameter(); updateresource.enablestaticpagecaching = resource.enablestaticpagecaching; updateresource.enableenhancedauthfeedback = resource.enableenhancedauthfeedback; updateresource.defaultauthtype = resource.defaultauthtype; updateresource.maxaaausers = resource.maxaaausers; updateresource.maxloginattempts = resource.maxloginattempts; updateresource.failedlogintimeout = resource.failedlogintimeout; updateresource.aaadnatip = resource.aaadnatip; return updateresource.update_resource(client); }
[ "Use this API to update aaaparameter." ]
[ "Scans a set of classes for both ReaderListeners and Swagger annotations. All found listeners will\nbe instantiated before any of the classes are scanned for Swagger annotations - so they can be invoked\naccordingly.\n\n@param classes a set of classes to scan\n@return the generated Swagger definition", "For the DC to check whether an operation should be ignored on the slave, if the slave is set up to ignore config not relevant to it\n\n@param domainResource the domain root resource\n@param serverConfigs the server configs the slave is known to have\n@param pathAddress the address of the operation to check if should be ignored or not", "Helper method for variance calculations.\n@return The sum of the squares of the differences between\neach value and the arithmetic mean.\n@throws EmptyDataSetException If the data set is empty.", "Facade method facilitating the creation of subshell.\nSubshell is created and run inside Command method and shares the same IO and naming strtategy.\n\nRun the obtained Shell with commandLoop().\n\n@param pathElement sub-prompt\n@param parent Shell to be subshell'd\n@param appName The app name string\n@param mainHandler Command handler\n@return subshell", "Returns a date and time string which is formatted as ISO-8601.", "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", "Extract the subscription ID from a resource ID string.\n@param id the resource ID string\n@return the subscription ID", "Inserts the LokenList immediately following the 'before' token", "Creates a timespan from a list of other timespans.\n\n@return a timespan representing the sum of all the timespans provided" ]
private void addMetadataProviderForMedia(String key, MetadataProvider provider) { if (!metadataProviders.containsKey(key)) { metadataProviders.put(key, Collections.newSetFromMap(new ConcurrentHashMap<MetadataProvider, Boolean>())); } Set<MetadataProvider> providers = metadataProviders.get(key); providers.add(provider); }
[ "Internal method that adds a metadata provider to the set associated with a particular hash key, creating the\nset if needed.\n\n@param key the hashKey identifying the media for which this provider can offer metadata (or the empty string if\nit can offer metadata for all media)\n@param provider the metadata provider to be added to the active set" ]
[ "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", "Use this API to fetch aaagroup_vpntrafficpolicy_binding resources of given name .", "Method that takes an inputstream, read it preserving the end lines, and subtitute using commons-lang-3 calls\nthe variables, first searching as system properties vars and then in environment var list.\nIn case of missing the property is replaced by white space.\n@param stream\n@return", "Get the hours difference", "Invoked by subclasses; performs actual file roll. Tests to see whether roll\nis necessary have already been performed, so just do it.", "Cancel all task with this tag and returns the canceled task count\n\n@param tagToCancel\n@return", "Enables or disabled shadow casting for a spot light.\nEnabling shadows attaches a GVRShadowMap component to the\nGVRSceneObject which owns the light and provides the\ncomponent with an perspective camera for shadow casting.\n@param enableFlag true to enable shadow casting, false to disable", "Processes a row of the sites table and stores the site information found\ntherein.\n\n@param siteRow\nstring serialisation of a sites table row as found in the SQL\ndump", "Return the index associated to the Renderer.\n\n@param renderer used to search in the prototypes collection.\n@return the prototype index associated to the renderer passed as argument." ]
public void execute() throws MojoExecutionException, MojoFailureException { try { Set<File> thriftFiles = findThriftFiles(); final File outputDirectory = getOutputDirectory(); ImmutableSet<File> outputFiles = findGeneratedFilesInDirectory(getOutputDirectory()); Set<String> compileRoots = new HashSet<String>(); compileRoots.add("scrooge"); if (thriftFiles.isEmpty()) { getLog().info("No thrift files to compile."); } else if (checkStaleness && ((lastModified(thriftFiles) + staleMillis) < lastModified(outputFiles))) { getLog().info("Generated thrift files up to date, skipping compile."); attachFiles(compileRoots); } else { outputDirectory.mkdirs(); // Quick fix to fix issues with two mvn installs in a row (ie no clean) cleanDirectory(outputDirectory); getLog().info(format("compiling thrift files %s with Scrooge", thriftFiles)); synchronized(lock) { ScroogeRunner runner = new ScroogeRunner(); Map<String, String> thriftNamespaceMap = new HashMap<String, String>(); for (ThriftNamespaceMapping mapping : thriftNamespaceMappings) { thriftNamespaceMap.put(mapping.getFrom(), mapping.getTo()); } // Include thrifts from resource as well. Set<File> includes = thriftIncludes; includes.add(getResourcesOutputDirectory()); // Include thrift root final File thriftSourceRoot = getThriftSourceRoot(); if (thriftSourceRoot != null && thriftSourceRoot.exists()) { includes.add(thriftSourceRoot); } runner.compile( getLog(), includeOutputDirectoryNamespace ? new File(outputDirectory, "scrooge") : outputDirectory, thriftFiles, includes, thriftNamespaceMap, language, thriftOpts); } attachFiles(compileRoots); } } catch (IOException e) { throw new MojoExecutionException("An IO error occurred", e); } }
[ "Executes the mojo." ]
[ "To read an object in a quick & dirty way. Prepare to handle failures when object serialization changes!", "Registers your facet filters, adding them to this InstantSearch's widgets.\n\n@param filters a List of facet filters.", "LRN cross-channel forward computation. Double parameters cast to tensor data type", "Check if number is valid\n\n@return boolean", "Returns a client object for a clientId\n\n@param clientId ID of client to return\n@return Client or null\n@throws Exception exception", "Set the values using the specified Properties object.\n\n@param properties Properties object containing specific property values\nfor the RESTClient config\n\nNote: We're using the same property names as that in ClientConfig\nfor backwards compatibility.", "Get a date range that correctly handles the case where the end time\nis midnight. In this instance the end time should be the start of the\nnext day.\n\n@param hours calendar hours\n@param start start date\n@param end end date", "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.", "Get the QNames of the port components to be declared\nin the namespaces\n\n@return collection of QNames" ]
private String formatTaskType(TaskType value) { return (LocaleData.getString(m_locale, (value == TaskType.FIXED_DURATION ? LocaleData.YES : LocaleData.NO))); }
[ "This method is called to format a task type.\n\n@param value task type value\n@return formatted task type" ]
[ "Cancel a particular download in progress. Returns 1 if the download Id is found else returns 0.\n\n@param downloadId\n@return int", "Return the project name or the default project name.", "Converts to a link-local Ipv6 address. Any MAC prefix length is ignored. Other elements of this address section are incorporated into the conversion.\nThis will provide the latter 4 segments of an IPv6 address, to be paired with the link-local IPv6 prefix of 4 segments.\n\n@return", "Get the short exception message using the requested locale. This does not include the cause exception message.\n\n@param locale locale for message\n@return (short) exception message", "This essentially ensures that we only store a single Vertex for each unique \"Set\" of tags.", "Samples without 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", "Extracts value from map if given value is null.\n@param value current value\n@param props properties to extract value from\n@param key property name to extract\n@return initial value or value extracted from map", "IS NULL predicate\n@param value the value for which to check\n@return a {@link LuaCondition} instance", "Format a date that is parseable from JavaScript, according to ISO-8601.\n\n@param date the date to format to a JSON string\n@return a formatted date in the form of a string" ]
public int blast(InputStream input, OutputStream output) throws IOException { m_input = input; m_output = output; int lit; /* true if literals are coded */ int dict; /* log2(dictionary size) - 6 */ int symbol; /* decoded symbol, extra bits for distance */ int len; /* length for copy */ int dist; /* distance for copy */ int copy; /* copy counter */ //unsigned char *from, *to; /* copy pointers */ /* read header */ lit = bits(8); if (lit > 1) { return -1; } dict = bits(8); if (dict < 4 || dict > 6) { return -2; } /* decode literals and length/distance pairs */ do { if (bits(1) != 0) { /* get length */ symbol = decode(LENCODE); len = BASE[symbol] + bits(EXTRA[symbol]); if (len == 519) { break; /* end code */ } /* get distance */ symbol = len == 2 ? 2 : dict; dist = decode(DISTCODE) << symbol; dist += bits(symbol); dist++; if (m_first != 0 && dist > m_next) { return -3; /* distance too far back */ } /* copy length bytes from distance bytes back */ do { //to = m_out + m_next; int to = m_next; int from = to - dist; copy = MAXWIN; if (m_next < dist) { from += copy; copy = dist; } copy -= m_next; if (copy > len) { copy = len; } len -= copy; m_next += copy; do { //*to++ = *from++; m_out[to++] = m_out[from++]; } while (--copy != 0); if (m_next == MAXWIN) { //if (s->outfun(s->outhow, s->out, s->next)) return 1; m_output.write(m_out, 0, m_next); m_next = 0; m_first = 0; } } while (len != 0); } else { /* get literal and write it */ symbol = lit != 0 ? decode(LITCODE) : bits(8); m_out[m_next++] = (byte) symbol; if (m_next == MAXWIN) { //if (s->outfun(s->outhow, s->out, s->next)) return 1; m_output.write(m_out, 0, m_next); m_next = 0; m_first = 0; } } } while (true); if (m_next != 0) { m_output.write(m_out, 0, m_next); } return 0; }
[ "Decode PKWare Compression Library stream.\n\nFormat notes:\n\n- First byte is 0 if literals are uncoded or 1 if they are coded. Second\nbyte is 4, 5, or 6 for the number of extra bits in the distance code.\nThis is the base-2 logarithm of the dictionary size minus six.\n\n- Compressed data is a combination of literals and length/distance pairs\nterminated by an end code. Literals are either Huffman coded or\nuncoded bytes. A length/distance pair is a coded length followed by a\ncoded distance to represent a string that occurs earlier in the\nuncompressed data that occurs again at the current location.\n\n- A bit preceding a literal or length/distance pair indicates which comes\nnext, 0 for literals, 1 for length/distance.\n\n- If literals are uncoded, then the next eight bits are the literal, in the\nnormal bit order in the stream, i.e. no bit-reversal is needed. Similarly,\nno bit reversal is needed for either the length extra bits or the distance\nextra bits.\n\n- Literal bytes are simply written to the output. A length/distance pair is\nan instruction to copy previously uncompressed bytes to the output. The\ncopy is from distance bytes back in the output stream, copying for length\nbytes.\n\n- Distances pointing before the beginning of the output data are not\npermitted.\n\n- Overlapped copies, where the length is greater than the distance, are\nallowed and common. For example, a distance of one and a length of 518\nsimply copies the last byte 518 times. A distance of four and a length of\ntwelve copies the last four bytes three times. A simple forward copy\nignoring whether the length is greater than the distance or not implements\nthis correctly.\n\n@param input InputStream instance\n@param output OutputStream instance\n@return status code" ]
[ "Use this API to apply nspbr6.", "Only call with the read lock held", "Use this API to fetch a appfwglobal_auditnslogpolicy_binding resources.", "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", "Return a Halton number, sequence starting at index = 0, base &gt; 1.\n\n@param index The index of the sequence.\n@param base The base of the sequence. Has to be greater than one (this is not checked).\n@return The Halton number.", "Processes an anonymous reference definition.\n\n@param attributes The attributes of the tag\n@exception XDocletException If an error occurs\[email protected] type=\"content\"\[email protected] name=\"attributes\" optional=\"true\" description=\"Attributes of the reference as name-value pairs 'name=value',\nseparated by commas\"\[email protected] name=\"auto-delete\" optional=\"true\" description=\"Whether to automatically delete the\nreferenced object on object deletion\"\[email protected] name=\"auto-retrieve\" optional=\"true\" description=\"Whether to automatically retrieve\nthe referenced object\"\[email protected] name=\"auto-update\" optional=\"true\" description=\"Whether to automatically update the\nreferenced object\"\[email protected] name=\"class-ref\" optional=\"false\" description=\"The fully qualified name of the class\nowning the referenced field\"\[email protected] name=\"documentation\" optional=\"true\" description=\"Documentation on the reference\"\[email protected] name=\"foreignkey\" optional=\"true\" description=\"The fields in the current type used for\nimplementing the reference\"\[email protected] name=\"otm-dependent\" optional=\"true\" description=\"Whether the reference is dependent on otm\"\[email protected] name=\"proxy\" optional=\"true\" description=\"Whether to use a proxy for the reference\"\[email protected] name=\"proxy-prefetching-limit\" optional=\"true\" description=\"Specifies the amount of objects to prefetch\"\[email protected] name=\"refresh\" optional=\"true\" description=\"Whether to automatically refresh the\nreference\"\[email protected] name=\"remote-foreignkey\" optional=\"true\" description=\"The fields in the referenced type\ncorresponding to the local fields (is only used for the table definition)\"", "This method is used to associate a child task with the current\ntask instance. It has been designed to\nallow the hierarchical outline structure of tasks in an MPX\nfile to be updated once all of the task data has been read.\n\n@param child child task", "Utility method to remove ampersands embedded in names.\n\n@param name name text\n@return name text without embedded ampersands", "Fling the content\n\n@param velocityX The initial velocity in the X direction. Positive numbers mean that the\nfinger/cursor is moving to the left on the screen, which means we want to\nscroll towards the beginning.\n@param velocityY The initial velocity in the Y direction. Positive numbers mean that the\nfinger/cursor is moving down the screen, which means we want to scroll\ntowards the top.\n@param velocityZ TODO: Z-scrolling is currently not supported\n@return" ]
public static ModelNode createReadResourceOperation(final ModelNode address, final boolean recursive) { final ModelNode op = createOperation(READ_RESOURCE_OPERATION, address); op.get(RECURSIVE).set(recursive); return op; }
[ "Creates an operation to read a resource.\n\n@param address the address to create the read for\n@param recursive whether to search recursively or not\n\n@return the operation" ]
[ "Adds a resource collection with execution hints.", "Invalidating just the GVRView associated with the GVRViewSceneObject\nincorrectly set the clip rectangle to just that view. To fix this,\nwe have to create a full screen android View and invalidate this\nto restore the clip rectangle.\n@return full screen View object", "Print the common class node's properties", "Handles the response of the SerialApiGetInitData request.\n@param incomingMlivessage the response message to process.", "If the String argument locatorSelectionStrategy is as key in the map representing the locatorSelectionStrategies, the\ncorresponding strategy is selected, else it remains unchanged.\n@param locatorSelectionStrategy", "Waits until all pending operations are complete and closes this repository.\n\n@param failureCauseSupplier the {@link Supplier} that creates a new {@link CentralDogmaException}\nwhich will be used to fail the operations issued after this method is called", "Returns iterable containing assignments for this single legal hold policy.\n@param fields the fields to retrieve.\n@return an iterable containing assignments for this single legal hold policy.", "Examins the structure of A for QR decomposition\n@param A matrix which is to be decomposed\n@return true if the solution is valid or false if the decomposition can't be performed (i.e. requires column pivots)", "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" ]
public static base_response delete(nitro_service client) throws Exception { locationfile deleteresource = new locationfile(); return deleteresource.delete_resource(client); }
[ "Use this API to delete locationfile." ]
[ "makes a deep clone of the object, using reflection.\n@param toCopy the object you want to copy\n@return", "Format the message using the pattern and the arguments.\n\n@param pattern the pattern in the format of \"{1} this is a {2}\"\n@param arguments the arguments.\n@return the formatted result.", "This method extracts task data from an MSPDI file.\n\n@param project Root node of the MSPDI file", "Process any StepEvent. You can change last added to stepStorage\nstep using this method.\n\n@param event to process", "Use this API to fetch hanode_routemonitor_binding resources of given name .", "Set the TableAlias for ClassDescriptor", "Use this API to apply nspbr6.", "Obtains the collection of server groups defined for a profile\n\n@param model\n@param profileId\n@return\n@throws Exception", "Use picasso to render the video thumbnail into the thumbnail widget using a temporal\nplaceholder.\n\n@param video to get the rendered thumbnail." ]
public void render(OutputStream outputStream, Format format, int dpi) throws PrintingException { try { if (baos == null) { prepare(); } writeDocument(outputStream, format, dpi); } catch (Exception e) { // NOSONAR throw new PrintingException(e, PrintingException.DOCUMENT_RENDER_PROBLEM); } }
[ "Renders the document to the specified output stream." ]
[ "Called to update the cached formats when something changes.", "This method is called by the ++ operator for the class CharSequence.\nIt increments the last character in the given CharSequence. If the last\ncharacter in the CharSequence is Character.MAX_VALUE a Character.MIN_VALUE\nwill be appended. The empty CharSequence is incremented to a string\nconsisting of the character Character.MIN_VALUE.\n\n@param self a CharSequence\n@return a value obtained by incrementing the toString() of the CharSequence\n@since 1.8.2", "Converters the diffusion coefficient to hydrodynamic diameter and vice versa\n@param value Diffusion coefficient in [m^2 s^-1] or hydrodynamic diameter in [m]\n@param temperatur Temperatur in [Kelvin]\n@param viscosity Viscosity in [kg m^-1 s^-1]\n@return Hydrodynmaic diameter [m] / diffusion coefficient [m^2 s^-1]", "We have received an update that invalidates any previous metadata for that player, so clear it out, and alert\nany listeners if this represents a change. This does not affect the hot cues; they will stick around until the\nplayer loads a new track that overwrites one or more of them.\n\n@param update the update which means we can have no metadata for the associated player", "retrieve an Object by query\nI.e perform a SELECT ... FROM ... WHERE ... in an RDBMS", "This method writes resource data to a PM XML file.", "Prepare a parallel HTTP GET Task.\n\n@param url\nthe UrlPostfix: e.g. in http://localhost:8080/index.html.,the url is \"/index.html\"\n@return the parallel task builder", "Ask the specified player for metadata about the track in the specified slot with the specified rekordbox ID,\nusing cached media instead if it is available, and possibly giving up if we are in passive mode.\n\n@param track uniquely identifies the track whose metadata is desired\n@param trackType identifies the type of track being requested, which affects the type of metadata request\nmessage that must be used\n@param failIfPassive will prevent the request from taking place if we are in passive mode, so that automatic\nmetadata updates will use available caches only\n\n@return the metadata found, if any", "Extract data for a single task.\n\n@param parent task parent\n@param row Synchro task data" ]
public String getUniformDescriptor(GVRContext ctx) { if (mShaderTemplate == null) { mShaderTemplate = makeTemplate(ID, ctx); ctx.getShaderManager().addShaderID(this); } return mShaderTemplate.getUniformDescriptor(); }
[ "Gets the string describing the uniforms used by shaders of this type.\n@param ctx GVFContext shader is associated with\n@return uniform descriptor string\n@see #getTemplate(GVRContext) GVRShader#getUniformDescriptor()" ]
[ "Discard the changes.", "Seeks to the given season within the given year\n\n@param seasonString\n@param yearString", "Use this API to fetch all the vpath resources that are configured on netscaler.", "A convenience method for creating an immutable map.\n\n@param self a Map\n@return an immutable Map\n@see java.util.Collections#unmodifiableMap(java.util.Map)\n@since 1.0", "Sets an element in at the specified index.", "This method extracts data for a single calendar from an MSPDI file.\n\n@param calendar Calendar data\n@param map Map of calendar UIDs to names\n@param baseCalendars list of base calendars", "Copies all elements from input into output which are &gt; tol.\n@param input (Input) input matrix. Not modified.\n@param output (Output) Output matrix. Modified and shaped to match input.\n@param tol Tolerance for defining zero", "Use this API to fetch appfwpolicy_csvserver_binding resources of given name .", "create a HTTP POST request.\n\n@return {@link HttpConnection}" ]
public static LinearSolverDense<DMatrixRMaj> general(int numRows , int numCols ) { if( numRows == numCols ) return linear(numRows); else return leastSquares(numRows,numCols); }
[ "Creates a general purpose solver. Use this if you are not sure what you need.\n\n@param numRows The number of rows that the decomposition is optimized for.\n@param numCols The number of columns that the decomposition is optimized for." ]
[ "Sets allowed values for attribute\n\n@param allowedValues values that are legal as part in this attribute\n@return a builder that can be used to continue building the attribute definition", "Return all valid tenors for a given moneyness and maturity.\nUses the payment times of the fix schedule to determine fractions.\n\n@param moneyness The moneyness as actual offset from par swap rate for which to get the maturities.\n@param maturity The maturities as year fraction from the reference date.\n@return The tenors as year fraction from reference date.", "Run a CLI script from a File.\n\n@param script The script file.", "Retrieve a specific row by index number, creating a blank row if this row does not exist.\n\n@param index index number\n@return MapRow instance", "Returns the response error stream, handling the case when it contains gzipped data.\n@return gzip decoded (if needed) error stream or null", "Verify that the given channels are all valid.\n\n@param channels\nthe given channels", "Set the week day the events should occur.\n@param weekDay the week day to set.", "Support the range subscript operator for String with IntRange\n\n@param text a String\n@param range an IntRange\n@return the resulting String\n@since 1.0", "Calculate start dates for a yearly recurrence.\n\n@param calendar current date\n@param dates array of start dates" ]
public void addRow(String primaryKeyColumnName, Map<String, Object> map) { Integer rowNumber = Integer.valueOf(m_rowNumber++); map.put("ROW_NUMBER", rowNumber); Object primaryKey = null; if (primaryKeyColumnName != null) { primaryKey = map.get(primaryKeyColumnName); } if (primaryKey == null) { primaryKey = rowNumber; } MapRow newRow = new MapRow(map); MapRow oldRow = m_rows.get(primaryKey); if (oldRow == null) { m_rows.put(primaryKey, newRow); } else { int oldVersion = oldRow.getInteger("ROW_VERSION").intValue(); int newVersion = newRow.getInteger("ROW_VERSION").intValue(); if (newVersion > oldVersion) { m_rows.put(primaryKey, newRow); } } }
[ "Add a row to the table. We have a limited understanding of the way\nBtrieve handles outdated rows, so we use what we think is a version number\nto try to ensure that we only have the latest rows.\n\n@param primaryKeyColumnName primary key column name\n@param map Map containing row data" ]
[ "Helper method to add a parameter without having to create it explicitely. The created parameter should be persisted afterwards.\n\n@param key\nname of the parameter to add\n@param value\nvalue of the parameter to create\n@return the newly created parameter", "LRN cross-channel forward computation. Double parameters cast to tensor data type", "Remove any overrides for an endpoint\n\n@param pathValue path (endpoint) value\n@param requestType path request type. \"GET\", \"POST\", etc\n@return true if success, false otherwise", "Gets the sub-entries of the navigation entry.\n\n@return the sub-entries", "Insert a new value prior to the index location in the existing value array,\nincreasing the field length accordingly.\n@param index - where the new values in an SFVec2f object will be placed in the array list\n@param newValue - the new x, y value for the array list", "This looks at the servlet attributes to get the list of response headers to remove while the response object gets created by the servlet", "Creates a ProjectCalendar instance from the Asta data.\n\n@param calendarRow basic calendar data\n@param workPatternMap work pattern map\n@param workPatternAssignmentMap work pattern assignment map\n@param exceptionAssignmentMap exception assignment map\n@param timeEntryMap time entry map\n@param exceptionTypeMap exception type map", "Returns a string representation of map of chunk id to number of chunks\n\n@return String of map of chunk id to number of chunks", "Convert a floating point date to a LocalDate.\n\nNote: This method currently performs a rounding to the next day.\nIn a future extension intra-day time offsets may be considered.\n\nIf referenceDate is null, the method returns null.\n\n@param referenceDate The reference date associated with \\( t=0 \\).\n@param floatingPointDate The value to the time offset \\( t \\).\n@return The date resulting from adding Math.round(fixingTime*365.0) days to referenceDate." ]
@SuppressWarnings("SameParameterValue") private void assembleAndSendPacket(Util.PacketType kind, byte[] payload, InetAddress destination, int port) throws IOException { DatagramPacket packet = Util.buildPacket(kind, ByteBuffer.wrap(announcementBytes, DEVICE_NAME_OFFSET, DEVICE_NAME_LENGTH).asReadOnlyBuffer(), ByteBuffer.wrap(payload)); packet.setAddress(destination); packet.setPort(port); socket.get().send(packet); }
[ "Finish the work of building and sending a protocol packet.\n\n@param kind the type of packet to create and send\n@param payload the content which will follow our device name in the packet\n@param destination where the packet should be sent\n@param port the port to which the packet should be sent\n\n@throws IOException if there is a problem sending the packet" ]
[ "Create a directory at the given path if it does not exist yet.\n\n@param path\nthe path to the directory\n@throws IOException\nif it was not possible to create a directory at the given\npath", "Add a row to the table. We have a limited understanding of the way\nBtrieve handles outdated rows, so we use what we think is a version number\nto try to ensure that we only have the latest rows.\n\n@param primaryKeyColumnName primary key column name\n@param map Map containing row data", "Methods returns InetAddress for localhost\n\n@return InetAddress of the localhost\n@throws UnknownHostException if localhost could not be resolved", "Creates the button for converting an XML bundle in a property bundle.\n@return the created button.", "Use this API to fetch dbdbprofile resource of given name .", "Method which performs strength checks on password. It returns outcome which can be used by CLI.\n\n@param isAdminitrative - administrative checks are less restrictive. This means that weak password or one which violates restrictions is not indicated as failure.\nAdministrative checks are usually performed by admin changing/setting default password for user.\n@param userName - the name of user for which password is set.\n@param password - password.\n@return", "Gets information about a trashed folder that's limited to a list of specified fields.\n@param folderID the ID of the trashed folder.\n@param fields the fields to retrieve.\n@return info about the trashed folder containing only the specified fields.", "This is a convenience method provided to allow a day to be set\nas working or non-working, by using the day number to\nidentify the required day.\n\n@param day required day\n@param working flag indicating if the day is a working day", "Gracefully stop the engine" ]
public static double findMax( double[] u, int startU , int length ) { double max = -1; int index = startU*2; int stopIndex = (startU + length)*2; for( ; index < stopIndex;) { double real = u[index++]; double img = u[index++]; double val = real*real + img*img; if( val > max ) { max = val; } } return Math.sqrt(max); }
[ "Returns the maximum magnitude of the complex numbers\n@param u Array of complex numbers\n@param startU first index to consider in u\n@param length Number of complex numebrs to consider\n@return magnitude" ]
[ "Disposes resources created to service this connection context", "Get the authentication method to use.\n\n@return authentication method", "Get the VCS revision from the Jenkins build environment. The search will one of \"SVN_REVISION\", \"GIT_COMMIT\",\n\"P4_CHANGELIST\" in the environment.\n\n@param env Th Jenkins build environment.\n@return The vcs revision for supported VCS", "Skips the stream over the specified number of bytes, adding the skipped\namount to the count.\n\n@param length the number of bytes to skip\n@return the actual number of bytes skipped\n@throws java.io.IOException if an I/O error occurs\n@see java.io.InputStream#skip(long)", "Write a list of custom field attributes.", "Create a canonical represenation of the data type value. Defaults to the value converter.\n\n@since 2.9", "called by timer thread", "Initializes unspecified sign properties using available defaults\nand global settings.", "Update the BinderDescriptor of the declarationBinderRef.\n\n@param declarationBinderRef the ServiceReference<DeclarationBinder> of the DeclarationBinder" ]
public int[] getPositions() { int[] list; if (assumeSinglePosition) { list = new int[1]; list[0] = super.startPosition(); return list; } else { try { processEncodedPayload(); list = mtasPosition.getPositions(); if (list != null) { return mtasPosition.getPositions(); } } catch (IOException e) { log.debug(e); // do nothing } int start = super.startPosition(); int end = super.endPosition(); list = new int[end - start]; for (int i = start; i < end; i++) list[i - start] = i; return list; } }
[ "Gets the positions.\n\n@return the positions" ]
[ "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.", "Use this API to fetch all the dospolicy resources that are configured on netscaler.", "Retrieve a Double from an input stream.\n\n@param is input stream\n@return Double instance", "Use this API to fetch all the dnsnsecrec resources that are configured on netscaler.\nThis uses dnsnsecrec_args which is a way to provide additional arguments while fetching the resources.", "Delete a path recursively.\n@param path a Path pointing to a file or a directory that may not exists anymore.\n@throws IOException", "Remove the given pair into the map.\n\n<p>\nIf the given key is inside the map, but is not mapped to the given value, the\nmap will not be changed.\n</p>\n\n@param <K> type of the map keys.\n@param <V> type of the map values.\n@param map the map to update.\n@param entry the entry (key, value) to remove from the map.\n@return {@code true} if the pair was removed.\n@since 2.15", "This method returns the value of the product under the specified model and other information in a key-value map.\n\n@param evaluationTime The time on which this products value should be observed.\n@param model A model used to evaluate the product.\n@return The values of the product.\n@throws net.finmath.exception.CalculationException Thrown if the valuation fails, specific cause may be available via the <code>cause()</code> method.", "Make a WMS getLayer request and return the image read from the server.\n\n@param wmsLayerParam the wms request parameters\n@param commonURI the uri to use for the requests (excepting parameters of course.)\n@param imageSize the size of the image to request\n@param dpi the dpi of the image to request\n@param angle the angle of the image to request\n@param bounds the area and projection of the request on the world.", "Sets the specified many-to-one 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" ]
protected final void setParentNode(final DiffNode parentNode) { if (this.parentNode != null && this.parentNode != parentNode) { throw new IllegalStateException("The parent of a node cannot be changed, once it's set."); } this.parentNode = parentNode; }
[ "Sets the parent node.\n\n@param parentNode The parent of this node. May be null, if this is a root node." ]
[ "Pass a model object and return a SoyMapData if a model object happens\nto be a SoyMapData.\n\nAn implementation will also check if a passed in object is a Map and return\na SoyMapData wrapping that map", "Producers returned from this method are not validated. Internal use only.", "Returns a string array of the methods loaded for a class\n\n@param pluginClass name of class\n@return string array of the methods loaded for the class\n@throws Exception exception", "Get DPI suggestions.\n\n@return DPI suggestions", "Emit an enum event with parameters supplied.\n\nThis will invoke all {@link SimpleEventListener} bound to the specific\nenum value and all {@link SimpleEventListener} bound to the enum class\ngiven the listeners has the matching argument list.\n\nFor example, given the following enum definition:\n\n```java\npublic enum UserActivity {LOGIN, LOGOUT}\n```\n\nWe have the following simple event listener methods:\n\n```java\n{@literal @}OnEvent\npublic void handleUserActivity(UserActivity, User user) {...}\n\n{@literal @}OnUserActivity(UserActivity.LOGIN)\npublic void logUserLogin(User user, long timestamp) {...}\n\n{@literal @}OnUserActivity(UserActivity.LOGOUT)\npublic void logUserLogout(User user) {...}\n```\n\nThe following code will invoke `logUserLogin` method:\n\n```java\nUser user = ...;\neventBus.emit(UserActivity.LOGIN, user, System.currentTimeMills());\n```\n\nThe `handleUserActivity` is not invoked because\n\n* The method parameter `(UserActivity, User, long)` does not match the declared argument list `(UserActivity, User)`\n\nWhile the following code will invoke both `handleUserActivity` and `logUserLogout` methods:\n\n```java\nUser user = ...;\neventBus.emit(UserActivity.LOGOUT, user);\n```\n\nThe `logUserLogin` method will not be invoked because\n\n1. the method is bound to `UserActivity.LOGIN` enum value specifically, while `LOGOUT` is triggered\n2. the method has a `long timestamp` in the argument list and it is not passed to `eventBus.emit`\n\n@param event\nthe target event\n@param args\nthe arguments passed in\n@see SimpleEventListener", "Applies the given codec registry to be used alongside the default codec registry.\n\n@param codecRegistry the codec registry to merge in.\n@return an {@link StitchObjectMapper} with the merged codec registries.", "Creates and attaches the annotation index to a resource root, if it has not already been attached", "Here the search query is composed and executed.\nThe result is wrapped in an easily usable form.\nIt is exposed to the JSP via the tag's \"var\" attribute.\n@return The result object exposed via the tag's attribute \"var\".", "Wraps a linear solver of any type with a safe solver the ensures inputs are not modified" ]