query stringlengths 74 6.1k | positive listlengths 1 1 | negative listlengths 9 9 |
|---|---|---|
public static base_response add(nitro_service client, tmtrafficaction resource) throws Exception {
tmtrafficaction addresource = new tmtrafficaction();
addresource.name = resource.name;
addresource.apptimeout = resource.apptimeout;
addresource.sso = resource.sso;
addresource.formssoaction = resource.formssoac... | [
"Use this API to add tmtrafficaction."
] | [
"Reset the combination generator.",
"Gets the element view.\n\n@return the element view",
"Sets the scale vector of the keyframe.",
"EAP 7.1",
"Whether the specified JavaBeans property exists on the given type or not.\n\n@param clazz the type of interest\n@param property the JavaBeans property name\n@param ... |
private InputStream prepareInputStream(InputStream stream) throws IOException
{
InputStream result;
BufferedInputStream bis = new BufferedInputStream(stream);
readHeaderProperties(bis);
if (isCompressed())
{
result = new InflaterInputStream(bis);
}
else
{
... | [
"If the file is compressed, handle this so that the stream is ready to read.\n\n@param stream input stream\n@return uncompressed input stream"
] | [
"waits for all async mutations that were added before this was called to be flushed. Does not\nwait for async mutations added after call.",
"Sets the submatrix of W up give Y is already configured and if it is being cached or not.",
"Return a logger associated with a particular class name.",
"Obtains a Intern... |
public static void writeUTF(@NotNull final OutputStream stream, @NotNull final String str) throws IOException {
try (DataOutputStream dataStream = new DataOutputStream(stream)) {
int len = str.length();
if (len < SINGLE_UTF_CHUNK_SIZE) {
dataStream.writeUTF(str);
... | [
"Writes long strings to output stream as several chunks.\n\n@param stream stream to write to.\n@param str string to be written.\n@throws IOException if something went wrong"
] | [
"Sets the category display options that affect how the category selection dialog is shown.\n\n@param displayCategoriesByRepository if true, the categories are shown separated by repository.\n@param displayCategorySelectionCollapsed if true, the selection dialog opens showing only the top-level categories\n(or the v... |
public void addNamespace(final MongoNamespace namespace) {
this.instanceLock.writeLock().lock();
try {
if (this.nsStreamers.containsKey(namespace)) {
return;
}
final NamespaceChangeStreamListener streamer =
new NamespaceChangeStreamListener(
namespace,
... | [
"Requests that the given namespace be started listening to for change events.\n\n@param namespace the namespace to listen for change events on."
] | [
"Shutdown each AHC client in the map.",
"Gets the default configuration for Freemarker within Windup.",
"Hide multiple channels. All other channels will be unaffected.\n@param channels The channels to hide",
"Returns all the deployment runtime names associated with an overlay accross all server groups.\n\n@p... |
@Deprecated
public static RemoteProxyController create(final ManagementChannelHandler channelAssociation, final PathAddress pathAddress, final ProxyOperationAddressTranslator addressTranslator) {
final TransactionalProtocolClient client = TransactionalProtocolHandlers.createClient(channelAssociation);
... | [
"Creates a new remote proxy controller using an existing channel.\n\n@param channelAssociation the channel association\n@param pathAddress the address within the model of the created proxy controller\n@param addressTranslator the translator to use translating the address for the remote proxy\n@return the proxy cont... | [
"Generate the body of a toString method that uses plain concatenation.\n\n<p>Conventionally, we join properties with comma separators. If all of the properties are\nalways present, this can be done with a long block of unconditional code. We could use a\nStringBuilder for this, but in fact the Java compiler will do... |
protected long getUniqueLong(FieldDescriptor field) throws SequenceManagerException
{
long result;
// lookup sequence name
String sequenceName = calculateSequenceName(field);
try
{
result = buildNextSequence(field.getClassDescriptor(), sequenceName);
... | [
"returns a unique long value for class clazz and field fieldName.\nthe returned number is unique accross all tables in the extent of clazz."
] | [
"Parses the field facet configurations.\n@param fieldFacetObject The JSON sub-node with the field facet configurations.\n@return The field facet configurations.",
"This method writes data for a single task to a Planner file.\n\n@param mpxjTask MPXJ Task instance\n@param taskList list of child tasks for current pa... |
public static String getPropertyName(String name) {
if(name != null && (name.startsWith("get") || name.startsWith("set"))) {
StringBuilder b = new StringBuilder(name);
b.delete(0, 3);
b.setCharAt(0, Character.toLowerCase(b.charAt(0)));
return b.toString();
... | [
"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"
] | [
"Use this API to fetch sslcipher resources of given names .",
"Issue the database statements to drop the table associated with a table configuration.\n\n<p>\n<b>WARNING:</b> This is [obviously] very destructive and is unrecoverable.\n</p>\n\n@param connectionSource\nAssociated connection source.\n@param tableConf... |
public static base_response delete(nitro_service client, Long clid) throws Exception {
clusterinstance deleteresource = new clusterinstance();
deleteresource.clid = clid;
return deleteresource.delete_resource(client);
} | [
"Use this API to delete clusterinstance of given name."
] | [
"Convert a layer type to a geometry class.\n\n@param layerType\nlayer type\n@return JTS class",
"Creates an encryptor for queryable text strings that uses standard password-based encryption. Uses a shared, or\nconstant 16 byte initialization vector so encrypting the same data results in the same encryption result... |
public static String format(ImageFormat format) {
if (format == null) {
throw new IllegalArgumentException("You must specify an image format.");
}
return FILTER_FORMAT + "(" + format.value + ")";
} | [
"Specify the output format of the image.\n\n@see ImageFormat"
] | [
"Adds an additional alias to the constructed document.\n\n@param text\nthe text of the alias\n@param languageCode\nthe language code of the alias\n@return builder object to continue construction",
"Determine whether the calling thread is the GL thread.\n\n@return {@code True} if called from the GL thread, {@code ... |
public static final void deleteQuietly(File file)
{
if (file != null)
{
if (file.isDirectory())
{
File[] children = file.listFiles();
if (children != null)
{
for (File child : children)
{
deleteQuietly(c... | [
"Delete a file ignoring failures.\n\n@param file file to delete"
] | [
"Launch Navigation Service residing in the navigation module",
"Use this API to apply nspbr6 resources.",
"Swap the current version folder for a new one\n\n@param newStoreDirectory The path to the new version directory",
"Read a long int from a byte array.\n\n@param data byte array\n@param offset start offset... |
public static base_responses update(nitro_service client, systemuser resources[]) throws Exception {
base_responses result = null;
if (resources != null && resources.length > 0) {
systemuser updateresources[] = new systemuser[resources.length];
for (int i=0;i<resources.length;i++){
updateresources[i] = ne... | [
"Use this API to update systemuser resources."
] | [
"alert, prompt, and confirm behave as if the OK button is always clicked.",
"Answer the SQL-Clause for a BetweenCriteria\n\n@param alias\n@param pathInfo\n@param c BetweenCriteria\n@param buf",
"Removes the key and its associated value from this map.\n\n@param key the key to remove\n@return the value associate... |
public static base_response add(nitro_service client, cachepolicylabel resource) throws Exception {
cachepolicylabel addresource = new cachepolicylabel();
addresource.labelname = resource.labelname;
addresource.evaluates = resource.evaluates;
return addresource.add_resource(client);
} | [
"Use this API to add cachepolicylabel."
] | [
"Replaces the first 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 CharSequence to be substituted for each match\n@return a CharSequence with replaced content\n... |
@ArgumentsChecked
@Throws(IllegalNullArgumentException.class)
public static byte checkByte(@Nonnull final Number number) {
Check.notNull(number, "number");
if (!isInByteRange(number)) {
throw new IllegalNumberRangeException(number.toString(), BYTE_MIN, BYTE_MAX);
}
return number.byteValue();
} | [
"Checks if a given number is in the range of a byte.\n\n@param number\na number which should be in the range of a byte (positive or negative)\n\n@see java.lang.Byte#MIN_VALUE\n@see java.lang.Byte#MAX_VALUE\n\n@return number as a byte (rounding might occur)"
] | [
"get the TypeArgSignature corresponding to given type\n\n@param type\n@return",
"Serialize a parameterized object to a JSON String.\n\n@param object The object to serialize.\n@param parameterizedType The ParameterizedType describing the object. Ex: LoganSquare.serialize(object, new ParameterizedType<MyModel<... |
synchronized boolean deleteMessageForId(String messageId, String userId){
if(messageId == null || userId == null) return false;
final String tName = Table.INBOX_MESSAGES.getName();
try {
final SQLiteDatabase db = dbHelper.getWritableDatabase();
db.delete(tName, _ID + " ... | [
"Deletes the inbox message for given messageId\n@param messageId String messageId\n@return boolean value based on success of operation"
] | [
"Reads a single day for a calendar.\n\n@param mpxjCalendar ProjectCalendar instance\n@param day ConceptDraw PROJECT week day",
"Retrieve the most recent storepoint.\n\n@param phoenixProject project data\n@return Storepoint instance",
"Perform a module dependency graph of the target and return the graph as a JSO... |
public static List<String> getDefaultConversionProviderChain(){
List<String> defaultChain = getMonetaryConversionsSpi()
.getDefaultProviderChain();
Objects.requireNonNull(defaultChain, "No default provider chain provided by SPI: " +
getMonetaryConversionsSpi().getClass().... | [
"Get the default provider used.\n\n@return the default provider, never {@code null}."
] | [
"Called when app's singleton registry has been initialized",
"Attach a script file to a scriptable target.\n\n@param target The scriptable target.\n@param scriptFile The script file object.",
"Retrieve the fixed data offset for a specific field.\n\n@param type field type\n@return offset",
"Return the availabl... |
public static void acceptsUrlMultiple(OptionParser parser) {
parser.acceptsAll(Arrays.asList(OPT_U, OPT_URL), "coordinator bootstrap urls")
.withRequiredArg()
.describedAs("url-list")
.withValuesSeparatedBy(',')
.ofType(String.class);
} | [
"Adds OPT_U | OPT_URL 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 sslcertkey resources of given names .",
"Sets the indirection handler class.\n\n@param indirectionHandlerClass The class for indirection handlers",
"Propagate onNoPick events to listeners\n@param picker GVRPicker which generated the event",
"Adds an array of groupby fieldNames for Repor... |
public int findAnimation(GVRAnimation findme)
{
int index = 0;
for (GVRAnimation anim : mAnimations)
{
if (anim == findme)
{
return index;
}
++index;
}
return -1;
} | [
"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)"
] | [
"Adds a type to collection with inheriting base type properties.\n\n@param type the type definition to add\n\n@return true if the type definition was added",
"Utility method used to round a double to the given precision.\n\n@param value value to truncate\n@param precision Number of decimals to round to.\n@return ... |
private static BufferedImage scale(BufferedImage imageToScale, int dWidth, int dHeight, double fWidth, double fHeight) {
BufferedImage dbi = null;
// Needed to create a new BufferedImage object
int imageType = imageToScale.getType();
if (imageToScale != null) {
dbi = new Buff... | [
"Image scale method\n@param imageToScale The image to be scaled\n@param dWidth Desired width, the new image object is created to this size\n@param dHeight Desired height, the new image object is created to this size\n@param fWidth What to multiply the width by. value < 1 scales down, and value > one scales up\n@par... | [
"Retrieves and validates the content type from the REST requests\n\n@return true if has content type.",
"Given a field node, checks if we are calling a private field from an inner class.",
"Calculate the value of a digital caplet assuming the Black'76 model.\n\n@param forward The forward (spot).\n@param volatil... |
private Table getTable(String name)
{
Table table = m_tables.get(name);
if (table == null)
{
table = EMPTY_TABLE;
}
return table;
} | [
"Retrieve a table by name.\n\n@param name table name\n@return Table instance"
] | [
"Retrieves or if necessary, creates a user alias to be used\nby a child criteria\n@param attribute The alias to set",
"Executes the sequence of operations",
"Create a new custom field setting on the project.\n\n@param project The project to associate the custom field with\n@return Request object",
"Creates a... |
@Override
public InstalledIdentity getInstalledIdentity(String productName, String productVersion) throws PatchingException {
final String defaultIdentityName = defaultIdentity.getIdentity().getName();
if(productName == null) {
productName = defaultIdentityName;
}
final ... | [
"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 produ... | [
"Build a String representation of given arguments.",
"called per frame of animation to update the camera position",
"Append the text at the end of the Path.\n\n@param self a Path\n@param text the text to append at the end of the Path\n@throws java.io.IOException if an IOException occurs.\n@since 2.3.0",
"Use ... |
@Override
public Response toResponse(ErrorDto e)
{
// String type = headers.getContentType() == null ? MediaType.APPLICATION_JSON : headers.getContentType();
return Response.status(e.httpStatus).entity(e).type(MediaType.APPLICATION_JSON).build();
} | [
"private HttpServletResponse headers;"
] | [
"Triggers a replication request.",
"Returns the full record for a single team.\n\n@param team Globally unique identifier for the team.\n@return Request object",
"return a HashMap with all properties, name as key, value as value\n@return the properties",
"Searches the set of imports to find a matching import ... |
static BsonDocument getDocumentVersionDoc(final BsonDocument document) {
if (document == null || !document.containsKey(DOCUMENT_VERSION_FIELD)) {
return null;
}
return document.getDocument(DOCUMENT_VERSION_FIELD, null);
} | [
"Returns the version document of the given document, if any; returns null otherwise.\n@param document the document to get the version from.\n@return the version of the given document, if any; returns null otherwise."
] | [
"Deletes the schema of an existing metadata template.\n\n@param api the API connection to be used\n@param scope the scope of the object\n@param template Unique identifier of the template",
"Returns the default output for functions without configured JSPs.\n\n@param request the current request\n@return the default... |
public SyntaxException getSyntaxError(int index) {
SyntaxException exception = null;
Message message = getError(index);
if (message != null && message instanceof SyntaxErrorMessage) {
exception = ((SyntaxErrorMessage) message).getCause();
}
return exception;
} | [
"Convenience routine to return the specified error's\nunderlying SyntaxException, or null if it isn't one."
] | [
"Indicates whether or not an event ID is a duplicate.\n\n<p>This method can be overridden by a subclass in order to provide custom de-duping logic.</p>\n\n@param eventID the event ID.\n@return true if the event is a duplicate; otherwise false.",
"Called recursively to renumber child task IDs.\n\n@param p... |
private void handleIncomingRequestMessage(SerialMessage incomingMessage) {
logger.debug("Message type = REQUEST");
switch (incomingMessage.getMessageClass()) {
case ApplicationCommandHandler:
handleApplicationCommandRequest(incomingMessage);
break;
case SendData:
handleSendDataRequest(incomingMess... | [
"Handles an incoming request message.\nAn incoming request message is a message initiated by a node or the controller.\n@param incomingMessage the incoming message to process."
] | [
"Calculates all dates of the series.\n@return all dates of the series in milliseconds.",
"Discard the changes.",
"Print an extended attribute value.\n\n@param writer parent MSPDIWriter instance\n@param value attribute value\n@param type type of the value being passed\n@return string representation",
"Resolve ... |
public static void applyToOr(ColorHolder colorHolder, TextView textView, ColorStateList colorDefault) {
if (colorHolder != null && textView != null) {
colorHolder.applyToOr(textView, colorDefault);
} else if (textView != null) {
textView.setTextColor(colorDefault);
}
... | [
"a small static helper to set the text color to a textView null save\n\n@param colorHolder\n@param textView\n@param colorDefault"
] | [
"Write a list of custom field attributes.",
"Invoke an HTTP GET request on a remote host. You must close the InputStream after you are done with.\n\n@param path The request path\n@param parameters The parameters (collection of Parameter objects)\n@return The Response",
"Get the Upper triangular factor.\n\... |
private Bpmn2Resource unmarshall(JsonParser parser,
String preProcessingData) throws IOException {
try {
parser.nextToken(); // open the object
ResourceSet rSet = new ResourceSetImpl();
rSet.getResourceFactoryRegistry().getExtensionToFacto... | [
"Start unmarshalling using the parser.\n@param parser\n@param preProcessingData\n@return the root element of a bpmn2 document.\n@throws java.io.IOException"
] | [
"Sets the class loader to be used on serialization operations, for data\nstored in the specified fqn and child nodes. Note that if another class\nloader is set for a specific child node tree, the cache will use instead\nthat class loader.\n\n@param regionFqn\n@param classLoader",
"Extracts the data for a single f... |
public void assignField(ConnectionSource connectionSource, Object data, Object val, boolean parentObject,
ObjectCache objectCache) throws SQLException {
if (logger.isLevelEnabled(Level.TRACE)) {
logger.trace("assiging from data {}, val {}: {}", (data == null ? "null" : data.getClass()),
(val == null ? "nu... | [
"Assign to the data object the val corresponding to the fieldType."
] | [
"Reverses a sequence of elements.\n@param array Array containing the sequence\n@param first Beginning of the range\n@param last One past the end of the range\n@exception ArrayIndexOutOfBoundsException If the range\nis invalid.",
"Adds all edges for a given object envelope vertex. All edges ... |
public void credentialsMigration(T overrider, Class overriderClass) {
try {
deployerMigration(overrider, overriderClass);
resolverMigration(overrider, overriderClass);
} catch (NoSuchFieldException | IllegalAccessException | IOException e) {
converterErrors.add(getCon... | [
"Migrate to Jenkins \"Credentials\" plugin from the old credential implementation"
] | [
"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",
"The main method. See the class documentation.",
"Computes A-B\n\n@param listA\n@param listB\n@return",
"Inser... |
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"
] | [
"Convert a Java date into a Planner date.\n\n20070222\n\n@param value Java Date instance\n@return Planner date",
"GetJob helper - String predicates are all created the same way, so this factors some code.",
"Concatenates of list of Bytes objects to create a byte array\n\n@param listOfBytes Bytes objects to conc... |
public static String getStatementUri(Statement statement) {
int i = statement.getStatementId().indexOf('$') + 1;
return PREFIX_WIKIDATA_STATEMENT
+ statement.getSubject().getId() + "-"
+ statement.getStatementId().substring(i);
} | [
"Get the URI for the given statement.\n\n@param statement\nthe statement for which to create a URI\n@return the URI"
] | [
"Plots the MSD curve for trajectory t.\n@param t List of trajectories\n@param lagMin Minimum timelag (e.g. 1,2,3..) lagMin*timelag = elapsed time in seconds\n@param lagMax Maximum timelag (e.g. 1,2,3..) lagMax*timelag = elapsed time in seconds",
"Stops the background data synchronization thread and releases the ... |
public String toStringByValue() {
IntArrayList theKeys = new IntArrayList();
keysSortedByValue(theKeys);
StringBuffer buf = new StringBuffer();
buf.append("[");
int maxIndex = theKeys.size() - 1;
for (int i = 0; i <= maxIndex; i++) {
int key = theKeys.get(i);
buf.append(String.valueOf(key));
b... | [
"Returns a string representation of the receiver, containing\nthe String representation of each key-value pair, sorted ascending by value."
] | [
"if you want to convert some string to an object, you have an argument to parse",
"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",
"Sets an attribute in the main section of the manifest.\n\n... |
private static StackTraceElement getStackTrace() {
StackTraceElement[] stack = Thread.currentThread().getStackTrace();
int i = 2; // we can skip the first two (first is getStackTrace(), second is this method)
while (i < stack.length) {
boolean isLoggingClass = false;
for (String loggingCl... | [
"Get the current stack trace element, skipping anything from known logging classes.\n@return The current stack trace for this thread"
] | [
"Read an optional int value form a JSON value.\n@param val the JSON value that should represent the int.\n@return the int from the JSON or 0 reading the int fails.",
"Save a weak reference to the resource",
"Send a get artifacts request\n\n@param hasLicense\n@return list of artifact\n@throws GrapesCommunication... |
public static base_response clear(nitro_service client, route6 resource) throws Exception {
route6 clearresource = new route6();
clearresource.routetype = resource.routetype;
return clearresource.perform_operation(client,"clear");
} | [
"Use this API to clear route6."
] | [
"Use this API to fetch all the systemsession resources that are configured on netscaler.",
"Loads configuration from InputStream. Later loads have lower priority.\n\n@param in InputStream to load from\n@since 1.2.0",
"Copy a patch element\n\n@param entry the patch entry\n@param patchId the patch i... |
public static vpnglobal_auditnslogpolicy_binding[] get(nitro_service service) throws Exception{
vpnglobal_auditnslogpolicy_binding obj = new vpnglobal_auditnslogpolicy_binding();
vpnglobal_auditnslogpolicy_binding response[] = (vpnglobal_auditnslogpolicy_binding[]) obj.get_resources(service);
return response;
} | [
"Use this API to fetch a vpnglobal_auditnslogpolicy_binding resources."
] | [
"Calculates the LatLong position of the end point of a line the specified\ndistance from this LatLong, along the provided bearing, where North is 0,\nEast is 90 etc.\n\n@param bearing The bearing, in degrees, with North as 0, East as 90 etc.\n@param distance The distance in metres.\n@return A new LatLong indicating... |
@SuppressWarnings({"unused", "WeakerAccess"})
public void pushNotificationViewedEvent(Bundle extras){
if (extras == null || extras.isEmpty() || extras.get(Constants.NOTIFICATION_TAG) == null) {
getConfigLogger().debug(getAccountId(), "Push notification: " + (extras == null ? "NULL" : extras.toS... | [
"Pushes the Notification Viewed event to CleverTap.\n\n@param extras The {@link Bundle} object that contains the\nnotification details"
] | [
"Create an index of base font numbers and their associated base\nfont instances.\n@param data property data",
"Read configuration from zookeeper",
"Formats the supplied value using the specified DateTimeFormat.\n\n@return \"\" if the value is null",
"Find the animation associated with this avatar with the giv... |
private void processUDF(UDFTypeType udf)
{
FieldTypeClass fieldType = FIELD_TYPE_MAP.get(udf.getSubjectArea());
if (fieldType != null)
{
UserFieldDataType dataType = UserFieldDataType.getInstanceFromXmlName(udf.getDataType());
String name = udf.getTitle();
FieldType field... | [
"Process an individual UDF.\n\n@param udf UDF definition"
] | [
"Matches an array value if it contains all the elements of the argument array\n@param rhs The arguments\n@return PredicateExpression: $all rhs",
"Performs all actions that have been configured.",
"Retrieve list of assignment extended attributes.\n\n@return list of extended attributes",
"Convenience method whi... |
private String formatCurrency(Number value)
{
return (value == null ? null : m_formats.getCurrencyFormat().format(value));
} | [
"This method is called to format a currency value.\n\n@param value numeric value\n@return currency value"
] | [
"The main method called from the command line.\n\n@param args the command line arguments",
"Retrieves the work variance.\n\n@return work variance",
"Convert the Primavera string representation of a UUID into a Java UUID instance.\n\n@param value Primavera UUID\n@return Java UUID instance",
"Get the OAuth requ... |
public void updateIntegerBelief(String name, int value) {
introspector.storeBeliefValue(this, name, getIntegerBelief(name) + value);
} | [
"Updates the given integer belief\nadding the given integer\nnewBelief = previousBelief + givenValue\n\n@param String - the belief name\n@param the value to add"
] | [
"Scans a path on the filesystem for resources inside the given classpath location.\n\n@param location The system-independent location on the classpath.\n@param locationUri The system-specific physical location URI.\n@return a sorted set containing all the resources inside the given location\n@throws IOException ... |
private void readCostRateTables(Resource resource, Rates rates)
{
if (rates == null)
{
CostRateTable table = new CostRateTable();
table.add(CostRateTableEntry.DEFAULT_ENTRY);
resource.setCostRateTable(0, table);
table = new CostRateTable();
table.add(CostRate... | [
"Reads the cost rate tables from the file.\n\n@param resource parent resource\n@param rates XML cot rate tables"
] | [
"Here we specify the configuration, starting from default MostUsefulConfiguration, and changing only what is needed",
"Build a Dataset from some data.\n\n@param oldData This {@link Dataset} represents data for which we which to\nsome features, specifically those features not in the {@link edu.stanford.nlp.ut... |
public static <K, V> QueuedKeyedResourcePool<K, V> create(ResourceFactory<K, V> factory) {
return create(factory, new ResourcePoolConfig());
} | [
"Create a new queued pool using the defaults for key of type K, request of\ntype R, and value of Type V.\n\n@param factory The factory that creates objects\n@return The created pool"
] | [
"Read resource data from a PEP file.",
"Moves our current playback position to the specified beat; this will be reflected in any status and beat packets\nthat we are sending. An incoming value less than one will jump us to the first beat.\n\n@param beat the beat that we should pretend to be playing",
"Determine... |
public static Map<FieldType, String> getDefaultResourceFieldMap()
{
Map<FieldType, String> map = new LinkedHashMap<FieldType, String>();
map.put(ResourceField.UNIQUE_ID, "rsrc_id");
map.put(ResourceField.GUID, "guid");
map.put(ResourceField.NAME, "rsrc_name");
map.put(ResourceField.COD... | [
"Retrieve the default mapping between MPXJ resource fields and Primavera resource field names.\n\n@return mapping"
] | [
"Sends a normal HTTP response containing the serialization information in\na XML format",
"Calculate the starting content offset based on the layout orientation and Gravity\n@param totalSize total size occupied by the content",
"Call the onQueryExecuteTimeLimitExceeded hook if necessary\n@param sql sql statemen... |
@SuppressWarnings("unchecked")
protected String addPostRunDependent(Creatable<? extends Indexable> creatable) {
TaskGroup.HasTaskGroup dependency = (TaskGroup.HasTaskGroup) creatable;
return this.addPostRunDependent(dependency);
} | [
"Add a creatable \"post-run\" dependent for this task item.\n\n@param creatable the creatable \"post-run\" dependent.\n@return the key to be used as parameter to taskResult(string) method to retrieve created \"post-run\" dependent"
] | [
"Wraps a linear solver of any type with a safe solver the ensures inputs are not modified",
"Resumes a given entry point type;\n\n@param entryPoint The entry point",
"Use the jgrapht cycle checker to detect any cycles in the provided dependency graph.",
"Obtains a local date in Symmetry454 calendar system fro... |
public static void showChannels(Object... channels){
// TODO this could share more code with the other show/hide(Only)Channels methods
for(LogRecordHandler handler : handlers){
if(handler instanceof VisibilityHandler){
VisibilityHandler visHandler = (VisibilityHandler) handler;
for (O... | [
"Show multiple channels. All other channels will be unaffected.\n@param channels The channels to show"
] | [
"Adds a class entry to this JAR.\n\n@param clazz the class to add to the JAR.\n@return {@code this}",
"This method is called to alert project listeners to the fact that\na resource assignment has been read from a project file.\n\n@param resourceAssignment resourceAssignment instance",
"Attachments are only stru... |
public static AbstractBuild<?, ?> getRootBuild(AbstractBuild<?, ?> currentBuild) {
AbstractBuild<?, ?> rootBuild = null;
AbstractBuild<?, ?> parentBuild = getUpstreamBuild(currentBuild);
while (parentBuild != null) {
if (isPassIdentifiedDownstream(parentBuild)) {
root... | [
"Get the root build which triggered the current build. The build root is considered to be the one furthest one\naway from the current build which has the isPassIdentifiedDownstream active, if no parent build exists, check\nthat the current build needs an upstream identifier, if it does return it.\n\n@param currentB... | [
"Returns a unique file name\n@param baseFileName the requested base name for the file\n@param extension the requested extension for the file\n@param cleanBaseFileName specify if the <code>baseFileName</code> has to be cleaned before being used (i.e. 'jboss-web' should not be cleaned to avoid '-' to become '_')\n@pa... |
public static base_response update(nitro_service client, nd6ravariables resource) throws Exception {
nd6ravariables updateresource = new nd6ravariables();
updateresource.vlan = resource.vlan;
updateresource.ceaserouteradv = resource.ceaserouteradv;
updateresource.sendrouteradv = resource.sendrouteradv;
update... | [
"Use this API to update nd6ravariables."
] | [
"Creates the adapter for the target database.",
"Returns the parameter key of the facet with the given name.\n@param facet the facet's name.\n@return the parameter key for the facet.",
"Sets the scale vector of the keyframe.",
"Returns a new index creation statement using the session's keyspace.\n\n@param key... |
public void removeCustomOverride(int path_id, String client_uuid) throws Exception {
updateRequestResponseTables("custom_response", "", getProfileIdFromPathID(path_id), client_uuid, path_id);
} | [
"Remove custom overrides\n\n@param path_id ID of path containing custom override\n@param client_uuid UUID of the client\n@throws Exception exception"
] | [
"Returns a new instance of the given class using the constructor with the specified parameter.\n\n@param target The class to instantiate\n@param type The types of the single parameter of the constructor\n@param arg The argument\n@return The instance",
"Generates and writes the sql for inserting the currently... |
private Date getTime(String value) throws MPXJException
{
try
{
Number hours = m_twoDigitFormat.parse(value.substring(0, 2));
Number minutes = m_twoDigitFormat.parse(value.substring(2, 4));
Calendar cal = DateHelper.popCalendar();
cal.set(Calendar.HOUR_OF_DAY, hours.i... | [
"Convert a Planner time into a Java date.\n\n0800\n\n@param value Planner time\n@return Java Date instance"
] | [
"Read project calendars.",
"This method displays the resource assignments for each resource. This time\nrather than just iterating through the list of all assignments in\nthe file, we extract the assignments on a resource-by-resource basis.\n\n@param file MPX file",
"Prints a debug log message that details the ... |
public SourceBuilder add(String fmt, Object... args) {
TemplateApplier.withParams(args).onText(source::append).onParam(this::add).parse(fmt);
return this;
} | [
"Appends formatted text to the source.\n\n<p>Formatting supports {@code %s} and {@code %n$s}. Most args are converted according to their\n{@link Object#toString()} method, except that:<ul>\n<li> {@link Package} and {@link PackageElement} instances use their fully-qualified names\n(no \"package \" prefix).\n<li> {@l... | [
"Creates a player wrapper for the Android MediaPlayer.",
"Specialized version of readValue just for reading map keys, because the StdDeserializer methods like\n_parseIntPrimitive blow up when the current JsonToken is FIELD_NAME",
"Appends a line separator node that will only be effective if the current line con... |
public static final Bytes of(ByteBuffer bb) {
Objects.requireNonNull(bb);
if (bb.remaining() == 0) {
return EMPTY;
}
byte[] data;
if (bb.hasArray()) {
data = Arrays.copyOfRange(bb.array(), bb.position() + bb.arrayOffset(),
bb.limit() + bb.arrayOffset());
} else {
data... | [
"Creates a Bytes object by copying the data of the given ByteBuffer.\n\n@param bb Data will be read from this ByteBuffer in such a way that its position is not\nchanged."
] | [
"Renders in LI tags, Wraps with UL tags optionally.",
"Use this API to fetch filtered set of appqoepolicy resources.\nset the filter parameter values in filtervalue object.",
"Serialize a parameterized object to an OutputStream.\n\n@param object The object to serialize.\n@param parameterizedType The Parameteri... |
private final boolean matchChildBlock(int bufferIndex)
{
//
// Match the pattern we see at the start of the child block
//
int index = 0;
for (byte b : CHILD_BLOCK_PATTERN)
{
if (b != m_buffer[bufferIndex + index])
{
return false;
}
... | [
"Locate a child block by byte pattern and validate by\nchecking the length of the string we are expecting\nto follow the pattern.\n\n@param bufferIndex start index\n@return true if a child block starts at this point"
] | [
"Used for unit tests only.\n\nFIXME: Refactor test code with dependency injection or scope restrictions so this function is not public.\n\n@deprecated Do not use for production code, use {@link #fetch(String, String, voldemort.server.protocol.admin.AsyncOperationStatus, String, long, voldemort.store.metadata.Metada... |
public static Set<Map<String, Object>> setify(ObjectMapper mapper, Object source) {
return (Set<Map<String, Object>>) collectify(mapper, source, Set.class);
} | [
"Convert an object to a set of maps.\n\n@param mapper the object mapper\n@param source the source object\n@return set"
] | [
"Generates the build-info module for this docker image.\nAdditionally. this method tags the deployed docker layers with properties,\nsuch as build.name, build.number and custom properties defined in the Jenkins build.\n@param build\n@param listener\n@param config\n@param buildName\n@param buildNumber\n@param timest... |
public ItemRequest<Task> removeFollowers(String task) {
String path = String.format("/tasks/%s/removeFollowers", task);
return new ItemRequest<Task>(this, Task.class, path, "POST");
} | [
"Removes each of the specified followers from the task if they are\nfollowing. Returns the complete, updated record for the affected task.\n\n@param task The task to remove followers from.\n@return Request object"
] | [
"Returns the portion of the field name after the last dot, as field names\nmay actually be paths.",
"Pre API 11, this does an alpha animation.\n\n@param progress",
"Use this API to export application.",
"Use this API to fetch all the gslbservice resources that are configured on netscaler.",
"All address str... |
private static String getBindingId(Server server) {
Endpoint ep = server.getEndpoint();
BindingInfo bi = ep.getBinding().getBindingInfo();
return bi.getBindingId();
} | [
"Extracts the bindingId from a Server.\n@param server\n@return"
] | [
"Converts an image in BINARY mode to RGB mode\n\n@param img image\n@return new MarvinImage instance in RGB mode",
"Converts any string into a string that is safe to use as a file name.\nThe result will only include ascii characters and numbers, and the \"-\",\"_\", and \".\" characters.",
"For a cert we have ge... |
public void fillRectangle(Rectangle rect, Color color) {
template.saveState();
setFill(color);
template.rectangle(origX + rect.getLeft(), origY + rect.getBottom(), rect.getWidth(), rect.getHeight());
template.fill();
template.restoreState();
} | [
"Draw a rectangle's interior with this color.\n\n@param rect rectangle\n@param color colour"
] | [
"Read ClassDescriptors from the given repository file.\n@see #mergeDescriptorRepository",
"Exception handler if we are unable to parse a json value into a java representation\n\n@param expectedType Name of the expected Type\n@param type Type of the json node\n@return SpinJsonDataFormatException",
"Searches the ... |
public List<MaterialSection> getSectionList() {
List<MaterialSection> list = new LinkedList<>();
for(MaterialSection section : sectionList)
list.add(section);
for(MaterialSection section : bottomSectionList)
list.add(section);
return list;
} | [
"Get the section list\n\nN.B. The section list contains the bottom sections\n@return the list of sections setted"
] | [
"Checks if the required option exists.\n\n@param options OptionSet to checked\n@param opt Required option to check\n@throws VoldemortException",
"Find the style filter that must be applied to this feature.\n\n@param feature\nfeature to find the style for\n@param styles\nstyle filters to select from\n@return a sty... |
public static final Number parseUnits(Number value)
{
return (value == null ? null : NumberHelper.getDouble(value.doubleValue() * 100));
} | [
"Parse units.\n\n@param value units value\n@return units value"
] | [
"Use this API to delete snmpmanager.",
"Sets the maximum time to wait before a call to getConnection is timed out.\n\nSetting this to zero is similar to setting it to Long.MAX_VALUE\n\n@param connectionTimeout\n@param timeUnit the unit of the connectionTimeout argument",
"returns the total count of objects in t... |
@Override
public RandomVariable getValue(double evaluationTime, AssetModelMonteCarloSimulationModel model) throws CalculationException {
if(exerciseMethod == ExerciseMethod.UPPER_BOUND_METHOD) {
// Find optimal lambda
GoldenSectionSearch optimizer = new GoldenSectionSearch(-1.0, 1.0);
while(!optimizer.isDon... | [
"This method returns the value random variable of the product within the specified model,\nevaluated at a given evalutationTime.\nCash-flows prior evaluationTime are not considered.\n\n@param evaluationTime The time on which this products value should be observed.\n@param model The model used to price the product.\... | [
"Generated the report.",
"Send a request to another handler internal to the server, getting back the response body and response code.\n\n@param request request to send to another handler.\n@return {@link InternalHttpResponse} containing the response code and body.",
"This method finds the start of the next work... |
private static void readAndAddDocumentsFromStream(
final SolrClient client,
final String lang,
final InputStream is,
final List<SolrInputDocument> documents,
final boolean closeStream) {
final BufferedReader br = new BufferedReader(new InputStreamReader(is));
tr... | [
"Parses the dictionary from an InputStream.\n\n@param client The SolrClient instance object.\n@param lang The language of the dictionary.\n@param is The InputStream object.\n@param documents List to put the assembled SolrInputObjects into.\n@param closeStream boolean flag that determines whether to close the inputs... | [
"Generates an organization regarding the parameters.\n\n@param name String\n@return Organization",
"Deletes all outgoing links of specified entity.\n\n@param entity the entity.",
"Use this API to delete nsacl6 resources of given names.",
"Reads data from the SP file.\n\n@return Project File instance",
"Add ... |
public ProjectFile read(POIFSFileSystem fs) throws MPXJException
{
try
{
ProjectFile projectFile = new ProjectFile();
ProjectConfig config = projectFile.getProjectConfig();
config.setAutoTaskID(false);
config.setAutoTaskUniqueID(false);
config.setAutoResource... | [
"Alternative entry point allowing an MPP file to be read from\na user-supplied POI file stream.\n\n@param fs POI file stream\n@return ProjectFile instance\n@throws MPXJException"
] | [
"Stop the drag action.",
"Assigns retention policy with givenID to folder or enterprise.\n@param api the API connection to be used by the created assignment.\n@param policyID id of the assigned retention policy.\n@param assignTo object representing folder or enterprise to assign policy to.\n@return info about cre... |
protected void convertSearchResults(final Collection<CmsSearchResource> searchResults) {
m_foundResources = new ArrayList<I_CmsSearchResourceBean>();
for (final CmsSearchResource searchResult : searchResults) {
m_foundResources.add(new CmsSearchResourceBean(searchResult, m_cmsObject));
... | [
"Converts the search results from CmsSearchResource to CmsSearchResourceBean.\n@param searchResults The collection of search results to transform."
] | [
"Returns the default privacy level for geographic information attached to the user's photos.\n\n@return privacy-level\n@throws FlickrException\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_FRIEND... |
protected void validateResultsDirectories() {
for (String result : results) {
if (Files.notExists(Paths.get(result))) {
throw new AllureCommandException(String.format("Report directory <%s> not found.", result));
}
}
} | [
"Throws an exception if at least one results directory is missing."
] | [
"Get a list of path transformers for a given address.\n\n@param address the path address\n@param placeholderResolver a placeholder resolver used to resolve children of a placeholder registration\n@return a list of path transformations",
"Create button message key.\n\n@param gallery name\n@return Button message k... |
public List<BuildpackInstallation> listBuildpackInstallations(String appName) {
return connection.execute(new BuildpackInstallationList(appName), apiKey);
} | [
"Lists the buildpacks installed on an app\n\n@param appName See {@link #listApps} for a list of apps that can be used."
] | [
"Returns requested content types or default content type if none found.\n\n@return Requested content types or default content type if none found.",
"Retrieves the registar linked to the bus.\nCreates a new registar is not present.\n\n@param bus\n@return",
"Return the lines of a CharSequence as a List of String.... |
public int getVertices(double[] coords) {
for (int i = 0; i < numVertices; i++) {
Point3d pnt = pointBuffer[vertexPointIndices[i]].pnt;
coords[i * 3 + 0] = pnt.x;
coords[i * 3 + 1] = pnt.y;
coords[i * 3 + 2] = pnt.z;
}
return numVertices;
} | [
"Returns the coordinates of the vertex points of this hull.\n\n@param coords\nreturns the x, y, z coordinates of each vertex. This length of\nthis array must be at least three times the number of\nvertices.\n@return the number of vertices\n@see QuickHull3D#getVertices()\n@see QuickHull3D#getFaces()"
] | [
"to do with XmlId value being strictly of type 'String'",
"Use this API to export sslfipskey.",
"Get HttpResourceModel which matches the HttpMethod of the request.\n\n@param routableDestinations List of ResourceModels.\n@param targetHttpMethod HttpMethod.\n@param requestUri request URI.\n@return RoutableDestina... |
public static String readUntilTag(Reader r) throws IOException {
if (!r.ready()) {
return "";
}
StringBuilder b = new StringBuilder();
int c = r.read();
while (c >= 0 && c != '<') {
b.append((char) c);
c = r.read();
}
return b.toString();
} | [
"Reads all text up to next XML tag and returns it as a String.\n\n@return the String of the text read, which may be empty."
] | [
"Computes the inner product of A times A and stores the results in B. The inner product is symmetric and this\nfunction will only store the lower triangle. The value of the upper triangular matrix is undefined.\n\n<p>B = A<sup>T</sup>*A</sup>\n\n@param A (Input) Matrix\n@param B (Output) Storage for output.",
"Pr... |
@Deprecated
public InputStream getOriginalAsStream() throws IOException, FlickrException {
if (originalFormat != null) {
return getOriginalImageAsStream("_o." + originalFormat);
}
return getOriginalImageAsStream(DEFAULT_ORIGINAL_IMAGE_SUFFIX);
} | [
"Get an InputStream for the original image. Callers must close the stream upon completion.\n\n@deprecated\n@see PhotosInterface#getImageAsStream(Photo, int)\n@return The InputStream\n@throws IOException"
] | [
"Converts a TimeUnit instance to an integer value suitable for\nwriting to an MPX file.\n\n@param recurrence RecurringTask instance\n@return integer value",
"Use this API to add ntpserver.",
"Returns the compact project records for all projects in the workspace.\n\n@param workspace The workspace or organizatio... |
public void setRequestType(int pathId, Integer requestType) {
if (requestType == null) {
requestType = Constants.REQUEST_TYPE_GET;
}
PreparedStatement statement = null;
try (Connection sqlConnection = sqlService.getConnection()) {
statement = sqlConnection.prepar... | [
"Sets the request type for this ID. Defaults to GET\n\n@param pathId ID of path\n@param requestType type of request to service"
] | [
"Verify that the given queues are all valid.\n\n@param queues the given queues",
"Throw IllegalStateException if key is not present in map.\n@param key the key to expect.\n@param map the map to search.\n@throws IllegalArgumentException if key is not in map.",
"Convert from a DTO to an internal Spring bean defin... |
public PhotoList<Photo> searchInterestingness(SearchParameters params, int perPage, int page) throws FlickrException {
PhotoList<Photo> photos = new PhotoList<Photo>();
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("method", METHOD_GET_INTERESTINGNESS);
... | [
"Search for interesting photos using the Flickr Interestingness algorithm.\n\n@param params\nAny search parameters\n@param perPage\nNumber of items per page\n@param page\nThe page to start on\n@return A PhotoList\n@throws FlickrException"
] | [
"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.",
"Transforms user name and icon size into the rfs image path.\n\n@param name the user name\n@param size IconSize to get ... |
protected static PatchElement createRollbackElement(final PatchEntry entry) {
final PatchElement patchElement = entry.element;
final String patchId;
final Patch.PatchType patchType = patchElement.getProvider().getPatchType();
if (patchType == Patch.PatchType.CUMULATIVE) {
pat... | [
"Create a patch element for the rollback patch.\n\n@param entry the entry\n@return the new patch element"
] | [
"Update the value of an embedded node property.\n\n@param executionEngine the {@link GraphDatabaseService} used to run the query\n@param keyValues the columns representing the identifier in the entity owning the embedded\n@param embeddedColumn the column on the embedded node (dot-separated properties)\n@param value... |
public void writeTo(Writer destination) {
Element eltRuleset = new Element("ruleset");
addAttribute(eltRuleset, "name", name);
addChild(eltRuleset, "description", description);
for (PmdRule pmdRule : rules) {
Element eltRule = new Element("rule");
addAttribute(elt... | [
"Serializes this RuleSet in an XML document.\n\n@param destination The writer to which the XML document shall be written."
] | [
"Returns an input stream that applies the required decompression to the\ngiven input stream.\n\n@param inputStream\nthe input stream with the (possibly compressed) data\n@param compressionType\nthe kind of compression\n@return an input stream with decompressed data\n@throws IOException\nif there was a problem creat... |
public void setEnterpriseText(int index, String value)
{
set(selectField(AssignmentFieldLists.ENTERPRISE_TEXT, index), value);
} | [
"Set an enterprise text value.\n\n@param index text index (1-40)\n@param value text value"
] | [
"Handle value change event on the individual dates list.\n@param event the change event.",
"Attachments are only structurally different if one step has an inline attachment\nand the other step either has no inline attachment or the inline attachment is\ndifferent.",
"Shuts down a standalone server.\n\n@param cl... |
public double[] getMoneynessAsOffsets() {
DoubleStream moneyness = getGridNodesPerMoneyness().keySet().stream().mapToDouble(Integer::doubleValue);
if(quotingConvention == QuotingConvention.PAYERVOLATILITYLOGNORMAL) {
moneyness = moneyness.map(new DoubleUnaryOperator() {
@Override
public double apply... | [
"Return all levels of moneyness for which data exists.\nMoneyness is returned as actual difference strike - par swap rate.\n\n@return The levels of moneyness as difference of strike to par swap rate."
] | [
"Template-and-Hook method for generating the url required by the jdbc driver\nto allow for modifying an existing database.",
"Returns the name of the current member which is the name in the case of a field, or the property name for an\naccessor method.\n\n@return The member name\n@exception X... |
public boolean contains(String column) {
for ( String columnName : columnNames ) {
if ( columnName.equals( column ) ) {
return true;
}
}
return false;
} | [
"Check if a column is part of the row key columns.\n\n@param column the name of the column to check\n@return true if the column is one of the row key columns, false otherwise"
] | [
"Returns the getter method for field on an object.\n\n@param object\nthe object\n@param fieldName\nthe field name\n@return the getter associated with the field on the object\n@throws NullPointerException\nif object or fieldName is null\n@throws SuperCsvReflectionException\nif the getter doesn't exist or is not visi... |
@Override
public final double getDouble(final String key) {
Double result = optDouble(key);
if (result == null) {
throw new ObjectMissingException(this, key);
}
return result;
} | [
"Get a property as a double or throw an exception.\n\n@param key the property name"
] | [
"Use the universal project reader to open the file.\nThrow an exception if we can't determine the file type.\n\n@param inputFile file name\n@return ProjectFile instance",
"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 m... |
public synchronized Object[] getIds() {
String[] keys = getAllKeys();
int size = keys.length + indexedProps.size();
Object[] res = new Object[size];
System.arraycopy(keys, 0, res, 0, keys.length);
int i = keys.length;
// now add all indexed properties
for (Object ... | [
"Get an array of property ids.\n\nNot all property ids need be returned. Those properties\nwhose ids are not returned are considered non-enumerable.\n\n@return an array of Objects. Each entry in the array is either\na java.lang.String or a java.lang.Number"
] | [
"Set a friendly name for a client\n\n@param profileId profileId of the client\n@param clientUUID UUID of the client\n@param friendlyName friendly name of the client\n@return return Client object or null\n@throws Exception exception",
"Ensure that a tool object is valid for creation. The API requires certain field... |
@Override
public String getText() {
String retType = AstToTextHelper.getClassText(returnType);
String exceptionTypes = AstToTextHelper.getThrowsClauseText(exceptions);
String parms = AstToTextHelper.getParametersText(parameters);
return AstToTextHelper.getModifiersText(modifiers) + "... | [
"Provides a nicely formatted string of the method definition. For simplicity, generic types on some of the elements\nare not displayed.\n@return\nstring form of node with some generic elements suppressed"
] | [
"Attempts shared acquisition with a max wait time.\n@param permit - the permit Integer for this operation. May not be {@code null}.\n@param timeout - the time value to wait for acquiring the lock\n@param unit - See {@code TimeUnit} for valid values\n@return {@code boolean} true on success.",
"Populate a resource ... |
public String getDependencyJsonModel() throws IOException {
final Artifact artifact = DataModelFactory.createArtifact("","","","","","","");
return JsonUtils.serialize(DataModelFactory.createDependency(artifact, Scope.COMPILE));
} | [
"Returns an empty model of a Dependency in Json\n\n@return String\n@throws IOException"
] | [
"Construct new path by replacing file directory part. No\nfiles are actually modified.\n@param file path to move\n@param target new path directory",
"Abort the daemon\n\n@param error the error causing the abortion",
"Use this API to flush nssimpleacl.",
"Visit this and all child nodes.\n\n@param visitor The v... |
private void readHeader(InputStream is) throws IOException
{
byte[] header = new byte[20];
is.read(header);
m_offset += 20;
SynchroLogger.log("HEADER", header);
} | [
"Read the file header data.\n\n@param is input stream"
] | [
"Retrieve a finish date.\n\n@param data byte array\n@param offset offset into byte array\n@return finish date",
"Convenience method dispatches this object to the source appender, which\nwill result in the custom message being appended to the new file.\n\n@param message\nThe custom logging message to be appended."... |
public static void startAndWait(PersistentNode node, int maxWaitSec) {
node.start();
int waitTime = 0;
try {
while (node.waitForInitialCreate(1, TimeUnit.SECONDS) == false) {
waitTime += 1;
log.info("Waited " + waitTime + " sec for ephemeral node to be created");
if (waitTime >... | [
"Starts the ephemeral node and waits for it to be created\n\n@param node Node to start\n@param maxWaitSec Maximum time in seconds to wait"
] | [
"Get a property as a object or throw exception.\n\n@param key the property name",
"Retrieve all References\n\n@param newObj the instance to be loaded or refreshed\n@param cld the ClassDescriptor of the instance\n@param forced if set to true loading is forced even if cld differs.",
"Post-configure retreival of s... |
public InputStream getStream(String url, RasterLayer layer) throws IOException {
if (layer instanceof ProxyLayerSupport) {
ProxyLayerSupport proxyLayer = (ProxyLayerSupport) layer;
if (proxyLayer.isUseCache() && null != cacheManagerService) {
Object cachedObject = cacheManagerService.get(proxyLayer, CacheCa... | [
"Get the contents from the request URL.\n\n@param url URL to get the response from\n@param layer the raster layer\n@return {@link InputStream} with the content\n@throws IOException cannot get content"
] | [
"Adds title and subtitle to the TitleBand when it applies.\nIf title is not present then subtitle will be ignored",
"Prints a report about the statistics stored in the given data object.\n\n@param usageStatistics\nthe statistics object to print\n@param entityLabel\nthe label to use to refer to this kind of entiti... |
private RgbaColor withHsl(int index, float value) {
float[] HSL = convertToHsl();
HSL[index] = value;
return RgbaColor.fromHsl(HSL);
} | [
"Returns a new color with a new value of the specified HSL\ncomponent."
] | [
"Add authentication information for the given host\n@param host the host\n@param credentials the credentials\n@param authScheme the scheme for preemptive authentication (should be\n<code>null</code> if adding authentication for a proxy server)\n@param context the context in which the authentication information\nsho... |
private InputStream runSparqlQuery(String query) throws IOException {
try {
String queryString = "query=" + URLEncoder.encode(query, "UTF-8")
+ "&format=json";
URL url = new URL("https://query.wikidata.org/sparql?"
+ queryString);
HttpURLConnection connection = (HttpURLConnection) url
.openCon... | [
"Executes a given SPARQL query and returns a stream with the result in\nJSON format.\n\n@param query\n@return\n@throws IOException"
] | [
"Returns a raw handle to the SQLite database connection. Do not close!\n@param context A context, which is used to (when needed) set up a connection to the database\n@return The single, unique connection to the database, as is (also) used by our Cupboard instance",
"Creates a field map for relations.\n\n@param pr... |
public static void checkOperatorIsValid(int operatorCode) {
switch (operatorCode) {
case OPERATOR_LT:
case OPERATOR_LE:
case OPERATOR_EQ:
case OPERATOR_NE:
case OPERATOR_GE:
case OPERATOR_GT:
case OPERATOR_UNKNOWN:
... | [
"Checks if the given operator code is a valid one.\n\n@param operatorCode an operator code to evaluate\n@throws IllegalStateException if operatorCode is not a known operator code."
] | [
"Returns a TypeConverter for a given class.\n\n@param cls The class for which the TypeConverter should be fetched.",
"Returns an unmodifiable set containing the given elements.\n\n@param ts the elements from which to create a set\n@param <T> the type of the element in the set\n@return an unmodifiable set containi... |
private Set<QualifierInstance> getRequiredQualifiers(EnhancedAnnotatedParameter<?, ? super X> enhancedDisposedParameter) {
Set<Annotation> disposedParameterQualifiers = enhancedDisposedParameter.getMetaAnnotations(Qualifier.class);
if (disposedParameterQualifiers.isEmpty()) {
disposedParamet... | [
"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"
] | [
"Returns an iterable containing the items in this folder and specifies which child fields to retrieve from the\nAPI.\n\n@param fields the fields to retrieve.\n@return an iterable containing the items in this folder.",
"Remove all the existing links of the DeclarationBinder.\n\n@param declarationBinderRef the Serv... |
@Override
public ProxyAuthenticationMethod getMethod() {
switch (authenticationMethod) {
case BASIC:
return ProxyAuthenticationMethod.BASIC;
case DIGEST:
return ProxyAuthenticationMethod.DIGEST;
case URL:
return ProxyAuthenticationMethod.URL;
default:
return null;
}
} | [
"Get the authentication method to use.\n\n@return authentication method"
] | [
"Reads outline code custom field values and populates container.",
"Read JdbcConnectionDescriptors from the given repository file.\n\n@see #mergeConnectionRepository",
"Print the class's operations m",
"Returns a presentable version of the given PTB-tokenized text.\nPTB tokenization splits up punctuation and ... |
public void addChannel(String boneName, GVRAnimationChannel channel)
{
int boneId = mSkeleton.getBoneIndex(boneName);
if (boneId >= 0)
{
mBoneChannels[boneId] = channel;
mSkeleton.setBoneOptions(boneId, GVRSkeleton.BONE_ANIMATE);
Log.d("BONE", "Adding anim... | [
"Add a channel to the animation to animate the named bone.\n@param boneName name of bone to animate.\n@param channel The animation channel."
] | [
"MOVED INSIDE ExpressionUtils\n\nprotected JRDesignExpression getExpressionForConditionalStyle(ConditionalStyle condition, String columExpression) {\nString fieldsMap = \"((\"+DJDefaultScriptlet.class.getName() + \")$P{REPORT_SCRIPTLET}).getCurrentFields()\";\nString parametersMap = \"((\"+DJDefaultScriptlet.class.... |
public static int compare(double a, double b, double delta) {
if (equals(a, b, delta)) {
return 0;
}
return Double.compare(a, b);
} | [
"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."
] | [
"Parses a record containing hours and add them to a container.\n\n@param ranges hours container\n@param hoursRecord hours record",
"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 upda... |
public static base_response add(nitro_service client, sslocspresponder resource) throws Exception {
sslocspresponder addresource = new sslocspresponder();
addresource.name = resource.name;
addresource.url = resource.url;
addresource.cache = resource.cache;
addresource.cachetimeout = resource.cachetimeout;
a... | [
"Use this API to add sslocspresponder."
] | [
"Return the Payload attached to the current active bucket for |test|.\nAlways returns a payload so the client doesn't crash on a malformed\ntest definition.\n\n@param testName test name\n@return pay load attached to the current active bucket\n@deprecated Use {@link #getPayload(String, Bucket)} instead",
"Returns ... |
public static String wordShape(String inStr, int wordShaper, Collection<String> knownLCWords) {
// this first bit is for backwards compatibility with how things were first
// implemented, where the word shaper name encodes whether to useLC.
// If the shaper is in the old compatibility list, then a specif... | [
"Specify the string and the int identifying which word shaper to\nuse and this returns the result of using that wordshaper on the String.\n\n@param inStr String to calculate word shape of\n@param wordShaper Constant for which shaping formula to use\n@param knownLCWords A Collection of known lowercase words, which s... | [
"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",
"Gets the value for the key.\n\n@param key the... |
private String getHostHeaderForHost(String hostName) {
List<ServerRedirect> servers = serverRedirectService.tableServers(requestInformation.get().client.getId());
for (ServerRedirect server : servers) {
if (server.getSrcUrl().compareTo(hostName) == 0) {
String hostHeader = se... | [
"Obtain host header value for a hostname\n\n@param hostName\n@return"
] | [
"Processes the template for all column definitions of the current table.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\n@doc.tag type=\"block\"",
"Acquire the exclusive lock, with a max wait... |
private boolean getRelative(int value)
{
boolean result;
if (value < 0 || value >= RELATIVE_MAP.length)
{
result = false;
}
else
{
result = RELATIVE_MAP[value];
}
return result;
} | [
"Determine if the exception is relative based on the recurrence type integer value.\n\n@param value integer value\n@return true if the recurrence is relative"
] | [
"Parse a parameterized object from an InputStream.\n\n@param is The InputStream, most likely from your networking library.\n@param jsonObjectType The ParameterizedType describing the object. Ex: LoganSquare.parse(is, new ParameterizedType<MyModel<OtherModel>>() { });",
"Places a connection back in the... |
public static String[] slice(String[] strings, int begin, int length) {
String[] result = new String[length];
System.arraycopy( strings, begin, result, 0, length );
return result;
} | [
"Create a smaller array from an existing one.\n\n@param strings an array containing element of type {@link String}\n@param begin the starting position of the sub-array\n@param length the number of element to consider\n@return a new array continaining only the selected elements"
] | [
"Dumps an animation channel to stdout.\n\n@param nodeAnim the channel",
"Merges two lists of references, eliminating duplicates in the process.\n\n@param references1\n@param references2\n@return merged list",
"Get the class name without the qualified package name.\n@param className the className to get the shor... |
private void populateCalendar(Record record, ProjectCalendar calendar, boolean isBaseCalendar)
{
if (isBaseCalendar == true)
{
calendar.setName(record.getString(0));
}
else
{
calendar.setParent(m_projectFile.getCalendarByName(record.getString(0)));
}
calen... | [
"Populates a calendar instance.\n\n@param record MPX record\n@param calendar calendar instance\n@param isBaseCalendar true if this is a base calendar"
] | [
"Clone a widget info map considering what may be copied to the client.\n\n@param widgetInfo widget info map\n@return cloned copy including only records which are not {@link ServerSideOnlyInfo}",
"Make a list value containing the specified values.",
"as we know nothing has changed.",
"Go through all nodes and ... |
private HashMap<String, StoreDefinition> makeStoreDefinitionMap(List<StoreDefinition> storeDefs) {
HashMap<String, StoreDefinition> storeDefMap = new HashMap<String, StoreDefinition>();
for(StoreDefinition storeDef: storeDefs)
storeDefMap.put(storeDef.getName(), storeDef);
return sto... | [
"Returns the list of store defs as a map\n\n@param storeDefs\n@return"
] | [
"Clears out the statement handles.\n@param internalClose if true, close the inner statement handle too.",
"Add a property.",
"Reads the next chunk for the intermediate work buffer.",
"Execute a partitioned query using an index and a query selector.\n\nOnly available in partitioned databases. To verify a datab... |
public double getBearing(LatLong end) {
if (this.equals(end)) {
return 0;
}
double lat1 = latToRadians();
double lon1 = longToRadians();
double lat2 = end.latToRadians();
double lon2 = end.longToRadians();
double angle = -Math.atan2(Math.sin(lon1 - l... | [
"Calculates the bearing, in degrees, of the end LatLong point from this\nLatLong point.\n\n@param end The point that the bearing is calculated for.\n@return The bearing, in degrees, of the supplied point from this point."
] | [
"Get a list of referring domains for a collection.\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 collectionId\n(Optional) The id of the collect... |
public ValueContainer[] getKeyValues(ClassDescriptor cld, Object objectOrProxy, boolean convertToSql) throws PersistenceBrokerException
{
IndirectionHandler handler = ProxyHelper.getIndirectionHandler(objectOrProxy);
if(handler != null)
{
return getKeyValues(cld, handler.g... | [
"Returns an Array with an Objects PK VALUES if convertToSql is true, any\nassociated java-to-sql conversions are applied. If the Object is a Proxy\nor a VirtualProxy NO conversion is necessary.\n\n@param objectOrProxy\n@param convertToSql\n@return Object[]\n@throws PersistenceBrokerException"
] | [
"Use this API to fetch hanode_routemonitor_binding resources of given name .",
"Sets the duration for the animations in this animator.\n\n@param start the animation will start playing from the specified time\n@param end the animation will stop playing at the specified time\n\n@see GVRAnimation#setDuration(float, ... |
@Override
@SuppressWarnings("unchecked")
public ChronoLocalDateTime<JulianDate> localDateTime(TemporalAccessor temporal) {
return (ChronoLocalDateTime<JulianDate>) super.localDateTime(temporal);
} | [
"Obtains a Julian local date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Julian local date-time, not null\n@throws DateTimeException if unable to create the date-time"
] | [
"Gets the registration point that been associated with the registration for the longest period.\n\n@return the initial registration point, or {@code null} if there are no longer any registration points",
"Gets the data by id.\n\n@param id the id\n@return the data by id\n@throws IOException Signals that an I/O exc... |
public String getUniqueFilename(String baseFileName, String extension, boolean cleanBaseFileName, String... ancestorFolders)
{
if (cleanBaseFileName)
{
baseFileName = PathUtil.cleanFileName(baseFileName);
}
if (ancestorFolders != null)
{
Path pathToFi... | [
"Returns a unique file name\n@param baseFileName the requested base name for the file\n@param extension the requested extension for the file\n@param cleanBaseFileName specify if the <code>baseFileName</code> has to be cleaned before being used (i.e. 'jboss-web' should not be cleaned to avoid '-' to become '_')\n@pa... | [
"Searches the variables layers, top to bottom, for given name, and returns if found; null otherwise.\n\nIf maxDepth is set to {@link Variables#SEARCH_ALL_LAYERS}, then search all layers.",
"Return the list of galleries created by a user. Sorted from newest to oldest.\n\n@param userId\nThe user you want to check f... |
public ReferrerList getCollectionReferrers(Date date, String domain, String collectionId, int perPage, int page) throws FlickrException {
return getReferrers(METHOD_GET_COLLECTION_REFERRERS, domain, "collection_id", collectionId, date, perPage, page);
} | [
"Get a list of referrers from a given domain to a collection.\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 re... | [
"Convert from Hadoop Text to Bytes",
"Return the max bounds of the layer as envelope.\n\n@param layer the layer to get envelope from\n@return Envelope the envelope",
"Executes a query using the given parameters. The query results will be added to the\nExecutionResults using the given identifier.\n\n@param ident... |
public Bundler put(String key, String value) {
delegate.putString(key, value);
return this;
} | [
"Inserts a String value into the mapping of the underlying Bundle, replacing any existing value\nfor the given key. Either key or value may be null.\n\n@param key a String, or null\n@param value a String, or null\n@return this bundler instance to chain method calls"
] | [
"Returns the compact tag records for all tags in the workspace.\n\n@param workspace The workspace or organization to find tags in.\n@return Request object",
"returns true if a job was queued within a timeout",
"Validate that the configuration is valid.\n\n@return any validation errors.",
"Creates the contain... |
public static boolean isSafe(Expression expression) {
if (expression instanceof MethodCallExpression) {
return ((MethodCallExpression) expression).isSafe();
}
if (expression instanceof PropertyExpression) {
return ((PropertyExpression) expression).isSafe();
... | [
"Tells you if the expression is a null safe dereference.\n@param expression\nexpression\n@return\ntrue if is null safe dereference."
] | [
"Use this API to update nsrpcnode.",
"Throw fault.\n\n@param code the fault code\n@param message the message\n@param t the throwable type\n@throws PutEventsFault",
"Retrieve the version number",
"Removes the specified list of users from following the project, this will not affect project membership status.\nR... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.