query
stringlengths 74
6.1k
| positive
sequencelengths 1
1
| negative
sequencelengths 9
9
|
---|---|---|
public String translatePath(String path) {
String translated;
// special character: ~ maps to the user's home directory
if (path.startsWith("~" + File.separator)) {
translated = System.getProperty("user.home") + path.substring(1);
} else if (path.startsWith("~")) {
String userName = path.substring(1);
translated = new File(new File(System.getProperty("user.home")).getParent(),
userName).getAbsolutePath();
// Keep the path separator in translated or add one if no user home specified
translated = userName.isEmpty() || path.endsWith(File.separator) ? translated + File.separator : translated;
} else if (!new File(path).isAbsolute()) {
translated = ctx.getCurrentDir().getAbsolutePath() + File.separator + path;
} else {
translated = path;
}
return translated;
} | [
"Translate a path that has previously been unescaped and unquoted.\nThat is called at command execution when the calue is retrieved prior to be\nused as ModelNode value.\n@param path The unquoted, unescaped path.\n@return A path with ~ and default dir expanded."
] | [
"Add an additional binary type",
"Returns a new color that has the hue adjusted by the specified\namount.",
"Helper method to split a string by a given character, with empty parts omitted.",
"Use this API to enable clusterinstance resources of given names.",
"Sets the number of views for this Photo. For un-authenticated calls this value is not available and will be set to -1.\n\n@param views\n@deprecated attribute no longer available",
"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.",
"Use this API to unset the properties of nsrpcnode resources.\nProperties that need to be unset are specified in args array.",
"Return the value of field in the data argument if it is not the default value for the class. If it is the default\nthen null is returned.",
"Read a text file from assets into a single string\n\n@param context\nA non-null Android Context\n@param asset\nThe asset file to read\n@return The contents or null on error."
] |
protected void eciProcess() {
EciMode eci = EciMode.of(content, "ISO8859_1", 3)
.or(content, "ISO8859_2", 4)
.or(content, "ISO8859_3", 5)
.or(content, "ISO8859_4", 6)
.or(content, "ISO8859_5", 7)
.or(content, "ISO8859_6", 8)
.or(content, "ISO8859_7", 9)
.or(content, "ISO8859_8", 10)
.or(content, "ISO8859_9", 11)
.or(content, "ISO8859_10", 12)
.or(content, "ISO8859_11", 13)
.or(content, "ISO8859_13", 15)
.or(content, "ISO8859_14", 16)
.or(content, "ISO8859_15", 17)
.or(content, "ISO8859_16", 18)
.or(content, "Windows_1250", 21)
.or(content, "Windows_1251", 22)
.or(content, "Windows_1252", 23)
.or(content, "Windows_1256", 24)
.or(content, "SJIS", 20)
.or(content, "UTF8", 26);
if (EciMode.NONE.equals(eci)) {
throw new OkapiException("Unable to determine ECI mode.");
}
eciMode = eci.mode;
inputData = toBytes(content, eci.charset);
encodeInfo += "ECI Mode: " + eci.mode + "\n";
encodeInfo += "ECI Charset: " + eci.charset.name() + "\n";
} | [
"Chooses the ECI mode most suitable for the content of this symbol."
] | [
"Use this API to unset the properties of gslbservice resources.\nProperties that need to be unset are specified in args array.",
"Returns the rendered element content for all the given containers.\n\n@param element the element to render\n@param containers the containers the element appears in\n\n@return a map from container names to rendered page contents",
"Retrieves the notes text for this resource.\n\n@return notes text",
"Updates the internal list of dates and fires a value change if necessary.\n\n@param dates the dates to set.",
"Generate the next combination and return an array containing\nthe appropriate elements.\n@see #nextCombinationAsArray(Object[])\n@see #nextCombinationAsList()\n@return An array containing the elements that make up the next combination.",
"Seeks forward or backwards to a particular holiday based on the current date\n\n@param holidayString The holiday to seek to\n@param direction The direction to seek\n@param seekAmount The number of years to seek",
"Create and return a new Violation for this rule and the specified import\n@param sourceCode - the SourceCode\n@param importNode - the ImportNode for the import triggering the violation\n@return a new Violation object",
"Loads the columns for this table into the alChildren list.",
"Add a LIKE clause so the column must mach the value using '%' patterns."
] |
private void countPropertyMain(UsageStatistics usageStatistics,
PropertyIdValue property, int count) {
addPropertyCounters(usageStatistics, property);
usageStatistics.propertyCountsMain.put(property,
usageStatistics.propertyCountsMain.get(property) + count);
} | [
"Counts additional occurrences of a property as the main property of\nstatements.\n\n@param usageStatistics\nstatistics object where count is stored\n@param property\nthe property to count\n@param count\nthe number of times to count the property"
] | [
"Log a warning for the given operation at the provided address for the given attributes, using the provided detail\nmessage.\n\n@param address where warning occurred\n@param operation where which problem occurred\n@param message custom error message to append\n@param attributes attributes we that have problems about",
"Set new front facing rotation\n@param rotation",
"Send ourselves \"updates\" about any tracks that were loaded before we started, or before we were requesting\ndetails, since we missed them.",
"Creates AzureAsyncOperation from the given HTTP response.\n\n@param serializerAdapter the adapter to use for deserialization\n@param response the response\n@return the async operation object\n@throws CloudException if the deserialization fails or response contains invalid body",
"Simple context menu handler for multi-select tables.\n\n@param table the table\n@param menu the table's context menu\n@param event the click event\n@param entries the context menu entries",
"Detokenize the input list of words.\n\n@param tokens List of words.\n@return Detokenized string.",
"Handles DMR strings in the configuration\n\n@param node the node to create.\n@param name the name for the node.\n@param value the value for the node.",
"Creates the actual path to the xml file of the module.",
"Map a single ResultSet row to a T instance.\n\n@throws SQLException"
] |
static Resource getOrCreateSubDeployment(final String deploymentName, final DeploymentUnit parent) {
final Resource root = parent.getAttachment(DEPLOYMENT_RESOURCE);
return getOrCreate(root, PathElement.pathElement(SUBDEPLOYMENT, deploymentName));
} | [
"Gets or creates the a resource for the sub-deployment on the parent deployments resource.\n\n@param deploymentName the name of the deployment\n@param parent the parent deployment used to find the parent resource\n\n@return the already registered resource or a newly created resource"
] | [
"Creates a new capsule\n\n@param mode the capsule mode, or {@code null} for the default mode\n@param wrappedJar a path to a capsule JAR that will be launched (wrapped) by the empty capsule in {@code jarFile}\nor {@code null} if no wrapped capsule is wanted\n@return the capsule.",
"Tells you if an expression is the expected constant.\n@param expression\nany expression\n@param expected\nthe expected int or String\n@return\nas described",
"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",
"static expansion helpers",
"Returns the squared of the Euclidean distance between this vector and\nvector v.\n\n@return squared distance between this vector and v",
"Remove all of the audio sources from the audio manager.\nThis will stop all sound from playing.",
"Returns an ArrayList of String URLs of the Carousel Images\n@return ArrayList of Strings",
"host.xml",
"Scroll to the next page. To process the scrolling by pages LayoutScroller must be constructed\nwith a pageSize greater than zero.\n@return the new current item after the scrolling processed."
] |
private ServerSetup[] createServerSetup() {
List<ServerSetup> setups = new ArrayList<>();
if (smtpProtocol) {
smtpServerSetup = createTestServerSetup(ServerSetup.SMTP);
setups.add(smtpServerSetup);
}
if (smtpsProtocol) {
smtpsServerSetup = createTestServerSetup(ServerSetup.SMTPS);
setups.add(smtpsServerSetup);
}
if (pop3Protocol) {
setups.add(createTestServerSetup(ServerSetup.POP3));
}
if (pop3sProtocol) {
setups.add(createTestServerSetup(ServerSetup.POP3S));
}
if (imapProtocol) {
setups.add(createTestServerSetup(ServerSetup.IMAP));
}
if (imapsProtocol) {
setups.add(createTestServerSetup(ServerSetup.IMAPS));
}
return setups.toArray(new ServerSetup[setups.size()]);
} | [
"Creates the server setup, depending on the protocol flags.\n\n@return the configured server setups."
] | [
"Given a Task instance, this task determines if it should be written to the\nPM XML file as an activity or as a WBS item, and calls the appropriate\nmethod.\n\n@param task Task instance",
"Get the Avro Schema of the input path, assuming the path contains just one\nschema version in all files under that path.",
"returns true if the primary key fields are valid for delete, else false.\nPK fields are valid if each of them contains a valid non-null value\n@param cld the ClassDescriptor\n@param obj the object\n@return boolean",
"remove the user profile with id from the db.",
"2-D Forward Discrete Hartley Transform.\n\n@param data Data.",
"Retrieves the earliest start date for all assigned tasks.\n\n@return start date",
"Reads a time value. The time is represented as tenths of a\nminute since midnight.\n\n@param data byte array of data\n@param offset location of data as offset into the array\n@return time value",
"Returns the arguments as a list in their command line form.\n\n@return the arguments for the command line",
"Check the given URI to see if it matches.\n\n@param matchInfo the matchInfo to validate.\n@return True if it matches."
] |
public static Class<?> loadClass(String className, ClassLoader cl) {
try {
return Class.forName(className, false, cl);
} catch(ClassNotFoundException e) {
throw new IllegalArgumentException(e);
}
} | [
"Load the given class using a specific class loader.\n\n@param className The name of the class\n@param cl The Class Loader to be used for finding the class.\n@return The class object"
] | [
"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",
"Adds a new row after the given one.\n\n@param row the row after which a new one should be added",
"Use this API to add locationfile.",
"Returns the text value of all of the elements in the collection.\n\n@return the text value of all the elements in the collection or null",
"Returns a description a block of work, or \"exit\" if no more blocks exist\n\n@param name the assigned name of the consumer requesting a block of work\n@return a description a block of work, or \"exit\" if no more blocks exist",
"Return a String of length a minimum of totalChars characters by\npadding the input String str at the right end with spaces.\nIf str is already longer\nthan totalChars, it is returned unchanged.",
"Adds a variable to the end of the token list\n@param variable Variable which is to be added\n@return The new Token created around variable",
"Use this API to sync gslbconfig.",
"We have an OLE compound document... but is it an MPP file?\n\n@param stream file input stream\n@return ProjectFile instance"
] |
public static String getParameter(DbConn cnx, String key, String defaultValue)
{
try
{
return cnx.runSelectSingle("globalprm_select_by_key", 3, String.class, key);
}
catch (NoResultException e)
{
return defaultValue;
}
} | [
"Retrieve the value of a single-valued parameter.\n\n@param key\n@param defaultValue\n@param cnx"
] | [
"Handles Multi Instance Report message. Handles Report on\nthe number of instances for the command class.\n@param serialMessage the serial message to process.\n@param offset the offset at which to start procesing.",
"Read project data from a database.\n\n@return ProjectFile instance\n@throws MPXJException",
"Specify the time out of the session established at the server. The\nsession is kept alive by requests sent by this client object. If the\nsession is idle for a period of time that would timeout the session, the\nclient will send a PING request to keep the session alive.\n\n@param timeout timeout in milliseconds, must be greater than zero and less\nthan 60000.",
"Parse the json string to the diagram model, assumes that the json is\nhierarchical ordered\n@param json\n@return Model with all shapes defined in JSON\n@throws org.json.JSONException",
"Get a property as a double or defaultValue.\n\n@param key the property name\n@param defaultValue the default value",
"Gets the thread usage.\n\n@return the thread usage",
"Rehashes the contents of the receiver into a new table\nwith a smaller or larger capacity.\nThis method is called automatically when the\nnumber of keys in the receiver exceeds the high water mark or falls below the low water mark.",
"Return the Renderer class associated to the prototype.\n\n@param prototypeClass used to search the renderer in the prototypes collection.\n@return the prototype index associated to the prototypeClass.",
"Read correlation id.\n\n@param message the message\n@return correlation id from the message"
] |
@Override
public String upload(byte[] data, UploadMetaData metaData) throws FlickrException {
Payload payload = new Payload(data);
return sendUploadRequest(metaData, payload);
} | [
"Upload a photo from a byte-array.\n\n@param data\nThe photo data as a byte array\n@param metaData\nThe meta data\n@return photoId or ticketId\n@throws FlickrException"
] | [
"Execute a slave process. Pump events to the given event bus.",
"Compress a directory into a zip file\n\n@param dir Directory\n@param zipFile ZIP file to create\n@throws IOException I/O Error",
"Microsoft Project bases the order of tasks displayed on their ID\nvalue. This method takes the hierarchical structure of tasks\nrepresented in MPXJ and renumbers the ID values to ensure that\nthis structure is displayed as expected in Microsoft Project. This\nis typically used to deal with the case where a hierarchical task\nstructure has been created programmatically in MPXJ.",
"Flatten a list of test suite results into a collection of results grouped by test class.\nThis method basically strips away the TestNG way of organising tests and arranges\nthe results by test class.",
"Detach a connection from a key.\n\n@param key\nthe key\n@param connection\nthe connection",
"Sets the provided filters.\n@param filters a map \"column id -> filter\".",
"Store a comment based on comment text, gavc and user information\n\n@param gavc - entity id\n@param commentText - comment text\n@param credential - user credentials\n@param entityType - type of the entity",
"Extract site path, base name and locale from the resource opened with the editor.",
"Adds all pairs from 'fromMap' to 'toMap' excluding once that matching the pattern"
] |
@Override
public boolean postBuild(MavenBuildProxy build, MavenProject pom, BuildListener listener)
throws InterruptedException, IOException {
build.executeAsync(new BuildCallable<Void, IOException>() {
// record is transient, so needs to make a copy first
private final Set<MavenDependency> d = dependencies;
public Void call(MavenBuild build) throws IOException, InterruptedException {
// add the action
//TODO: [by yl] These actions are persisted into the build.xml of each build run - we need another
//context to store these actions
build.getActions().add(new MavenDependenciesRecord(build, d));
return null;
}
});
return true;
} | [
"Sends the collected dependencies over to the master and record them."
] | [
"If the status of a print job is not checked for a while, we assume that the user is no longer\ninterested in the report, and we cancel the job.\n\n@param printJob\n@return is the abandoned timeout exceeded?",
"Adds a data source to the configuration. If in deduplication mode\ngroupno == 0, otherwise it gives the number of the group to which\nthe data source belongs.",
"The cell String is the string representation of the object.\nIf padLeft is greater than 0, it is padded. Ditto right",
"Loads a PDF document and creates a DOM tree from it.\n@param doc the source document\n@return a DOM Document representing the DOM tree\n@throws IOException",
"A factory method for users that need to report success without actually running any analysis. The returned\nresult will be successful, but will not contain the actual configurations of extensions.\n\n@return a \"fake\" successful analysis result",
"URLDecode a string\n@param s\n@return",
"Main method of this class related to ListView widget. This method is the responsible of\nrecycle or create a new Renderer instance with all the needed information to implement the\nrendering. This method will validate all the attributes passed in the builder constructor and\nwill check if can recycle or has to create a new Renderer instance.\n\nThis method is used with ListView because the view recycling mechanism is implemented in this\nclass. RecyclerView widget will use buildRendererViewHolder method.\n\n@return ready to use Renderer instance.",
"Generates a License regarding the parameters.\n\n@param name String\n@param longName String\n@param comments String\n@param regexp String\n@param url String\n@return License",
"Initialize. create the httpClientStore, tcpClientStore"
] |
public boolean isWorkingDate(Date date)
{
Calendar cal = DateHelper.popCalendar(date);
Day day = Day.getInstance(cal.get(Calendar.DAY_OF_WEEK));
DateHelper.pushCalendar(cal);
return isWorkingDate(date, day);
} | [
"This method allows the caller to determine if a given date is a\nworking day. This method takes account of calendar exceptions.\n\n@param date Date to be tested\n@return boolean value"
] | [
"Returns all the deployment runtime names associated with an overlay accross all server groups.\n\n@param context the current OperationContext.\n@param overlay the name of the overlay.\n@return all the deployment runtime names associated with an overlay accross all server groups.",
"Returns the JMX connector address of a child process.\n\n@param p the process to which to connect\n@param startAgent whether to installed the JMX agent in the target process if not already in place\n@return a {@link JMXServiceURL} to the process's MBean server",
"Gets a SerialMessage with the MULTI INSTANCE GET command.\nReturns the number of instances for this command class.\n@param the command class to return the number of instances for.\n@return the serial message.",
"Checks if the given String is null or contains only whitespaces.\nThe String is trimmed before the empty check.\n\n@param argument the String to check for null or emptiness\n@param argumentName the name of the argument to check.\nThis is used in the exception message.\n@return the String that was given as argument\n@throws IllegalArgumentException in case argument is null or empty",
"Executes the API action \"wbsetclaim\" for the given parameters.\n\n@param statement\nthe JSON serialization of claim to add or delete.\n@param bot\nif true, edits will be flagged as \"bot edits\" provided that\nthe logged in user is in the bot group; for regular users, the\nflag will just be ignored\n@param baserevid\nthe revision of the data that the edit refers to or 0 if this\nshould not be submitted; when used, the site will ensure that\nno edit has happened since this revision to detect edit\nconflicts; it is recommended to use this whenever in all\noperations where the outcome depends on the state of the\nonline data\n@param summary\nsummary for the edit; will be prepended by an automatically\ngenerated comment; the length limit of the autocomment\ntogether with the summary is 260 characters: everything above\nthat limit will be cut off\n@return the JSON response from the API\n@throws IOException\nif there was an IO problem. such as missing network\nconnection\n@throws MediaWikiApiErrorException\nif the API returns an error\n@throws IOException\n@throws MediaWikiApiErrorException",
"Adds a measure to the crosstab. A crosstab can have many measures. DJ will lay out one measure above\nthe other.\n\nA measure is what is shown on each intersection of a column and a row. A calculation is performed to\nall occurrences in the datasource where the column and row values matches (between elements)\n\nThe only difference between the prior methods is that this method sets \"visible\" to false\n\n@param property\n@param className\n@param title\n@return",
"Set the amount of padding between child objects.\n@param axis {@link Axis}\n@param padding",
"Ensures that the primary keys required by the given reference are present in the referenced class.\n\n@param modelDef The model\n@param refDef The reference\n@throws ConstraintException If there is a conflict between the primary keys",
"Lookup the group for the specified URL.\n\n@param url\nThe url\n@return The group\n@throws FlickrException"
] |
public List<GetLocationResult> search(String q, int maxRows, Locale locale)
throws Exception {
List<GetLocationResult> searchResult = new ArrayList<GetLocationResult>();
String url = URLEncoder.encode(q, "UTF8");
url = "q=select%20*%20from%20geo.placefinder%20where%20text%3D%22"
+ url + "%22";
if (maxRows > 0) {
url = url + "&count=" + maxRows;
}
url = url + "&flags=GX";
if (null != locale) {
url = url + "&locale=" + locale;
}
if (appId != null) {
url = url + "&appid=" + appId;
}
InputStream inputStream = connect(url);
if (null != inputStream) {
SAXBuilder parser = new SAXBuilder();
Document doc = parser.build(inputStream);
Element root = doc.getRootElement();
// check code for exception
String message = root.getChildText("Error");
// Integer errorCode = Integer.parseInt(message);
if (message != null && Integer.parseInt(message) != 0) {
throw new Exception(root.getChildText("ErrorMessage"));
}
Element results = root.getChild("results");
for (Object obj : results.getChildren("Result")) {
Element toponymElement = (Element) obj;
GetLocationResult location = getLocationFromElement(toponymElement);
searchResult.add(location);
}
}
return searchResult;
} | [
"Call the Yahoo! PlaceFinder service for a result.\n\n@param q\nsearch string\n@param maxRows\nmax number of rows in result, or 0 for all\n@param locale\nlocale for strings\n@return list of found results\n@throws Exception\noops\n@see <a\nhref=\"http://developer.yahoo.com/boss/geo/docs/free_YQL.html#table_pf\">Yahoo!\nBoss Geo PlaceFinder</a>"
] | [
"Release transaction that was acquired in a thread with specified permits.",
"Remove all existing subscriptions",
"host.xml",
"checks if the triangle is not re-entrant",
"Checks whether the compilation has been canceled and reports the given work increment to the compiler progress.",
"Rethrows OperationCanceledErrors and wraps platform specific OperationCanceledExceptions. Does nothing for any other type of Throwable.",
"Check type.\n\n@param type the type\n@return the boolean",
"Send a beat grid update announcement to all registered listeners.\n\n@param player the player whose beat grid information has changed\n@param beatGrid the new beat grid associated with that player, if any",
"Returns the command to run by the shell to normally run the checkin script.\n@return the command to run by the shell to normally run the checkin script."
] |
public static DMatrixRMaj diagonal(int numRows , int numCols , double min , double max , Random rand ) {
if( max < min )
throw new IllegalArgumentException("The max must be >= the min");
DMatrixRMaj ret = new DMatrixRMaj(numRows,numCols);
int N = Math.min(numRows,numCols);
double r = max-min;
for( int i = 0; i < N; i++ ) {
ret.set(i,i, rand.nextDouble()*r+min);
}
return ret;
} | [
"Creates a random matrix where all elements are zero but diagonal elements. Diagonal elements\nrandomly drawn from a uniform distribution from min to max, inclusive.\n\n@param numRows Number of rows in the returned matrix..\n@param numCols Number of columns in the returned matrix.\n@param min Minimum value of a diagonal element.\n@param max Maximum value of a diagonal element.\n@param rand Random number generator.\n@return A random diagonal matrix."
] | [
"Returns the command to run by the shell to normally run the checkin script.\n@return the command to run by the shell to normally run the checkin script.",
"Get the element at the index as a float.\n\n@param i the index of the element to access",
"Set the view frustum to pick against from the minimum and maximum corners.\nThe viewpoint of the frustum is the center of the scene object\nthe picker is attached to. The view direction is the forward\ndirection of that scene object. The frustum will pick what a camera\nattached to the scene object with that view frustum would see.\nIf the frustum is not attached to a scene object, it defaults to\nthe view frustum of the main camera of the scene.\n\n@param frustum array of 6 floats as follows:\nfrustum[0] = left corner of frustum\nfrustum[1] = bottom corner of frustum\nfrustum[2] = front corner of frustum (near plane)\nfrustum[3] = right corner of frustum\nfrustum[4] = top corner of frustum\nfrustum[5 = back corner of frustum (far plane)",
"This is a method to stream slops to \"slop\" store when a node is detected\nfaulty in a streaming session\n\n@param key -- original key\n@param value -- original value\n@param storeName -- the store for which we are registering the slop\n@param failedNodeId -- the faulty node ID for which we register a slop\n@throws IOException",
"This static method calculated the rho of a call option under a Black-Scholes model\n\n@param initialStockValue The initial value of the underlying, i.e., the spot.\n@param riskFreeRate The risk free rate of the bank account numerarie.\n@param volatility The Black-Scholes volatility.\n@param optionMaturity The option maturity T.\n@param optionStrike The option strike.\n@return The rho of the option",
"Use this API to unlink sslcertkey.",
"Removes a corporate groupId from an Organisation\n\n@param organizationId String\n@param corporateGroupId String",
"Adds two complex numbers.\n\n@param z1 Complex Number.\n@param z2 Complex Number.\n@return Returns new ComplexNumber instance containing the sum of specified complex numbers.",
"creates option map for remoting connections\n@param resolver\n@param model\n@param defaults\n@return\n@throws OperationFailedException\n@deprecated configuring xnio worker options is no longer supported and should be replaced for referencing IO subsystem"
] |
private List<TaskField> getAllTaskExtendedAttributes()
{
ArrayList<TaskField> result = new ArrayList<TaskField>();
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_TEXT));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_START));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_FINISH));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_COST));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_DATE));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_FLAG));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_NUMBER));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_DURATION));
result.addAll(Arrays.asList(TaskFieldLists.CUSTOM_OUTLINE_CODE));
result.addAll(Arrays.asList(TaskFieldLists.ENTERPRISE_COST));
result.addAll(Arrays.asList(TaskFieldLists.ENTERPRISE_DATE));
result.addAll(Arrays.asList(TaskFieldLists.ENTERPRISE_DURATION));
result.addAll(Arrays.asList(TaskFieldLists.ENTERPRISE_FLAG));
result.addAll(Arrays.asList(TaskFieldLists.ENTERPRISE_NUMBER));
result.addAll(Arrays.asList(TaskFieldLists.ENTERPRISE_TEXT));
return result;
} | [
"Retrieve list of task extended attributes.\n\n@return list of extended attributes"
] | [
"Log an audit record of this operation.",
"Checks that index is valid an throw an exception if not.\n\n@param type the type\n@param index the index to check",
"SetLoop will either set the GVRNodeAnimation's Repeat Mode to REPEATED if loop is true.\nor it will set the GVRNodeAnimation's Repeat Mode to ONCE if loop is false\nif loop is set to TRUE, when it was previously FALSE, then start the Animation.\n@param doLoop\n@param gvrContext",
"Creates custom Http Client connection pool to be used by Http Client\n\n@return {@link PoolingHttpClientConnectionManager}",
"Common method for creating styles.\n\n@param template the template that the map is part of\n@param styleRef the style ref identifying the style\n@param <T> the source type",
"Creates an endpoint reference by duplicating the endpoint reference of a given server.\n@param server\n@param address\n@param props\n@return",
"Creates an attachment from a binary input stream.\nThe content of the stream will be transformed into a Base64 encoded string\n@throws IOException if an I/O error occurs\n@throws java.lang.IllegalArgumentException if mediaType is not binary",
"Resolve the given class if it is a primitive class,\nreturning the corresponding primitive wrapper type instead.\n@param clazz the class to check\n@return the original class, or a primitive wrapper for the original primitive type",
"Use this API to delete dnssuffix resources of given names."
] |
public void setEditedFilePath(final String editedFilePath) {
m_filePathField.setReadOnly(false);
m_filePathField.setValue(editedFilePath);
m_filePathField.setReadOnly(true);
} | [
"Sets the path of the edited file in the corresponding display.\n@param editedFilePath path of the edited file to set."
] | [
"Update the descriptor content with values from the editor.\n@throws CmsXmlException thrown if update fails due to a wrong XML structure (should never happen)",
"Use this API to fetch a appfwglobal_auditsyslogpolicy_binding resources.",
"Add tables to the tree.\n\n@param parentNode parent tree node\n@param file tables container",
"Displays a sample model for the report request.\n@return A string describing the structure of a certain report execution",
"Returns a string representation of the receiver, containing\nthe String representation of each key-value pair, sorted ascending by value.",
"Returns all base types.\n\n@return An iterator of the base types",
"FOR internal use. This method was called after the external transaction was completed.\n\n@see javax.transaction.Synchronization",
"Initialize. create the httpClientStore, tcpClientStore",
"Use this API to fetch all the Interface resources that are configured on netscaler."
] |
public static synchronized Class< ? > locate(final String serviceName) {
if ( serviceName == null ) {
throw new IllegalArgumentException( "serviceName cannot be null" );
}
if ( factories != null ) {
List<Callable<Class< ? >>> l = factories.get( serviceName );
if ( l != null && !l.isEmpty() ) {
Callable<Class< ? >> c = l.get( l.size() - 1 );
try {
return c.call();
} catch ( Exception e ) {
}
}
}
return null;
} | [
"Finds the preferred provider for the given service. The preferred\nprovider is the last one added to the set of providers.\n\n@param serviceName\nThe fully qualified name of the service interface.\n@return\nThe last provider added for the service if any exists.\nOtherwise, it returns <tt>null</tt>.\n@throws IllegalArgumentException if serviceName is <tt>null</tt>"
] | [
"Add the given person to the photo. Optionally, send in co-ordinates\n\n@param photoId\n@param userId\n@param bounds\n@throws FlickrException",
"Returns the list of module dependencies regarding the provided filters\n\n@param moduleId String\n@param filters FiltersHolder\n@return List<Dependency>",
"Returns the object pointed by the result-type parameter \"parameters\"\n@param _invocation\n@return",
"Creates the save and exit button UI Component.\n@return the save and exit button.",
"If directory doesn't exists try to create it.\n\n@param directory given directory to check\n@throws ReportGenerationException if can't create specified directory",
"Given a method node, checks if we are calling a private method from an inner class.",
"Write a comma to the output stream if required.",
"Write the config to the writer.",
"Sets the site root.\n\n@param siteRoot the site root"
] |
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."
] | [
"Formats a double value.\n\n@param number numeric value\n@return Double instance",
"Writes the results of the processing to a CSV file.",
"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",
"Apply the matching client UUID for the request\n\n@param httpServletRequest\n@param history",
"Use this API to fetch all the ntpserver resources that are configured on netscaler.",
"Internal method used to locate an remove an item from a list Relations.\n\n@param relationList list of Relation instances\n@param targetTask target relationship task\n@param type target relationship type\n@param lag target relationship lag\n@return true if a relationship was removed",
"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",
"Create a discount curve from forwards given by a LIBORMonteCarloModel. If the model uses multiple curves, return its discount curve.\n\n@param forwardCurveName name of the forward curve.\n@param model Monte Carlo model providing the forwards.\n@param startTime time at which the curve starts, i.e. zero time for the curve\n@return a discount curve from forwards given by a LIBORMonteCarloModel.\n@throws CalculationException Thrown if the model failed to provide the forward rates.",
"Manually set the breaker to be reset and ready for use. This\nis only useful after a manual trip otherwise the breaker will\ntrip automatically again if the service is still unavailable.\nJust like a real breaker. WOOT!!!"
] |
protected List<I_CmsSearchConfigurationSortOption> getSortOptions() {
List<I_CmsSearchConfigurationSortOption> options = new LinkedList<I_CmsSearchConfigurationSortOption>();
try {
JSONArray sortOptions = m_configObject.getJSONArray(JSON_KEY_SORTOPTIONS);
for (int i = 0; i < sortOptions.length(); i++) {
I_CmsSearchConfigurationSortOption option = parseSortOption(sortOptions.getJSONObject(i));
if (option != null) {
options.add(option);
}
}
} catch (JSONException e) {
if (null == m_baseConfig) {
if (LOG.isInfoEnabled()) {
LOG.info(Messages.get().getBundle().key(Messages.LOG_NO_SORT_CONFIG_0), e);
}
} else {
options = m_baseConfig.getSortConfig().getSortOptions();
}
}
return options;
} | [
"Returns the list of the configured sort options, or the empty list if no sort options are configured.\n@return The list of the configured sort options, or the empty list if no sort options are configured."
] | [
"Unlocks a file.",
"Sets top and bottom padding for all cells in the row.\n@param padding new padding for top and bottom, ignored if smaller than 0\n@return this to allow chaining",
"Set the individual dates.\n@param dates the dates to set.",
"Returns all the dependencies taken into account the artifact of the module that will be removed from the dependencies\n\n@param module Module\n@param producedArtifacts List<String>\n@return Set<Dependency>",
"Lookup Seam integration resource loader.\n@return the Seam integration resource loader\n@throws DeploymentUnitProcessingException for any error",
"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",
"Returns all information related to a single texture.\n\n@param type the texture type\n@param index the index in the texture stack\n@return the texture information",
"remove the user profile with id from the db.",
"Collect environment variables and system properties under with filter constrains"
] |
private CmsSpellcheckingRequest parseJsonRequest(JSONObject jsonRequest) {
final String id = jsonRequest.optString(JSON_ID);
final JSONObject params = jsonRequest.optJSONObject(JSON_PARAMS);
if (null == params) {
LOG.debug("Invalid JSON request: No field \"params\" defined. ");
return null;
}
final JSONArray words = params.optJSONArray(JSON_WORDS);
final String lang = params.optString(JSON_LANG, LANG_DEFAULT);
if (null == words) {
LOG.debug("Invalid JSON request: No field \"words\" defined. ");
return null;
}
// Convert JSON array to array of type String
final List<String> wordsToCheck = new LinkedList<String>();
for (int i = 0; i < words.length(); i++) {
final String word = words.opt(i).toString();
wordsToCheck.add(word);
if (Character.isUpperCase(word.codePointAt(0))) {
wordsToCheck.add(word.toLowerCase());
}
}
return new CmsSpellcheckingRequest(wordsToCheck.toArray(new String[wordsToCheck.size()]), lang, id);
} | [
"Parse JSON parameters from this request.\n\n@param jsonRequest The request in the JSON format.\n@return CmsSpellcheckingRequest object that contains parsed parameters or null, if JSON input is not well\ndefined."
] | [
"Parse request parameters and files.\n@param request\n@param response",
"Gets axis dimension\n@param axis Axis. It might be either {@link Layout.Axis#X X} or\n{@link Layout.Axis#Y Y} or {@link Layout.Axis#Z Z}\n@return axis dimension",
"Sets the SCXML model with an InputStream\n\n@param inputFileStream the model input stream",
"Get the authentication info for this layer.\n\n@return authentication info.",
"Returns the Class object of the Event implementation.",
"This method writes project property data to a JSON file.",
"Returns the perma link for the current page based on the URI and detail content id stored in the CmsObject passed as a parameter.<p<\n\n@param cms the CMS context to use to generate the permalink\n\n@return the permalink",
"Adds a corporate groupId to an organization\n\n@param organizationId String\n@param corporateGroupId String",
"Adds an item to the list box, specifying its direction and an initial\nvalue 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 dir the item's direction\n@param text the text of the item to be added"
] |
public synchronized int put(byte[] src, int off, int len) {
if (available == capacity) {
return 0;
}
// limit is last index to put + 1
int limit = idxPut < idxGet ? idxGet : capacity;
int count = Math.min(limit - idxPut, len);
System.arraycopy(src, off, buffer, idxPut, count);
idxPut += count;
if (idxPut == capacity) {
// Array end reached, check if we have more
int count2 = Math.min(len - count, idxGet);
if (count2 > 0) {
System.arraycopy(src, off + count, buffer, 0, count2);
idxPut = count2;
count += count2;
} else {
idxPut = 0;
}
}
available += count;
return count;
} | [
"Puts as many of the given bytes as possible into this buffer.\n\n@return number of bytes actually put into this buffer (0 if the buffer is full)"
] | [
"Use this API to unset the properties of Interface resource.\nProperties that need to be unset are specified in args array.",
"Starts all streams.",
"Determines the number of elements that the query would return. Override this\nmethod if the size shall be determined in a specific way.\n\n@return The number of elements",
"Tests correctness. Try\nfrom=1000, to=10000\nfrom=200, to=1000\nfrom=16, to=1000\nfrom=1000, to=Integer.MAX_VALUE",
"checks if a bean has been seen before in the dependencyPath. If not, it\nresolves the InjectionPoints and adds the resolved beans to the set of\nbeans to be validated",
"Add an appliable dependency for this task item.\n\n@param appliable the appliable dependency.\n@return the key to be used as parameter to taskResult(string) method to retrieve updated dependency",
"Logs all the canidate elements so that the plugin knows which elements were the candidate\nelements.",
"Calculate the value of a CMS option using the Black-Scholes model for the swap rate together with\nthe Hunt-Kennedy convexity adjustment.\n\n@param forwardSwaprate The forward swap rate\n@param volatility Volatility of the log of the swap rate\n@param swapAnnuity The swap annuity\n@param optionMaturity The option maturity\n@param swapMaturity The swap maturity\n@param payoffUnit The payoff unit, e.g., the discount factor corresponding to the payment date\n@param optionStrike The option strike\n@return Value of the CMS option",
"returns an Array with an Objects PK VALUES\n@throws PersistenceBrokerException if there is an erros accessing o field values"
] |
public void scale(double v){
for(int i = 0; i < this.size(); i++){
this.get(i).scale(v);;
}
} | [
"Multiplies all positions with a factor v\n@param v Multiplication factor"
] | [
"Returns an identity matrix",
"Encodes the given source into an encoded String using the rules specified\nby the given component and with the given options.\n@param source the source string\n@param encoding the encoding of the source string\n@param type the URI component for the source\n@return the encoded URI\n@throws IllegalArgumentException when the given uri parameter is not a valid URI",
"Use this API to fetch authorizationpolicylabel_binding resource of given name .",
"Uses data from a bar to populate a task.\n\n@param row bar data\n@param task task to populate",
"Create a discount curve from forwards given by a LIBORMonteCarloModel. If the model uses multiple curves, return its discount curve.\n\n@param forwardCurveName name of the forward curve.\n@param model Monte Carlo model providing the forwards.\n@param startTime time at which the curve starts, i.e. zero time for the curve\n@return a discount curve from forwards given by a LIBORMonteCarloModel.\n@throws CalculationException Thrown if the model failed to provide the forward rates.",
"Handles incoming Serial Messages. Serial messages can either be messages\nthat are a response to our own requests, or the stick asking us information.\n@param incomingMessage the incoming message to process.",
"Wraps the specified object pool for connections as a DataSource.\n\n@param jcd the OJB connection descriptor for the pool to be wrapped\n@param connectionPool the connection pool to be wrapped\n@return a DataSource attached to the connection pool.\nConnections will be wrapped using DBCP PoolGuard, that will not allow\nunwrapping unless the \"accessToUnderlyingConnectionAllowed=true\" configuration\nis specified.",
"A slop is dead if the destination node or the store does not exist\nanymore on the cluster.\n\n@param slop\n@return",
"Resolves line alpha based on distance comparing to max distance.\nWhere alpha is close to 0 for maxDistance, and close to 1 to 0 distance.\n\n@param distance line length\n@param maxDistance max line length\n@return line alpha"
] |
public boolean getWorkModified(List<TimephasedWork> list)
{
boolean result = false;
for (TimephasedWork assignment : list)
{
result = assignment.getModified();
if (result)
{
break;
}
}
return result;
} | [
"Test the list of TimephasedWork instances to see\nif any of them have been modified.\n\n@param list list of TimephasedWork instances\n@return boolean flag"
] | [
"Append the bounding volume particle positions, times and velocities to the existing mesh\nbefore creating a new scene object with this mesh attached to it.\nAlso, append every created scene object and its creation time to corresponding array lists.\n\n@param particlePositions\n@param particleVelocities\n@param particleTimeStamps",
"Counts the coordinates stored in a single statement for the relevant\nproperty, if they are actually given and valid.\n\n@param statement\n@param itemDocument",
"Merge the given maps.\n\n<p>\nThe replied map is a view on the given two maps.\nIf a key exists in the two maps, the replied value is the value of the right operand.\n</p>\n\n<p>\nEven if the key of the right operand exists in the left operand, the value in the right operand is preferred.\n</p>\n\n<p>\nThe replied map is unmodifiable.\n</p>\n\n@param <K> type of the map keys.\n@param <V> type of the map values.\n@param left the left map.\n@param right the right map.\n@return a map with the merged contents from the two maps.\n@since 2.15",
"Use this API to clear configuration on netscaler.\n@param force clear confirmation without prompting.\n@param level clear config according to the level. eg: basic, extended, full\n@return status of the operation performed.\n@throws Exception Nitro exception is thrown.",
"This method writes data for an individual calendar to a PM XML file.\n\n@param mpxj ProjectCalander instance",
"Commit all changes if there are uncommitted changes.\n\n@param msg the commit message.\n@throws GitAPIException",
"Formats the value provided with the specified DateTimeFormat",
"will trigger workers to cancel then wait for it to report back.",
"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"
] |
public ResourceTransformerEntry resolveResourceTransformer(final PathAddress address, final PlaceholderResolver placeholderResolver) {
return resolveResourceTransformer(address.iterator(), null, placeholderResolver);
} | [
"Resolve a resource transformer for a given address.\n\n@param address the address\n@param placeholderResolver a placeholder resolver used to resolve children of a placeholder registration\n@return the resource transformer"
] | [
"Makes a CRFDatum by producing features and a label from input data at a\nspecific position, using the provided factory.\n\n@param info\nThe input data\n@param loc\nThe position to build a datum at\n@param featureFactory\nThe FeatureFactory to use to extract features\n@return The constructed CRFDatum",
"Log a warning for the resource at the provided address and the given attributes. The detail message is a default\n'Attributes are not understood in the target model version and this resource will need to be ignored on the target host.'\n\n@param address where warning occurred\n@param attributes attributes we are warning about",
"END ODO CHANGES",
"Alias accessor provided for JSON serialization only",
"Gets information about the device pin.\n@param fields the fields to retrieve.\n@return info about the device pin.",
"Parses a single query facet item with query and label.\n@param prefix path to the query facet item (with trailing '/').\n@return the query facet item.",
"Use this API to unset the properties of systemcollectionparam resource.\nProperties that need to be unset are specified in args array.",
"Close the open stream.\n\nClose the stream if it was opened before",
"Checks that sequence-name is only used with autoincrement='ojb'\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"
] |
@Override
public EditMode editMode() {
if(readInputrc) {
try {
return EditModeBuilder.builder().parseInputrc(new FileInputStream(inputrc())).create();
}
catch(FileNotFoundException e) {
return EditModeBuilder.builder(mode()).create();
}
}
else
return EditModeBuilder.builder(mode()).create();
} | [
"Get EditMode based on os and mode\n\n@return edit mode"
] | [
"Return the numeric distance value in degrees.\n\n@return the degrees",
"Handle interval change.\n@param event the change event.",
"Set the value of one or more fields based on the contents of a database row.\n\n@param map column to field map\n@param row database row\n@param container field container",
"Try to link the declaration with the importerService referenced by the ServiceReference,.\nreturn true if they have been link together, false otherwise.\n\n@param declaration The Declaration\n@param declarationBinderRef The ServiceReference<S> of S\n@return true if they have been link together, false otherwise.",
"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.",
"Reads a string of two byte characters from the input array.\nThis method assumes that the string finishes either at the\nend of the array, or when char zero is encountered.\nThe value starts at the position specified by the offset\nparameter.\n\n@param data byte array of data\n@param offset start point of unicode string\n@return string value",
"Use this API to delete dnsview of given name.",
"Get the real Object\n\n@param objectOrProxy\n@return Object",
"Use this API to fetch all the nsspparams resources that are configured on netscaler."
] |
public List<Dependency> getModuleDependencies(final String moduleName, final String moduleVersion, final Boolean fullRecursive, final Boolean corporate, final Boolean thirdParty) throws GrapesCommunicationException {
final Client client = getClient();
final WebResource resource = client.resource(serverURL).path(RequestUtils.getArtifactDependencies(moduleName, moduleVersion));
final ClientResponse response = resource.queryParam(ServerAPI.SCOPE_COMPILE_PARAM, "true")
.queryParam(ServerAPI.SCOPE_PROVIDED_PARAM, "true")
.queryParam(ServerAPI.SCOPE_RUNTIME_PARAM, "true")
.queryParam(ServerAPI.SCOPE_TEST_PARAM, "true")
.queryParam(ServerAPI.RECURSIVE_PARAM, fullRecursive.toString())
.queryParam(ServerAPI.SHOW_CORPORATE_PARAM, corporate.toString())
.queryParam(ServerAPI.SHOW_THIRPARTY_PARAM, thirdParty.toString())
.accept(MediaType.APPLICATION_JSON).get(ClientResponse.class);
client.destroy();
if(ClientResponse.Status.OK.getStatusCode() != response.getStatus()){
final String message = String.format(FAILED_TO_GET_MODULE, "get module ancestors ", moduleName, moduleVersion);
if(LOG.isErrorEnabled()) {
LOG.error(String.format(HTTP_STATUS_TEMPLATE_MSG, message, response.getStatus()));
}
throw new GrapesCommunicationException(message, response.getStatus());
}
return response.getEntity(new GenericType<List<Dependency>>(){});
} | [
"Return the list of module dependencies\n\n@param moduleName\n@param moduleVersion\n@param fullRecursive\n@param corporate\n@param thirdParty\n@return List<Dependency>\n@throws GrapesCommunicationException"
] | [
"Calculate the duration percent complete.\n\n@param row task data\n@return percent complete",
"Returns all the retention policies.\n@param api the API connection to be used by the resource.\n@param fields the fields to retrieve.\n@return an iterable with all the retention policies.",
"Returns the rank of the decomposed matrix.\n\n@see SingularOps_DDRM#rank(SingularValueDecomposition_F64, double)\n\n@return The matrix's rank",
"Check if new license pattern is valid and doesn't match any existing one\n@param newComer License being added or edited\n@throws WebApplicationException if conflicts involving the newComer are detected",
"Join a group as a public member.\n\nNote: if a group has rules - the client must display the rules to the user and the user must accept them prior to joining the group. The acceptRules\nparameter indicates that the user has accepted those rules.\n\n@param groupId\n- the id of the group to join\n@param acceptRules\n- if a group has rules, true indicates the user has accepted the rules\n\n@see <a href=\"http://www.flickr.com/services/api/flickr.groups.join.html\">flickr.groups.join</a>",
"Creates an endpoint reference by duplicating the endpoint reference of a given server.\n@param server\n@param address\n@param props\n@return",
"convert selector used in an upsert statement into a document",
"Initialize; cached threadpool is safe as it is releasing resources automatically if idle",
"Set new particle coordinates somewhere off screen and apply new direction towards the screen\n\n@param position the particle position to apply new values to"
] |
@Override
public boolean isPrefixBlock() {
Integer networkPrefixLength = getNetworkPrefixLength();
if(networkPrefixLength == null) {
return false;
}
if(getNetwork().getPrefixConfiguration().allPrefixedAddressesAreSubnets()) {
return true;
}
return containsPrefixBlock(networkPrefixLength);
} | [
"Returns whether this address section represents a subnet block of addresses associated its prefix length.\n\nReturns false if it has no prefix length, if it is a single address with a prefix length (ie not a subnet), or if it is a range of addresses that does not include\nthe entire subnet block for its prefix length.\n\nIf {@link AddressNetwork#getPrefixConfiguration} is set to consider all prefixes as subnets, this returns true for any grouping with prefix length.\n\n@return"
] | [
"Converts Observable of list to Observable of Inner.\n@param innerList list to be converted.\n@param <InnerT> type of inner.\n@return Observable for list of inner.",
"Adds a new role to the list of defined roles.\n\n@param roleName - The name of the role being added.",
"Returns all categories that are direct children of the current main category.\n\n@return all categories that are direct children of the current main category.",
"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",
"decides which icon to apply or hide this view\n\n@param imageHolder\n@param imageView\n@param iconColor\n@param tint",
"Use this API to fetch aaapreauthenticationpolicy_aaaglobal_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.",
"Load the available layers.\n\n@param image the installed image\n@param productConfig the product config to establish the identity\n@param moduleRoots the module roots\n@param bundleRoots the bundle roots\n@return the layers\n@throws IOException",
"Entry point with no system exit"
] |
public static void cleanIneligibleKeys(Map<ByteArray, Map<Value, Set<ClusterNode>>> keyVersionNodeSetMap,
int requiredWrite) {
Set<ByteArray> keysToDelete = new HashSet<ByteArray>();
for (Map.Entry<ByteArray, Map<Value, Set<ClusterNode>>> entry : keyVersionNodeSetMap.entrySet()) {
Set<Value> valuesToDelete = new HashSet<Value>();
ByteArray key = entry.getKey();
Map<Value, Set<ClusterNode>> valueNodeSetMap = entry.getValue();
// mark version for deletion if not enough writes
for (Map.Entry<Value, Set<ClusterNode>> versionNodeSetEntry : valueNodeSetMap.entrySet()) {
Set<ClusterNode> nodeSet = versionNodeSetEntry.getValue();
if (nodeSet.size() < requiredWrite) {
valuesToDelete.add(versionNodeSetEntry.getKey());
}
}
// delete versions
for (Value v : valuesToDelete) {
valueNodeSetMap.remove(v);
}
// mark key for deletion if no versions left
if (valueNodeSetMap.size() == 0) {
keysToDelete.add(key);
}
}
// delete keys
for (ByteArray k : keysToDelete) {
keyVersionNodeSetMap.remove(k);
}
} | [
"Determine if a key version is invalid by comparing the version's\nexistence and required writes configuration\n\n@param keyVersionNodeSetMap A map that contains keys mapping to a map\nthat maps versions to set of PrefixNodes\n@param requiredWrite Required Write configuration"
] | [
"Gets the file from which boot operations should be parsed.\n@return the file. Will not be {@code null}",
"Tells you if the expression is a null safe dereference.\n@param expression\nexpression\n@return\ntrue if is null safe dereference.",
"Checks if class package match provided list of action packages\n\n@param classPackageName\nname of class package\n@return true if class package is on the {@link #actionPackages} list",
"Handle click on \"Add\" button.\n@param e the click event.",
"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",
"TestNG returns a compound thread ID that includes the thread name and its numeric ID,\nseparated by an 'at' sign. We only want to use the thread name as the ID is mostly\nunimportant and it takes up too much space in the generated report.\n@param threadId The compound thread ID.\n@return The thread name.",
"Specifies the container object class to be instantiated\n\n@param containerObjectClass\ncontainer object class to be instantiated\n\n@return the current builder instance",
"Returns the list of nodes which match the expression xpathExpr in the String domStr.\n\n@return the list of nodes which match the query\n@throws XPathExpressionException\n@throws IOException",
"this method is basically checking whether we can return \"this\" for getNetworkSection"
] |
@GwtIncompatible("Class.getDeclaredFields")
public ToStringBuilder addDeclaredFields() {
Field[] fields = instance.getClass().getDeclaredFields();
for(Field field : fields) {
addField(field);
}
return this;
} | [
"Adds all fields declared directly in the object's class to the output\n@return this"
] | [
"Parses a single query facet item with query and label.\n@param prefix path to the query facet item (with trailing '/').\n@return the query facet item.",
"Picks out a File from `thriftFiles` corresponding to a given artifact ID\nand file name. Returns null if `artifactId` and `fileName` do not map to a\nthrift file path.\n\n@parameter artifactId The artifact ID of which to look up the path\n@parameter fileName the name of the thrift file for which to extract a path\n@parameter thriftFiles The set of Thrift files in which to lookup the\nartifact ID.\n@return The path of the directory containing Thrift files for the given\nartifact ID. null if artifact ID not found.",
"Uploads bytes to an open upload session.\n@param data data\n@param offset the byte position where the chunk begins in the file.\n@param partSize the part size returned as part of the upload session instance creation.\nOnly the last chunk can have a lesser value.\n@param totalSizeOfFile The total size of the file being uploaded.\n@return the part instance that contains the part id, offset and part size.",
"Retrieves the registar linked to the bus.\nCreates a new registar is not present.\n\n@param bus\n@return",
"Calculates all dates of the series.\n@return all dates of the series in milliseconds.",
"Get the value for a particular configuration property\n\n@param name - name of the property\n@return The first value encountered or null",
"Attaches an arbitrary object to this context.\n\n@param key they attachment key used to ensure uniqueness and used for retrieval of the value.\n@param value the value to store.\n@param <V> the value type of the attachment.\n\n@return the previous value associated with the key or {@code null} if there was no previous value.",
"Converts this address to a prefix length\n\n@return the prefix of the indicated IP type represented by this address or null if this address is valid but cannot be represented by a network prefix length\n@throws AddressStringException if the address is invalid",
"After obtaining a connection, perform additional tasks.\n@param handle\n@param statsObtainTime"
] |
public static Node addPartitionsToNode(final Node node, final Set<Integer> donatedPartitions) {
List<Integer> deepCopy = new ArrayList<Integer>(node.getPartitionIds());
deepCopy.addAll(donatedPartitions);
Collections.sort(deepCopy);
return updateNode(node, deepCopy);
} | [
"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"
] | [
"Retrieve a Double from an input stream.\n\n@param is input stream\n@return Double instance",
"Creates a color item that represents a color field found for a track based on a dbserver message.\n\n@param menuItem the rendered menu item containing the color metadata field\n\n@return the color metadata field",
"Computes eigenvalues only\n\n@return",
"returns a new segment masked by the given mask\n\nThis method applies the mask first to every address in the range, and it does not preserve any existing prefix.\nThe given prefix will be applied to the range of addresses after the mask.\nIf the combination of the two does not result in a contiguous range, then {@link IncompatibleAddressException} is thrown.",
"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 double value",
"Builds the resource.\n\n@return the cms resource",
"Prepare a parallel TCP Task.\n\n@param command\nthe command\n@return the parallel task builder",
"Adds to this set all of the elements in the specified members array\n@param members the members to add\n@return the number of members actually added",
"Helper method to create a string template source for a given formatter and content.\n\n@param formatter the formatter\n@param contentSupplier the content supplier\n\n@return the string template provider"
] |
public int getPrivacy() throws FlickrException {
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("method", METHOD_GET_PRIVACY);
Response response = transportAPI.get(transportAPI.getPath(), parameters, apiKey, sharedSecret);
if (response.isError()) {
throw new FlickrException(response.getErrorCode(), response.getErrorMessage());
}
Element personElement = response.getPayload();
return Integer.parseInt(personElement.getAttribute("privacy"));
} | [
"Returns the default privacy level preference for the user.\n\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@throws FlickrException\n@return privacyLevel"
] | [
"Returns the probability that the records v1 and v2 came from\nrepresent the same entity, based on high and low probability\nsettings etc.",
"Sets the left padding character for all cells in the row.\n@param paddingLeftChar new padding character, ignored if null\n@return this to allow chaining",
"Use this API to fetch crvserver_binding resource of given name .",
"Delivers the correct JSON Object for the Bounds\n\n@param bounds\n@throws org.json.JSONException",
"Find the the qualfied container port of the target service\nUses java annotations first or returns the container port.\n\n@param service\nThe target service.\n@param qualifiers\nThe set of qualifiers.\n\n@return Returns the resolved containerPort of '0' as a fallback.",
"Evict cached object\n\n@param key\nthe key indexed the cached object to be evicted",
"All the attributes needed either by the processors for each datasource row or by the jasper template.\n\n@param attributes the attributes.",
"Generate random time stamps from the current time upto the next one second.\nPassed as texture coordinates to the vertex shader; an unused field is present\nwith every pair passed.\n\n@param totalTime\n@return",
"Tests whether the ClassNode implements the specified method name\n\n@param classNode The ClassNode\n@param methodName The method name\n@param argTypes\n@return True if it implements the method"
] |
public static filterpolicy_csvserver_binding[] get(nitro_service service, String name) throws Exception{
filterpolicy_csvserver_binding obj = new filterpolicy_csvserver_binding();
obj.set_name(name);
filterpolicy_csvserver_binding response[] = (filterpolicy_csvserver_binding[]) obj.get_resources(service);
return response;
} | [
"Use this API to fetch filterpolicy_csvserver_binding resources of given name ."
] | [
"Arbitrarily resolve the inconsistency by choosing the first object if\nthere is one.\n\n@param values The list of objects\n@return A single value, if one exists, taken from the input list.",
"open a readable or writeable FileChannel\n\n@param file file object\n@param mutable writeable\n@return open the FileChannel\n@throws IOException any io exception",
"Wrapped version of standard jdbc executeUpdate Pays attention to DB\nlocked exception and waits up to 1s\n\n@param query SQL query to execute\n@throws Exception - will throw an exception if we can never get a lock",
"Checks to see if the matrix is symmetric to within tolerance.\n\n@param A Matrix being tested. Not modified.\n@param tol Tolerance that defines how similar two values must be to be considered identical\n@return true if symmetric or false if not",
"Set up the services to create a channel listener and operation handler service.\n@param serviceTarget the service target to install the services into\n@param endpointName the endpoint name to install the services into\n@param channelName the name of the channel\n@param executorServiceName service name of the executor service to use in the operation handler service\n@param scheduledExecutorServiceName service name of the scheduled executor service to use in the operation handler service",
"Support the subscript operator for GString.\n\n@param text a GString\n@param index the index of the Character to get\n@return the Character at the given index\n@since 2.3.7",
"Handles a key change.\n\n@param event the key change event.\n@param allLanguages <code>true</code> for changing the key for all languages, <code>false</code> if the key should be changed only for the current language.\n@return result, indicating if the key change was successful.",
"Gets the boxed type of a class\n\n@param type The type\n@return The boxed type",
"Assign FK value to all n-side objects referenced by given object.\n\n@param obj real object with 1:n reference\n@param cod {@link CollectionDescriptor} of referenced 1:n objects\n@param insert flag signal insert operation, false signals update operation"
] |
public Module getModule(final String name, final String version) throws GrapesCommunicationException {
final Client client = getClient();
final WebResource resource = client.resource(serverURL).path(RequestUtils.getModulePath(name, version));
final ClientResponse response = resource.accept(MediaType.APPLICATION_JSON).get(ClientResponse.class);
client.destroy();
if(ClientResponse.Status.OK.getStatusCode() != response.getStatus()){
final String message = String.format(FAILED_TO_GET_MODULE, "get module details", name, version);
if(LOG.isErrorEnabled()) {
LOG.error(String.format(HTTP_STATUS_TEMPLATE_MSG, message, response.getStatus()));
}
throw new GrapesCommunicationException(message, response.getStatus());
}
return response.getEntity(Module.class);
} | [
"Send a get module request\n\n@param name\n@param version\n@return the targeted module\n@throws GrapesCommunicationException"
] | [
"Create users for the given array of addresses. The passwords will be set to the email addresses.\n\n@param greenMail Greenmail instance to create users for\n@param addresses Addresses",
"Use this API to fetch statistics of scpolicy_stats resource of given name .",
"Use this API to fetch dnsview resources of given names .",
"Swap the current version folder for a new one\n\n@param newStoreDirectory The path to the new version directory",
"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",
"Get the values for a particular configuration property\n\n@param name - name of the property\n@return All values encountered or null",
"Walk project references recursively, building up a list of thrift files they provide, starting\nwith an empty file list.",
"Returns the list of user defined attribute names.\n\n@return the list of user defined attribute names, if there are none it returns an empty set.",
"Sets the node meta data but allows overwriting values.\n\n@param key - the meta data key\n@param value - the meta data value\n@return the old node meta data value for this key\n@throws GroovyBugError if key is null"
] |
public static String escapeDoubleQuotesForJson(String text) {
if ( text == null ) {
return null;
}
StringBuilder builder = new StringBuilder( text.length() );
for ( int i = 0; i < text.length(); i++ ) {
char c = text.charAt( i );
switch ( c ) {
case '"':
case '\\':
builder.append( "\\" );
default:
builder.append( c );
}
}
return builder.toString();
} | [
"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"
] | [
"Sets the upper limits for the \"moving\" body translation relative to joint point.\n\n@param limitX the X upper lower translation limit\n@param limitY the Y upper lower translation limit\n@param limitZ the Z upper lower translation limit",
"Release the rebalancing permit for a particular node id\n\n@param nodeId The node id whose permit we want to release",
"Disallow the job type from being executed.\n@param jobType the job type to disallow",
"Inserts a column name, value pair into the SQL.\n\n@param column\nName of the table column.\n@param value\nValue to substitute in. InsertBuilder does *no* interpretation\nof this. If you want a string constant inserted, you must\nprovide the single quotes and escape the internal quotes. It\nis more common to use a question mark or a token in the style\nof {@link ParameterizedPreparedStatementCreator}, e.g. \":foo\".",
"performs an INSERT operation against RDBMS.\n@param obj The Object to be inserted as a row of the underlying table.\n@param cld ClassDescriptor providing mapping information.",
"Enable a host\n\n@param hostName\n@throws Exception",
"Processes the most recent dump of the given type using the given dump\nprocessor.\n\n@see DumpProcessingController#processMostRecentMainDump()\n@see DumpProcessingController#processAllRecentRevisionDumps()\n\n@param dumpContentType\nthe type of dump to process\n@param dumpFileProcessor\nthe processor to use\n@deprecated Use {@link #getMostRecentDump(DumpContentType)} and\n{@link #processDump(MwDumpFile)} instead; method will vanish\nin WDTK 0.5",
"Returns Task field name of supplied code no.\n\n@param key - the code no of required Task field\n@return - field name",
"Clear the selection of all items.\n@param requestLayout request layout after clear selection if the flag is true, no layout\nrequested otherwise\n@return {@code true} if at least one item was deselected,\n{@code false} otherwise."
] |
public void cleanup() {
managers.clear();
for (BeanManagerImpl beanManager : beanDeploymentArchives.values()) {
beanManager.cleanup();
}
beanDeploymentArchives.clear();
deploymentServices.cleanup();
deploymentManager.cleanup();
instance.clear(contextId);
} | [
"Cause the container to be cleaned up, including all registered bean\nmanagers, and all deployment services"
] | [
"Function to perform forward softmax",
"Checks the preconditions for creating a new Truncate processor.\n\n@param maxSize\nthe maximum size of the String\n@param suffix\nthe String to append if the input is truncated (e.g. \"...\")\n@throws IllegalArgumentException\nif {@code maxSize <= 0}\n@throws NullPointerException\nif suffix is null",
"Tests correctness.",
"Use this API to fetch appfwsignatures resource of given name .",
"Boot the controller. Called during service start.\n\n@param context the boot context\n@throws ConfigurationPersistenceException\nif the configuration failed to be loaded",
"Retrieve the default mapping between MPXJ task fields and Primavera wbs field names.\n\n@return mapping",
"Create a new thread\n\n@param name The name of the thread\n@param runnable The work for the thread to do\n@param daemon Should the thread block JVM shutdown?\n@return The unstarted thread",
"Propagates node table of given DAG to all of it ancestors.",
"Converts a vector into a quaternion.\nUsed for the direction of spot and directional lights\nCalled upon initialization and updates to those vectors\n\n@param d"
] |
protected void processStop(Endpoint endpoint, EventTypeEnum eventType) {
if (!sendLifecycleEvent) {
return;
}
Event event = createEvent(endpoint, eventType);
monitoringServiceClient.putEvents(Collections.singletonList(event));
if (LOG.isLoggable(Level.INFO)) {
LOG.info("Send " + eventType + " event to SAM Server successful!");
}
} | [
"Process stop.\n\n@param endpoint the endpoint\n@param eventType the event type"
] | [
"Create the function. Be sure to handle all possible input types and combinations correctly and provide\nmeaningful error messages. The output matrix should be resized to fit the inputs.",
"Delete all backups asynchronously",
"Removes all children",
"END ODO CHANGES",
"Gets the global and adds it ot the BatchExecutionresults using the alternative outIdentifier.\n\n@param identifier\nThe identifier of the global\n@param outIdentifier\nThe identifier used in the ExecutionResults to store the global.\n@return",
"This method extracts data for a single calendar from a Planner file.\n\n@param plannerCalendar Calendar data\n@param parentMpxjCalendar parent of derived calendar",
"Converts a string representation of an integer into an Integer object.\nSilently ignores any parse exceptions and returns null.\n\n@param value String representation of an integer\n@return Integer instance",
"Read a Synchro string from an input stream.\n\n@param is input stream\n@return String instance",
"Removes a watermark from the item.\nIf the item did not have a watermark applied to it, a 404 Not Found will be returned by API.\n@param itemUrl url template for the item."
] |
public InsertIntoTable set(String name, Object value) {
builder.set(name, value);
return this;
} | [
"Set the given column name to the given value.\n\n@param name The column name to set.\n@param value the value to set.\n@return {@code this}\n@throws IllegalArgumentException if a column name does not exist in the table."
] | [
"Checks that the modified features exist.\n\n@param classDef The class 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",
"Find Flickr Places information by Place URL.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@deprecated This method has been deprecated. It won't be removed but you should use {@link PlacesInterface#getInfoByUrl(String)} instead.\n@param flickrPlacesUrl\n@return A Location\n@throws FlickrException",
"Extract data for a single predecessor.\n\n@param task parent task\n@param row Synchro predecessor data",
"Write objects to data store, but don't release the locks.\nI don't know what we should do if we are in a checkpoint and\nwe need to abort.",
"Process each regex group matched substring of the given CharSequence. If the closure\nparameter takes one argument, an array with all match groups is passed to it.\nIf the closure takes as many arguments as there are match groups, then each\nparameter will be one match group.\n\n@param self the source CharSequence\n@param regex a Regex CharSequence\n@param closure a closure with one parameter or as much parameters as groups\n@return the source CharSequence\n@see #eachMatch(String, String, groovy.lang.Closure)\n@since 1.8.2",
"Use this API to fetch all the nsspparams resources that are configured on netscaler.",
"Accessor method used to retrieve a String 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",
"Calculates the Black-Scholes option value of an atm call option.\n\n@param volatility The Black-Scholes volatility.\n@param optionMaturity The option maturity T.\n@param forward The forward, i.e., the expectation of the index under the measure associated with payoff unit.\n@param payoffUnit The payoff unit, i.e., the discount factor or the anuity associated with the payoff.\n@return Returns the value of a European at-the-money call option under the Black-Scholes model",
"Get all views from the list content\n@return list of views currently visible"
] |
public Photo getInfo(String photoId, String secret) throws FlickrException {
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("method", METHOD_GET_INFO);
parameters.put("photo_id", photoId);
if (secret != null) {
parameters.put("secret", secret);
}
Response response = transport.get(transport.getPath(), parameters, apiKey, sharedSecret);
if (response.isError()) {
throw new FlickrException(response.getErrorCode(), response.getErrorMessage());
}
Element photoElement = response.getPayload();
return PhotoUtils.createPhoto(photoElement);
} | [
"Get all info for the specified photo.\n\nThe calling user must have permission to view the photo.\n\nThis method does not require authentication.\n\n@param photoId\nThe photo Id\n@param secret\nThe optional secret String\n@return The Photo\n@throws FlickrException"
] | [
"Create an element that represents a horizntal or vertical line.\n@param x1\n@param y1\n@param x2\n@param y2\n@return the created DOM element",
"Process an MPP file to make it anonymous.\n\n@param input input file name\n@param output output file name\n@throws Exception",
"This method is called to alert project listeners to the fact that\na relation has been read from a project file.\n\n@param relation relation instance",
"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.",
"Ensure that the nodeList is either null or empty.\n\n@param nodeList the nodeList to ensure to be either null or empty\n@param expression the expression was used to fine the nodeList\n@throws SpinXPathException if the nodeList is either null or empty",
"This method extracts data for a single calendar from a Planner file.\n\n@param plannerCalendar Calendar data\n@param parentMpxjCalendar parent of derived calendar",
"We have reason to believe we might have enough information to calculate a signature for the track loaded on a\nplayer. Verify that, and if so, perform the computation and record and report the new signature.",
"Checks if the last argument matches the vararg type.\n@param params\n@param args\n@return -1 if no match, 0 if the last argument is exactly the vararg type and 1 if of an assignable type",
"Finds all the resource names contained in this file system folder.\n\n@param classPathRootOnDisk The location of the classpath root on disk, with a trailing slash.\n@param scanRootLocation The root location of the scan on the classpath, without leading or trailing slashes.\n@param folder The folder to look for resources under on disk.\n@return The resource names;"
] |
public static <T> void setBeanInstance(String contextId, T proxy, BeanInstance beanInstance, Bean<?> bean) {
if (proxy instanceof ProxyObject) {
ProxyObject proxyView = (ProxyObject) proxy;
proxyView.weld_setHandler(new ProxyMethodHandler(contextId, beanInstance, bean));
}
} | [
"Convenience method to set the underlying bean instance for a proxy.\n\n@param proxy the proxy instance\n@param beanInstance the instance of the bean"
] | [
"Calculates all dates of the series.\n@return all dates of the series in milliseconds.",
"Use this API to fetch all the auditmessages resources that are configured on netscaler.",
"Join the Collection of Strings using the specified delimiter.\n\n@param s\nThe String collection\n@param delimiter\nThe delimiter String\n@return The joined String",
"Gets the node meta data.\n\n@param key - the meta data key\n@return the node meta data value for this key",
"Specify the proxy and the authentication parameters to be used\nto establish the connections to Apple Servers.\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@param proxy the proxy object to be used to create connections\n@param proxyUsername a String object representing the username of the proxy server\n@param proxyPassword a String object representing the password of the proxy server\n@return this",
"Checks, if all values necessary for a specific pattern are valid.\n@return a flag, indicating if all values required for the pattern are valid.",
"Check if the path to the property correspond to an association.\n\n@param targetTypeName the name of the entity containing the property\n@param pathWithoutAlias the path to the property WITHOUT aliases\n@return {@code true} if the property is an association or {@code false} otherwise",
"Add tasks to the tree.\n\n@param parentNode parent tree node\n@param parent parent task container",
"Visits a parameter of this method.\n\n@param name\nparameter name or null if none is provided.\n@param access\nthe parameter's access flags, only <tt>ACC_FINAL</tt>,\n<tt>ACC_SYNTHETIC</tt> or/and <tt>ACC_MANDATED</tt> are\nallowed (see {@link Opcodes})."
] |
public static List<Versioned<byte[]>> pruneNonReplicaEntries(List<Versioned<byte[]>> vals,
List<Integer> keyReplicas,
MutableBoolean didPrune) {
List<Versioned<byte[]>> prunedVals = new ArrayList<Versioned<byte[]>>(vals.size());
for(Versioned<byte[]> val: vals) {
VectorClock clock = (VectorClock) val.getVersion();
List<ClockEntry> clockEntries = new ArrayList<ClockEntry>();
for(ClockEntry clockEntry: clock.getEntries()) {
if(keyReplicas.contains((int) clockEntry.getNodeId())) {
clockEntries.add(clockEntry);
} else {
didPrune.setValue(true);
}
}
prunedVals.add(new Versioned<byte[]>(val.getValue(),
new VectorClock(clockEntries, clock.getTimestamp())));
}
return prunedVals;
} | [
"Remove all non replica clock entries from the list of versioned values\nprovided\n\n@param vals list of versioned values to prune replicas from\n@param keyReplicas list of current replicas for the given key\n@param didPrune flag to mark if we did actually prune something\n@return pruned list"
] | [
"Extracts the service name from a Server.\n@param server\n@return",
"Return fallback if first string is null or empty",
"Returns the context the view is running in, through which it can\naccess the current theme, resources, etc.\n\n@return The view's Context.",
"Use this API to create sslfipskey.",
"Obtains a Accounting local date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Accounting local date-time, not null\n@throws DateTimeException if unable to create the date-time",
"Constructs a triangule Face from vertices v0, v1, and v2.\n\n@param v0\nfirst vertex\n@param v1\nsecond vertex\n@param v2\nthird vertex",
"Get the current attribute type.\n@param key the entry's key, not null\n@return the current attribute type, or null, if no such attribute exists.",
"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.",
"This method generates a list of lists. Each list represents the data\nfor an embedded object, and contains set set of RTFEmbeddedObject instances\nthat make up the embedded object. This method will return null\nif there are no embedded objects in the RTF document.\n\n@param text RTF document\n@return list of lists of RTFEmbeddedObject instances"
] |
protected boolean isMultimedia(File file) {
//noinspection SimplifiableIfStatement
if (isDir(file)) {
return false;
}
String path = file.getPath().toLowerCase();
for (String ext : MULTIMEDIA_EXTENSIONS) {
if (path.endsWith(ext)) {
return true;
}
}
return false;
} | [
"An extremely simple method for identifying multimedia. This\ncould be improved, but it's good enough for this example.\n\n@param file which could be an image or a video\n@return true if the file can be previewed, false otherwise"
] | [
"Adds the List of Lists of CRFDatums to the data and labels arrays, treating\neach datum as if it were its own document. Adds context labels in addition\nto the target label for each datum, meaning that for a particular document,\nthe number of labels will be windowSize-1 greater than the number of\ndatums.\n\n@param processedData\na List of Lists of CRFDatums",
"Use this API to fetch filtered set of appfwlearningsettings resources.\nset the filter parameter values in filtervalue object.",
"This method retrieves a byte array containing the data at the\ngiven offset in the block. If no data is found at the given offset\nthis method returns null.\n\n@param offset offset of required data\n@return byte array containing required data",
"Generate a schedule descriptor for the given start and end date.\n\n@param startDate The start date.\n@param endDate The end date.\n@return The schedule descriptor",
"Adds an additional statement to the constructed document.\n\n@param statement\nthe additional statement\n@return builder object to continue construction",
"High-accuracy Complementary normal distribution function.\n\n@param x Value.\n@return Result.",
"Reads next frame image.",
"Use this API to fetch the statistics of all nsacl6_stats resources that are configured on netscaler.",
"Reset the pool of resources for a specific destination. Idle resources\nwill be destroyed. Checked out resources that are subsequently checked in\nwill be destroyed. Newly created resources can be checked in to\nreestablish resources for the specific destination."
] |
private void performScriptedStep() {
double scale = computeBulgeScale();
if( steps > giveUpOnKnown ) {
// give up on the script
followScript = false;
} else {
// use previous singular value to step
double s = values[x2]/scale;
performImplicitSingleStep(scale,s*s,false);
}
} | [
"Shifts are performed based upon singular values computed previously. If it does not converge\nusing one of those singular values it uses a Wilkinson shift instead."
] | [
"Returns the single abstract method of a class node, if it is a SAM type, or null otherwise.\n@param type a type for which to search for a single abstract method\n@return the method node if type is a SAM type, null otherwise",
"Init the licenses cache\n\n@param licenses",
"Use this API to update cmpparameter.",
"Determine whether the user has followed bean-like naming convention or not.",
"Returns the compact project records for all projects in the team.\n\n@param team The team to find projects in.\n@return Request object",
"Set default values for annotations.\nInitial annotation take precedence over the default annotation when both annotation types are present\n\n@param defaultAnnotations default value for annotations",
"Creates the tables according to the schema files.\n\n@throws PlatformException If some error occurred",
"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",
"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."
] |
private List<String> parseRssFeedForeCast(String feed) {
String[] result = feed.split("<br />");
List<String> returnList = new ArrayList<String>();
String[] result2 = result[2].split("<BR />");
returnList.add(result2[3] + "\n");
returnList.add(result[3] + "\n");
returnList.add(result[4] + "\n");
returnList.add(result[5] + "\n");
returnList.add(result[6] + "\n");
return returnList;
} | [
"Parser for forecast\n\n@param feed\n@return"
] | [
"Determine the consistency level of a key\n\n@param versionNodeSetMap A map that maps version to set of PrefixNodes\n@param replicationFactor Total replication factor for the set of clusters\n@return ConsistencyLevel Enum",
"Map custom info.\n\n@param ciType the custom info type\n@return the map",
"Use this API to add cachepolicylabel.",
"Use this API to delete appfwlearningdata.",
"Use this API to enable Interface of given name.",
"Find the next match of the pattern on the tree\n\n@return whether there is a match somewhere in the tree",
"Use this API to add autoscaleprofile.",
"Creates the stats items.\n\n@param statsType\nthe stats type\n@return the sorted set\n@throws IOException\nSignals that an I/O exception has occurred.",
"Retrieve the parent task based on its WBS.\n\n@param wbs parent WBS\n@return parent task"
] |
public void callFunction(
final String name,
final List<?> args,
final @Nullable Long requestTimeout) {
this.functionService.callFunction(name, args, requestTimeout);
} | [
"Calls the specified Stitch function.\n\n@param name the name of the Stitch function to call.\n@param args the arguments to pass to the Stitch function.\n@param requestTimeout the number of milliseconds the client should wait for a response from the\nserver before failing with an error."
] | [
"Convert an MPXJ Duration instance into an integer duration in minutes\nready to be written to an MPX file.\n\n@param properties project properties, used for duration units conversion\n@param duration Duration instance\n@return integer duration in minutes",
"Adds api doc roots from a link. The folder reffered by the link should contain a package-list\nfile that will be parsed in order to add api doc roots to this configuration\n@param packageListUrl",
"Use this API to add vpnsessionaction.",
"This method returns the value it is passed, or null if the value\nmatches the nullValue argument.\n\n@param value value under test\n@param nullValue return null if value under test matches this value\n@return value or null",
"checks if the 2 triangles shares a segment\n@author Doron Ganel & Eyal Roth(2009)\n@param t2 - a second triangle\n@return boolean",
"Use this API to fetch vpnvserver_authenticationradiuspolicy_binding resources of given name .",
"Determines the field via reflection look-up.\n\n@param clazz The java class to search in\n@param fieldName The field's name\n@return The field object or <code>null</code> if no matching field was found",
"Convert the continuous values into discrete values by chopping up\nthe distribution into several equally-sized intervals.",
"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"
] |
protected int getRequestTypeFromString(String requestType) {
if ("GET".equals(requestType)) {
return REQUEST_TYPE_GET;
}
if ("POST".equals(requestType)) {
return REQUEST_TYPE_POST;
}
if ("PUT".equals(requestType)) {
return REQUEST_TYPE_PUT;
}
if ("DELETE".equals(requestType)) {
return REQUEST_TYPE_DELETE;
}
return REQUEST_TYPE_ALL;
} | [
"Convert a request type string to value\n\n@param requestType String value of request type GET/POST/PUT/DELETE\n@return Matching REQUEST_TYPE. Defaults to ALL"
] | [
"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",
"Reset a timer of the given string name for the given thread. If no such\ntimer exists yet, then it will be newly created.\n\n@param timerName\nthe name of the timer\n@param todoFlags\n@param threadId\nof the thread to track, or 0 if only system clock should be\ntracked",
"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.",
"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",
"Returns the corresponding module resolved service name for the given module.\n\nThe module resolved service is basically a latch that prevents the module from being loaded\nuntil all the transitive dependencies that it depends upon have have their module spec services\ncome up.\n\n@param identifier The module identifier\n@return The service name of the ModuleSpec service",
"flushes log queue, this actually writes combined log message into system log",
"Map the given region of the given file descriptor into memory.\nReturns a Pointer to the newly mapped memory throws an\nIOException on error.",
"Removes any configured observers.\n\n@deprecated since 1.1.0. Replaced by {@link #setObserverProvider(String)} and\n{@link #getObserverProvider()}",
"Handles logging tasks related to a failure to connect to a remote HC.\n@param uri the URI at which the connection attempt was made. Can be {@code null} indicating a failure to discover the HC\n@param discoveryOption the {@code DiscoveryOption} used to determine {@code uri}\n@param moreOptions {@code true} if there are more untried discovery options\n@param e the exception"
] |
static String tokenize(PageMetadata<?, ?> pageMetadata) {
try {
Gson g = getGsonWithKeyAdapter(pageMetadata.pageRequestParameters);
return new String(Base64.encodeBase64URLSafe(g.toJson(new PaginationToken
(pageMetadata)).getBytes("UTF-8")),
Charset.forName("UTF-8"));
} catch (UnsupportedEncodingException e) {
//all JVMs should support UTF-8
throw new RuntimeException(e);
}
} | [
"Generate an opaque pagination token from the supplied PageMetadata.\n\n@param pageMetadata page metadata of the page for which the token should be generated\n@return opaque pagination token"
] | [
"Sends a normal HTTP response containing the serialization information in\na XML format",
"Checks the component type of the given array against the expected component type.\n\n@param array\nthe array to be checked. May not be <code>null</code>.\n@param expectedComponentType\nthe expected component type of the array. May not be <code>null</code>.\n@return the unchanged array.\n@throws ArrayStoreException\nif the expected runtime {@code componentType} does not match the actual runtime component type.",
"Adds a directory to the collection of module paths.\n\n@param moduleDir the module directory to add\n\n@throws java.lang.IllegalArgumentException if the path is {@code null}",
"Use this API to update nsip6 resources.",
"Callback when each frame in the indicator animation should be drawn.",
"Use this API to fetch lbvserver_servicegroupmember_binding resources of given name .",
"Seeks to the given season within the given year\n\n@param seasonString\n@param yearString",
"Use this API to fetch ipset_nsip_binding resources of given name .",
"Calculates the Boundedness value to given confinement radius, diffusion coefficient, timlag and number of steps.\n@param D diffusion coefficient\n@param N Number of steps\n@param timelag Timelag\n@param confRadius Confinement radius\n@return Boundedness value"
] |
@Override
@SuppressWarnings("unchecked")
public ChronoZonedDateTime<DiscordianDate> zonedDateTime(TemporalAccessor temporal) {
return (ChronoZonedDateTime<DiscordianDate>) super.zonedDateTime(temporal);
} | [
"Obtains a Discordian zoned date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Discordian zoned date-time, not null\n@throws DateTimeException if unable to create the date-time"
] | [
"Creates a metadata cache archive file of all tracks in the specified slot on the specified player. Any\nprevious contents of the specified file will be replaced.\n\n@param slot the slot in which the media to be cached can be found\n@param playlistId the id of playlist to be cached, or 0 of all tracks should be cached\n@param cache the file into which the metadata cache should be written\n\n@throws Exception if there is a problem communicating with the player or writing the cache file.",
"Use this API to fetch statistics of servicegroup_stats resource of given name .",
"This method extracts data for a single calendar from a Phoenix file.\n\n@param calendar calendar data",
"This method merges together assignment data for the same cost.\n\n@param list assignment data",
"Returns the number of key-value mappings in this map for the second key.\n\n@param firstKey\nthe first key\n@return Returns the number of key-value mappings in this map for the second key.",
"Determine which daughter of the current parse tree is the head.\n\n@param t The parse tree to examine the daughters of.\nIf this is a leaf, <code>null</code> is returned\n@param parent The parent of t\n@return The daughter parse tree that is the head of <code>t</code>.\nReturns null for leaf nodes.\n@see Tree#percolateHeads(HeadFinder)\nfor a routine to call this and spread heads throughout a tree",
"Adds a leaf node, which could be a task or a milestone.\n\n@param parentName parent bar name\n@param row row to add\n@param task task to populate with data from the row",
"Provides the scrollableList implementation for page scrolling\n@return {@link LayoutScroller.ScrollableList} implementation, passed to {@link LayoutScroller}\nfor the processing the scrolling",
"Look-up the results data for a particular test class."
] |
public static base_response unset(nitro_service client, nstimeout resource, String[] args) throws Exception{
nstimeout unsetresource = new nstimeout();
return unsetresource.unset_resource(client,args);
} | [
"Use this API to unset the properties of nstimeout resource.\nProperties that need to be unset are specified in args array."
] | [
"Get the column name from the indirection table.\n@param mnAlias\n@param path",
"Returns the artifact available versions\n\n@param gavc String\n@return List<String>",
"Harvest any values that may have been returned during the execution\nof a procedure.\n\n@param proc the procedure descriptor that provides info about the procedure\nthat was invoked.\n@param obj the object that was persisted\n@param stmt the statement that was used to persist the object.\n\n@throws PersistenceBrokerSQLException if a problem occurs.",
"Get a property as a int or null.\n\n@param key the property name",
"Collect environment variables and system properties under with filter constrains",
"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",
"Use this API to fetch all the sslpolicylabel resources that are configured on netscaler.",
"Execute push docker image on agent\n\n@param launcher\n@param log\n@param imageTag\n@param username\n@param password\n@param host @return\n@throws IOException\n@throws InterruptedException",
"Adds the headers.\n\n@param builder\nthe builder\n@param headerMap\nthe header map"
] |
public final void draw() {
AffineTransform transform = new AffineTransform(this.transform);
transform.concatenate(getAlignmentTransform());
// draw the background box
this.graphics2d.setTransform(transform);
this.graphics2d.setColor(this.params.getBackgroundColor());
this.graphics2d.fillRect(0, 0, this.settings.getSize().width, this.settings.getSize().height);
//draw the labels
this.graphics2d.setColor(this.params.getFontColor());
drawLabels(transform, this.params.getOrientation(), this.params.getLabelRotation());
//sets the transformation for drawing the bar and do it
final AffineTransform lineTransform = new AffineTransform(transform);
setLineTranslate(lineTransform);
if (this.params.getOrientation() == Orientation.VERTICAL_LABELS_LEFT ||
this.params.getOrientation() == Orientation.VERTICAL_LABELS_RIGHT) {
final AffineTransform rotate = AffineTransform.getQuadrantRotateInstance(1);
lineTransform.concatenate(rotate);
}
this.graphics2d.setTransform(lineTransform);
this.graphics2d.setStroke(new BasicStroke(this.settings.getLineWidth()));
this.graphics2d.setColor(this.params.getColor());
drawBar();
} | [
"Start the rendering of the scalebar."
] | [
"Obtain newline-delimited headers from response\n\n@param response HttpServletResponse to scan\n@return newline-delimited headers",
"Retrieve a duration in the form required by Phoenix.\n\n@param duration Duration instance\n@return formatted duration",
"Construct a Libor index for a given curve and schedule.\n\n@param forwardCurveName\n@param schedule\n@return The Libor index or null, if forwardCurveName is null.",
"Returns whether this is a valid address string format.\n\nThe accepted IP address formats are:\nan IPv4 address, an IPv6 address, a network prefix alone, the address representing all addresses of all types, or an empty string.\nIf this method returns false, and you want more details, call validate() and examine the thrown exception.\n\n@return whether this is a valid address string format",
"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",
"Performs all actions that have been configured.",
"Go through all node IDs and determine which node\n\n@param cluster\n@param storeRoutingPlan\n@return",
"Gets the boxed type of a class\n\n@param type The type\n@return The boxed type",
"Obtains a local date in Julian 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 Julian local date, not null\n@throws DateTimeException if unable to create the date"
] |
public boolean merge(AbstractTransition another) {
if (!isCompatible(another)) {
return false;
}
if (another.mId != null) {
if (mId == null) {
mId = another.mId;
} else {
StringBuilder sb = new StringBuilder(mId.length() + another.mId.length());
sb.append(mId);
sb.append("_MERGED_");
sb.append(another.mId);
mId = sb.toString();
}
}
mUpdateStateAfterUpdateProgress |= another.mUpdateStateAfterUpdateProgress;
mSetupList.addAll(another.mSetupList);
Collections.sort(mSetupList, new Comparator<S>() {
@Override
public int compare(S lhs, S rhs) {
if (lhs instanceof AbstractTransitionBuilder && rhs instanceof AbstractTransitionBuilder) {
AbstractTransitionBuilder left = (AbstractTransitionBuilder) lhs;
AbstractTransitionBuilder right = (AbstractTransitionBuilder) rhs;
float startLeft = left.mReverse ? left.mEnd : left.mStart;
float startRight = right.mReverse ? right.mEnd : right.mStart;
return (int) ((startRight - startLeft) * 1000);
}
return 0;
}
});
return true;
} | [
"Merge another AbstractTransition's states into this object, such that the other AbstractTransition\ncan be discarded.\n\n@param another\n@return true if the merge is successful."
] | [
"Add a 'IS NULL' clause so the column must be null. '=' NULL does not work.",
"Returns the total count of the specified event\n@param event The event for which you want to get the total count\n@return Total count in int",
"Gets the default options to be passed when no custom properties are given.\n\n@return properties with formatter options",
"Initialize the fat client for the given store.\n\n1. Updates the coordinatorMetadata 2.Gets the new store configs from the\nconfig file 3.Creates a new @SocketStoreClientFactory 4. Subsequently\ncaches the @StoreClient obtained from the factory.\n\n\nThis is synchronized because if Coordinator Admin is already doing some\nchange we want the AsyncMetadataVersionManager to wait.\n\n@param storeName",
"Attempt to shutdown the server. As much shutdown as possible will be\ncompleted, even if intermediate errors are encountered.\n\n@throws VoldemortException",
"Create servlet deployment.\n\nCan be overridden with custom servlet deployment. e.g. exact resources listing in restricted env like GAE\n\n@param context the servlet context\n@param bootstrap the bootstrap\n@return new servlet deployment",
"Gets the Symmetric Chi-square divergence.\n\n@param p P vector.\n@param q Q vector.\n@return The Symmetric chi-square divergence between p and q.",
"Checks the day, month and year are equal.",
"Adds a column to this table definition.\n\n@param columnDef The new column"
] |
public static Set<String> listLinks(OperationContext context, PathAddress overlayAddress) {
Resource overlayResource = context.readResourceFromRoot(overlayAddress);
if (overlayResource.hasChildren(DEPLOYMENT)) {
return overlayResource.getChildrenNames(DEPLOYMENT);
}
return Collections.emptySet();
} | [
"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."
] | [
"Get the list of all nodes and the list of active nodes in the cluster.\n\n@return Membership object encapsulating lists of all nodes and the cluster nodes\n@see <a\nhref=\"https://console.bluemix.net/docs/services/Cloudant/api/advanced.html#-get-_membership-\">\n_membership</a>",
"Utility function that fetches user defined store definitions\n\n@param adminClient An instance of AdminClient points to given cluster\n@param nodeId Node id to fetch store definitions from\n@return The map container that maps store names to store definitions",
"Schedule at most one task.\n\nThe scheduled task *must* invoke 'doneTask()' upon\ncompletion/termination.\n\n@param executeService flag to control execution of the service, some tests pass\nin value 'false'\n@return The task scheduled or null if not possible to schedule a task at\nthis time.",
"Resize and return the image passing the new height and width\n\n@param height\n@param width\n@return",
"Sets the specified date 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",
"Schedule at most one task.\n\nThe scheduled task *must* invoke 'doneTask()' upon\ncompletion/termination.\n\n@param executeService flag to control execution of the service, some tests pass\nin value 'false'\n@return The task scheduled or null if not possible to schedule a task at\nthis time.",
"Use this API to fetch all the appfwprofile resources that are configured on netscaler.",
"Returns a product regarding its name\n\n@param name String\n@return DbProduct",
"Sets the body of this request to a given JSON string.\n@param body the JSON string to use as the body."
] |
public static <T> List<T> flatten(Collection<List<T>> nestedList) {
List<T> result = new ArrayList<T>();
for (List<T> list : nestedList) {
result.addAll(list);
}
return result;
} | [
"combines all the lists in a collection to a single list"
] | [
"Return the entity of a resource\n\n@param resource the resource\n@param <T> the type of the resource's entity\n@param <R> the resource type\n@return the resource's entity",
"Sets the ProjectCalendar instance from which this calendar is derived.\n\n@param calendar base calendar instance",
"Adds a user defined field value to a task.\n\n@param fieldType field type\n@param container FieldContainer instance\n@param row UDF data",
"Use this API to fetch filtered set of sslglobal_sslpolicy_binding resources.\nset the filter parameter values in filtervalue object.",
"Read all of the fields information from the configuration file.",
"Retrieves state and metrics information for all channels on individual connection.\n@param connectionName the connection name to retrieve channels\n@return list of channels on the connection",
"Deletes the concrete representation of the specified object in the underlying\npersistence system. This method is intended for use in top-level api or\nby internal calls.\n\n@param obj The object to delete.\n@param ignoreReferences With this flag the automatic deletion/unlinking\nof references can be suppressed (independent of the used auto-delete setting in metadata),\nexcept {@link org.apache.ojb.broker.metadata.SuperReferenceDescriptor}\nthese kind of reference (descriptor) will always be performed. If <em>true</em>\nall \"normal\" referenced objects will be ignored, only the specified object is handled.\n@throws PersistenceBrokerException",
"Use this API to fetch lbvserver_filterpolicy_binding resources of given name .",
"This method extracts project properties from a GanttProject file.\n\n@param ganttProject GanttProject file"
] |
public List<BoxTaskAssignment.Info> getAssignments() {
URL url = GET_ASSIGNMENTS_URL_TEMPLATE.build(this.getAPI().getBaseURL(), this.getID());
BoxAPIRequest request = new BoxAPIRequest(this.getAPI(), url, "GET");
BoxJSONResponse response = (BoxJSONResponse) request.send();
JsonObject responseJSON = JsonObject.readFrom(response.getJSON());
int totalCount = responseJSON.get("total_count").asInt();
List<BoxTaskAssignment.Info> assignments = new ArrayList<BoxTaskAssignment.Info>(totalCount);
JsonArray entries = responseJSON.get("entries").asArray();
for (JsonValue value : entries) {
JsonObject assignmentJSON = value.asObject();
BoxTaskAssignment assignment = new BoxTaskAssignment(this.getAPI(), assignmentJSON.get("id").asString());
BoxTaskAssignment.Info info = assignment.new Info(assignmentJSON);
assignments.add(info);
}
return assignments;
} | [
"Gets any assignments for this task.\n@return a list of assignments for this task."
] | [
"This method extracts data for a normal working day from an MSPDI file.\n\n@param calendar Calendar data\n@param weekDay Day data",
"Indicates that all of the packages within an archive are \"known\" by the package mapper. Generally\nthis indicates that the archive does not contain customer code.",
"The token was previously determined as potentially to-be-splitted thus we\nemit additional indentation or dedenting tokens.",
"Return a long value which is the number of rows in the table.",
"This method calculates the total amount of working time in a single\nday, which intersects with the supplied time range.\n\n@param hours collection of working hours in a day\n@param startDate time range start\n@param endDate time range end\n@return length of time in milliseconds",
"low level http operations",
"Synchronize the scroll positions of the scrollbars with the actual scroll\nposition of the content.",
"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.",
"Returns the compact records for all teams in the organization visible to\nthe authorized user.\n\n@param organization Globally unique identifier for the workspace or organization.\n@return Request object"
] |
public PromotionEvaluationReport getModulePromotionReport(final String name, final String version) throws GrapesCommunicationException {
return getModulePromotionReportRaw(name, version, false, PromotionEvaluationReport.class);
} | [
"Check if a module can be promoted in the Grapes server\n\n@param name\n@param version\n@return a boolean which is true only if the module can be promoted\n@throws GrapesCommunicationException"
] | [
"Unlinks a set of dependents from this task.\n\n@param task The task to remove dependents from.\n@return Request object",
"Gets a list of any comments on this file.\n\n@return a list of comments on this file.",
"binds the Identities Primary key values to the statement",
"Adds the parent package to the java.protocol.handler.pkgs system property.",
"Returns the index of the eigenvalue which has the largest magnitude.\n\n@return index of the largest magnitude eigen value.",
"Add a content modification.\n\n@param modification the content modification",
"Calculate the value of a CMS strike using the Black-Scholes model for the swap rate together with\nthe Hunt-Kennedy convexity adjustment.\n\n@param forwardSwaprate The forward swap rate\n@param volatility Volatility of the log of the swap rate\n@param swapAnnuity The swap annuity\n@param optionMaturity The option maturity\n@param swapMaturity The swap maturity\n@param payoffUnit The payoff unit, e.g., the discount factor corresponding to the payment date\n@param optionStrike The option strike\n@return Value of the CMS strike",
"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.",
"Check if the given class represents an array of primitives,\ni.e. boolean, byte, char, short, int, long, float, or double.\n@param clazz the class to check\n@return whether the given class is a primitive array class"
] |
public static nstrafficdomain_bridgegroup_binding[] get(nitro_service service, Long td) throws Exception{
nstrafficdomain_bridgegroup_binding obj = new nstrafficdomain_bridgegroup_binding();
obj.set_td(td);
nstrafficdomain_bridgegroup_binding response[] = (nstrafficdomain_bridgegroup_binding[]) obj.get_resources(service);
return response;
} | [
"Use this API to fetch nstrafficdomain_bridgegroup_binding resources of given name ."
] | [
"Delete an object from the database.",
"Internal function that uses recursion to create the list",
"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.",
"This method retrieves the UID for a calendar associated with a task.\n\n@param mpx MPX Task instance\n@return calendar UID",
"BuildInteractiveObjectFromAnchor is a special type of interactive object in that it does not get\nbuilt using ROUTE's.\n\n@param anchorSensor is the Sensor that describes the sensor set to an Anchor\n@param anchorDestination is either another Viewpoint, url to a web site or another x3d scene",
"Log table contents.\n\n@param label label text\n@param klass reader class name\n@param map table data",
"B tensor is ignored for CUDNN_OP_TENSOR_SQRT, CUDNN_OP_TENSOR_NOT.",
"Get list of replies\n\n@param topicId\nUnique identifier of a topic for a given group {@link Topic}.\n@return A reply object\n@throws FlickrException\n@see <a href=\"http://www.flickr.com/services/api/flickr.groups.discuss.replies.getList.html\">API Documentation</a>",
"the transaction id are generated as unique timestamps\n\n@param timeMs in milliseconds\n@return a unique transactionId"
] |
public static long wrapped(DMatrixRMaj a , DMatrixRMaj b , DMatrixRMaj c )
{
long timeBefore = System.currentTimeMillis();
double valA;
int indexCbase= 0;
int endOfKLoop = b.numRows*b.numCols;
for( int i = 0; i < a.numRows; i++ ) {
int indexA = i*a.numCols;
// need to assign dataC to a value initially
int indexB = 0;
int indexC = indexCbase;
int end = indexB + b.numCols;
valA = a.get(indexA++);
while( indexB < end ) {
c.set( indexC++ , valA*b.get(indexB++));
}
// now add to it
while( indexB != endOfKLoop ) { // k loop
indexC = indexCbase;
end = indexB + b.numCols;
valA = a.get(indexA++);
while( indexB < end ) { // j loop
c.plus( indexC++ , valA*b.get(indexB++));
}
}
indexCbase += c.numCols;
}
return System.currentTimeMillis() - timeBefore;
} | [
"Wrapper functions with no bounds checking are used to access matrix internals"
] | [
"Read a text stream into a single string.\n\n@param inputStream\nStream containing text. Will be closed on exit.\n@return The contents, or null on error.",
"Helper function to return the minimum size of the index space to be passed to the reduction given the input and\noutput tensors",
"Retains only beans which are enabled.\n\n@param beans The mutable set of beans to filter\n@param beanManager The bean manager\n@return a mutable set of enabled beans",
"This method extracts project properties from a Phoenix file.\n\n@param phoenixSettings Phoenix settings\n@param storepoint Current storepoint",
"Convert the holiday format from EquivalenceClassTransformer into a date format\n\n@param holiday the date\n@return a date String in the format yyyy-MM-dd",
"Returns a short class name for an object.\nThis is the class name stripped of any package name.\n\n@return The name of the class minus a package name, for example\n<code>ArrayList</code>",
"Assign float value within allowed range of [0,infinity) to initializeOnly SFFloat field named spacing.\n@param newValue",
"Use this API to unset the properties of gslbsite resources.\nProperties that need to be unset are specified in args array.",
"Resizes an image to the specified height, changing width in the same proportion\n@param originalImage Image in memory\n@param heightOut The height to resize\n@return New Image in memory"
] |
public void addSource(GVRAudioSource audioSource)
{
synchronized (mAudioSources)
{
if (!mAudioSources.contains(audioSource))
{
audioSource.setListener(this);
mAudioSources.add(audioSource);
}
}
} | [
"Adds an audio source to the audio manager.\nAn audio source cannot be played unless it is\nadded to the audio manager. A source cannot be\nadded twice.\n@param audioSource audio source to add"
] | [
"Converts a string representation of an integer into an Integer object.\nSilently ignores any parse exceptions and returns null.\n\n@param value String representation of an integer\n@return Integer instance",
"Process a single criteria block.\n\n@param list parent criteria list\n@param block current block",
"Method used as dynamical parameter converter",
"Process the graphical indicator criteria for a single column.\n\n@param type field type\n@return indicator criteria data",
"Resets the calendar",
"Creates a new instance from the given configuration file.\n\n@throws IOException if failed to load the configuration from the specified file",
"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",
"Converts a batch indexing into the sample, to a batch indexing into the\noriginal function.\n\n@param batch The batch indexing into the sample.\n@return A new batch indexing into the original function, containing only\nthe indices from the sample.",
"Generate a schedule descriptor for the given start and end date.\n\n@param startDate The start date.\n@param endDate The end date.\n@return The schedule descriptor"
] |
public History[] refreshHistory(int limit, int offset) throws Exception {
BasicNameValuePair[] params = {
new BasicNameValuePair("limit", String.valueOf(limit)),
new BasicNameValuePair("offset", String.valueOf(offset))
};
return constructHistory(params);
} | [
"refresh the most recent history entries\n\n@param limit number of entries to populate\n@param offset number of most recent entries to skip\n@return populated history entries\n@throws Exception exception"
] | [
"Generates the cache key for Online links.\n@param cms the current CmsObject\n@param targetSiteRoot the target site root\n@param detailPagePart the detail page part\n@param absoluteLink the absolute (site-relative) link to the resource\n@return the cache key",
"Returns PatternParser used to parse the conversion string. Subclasses may\noverride this to return a subclass of PatternParser which recognize\ncustom conversion characters.\n\n@since 0.9.0",
"When we execute a single statement we only need the corresponding Row with the result.\n\n@param results a list of {@link StatementResult}\n@return the result of a single query",
"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.",
"Set the repeat count of an override at ordinal index\n\n@param pathName Path name\n@param methodName Fully qualified method name\n@param ordinal 1-based index of the override within the overrides of type methodName\n@param repeatCount new repeat count to set\n@return true if success, false otherwise",
"Returns an empty Promotion details in Json\n\n@return String\n@throws IOException",
"If a custom CSS file has been specified, returns the path. Otherwise\nreturns null.\n@return A {@link File} pointing to the stylesheet, or null if no stylesheet\nis specified.",
"Translate the each ByteArray in an iterable into a hexadecimal string\n\n@param arrays The array of bytes to translate\n@return An iterable of converted strings",
"Use this API to add gslbsite."
] |
public void appointTempoMaster(int deviceNumber) throws IOException {
final DeviceUpdate update = getLatestStatusFor(deviceNumber);
if (update == null) {
throw new IllegalArgumentException("Device " + deviceNumber + " not found on network.");
}
appointTempoMaster(update);
} | [
"Tell a device to become tempo master.\n\n@param deviceNumber the device we want to take over the role of tempo master\n\n@throws IOException if there is a problem sending the command to the device\n@throws IllegalStateException if the {@code VirtualCdj} is not active\n@throws IllegalArgumentException if {@code deviceNumber} is not found on the network"
] | [
"Adds a basic LHS OPERATOR RHS block.\n\n@param list parent criteria list\n@param block current block",
"Delivers the correct JSON Object for outgoings\n\n@param outgoings\n@throws org.json.JSONException",
"Utility function that fetches quota types.",
"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",
"Gets the value of the callout property.\n\n<p>\nThis accessor method returns a reference to the live list,\nnot a snapshot. Therefore any modification you make to the\nreturned list will be present inside the JAXB object.\nThis is why there is not a <CODE>set</CODE> method for the callout property.\n\n<p>\nFor example, to add a new item, do as follows:\n<pre>\ngetCallout().add(newItem);\n</pre>\n\n\n<p>\nObjects of the following type(s) are allowed in the list\n{@link Callouts.Callout }",
"Build a URL with Query String and URL Parameters.\n@param base base URL\n@param queryString query string\n@param values URL Parameters\n@return URL",
"Print a work group.\n\n@param value WorkGroup instance\n@return work group value",
"Find the current active layout.\n\n@param phoenixProject phoenix project data\n@return current active layout",
"Checks if class is on class path\n@param className of the class to check.\n@return true if class in on class path, false otherwise."
] |
public InsertIntoTable addRowsFromDelimited(File file, String delimiter, Object nullValue) {
builder.addRowsFromDelimited(file, delimiter, nullValue);
return this;
} | [
"Adds all rows from the TSV file specified, using the provided delimiter and null value.\n\n@param file The file to read the data from.\n@param delimiter A column delimiter.\n@param nullValue Value to be treated as null in the source data.\n@return {@code this}"
] | [
"Returns an ArrayList of String URLs of the Carousel Images\n@return ArrayList of Strings",
"Invoke to find all services for given service type using specified class loader\n\n@param classLoader specified class loader\n@param serviceType given service type\n@return List of found services",
"Read a single resource assignment.\n\n@param resource MPXJ resource\n@param assignment Phoenix assignment",
"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.",
"end class SAXErrorHandler",
"If the resource has ordered child types, those child types will be stored in the attachment. If there are no\nordered child types, this method is a no-op.\n\n@param resourceAddress the address of the resource\n@param resource the resource which may or may not have ordered children.",
"Calculate the layout offset",
"Set the degrees of rotation. Value will be set to -1, if not available.\n\n@param rotation",
"Convert an Object to a Time."
] |
public void setAlias(UserAlias userAlias)
{
m_alias = userAlias.getName();
// propagate to SelectionCriteria,not to Criteria
for (int i = 0; i < m_criteria.size(); i++)
{
if (!(m_criteria.elementAt(i) instanceof Criteria))
{
((SelectionCriteria) m_criteria.elementAt(i)).setAlias(userAlias);
}
}
} | [
"Sets the alias using a userAlias object.\n@param userAlias The alias to set"
] | [
"Get the value of a primitive type from the request data.\n\n@param fieldName the name of the attribute to get from the request data.\n@param pAtt the primitive attribute.\n@param requestData the data to retrieve the value from.",
"Get the Json Schema of the input path, assuming the path contains just one\nschema version in all files under that path.",
"Restores a trashed folder to a new location with a new name.\n@param folderID the ID of the trashed folder.\n@param newName an optional new name to give the folder. This can be null to use the folder's original name.\n@param newParentID an optional new parent ID for the folder. This can be null to use the folder's original\nparent.\n@return info about the restored folder.",
"Removes a filter from this project file.\n\n@param filterName The name of the filter",
"Get a collection of public photos for the specified user ID.\n\nThis method does not require authentication.\n\n@see com.flickr4java.flickr.photos.Extras\n@param userId\nThe User ID\n@param extras\nSet of extra-attributes to include (may be null)\n@param perPage\nThe number of photos per page\n@param page\nThe page offset\n@return The PhotoList collection\n@throws FlickrException",
"Use this API to fetch cachepolicylabel resource of given name .",
"Returns the first product found in the vector of calibration products\nwhich matches the given symbol, where symbol is the String set in\nthe calibrationSpecs.\n\n@param symbol A given symbol string.\n@return The product associated with that symbol.",
"Start pushing the element off to the right.",
"we need to cache the address in here and not in the address section if there is a zone"
] |
public static String strMapToStr(Map<String, String> map) {
StringBuilder sb = new StringBuilder();
if (map == null || map.isEmpty())
return sb.toString();
for (Entry<String, String> entry : map.entrySet()) {
sb.append("< " + entry.getKey() + ", " + entry.getValue() + "> ");
}
return sb.toString();
} | [
"Str map to str.\n\n@param map\nthe map\n@return the string"
] | [
"Obtains a Julian zoned date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Julian zoned date-time, not null\n@throws DateTimeException if unable to create the date-time",
"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",
"Makes object obj persistent in the underlying persistence system.\nE.G. by INSERT INTO ... or UPDATE ... in an RDBMS.\nThe ObjectModification parameter can be used to determine whether INSERT or update is to be used.\nThis functionality is typically called from transaction managers, that\ntrack which objects have to be stored. If the object is an unmaterialized\nproxy the method return immediately.",
"Use this API to delete sslcertkey.",
"Use this API to fetch all the nssimpleacl resources that are configured on netscaler.",
"Use this API to fetch a aaaglobal_binding resource .",
"Ask the specified player for the specified artwork from the specified media slot, first checking if we have a\ncached copy.\n\n@param artReference uniquely identifies the desired artwork\n@param trackType the kind of track that owns the artwork\n\n@return the artwork, if it was found, or {@code null}\n\n@throws IllegalStateException if the ArtFinder is not running",
"Assign target number of partitions per node to specific node IDs. Then,\nseparates Nodes into donorNodes and stealerNodes based on whether the\nnode needs to donate or steal primary partitions.\n\n@param nextCandidateCluster\n@param numPartitionsPerNodePerZone\n@return a Pair. First element is donorNodes, second element is\nstealerNodes. Each element in the pair is a HashMap of Node to\nInteger where the integer value is the number of partitions to\nstore.",
"When using a map rotation, there might be tiles that are outside the rotated map area. To avoid to load\nthese tiles, this method checks if a tile is really required to draw the map."
] |
private String validatePattern() {
String error = null;
switch (getPatternType()) {
case DAILY:
error = isEveryWorkingDay() ? null : validateInterval();
break;
case WEEKLY:
error = validateInterval();
if (null == error) {
error = validateWeekDaySet();
}
break;
case MONTHLY:
error = validateInterval();
if (null == error) {
error = validateMonthSet();
if (null == error) {
error = isWeekDaySet() ? validateWeekOfMonthSet() : validateDayOfMonth();
}
}
break;
case YEARLY:
error = isWeekDaySet() ? validateWeekOfMonthSet() : validateDayOfMonth();
break;
case INDIVIDUAL:
case NONE:
default:
}
return error;
} | [
"Check, if all values used for calculating the series for a specific pattern are valid.\n@return <code>null</code> if the pattern is valid, a suitable error message otherwise."
] | [
"Creates a statement with parameters that should work with most RDBMS.",
"Modifies the specified mode and length arrays to combine adjacent modes of the same type, returning the updated index point.",
"Use this API to fetch all the pqbinding resources that are configured on netscaler.\nThis uses pqbinding_args which is a way to provide additional arguments while fetching the resources.",
"Make superclasses method protected??",
"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.",
"helper to calculate the actionBar height\n\n@param context\n@return",
"Retrieve the fixed data offset for a specific field.\n\n@param type field type\n@return offset",
"This is a generic function for retrieving any config value. The returned value\nis the one the server is operating with, no matter whether it comes from defaults\nor from the user-supplied configuration.\n\nThis function only provides access to configs which are deemed safe to share\npublicly (i.e.: not security-related configs). The list of configs which are\nconsidered off-limit can itself be configured via '{@value #RESTRICTED_CONFIGS}'.\n\n@param key config key for which to retrieve the value.\n@return the value for the requested config key, in String format.\nMay return null if the key exists and its value is explicitly set to null.\n@throws UndefinedPropertyException if the requested key does not exist in the config.\n@throws ConfigurationException if the requested key is not publicly available.",
"Generates a comment regarding the parameters.\n\n@param entityId - id of the commented entity\n@param entityType - type of the entity\n@param action - the action performed by the user\n@param commentedText - comment text\n@param user - comment left by\n@param date - date comment was created\n@return - comment entity"
] |
@Override
public Scenario<GIVEN, WHEN, THEN> startScenario( String description ) {
super.startScenario( description );
return this;
} | [
"Describes the scenario. Must be called before any step invocation.\n@param description the description\n@return this for a fluent interface"
] | [
"Checks if a given number is in the range of a float.\n\n@param number\na number which should be in the range of a float (positive or negative)\n\n@see java.lang.Float#MIN_VALUE\n@see java.lang.Float#MAX_VALUE\n\n@return number as a float",
"Create and return a new Violation for this rule and the specified import\n@param sourceCode - the SourceCode\n@param importNode - the ImportNode for the import triggering the violation\n@return a new Violation object",
"Retrieve a child record by name.\n\n@param key child record name\n@return child record",
"Calls the stored procedure stored procedure throws an\nerror if it doesn't exist.\n@param broker\n@param cld\n@param sequenceName\n@return\n@throws LookupException\n@throws SQLException",
"Map from an activity code value UUID to the actual value itself, and its\nsequence number.\n\n@param storepoint storepoint containing current project data",
"Deals with the case where we have had to map a task ID to a new value.\n\n@param id task ID from database\n@return mapped task ID",
"Retrieve the value from the REST request body.\n\nTODO: REST-Server value cannot be null ( null/empty string ?)",
"We have obtained metadata for a device, so store it and alert any listeners.\n\n@param update the update which caused us to retrieve this metadata\n@param data the metadata which we received",
"Returns a UTMDetail object which consists of UTM parameters like source, medium & campaign\n@return The {@link UTMDetail} object"
] |
public static sslservice get(nitro_service service, String servicename) throws Exception{
sslservice obj = new sslservice();
obj.set_servicename(servicename);
sslservice response = (sslservice) obj.get_resource(service);
return response;
} | [
"Use this API to fetch sslservice resource of given name ."
] | [
"Add a new PropertyChangeListener to this node for a specific property.\nThis functionality has\nbeen borrowed from the java.beans package, though this class has\nnothing to do with a bean",
"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",
"Creates a style definition used for the body element.\n@return The body style definition.",
"Writes triples to determine the statements with the highest rank.",
"Bessel function of the first kind, of order 0.\n\n@param x Value.\n@return I0 value.",
"Parses command line arguments.\n\n@param args\nArray of arguments, like the ones provided by\n{@code void main(String[] args)}\n@param objs\nOne or more objects with annotated public fields.\n@return A {@code List} containing all unparsed arguments (i.e. arguments\nthat are no switches)\n@throws IOException\nif a parsing error occurred.\n@see CmdArgument",
"Read the metadata from a hadoop SequenceFile\n\n@param fs The filesystem to read from\n@param path The file to read from\n@return The metadata from this file",
"Create constant name.\n@param state STATE_UNCHANGED, STATE_CHANGED, STATE_NEW or STATE_DELETED.\n@return cconstanname as String",
"Inserts a child task prior to a given sibling task.\n\n@param child new child task\n@param previousSibling sibling task"
] |
private boolean isNullOrEmpty(Object paramValue) {
boolean isNullOrEmpty = false;
if (paramValue == null) {
isNullOrEmpty = true;
}
if (paramValue instanceof String) {
if (((String) paramValue).trim().equalsIgnoreCase("")) {
isNullOrEmpty = true;
}
} else if (paramValue instanceof List) {
return ((List) paramValue).isEmpty();
}
return isNullOrEmpty;
} | [
"Checks String to see if the parameter is null.\n@param paramValue Object that will be checked if null.\n@return this.true if the parameter that is being checked is not null"
] | [
"Get list of replies\n\n@param topicId\nUnique identifier of a topic for a given group {@link Topic}.\n@return A reply object\n@throws FlickrException\n@see <a href=\"http://www.flickr.com/services/api/flickr.groups.discuss.replies.getList.html\">API Documentation</a>",
"The conditional expectation is calculated using a Monte-Carlo regression technique.\n\n@param exerciseTime The exercise time\n@param model The valuation model\n@return The condition expectation estimator\n@throws CalculationException Thrown if underlying model failed to calculate stochastic process.",
"Handling out request.\n\n@param message\nthe message\n@throws Fault\nthe fault",
"Use this API to delete nsip6 resources of given names.",
"Retrieves the formatted parent WBS value.\n\n@return formatted parent WBS value",
"Build the default transformation description.\n\n@param discardPolicy the discard policy to use\n@param inherited whether the definition is inherited\n@param registry the attribute transformation rules for the resource\n@param discardedOperations the discarded operations\n@return the transformation description",
"Sets the currency code, or the regular expression to select codes.\n\n@param codes the currency codes or code expressions, not null.\n@return the query for chaining.",
"Set the row, column, and value\n\n@return this",
"Called after creating the first connection. The adapter should create its caches and do all initialization it requires. Most\nimportantly, the SQL query cache should be created.\n\n@param cnx\nan open ready to use connection to the database."
] |
@Override
public void process(Step context) {
Iterator<Attachment> iterator = context.getAttachments().listIterator();
while (iterator.hasNext()) {
Attachment attachment = iterator.next();
if (pattern.matcher(attachment.getSource()).matches()) {
deleteAttachment(attachment);
iterator.remove();
}
}
for (Step step : context.getSteps()) {
process(step);
}
} | [
"Remove attachments matches pattern from step and all step substeps\n\n@param context from which attachments will be removed"
] | [
"Registers a new site for specific data collection. If null is used as a\nsite key, then all data is collected.\n\n@param siteKey\nthe site to collect geo data for",
"Lookup the username for the specified User URL.\n\n@param url\nThe user profile URL\n@return The username\n@throws FlickrException",
"Checks the preconditions for creating a new StrRegExReplace processor.\n\n@param regex\nthe supplied regular expression\n@param replacement\nthe supplied replacement text\n@throws IllegalArgumentException\nif regex is empty\n@throws NullPointerException\nif regex or replacement is null",
"Permanently close the ClientRequestExecutor pool. Resources subsequently\nchecked in will be destroyed.",
"Converts a number of bytes to a human-readable string\n@param bytes the bytes\n@return the human-readable string",
"Writes back hints file.",
"Called by determineHead and may be overridden in subclasses\nif special treatment is necessary for particular categories.",
"Set the value of switch component.",
"Reads an HTML snippet with the given name.\n\n@return the HTML data"
] |
public ServerGroup getServerGroup(int id, int profileId) throws Exception {
PreparedStatement queryStatement = null;
ResultSet results = null;
if (id == 0) {
return new ServerGroup(0, "Default", profileId);
}
try (Connection sqlConnection = sqlService.getConnection()) {
queryStatement = sqlConnection.prepareStatement(
"SELECT * FROM " + Constants.DB_TABLE_SERVER_GROUPS +
" WHERE " + Constants.GENERIC_ID + " = ?"
);
queryStatement.setInt(1, id);
results = queryStatement.executeQuery();
if (results.next()) {
ServerGroup curGroup = new ServerGroup(results.getInt(Constants.GENERIC_ID),
results.getString(Constants.GENERIC_NAME),
results.getInt(Constants.GENERIC_PROFILE_ID));
return curGroup;
}
logger.info("Did not find the ID: {}", id);
} catch (SQLException e) {
throw e;
} finally {
try {
if (results != null) {
results.close();
}
} catch (Exception e) {
}
try {
if (queryStatement != null) {
queryStatement.close();
}
} catch (Exception e) {
}
}
return null;
} | [
"Returns server group by ID\n\n@param id ID of server group\n@return ServerGroup\n@throws Exception exception"
] | [
"Returns true if the provided matrix is has a value of 1 along the diagonal\nelements and zero along all the other elements.\n\n@param a Matrix being inspected.\n@param tol How close to zero or one each element needs to be.\n@return If it is within tolerance to an identity matrix.",
"Remove a handler from the list\n@param toRemove The handler to remove. Any handler object that\nmatches this class will be removed.\n@return true if this handler was in the list.",
"return request is success by JsonRtn object\n\n@param jsonRtn\n@return",
"Add a listener to be invoked when the checked button changes in this group.\n@param listener\n@param <T>\n@return",
"Parse the JSON string and return the object. The string is expected to be the JSON print data from the\nclient.\n\n@param spec the JSON formatted string.\n@return The encapsulated JSON object",
"Stops the background data synchronization thread and releases the local client.",
"Scale the mesh at x, y and z axis.\n\n@param mesh Mesh to be scaled.\n@param x Scale to be applied on x-axis.\n@param y Scale to be applied on y-axis.\n@param z Scale to be applied on z-axis.",
"Use this API to reset Interface resources.",
"Add a rollback loader for a give patch.\n\n@param patchId the patch id.\n@param target the patchable target\n@throws XMLStreamException\n@throws IOException"
] |
public static wisite_binding get(nitro_service service, String sitepath) throws Exception{
wisite_binding obj = new wisite_binding();
obj.set_sitepath(sitepath);
wisite_binding response = (wisite_binding) obj.get_resource(service);
return response;
} | [
"Use this API to fetch wisite_binding resource of given name ."
] | [
"Returns a representation of the date from the value attributes as ISO\n8601 encoding.\n\n@param value\n@return ISO 8601 value (String)",
"Require that the namespace of the current element matches the required namespace.\n\n@param reader the reader\n@param requiredNs the namespace required\n@throws XMLStreamException if the current namespace does not match the required namespace",
"END ODO CHANGES",
"This method is used to quote any special characters that appear in\nliteral text that is required as part of the currency format.\n\n@param literal Literal text\n@return literal text with special characters in quotes",
"Uploads a new file to this folder while reporting the progress to a ProgressListener.\n\n@param fileContent a stream containing the contents of the file to upload.\n@param name the name to give the uploaded file.\n@param fileSize the size of the file used for determining the progress of the upload.\n@param listener a listener for monitoring the upload's progress.\n@return the uploaded file's info.",
"flush all messages to disk\n\n@param force flush anyway(ignore flush interval)",
"Returns the classpath for executable jar.",
"select a use case.",
"Unlock all files opened for writing."
] |
public DynamicReportBuilder setTemplateFile(String path, boolean importFields, boolean importVariables, boolean importParameters, boolean importDatasets) {
report.setTemplateFileName(path);
report.setTemplateImportFields(importFields);
report.setTemplateImportParameters(importParameters);
report.setTemplateImportVariables(importVariables);
report.setTemplateImportDatasets(importDatasets);
return this;
} | [
"The full path of a jrxml file, or the path in the classpath of a jrxml\nresource.\n\n@param path\n@return"
] | [
"Sets the appropriate OpenCms context.\n@param cms The OpenCms instance object.",
"Organises the data from Asta into a hierarchy and converts this into tasks.\n\n@param bars bar data\n@param expandedTasks expanded task data\n@param tasks task data\n@param milestones milestone data",
"Set the current playback position. This method can only be used in situations where the component is\ntied to a single player, and therefore always has a single playback position.\n\nWill cause part of the component to be redrawn if the position has\nchanged. This will be quickly overruled if a player is being monitored, but\ncan be used in other contexts.\n\n@param milliseconds how far into the track has been played\n\n@see #setPlaybackState",
"Return the serialized form of this Identity.\n\n@return The serialized representation\n@see #fromByteArray\n@deprecated",
"The range of velocities that a particle generated from this emitter can have.\n@param minV Minimum velocity that a particle can have\n@param maxV Maximum velocity that a particle can have",
"in truth we probably only need the types as injected by the metadata binder",
"Add the line to the content\n\n@param bufferedFileReader The file reader\n@param content The content of the file\n@param line The current read line\n@throws IOException",
"Method used to instantiate the appropriate input stream reader,\na standard one, or one which can deal with \"encrypted\" data.\n\n@param directory directory entry\n@param name file name\n@return new input stream\n@throws IOException",
"Retrieves the text value for the baseline duration.\n\n@return baseline duration text"
] |
public void viewDocument(DocumentEntry entry)
{
InputStream is = null;
try
{
is = new DocumentInputStream(entry);
byte[] data = new byte[is.available()];
is.read(data);
m_model.setData(data);
updateTables();
}
catch (IOException ex)
{
throw new RuntimeException(ex);
}
finally
{
StreamHelper.closeQuietly(is);
}
} | [
"Command to select a document from the POIFS for viewing.\n\n@param entry document to view"
] | [
"Use this API to fetch appfwwsdl resource of given name .",
"Remove a named object",
"The normalized string returned by this method is consistent with java.net.Inet6address.\nIPs are not compressed nor mixed in this representation.",
"Issue the database statements to drop the table associated with a dao.\n\n@param dao\nAssociated dao.\n@return The number of statements executed to do so.",
"Puts strings inside quotes and numerics are left as they are.\n@param str\n@return",
"Creates a non-binary media type with the given type, subtype, and UTF-8 encoding\n@throws com.tngtech.jgiven.exception.JGivenWrongUsageException if any of the given arguments is {@code null}",
"Adds the basic sentence.\n\n@param s the s\n@throws ParseException the parse exception",
"Returns the simple name of the builder class that should be generated for the given type.\n\n<p>This is simply the {@link #BUILDER_SIMPLE_NAME_TEMPLATE} with the original type name\nsubstituted in. (If the original type is nested, its enclosing classes will be included,\nseparated with underscores, to ensure uniqueness.)",
"Compares current cluster with final cluster. Uses pertinent store defs\nfor each cluster to determine if a node that hosts a zone-primary in the\ncurrent cluster will no longer host any zone-nary in the final cluster.\nThis check is the precondition for a server returning an invalid metadata\nexception to a client on a normal-case put or get. Normal-case being that\nthe zone-primary receives the pseudo-master put or the get operation.\n\n@param currentCluster\n@param currentStoreDefs\n@param finalCluster\n@param finalStoreDefs\n@return pretty-printed string documenting invalid metadata rates for each\nzone."
] |
private ProjectFile readFile(String inputFile) throws MPXJException
{
ProjectReader reader = new UniversalProjectReader();
ProjectFile projectFile = reader.read(inputFile);
if (projectFile == null)
{
throw new IllegalArgumentException("Unsupported file type");
}
return projectFile;
} | [
"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"
] | [
"Checks if a Zip is valid navigating through the entries\n\n@param file File to validate\n@throws IOException I/O Error",
"Start a managed server.\n\n@param factory the boot command factory",
"Log a message with a throwable at the provided level.",
"Unregister the mgmt channel.\n\n@param old the proxy controller to unregister\n@param shuttingDown whether the server inventory is shutting down\n@return whether the registration can be removed from the domain-controller",
"Process the module and bundle roots and cross check with the installed information.\n\n@param conf the installed configuration\n@param moduleRoots the module roots\n@param bundleRoots the bundle roots\n@return the processed layers\n@throws IOException",
"Total count of partition-stores moved in this task.\n\n@return number of partition stores moved in this task.",
"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 tableConfig\nHand or spring wired table configuration. If null then the class must have {@link DatabaseField}\nannotations.\n@param ignoreErrors\nIf set to true then try each statement regardless of {@link SQLException} thrown previously.\n@return The number of statements executed to do so.",
"This is a method to stream slops to \"slop\" store when a node is detected\nfaulty in a streaming session\n\n@param key -- original key\n@param value -- original value\n@param storeName -- the store for which we are registering the slop\n@param failedNodeId -- the faulty node ID for which we register a slop\n@throws IOException",
"Figures out the correct class loader to use for a proxy for a given bean"
] |
public Set<String> getTags() {
Set<String> tags = new HashSet<String>(classIndex.objectsList());
tags.remove(flags.backgroundSymbol);
return tags;
} | [
"Returns the Set of entities recognized by this Classifier.\n\n@return The Set of entities recognized by this Classifier."
] | [
"Returns a string representation of the receiver, containing\nthe String representation of each key-value pair, sorted ascending by value.",
"Tells you if the expression is the false expression, either literal or constant.\n@param expression\nexpression\n@return\nas described",
"Updates LetsEncrypt configuration.",
"Inserts the specified array into the specified original array at the specified index.\n\n@param original the original array into which we want to insert another array\n@param index the index at which we want to insert the array\n@param inserted the array that we want to insert\n@return the combined array",
"Part of the endOfRun process that needs the database. May be deferred if the database is not available.",
"returns a dynamic Proxy that implements all interfaces of the\nclass described by this ClassDescriptor.\n\n@return Class the dynamically created proxy class",
"Lists the formation info for an app\n\n@param appName See {@link #listApps} for a list of apps that can be used.",
"of the unbound provider (",
"to check availability, then class name is truncated to bundle id"
] |
@Override
public boolean decompose(DMatrixRMaj orig) {
if( orig.numCols != orig.numRows )
throw new IllegalArgumentException("Matrix must be square.");
if( orig.numCols <= 0 )
return false;
int N = orig.numRows;
// compute a similar tridiagonal matrix
if( !decomp.decompose(orig) )
return false;
if( diag == null || diag.length < N) {
diag = new double[N];
off = new double[N-1];
}
decomp.getDiagonal(diag,off);
// Tell the helper to work with this matrix
helper.init(diag,off,N);
if( computeVectors ) {
if( computeVectorsWithValues ) {
return extractTogether();
} else {
return extractSeparate(N);
}
} else {
return computeEigenValues();
}
} | [
"Decomposes the matrix using the QR algorithm. Care was taken to minimize unnecessary memory copying\nand cache skipping.\n\n@param orig The matrix which is being decomposed. Not modified.\n@return true if it decomposed the matrix or false if an error was detected. This will not catch all errors."
] | [
"Checks if two claims are equivalent in the sense that they have the same\nmain snak and the same qualifiers, but possibly in a different order.\n\n@param claim1\n@param claim2\n@return true if claims are equivalent",
"Use this API to fetch all the spilloverpolicy resources that are configured on netscaler.",
"Use this API to add sslcertkey.",
"Extracts calendar data from a ConceptDraw PROJECT file.\n\n@param cdp ConceptDraw PROJECT file",
"Sinc function.\n\n@param x Value.\n@return Sinc of the value.",
"Returns all migrations starting from and excluding the given version. Usually you want to provide the version of\nthe database here to get all migrations that need to be executed. In case there is no script with a newer\nversion than the one given, an empty list is returned.\n\n@param version the version that is currently in the database\n@return all versions since the given version or an empty list if no newer script is available. Never null.\nDoes not include the given version.",
"Print the class's constructors m",
"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",
"Removes all events from table\n\n@param table the table to remove events"
] |
private static JSONArray parseStencilSetExtensions(ArrayList<String> extensions) {
if (extensions != null) {
JSONArray extensionsArray = new JSONArray();
for (String extension : extensions) {
extensionsArray.put(extension.toString());
}
return extensionsArray;
}
return new JSONArray();
} | [
"Delivers the correct JSON Object for the Stencilset Extensions\n\n@param extensions"
] | [
"Return the number of days between startDate and endDate given the\nspecific daycount convention.\n\n@param startDate The start date given as a {@link org.threeten.bp.LocalDate}.\n@param endDate The end date given as a {@link org.threeten.bp.LocalDate}.\n@param convention A convention string.\n@return The number of days within the given period.",
"Send the started notification",
"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",
"Check if number is valid\n\n@return boolean",
"Returns the default jdbc type for the given java type.\n\n@param javaType The qualified java type\n@return The default jdbc type",
"Remove the S3 file that contains the domain controller data.\n\n@param directoryName the name of the directory that contains the S3 file",
"Gets the pathClasses.\nA Map containing hints about what Class to be used for what path segment\nIf local instance not set, try parent Criteria's instance. If this is\nthe top-level Criteria, try the m_query's instance\n@return Returns a Map",
"Creates a field map for resources.\n\n@param props props data",
"Microsoft Project bases the order of tasks displayed on their ID\nvalue. This method takes the hierarchical structure of tasks\nrepresented in MPXJ and renumbers the ID values to ensure that\nthis structure is displayed as expected in Microsoft Project. This\nis typically used to deal with the case where a hierarchical task\nstructure has been created programmatically in MPXJ."
] |
public static ResourceKey key(Enum<?> enumValue, String key) {
return new ResourceKey(enumValue.getClass().getName(), enumValue.name()).child(key);
} | [
"Creates a resource key defined as a child of key defined by enumeration value.\n@see #key(Enum)\n@see #child(String)\n@param enumValue the enumeration value defining the parent key\n@param key the child id\n@return the resource key"
] | [
"Delete rows that match the prepared statement.",
"calls _initMH on the method handler and then stores the result in the\nmethodHandler field as then new methodHandler",
"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. This is\ndone to allow encrypted data to be queried against. Encrypted text is hex-encoded.\n\n@param password the password used to generate the encryptor's secret key; should not be shared\n@param salt a hex-encoded, random, site-global salt value to use to generate the secret key",
"Set the row, column, and value\n\n@return this",
"Downloads a part of this file's contents, starting at rangeStart and stopping at rangeEnd, while reporting the\nprogress to a ProgressListener.\n\n@param output the stream to where the file will be written.\n@param rangeStart the byte offset at which to start the download.\n@param rangeEnd the byte offset at which to stop the download.\n@param listener a listener for monitoring the download's progress.",
"Check whether the given is is matched by one of the include expressions.\n\n@param id id to check\n@param includes list of include regular expressions\n@return true when id is included",
"Get a property as a int or null.\n\n@param key the property name",
"Load entries from the storage.\nOverriding methods should first delegate to super before adding their own entries.",
"Determine whether the given property matches this element.\nA property matches this element when property name and this key are equal,\nvalues are equal or this element value is a wildcard.\n@param property the property to check\n@return {@code true} if the property matches"
] |
public Table createTable(ProjectFile file, byte[] data, VarMeta varMeta, Var2Data varData)
{
Table table = new Table();
table.setID(MPPUtility.getInt(data, 0));
table.setResourceFlag(MPPUtility.getShort(data, 108) == 1);
table.setName(MPPUtility.removeAmpersands(MPPUtility.getUnicodeString(data, 4)));
byte[] columnData = null;
Integer tableID = Integer.valueOf(table.getID());
if (m_tableColumnDataBaseline != null)
{
columnData = varData.getByteArray(varMeta.getOffset(tableID, m_tableColumnDataBaseline));
}
if (columnData == null)
{
columnData = varData.getByteArray(varMeta.getOffset(tableID, m_tableColumnDataEnterprise));
if (columnData == null)
{
columnData = varData.getByteArray(varMeta.getOffset(tableID, m_tableColumnDataStandard));
}
}
processColumnData(file, table, columnData);
//System.out.println(table);
return (table);
} | [
"Creates a new Table instance from data extracted from an MPP file.\n\n@param file parent project file\n@param data fixed data\n@param varMeta var meta\n@param varData var data\n@return Table instance"
] | [
"A simple convinience function that decomposes the matrix but automatically checks the input ti make\nsure is not being modified.\n\n@param decomp Decomposition which is being wrapped\n@param M THe matrix being decomposed.\n@param <T> Matrix type.\n@return If the decomposition was successful or not.",
"Clears all checked widgets in the group",
"Adds folders to perform the search in.\n@param folders Folders to search in.",
"Use this API to update nsdiameter.",
"Makes the object unpickable and removes the touch handler for it\n@param sceneObject\n@return true if the handler has been successfully removed",
"Returns a UTMDetail object which consists of UTM parameters like source, medium & campaign\n@return The {@link UTMDetail} object",
"Serialize specified object to directory with specified name. Given output stream will be closed.\n\n@param obj object to serialize\n@return number of bytes written to directory",
"Shows the provided list of dates as current dates.\n@param dates the current dates to show, accompanied with the information if they are exceptions or not.",
"Creates an operations that targets this handler.\n@param operationToValidate the operation that this handler will validate\n@return the validation operation"
] |
private void executeBatch(int batchId, final RebalanceBatchPlan batchPlan) {
final Cluster batchCurrentCluster = batchPlan.getCurrentCluster();
final List<StoreDefinition> batchCurrentStoreDefs = batchPlan.getCurrentStoreDefs();
final Cluster batchFinalCluster = batchPlan.getFinalCluster();
final List<StoreDefinition> batchFinalStoreDefs = batchPlan.getFinalStoreDefs();
try {
final List<RebalanceTaskInfo> rebalanceTaskInfoList = batchPlan.getBatchPlan();
if(rebalanceTaskInfoList.isEmpty()) {
RebalanceUtils.printBatchLog(batchId, logger, "Skipping batch "
+ batchId + " since it is empty.");
// Even though there is no rebalancing work to do, cluster
// metadata must be updated so that the server is aware of the
// new cluster xml.
adminClient.rebalanceOps.rebalanceStateChange(batchCurrentCluster,
batchFinalCluster,
batchCurrentStoreDefs,
batchFinalStoreDefs,
rebalanceTaskInfoList,
false,
true,
false,
false,
true);
return;
}
RebalanceUtils.printBatchLog(batchId, logger, "Starting batch "
+ batchId + ".");
// Split the store definitions
List<StoreDefinition> readOnlyStoreDefs = StoreDefinitionUtils.filterStores(batchFinalStoreDefs,
true);
List<StoreDefinition> readWriteStoreDefs = StoreDefinitionUtils.filterStores(batchFinalStoreDefs,
false);
boolean hasReadOnlyStores = readOnlyStoreDefs != null
&& readOnlyStoreDefs.size() > 0;
boolean hasReadWriteStores = readWriteStoreDefs != null
&& readWriteStoreDefs.size() > 0;
// STEP 1 - Cluster state change
boolean finishedReadOnlyPhase = false;
List<RebalanceTaskInfo> filteredRebalancePartitionPlanList = RebalanceUtils.filterTaskPlanWithStores(rebalanceTaskInfoList,
readOnlyStoreDefs);
rebalanceStateChange(batchId,
batchCurrentCluster,
batchCurrentStoreDefs,
batchFinalCluster,
batchFinalStoreDefs,
filteredRebalancePartitionPlanList,
hasReadOnlyStores,
hasReadWriteStores,
finishedReadOnlyPhase);
// STEP 2 - Move RO data
if(hasReadOnlyStores) {
RebalanceBatchPlanProgressBar progressBar = batchPlan.getProgressBar(batchId);
executeSubBatch(batchId,
progressBar,
batchCurrentCluster,
batchCurrentStoreDefs,
filteredRebalancePartitionPlanList,
hasReadOnlyStores,
hasReadWriteStores,
finishedReadOnlyPhase);
}
// STEP 3 - Cluster change state
finishedReadOnlyPhase = true;
filteredRebalancePartitionPlanList = RebalanceUtils.filterTaskPlanWithStores(rebalanceTaskInfoList,
readWriteStoreDefs);
rebalanceStateChange(batchId,
batchCurrentCluster,
batchCurrentStoreDefs,
batchFinalCluster,
batchFinalStoreDefs,
filteredRebalancePartitionPlanList,
hasReadOnlyStores,
hasReadWriteStores,
finishedReadOnlyPhase);
// STEP 4 - Move RW data
if(hasReadWriteStores) {
proxyPause();
RebalanceBatchPlanProgressBar progressBar = batchPlan.getProgressBar(batchId);
executeSubBatch(batchId,
progressBar,
batchCurrentCluster,
batchCurrentStoreDefs,
filteredRebalancePartitionPlanList,
hasReadOnlyStores,
hasReadWriteStores,
finishedReadOnlyPhase);
}
RebalanceUtils.printBatchLog(batchId,
logger,
"Successfully terminated batch "
+ batchId + ".");
} catch(Exception e) {
RebalanceUtils.printErrorLog(batchId, logger, "Error in batch "
+ batchId + " - " + e.getMessage(), e);
throw new VoldemortException("Rebalance failed on batch " + batchId,
e);
}
} | [
"Executes a batch plan.\n\n@param batchId Used as the ID of the batch plan. This allows related\ntasks on client- & server-side to pretty print messages in a\nmanner that debugging can track specific batch plans across the\ncluster.\n@param batchPlan The batch plan..."
] | [
"Converts a byte array to a hexadecimal string representation\n@param bb the byte array to convert\n@return string the string representation",
"Check type.\n\n@param type the type\n@return the boolean",
"Return all scripts of a given type\n\n@param type integer value of type\n@return Array of scripts of the given type",
"Use this API to delete route6 of given name.",
"Retrieve a UUID in the form required by Primavera PMXML.\n\n@param guid UUID instance\n@return formatted UUID",
"Sets the set of language filters based on the given string.\n\n@param filters\ncomma-separates list of language codes, or \"-\" to filter all\nlanguages",
"Use this API to delete nsip6.",
"Checks anonymous fields.\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",
"Creates an attachment from a binary input stream.\nThe content of the stream will be transformed into a Base64 encoded string\n@throws IOException if an I/O error occurs\n@throws java.lang.IllegalArgumentException if mediaType is not binary"
] |
public int[] next()
{
boolean hasNewPerm = false;
escape:while( level >= 0) {
// boolean foundZero = false;
for( int i = iter[level]; i < data.length; i = iter[level] ) {
iter[level]++;
if( data[i] == -1 ) {
level++;
data[i] = level-1;
if( level >= data.length ) {
// a new permutation has been created return the results.
hasNewPerm = true;
System.arraycopy(data,0,ret,0,ret.length);
level = level-1;
data[i] = -1;
break escape;
} else {
valk[level] = i;
}
}
}
data[valk[level]] = -1;
iter[level] = 0;
level = level-1;
}
if( hasNewPerm )
return ret;
return null;
} | [
"Creates the next permutation in the sequence.\n\n@return An array containing the permutation. The returned array is modified each time this function is called."
] | [
"Set the week of month.\n@param weekOfMonthStr the week of month to set.",
"Returns an array of the enabled endpoints as Integer IDs\n\n@param pathId ID of path\n@param clientUUID UUID of client\n@param filters If supplied, only endpoints ending with values in filters are returned\n@return Collection of endpoints\n@throws Exception exception",
"Set the mesh to be tested against.\n\n@param mesh\nThe {@link GVRMesh} that the picking ray will test against.",
"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",
"retrieve a collection of type collectionClass matching the Query query\n\n@see org.apache.ojb.broker.PersistenceBroker#getCollectionByQuery(Class, Query)",
"region Override Methods",
"calculate arc angle between point a and point b\n\n@param center\n@param a\n@param b\n@param area\n@param radius\n@return",
"Update artifact download url of an artifact\n\n@param gavc String\n@param downLoadUrl String",
"Remove a management request handler factory from this context.\n\n@param instance the request handler factory\n@return {@code true} if the instance was removed, {@code false} otherwise"
] |
public static <T extends HasWord> TokenizerFactory<T> factory(LexedTokenFactory<T> factory, String options) {
return new PTBTokenizerFactory<T>(factory, options);
} | [
"Get a TokenizerFactory that does Penn Treebank tokenization.\nThis is now the recommended factory method to use.\n\n@param factory A TokenFactory that determines what form of token is returned by the Tokenizer\n@param options A String specifying options (see the class javadoc for details)\n@param <T> The type of the tokens built by the LexedTokenFactory\n@return A TokenizerFactory that does Penn Treebank tokenization"
] | [
"Gets the value of a global editor configuration parameter.\n\n@param cms the CMS context\n@param editor the editor name\n@param param the name of the parameter\n\n@return the editor parameter value",
"On key down we assume the key will go at the end. It's the most\ncommon case and not that distracting if that's not true.",
"Prints the data for a single class to the given stream. This will be a\nsingle line in CSV.\n\n@param out\nthe output to write to\n@param classRecord\nthe class record to write\n@param entityIdValue\nthe item id that this class record belongs to",
"do the parsing on an JSONObject, assumes that the json is hierarchical\nordered, so all shapes are reachable over child relations\n@param json hierarchical JSON object\n@return Model with all shapes defined in JSON\n@throws org.json.JSONException",
"Maps the text representation of column data to Java types.\n\n@param table table name\n@param column column name\n@param data text representation of column data\n@param type column data type\n@param epochDateFormat true if date is represented as an offset from an epoch\n@return Java representation of column data\n@throws MPXJException",
"Convert an object to another object given a parameterized type signature\n\n@param context\n@param destinationType\nthe destination type\n@param source\nthe source object\n\n@return the converted object\n@throws ConverterException\nif conversion failed",
"Attemps to delete all provided segments from a log and returns how many it was able to",
"Description accessor provided for JSON serialization only.",
"Creates a sorted list that contains the items of the given iterable. The resulting list is in ascending order,\naccording to the natural ordering of the elements in the iterable.\n\n@param iterable\nthe items to be sorted. May not be <code>null</code>.\n@return a sorted list as a shallow copy of the given iterable.\n@see Collections#sort(List)\n@see #sort(Iterable, Comparator)\n@see #sortBy(Iterable, org.eclipse.xtext.xbase.lib.Functions.Function1)\n@see ListExtensions#sortInplace(List)"
] |
public static ProjectWriter getProjectWriter(String name) throws InstantiationException, IllegalAccessException
{
int index = name.lastIndexOf('.');
if (index == -1)
{
throw new IllegalArgumentException("Filename has no extension: " + name);
}
String extension = name.substring(index + 1).toUpperCase();
Class<? extends ProjectWriter> fileClass = WRITER_MAP.get(extension);
if (fileClass == null)
{
throw new IllegalArgumentException("Cannot write files of type: " + name);
}
ProjectWriter file = fileClass.newInstance();
return (file);
} | [
"Retrieves a ProjectWriter instance which can write a file of the\ntype specified by the supplied file name.\n\n@param name file name\n@return ProjectWriter instance"
] | [
"Given a list of keys and a number of splits find the keys to split on.\n\n@param keys the list of keys.\n@param numSplits the number of splits.",
"Adds all items from the iterable to the Collection.\n\n@param self the collection\n@param items the items to add\n@return true if the collection changed",
"Get the server redirects belonging to a server group\n\n@param profileId ID of profile\n@param serverGroupId ID of server group\n@return Collection of ServerRedirect for a server group",
"Add raw SQL \"ORDER BY\" clause to the SQL query statement.\n\n@param rawSql\nThe raw SQL order by clause. This should not include the \"ORDER BY\".",
"This method is used to push install referrer via UTM source, medium & campaign parameters\n@param source The UTM source parameter\n@param medium The UTM medium parameter\n@param campaign The UTM campaign parameter",
"Returns a fine-grained word shape classifier, that equivalence classes\nlower and upper case and digits, and collapses sequences of the\nsame type, but keeps all punctuation. This adds an extra recognizer\nfor a greek letter embedded in the String, which is useful for bio.",
"Remove control from the control bar. Size of control bar is updated based on new number of\ncontrols.\n@param name name of the control to remove",
"Evaluates the animation with the given index at the specified time.\n@param animIndex 0-based index of {@link GVRAnimator} to start\n@param timeInSec time to evaluate the animation at\n@see GVRAvatar#stop()\n@see #start(String)",
"make a copy of the criteria\n@param includeGroupBy if true\n@param includeOrderBy if ture\n@param includePrefetchedRelationships if true\n@return a copy of the criteria"
] |
public static void setLocale(ProjectProperties properties, Locale locale)
{
properties.setMpxDelimiter(LocaleData.getChar(locale, LocaleData.FILE_DELIMITER));
properties.setMpxProgramName(LocaleData.getString(locale, LocaleData.PROGRAM_NAME));
properties.setMpxCodePage((CodePage) LocaleData.getObject(locale, LocaleData.CODE_PAGE));
properties.setCurrencySymbol(LocaleData.getString(locale, LocaleData.CURRENCY_SYMBOL));
properties.setSymbolPosition((CurrencySymbolPosition) LocaleData.getObject(locale, LocaleData.CURRENCY_SYMBOL_POSITION));
properties.setCurrencyDigits(LocaleData.getInteger(locale, LocaleData.CURRENCY_DIGITS));
properties.setThousandsSeparator(LocaleData.getChar(locale, LocaleData.CURRENCY_THOUSANDS_SEPARATOR));
properties.setDecimalSeparator(LocaleData.getChar(locale, LocaleData.CURRENCY_DECIMAL_SEPARATOR));
properties.setDateOrder((DateOrder) LocaleData.getObject(locale, LocaleData.DATE_ORDER));
properties.setTimeFormat((ProjectTimeFormat) LocaleData.getObject(locale, LocaleData.TIME_FORMAT));
properties.setDefaultStartTime(DateHelper.getTimeFromMinutesPastMidnight(LocaleData.getInteger(locale, LocaleData.DEFAULT_START_TIME)));
properties.setDateSeparator(LocaleData.getChar(locale, LocaleData.DATE_SEPARATOR));
properties.setTimeSeparator(LocaleData.getChar(locale, LocaleData.TIME_SEPARATOR));
properties.setAMText(LocaleData.getString(locale, LocaleData.AM_TEXT));
properties.setPMText(LocaleData.getString(locale, LocaleData.PM_TEXT));
properties.setDateFormat((ProjectDateFormat) LocaleData.getObject(locale, LocaleData.DATE_FORMAT));
properties.setBarTextDateFormat((ProjectDateFormat) LocaleData.getObject(locale, LocaleData.DATE_FORMAT));
} | [
"This method is called when the locale of the parent file is updated.\nIt resets the locale specific currency attributes to the default values\nfor the new locale.\n\n@param properties project properties\n@param locale new locale"
] | [
"Returns the adapter position of the Parent associated with this ParentViewHolder\n\n@return The adapter position of the Parent if it still exists in the adapter.\nRecyclerView.NO_POSITION if item has been removed from the adapter,\nRecyclerView.Adapter.notifyDataSetChanged() has been called after the last\nlayout pass or the ViewHolder has already been recycled.",
"do the parsing on an JSONObject, assumes that the json is hierarchical\nordered, so all shapes are reachable over child relations\n@param json hierarchical JSON object\n@return Model with all shapes defined in JSON\n@throws org.json.JSONException",
"Add component processing time to given map\n@param mapComponentTimes\n@param component",
"Returns an array with the width of the longest word per column calculated from the given table.\nDefault padding will be added per column.\nPadding for individual columns will be added if defined.\n@param rows the table rows for calculations\n@param colNumbers number of columns in the table\n@return array with width of longest word for each column, null if input table was null",
"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)",
"Find the the qualified container port of the target service\nUses java annotations first or returns the container port.\n\n@param service\nThe target service.\n@param qualifiers\nThe set of qualifiers.\n\n@return Returns the resolved containerPort of '0' as a fallback.",
"Gets the Java subclass of GVRShader which implements\nthis shader type.\n@param ctx GVRContext shader is associated with\n@return GVRShader class implementing the shader type",
"Read calendar data.",
"Get list of Jobs from a queue.\n\n@param jedis\n@param queueName\n@param jobOffset\n@param jobCount\n@return"
] |
public PhotoList<Photo> getRecent(Set<String> extras, int perPage, int page) throws FlickrException {
Map<String, Object> parameters = new HashMap<String, Object>();
parameters.put("method", METHOD_GET_RECENT);
if (extras != null && !extras.isEmpty()) {
parameters.put(Extras.KEY_EXTRAS, StringUtilities.join(extras, ","));
}
if (perPage > 0) {
parameters.put("per_page", Integer.toString(perPage));
}
if (page > 0) {
parameters.put("page", Integer.toString(page));
}
Response response = transport.get(transport.getPath(), parameters, apiKey, sharedSecret);
if (response.isError()) {
throw new FlickrException(response.getErrorCode(), response.getErrorMessage());
}
Element photosElement = response.getPayload();
PhotoList<Photo> photos = PhotoUtils.createPhotoList(photosElement);
return photos;
} | [
"Get a collection of recent photos.\n\nThis method does not require authentication.\n\n@see com.flickr4java.flickr.photos.Extras\n@param extras\nSet of extra-fields\n@param perPage\nThe number of photos per page\n@param page\nThe page offset\n@return A collection of Photo objects\n@throws FlickrException"
] | [
"Retrieve the default number of minutes per month.\n\n@return minutes per month",
"Logs an error by sending an error event to all listeners.\n\nError events can be generated by any part of GearVRF,\nfrom any thread. They are always sent to the event receiver\nof the GVRContext.\n\n@param message error message\n@param sender object which had the error\n@see IErrorEvents",
"Process dump file data from the given input stream. The method can\nrecover from an errors that occurred while processing an input stream,\nwhich is assumed to contain the JSON serialization of a list of JSON\nentities, with each entity serialization in one line. To recover from the\nprevious error, the first line is skipped.\n\n@param inputStream\nthe stream to read from\n@throws IOException\nif there is a problem reading the stream",
"This method is called from the task class each time an attribute\nis added, ensuring that all of the attributes present in each task\nrecord are present in the resource model.\n\n@param field field identifier",
"Set the serial end date.\n@param date the serial end date.",
"Converts this update description to its document representation as it would appear in a\nMongoDB Change Event.\n\n@return the update description document as it would appear in a change event",
"Add a note to a photo. The Note object bounds and text must be specified.\n\n@param photoId\nThe photo ID\n@param note\nThe Note object\n@return The updated Note object",
"convenience factory method for the most usual case.",
"This will check to see if certain configuration values exist from the ConfigurationService\nIf not then it redirects to the configuration screen"
] |
@Override public void close() throws IOException
{
long skippedLast = 0;
if (m_remaining > 0)
{
skippedLast = skip(m_remaining);
while (m_remaining > 0 && skippedLast > 0)
{
skippedLast = skip(m_remaining);
}
}
} | [
"Closing will only skip to the end of this fixed length input stream and\nnot call the parent's close method.\n@throws IOException if an I/O error occurs while closing stream"
] | [
"if you have a default, it's automatically optional",
"Gets a property from system, environment or an external map.\nThe lookup order is system > env > map > defaultValue.\n\n@param name\nThe name of the property.\n@param map\nThe external map.\n@param defaultValue\nThe value that should be used if property is not found.",
"Remove a named object",
"Populates a calendar exception instance.\n\n@param record MPX record\n@param calendar calendar to which the exception will be added\n@throws MPXJException",
"Return collection of path Ids in priority order\n\n@param profileId ID of profile\n@return collection of path Ids in priority order",
"Creates, writes and loads a new keystore and CA root certificate.",
"Use this API to fetch all the nsdiameter resources that are configured on netscaler.",
"See also WELD-1454.\n\n@param ij\n@return the formatted string",
"Use this API to fetch a tmglobal_tmsessionpolicy_binding resources."
] |
private void readVersion(InputStream is) throws IOException
{
BytesReadInputStream bytesReadStream = new BytesReadInputStream(is);
String version = DatatypeConverter.getString(bytesReadStream);
m_offset += bytesReadStream.getBytesRead();
SynchroLogger.log("VERSION", version);
String[] versionArray = version.split("\\.");
m_majorVersion = Integer.parseInt(versionArray[0]);
} | [
"Read the version number.\n\n@param is input stream"
] | [
"Tells you if the ASTNode is a method node for the given name, arity, and return type.\n@param node\nthe node to inspect\n@param methodNamePattern\nthe expected name of the method\n@param numArguments\nthe expected number of arguments, optional\n@param returnType\nthe expected return type, optional\n@return\ntrue if this node is a MethodNode meeting the parameters. false otherwise",
"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",
"Handles Multi Instance Report message. Handles Report on\nthe number of instances for the command class.\n@param serialMessage the serial message to process.\n@param offset the offset at which to start procesing.",
"A comment.\n\n@param args the parameters",
"Opens a JDBC connection with the given parameters.",
"Unmarshals the descriptor content.\n\n@throws CmsXmlException thrown if the XML structure of the descriptor is wrong.\n@throws CmsException thrown if reading the descriptor file fails.",
"Get result report.\n\n@param reportURI the URI of the report\n@return the result report.",
"Check if all cluster objects in the list are congruent.\n\n@param clusterUrls of cluster objects\n@return",
"Set the channel. This will return whether the channel could be set successfully or not.\n\n@param newChannel the channel\n@return whether the operation succeeded or not"
] |
@Override
public final PObject getObject(final String key) {
PObject result = optObject(key);
if (result == null) {
throw new ObjectMissingException(this, key);
}
return result;
} | [
"Get a property as a object or throw exception.\n\n@param key the property name"
] | [
"Alias accessor provided for JSON serialization only",
"Pretty print a progress update after each batch complete.\n\n@param batchCount current batch\n@param numBatches total number of batches\n@param partitionStoreCount partition stores migrated\n@param numPartitionStores total number of partition stores to migrate\n@param totalTimeMs total time, in milliseconds, of execution thus far.",
"Create a Count-Query for QueryBySQL\n\n@param aQuery\n@return The count query",
"Extract resource type from a resource ID string.\n@param id the resource ID string\n@return the resource type",
"Get the waveform details available for all tracks currently loaded in any player, either on the play deck, or\nin a hot cue.\n\n@return the details associated with all current players, including for any tracks loaded in their hot cue slots\n\n@throws IllegalStateException if the WaveformFinder is not running or requesting waveform details",
"Use this API to fetch the statistics of all protocolip_stats resources that are configured on netscaler.",
"Try to open a file at the given position.",
"converts a java.net.URI into a string representation with empty authority, if absent and has file scheme.",
"Get a unique reference to a place where a track is currently loaded in a player.\n\n@param player the player in which the track is loaded\n@param hotCue hot cue number in which the track is loaded, or 0 if it is actively loaded on the playback deck\n\n@return the instance that will always represent a reference to the specified player and hot cue"
] |
public static ServiceName deploymentUnitName(String name, Phase phase) {
return JBOSS_DEPLOYMENT_UNIT.append(name, phase.name());
} | [
"Get the service name of a top-level deployment unit.\n\n@param name the simple name of the deployment\n@param phase the deployment phase\n@return the service name"
] | [
"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.",
"Initial random seed used for shuffling test suites and other sources\nof pseudo-randomness. If not set, any random value is set.\n\n<p>The seed's format is compatible with {@link RandomizedRunner} so that\nseed can be fixed for suites and methods alike.",
"This private method allows the caller to determine if a given date is a\nworking day. This method takes account of calendar exceptions. It assumes\nthat the caller has already calculated the day of the week on which\nthe given day falls.\n\n@param date Date to be tested\n@param day Day of the week for the date under test\n@return boolean flag",
"Creates a new row with content with given cell context and a normal row style.\n@param content the content for the row, each member of the array represents the content for a cell in the row, must not be null but can contain null members\n@return a new row with content\n@throws {@link NullPointerException} if content was null",
"Determines the accessor method name based on a field name.\n\n@param fieldName\na field name\n@return the resulting method name",
"Invite a user to an enterprise.\n@param api the API connection to use for the request.\n@param userLogin the login of the user to invite.\n@param enterpriseID the ID of the enterprise to invite the user to.\n@return the invite info.",
"Returns all keys of all rows contained within this association.\n\n@return all keys of all rows contained within this association",
"Retrieves and validates the content length from the REST request.\n\n@return true if has content length",
"This method allows a resource assignment to be added to the\ncurrent task.\n\n@param resource the resource to assign\n@return ResourceAssignment object"
] |
public VideoCollection generate(final int videoCount) {
List<Video> videos = new LinkedList<Video>();
for (int i = 0; i < videoCount; i++) {
Video video = generateRandomVideo();
videos.add(video);
}
return new VideoCollection(videos);
} | [
"Generate a VideoCollection with random data obtained form VIDEO_INFO map. You don't need o\ncreate your own AdapteeCollections. Review ListAdapteeCollection if needed.\n\n@param videoCount size of the collection.\n@return VideoCollection generated."
] | [
"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",
"Add the list with given bundles to the \"Import-Package\" main attribute.\n\n@param importedPackages The list of all packages to add.",
"Creates a new connection from the data source that the connection descriptor\nrepresents. If the connection descriptor does not directly contain the data source\nthen a JNDI lookup is performed to retrieve the data source.\n\n@param jcd The connection descriptor\n@return A connection instance\n@throws LookupException if we can't get a connection from the datasource either due to a\nnaming exception, a failed sanity check, or a SQLException.",
"Creates a rectangular matrix which is zero except along the diagonals.\n\n@param numRows Number of rows in the matrix.\n@param numCols NUmber of columns in the matrix.\n@return A matrix with diagonal elements equal to one.",
"Initializes the alarm sensor command class. Requests the supported alarm types.",
"Use this API to fetch all the nsfeature resources that are configured on netscaler.",
"As already described, but if separator is not null, then objects\nsuch as TaggedWord\n\n@param separator The string used to separate Word and Tag\nin TaggedWord, etc",
"Release the broker instance.",
"Used to create a new retention policy.\n@param api the API connection to be used by the created user.\n@param name the name of the retention policy.\n@param type the type of the retention policy. Can be \"finite\" or \"indefinite\".\n@param length the duration in days that the retention policy will be active for after being assigned to content.\n@param action the disposition action can be \"permanently_delete\" or \"remove_retention\".\n@return the created retention policy's info."
] |
CapabilityRegistry createShadowCopy() {
CapabilityRegistry result = new CapabilityRegistry(forServer, this);
readLock.lock();
try {
try {
result.writeLock.lock();
copy(this, result);
} finally {
result.writeLock.unlock();
}
} finally {
readLock.unlock();
}
return result;
} | [
"Creates updateable version of capability registry that on publish pushes all changes to main registry\nthis is used to create context local registry that only on completion commits changes to main registry\n\n@return writable registry"
] | [
"Use this API to delete route6.",
"Creates a new immutable set that consists of given elements.\n\n@param elements the given elements\n@return a new immutable set that consists of given elements",
"Records the list of backedup files into a text file\n\n@param filesInEnv\n@param backupDir",
"Creates a Bytes object by copying the data of the CharSequence and encoding it using UTF-8.",
"Set a Java classname path to ignore when printing stack traces\n@param classToIgnoreInTraces The class name (with packages, etc) to ignore.\n@return this",
"Creates a new ServerDetails object for deployer, this will take URL and name from the oldDeployer ServerDetails",
"iteration not synchronized",
"persist decorator and than continue to children without touching the model",
"We have received notification that a device is no longer on the network, so clear out all its waveforms.\n\n@param announcement the packet which reported the device’s disappearance"
] |
public static List<Integer> getAllNodeIds(AdminClient adminClient) {
List<Integer> nodeIds = Lists.newArrayList();
for(Integer nodeId: adminClient.getAdminClientCluster().getNodeIds()) {
nodeIds.add(nodeId);
}
return nodeIds;
} | [
"Utility function that fetches node ids.\n\n@param adminClient An instance of AdminClient points to given cluster\n@return Node ids in cluster"
] | [
"Check whether vector addition works. This is pure Java code and should work.",
"Attemps to delete all provided segments from a log and returns how many it was able to",
"Join N sets.",
"When all the elements in a sorted set are inserted with the same score, in order to force lexicographical\nordering, this command returns the number of elements in the sorted set with a value in the given range.\n@param lexRange\n@return the number of elements in the specified range.",
"Make sure that we have some reasonable defaults available. These would typically be provided by the rulesets\nin the real world.",
"Log a fatal message with a throwable.",
"Read custom fields for a GanttProject task.\n\n@param gpTask GanttProject task\n@param mpxjTask MPXJ Task instance",
"Add parameter to testCase\n\n@param context which can be changed",
"Add an executable \"post-run\" dependent for this model.\n\n@param executable the executable \"post-run\" dependent\n@return the key to be used as parameter to taskResult(string) method to retrieve result of executing\nthe executable \"post-run\" dependent"
] |
@Override
public synchronized void start() {
if (!started.getAndSet(true)) {
finished.set(false);
thread.start();
}
} | [
"Starts processor thread."
] | [
"Returns the configured fields of the current field configuration.\n\n@return the configured fields of the current field configuration",
"Use this API to fetch authorizationpolicylabel_binding resource of given name .",
"Requests the beat grid for a specific track ID, given a connection to a player that has already been set up.\n\n@param rekordboxId the track of interest\n@param slot identifies the media slot we are querying\n@param client the dbserver client that is communicating with the appropriate player\n\n@return the retrieved beat grid, or {@code null} if there was none available\n\n@throws IOException if there is a communication problem",
"Here the lambda in the implicit step is determined dynamically. At first\nit selects zeros to quickly reveal singular values that are zero or close to zero.\nThen it computes it using a Wilkinson shift.",
"Perform all Cursor cleanup here.",
"If the layer transformer has not been prepared yet, do it.\n\n@param transformer the transformer",
"Get a collection of tags used by the specified user.\n\n<p>\nThis method does not require authentication.\n</p>\n\n@param userId\nThe User ID\n@return The User object\n@throws FlickrException",
"Get DPI suggestions.\n\n@return DPI suggestions",
"Use this API to fetch dnsnsecrec resources of given names ."
] |
public static Class<?> resolvePrimitiveIfNecessary(Class<?> clazz) {
Assert.notNull(clazz, "Class must not be null");
return (clazz.isPrimitive() && clazz != void.class? primitiveTypeToWrapperMap.get(clazz) : clazz);
} | [
"Resolve the given class if it is a primitive class,\nreturning the corresponding primitive wrapper type instead.\n@param clazz the class to check\n@return the original class, or a primitive wrapper for the original primitive type"
] | [
"This creates a new audit log file with default permissions.\n\n@param file File to create",
"Obtain collection of profiles\n\n@param model\n@return\n@throws Exception",
"Gets the SerialMessage as a byte array.\n@return the message",
"1.5 and on, 2.0 and on, 3.0 and on.",
"Allocates a database connection.\n\n@throws SQLException",
"Parse duration represented as an arbitrary fraction of minutes.\n\n@param properties project properties\n@param value duration value\n@param targetTimeUnit required output time units\n@param factor required fraction of a minute\n@return Duration instance",
"Add a raw SQL \"GROUP BY\" clause to the SQL query statement. This should not include the \"GROUP BY\".",
"Tests that the area is valid geojson, the style ref is valid or null and the display is non-null.",
"Use this API to rename a cmppolicylabel resource."
] |
@SuppressWarnings("unchecked")
public static <E> void serialize(E object, ParameterizedType<E> parameterizedType, OutputStream os) throws IOException {
mapperFor(parameterizedType).serialize(object, os);
} | [
"Serialize a parameterized object to an OutputStream.\n\n@param object The object to serialize.\n@param parameterizedType The ParameterizedType describing the object. Ex: LoganSquare.serialize(object, new ParameterizedType<MyModel<OtherModel>>() { }, os);\n@param os The OutputStream being written to."
] | [
"Sets the currency code, or the regular expression to select codes.\n\n@param codes the currency codes or code expressions, not null.\n@return the query for chaining.",
"Get an extent aware RsIterator based on the Query\n\n@param query\n@param cld\n@param factory the Factory for the RsIterator\n@return OJBIterator",
"Returns the primary message codewords for mode 2.\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",
"Converts a date to an instance date bean.\n@return the instance date bean.",
"Start the timer.",
"Returns the deployment names with the specified runtime names at the specified deploymentRootAddress.\n\n@param deploymentRootResource\n@param runtimeNames\n@return the deployment names with the specified runtime names at the specified deploymentRootAddress.",
"The service name to be removed. Can be overridden for unusual service naming patterns\n@param name The name of the resource being removed\n@return The service name to remove. May return {@code null} if only removal based on {@code unavailableCapabilities}\npassed to the constructor are to be performed",
"Gets the Taneja divergence.\n\n@param p P vector.\n@param q Q vector.\n@return The Taneja divergence between p and q.",
"Creates a new RgbaColor from the specified HSL components.\n\n<p>\n<i>Implementation based on <a\nhref=\"http://en.wikipedia.org/wiki/HSL_and_HSV\">wikipedia</a>\nand <a\nhref=\"http://www.w3.org/TR/css3-color/#hsl-color\">w3c</a></i>\n\n@param H\nHue [0,360)\n@param S\nSaturation [0,100]\n@param L\nLightness [0,100]"
] |
private void logOriginalRequestHistory(String requestType,
HttpServletRequest request, History history) {
logger.info("Storing original request history");
history.setRequestType(requestType);
history.setOriginalRequestHeaders(HttpUtilities.getHeaders(request));
history.setOriginalRequestURL(request.getRequestURL().toString());
history.setOriginalRequestParams(request.getQueryString() == null ? "" : request.getQueryString());
logger.info("Done storing");
} | [
"Log original incoming request\n\n@param requestType\n@param request\n@param history"
] | [
"For internal use! This method creates real new PB instances",
"Orders first by word, then by tag.\n\n@param wordTag object to compare to\n@return result (positive if <code>this</code> is greater than\n<code>obj</code>, 0 if equal, negative otherwise)",
"Checks if this has the passed prefix\n\n@param prefix is a Bytes object to compare to this\n@return true or false\n@since 1.1.0",
"Handles Multi Channel Encapsulation message. Decapsulates\nan Application Command message and handles it using the right\nendpoint.\n@param serialMessage the serial message to process.\n@param offset the offset at which to start procesing.",
"returns an Array with an Objects PK VALUES\n@throws PersistenceBrokerException if there is an erros accessing o field values",
"Use this API to fetch all the dnspolicylabel resources that are configured on netscaler.",
"Returns the URL of the first route.\n@return URL backed by the first route.",
"Get the PropertyDescriptor for aClass and aPropertyName",
"Writes the content of an input stream to an output stream\n\n@throws IOException"
] |
private int getCostRateTableEntryIndex(Date date)
{
int result = -1;
CostRateTable table = getCostRateTable();
if (table != null)
{
if (table.size() == 1)
{
result = 0;
}
else
{
result = table.getIndexByDate(date);
}
}
return result;
} | [
"Retrieves the index of a cost rate table entry active on a given date.\n\n@param date target date\n@return cost rate table entry index"
] | [
"Handle unbind service event.\n@param service Service instance\n@param props Service reference properties",
"Probe the existing cluster to retrieve the current cluster xml and stores\nxml.\n\n@return Pair of Cluster and List<StoreDefinition> from current cluster.",
"Returns a compact representation of all of the subtasks of a task.\n\n@param task The task to get the subtasks of.\n@return Request object",
"Generates a set of excluded method names.\n\n@param methodNames method names\n@return set of method names",
"Resolves current full path with .yml and .yaml extensions\n\n@param fullpath\nwithout extension.\n\n@return Path of existing definition or null",
"Prepare a batch api request using list of individual reuests.\n@param requests list of api requests that has to be executed in batch.",
"Import user from file.",
"Send message to all connections of a certain user\n\n@param message the message to be sent\n@param username the username\n@return this context",
"End building the prepared script\n@param config the configuration for the script to build\n@return the new {@link LuaPreparedScript} instance"
] |
public Bundler put(String key, Bundle value) {
delegate.putBundle(key, value);
return this;
} | [
"Inserts a Bundle 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 Bundle object, or null\n@return this bundler instance to chain method calls"
] | [
"Makes object obj persistent in the underlying persistence system.\nE.G. by INSERT INTO ... or UPDATE ... in an RDBMS.\nThe ObjectModification parameter can be used to determine whether INSERT or update is to be used.\nThis functionality is typically called from transaction managers, that\ntrack which objects have to be stored. If the object is an unmaterialized\nproxy the method return immediately.",
"Answer the SQL-Clause for a SelectionCriteria\nIf the Criteria references a class with extents an OR-Clause is\nadded for each extent\n@param c SelectionCriteria",
"Process an individual work week day.\n\n@param data calendar data\n@param offset current offset into data\n@param week parent week\n@param day current day",
"Returns the rank of the decomposed matrix.\n\n@see SingularOps_DDRM#rank(SingularValueDecomposition_F64, double)\n\n@return The matrix's rank",
"Returns the primary port of the server.\n\n@return the primary {@link ServerPort} if the server is started. {@link Optional#empty()} otherwise.",
"Render json.\n\n@param o\nthe o\n@return the string",
"Set the background color of the progress spinner disc.\n\n@param colorRes Resource id of the color.",
"copied and altered from TransactionHelper",
"Create a unique signature for this shader.\nThe signature for simple shaders is just the class name.\nFor the more complex shaders generated by GVRShaderTemplate\nthe signature includes information about the vertex attributes,\nuniforms, textures and lights used by the shader variant.\n\n@param defined\nnames to be defined for this shader\n@return string signature for shader\n@see GVRShaderTemplate"
] |
public <T extends Widget & Checkable> List<T> getCheckableChildren() {
List<Widget> children = getChildren();
ArrayList<T> result = new ArrayList<>();
for (Widget c : children) {
if (c instanceof Checkable) {
result.add((T) c);
}
}
return result;
} | [
"Gets all Checkable widgets in the group\n@return list of Checkable widgets"
] | [
"Delete a license from the repository\n\n@param licName The name of the license to remove",
"If the burst mode is on, emit the particles only once.\n\n@param particlePositions\n@param particleVelocities\n@param particleTimeStamps",
"Count the number of queued resource requests for a specific pool.\n\n@param key The key\n@return The count of queued resource requests. Returns 0 if no queue\nexists for given key.",
"Use this API to fetch spilloverpolicy resource of given name .",
"Retrieve column font details from a block of property data.\n\n@param data property data\n@param offset offset into property data\n@param fontBases map of font bases\n@return ColumnFontStyle instance",
"get the underlying wrapped connection\n@return OTMConnection raw connection to the OTM.",
"Starts the animation with the given index.\n@param animIndex 0-based index of {@link GVRAnimator} to start;\n@see GVRAvatar#stop()\n@see #start(String)",
"Determine how many forked JVMs to use.",
"commit all envelopes against the current broker"
] |
public CodePage getCodePage(int field)
{
CodePage result;
if ((field < m_fields.length) && (m_fields[field].length() != 0))
{
result = CodePage.getInstance(m_fields[field]);
}
else
{
result = CodePage.getInstance(null);
}
return (result);
} | [
"Retrieves a CodePage instance. Defaults to ANSI.\n\n@param field the index number of the field to be retrieved\n@return the value of the required field"
] | [
"Create and return a new Violation for this rule and the specified import\n@param sourceCode - the SourceCode\n@param importNode - the ImportNode for the import triggering the violation\n@return a new Violation object",
"Add a listener to be invoked when the checked button changes in this group.\n@param listener\n@param <T>\n@return",
"Returns a presentable version of the given PTB-tokenized text.\nPTB tokenization splits up punctuation and does various other things\nthat makes simply joining the tokens with spaces look bad. So join\nthe tokens with space and run it through this method to produce nice\nlooking text. It's not perfect, but it works pretty well.\n\n@param ptbText A String in PTB3-escaped form\n@return An approximation to the original String",
"Adds OPT_D | OPT_DIR option to OptionParser, with one argument.\n\n@param parser OptionParser to be modified\n@param required Tells if this option is required or optional",
"Determines the offset code of a forward contract from a schedule. Rounds the average period length to full months.\n\n@param schedule The schedule.\n@return The offset code as String",
"Checks if the given String is null or contains only whitespaces.\nThe String is trimmed before the empty check.\n\n@param argument the String to check for null or emptiness\n@param argumentName the name of the argument to check.\nThis is used in the exception message.\n@return the String that was given as argument\n@throws IllegalArgumentException in case argument is null or empty",
"Either a single file extension or a comma-separated list of extensions for which the language\nshall be registered.",
"Given a parameter, builds a new parameter for which the known generics placeholders are resolved.\n@param genericFromReceiver resolved generics from the receiver of the message\n@param placeholdersFromContext, resolved generics from the method context\n@param methodParameter the method parameter for which we want to resolve generic types\n@param paramType the (unresolved) type of the method parameter\n@return a new parameter with the same name and type as the original one, but with resolved generic types",
"Fetch the outermost Hashmap as a TwoDHashMap.\n\n@param firstKey\nfirst key\n@return the the innermost hashmap"
] |
protected void writeEntries(final StorageAwareResource resource, final ZipOutputStream zipOut) throws IOException {
final BufferedOutputStream bufferedOutput = new BufferedOutputStream(zipOut);
ZipEntry _zipEntry = new ZipEntry("emf-contents");
zipOut.putNextEntry(_zipEntry);
try {
this.writeContents(resource, bufferedOutput);
} finally {
bufferedOutput.flush();
zipOut.closeEntry();
}
ZipEntry _zipEntry_1 = new ZipEntry("resource-description");
zipOut.putNextEntry(_zipEntry_1);
try {
this.writeResourceDescription(resource, bufferedOutput);
} finally {
bufferedOutput.flush();
zipOut.closeEntry();
}
if (this.storeNodeModel) {
ZipEntry _zipEntry_2 = new ZipEntry("node-model");
zipOut.putNextEntry(_zipEntry_2);
try {
this.writeNodeModel(resource, bufferedOutput);
} finally {
bufferedOutput.flush();
zipOut.closeEntry();
}
}
} | [
"Write entries into the storage.\nOverriding methods should first delegate to super before adding their own entries."
] | [
"Updates the story and returns the full record for the updated story.\nOnly comment stories can have their text updated, and only comment stories and\nattachment stories can be pinned. Only one of `text` and `html_text` can be specified.\n\n@param story Globally unique identifier for the story.\n@return Request object",
"Creates a new row with content with given cell context and a normal row style.\n@param content the content for the row, each member of the array represents the content for a cell in the row, must not be null but can contain null members\n@return a new row with content\n@throws {@link NullPointerException} if content was null",
"Set the weekdays at which the event should take place.\n@param weekDays the weekdays at which the event should take place.",
"Un-serialize a Json into Organization\n@param organization String\n@return Organization\n@throws IOException",
"Returns true if required properties for MiniFluo are set",
"Creates a new ServerDetails object for resolver, this will take URL and name from the deployer ServerDetails as a default behaviour",
"Returns the position for a given number of occurrences or NOT_FOUND if\nthis value is not found.\n\n@param nOccurrence\nnumber of occurrences\n@return the position for a given number of occurrences or NOT_FOUND if\nthis value is not found",
"Read a nested table whose contents we don't understand.\n\n@param rowSize fixed row size\n@param rowMagicNumber row magic number\n@return table rows",
"Returns the tags that were root in the definition files. These serve as entry point shortcuts when browsing the graph. We could reduce this to\njust fewer as the root tags may be connected through parents=\"...\"."
] |
public static String getTokenText(INode node) {
if (node instanceof ILeafNode)
return ((ILeafNode) node).getText();
else {
StringBuilder builder = new StringBuilder(Math.max(node.getTotalLength(), 1));
boolean hiddenSeen = false;
for (ILeafNode leaf : node.getLeafNodes()) {
if (!leaf.isHidden()) {
if (hiddenSeen && builder.length() > 0)
builder.append(' ');
builder.append(leaf.getText());
hiddenSeen = false;
} else {
hiddenSeen = true;
}
}
return builder.toString();
}
} | [
"This method converts a node to text.\n\nLeading and trailing text from hidden tokens (whitespace/comments) is removed. Text from hidden tokens that is\nsurrounded by text from non-hidden tokens is summarized to a single whitespace.\n\nThe preferred use case of this method is to convert the {@link ICompositeNode} that has been created for a data\ntype rule to text.\n\nThis is also the recommended way to convert a node to text if you want to invoke\n{@link org.eclipse.xtext.conversion.IValueConverterService#toValue(String, String, INode)}"
] | [
"Add parameter to testCase\n\n@param context which can be changed",
"Checks all data sets in a given record for constraint violations.\n\n@param record\nIIM record (1,2,3, ...) to check\n\n@return list of constraint violations, empty set if IIM file is valid",
"Evaluates the animation with the given index at the specified time.\n@param animIndex 0-based index of {@link GVRAnimator} to start\n@param timeInSec time to evaluate the animation at\n@see GVRAvatar#stop()\n@see #start(String)",
"Add calendars to the tree.\n\n@param parentNode parent tree node\n@param file calendar container",
"Prints out the interceptor chain in a format that is easy to read. It\nalso filters out instances of the DemoInterceptor so you can see what the\nchain would look like in a normal invokation.\n\n@param chain",
"Returns the current transaction for the calling thread.\n\n@throws org.odmg.TransactionNotInProgressException\n{@link org.odmg.TransactionNotInProgressException} if no transaction was found.",
"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",
"Returns the complete record for a single status update.\n\n@param projectStatus The project status update to get.\n@return Request object",
"Set the main attribute \"Bundle-RequiredExecutionEnvironment\" to the given\nvalue.\n\n@param bree The new value"
] |
protected void generateRoutes()
{
try {
// Optional<io.sinistral.proteus.annotations.Chain> typeLevelWrapAnnotation = Optional.ofNullable(controllerClass.getAnnotation(io.sinistral.proteus.annotations.Chain.class));
//
// typeLevelWrapAnnotation.ifPresent( a -> {
//
// io.sinistral.proteus.annotations.Chain w = typeLevelWrapAnnotation.get();
//
// Class<? extends HandlerWrapper> wrapperClasses[] = w.value();
//
// for (int i = 0; i < wrapperClasses.length; i++)
// {
// Class<? extends HandlerWrapper> wrapperClass = wrapperClasses[i];
//
// String wrapperName = generateFieldName(wrapperClass.getCanonicalName());
//
// handlerWrapperMap.put(wrapperClass, wrapperName);
// }
//
// });
//
// for(Method m : this.controllerClass.getDeclaredMethods())
// {
//
// Optional<io.sinistral.proteus.annotations.Chain> methodLevelWrapAnnotation = Optional.ofNullable(m.getAnnotation(io.sinistral.proteus.annotations.Chain.class));
//
// methodLevelWrapAnnotation.ifPresent( a -> {
//
// io.sinistral.proteus.annotations.Chain w = methodLevelWrapAnnotation.get();
//
// Class<? extends HandlerWrapper> wrapperClasses[] = w.value();
//
// for (int i = 0; i < wrapperClasses.length; i++)
// {
// Class<? extends HandlerWrapper> wrapperClass = wrapperClasses[i];
//
// String wrapperName = generateFieldName(wrapperClass.getCanonicalName());
//
// handlerWrapperMap.put(wrapperClass, wrapperName);
// }
//
// });
//
// }
//
// log.info("handlerWrapperMap: " + handlerWrapperMap);
TypeSpec.Builder typeBuilder = TypeSpec.classBuilder(className).addModifiers(Modifier.PUBLIC)
.addSuperinterface(ParameterizedTypeName.get(Supplier.class, RoutingHandler.class));
ClassName extractorClass = ClassName.get("io.sinistral.proteus.server", "Extractors");
ClassName injectClass = ClassName.get("com.google.inject", "Inject");
MethodSpec.Builder constructor = MethodSpec.constructorBuilder().addModifiers(Modifier.PUBLIC).addAnnotation(injectClass);
String className = this.controllerClass.getSimpleName().toLowerCase() + "Controller";
typeBuilder.addField(this.controllerClass, className, Modifier.PROTECTED, Modifier.FINAL);
ClassName wrapperClass = ClassName.get("io.undertow.server", "HandlerWrapper");
ClassName stringClass = ClassName.get("java.lang", "String");
ClassName mapClass = ClassName.get("java.util", "Map");
TypeName mapOfWrappers = ParameterizedTypeName.get(mapClass, stringClass, wrapperClass);
TypeName annotatedMapOfWrappers = mapOfWrappers
.annotated(AnnotationSpec.builder(com.google.inject.name.Named.class).addMember("value", "$S", "registeredHandlerWrappers").build());
typeBuilder.addField(mapOfWrappers, "registeredHandlerWrappers", Modifier.PROTECTED, Modifier.FINAL);
constructor.addParameter(this.controllerClass, className);
constructor.addParameter(annotatedMapOfWrappers, "registeredHandlerWrappers");
constructor.addStatement("this.$N = $N", className, className);
constructor.addStatement("this.$N = $N", "registeredHandlerWrappers", "registeredHandlerWrappers");
addClassMethodHandlers(typeBuilder, this.controllerClass);
typeBuilder.addMethod(constructor.build());
JavaFile javaFile = JavaFile.builder(packageName, typeBuilder.build()).addStaticImport(extractorClass, "*").build();
StringBuilder sb = new StringBuilder();
javaFile.writeTo(sb);
this.sourceString = sb.toString();
} catch (Exception e) {
log.error(e.getMessage(), e);
}
} | [
"Generates the routing Java source code"
] | [
"Updates value of entity in the table.",
"To read an object in a quick & dirty way. Prepare to handle failures when object serialization changes!",
"Check if the print has not been asked to stop taking new jobs.\n\n@return true if it's OK to take new jobs.",
"Parses the field facet configurations.\n@param fieldFacetObject The JSON sub-node with the field facet configurations.\n@return The field facet configurations.",
"will trigger workers to cancel then wait for it to report back.",
"Generates the cache key for Online links.\n@param cms the current CmsObject\n@param targetSiteRoot the target site root\n@param detailPagePart the detail page part\n@param absoluteLink the absolute (site-relative) link to the resource\n@return the cache key",
"Use this API to fetch tmtrafficpolicy_lbvserver_binding resources of given name .",
"Gets the or create protocol header.\n\n@param message the message\n@return the message headers map",
"Resets the text box by removing its content and resetting visual state."
] |
private void deliverTempoChangedAnnouncement(final double tempo) {
for (final MasterListener listener : getMasterListeners()) {
try {
listener.tempoChanged(tempo);
} catch (Throwable t) {
logger.warn("Problem delivering tempo changed announcement to listener", t);
}
}
} | [
"Send a tempo changed announcement to all registered master listeners.\n\n@param tempo the new master tempo"
] | [
"select a use case.",
"Gets JmsDestinationType from java class name\n\nReturns null for unrecognized class",
"Determine whether all references are available locally.\n\n@param domain the domain model\n@param hostElement the host path element\n@return whether to a sync with the master is required",
"Obtain the IDs of profile and path as Identifiers\n\n@param profileIdentifier actual ID or friendly name of profile\n@param pathIdentifier actual ID or friendly name of path\n@return\n@throws Exception",
"Use this API to fetch all the nd6ravariables resources that are configured on netscaler.",
"Sets an error message that will be displayed in a popup when the EditText has focus along\nwith an icon displayed at the right-hand side.\n\n@param error error message to show",
"Writes references that have been added recently. Auxiliary triples that\nare generated for serializing snaks in references will be written right\nafterwards. This will also trigger any other auxiliary triples to be\nwritten that the snak converter object may have buffered.\n\n@throws RDFHandlerException\nif there was a problem writing the restrictions",
"Answer true if an Iterator for a Table is already available\n@param aTable\n@return",
"Parses formatter attributes.\n\n@param formatterLoc the node location\n@return the map of formatter attributes (unmodifiable)"
] |
Subsets and Splits