query
stringlengths
74
6.1k
positive
sequencelengths
1
1
negative
sequencelengths
9
9
public String[] getReportSamples() { final Map<String, String> sampleValues = new HashMap<>(); sampleValues.put("name1", "Secure Transpiler Mars"); sampleValues.put("version1", "4.7.0"); sampleValues.put("name2", "Secure Transpiler Bounty"); sampleValues.put("version2", "5.0.0"); sampleValues.put("license", "CDDL-1.1"); sampleValues.put("name", "Secure Pretender"); sampleValues.put("version", "2.7.0"); sampleValues.put("organization", "Axway"); return ReportsRegistry.allReports() .stream() .map(report -> ReportUtils.generateSampleRequest(report, sampleValues)) .map(request -> { try { String desc = ""; final Optional<Report> byId = ReportsRegistry.findById(request.getReportId()); if(byId.isPresent()) { desc = byId.get().getDescription() + "<br/><br/>"; } return String.format(TWO_PLACES, desc, JsonUtils.serialize(request)); } catch(IOException e) { return "Error " + e.getMessage(); } }) .collect(Collectors.toList()) .toArray(new String[] {}); }
[ "Displays a sample model for the report request.\n@return A string describing the structure of a certain report execution" ]
[ "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", "Initializes context size.\n\n@param rectangle rectangle", "Gets an entry point for the given deployment. If one does not exist it will be created. If the request controller is disabled\nthis will return null.\n\nEntry points are reference counted. If this method is called n times then {@link #removeControlPoint(ControlPoint)}\nmust also be called n times to clean up the entry points.\n\n@param deploymentName The top level deployment name\n@param entryPointName The entry point name\n@return The entry point, or null if the request controller is disabled", "See also JLS8, 4.12.5 Initial Values of Variables.\n\n@param type\n@return the default value for the given type as defined by JLS", "Retrieves the default calendar for this project based on the calendar name\ngiven in the project properties. If a calendar of this name cannot be found, then\nthe first calendar listed for the project will be returned. If the\nproject contains no calendars, then a default calendar is added.\n\n@return default projectCalendar instance", "Returns the Map value of the field.\n\n@return the Map value of the field. It returns a reference of the value both for <code>MAP</code> and\n<code>LIST_MAP</code>.\n@throws IllegalArgumentException if the value cannot be converted to Map.", "Calculate the value of a digital caplet assuming the Black'76 model.\n\n@param forward The forward (spot).\n@param volatility The Black'76 volatility.\n@param periodLength The period length of the underlying forward rate.\n@param discountFactor The discount factor corresponding to the payment date (option maturity + period length).\n@param optionMaturity The option maturity\n@param optionStrike The option strike.\n@return Returns the price of a digital caplet under the Black'76 model", "Returns the y-coordinate of a vertex bitangent.\n\n@param vertex the vertex index\n@return the y coordinate", "Get a timer of the given string name and todos for the current thread. If\nno such timer exists yet, then it will be newly created.\n\n@param timerName\nthe name of the timer\n@param todoFlags\n@return timer" ]
public static nspbr6 get(nitro_service service, String name) throws Exception{ nspbr6 obj = new nspbr6(); obj.set_name(name); nspbr6 response = (nspbr6) obj.get_resource(service); return response; }
[ "Use this API to fetch nspbr6 resource of given name ." ]
[ "Returns the next object in the table.\n\n@throws IllegalStateException\nIf there was a problem extracting the object from SQL.", "From the set of classes a new set is built containing all indexed\nsubclasses, but removing then all subtypes of indexed entities.\n\n@param selection\n\n@return a new set of entities", "Use this API to disable Interface of given name.", "Convert a Java date into a Planner date.\n\n20070222\n\n@param value Java Date instance\n@return Planner date", "obtains the internal JDO lifecycle state of the input StatemanagerInternal.\nThis Method is helpful to display persistent objects internal state.\n@param sm the StateManager to be inspected\n@return the LifeCycleState of a StateManager instance", "Checks the given class descriptor for correct procedure settings.\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", "Attempt to detect the current platform.\n\n@return The current platform.\n\n@throws UnsupportedPlatformException if the platform cannot be detected.", "Get the currently selected opacity.\n\n@return The int value of the currently selected opacity.", "Check if position is in inner circle\n\n@param x x position\n@param y y position\n@return true if in inner circle, false otherwise" ]
public void doRun(Properties properties) { ServerSetup[] serverSetup = new PropertiesBasedServerSetupBuilder().build(properties); if (serverSetup.length == 0) { printUsage(System.out); } else { greenMail = new GreenMail(serverSetup); log.info("Starting GreenMail standalone v{} using {}", BuildInfo.INSTANCE.getProjectVersion(), Arrays.toString(serverSetup)); greenMail.withConfiguration(new PropertiesBasedGreenMailConfigurationBuilder().build(properties)) .start(); } }
[ "Start and configure GreenMail using given properties.\n\n@param properties the properties such as System.getProperties()" ]
[ "Use this API to fetch all the vpnsessionaction resources that are configured on netscaler.", "Computes the WordNet 2.0 POS tag corresponding to the PTB POS tag s.\n\n@param s a Penn TreeBank POS tag.", "The quick way to detect for a tier of devices.\nThis method detects for devices which are likely to be capable\nof viewing CSS content optimized for the iPhone,\nbut may not necessarily support JavaScript.\nExcludes all iPhone Tier devices.\n@return detection of any device in the 'Rich CSS' Tier", "Returns an iban with replaced check digit.\n\n@param iban The iban\n@return The iban without the check digit", "Validates a favorite entry.\n\n<p>If the favorite entry references a resource or project that can't be read, this will return false.\n\n@param entry the favorite entry\n@return the", "Adds the value to the Collection mapped to by the key.", "Set the value of the underlying component. Note that this will\nnot work for ListEditor components. Also, note that for a JComboBox,\nThe value object must have the same identity as an object in the drop-down.\n\n@param propName The DMR property name to set.\n@param value The value.", "Returns the item at the specified position.\n\n@param position index of the item to return\n@return the item at the specified position or {@code null} when not found", "A convenience method for creating an immutable sorted set.\n\n@param self a SortedSet\n@return an immutable SortedSet\n@see java.util.Collections#unmodifiableSortedSet(java.util.SortedSet)\n@since 1.0" ]
public static String[] addStringToArray(String[] array, String str) { if (isEmpty(array)) { return new String[]{str}; } String[] newArr = new String[array.length + 1]; System.arraycopy(array, 0, newArr, 0, array.length); newArr[array.length] = str; return newArr; }
[ "Append the given String to the given String array, returning a new array\nconsisting of the input array contents plus the given String.\n\n@param array the array to append to (can be <code>null</code>)\n@param str the String to append\n@return the new array (never <code>null</code>)" ]
[ "Process the host info and determine which configuration elements are required on the slave host.\n\n@param hostInfo the host info\n@param root the model root\n@param extensionRegistry the extension registry\n@return", "Fixed length fancy formatting for doubles. If possible decimal notation is used. If all the significant digits\ncan't be shown then it will switch to exponential notation. If not all the space is needed then it will\nbe filled in to ensure it has the specified length.\n\n@param value value being formatted\n@param format default format before exponential\n@param length Maximum number of characters it can take.\n@param significant Number of significant decimal digits to show at a minimum.\n@return formatted string", "Group results by the specified field.\n\n@param fieldName by which to group results\n@param isNumber whether field isNumeric.\n@return this for additional parameter setting or to query", "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", "Constraint that ensures that the field has a length if the jdbc type requires it.\n\n@param fieldDef The field descriptor\n@param checkLevel The current check level (this constraint is checked in all levels)", "Converts an object to an XML file.\n\n@param object The object to convert.\n@param fileName The filename where to save it to.\n@throws FileNotFoundException On error.", "Checks the given model.\n\n@param modelDef The model\n@param checkLevel The amount of checks to perform\n@exception ConstraintException If a constraint has been violated", "set custom response for the default profile's default client\n\n@param pathName friendly name of path\n@param customData custom response/request data\n@return true if success, false otherwise", "generate a message for loglevel WARN\n\n@param pObject the message Object" ]
public void executeInsert(ClassDescriptor cld, Object obj) throws PersistenceBrokerException { if (logger.isDebugEnabled()) { logger.debug("executeInsert: " + obj); } final StatementManagerIF sm = broker.serviceStatementManager(); PreparedStatement stmt = null; try { stmt = sm.getInsertStatement(cld); if (stmt == null) { logger.error("getInsertStatement returned a null statement"); throw new PersistenceBrokerException("getInsertStatement returned a null statement"); } // before bind values perform autoincrement sequence columns assignAutoincrementSequences(cld, obj); sm.bindInsert(stmt, cld, obj); if (logger.isDebugEnabled()) logger.debug("executeInsert: " + stmt); stmt.executeUpdate(); // after insert read and assign identity columns assignAutoincrementIdentityColumns(cld, obj); // Harvest any return values. harvestReturnValues(cld.getInsertProcedure(), obj, stmt); } catch (PersistenceBrokerException e) { logger.error("PersistenceBrokerException during the execution of the insert: " + e.getMessage(), e); throw e; } catch(SequenceManagerException e) { throw new PersistenceBrokerException("Error while try to assign identity value", e); } catch (SQLException e) { final String sql = broker.serviceSqlGenerator().getPreparedInsertStatement(cld).getStatement(); throw ExceptionHelper.generateException(e, sql, cld, logger, obj); } finally { sm.closeResources(stmt, null); } }
[ "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." ]
[ "Add a 'IS NOT NULL' clause so the column must not be null. '&lt;&gt;' NULL does not work.", "Reset the combination generator.", "Load a classifier from the specified InputStream. The classifier is\nreinitialized from the flags serialized in the classifier. This does not\nclose the InputStream.\n\n@param in\nThe InputStream to load the serialized classifier from\n@param props\nThis Properties object will be used to update the\nSeqClassifierFlags which are read from the serialized classifier\n\n@throws IOException\nIf there are problems accessing the input stream\n@throws ClassCastException\nIf there are problems interpreting the serialized data\n@throws ClassNotFoundException\nIf there are problems interpreting the serialized data", "Creates a new Box Developer Edition connection with App User token levaraging BoxConfig.\n@param userId the user ID to use for an App User.\n@param boxConfig box configuration settings object\n@return a new instance of BoxAPIConnection.", "Use this API to delete onlinkipv6prefix of given name.", "Add a property with the given name and the given list of values to this Properties object. Name\nand values are trimmed before the property is added.\n\n@param name the name of the property, must not be <code>null</code>.\n@param values the values of the property, must no be <code>null</code>,\nnone of the values must be <code>null</code>", "Finds and returns the date for the given event summary and year within the given ics file,\nor null if not present.", "Resets the text box by removing its content and resetting visual state.", "Read phases and activities from the Phoenix file to create the task hierarchy.\n\n@param phoenixProject all project data\n@param storepoint storepoint containing current project data" ]
public static void append(Path self, Object text) throws IOException { Writer writer = null; try { writer = new OutputStreamWriter(Files.newOutputStream(self, CREATE, APPEND), Charset.defaultCharset()); InvokerHelper.write(writer, text); writer.flush(); Writer temp = writer; writer = null; temp.close(); } finally { closeWithWarning(writer); } }
[ "Append the text at the end of the Path.\n\n@param self a Path\n@param text the text to append at the end of the Path\n@throws java.io.IOException if an IOException occurs.\n@since 2.3.0" ]
[ "Polls the next ParsedWord from the stack.\n\n@return next ParsedWord", "Gets the actual type arguments of a class\n\n@param clazz The class to examine\n@return The type arguments", "Parse currency.\n\n@param value currency value\n@return currency value", "This intro hides the system bars.", "Finish initializing.\n\n@throws GeomajasException oops", "Acquire the shared lock allowing the acquisition to be interrupted.\n@param permit - the permit Integer for this operation. May not be {@code null}.\n@throws InterruptedException - if the acquiring thread is interrupted.\n@throws IllegalArgumentException if {@code permit} is null.", "Joins with another IPv4 segment to produce a IPv6 segment.\n\n@param creator\n@param low\n@return", "Use this API to fetch all the nsacl6 resources that are configured on netscaler.", "Helper method to split a string by a given character, with empty parts omitted." ]
boolean lockShared(final Integer permit, final long timeout, final TimeUnit unit) { boolean result = false; try { result = lockSharedInterruptibly(permit, timeout, unit); } catch (InterruptedException e) { Thread.currentThread().interrupt(); } return result; }
[ "Attempts shared acquisition with a max wait time.\n@param permit - the permit Integer for this operation. May not be {@code null}.\n@param timeout - the time value to wait for acquiring the lock\n@param unit - See {@code TimeUnit} for valid values\n@return {@code boolean} true on success." ]
[ "Use this API to fetch sslvserver_sslcipher_binding resources of given name .", "Returns an HTML table containing the matrix of Strings passed in.\nThe first dimension of the matrix should represent the rows, and the\nsecond dimension the columns.", "Set the configuration property.\n\n@param key\n@param value\n@return self\n@see #ARCHIVE_ISOLATION_SYSTEM_PROPERTY\n@see #SHUTDOWN_HOOK_SYSTEM_PROPERTY\n@see #DEV_MODE_SYSTEM_PROPERTY\n@see ConfigurationKey", "Retrieve list of task extended attributes.\n\n@return list of extended attributes", "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)", "Set the start time.\n@param date the start time to set.", "Use this API to fetch authenticationvserver_authenticationradiuspolicy_binding resources of given name .", "Use this API to unset the properties of clusternodegroup resources.\nProperties that need to be unset are specified in args array.", "Uploads chunk of a stream to an open upload session.\n@param stream the stream that is used to read the chunck using the offset and part size.\n@param offset the byte position where the chunk begins in the file.\n@param partSize the part size returned as part of the upload session instance creation.\nOnly the last chunk can have a lesser value.\n@param totalSizeOfFile The total size of the file being uploaded.\n@return the part instance that contains the part id, offset and part size." ]
private void getSingleValue(Method method, Object object, Map<String, String> map) { Object value; try { value = filterValue(method.invoke(object)); } catch (Exception ex) { value = ex.toString(); } if (value != null) { map.put(getPropertyName(method), String.valueOf(value)); } }
[ "Retrieve a single value property.\n\n@param method method definition\n@param object target object\n@param map parameter values" ]
[ "Load the installation state based on the identity\n\n@param installedIdentity the installed identity\n@return the installation state\n@throws IOException", "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", "Method to know if already exists one file with the same name in the same\nfolder\n\n@param scenario_name\n@param path\n@param dest_dir\n@return true when the file does not exist", "Publish finish events for each of the specified query labels\n\n<pre>\n{@code\nLabelledEvents.start(\"get\", 1l, bus, \"typeA\", \"custom\");\ntry {\nreturn \"ok\";\n} finally {\nRequestEvents.finish(\"get\", 1l, bus, \"typeA\", \"custom\");\n}\n\n}\n</pre>\n\n\n@param query Completed query\n@param correlationId Identifier\n@param bus EventBus to post events to\n@param labels Query types to post to event bus", "Convert moneyness given as difference to par swap rate to moneyness in bp.\nUses the fixing times of the fix schedule to determine fractions.\n\n@param moneyness as offset.\n@return Moneyness in bp.", "Use this API to fetch all the route6 resources that are configured on netscaler.\nThis uses route6_args which is a way to provide additional arguments while fetching the resources.", "Logic for timestamp\n@param time Epoch date of creation\n@return String timestamp", "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", "Creates a clone using java serialization\n\n@param from Object to be cloned\n@param <T> type of the cloned object\n@return Clone of the object" ]
public static final String printResourceUID(Integer value) { ProjectFile file = PARENT_FILE.get(); if (file != null) { file.getEventManager().fireResourceWrittenEvent(file.getResourceByUniqueID(value)); } return (value.toString()); }
[ "Print a resource UID.\n\n@param value resource UID value\n@return resource UID string" ]
[ "Print a task type.\n\n@param value TaskType instance\n@return task type value", "Parses the supplied text and converts it to a Long\ncorresponding to that midnight in UTC on the specified date.\n\n@return null if it fails to parsing using the specified\nDateTimeFormat", "Generate the next permutation and return an array containing\nthe elements in the appropriate order.\n@see #nextPermutationAsArray(Object[])\n@see #nextPermutationAsList()\n@return The next permutation as an array.", "Checks if a newly created action wants to write output to stdout, and\nlogs a warning if other actions are doing the same.\n\n@param newAction\nthe new action to be checked", "Use this API to update dbdbprofile resources.", "Store the given data and return a uuid for later retrieval of the data\n\n@param data\n@return unique id for the stored data", "Set new list data set\n@param list new data set", "Returns a usage String based on the defined command and options.\nUseful when printing \"help\" info etc.", "Identifies the canonical type of an object heuristically.\n\n@return the canonical type identifier of the object's class\naccording to Jackson's type format (see {@link TypeFactory#constructFromCanonical(String)})" ]
private boolean findBinding(Injector injector, Class<?> type) { boolean found = false; for (Key<?> key : injector.getBindings().keySet()) { if (key.getTypeLiteral().getRawType().equals(type)) { found = true; break; } } if (!found && injector.getParent() != null) { return findBinding(injector.getParent(), type); } return found; }
[ "Finds binding for a type in the given injector and, if not found,\nrecurses to its parent\n\n@param injector\nthe current Injector\n@param type\nthe Class representing the type\n@return A boolean flag, <code>true</code> if binding found" ]
[ "Adds the contents of a Java package to this JAR.\n\n@param clazz a class whose package we wish to add to the JAR.\n@param filter a filter to select particular classes\n@return {@code this}", "Use this API to delete dnstxtrec resources.", "Get minimum gray value in the image.\n\n@param fastBitmap Image to be processed.\n@param startX Initial X axis coordinate.\n@param startY Initial Y axis coordinate.\n@param width Width.\n@param height Height.\n@return Minimum gray.", "Get unique values form the array.\n\n@param values Array of values.\n@return Unique values.", "Lift a Java Func0 to a Scala Function0\n\n@param f the function to lift\n\n@returns the Scala function", "Make sure the result index points to the next available key in the scan result, if exists.", "compute Cosh using Taylor Series.\n\n@param x An angle, in radians.\n@param nTerms Number of terms.\n@return Result.", "Encodes the given URI path segment with the given encoding.\n@param segment the segment to be encoded\n@param encoding the character encoding to encode to\n@return the encoded segment\n@throws UnsupportedEncodingException when the given encoding parameter is not supported", "Emit information about all of suite's tests." ]
protected Connection openConnection() throws IOException { // Perhaps this can just be done once? CallbackHandler callbackHandler = null; SSLContext sslContext = null; if (realm != null) { sslContext = realm.getSSLContext(); CallbackHandlerFactory handlerFactory = realm.getSecretCallbackHandlerFactory(); if (handlerFactory != null) { String username = this.username != null ? this.username : localHostName; callbackHandler = handlerFactory.getCallbackHandler(username); } } final ProtocolConnectionConfiguration config = ProtocolConnectionConfiguration.copy(configuration); config.setCallbackHandler(callbackHandler); config.setSslContext(sslContext); config.setUri(uri); AuthenticationContext authenticationContext = this.authenticationContext != null ? this.authenticationContext : AuthenticationContext.captureCurrent(); // Connect try { return authenticationContext.run((PrivilegedExceptionAction<Connection>) () -> ProtocolConnectionUtils.connectSync(config)); } catch (PrivilegedActionException e) { if (e.getCause() instanceof IOException) { throw (IOException) e.getCause(); } throw new IOException(e); } }
[ "Connect and register at the remote domain controller.\n\n@return connection the established connection\n@throws IOException" ]
[ "Used to parse the dividend dates. Returns null if the date cannot be\nparsed.\n\n@param date String received that represents the date\n@return Calendar object representing the parsed date", "Get the class name without the package\n\n@param c The class name with package\n@return the class name without the package", "Use this API to fetch all the dnstxtrec resources that are configured on netscaler.\nThis uses dnstxtrec_args which is a way to provide additional arguments while fetching the resources.", "Notifies that a content item is removed.\n\n@param position the position.", "Called to update the cached formats when something changes.", "Starts given docker machine.\n\n@param cliPathExec\nlocation of docker-machine or null if it is on PATH.\n@param machineName\nto be started.", "This must be called with the write lock held.\n@param requirement the requirement", "Send an album art update announcement to all registered listeners.", "Calculate where within the beat grid array the information for the specified beat can be found.\nYes, this is a super simple calculation; the main point of the method is to provide a nice exception\nwhen the beat is out of bounds.\n\n@param beatNumber the beat desired\n\n@return the offset of the start of our cache arrays for information about that beat" ]
private void processRedirect(String stringStatusCode, HttpMethod httpMethodProxyRequest, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) throws Exception { // Check if the proxy response is a redirect // The following code is adapted from // org.tigris.noodle.filters.CheckForRedirect // Hooray for open source software String stringLocation = httpMethodProxyRequest.getResponseHeader(STRING_LOCATION_HEADER).getValue(); if (stringLocation == null) { throw new ServletException("Received status code: " + stringStatusCode + " but no " + STRING_LOCATION_HEADER + " header was found in the response"); } // Modify the redirect to go to this proxy servlet rather than the proxied host String stringMyHostName = httpServletRequest.getServerName(); if (httpServletRequest.getServerPort() != 80) { stringMyHostName += ":" + httpServletRequest.getServerPort(); } stringMyHostName += httpServletRequest.getContextPath(); httpServletResponse.sendRedirect(stringLocation.replace( getProxyHostAndPort() + this.getProxyPath(), stringMyHostName)); }
[ "Execute a redirected request\n\n@param stringStatusCode\n@param httpMethodProxyRequest\n@param httpServletRequest\n@param httpServletResponse\n@throws Exception" ]
[ "Adds a listener to this collection.\n\n@param listener The listener to add", "Deletes the disabled marker file in the directory of the specified version.\n\n@param version to enable\n@throws PersistenceFailureException if the marker file could not be deleted (can happen if\nthe storage system has become read-only or is otherwise\ninaccessible).", "Checks if the given group of statements contains the given value as the\nvalue of a main snak of some statement.\n\n@param statementGroup\nthe statement group to scan\n@param value\nthe value to scan for\n@return true if value was found", "Convenience method to convert a CSV string list to a set. Note that this\nwill suppress duplicates.\n\n@param str the input String\n@return a Set of String entries in the list", "Use this API to update inat.", "Checks whether a built of the indices is necessary.\n@param cms The appropriate CmsObject instance.\n@return true, if the spellcheck indices have to be rebuilt, otherwise false", "Method used to write the name of the scenarios methods\n\n@param word\n@return the same word starting with lower case", "Just collapses digits to 9 characters.\nDoes lazy copying of String.\n\n@param s String to find word shape of\n@return The same string except digits are equivalence classed to 9.", "Add a Comparator to the end of the chain using the provided sort order.\n@param comparator the Comparator to add to the end of the chain\n@param ascending the sort order: ascending (true) or descending (false)" ]
public void seekToHolidayYear(String holidayString, String yearString) { Holiday holiday = Holiday.valueOf(holidayString); assert(holiday != null); seekToIcsEventYear(HOLIDAY_ICS_FILE, yearString, holiday.getSummary()); }
[ "Seeks to the given holiday within the given year\n\n@param holidayString\n@param yearString" ]
[ "Removes a value from the list box. Nothing is done if the value isn't on\nthe list box.\n\n@param value the value to be removed from the list\n@param reload perform a 'material select' reload to update the DOM.", "Generate the specified output file by merging the specified\nVelocity template with the supplied context.", "Standard doclet entry point\n@param root\n@return", "Do the search, called as a \"page action\"", "The selectionStrategy given as String argument is selected as locatorSelectionStrategy.\nIf selectionStrategy is null, the defaultLocatorSelectionStrategy is used instead.\nThen the new locatorSelectionStrategy is connected to the locatorClient and the matcher.\nA new LocatorTargetSelector is created, set to the locatorSelectionStrategy and then set\nas selector in the conduitSelectorHolder.\n\n@param conduitSelectorHolder\n@param matcher\n@param selectionStrategy", "Sets the values of this vector to those of v1.\n\n@param v1\nvector whose values are copied", "set ViewPager scroller to change animation duration when sliding", "Collect environment variables and system properties under with filter constrains", "Method indicating whether a day is a working or non-working day.\n\n@param day required day\n@return true if this is a working day" ]
public static aaauser_auditsyslogpolicy_binding[] get(nitro_service service, String username) throws Exception{ aaauser_auditsyslogpolicy_binding obj = new aaauser_auditsyslogpolicy_binding(); obj.set_username(username); aaauser_auditsyslogpolicy_binding response[] = (aaauser_auditsyslogpolicy_binding[]) obj.get_resources(service); return response; }
[ "Use this API to fetch aaauser_auditsyslogpolicy_binding resources of given name ." ]
[ "Return a long value which is the number of rows in the table.", "Writes the data collected about classes to a file.", "Returns an array of non null elements from the source array.\n\n@param tArray the source array\n@return the array", "Creates a new Message from the specified text.", "Generates a full list of all parents and their children, in order.\n\n@param parentList A list of the parents from\nthe {@link ExpandableRecyclerAdapter}\n@return A list of all parents and their children, expanded", "Get the real Class\n\n@param objectOrProxy\n@return Class", "Blocks until the server has started successfully or an exception is\nthrown.\n\n@throws VoldemortException if a problem occurs during start-up wrapping\nthe original exception.", "Get the bounding-box containing all features of all layers.", "Requests that the given namespace be started listening to for change events.\n\n@param namespace the namespace to listen for change events on." ]
public ColumnBuilder addFieldProperty(String propertyName, String value) { fieldProperties.put(propertyName, value); return this; }
[ "When the JRField needs properties, use this method.\n@param propertyName\n@param value\n@return" ]
[ "Check if the provided date or any date after it are part of the series.\n@param nextDate the current date to check.\n@param previousOccurrences the number of events of the series that took place before the date to check.\n@return <code>true</code> if more dates (including the provided one) could be in the series, <code>false</code> otherwise.", "replace the counter for K1-index o by new counter c", "Remove a collaborator from an app.\n@param appName App name. See {@link #listApps} for a list of apps that can be used.\n@param collaborator See {@link #listCollaborators} for collaborators that can be removed from the app.", "Decrements the client's use count, and makes it eligible for closing if it is no longer in use.\n\n@param client the dbserver connection client which is no longer being used for a task", "changes an existing property with the same name, or adds a new one\n@param key property name with which the specified value is to be\nassociated\n@param value value to be associated with the specified property name\n@return the previous value associated with property name, or null if\nthere was no mapping for property name. (A null return can also\nindicate that the map previously associated null with key.)", "Use this API to fetch all the route6 resources that are configured on netscaler.", "Generates a change event for a local insert of the given document in the given namespace.\n\n@param namespace the namespace where the document was inserted.\n@param document the document that was inserted.\n@return a change event for a local insert of the given document in the given namespace.", "Use this API to fetch a cmpglobal_cmppolicy_binding resources.", "Get the SPIProviderResolver instance using the provided classloader for lookup\n\n@param cl classloader to use for lookup\n@return instance of this class" ]
private List<Job> getJobs(final Jedis jedis, final String queueName, final long jobOffset, final long jobCount) throws Exception { final String key = key(QUEUE, queueName); final List<Job> jobs = new ArrayList<>(); if (JedisUtils.isDelayedQueue(jedis, key)) { // If delayed queue, use ZRANGEWITHSCORES final Set<Tuple> elements = jedis.zrangeWithScores(key, jobOffset, jobOffset + jobCount - 1); for (final Tuple elementWithScore : elements) { final Job job = ObjectMapperFactory.get().readValue(elementWithScore.getElement(), Job.class); job.setRunAt(elementWithScore.getScore()); jobs.add(job); } } else { // Else, use LRANGE final List<String> elements = jedis.lrange(key, jobOffset, jobOffset + jobCount - 1); for (final String element : elements) { jobs.add(ObjectMapperFactory.get().readValue(element, Job.class)); } } return jobs; }
[ "Get list of Jobs from a queue.\n\n@param jedis\n@param queueName\n@param jobOffset\n@param jobCount\n@return" ]
[ "Ensure the current throughput levels for the tracked operation does not\nexceed set quota limits. Throws an exception if exceeded quota.\n\n@param quotaKey\n@param trackedOp", "Last caller of this method will unregister the Mbean. All callers\ndecrement the counter.", "Make a copy of JobContext of current thread\n@return the copy of current job context or an empty job context", "Use this API to fetch all the ipset resources that are configured on netscaler.", "Retrieves a long value from the extended data.\n\n@param type Type identifier\n@return long value", "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.", "Sets whether an individual list value is selected.\n\n@param value the value of the item to be selected or unselected\n@param selected <code>true</code> to select the item", "Sets the SCXML model with an InputStream\n\n@param inputFileStream the model input stream", "Writes the buffer contents to the given byte channel.\n\n@param channel\n@throws IOException" ]
protected Object[] escape(final Format format, Object... args) { // Transformer that escapes HTML,XML,JSON strings Transformer<Object, Object> escapingTransformer = new Transformer<Object, Object>() { @Override public Object transform(Object object) { return format.escapeValue(object); } }; List<Object> list = Arrays.asList(ArrayUtils.clone(args)); CollectionUtils.transform(list, escapingTransformer); return list.toArray(); }
[ "Escapes args' string values according to format\n\n@param format the Format used by the PrintStream\n@param args the array of args to escape\n@return The cloned and escaped array of args" ]
[ "Use this API to update responderpolicy resources.", "Recursively builds the VFS entry bean for the quick filtering function in the folder tab.<p<\n\n@param resource the resource\n@param childMap map from parent to child resources\n@param filterMatches the resources matching the filter\n@param parentPaths root paths of resources which are not leaves\n@param isRoot true if this the root node\n\n@return the VFS entry bean for the client\n\n@throws CmsException if something goes wrong", "Set the row, column, and value\n\n@return this", "Removes top of thread-local shell stack.", "Sets no of currency digits.\n\n@param currDigs Available values, 0,1,2", "Retrieve the value of a UDF.\n\n@param udf UDF value holder\n@return UDF value", "Visit the implicit first frame of this method.", "Creates a new deployment for the URL. The target server will require access to the URL.\n\n@param url the URL representing the content\n\n@return the deployment", "Call this method to initialize the Fluo connection props\n\n@param conf Job configuration\n@param props Use {@link org.apache.fluo.api.config.FluoConfiguration} to set props\nprogrammatically" ]
private void setTaskNotes(Task task, byte[] data, ExtendedData taskExtData, FixDeferFix taskVarData) { String notes = taskExtData.getString(TASK_NOTES); if (notes == null && data.length == 366) { byte[] offsetData = taskVarData.getByteArray(getOffset(data, 362)); if (offsetData != null && offsetData.length >= 12) { notes = taskVarData.getString(getOffset(offsetData, 8)); // We do pick up some random stuff with this approach, and // we don't know enough about the file format to know when to ignore it // so we'll use a heuristic here to ignore anything that // doesn't look like RTF. if (notes != null && notes.indexOf('{') == -1) { notes = null; } } } if (notes != null) { if (m_reader.getPreserveNoteFormatting() == false) { notes = RtfHelper.strip(notes); } task.setNotes(notes); } }
[ "There appear to be two ways of representing task notes in an MPP8 file.\nThis method tries to determine which has been used.\n\n@param task task\n@param data task data\n@param taskExtData extended task data\n@param taskVarData task var data" ]
[ "Updates the date and time formats.\n\n@param properties project properties", "Checks to see if a WORD matches the name of a macro. if it does it applies the macro at that location", "Create User Application Properties\nCreate application properties for a user\n@param userId User Id (required)\n@param properties Properties to be updated (required)\n@param aid Application ID (optional)\n@return PropertiesEnvelope\n@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body", "Retrieve configuration details for a given custom field.\n\n@param field required custom field\n@return configuration detail", "Go over the task list and create a map of stealerId -> Tasks\n\n@param sbTaskList List of all stealer-based rebalancing tasks to be\nscheduled.", "Read the parameters on initialization.\n\n@see org.apache.solr.update.processor.UpdateRequestProcessorFactory#init(org.apache.solr.common.util.NamedList)", "Checks attributes for rejection\n\n@param rejectedAttributes gathers information about failed attributes\n@param attributeValue the attribute value", "Obtains a local date in International Fixed 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 International Fixed local date, not null\n@throws DateTimeException if unable to create the date", "Attempts to substitute all the found expressions in the input\nwith their corresponding resolved values.\nIf any of the found expressions failed to resolve or\nif the input does not contain any expression, the input is returned as is.\n\n@param input the input string\n@return the input with resolved expressions or the original input in case\nthe input didn't contain any expressions or at least one of the\nexpressions could not be resolved" ]
public static String[] copyArrayCutFirst(String[] arr) { if(arr.length > 1) { String[] arrCopy = new String[arr.length - 1]; System.arraycopy(arr, 1, arrCopy, 0, arrCopy.length); return arrCopy; } else { return new String[0]; } }
[ "Utility function that copies a string array except for the first element\n\n@param arr Original array of strings\n@return Copied array of strings" ]
[ "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.", "Creates a method signature.\n\n@param method Method instance\n@return method signature", "The keywords to include in the PDF metadata.\n\n@param keywords the keywords of the PDF.", "Pick arbitrary wrapping method. No generics should be set.\n@param builder", "Helper method fro providers to fire hotkey event in a separate thread\n\n@param hotKey hotkey to fire", "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", "Execute the transactional flow - catch only specified exceptions\n\n@param input Initial data input\n@param classes Exception types to catch\n@return Try that represents either success (with result) or failure (with errors)", "Parses a duration and returns the corresponding number of milliseconds.\n\nDurations consist of a space-separated list of components of the form {number}{time unit},\nfor example 1d 5m. The available units are d (days), h (hours), m (months), s (seconds), ms (milliseconds).<p>\n\n@param durationStr the duration string\n@param defaultValue the default value to return in case the pattern does not match\n@return the corresponding number of milliseconds", "Convert to IPv6 EUI-64 section\n\nhttp://standards.ieee.org/develop/regauth/tut/eui64.pdf\n\n@param asMAC if true, this address is considered MAC and the EUI-64 is extended using ff-ff, otherwise this address is considered EUI-48 and extended using ff-fe\nNote that IPv6 treats MAC as EUI-48 and extends MAC to IPv6 addresses using ff-fe\n@return" ]
public static int wavelengthToRGB(float wavelength) { float gamma = 0.80f; float r, g, b, factor; int w = (int)wavelength; if (w < 380) { r = 0.0f; g = 0.0f; b = 0.0f; } else if (w < 440) { r = -(wavelength - 440) / (440 - 380); g = 0.0f; b = 1.0f; } else if (w < 490) { r = 0.0f; g = (wavelength - 440) / (490 - 440); b = 1.0f; } else if (w < 510) { r = 0.0f; g = 1.0f; b = -(wavelength - 510) / (510 - 490); } else if (w < 580) { r = (wavelength - 510) / (580 - 510); g = 1.0f; b = 0.0f; } else if (w < 645) { r = 1.0f; g = -(wavelength - 645) / (645 - 580); b = 0.0f; } else if (w <= 780) { r = 1.0f; g = 0.0f; b = 0.0f; } else { r = 0.0f; g = 0.0f; b = 0.0f; } // Let the intensity fall off near the vision limits if (380 <= w && w <= 419) factor = 0.3f + 0.7f*(wavelength - 380) / (420 - 380); else if (420 <= w && w <= 700) factor = 1.0f; else if (701 <= w && w <= 780) factor = 0.3f + 0.7f*(780 - wavelength) / (780 - 700); else factor = 0.0f; int ir = adjust(r, factor, gamma); int ig = adjust(g, factor, gamma); int ib = adjust(b, factor, gamma); return 0xff000000 | (ir << 16) | (ig << 8) | ib; }
[ "Convert a wavelength to an RGB value.\n@param wavelength wavelength in nanometres\n@return the RGB value" ]
[ "Put a new value in map.\n\n@param key id of the value for looking up.\n@param value the value.", "If an error is thrown while loading zone data, the exception is logged\nto system error and null is returned for this and all future requests.\n\n@param id the id to load\n@return the loaded zone", "Checks if user exists.\n\n@param userId the user id, which can be an email or the login.\n@return true, if user exists.", "Puts a new document in the service. The generate key is globally unique.\n\n@param document document\n@return key unique key to reference the document", "Return collection of path Ids in priority order\n\n@param profileId ID of profile\n@return collection of path Ids in priority order", "Removes an Object from the cache.", "Returns the class of datatype URI that best characterizes the range of\nthe given property based on its datatype.\n\n@param propertyIdValue\nthe property for which to get a range\n@return the range URI or null if the datatype could not be identified.", "Inserts the currently contained data objects into the database.\n\n@param platform The (connected) database platform for inserting data\n@param model The database model\n@param batchSize The batch size; use 1 for not using batch mode", "Creates multiple aliases at once." ]
public static appfwpolicylabel_stats get(nitro_service service, String labelname) throws Exception{ appfwpolicylabel_stats obj = new appfwpolicylabel_stats(); obj.set_labelname(labelname); appfwpolicylabel_stats response = (appfwpolicylabel_stats) obj.stat_resource(service); return response; }
[ "Use this API to fetch statistics of appfwpolicylabel_stats resource of given name ." ]
[ "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", "Serializes any char sequence and writes it into specified buffer.", "Returns true if a Map literal that contains only entries where both key and value are constants.\n@param expression - any expression", "Read an int from the byte array starting at the given offset\n\n@param bytes The byte array to read from\n@param offset The offset to start reading at\n@return The int read", "Sets a string-valued additional info entry on the user.\n\n@param username the name of the user\n@param infoName the additional info key\n@param value the additional info value\n\n@throws CmsException if something goes wrong", "Will start the HiveServer.\n\n@param testConfig Specific test case properties. Will be merged with the HiveConf of the context\n@param hiveVars HiveVars to pass on to the HiveServer for this session", "Split string content into list, ignoring matches of the pattern\n@param content String content\n@param ignorePattern Pattern to ignore\n@return list", "Adds a license to an artifact if the license exist into the database\n\n@param gavc String\n@param licenseId String", "Converts a Fluo Span to Accumulo Range\n\n@param span Span\n@return Range" ]
static JobContext copy() { JobContext current = current_.get(); //JobContext ctxt = new JobContext(keepParent ? current : null); JobContext ctxt = new JobContext(null); if (null != current) { ctxt.bag_.putAll(current.bag_); } return ctxt; }
[ "Make a copy of JobContext of current thread\n@return the copy of current job context or an empty job context" ]
[ "Add statistics about a created map.\n\n@param mapContext the\n@param mapValues the", "Returns the size of the shadow element", "Creates a field map for tasks.\n\n@param props props data", "Sets the value for the API's \"languages\" parameter based on the current\nsettings.\n\n@param properties\ncurrent setting of parameters", "Retrieve configuration details for a given custom field.\n\n@param field required custom field\n@return configuration detail", "Returns the list of store defs as a map\n\n@param storeDefs\n@return", "This method works as the one above, adding some properties to the message\n\n@param agent_name\nThe id of the agents that receive the message\n@param msgtype\n@param message_content\nThe content of the message\n@param properties\nto be added to the message\n@param connector\nThe connector to get the external access", "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", "Looks up a variable given its name. If none is found then return null." ]
public static final Rect getViewportBounds() { return new Rect(Window.getScrollLeft(), Window.getScrollTop(), Window.getClientWidth(), Window.getClientHeight()); }
[ "This takes into account scrolling and will be in absolute\ncoordinates where the top left corner of the page is 0,0 but\nthe viewport may be scrolled to something else." ]
[ "Used to get the current repository key\n@return keyFromText or keyFromSelect reflected by the dynamicMode flag", "Write the config to the writer.", "Use this API to change appfwsignatures.", "Calculate the Hamming distance between two hashes\n\n@param h1\n@param h2\n@return", "Retrieves a byte value from the property data.\n\n@param type Type identifier\n@return byte value", "Retrieve a FieldType instance based on an ID value from\nan MPP9 or MPP12 file.\n\n@param fieldID field ID\n@return FieldType instance", "Use this API to update gslbservice resources.", "Magnitude of complex number.\n\n@param z Complex number.\n@return Magnitude of complex number.", "Formats the supplied value using the specified DateTimeFormat.\n\n@return \"\" if the value is null" ]
public synchronized void addShutdownListener(ShutdownListener listener) { if (state == CLOSED) { listener.handleCompleted(); } else { listeners.add(listener); } }
[ "Add a shutdown listener, which gets called when all requests completed on shutdown.\n\n@param listener the shutdown listener" ]
[ "List all the environment variables for an app.\n@param appName App name. See {@link #listApps} for a list of apps that can be used.\n@return map of config vars", "Utility method to remove ampersands embedded in names.\n\n@param name name text\n@return name text without embedded ampersands", "Creates a slice for directly a raw memory address. This is\ninherently unsafe as it may be used to access arbitrary memory.\n\n@param address the raw memory address base\n@param size the size of the slice\n@return the unsafe slice", "Returns the list view of corporate groupIds of an organization\n\n@param organizationId String\n@return ListView", "Convenience method to escape any character that is special to the regex system.\n\n@param inString\nthe string to fix\n\n@return the fixed string", "Inserts a vertex into this list before another specificed vertex.", "Calculate a cache key.\n@param sql to use\n@param columnIndexes to use\n@return cache key to use.", "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", "Use this API to fetch all the systemsession resources that are configured on netscaler." ]
public static boolean isFileExist(String filePath) { if (StringUtils.isEmpty(filePath)) { return false; } File file = new File(filePath); return (file.exists() && file.isFile()); }
[ "Indicates if this file represents a file on the underlying file system.\n\n@param filePath\n@return" ]
[ "Serializes this RuleSet in an XML document.\n\n@param destination The writer to which the XML document shall be written.", "Create an index of base font numbers and their associated base\nfont instances.\n@param data property data", "Use this API to update ntpserver.", "Counts the amount of 'ch' at the start of this line optionally ignoring\nspaces.\n\n@param ch\nThe char to count.\n@param allowSpaces\nWhether to allow spaces or not\n@return Number of characters found.\n@since 0.12", "Set HTTP headers to allow caching for the given number of seconds.\n\n@param response where to set the caching settings\n@param seconds number of seconds into the future that the response should be cacheable for", "Use this API to fetch dnssuffix resource of given name .", "Open an OutputStream and execute the function using the OutputStream.\n\n@param function the function to execute\n@return the URI and the file size", "Create an index of base font numbers and their associated base\nfont instances.\n@param data property data", "Sets a header per-request\n\n@param key Header key\n@param value Header value\n@return The request itself" ]
private static void writeUtf16Bom(OutputStream stream, boolean bigEndian) throws IOException { if (bigEndian) { stream.write(-2); stream.write(-1); } else { stream.write(-1); stream.write(-2); } }
[ "Write a Byte Order Mark at the beginning of the file\n\n@param stream the FileOutputStream to write the BOM to\n@param bigEndian true if UTF 16 Big Endian or false if Low Endian\n@throws IOException if an IOException occurs.\n@since 1.0" ]
[ "This logic is shared for all actual types i.e. raw types, parameterized types and generic array types.", "Creates a new remote proxy controller using an existing channel.\n\n@param channelAssociation the channel association\n@param pathAddress the address within the model of the created proxy controller\n@param addressTranslator the translator to use translating the address for the remote proxy\n@return the proxy controller\n\n@deprecated only present for test case use", "Adds BETWEEN criteria,\ncustomer_id between 1 and 10\n\n@param attribute The field name to be used\n@param value1 The lower boundary\n@param value2 The upper boundary", "Hardcode a copy method as being valid. This should be used to tell Mutability Detector about\na method which copies a collection, and when the copy can be wrapped in an immutable wrapper\nwe can consider the assignment immutable. Useful for allowing Mutability Detector to correctly\nwork with other collections frameworks such as Google Guava. Reflection is used to obtain the\nmethod's descriptor and to verify the method's existence.\n\n@param fieldType - the type of the field to which the result of the copy is assigned\n@param fullyQualifiedMethodName - the fully qualified method name\n@param argType - the type of the argument passed to the copy method\n\n@throws MutabilityAnalysisException - if the specified class or method does not exist\n@throws IllegalArgumentException - if any of the arguments are null", "Copy the data from an InputStream to a temp file.\n\n@param inputStream data source\n@param tempFileSuffix suffix to use for temp file\n@return File instance", "Creates an appropriate HSGE for a domain-wide resource of a type that is mappable to server groups", "Watches specified IDs in a collection.\n@param ids the ids to watch.\n@return the stream of change events.", "Flush output streams.", "Processes an index descriptor tag.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException If an error occurs\[email protected] type=\"content\"\[email protected] name=\"documentation\" optional=\"true\" description=\"Documentation on the index\"\[email protected] name=\"fields\" optional=\"false\" description=\"The fields making up the index separated by commas\"\[email protected] name=\"name\" optional=\"false\" description=\"The name of the index descriptor\"\[email protected] name=\"unique\" optional=\"true\" description=\"Whether the index descriptor is unique\" values=\"true,false\"" ]
public final void setDefaultStyle(final Map<String, Style> defaultStyle) { this.defaultStyle = new HashMap<>(defaultStyle.size()); for (Map.Entry<String, Style> entry: defaultStyle.entrySet()) { String normalizedName = GEOMETRY_NAME_ALIASES.get(entry.getKey().toLowerCase()); if (normalizedName == null) { normalizedName = entry.getKey().toLowerCase(); } this.defaultStyle.put(normalizedName, entry.getValue()); } }
[ "Set the default styles. the case of the keys are not important. The retrieval will be case\ninsensitive.\n\n@param defaultStyle the mapping from geometry type name (point, polygon, etc...) to the style\nto use for that type." ]
[ "Attempts to insert a colon so that a value without a colon can\nbe parsed.", "Permanently deletes a trashed folder.\n@param folderID the ID of the trashed folder to permanently delete.", "Parse a date value.\n\n@param value String representation\n@return Date instance", "Return the authorization URL which is used to perform the authorization_code based OAuth2 flow.\n@param clientID the client ID to use with the connection.\n@param redirectUri the URL to which Box redirects the browser when authentication completes.\n@param state the text string that you choose.\nBox sends the same string to your redirect URL when authentication is complete.\n@param scopes this optional parameter identifies the Box scopes available\nto the application once it's authenticated.\n@return the authorization URL", "Initialize new instance\n@param instance\n@param logger\n@param auditor", "Executes the given supplier within the context of a read lock.\n\n@param <E> The result type.\n@param sup The supplier.\n@return The result of {@link Supplier#get()}.", "Searches for all annotations of the given type on this method or on type level for all interfaces and superclasses\n\n@param method the method to scan\n@param annotation the annotation to search for\n@param <T> the type of the annotation\n@return the list of all method or type level annotations in the type hierarchy", "Use this API to update csparameter.", "Gets the file from which boot operations should be parsed.\n@return the file. Will not be {@code null}" ]
public static BeanManager getBeanManager(Object ctx) { return (BeanManager) javax.portlet.PortletContext.class.cast(ctx).getAttribute(WeldServletLifecycle.BEAN_MANAGER_ATTRIBUTE_NAME); }
[ "Get bean manager from portlet context.\n\n@param ctx the portlet context\n@return bean manager if found" ]
[ "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.", "Execute JavaScript in the browser.\n\n@param code The code to execute.\n@return The return value of the JavaScript.\n@throws CrawljaxException when javascript execution failed.", "Used to determine if multiple cost rates apply to this assignment.\n\n@return true if multiple cost rates apply to this assignment", "Gets the groupby for ReportQueries of all Criteria and Sub Criteria\nthe elements are of class FieldHelper\n@return List of FieldHelper", "create an instance from the className\n@param <E> class of object\n@param className full class name\n@return an object or null if className is null", "Adds a resource collection with execution hints.", "Use this API to unset the properties of snmpoption resource.\nProperties that need to be unset are specified in args array.", "Clear out our DAO caches.", "We have received an update that invalidates the waveform preview for a player, so clear it and alert\nany listeners if this represents a change. This does not affect the hot cues; they will stick around until the\nplayer loads a new track that overwrites one or more of them.\n\n@param update the update which means we have no waveform preview for the associated player" ]
private void stop() { for (int i = 0; i < mDownloadDispatchers.length; i++) { if (mDownloadDispatchers[i] != null) { mDownloadDispatchers[i].quit(); } } }
[ "Stops download dispatchers." ]
[ "Configure the HTTP response to switch off caching.\n\n@param response response to configure\n@since 1.9.0", "Set the serial pattern type.\n@param patternType the pattern type to set.", "Add the collection of elements to this collection. This will also them to the associated database table.\n\n@return Returns true if any of the items did not already exist in the collection otherwise false.", "Creates the operation to add a resource.\n\n@param address the address of the operation to add.\n@param properties the properties to set for the resource.\n\n@return the operation.", "Read the top level tasks from GanttProject.\n\n@param gpProject GanttProject project", "Gets a SerialMessage with the BASIC SET command\n@param the level to set.\n@return the serial message", "Sets the debug JPDA remote socket debugging argument.\n\n@param suspend {@code true} to suspend otherwise {@code false}\n@param port the port to listen on\n\n@return the builder", "To sql pattern.\n\n@param attribute the attribute\n@return the string", "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" ]
public void saveFile(File file, String type) { try { Class<? extends ProjectWriter> fileClass = WRITER_MAP.get(type); if (fileClass == null) { throw new IllegalArgumentException("Cannot write files of type: " + type); } ProjectWriter writer = fileClass.newInstance(); writer.write(m_projectFile, file); } catch (Exception ex) { throw new RuntimeException(ex); } }
[ "Save the current file as the given type.\n\n@param file target file\n@param type file type" ]
[ "Internal method used to retrieve a integer from an\nembedded data block.\n\n@param blocks list of data blocks\n@return int value", "Find the fields in which the Activity ID and Activity Type are stored.", "Get a collection of Photo objects for the specified Photoset.\n\nThis method does not require authentication.\n\n@see com.flickr4java.flickr.photos.Extras\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_NO_FILTER\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_PUBLIC\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FRIENDS\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FRIENDS_FAMILY\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FAMILY\n@see com.flickr4java.flickr.Flickr#PRIVACY_LEVEL_FRIENDS\n@param photosetId\nThe photoset ID\n@param extras\nSet of extra-fields\n@param privacy_filter\nfilter value for authenticated calls\n@param perPage\nThe number of photos per page\n@param page\nThe page offset\n@return PhotoList The Collection of Photo objects\n@throws FlickrException", "Returns the effective batch size. If the dialect is multiget capable and a batch size has been configured, use\nthat one, otherwise the default.", "Encodes the given URI host with the given encoding.\n@param host the host to be encoded\n@param encoding the character encoding to encode to\n@return the encoded host\n@throws UnsupportedEncodingException when the given encoding parameter is not supported", "Add a task to the project.\n\n@return new task instance", "Creates a curator built using Fluo's zookeeper connection string. Root path will start at Fluo\nchroot.", "Checks if is file exist.\n\n@param filePath\nthe file path\n@return true, if is file exist", "Rethrows platform specific OperationCanceledExceptions and unwraps OperationCanceledErrors. Does nothing for any other type of Throwable." ]
protected OJBIterator getIteratorFromQuery(Query query, ClassDescriptor cld) throws PersistenceBrokerException { RsIteratorFactory factory = RsIteratorFactoryImpl.getInstance(); OJBIterator result = getRsIteratorFromQuery(query, cld, factory); if (query.usePaging()) { result = new PagingIterator(result, query.getStartAtIndex(), query.getEndAtIndex()); } return result; }
[ "Get an extent aware Iterator based on the Query\n\n@param query\n@param cld the ClassDescriptor\n@return OJBIterator" ]
[ "Set whether the player holding the waveform is playing, which changes the indicator color to white from red.\nThis method can only be used in situations where the component is tied to a single player, and therefore has\na single playback position.\n\n@param playing if {@code true}, draw the position marker in white, otherwise red\n\n@see #setPlaybackState", "Helper to read an optional Boolean value.\n@param path The XML path of the element to read.\n@return The Boolean value stored in the XML, or <code>null</code> if the value could not be read.", "Returns the result of calling a closure with the first occurrence of a regular expression found within a CharSequence.\nIf the regex doesn't match, the closure will not be called and find will return null.\n\n@param self a CharSequence\n@param regex the capturing regex CharSequence\n@param closure the closure that will be passed the full match, plus each of the capturing groups (if any)\n@return a String containing the result of calling the closure (calling toString() if needed), or null if the regex pattern doesn't match\n@see #find(String, java.util.regex.Pattern, groovy.lang.Closure)\n@since 1.8.2", "Adds a node to this graph.\n\n@param node the node", "If UPDATE, INSERT or DELETE, return BatchPreparedStatement,\notherwise return null.", "Processes the template if the property value of the current object on the specified level equals the given value.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException If an error occurs\[email protected] type=\"block\"\[email protected] name=\"level\" optional=\"false\" description=\"The level for the current object\"\nvalues=\"class,field,reference,collection\"\[email protected] name=\"name\" optional=\"false\" description=\"The name of the property\"\[email protected] name=\"value\" optional=\"false\" description=\"The value to check for\"\[email protected] name=\"default\" optional=\"true\" description=\"A default value to use if the property\nis not defined\"", "Visits a method instruction. A method instruction is an instruction that\ninvokes a method.\n\n@param opcode\nthe opcode of the type instruction to be visited. This opcode\nis either INVOKEVIRTUAL, INVOKESPECIAL, INVOKESTATIC or\nINVOKEINTERFACE.\n@param owner\nthe internal name of the method's owner class (see\n{@link Type#getInternalName() getInternalName}).\n@param name\nthe method's name.\n@param desc\nthe method's descriptor (see {@link Type Type}).\n@param itf\nif the method's owner class is an interface.", "This method reads a byte array from the input stream.\n\n@param is the input stream\n@param size number of bytes to read\n@return byte array\n@throws IOException on file read error or EOF", "simple echo implementation" ]
public static void removeFromList(List<String> list, String value) { int foundIndex = -1; int i = 0; for (String id : list) { if (id.equalsIgnoreCase(value)) { foundIndex = i; break; } i++; } if (foundIndex != -1) { list.remove(foundIndex); } }
[ "Removes a value from the list.\n\n@param list the list\n@param value value to remove" ]
[ "Updates a metadata classification on the specified file.\n\n@param classificationType the metadata classification type.\n@return the new metadata classification type updated on the file.", "Write exceptions into the format used by MSPDI files from\nProject 2007 onwards.\n\n@param calendar parent calendar\n@param exceptions list of exceptions", "Looks for sequences of integer lists and combine them into one big sequence", "Produces or returns the existing proxy class. The operation is thread-safe.\n\n@return always the class of the proxy", "Adds an alias to the currently configured site.\n\n@param alias the URL of the alias server\n@param redirect <code>true</code> to always redirect to main URL\n@param offset the optional time offset for this alias", "Should be called each frame.", "Use this API to add nspbr6.", "Create an LBuffer from a given file.\n@param file\n@return\n@throws IOException", "Return the parent outline number, or an empty string if\nwe have a root task.\n\n@param outlineNumber child outline number\n@return parent outline number" ]
private static String firstFoundTableName(PersistenceBroker brokerForClass, ClassDescriptor cld) { String name = null; if (!cld.isInterface() && cld.getFullTableName() != null) { return cld.getFullTableName(); } if (cld.isExtent()) { Collection extentClasses = cld.getExtentClasses(); for (Iterator iterator = extentClasses.iterator(); iterator.hasNext();) { name = firstFoundTableName(brokerForClass, brokerForClass.getClassDescriptor((Class) iterator.next())); // System.out.println("## " + cld.getClassNameOfObject()+" - name: "+name); if (name != null) break; } } return name; }
[ "try to find the first none null table name for the given class-descriptor.\nIf cld has extent classes, all of these cld's searched for the first none null\ntable name." ]
[ "Lists the buildpacks installed on an app\n\n@param appName See {@link #listApps} for a list of apps that can be used.", "Adds a property to report design, this properties are mostly used by\nexporters to know if any specific configuration is needed\n\n@param name\n@param value\n@return A Dynamic Report Builder", "Deletes the VFS XML bundle file.\n@throws CmsException thrown if the delete operation fails.", "Returns the given collection persister for the inverse side in case the given persister represents the main side\nof a bi-directional many-to-many association.\n\n@param mainSidePersister the collection persister on the main side of a bi-directional many-to-many association\n@return the collection persister for the inverse side of the given persister or {@code null} in case it\nrepresents the inverse side itself or the association is uni-directional", "A helper - in Java 9, the extension CL was renamed to platform CL and hosts all the JDK classes. Before 9, it was useless and we used\nbootstrap CL instead.\n\n@return the base CL to use.", "Sets any application-specific custom fields. The values\nare presented to the application and the iPhone doesn't\ndisplay them automatically.\n\nThis can be used to pass specific values (urls, ids, etc) to\nthe application in addition to the notification message\nitself.\n\n@param key the custom field name\n@param value the custom field value\n@return this", "The sniffing Loggers are some special Loggers, whose level will be set to TRACE forcedly.\n@param logger", "Sorts the row indices in ascending order.\n@param sorter (Optional) Used to sort rows. If null a new instance will be declared internally.", "Returns the configured extra parameters that should be given to Solr, or the empty string if no parameters are configured.\n@return The configured extra parameters that should be given to Solr, or the empty string if no parameters are configured." ]
public Long getLong(String fieldName) { try { return hasValue(fieldName) ? Long.valueOf(String.valueOf(resultMap.get(fieldName))) : null; } catch (NumberFormatException e) { throw new FqlException("Field '" + fieldName +"' is not a number.", e); } }
[ "Returns the value of the identified field as a Long.\n@param fieldName the name of the field\n@return the value of the field as a Long\n@throws FqlException if the field cannot be expressed as an Long" ]
[ "Sets the width and height of the canvas the text is drawn to.\n\n@param width\nwidth of the new canvas.\n\n@param height\nhegiht of the new canvas.", "Set the state of an individual day in a weekly recurrence.\n\n@param day Day instance\n@param value true if this day is included in the recurrence", "Initialize the service with a context\n@param context the servlet context to initialize the profile.", "called by timer thread", "Use this API to update nd6ravariables.", "In-place scaling of a column in A\n\n@param alpha scale factor\n@param A matrix\n@param col which row in A", "Gets a JsonObject containing any pending changes to this object that can be sent back to the Box API.\n@return a JsonObject containing the pending changes.", "Process TestCaseStartedEvent. New testCase will be created and added\nto suite as child.\n\n@param event to process", "perform the actual matching" ]
public void validateUniqueIDsForMicrosoftProject() { if (!isEmpty()) { for (T entity : this) { if (NumberHelper.getInt(entity.getUniqueID()) > MS_PROJECT_MAX_UNIQUE_ID) { renumberUniqueIDs(); break; } } } }
[ "Validate that the Unique IDs for the entities in this container are valid for MS Project.\nIf they are not valid, i.e one or more of them are too large, renumber them." ]
[ "Initialize VIDEO_INFO data.", "Given an AVRO serializer definition, validates if all the avro schemas\nare valid i.e parseable.\n\n@param avroSerDef", "Appends formatted text to the source.\n\n<p>Formatting supports {@code %s} and {@code %n$s}. Most args are converted according to their\n{@link Object#toString()} method, except that:<ul>\n<li> {@link Package} and {@link PackageElement} instances use their fully-qualified names\n(no \"package \" prefix).\n<li> {@link Class}, {@link TypeElement}, {@link DeclaredType} and {@link QualifiedName}\ninstances use their qualified names where necessary, or shorter versions if a suitable\nimport line can be added.\n<li> {@link Excerpt} instances have {@link Excerpt#addTo(SourceBuilder)} called.\n</ul>", "Calculate standart deviation.\n@param values Values.\n@param mean Mean.\n@return Standart deviation.", "Retrieve timephased baseline work. Note that index 0 represents \"Baseline\",\nindex 1 represents \"Baseline1\" and so on.\n\n@param index baseline index\n@return timephased work, or null if no baseline is present", "Convert an object to a collection.\n\n@param mapper the object mapper\n@param source the source object\n@param targetCollectionType the target collection type\n@param targetElementType the target collection element type\n@return collection", "Get range around median containing specified percentage of values.\n@param values Values.\n@param percent Values percentage around median.\n@return Returns the range which containes specifies percentage of values.", "Based on a provided locale return a SoyMsgBundle file.\n\nIf a passed in locale object is \"Optional.absent()\",\nthe implementation will return Optional.absent() as well\n@param locale - maybe locale\n@return maybe soy msg bundle", "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 Collection<Photocount> getCounts(Date[] dates, Date[] takenDates) throws FlickrException { List<Photocount> photocounts = new ArrayList<Photocount>(); Map<String, Object> parameters = new HashMap<String, Object>(); parameters.put("method", METHOD_GET_COUNTS); if (dates == null && takenDates == null) { throw new IllegalArgumentException("You must provide a value for either dates or takenDates"); } if (dates != null) { List<String> dateList = new ArrayList<String>(); for (int i = 0; i < dates.length; i++) { dateList.add(String.valueOf(dates[i].getTime() / 1000L)); } parameters.put("dates", StringUtilities.join(dateList, ",")); } if (takenDates != null) { List<String> takenDateList = new ArrayList<String>(); for (int i = 0; i < takenDates.length; i++) { takenDateList.add(String.valueOf(takenDates[i].getTime() / 1000L)); } parameters.put("taken_dates", StringUtilities.join(takenDateList, ",")); } Response response = transport.get(transport.getPath(), parameters, apiKey, sharedSecret); if (response.isError()) { throw new FlickrException(response.getErrorCode(), response.getErrorMessage()); } Element photocountsElement = response.getPayload(); NodeList photocountNodes = photocountsElement.getElementsByTagName("photocount"); for (int i = 0; i < photocountNodes.getLength(); i++) { Element photocountElement = (Element) photocountNodes.item(i); Photocount photocount = new Photocount(); photocount.setCount(photocountElement.getAttribute("count")); photocount.setFromDate(photocountElement.getAttribute("fromdate")); photocount.setToDate(photocountElement.getAttribute("todate")); photocounts.add(photocount); } return photocounts; }
[ "Gets a collection of photo counts for the given date ranges for the calling user.\n\nThis method requires authentication with 'read' permission.\n\n@param dates\nAn array of dates, denoting the periods to return counts for. They should be specified smallest first.\n@param takenDates\nAn array of dates, denoting the periods to return counts for. They should be specified smallest first.\n@return A Collection of Photocount objects" ]
[ "Add a Renderer instance as prototype.\n\n@param renderer to use as prototype.\n@return the current RendererBuilder instance.", "Convert an ObjectBank to corresponding collection of data features and\nlabels.\n\n@return A List of pairs, one for each document, where the first element is\nan int[][][] representing the data and the second element is an\nint[] representing the labels.", "This method is called if the data set has been scrolled.", "Look for the specified album art in both the hot cache of loaded tracks and the longer-lived LRU cache.\n\n@param artReference uniquely identifies the desired album art\n\n@return the art, if it was found in one of our caches, or {@code null}", "Modifies the belief referenced by bName parameter.\n\n@param bName\n- the name of the belief to update.\n@param value\n- the new value for the belief", "Process a calendar exception.\n\n@param calendar parent calendar\n@param row calendar exception data", "From v3_epoly.js, calculates the distance between this LatLong point and\nanother.\n\n@param end The end point to calculate the distance to.\n@return The distance, in metres, to the end point.", "Update the list of buildpacks installed on an app\n\n@param appName See {@link #listApps} for a list of apps that can be used.\n@param buildpacks the new list of buildpack names or URLs.", "Specify the class represented by this `ClassNode` implements\nan interface specified by the given name\n\n@param name the name of the interface class\n@return this `ClassNode` instance" ]
public void implicitDoubleStep( int x1 , int x2 ) { if( printHumps ) System.out.println("Performing implicit double step"); // compute the wilkinson shift double z11 = A.get(x2 - 1, x2 - 1); double z12 = A.get(x2 - 1, x2); double z21 = A.get(x2, x2 - 1); double z22 = A.get(x2, x2); double a11 = A.get(x1,x1); double a21 = A.get(x1+1,x1); double a12 = A.get(x1,x1+1); double a22 = A.get(x1+1,x1+1); double a32 = A.get(x1+2,x1+1); if( normalize ) { temp[0] = a11;temp[1] = a21;temp[2] = a12;temp[3] = a22;temp[4] = a32; temp[5] = z11;temp[6] = z22;temp[7] = z12;temp[8] = z21; double max = Math.abs(temp[0]); for( int j = 1; j < temp.length; j++ ) { if( Math.abs(temp[j]) > max ) max = Math.abs(temp[j]); } a11 /= max;a21 /= max;a12 /= max;a22 /= max;a32 /= max; z11 /= max;z22 /= max;z12 /= max;z21 /= max; } // these equations are derived when the eigenvalues are extracted from the lower right // 2 by 2 matrix. See page 388 of Fundamentals of Matrix Computations 2nd ed for details. double b11,b21,b31; if( useStandardEq ) { b11 = ((a11- z11)*(a11- z22)- z21 * z12)/a21 + a12; b21 = a11 + a22 - z11 - z22; b31 = a32; } else { // this is different from the version in the book and seems in my testing to be more resilient to // over flow issues b11 = ((a11- z11)*(a11- z22)- z21 * z12) + a12*a21; b21 = (a11 + a22 - z11 - z22)*a21; b31 = a32*a21; } performImplicitDoubleStep(x1, x2, b11 , b21 , b31 ); }
[ "Performs an implicit double step using the values contained in the lower right hand side\nof the submatrix for the estimated eigenvector values.\n@param x1\n@param x2" ]
[ "Read all child tasks for a given parent.\n\n@param parentTask parent task", "Find Flickr Places information by Place ID.\n\n@deprecated This method has been deprecated. It won't be removed but you should use {@link #getInfo(String, String)} instead.\n@param placeId\n@return A Location\n@throws FlickrException", "get an AdminClient from the cache if exists, if not create new one\nand return it. This method is non-blocking.\n\nAll AdminClient returned from checkout, once after the completion of\nusage must be returned to the pool by calling checkin. If not,\nthere will be leak of AdminClients (connections, threads and file handles).\n\n@return AdminClient", "Obtain instance of the SQL Service\n\n@return instance of SQLService\n@throws Exception exception", "Computes the product of the diagonal elements. For a diagonal or triangular\nmatrix this is the determinant.\n\n@param T A matrix.\n@return product of the diagonal elements.", "Generates the body of a toString method that uses a StringBuilder.\n\n<p>Conventionally, we join properties with comma separators. If all of the properties are\noptional, we have no choice but to track the separators at runtime, but if any of them will\nalways be present, we can actually do the hard work at compile time. Specifically, we can pick\nthe first such and output it without a comma; any property before it will have a comma\n<em>appended</em>, and any property after it will have a comma <em>prepended</em>. This gives\nus the right number of commas in the right places in all circumstances.\n\n<p>As well as keeping track of whether we are <b>prepending commas</b> yet (initially false),\nwe also keep track of whether we have just finished an if-then block for an optional property,\nor if we are in the <b>middle of an append chain</b>, and if so, whether we are in the\n<b>middle of a string literal</b>. This lets us output the fewest literals and statements,\nmuch as a mildly compulsive programmer would when writing the same code.", "Use this API to add gslbsite.", "Check the variable name and if not set, set it with the singleton variable name being on the top of the stack.", "Provisions a new app user in an enterprise with additional user information using Box Developer Edition.\n@param api the API connection to be used by the created user.\n@param name the name of the user.\n@param params additional user information.\n@return the created user's info." ]
public static <T> Observable<T> map(Observable<?> fromObservable, final T toValue) { if (fromObservable != null) { return fromObservable.subscribeOn(Schedulers.io()) .map(new RXMapper<T>(toValue)); } else { return Observable.empty(); } }
[ "Shortcut for mapping the output of an arbitrary observable to one returning an instance of a specific type, using the IO scheduler.\n@param fromObservable the source observable\n@param toValue the value to emit to the observer\n@param <T> the type of the value to emit\n@return an observable emitting the specified value" ]
[ "Read resource baseline values.\n\n@param row result set row", "Gets the current instance of plugin manager\n\n@return PluginManager", "Prints the help on the command line\n\n@param options Options object from commons-cli", "Creates a new access control entry and stores it for later write out.\n\n@param res the resource\n@param id the id of the principal\n@param allowed the allowed permissions\n@param denied the denied permissions\n@param flags the flags\n\n@return the created ACE", "Returns the Set of entities recognized by this Classifier.\n\n@return The Set of entities recognized by this Classifier.", "Retrieve the most recent storepoint.\n\n@param phoenixProject project data\n@return Storepoint instance", "Use this API to fetch the statistics of all nsacl6_stats resources that are configured on netscaler.", "Helper method for formatting connection termination messages.\n\n@param connectionName\nThe name of the connection\n@param host\nThe remote host\n@param connectionReason\nThe reason for establishing the connection\n@param terminationReason\nThe reason for terminating the connection\n@return A formatted message in the format:\n\"[&lt;connectionName&gt;] remote host[&lt;host&gt;] &lt;connectionReason&gt; - &lt;terminationReason&gt;\"\n<br/>\ne.g. [con1] remote host[123.123.123.123] connection to ECMG -\nterminated by remote host.", "Adds an additional statement to the constructed document.\n\n@param statement\nthe additional statement\n@return builder object to continue construction" ]
@Override public void begin(String namespace, String name, Attributes attributes) throws Exception { // not now: 6.0.0 // digester.setLogger(CmsLog.getLog(digester.getClass())); // Push an array to capture the parameter values if necessary if (m_paramCount > 0) { Object[] parameters = new Object[m_paramCount]; for (int i = 0; i < parameters.length; i++) { parameters[i] = null; } getDigester().pushParams(parameters); } }
[ "Process the start of this element.\n\n@param attributes The attribute list for this element\n@param namespace the namespace URI of the matching element, or an empty string if the parser is not namespace\naware or the element has no namespace\n@param name the local name if the parser is namespace aware, or just the element name otherwise\n@throws Exception if something goes wrong" ]
[ "Visit an exported package of the current module.\n\n@param packaze the qualified name of the exported package.\n@param access the access flag of the exported package,\nvalid values are among {@code ACC_SYNTHETIC} and\n{@code ACC_MANDATED}.\n@param modules the qualified names of the modules that can access to\nthe public classes of the exported package or\n<tt>null</tt>.", "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.", "Returns a Client object for a clientUUID and profileId\n\n@param clientUUID UUID or friendlyName of client\n@param profileId - can be null, safer if it is not null\n@return Client object or null\n@throws Exception exception", "Read a single duration field extended attribute.\n\n@param row field data", "Creates a player wrapper for the Android MediaPlayer.", "Initializes an annotation class\n\n@param name The name of the annotation class\n@return The instance of the annotation. Returns a dummy if the class was\nnot found", "Use this API to fetch all the tunneltrafficpolicy resources that are configured on netscaler.", "Handles adding a key. Calls the registered listener and wraps it's method in some GUI adjustments.", "Obtain the destination hostname for a source host\n\n@param hostName\n@return" ]
@PostConstruct public void initDatabase() { MongoDBInit.LOGGER.info("initializing MongoDB"); String dbName = System.getProperty("mongodb.name"); if (dbName == null) { throw new RuntimeException("Missing database name; Set system property 'mongodb.name'"); } MongoDatabase db = this.mongo.getDatabase(dbName); try { PathMatchingResourcePatternResolver resolver = new PathMatchingResourcePatternResolver(); Resource[] resources = resolver.getResources("classpath*:mongodb/*.ndjson"); MongoDBInit.LOGGER.info("Scanning for collection data"); for (Resource res : resources) { String filename = res.getFilename(); String collection = filename.substring(0, filename.length() - 7); MongoDBInit.LOGGER.info("Found collection file: {}", collection); MongoCollection<DBObject> dbCollection = db.getCollection(collection, DBObject.class); try (Scanner scan = new Scanner(res.getInputStream(), "UTF-8")) { int lines = 0; while (scan.hasNextLine()) { String json = scan.nextLine(); Object parse = JSON.parse(json); if (parse instanceof DBObject) { DBObject dbObject = (DBObject) parse; dbCollection.insertOne(dbObject); } else { MongoDBInit.LOGGER.error("Invalid object found: {}", parse); throw new RuntimeException("Invalid object"); } lines++; } MongoDBInit.LOGGER.info("Imported {} objects into collection {}", lines, collection); } } } catch (IOException e) { throw new RuntimeException("Error importing objects", e); } }
[ "init database with demo data" ]
[ "A GString variant of the equivalent GString method.\n\n@param self the original GString\n@param condition the closure that must evaluate to true to continue taking elements\n@return a prefix of elements in the GString where each\nelement passed to the given closure evaluates to true\n@since 2.3.7", "Populates currency settings.\n\n@param record MPX record\n@param properties project properties", "Returns a string that should be used as a label for the given item. The\nmethod also ensures that each label is used for only one class. Other\nclasses with the same label will have their QID added for disambiguation.\n\n@param entityIdValue\nthe item to label\n@return the label", "Checks the preconditions for creating a new ForbidSubStr processor with a List of forbidden substrings.\n\n@param forbiddenSubStrings\nthe forbidden substrings\n@throws NullPointerException\nif forbiddenSubStrings is null\n@throws IllegalArgumentException\nif forbiddenSubStrings is empty", "Use this API to add tmtrafficaction resources.", "Delete old jobs.\n\n@param checkTimeThreshold threshold for last check time\n@return the number of jobs deleted", "Compute the CRC32 of the segment of the byte array given by the\nspecificed size and offset\n\n@param bytes The bytes to checksum\n@param offset the offset at which to begin checksumming\n@param size the number of bytes to checksum\n@return The CRC32", "Detect new objects.", "set custom request for profile's default client\n\n@param profileName profileName to modify\n@param pathName friendly name of path\n@param customData custom request data\n@return true if success, false otherwise" ]
public static base_response delete(nitro_service client) throws Exception { locationfile deleteresource = new locationfile(); return deleteresource.delete_resource(client); }
[ "Use this API to delete locationfile." ]
[ "Add additional source types", "Updates an existing enum option. Enum custom fields require at least one enabled enum option.\n\nReturns the full record of the updated enum option.\n\n@param enumOption Globally unique identifier for the enum option.\n@return Request object", "Convert moneyness given as difference to par swap rate to moneyness in bp.\nUses the fixing times of the fix schedule to determine fractions.\n\n@param moneyness as offset.\n@return Moneyness in bp.", "Creates a \"delta clone\" of this Map, where only the differences are\nrepresented.", "Executes a method on the server asynchronously", "On host controller reload, remove a not running server registered in the process controller declared as stopping.", "Checks if this child holds the current active state.\nIf the child is or contains the active state it is applied.", "Register an active operation with a specific operation id.\n\n@param id the operation id\n@param attachment the shared attachment\n@param callback the completed callback\n@return the created active operation\n\n@throws java.lang.IllegalStateException if an operation with the same id is already registered", "Convert an Object to a DateTime, without an Exception" ]
protected float getViewPortSize(final Axis axis) { float size = mViewPort == null ? 0 : mViewPort.get(axis); Log.d(Log.SUBSYSTEM.LAYOUT, TAG, "getViewPortSize for %s %f mViewPort = %s", axis, size, mViewPort); return size; }
[ "Get viewport size along the axis\n@param axis {@link Axis}\n@return size" ]
[ "Abort an upload session, discarding any chunks that were uploaded to it.", "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", "Converts an object to an XML file.\n\n@param object The object to convert.\n@param fileName The filename where to save it to.\n@throws FileNotFoundException On error.", "Use this API to fetch vrid6 resource of given name .", "Sets the distance from the origin to the near clipping plane for the\nwhole camera rig.\n\n@param near\nDistance to the near clipping plane.", "Sets Idle max age.\n\nThe time, for a connection to remain unused before it is closed off. Do not use aggressive values here!\n@param idleMaxAge time after which a connection is closed off\n@param timeUnit idleMaxAge time granularity.", "Extracts location result from intent object\n\n@param intent valid intent object\n@return location result.\n@since 1.1.0", "Updates property of parent id for the image provided.\nReturns false if image was not captured true otherwise.\n\n@param log\n@param imageTag\n@param host\n@param buildInfoId\n@return\n@throws IOException\n@throws InterruptedException", "The nullity of the decomposed matrix.\n\n@see SingularOps_DDRM#nullity(SingularValueDecomposition_F64, double)\n\n@return The matrix's nullity" ]
public File getTargetFile(final MiscContentItem item) { final State state = this.state; if (state == State.NEW || state == State.ROLLBACK_ONLY) { return getTargetFile(miscTargetRoot, item); } else { throw new IllegalStateException(); // internal wrong usage, no i18n } }
[ "Get the target file for misc items.\n\n@param item the misc item\n@return the target location" ]
[ "Logs the time taken by this rule, and attaches this to the total for the RuleProvider", "add converter at given index. The index can be changed during conversion\nif canReorder is true\n\n@param index\n@param converter", "Checks if the required option exists.\n\n@param options OptionSet to checked\n@param opt Required option to check\n@throws VoldemortException", "Use this API to fetch systemsession resources of given names .", "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.", "returns an Enumeration of PrimaryKey Objects for objects of class DataClass.\nThe Elements returned come from a SELECT ... WHERE Statement\nthat is defined by the fields and their coresponding values of listFields\nand listValues.\nUseful for EJB Finder Methods...\n@param primaryKeyClass the pk class for the searched objects\n@param query the query", "Use this API to Import sslfipskey.", "Clear JobContext of current thread", "Populates data in this Options from the character stream.\n@param in The Reader\n@throws IOException If there is a problem reading data" ]
public void setDefaultInterval(long defaultInterval) { if(defaultInterval <= 0) { LOG.severe("collector.scheduler.interval must be greater than 0. Recommended value is 500-1000. Current value is " + defaultInterval); throw new IllegalArgumentException("collector.scheduler.interval must be greater than 0. Recommended value is 500-1000. Current value is " + defaultInterval); } this.defaultInterval = defaultInterval; }
[ "Set default interval for sending events to monitoring service. DefaultInterval will be used by\nscheduler.\n\n@param defaultInterval the new default interval" ]
[ "Returns a flag, indicating if search should be performed using a wildcard if the empty query is given.\n@return A flag, indicating if search should be performed using a wildcard if the empty query is given.", "Compute the CRC32 of the segment of the byte array given by the\nspecificed size and offset\n\n@param bytes The bytes to checksum\n@param offset the offset at which to begin checksumming\n@param size the number of bytes to checksum\n@return The CRC32", "get the ArrayTypeSignature corresponding to given generic array type\n\n@param genericArrayType\n@return", "Helper method to track storage operations & time via StreamingStats.\n\n@param startNs", "Retrieves the baseline duration text value.\n\n@param baselineNumber baseline number\n@return baseline duration text value", "Set a proxy for REST-requests.\n\n@param proxyHost\n@param proxyPort", "Isn't there a method for this in GeoTools?\n\n@param crs\nCRS string in the form of 'EPSG:<srid>'.\n@return SRID as integer.", "Remove a previously registered requirement for a capability.\n\n@param requirementRegistration the requirement. Cannot be {@code null}\n@see #registerAdditionalCapabilityRequirement(org.jboss.as.controller.capability.registry.RuntimeRequirementRegistration)", "Starts the enforcer." ]
public void setWorkConnection(CmsSetupDb db) { db.setConnection( m_setupBean.getDbDriver(), m_setupBean.getDbWorkConStr(), m_setupBean.getDbConStrParams(), m_setupBean.getDbWorkUser(), m_setupBean.getDbWorkPwd()); }
[ "Set work connection.\n\n@param db the db setup bean" ]
[ "Helper function that drops all local databases for every client.", "This method processes a single deferred relationship list.\n\n@param dr deferred relationship list data\n@throws MPXJException", "Find container env.\n\n@param ctx the container context\n@param dump the exception dump\n@return valid container or null", "Create a host target.\n\n@param hostName the host name\n@param client the connected controller client to the master host.\n@return the remote target", "Construct a new instance.\n\n@return the new instance", "To get all the textual content in the dom\n\n@param document\n@param individualTokens : default True : when set to true, each text node from dom is used to build the\ntext content : when set to false, the text content of whole is obtained at once.\n@return", "Sets the segment reject as a string. This method is for convenience\nto be able to set percent reject type just by calling with '3%' and\notherwise it uses rows. All this assuming that parsing finds '%' characher\nand is able to parse a raw reject number.\n\n@param reject the new segment reject", "We want to get the best result possible as this value\nis used to determine what work needs to be recovered.\n\n@return", "This method extracts resource data from a Phoenix file.\n\n@param phoenixProject parent node for resources" ]
protected WeldBeanDeploymentArchive createAdditionalBeanDeploymentArchive() { WeldBeanDeploymentArchive additionalBda = new WeldBeanDeploymentArchive(ADDITIONAL_BDA_ID, Collections.synchronizedSet(new HashSet<String>()), null); additionalBda.getServices().addAll(getServices().entrySet()); beanDeploymentArchives.add(additionalBda); setBeanDeploymentArchivesAccessibility(); return additionalBda; }
[ "Additional bean deployment archives are used for extentions, synthetic annotated types and beans which do not come from a bean archive.\n\n@param beanClass\n@return the additional bean deployment archive" ]
[ "Read correlation id.\n\n@param message the message\n@return correlation id from the message", "Returns the name under which this dump file. This is the name used online\nand also locally when downloading the file.\n\n@param dumpContentType\nthe type of the dump\n@param projectName\nthe project name, e.g. \"wikidatawiki\"\n@param dateStamp\nthe date of the dump in format YYYYMMDD\n@return file name string", "Counts the number of elements in A which are not zero.\n@param A A matrix\n@return number of non-zero elements", "Execute all recorded tasks.\n\n@param context the patch context\n@param callback the finalization callback\n@throws Exception", "Set the pattern scheme.\n@param isWeekDayBased flag, indicating if the week day based scheme should be set.", "Function to perform backward pooling", "Returns the specified range of elements in the sorted set.\nThe elements are considered to be ordered from the highest to the lowest score.\nDescending lexicographical order is used for elements with equal score.\nBoth start and stop are zero-based inclusive indexes. They can also be negative numbers indicating offsets from\nthe end of the sorted set, with -1 being the last element of the sorted set.\n@param start\n@param end\n@return the range of elements", "overridden in ipv6 to handle zone", "Vend a SessionVar with the default value" ]
private void printImage(PrintStream out, ItemDocument itemDocument) { String imageFile = null; if (itemDocument != null) { for (StatementGroup sg : itemDocument.getStatementGroups()) { boolean isImage = "P18".equals(sg.getProperty().getId()); if (!isImage) { continue; } for (Statement s : sg) { if (s.getMainSnak() instanceof ValueSnak) { Value value = s.getMainSnak().getValue(); if (value instanceof StringValue) { imageFile = ((StringValue) value).getString(); break; } } } if (imageFile != null) { break; } } } if (imageFile == null) { out.print(",\"http://commons.wikimedia.org/w/thumb.php?f=MA_Route_blank.svg&w=50\""); } else { try { String imageFileEncoded; imageFileEncoded = URLEncoder.encode( imageFile.replace(" ", "_"), "utf-8"); // Keep special title symbols unescaped: imageFileEncoded = imageFileEncoded.replace("%3A", ":") .replace("%2F", "/"); out.print("," + csvStringEscape("http://commons.wikimedia.org/w/thumb.php?f=" + imageFileEncoded) + "&w=50"); } catch (UnsupportedEncodingException e) { throw new RuntimeException( "Your JRE does not support UTF-8 encoding. Srsly?!", e); } } }
[ "Prints the URL of a thumbnail for the given item document to the output,\nor a default image if no image is given for the item.\n\n@param out\nthe output to write to\n@param itemDocument\nthe document that may provide the image information" ]
[ "Returns details of a previously-requested Organization export.\n\n@param organizationExport Globally unique identifier for the Organization export.\n@return Request object", "Allocates a new next buffer and pending fetch.", "Formats the supplied value using the specified DateTimeFormat.\n\n@return \"\" if the value is null", "Log a message line to the output.", "Loads the specified class name and stores it in the hash\n\n@param className class name\n@throws Exception exception", "Replace the current with a new generated identity object and\nreturns the old one.", "Create a new remote proxy controller.\n\n@param client the transactional protocol client\n@param pathAddress the path address\n@param addressTranslator the address translator\n@param targetKernelVersion the {@link ModelVersion} of the kernel management API exposed by the proxied process\n@return the proxy controller", "Get the real Object for already materialized Handler\n\n@param objectOrProxy\n@return Object or null if the Handel is not materialized", "Checks if this service implementation accepts the given resource path.\n@param resourcePath Resource path\n@return true if the implementation matches and the configuration is not invalid." ]
public void incrementVersion(int node, long time) { if(node < 0 || node > Short.MAX_VALUE) throw new IllegalArgumentException(node + " is outside the acceptable range of node ids."); this.timestamp = time; Long version = versionMap.get((short) node); if(version == null) { version = 1L; } else { version = version + 1L; } versionMap.put((short) node, version); if(versionMap.size() >= MAX_NUMBER_OF_VERSIONS) { throw new IllegalStateException("Vector clock is full!"); } }
[ "Increment the version info associated with the given node\n\n@param node The node" ]
[ "Get the collection of configured blogs for the calling user.\n\n@return The Collection of configured blogs", "xml -> object\n\n@param message\n@param childClass\n@return", "Sets up and declares internal data structures.\n\n@param diag Diagonal elements from tridiagonal matrix. Modified.\n@param off Off diagonal elements from tridiagonal matrix. Modified.\n@param numCols number of columns (and rows) in the matrix.", "Get the spatial object from the cache.\n\n@param key key to get object for\n@param type type of object which should be returned\n@return object for key or null if object does not exist or is a different type", "Record the duration of a put operation, along with the size of the values\nreturned.", "Computes annualized seasonal adjustments from given monthly realized CPI values.\n\n@param realizedCPIValues An array of consecutive monthly CPI values (minimum size is 12*numberOfYearsToAverage))\n@param lastMonth The index of the last month in the sequence of realizedCPIValues (corresponding to the enums in <code>{@link java.time.Month}</code>).\n@param numberOfYearsToAverage The number of years to go back in the array of realizedCPIValues.\n@return Array of annualized seasonal adjustments, where [0] corresponds to the adjustment for from December to January.", "to check availability, then class name is truncated to bundle id", "Stops listening. Safe to call when already stopped. Ignored on devices\nwithout appropriate hardware.", "Print a task type.\n\n@param value TaskType instance\n@return task type value" ]
public static void generateJRXML(DynamicReport dr, LayoutManager layoutManager, Map _parameters, String xmlEncoding, OutputStream outputStream) throws JRException { JasperReport jr = generateJasperReport(dr, layoutManager, _parameters); if (xmlEncoding == null) xmlEncoding = DEFAULT_XML_ENCODING; JRXmlWriter.writeReport(jr, outputStream, xmlEncoding); }
[ "Creates a jrxml file\n\n@param dr\n@param layoutManager\n@param _parameters\n@param xmlEncoding (default is UTF-8 )\n@param outputStream\n@throws JRException" ]
[ "Create a hazard curve from given times and given discount factors using default interpolation and extrapolation methods.\n\n@param name The name of this hazard curve.\n@param times Array of times as doubles.\n@param givenSurvivalProbabilities Array of corresponding survival probabilities.\n@return A new discount factor object.", "Set the DPI value for GeoServer if there are already FORMAT_OPTIONS.", "Set the pattern scheme to either \"by weekday\" or \"by day of month\".\n@param isByWeekDay flag, indicating if the pattern \"by weekday\" should be set.\n@param fireChange flag, indicating if a value change event should be fired.", "Pretty-print the object.", "Updates the polling state from a DELETE or POST operation.\n\n@param response the response from Retrofit REST call\n@throws IOException thrown by deserialization", "Process UDFs for a specific object.\n\n@param mpxj field container\n@param udfs UDF values", "Read JaCoCo report determining the format to be used.\n@param executionDataVisitor visitor to store execution data.\n@param sessionInfoStore visitor to store info session.\n@return true if binary format is the latest one.\n@throws IOException in case of error or binary format not supported.", "removes all data for an annotation class. This should be called after an\nannotation has been modified through the SPI", "Generates JUnit 4 RunListener instances for any user defined RunListeners" ]
public static void main(final String[] args) { if (System.getProperty("db.name") == null) { System.out.println("Not running in multi-instance mode: no DB to connect to"); System.exit(1); } while (true) { try { Class.forName("org.postgresql.Driver"); DriverManager.getConnection("jdbc:postgresql://" + System.getProperty("db.host") + ":5432/" + System.getProperty("db.name"), System.getProperty("db.username"), System.getProperty("db.password")); System.out.println("Opened database successfully. Running in multi-instance mode"); System.exit(0); return; } catch (Exception e) { System.out.println("Failed to connect to the DB: " + e.toString()); try { Thread.sleep(1000); } catch (InterruptedException e1) { //ignored } } } }
[ "A comment.\n\n@param args the parameters" ]
[ "Searches the set of imports to find a matching import by type name.\n\n@param typeName\nname of type (qualified or simple name allowed)\n@return found import or {@code null}", "Connects to the comm port and starts send and receive threads.\n@param serialPortName the port name to open\n@throws SerialInterfaceException when a connection error occurs.", "Validate the Combination filter field in Multi configuration jobs", "Get a list of all methods.\n\n@return The method names\n@throws FlickrException", "Retrieves state and metrics information for individual client connection.\n\n@param name connection name\n@return connection information", "Return the text content of the document. It does not containing trailing spaces and asterisks\nat the start of the line.", "Attaches locale groups to the copied page.\n@param copiedPage the copied page.\n@throws CmsException thrown if the root cms cannot be retrieved.", "Assign a new value to this field.\n@param numStrings - number of strings\n@param newValues - the new strings", "Constructs a full capability name from a static base name and a dynamic element.\n\n@param baseName the base name. Cannot be {@code null}\n@param dynamicNameElement the dynamic portion of the name. Cannot be {@code null}\n@return the full capability name. Will not return {@code null}" ]
public static final void parseExtendedAttribute(ProjectFile file, FieldContainer mpx, String value, FieldType mpxFieldID, TimeUnit durationFormat) { if (mpxFieldID != null) { switch (mpxFieldID.getDataType()) { case STRING: { mpx.set(mpxFieldID, value); break; } case DATE: { mpx.set(mpxFieldID, parseExtendedAttributeDate(value)); break; } case CURRENCY: { mpx.set(mpxFieldID, parseExtendedAttributeCurrency(value)); break; } case BOOLEAN: { mpx.set(mpxFieldID, parseExtendedAttributeBoolean(value)); break; } case NUMERIC: { mpx.set(mpxFieldID, parseExtendedAttributeNumber(value)); break; } case DURATION: { mpx.set(mpxFieldID, parseDuration(file, durationFormat, value)); break; } default: { break; } } } }
[ "Parse an extended attribute value.\n\n@param file parent file\n@param mpx parent entity\n@param value string value\n@param mpxFieldID field ID\n@param durationFormat duration format associated with the extended attribute" ]
[ "Update server mapping's host header\n\n@param serverMappingId ID of server mapping\n@param hostHeader value of host header\n@return updated ServerRedirect", "Use this API to Import application.", "Return true if the AST expression has not already been visited. If it is\nthe first visit, register the expression so that the next visit will return false.\n\n@param expression - the AST expression to check\n@return true if the AST expression has NOT already been visited", "Call the appropriate handler for handling the httprequest. 404 if path is not found. 405 if path is found but\nhttpMethod does not match what's configured.\n\n@param request instance of {@code HttpRequest}\n@param responder instance of {@code HttpResponder} to handle the request.", "Adds service locator properties to an endpoint reference.\n@param epr\n@param props", "Configs created by this ConfigBuilder will have the given Redis hostname.\n\n@param host the Redis hostname\n@return this ConfigBuilder", "joins a collection of objects together as a String using a separator", "Sets the bottom padding character for all cells in the row.\n@param paddingBottomChar new padding character, ignored if null\n@return this to allow chaining", "Checks that index is valid an throw an exception if not.\n\n@param type the type\n@param index the index to check" ]
private Map<Integer, Integer> getNodeIdToZonePrimaryCount(Cluster cluster, StoreRoutingPlan storeRoutingPlan) { Map<Integer, Integer> nodeIdToZonePrimaryCount = Maps.newHashMap(); for(Integer nodeId: cluster.getNodeIds()) { nodeIdToZonePrimaryCount.put(nodeId, storeRoutingPlan.getZonePrimaryPartitionIds(nodeId).size()); } return nodeIdToZonePrimaryCount; }
[ "Go through all partition IDs and determine which node is \"first\" in the\nreplicating node list for every zone. This determines the number of\n\"zone primaries\" each node hosts.\n\n@return map of nodeId to number of zone-primaries hosted on node." ]
[ "Updates the terms and statements of the item document identified by the\ngiven item id. The updates are computed with respect to the current data\nfound online, making sure that no redundant deletions or duplicate insertions\nhappen. The references of duplicate statements will be merged. The labels\nand aliases in a given language are kept distinct.\n\n@param itemIdValue\nid of the document to be updated\n@param addLabels\nlabels to be set on the item. They will overwrite existing values\nin the same language.\n@param addDescriptions\ndescription to be set on the item. They will overwrite existing values\nin the same language.\n@param addAliases\naliases to be added. Existing aliases will be kept.\n@param deleteAliases\naliases to be deleted.\n@param addStatements\nthe list of statements to be added or updated; statements with\nempty statement id will be added; statements with non-empty\nstatement id will be updated (if such a statement exists)\n@param deleteStatements\nthe list of statements to be deleted; statements will only be\ndeleted if they are present in the current document (in\nexactly the same form, with the same id)\n@param summary\nshort edit summary\n@return the updated document\n@throws MediaWikiApiErrorException\nif the API returns errors\n@throws IOException\nif there are any IO errors, such as missing network connection", "Entry point for processing saved view state.\n\n@param file project file\n@param varData view state var data\n@param fixedData view state fixed data\n@throws IOException", "Return the number of rows affected.", "Checks the query-customizer setting of the given collection descriptor.\n\n@param collDef The collection descriptor\n@param checkLevel The current check level (this constraint is only checked in strict)\n@exception ConstraintException If the constraint has been violated", "Get's the user's current upload limits, User object only contains user_id\n\n@return Media Limits", "We have obtained a waveform preview for a device, so store it and alert any listeners.\n\n@param update the update which caused us to retrieve this waveform preview\n@param preview the waveform preview which we retrieved", "Instantiates an instance of input Java shader class,\nwhich must be derived from GVRShader or GVRShaderTemplate.\n@param id Java class which implements shaders of this type.\n@param ctx GVRContext shader belongs to\n@return GVRShader subclass which implements this shader type", "Use this API to add nsacl6 resources.", "Searches for brackets which are only used to construct new matrices by concatenating\n1 or more matrices together" ]
public static base_response update(nitro_service client, vridparam resource) throws Exception { vridparam updateresource = new vridparam(); updateresource.sendtomaster = resource.sendtomaster; return updateresource.update_resource(client); }
[ "Use this API to update vridparam." ]
[ "Obtains a Ethiopic zoned date-time from another date-time object.\n\n@param temporal the date-time object to convert, not null\n@return the Ethiopic zoned date-time, not null\n@throws DateTimeException if unable to create the date-time", "For test purposes only.", "Computes the inverse permutation vector\n\n@param original Original permutation vector\n@param inverse It's inverse", "This method writes extended attribute data for a resource.\n\n@param xml MSPDI resource\n@param mpx MPXJ resource", "This method allows us to peek into the OLE compound document to extract the file format.\nThis allows the UniversalProjectReader to determine if this is an MPP file, or if\nit is another type of OLE compound document.\n\n@param fs POIFSFileSystem instance\n@return file format name\n@throws IOException", "Execute a set of API calls as batch request.\n@param requests list of api requests that has to be executed in batch.\n@return list of BoxAPIResponses", "Create the exception assignment map.\n\n@param rows calendar rows\n@return exception assignment map", "Resolves the base directory. If the system property is set that value will be used. Otherwise the path is\nresolved from the home directory.\n\n@param name the system property name\n@param dirName the directory name relative to the base directory\n\n@return the resolved base directory", "A callback that handles requestComplete event from NIO selector manager\nWill try any possible nodes and pass itself as callback util all nodes\nare exhausted\n\n@param slopKey\n@param slopVersioned\n@param nodesToTry List of nodes to try to contact. Will become shorter\nafter each callback" ]
public static appfwpolicy_csvserver_binding[] get(nitro_service service, String name) throws Exception{ appfwpolicy_csvserver_binding obj = new appfwpolicy_csvserver_binding(); obj.set_name(name); appfwpolicy_csvserver_binding response[] = (appfwpolicy_csvserver_binding[]) obj.get_resources(service); return response; }
[ "Use this API to fetch appfwpolicy_csvserver_binding resources of given name ." ]
[ "Writes image files for all data that was collected and the statistics\nfile for all sites.", "Compares the StoreVersionManager's internal state with the content on the file-system\nof the rootDir provided at construction time.\n\nTODO: If the StoreVersionManager supports non-RO stores in the future,\nwe should move some of the ReadOnlyUtils functions below to another Utils class.", "This method extracts assignment data from an MSPDI file.\n\n@param project Root node of the MSPDI file", "Wrapper functions with no bounds checking are used to access matrix internals", "In this method perform the actual override in runtime.\n\n@see org.apache.log4j.spi.HierarchyEventListener#addAppenderEvent(org.apache.log4j.Category, org.apache.log4j.Appender)", "Ensures that generate-table-info is set to false if generate-repository-info is set to false.\n\n@param classDef The class descriptor\n@param checkLevel The current check level (this constraint is checked in all levels)", "Write the field to the specified channel.\n\n@param channel the channel to which it should be written\n\n@throws IOException if there is a problem writing to the channel", "Sets the position of the currency symbol.\n\n@param posn currency symbol position.", "Pops resource requests off the queue until queue is empty or an unexpired\nresource request is found. Invokes .handleTimeout on all expired resource\nrequests popped off the queue.\n\n@return null or a valid ResourceRequest" ]
public static String frame(String imageUrl) { if (imageUrl == null || imageUrl.length() == 0) { throw new IllegalArgumentException("Image URL must not be blank."); } return FILTER_FRAME + "(" + imageUrl + ")"; }
[ "This filter uses a 9-patch to overlay the image.\n\n@param imageUrl Watermark image URL. It is very important to understand that the same image\nloader that Thumbor uses will be used here." ]
[ "Bessel function of the first kind, of order n.\n\n@param n Order.\n@param x Value.\n@return I value.", "Iterate and insert each of the elements of the Collection.\n\n@param objects\nThe objects to insert\n@param outIdentifier\nIdentifier to lookup the returned objects\n@param returnObject\nboolean to specify whether the inserted Collection is part of the ExecutionResults\n@param entryPoint\nOptional EntryPoint for the insertions\n@return", "Indicates if a bean is proxyable\n\n@param bean The bean to test\n@return True if proxyable, false otherwise", "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", "You should use the server's time here. Otherwise you might get unexpected results.\n\nThe typical use case is:\n\n\n<pre>\nHTTPResponse response = ....\nHTTPRequest request = createRequest();\nrequest = request.conditionals(new Conditionals().ifModifiedSince(response.getLastModified());\n</pre>\n\n@param time the time to check.\n@return the conditionals with the If-Modified-Since date set.", "return the list of FormInputs that match this element\n\n@param element\n@return", "This function wires up a SSL Listener with the cyber villians root CA and cert with the correct CNAME for the request\n\n@param host\n@param listener", "return a prepared Select Statement for the given ClassDescriptor", "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" ]
public Response remove(String id) { assertNotEmpty(id, "id"); id = ensureDesignPrefix(id); String revision = null; // Get the revision ID from ETag, removing leading and trailing " revision = client.executeRequest(Http.HEAD(new DatabaseURIHelper(db.getDBUri() ).documentUri(id))).getConnection().getHeaderField("ETag"); if (revision != null) { revision = revision.substring(1, revision.length() - 1); return db.remove(id, revision); } else { throw new CouchDbException("No ETag header found for design document with id " + id); } }
[ "Removes a design document from the database.\n\n@param id the document id (optionally prefixed with \"_design/\")\n@return {@link DesignDocument}" ]
[ "Set the main attribute \"Bundle-Activator\" to the given value.\n\n@param bundleActivator The new value", "Decompiles a single type.\n\n@param metadataSystem\n@param typeName\n@return\n@throws IOException", "Use this API to add dospolicy resources.", "Use this API to fetch a vpnglobal_vpntrafficpolicy_binding resources.", "This deals with the CoNLL files for different languages which have\nbetween 2 and 5 columns on non-blank lines.\n\n@param line A line of CoNLL input\n@return The constructed token", "Tests if this partition has hit a threshold and signal to the pool watch thread to create new connections\n@param connectionPartition to test for.", "Get the possible beans for the given element\n\n@param resolvable The resolving criteria\n@return An unmodifiable set of matching beans", "Perform a normal scan", "Return a new client that may be cached or not. Given properties are always use when not cached, and only used at creation time for\ncached clients.\n\n@param name\nif null, default client. Otherwise, helpful to retrieve cached clients later.\n@param p\na set of properties. Implementation specific. Unknown properties are silently ignored.\n@param cached\nif false, the client will not be cached and subsequent calls with the same name will return different objects." ]
protected GVRPickedObject findCollider(GVRPickedObject[] pickList, GVRCollider findme) { if (pickList == null) { return null; } for (GVRPickedObject hit : pickList) { if ((hit != null) && (hit.hitCollider == findme)) { return hit; } } return null; }
[ "Find the collision against a specific collider in a list of collisions.\n@param pickList collision list\n@param findme collider to find\n@return collision with the specified collider, null if not found" ]
[ "This method returns the mapped certificate for a hostname, or generates a \"standard\"\nSSL server certificate issued by the CA to the supplied subject if no mapping has been\ncreated. This is not a true duplication, just a shortcut method\nthat is adequate for web browsers.\n\n@param hostname\n@return\n@throws CertificateParsingException\n@throws InvalidKeyException\n@throws CertificateExpiredException\n@throws CertificateNotYetValidException\n@throws SignatureException\n@throws CertificateException\n@throws NoSuchAlgorithmException\n@throws NoSuchProviderException\n@throws KeyStoreException\n@throws UnrecoverableKeyException", "Returns true if the context has access to any given permissions.", "Drives the unit test.", "Finds the first Field with given field name in the Class and in its super classes.\n\n@param type The Class type\n@param fieldName The field name to get\n@return an {@code Optional}. Use isPresent() to find out if the field name was found.", "Stores a new certificate and its associated private key in the keystore.\n@param hostname\n@param cert\n@param privKey @throws KeyStoreException\n@throws CertificateException\n@throws NoSuchAlgorithmException", "Use this API to enable snmpalarm of given name.", "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.", "Use this API to fetch gslbservice resource of given name .", "Determine the enum value corresponding to the third play state found in the packet.\n\n@return the proper value" ]
public synchronized ControlPoint getControlPoint(final String deploymentName, final String entryPointName) { ControlPointIdentifier id = new ControlPointIdentifier(deploymentName, entryPointName); ControlPoint ep = entryPoints.get(id); if (ep == null) { ep = new ControlPoint(this, deploymentName, entryPointName, trackIndividualControlPoints); entryPoints.put(id, ep); } ep.increaseReferenceCount(); return ep; }
[ "Gets an entry point for the given deployment. If one does not exist it will be created. If the request controller is disabled\nthis will return null.\n\nEntry points are reference counted. If this method is called n times then {@link #removeControlPoint(ControlPoint)}\nmust also be called n times to clean up the entry points.\n\n@param deploymentName The top level deployment name\n@param entryPointName The entry point name\n@return The entry point, or null if the request controller is disabled" ]
[ "Complete the current operation and persist the current state to the disk. This will also trigger the invalidation\nof outdated modules.\n\n@param modification the current modification\n@param callback the completion callback", "Saves meta tree, writes database root and flushes the log.\n\n@param metaTree mutable meta tree\n@param env enclosing environment\n@param expired expired loggables (database root to be added)\n@return database root loggable which is read again from the log.", "We have an OLE compound document... but is it an MPP file?\n\n@param stream file input stream\n@return ProjectFile instance", "This method checks for paging information and returns the appropriate\ndata\n\n@param result\n@param httpResponse\n@param where\n@return a {@link WrappingPagedList} if there is paging, result if not.", "This method takes the value of an agent's belief through its external\naccess\n\n@param agent_name\nThe name of the agent\n@param belief_name\nThe name of the belief inside agent's adf\n@param connector\nThe connector to get the external access\n@return belief_value The value of the requested belief", "Returns a query filter for the given document _id and version. The version is allowed to be\nnull. The query will match only if there is either no version on the document in the database\nin question if we have no reference of the version or if the version matches the database's\nversion.\n\n@param documentId the _id of the document.\n@param version the expected version of the document, if any.\n@return a query filter for the given document _id and version for a remote operation.", "the applications main loop.", "Given an array of variable names, returns a JsonObject\nof values.\n\n@param dataMap an map containing variable names and their corresponding values\nnames.\n@return a json object of values", "Use this API to fetch all the snmpmanager resources that are configured on netscaler." ]
protected boolean closeAtomically() { if (isClosed.compareAndSet(false, true)) { Closeable.closeQuietly(networkStatsListener); return true; } else { //was already closed. return false; } }
[ "Close the connection atomically.\n\n@return true if state changed to closed; false if nothing changed." ]
[ "Use this API to fetch cacheselector resources of given names .", "Gets the prefix from value.\n\n@param value the value\n@return the prefix from value", "Remove an read lock.", "Gets information about a trashed folder.\n@param folderID the ID of the trashed folder.\n@return info about the trashed folder.", "Parses command-line and gets metadata.\n\n@param args Command-line input\n@param printHelp Tells whether to print help only or execute command\nactually\n@throws IOException", "Determines whether the given type is an array type.\n\n@param type the given type\n@return true if the given type is a subclass of java.lang.Class or implements GenericArrayType", "Use this API to fetch appflowpolicy_appflowpolicylabel_binding resources of given name .", "Notifies that an existing header item is moved to another position.\n\n@param fromPosition the original position.\n@param toPosition the new position.", "retrieve a single reference- or collection attribute\nof a persistent instance.\n@param pInstance the persistent instance\n@param pAttributeName the name of the Attribute to load" ]
ResultAction executeOperation() { assert isControllingThread(); try { /** Execution has begun */ executing = true; processStages(); if (resultAction == ResultAction.KEEP) { report(MessageSeverity.INFO, ControllerLogger.ROOT_LOGGER.operationSucceeded()); } else { report(MessageSeverity.INFO, ControllerLogger.ROOT_LOGGER.operationRollingBack()); } } catch (RuntimeException e) { handleUncaughtException(e); ControllerLogger.MGMT_OP_LOGGER.unexpectedOperationExecutionException(e, controllerOperations); } finally { // On failure close any attached response streams if (resultAction != ResultAction.KEEP && !isBooting()) { synchronized (this) { if (responseStreams != null) { int i = 0; for (OperationResponse.StreamEntry is : responseStreams.values()) { try { is.getStream().close(); } catch (Exception e) { ControllerLogger.MGMT_OP_LOGGER.debugf(e, "Failed closing stream at index %d", i); } i++; } responseStreams.clear(); } } } } return resultAction; }
[ "Package-protected method used to initiate operation execution.\n@return the result action" ]
[ "Loads the localization for the current locale from a bundle of type xmlvfsbundle.\nIt assumes, the content has already been unmarshalled before.\n@param locale the locale for which the localization should be loaded", "Add a URL pattern to the routing table.\n\n@param urlPattern A regular expression\n@throws RouteAlreadyMappedException", "Sets the value associated with the given key; if the the key is one\nof the hashable keys, throws an exception.\n\n@throws HashableCoreMapException Attempting to set the value for an\nimmutable, hashable key.", "Shuffle an array.\n\n@param array Array.\n@param seed Random seed.", "Acquires a read lock on a specific key.\n@param key The key to lock\n@param timeout in milliseconds; -1 means wait indefinitely, 0 means no wait.", "Shutdown each AHC client in the map.", "Gets the actual type arguments of a class\n\n@param clazz The class to examine\n@return The type arguments", "Set the default host running the Odo instance to configure. Allows default profile methods and PathValueClient to\noperate on remote hosts\n\n@param hostName name of host", "Deploys application reading resources from specified URLs\n\n@param applicationName to configure in cluster\n@param urls where resources are read\n@return the name of the application\n@throws IOException" ]
public Enumeration getPKEnumerationByQuery(Class primaryKeyClass, Query query) throws PersistenceBrokerException { if (logger.isDebugEnabled()) logger.debug("getPKEnumerationByQuery " + query); query.setFetchSize(1); ClassDescriptor cld = getClassDescriptor(query.getSearchClass()); return new PkEnumeration(query, cld, primaryKeyClass, this); }
[ "returns an Enumeration of PrimaryKey Objects for objects of class DataClass.\nThe Elements returned come from a SELECT ... WHERE Statement\nthat is defined by the fields and their coresponding values of listFields\nand listValues.\nUseful for EJB Finder Methods...\n@param primaryKeyClass the pk class for the searched objects\n@param query the query" ]
[ "Produces an IPv4 address from any sequence of 4 bytes in this IPv6 address.\n\n@param byteIndex the byte index to start\n@throws IndexOutOfBoundsException if the index is less than zero or bigger than 7\n@return", "Alternate version of autoGeneratedKeys.\n@param sql\n@param autoGeneratedKeys\n@return cache key to use.", "Checks if the dependency server is available\n\n@return true if the server is reachable, false otherwise", "Use this API to update route6 resources.", "Shutdown the container.\n\n@see Weld#initialize()", "Set a custom response for this path\n\n@param pathName name of path\n@param customResponse value of custom response\n@return true if success, false otherwise\n@throws Exception exception", "Sets that there are some pending writes that occurred at a time for an associated\nlocally emitted change event. This variant maintains the last version set.\n\n@param atTime the time at which the write occurred.\n@param changeEvent the description of the write/change.", "Build a Dataset from some data.\n\n@param oldData This {@link Dataset} represents data for which we which to\nsome features, specifically those features not in the {@link edu.stanford.nlp.util.Index}\ngoodFeatures.\n@param goodFeatures An {@link edu.stanford.nlp.util.Index} of features we wish to retain.\n@return A new {@link Dataset} wheres each datapoint contains only features\nwhich were in goodFeatures.", "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" ]
private void revisitMessages(Definitions def) { List<RootElement> rootElements = def.getRootElements(); List<ItemDefinition> toAddDefinitions = new ArrayList<ItemDefinition>(); for (RootElement root : rootElements) { if (root instanceof Message) { if (!existsMessageItemDefinition(rootElements, root.getId())) { ItemDefinition itemdef = Bpmn2Factory.eINSTANCE.createItemDefinition(); itemdef.setId(root.getId() + "Type"); toAddDefinitions.add(itemdef); ((Message) root).setItemRef(itemdef); } } } for (ItemDefinition id : toAddDefinitions) { def.getRootElements().add(id); } }
[ "Revisit message to set their item ref to a item definition\n@param def Definitions" ]
[ "Handles the response of the SerialAPIGetCapabilities request.\n@param incomingMessage the response message to process.", "If the belief its a count of some sort his counting its increased by one.\n\n@param bName\n- the name of the belief count.", "Adds the newState and the edge between the currentState and the newState on the SFG.\n\n@param newState the new state.\n@param eventable the clickable causing the new state.\n@return the clone state iff newState is a clone, else returns null", "Decomposes the provided matrix and stores the result in the same matrix.\n\n@param A Matrix that is to be decomposed. Modified.\n@return If it succeeded or not.", "If the Authtoken was already created in a separate program but not saved to file.\n\n@param authToken\n@param tokenSecret\n@param username\n@return\n@throws IOException", "Adds position noise to the trajectories\n@param t\n@param sd\n@return trajectory with position noise", "Removes an audio source from the audio manager.\n@param audioSource audio source to remove", "Save a weak reference to the resource", "This function computes which reduce task to shuffle a record to." ]
public void cleanup() { List<String> keys = new ArrayList<>(created.keySet()); keys.sort(String::compareTo); for (String key : keys) { created.remove(key) .stream() .sorted(Comparator.comparing(HasMetadata::getKind)) .forEach(metadata -> { log.info(String.format("Deleting %s : %s", key, metadata.getKind())); deleteWithRetries(metadata); }); } }
[ "Removes all resources deployed using this class." ]
[ "Wait to shutdown service\n\n@param executorService Executor service to shutdown\n@param timeOutSec Time we wait for", "Get the group URL for the specified group ID\n\n@param groupId\nThe group ID\n@return The group URL\n@throws FlickrException", "Returns an integer array that contains the current values for all the\ntexture parameters.\n\n@return an integer array that contains the current values for all the\ntexture parameters.", "Tries to stop the JLAN server and return after it is stopped, but will also return if the thread hasn't stopped after MAX_SHUTDOWN_WAIT_MILLIS.", "Computes the decomposition of the provided matrix. If no errors are detected then true is returned,\nfalse otherwise.\n@param A The matrix that is being decomposed. Not modified.\n@return If it detects any errors or not.", "The entity instance is not in the session cache\n\nCopied from Loader#instanceNotYetLoaded", "Add a raw SQL \"GROUP BY\" clause to the SQL query statement. This should not include the \"GROUP BY\".", "Detects if the current browser is a Sony Mylo device.\n@return detection of a Sony Mylo device", "Creates a resource key with given id for bundle specified by given class.\n@param clazz the class owning the bundle.\n@param id value identifier\n@return the resource key" ]
public final void loadCollection( final SharedSessionContractImplementor session, final Serializable id, final Type type) throws HibernateException { if ( log.isDebugEnabled() ) { log.debug( "loading collection: " + MessageHelper.collectionInfoString( getCollectionPersisters()[0], id, getFactory() ) ); } Serializable[] ids = new Serializable[]{id}; QueryParameters qp = new QueryParameters( new Type[]{type}, ids, ids ); doQueryAndInitializeNonLazyCollections( session, qp, OgmLoadingContext.EMPTY_CONTEXT, true ); log.debug( "done loading collection" ); }
[ "Called by subclasses that initialize collections\n\n@param session the session\n@param id the collection identifier\n@param type collection type\n@throws HibernateException if an error occurs" ]
[ "Curries a function that takes three arguments.\n\n@param function\nthe original function. May not be <code>null</code>.\n@param argument\nthe fixed first argument of {@code function}.\n@return a function that takes two arguments. Never <code>null</code>.", "Map custom info.\n\n@param ciType the custom info type\n@return the map", "Returns an entry with the given proposal and the prefix from the context, or null if the proposal is not valid.", "Translate this rectangle over the specified following distances.\n\n@param rect rectangle to move\n@param dx delta x\n@param dy delta y", "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\".", "This function uses a proxy which is capable of transforming typed invocations into proper HTTP calls\nwhich will be understood by RESTful services. This works for subresources as well. Interfaces and\nconcrete classes can be proxified, in the latter case a CGLIB runtime dependency is needed. CXF JAX-RS\nproxies can be configured the same way as HTTP-centric WebClients and response status and headers can\nalso be checked. HTTP response errors can be converted into typed exceptions.", "Stops all transitions.", "k\nReturns a list of artifact regarding the filters\n\n@return List<DbArtifact>", "This method writes project property data to a JSON file." ]
public static void permutationInverse( int []original , int []inverse , int length ) { for (int i = 0; i < length; i++) { inverse[original[i]] = i; } }
[ "Computes the inverse permutation vector\n\n@param original Original permutation vector\n@param inverse It's inverse" ]
[ "Returns the orthogonal U matrix.\n\n@param U If not null then the results will be stored here. Otherwise a new matrix will be created.\n@return The extracted Q matrix.", "Gets information about a trashed folder that's limited to a list of specified fields.\n@param folderID the ID of the trashed folder.\n@param fields the fields to retrieve.\n@return info about the trashed folder containing only the specified fields.", "Returns a single sort option configuration as configured via the methods parameter, or null if the parameter does not specify a sort option.\n@param json The JSON sort option configuration.\n@return The sort option configuration, or null if the JSON could not be read.", "Use this API to save nsconfig.", "Retrieves a list of Terms of Service that belong to your Enterprise as an Iterable.\n@param api api the API connection to be used by the resource.\n@param termsOfServiceType the type of terms of service to be retrieved. Can be set to \"managed\" or \"external\"\n@return the Iterable of Terms of Service in an Enterprise that match the filter parameters.", "Compiles and performs the provided equation.\n\n@param equation String in simple equation format", "Find the style filter that must be applied to this feature.\n\n@param feature\nfeature to find the style for\n@param styles\nstyle filters to select from\n@return a style filter", "Take a stab at fixing validation problems ?\n\n@param object", "Convert a URL Encoded name back to the original form.\n@param name the name to URL urlDecode.\n@param encoding the string encoding to be used (i.e. UTF-8)\n@return the name in original form.\n@throws UnsupportedEncodingException if the encoding is not supported." ]
public List getFeedback() { List<?> messages = new ArrayList(); for ( ValueSource vs : valueSources ) { List feedback = vs.getFeedback(); if ( feedback != null && !feedback.isEmpty() ) { messages.addAll( feedback ); } } return messages; }
[ "Return any feedback messages and errors that were generated - but\nsuppressed - during the interpolation process. Since unresolvable\nexpressions will be left in the source string as-is, this feedback is\noptional, and will only be useful for debugging interpolation problems.\n\n@return a {@link List} that may be interspersed with {@link String} and\n{@link Throwable} instances." ]
[ "Reads a color value represented by three bytes, for R, G, and B\ncomponents, plus a flag byte indicating if this is an automatic color.\nReturns null if the color type is \"Automatic\".\n\n@param data byte array of data\n@param offset offset into array\n@return new Color instance", "The smallest granularity of rebalancing where-in we move partitions for a\nsub-set of stores. Finally at the end of the movement, the node is\nremoved out of rebalance state\n\n<br>\n\nAlso any errors + rollback procedures are performed at this level itself.\n\n<pre>\n| Case | hasRO | hasRW | finishedRO | Action |\n| 0 | t | t | t | rollback cluster change + swap |\n| 1 | t | t | f | nothing to do since \"rebalance state change\" should have removed everything |\n| 2 | t | f | t | won't be triggered since hasRW is false |\n| 3 | t | f | f | nothing to do since \"rebalance state change\" should have removed everything |\n| 4 | f | t | t | rollback cluster change |\n| 5 | f | t | f | won't be triggered |\n| 6 | f | f | t | won't be triggered |\n| 7 | f | f | f | won't be triggered |\n</pre>\n\n@param batchId Rebalance batch id\n@param batchRollbackCluster Cluster to rollback to if we have a problem\n@param rebalanceTaskPlanList The list of rebalance partition plans\n@param hasReadOnlyStores Are we rebalancing any read-only stores?\n@param hasReadWriteStores Are we rebalancing any read-write stores?\n@param finishedReadOnlyStores Have we finished rebalancing of read-only\nstores?", "Changes the image data associated with a GVRTexture.\nThis can be a simple bitmap, a compressed bitmap,\na cubemap or a compressed cubemap.\n@param imageData data for the texture as a GVRImate", "Acquire transaction with a single permit in a thread. Transactions are acquired reentrantly, i.e.\nwith respect to transactions already acquired in the thread.\n\n@return the number of acquired permits, identically equal to 1.", "Use this API to fetch all the cmpparameter resources that are configured on netscaler.", "View that redirects the top level window to the URL defined in postDeclineUrl property after user declines to authorize application.\nMay be overridden for custom views, particularly in the case where the post-decline view should be rendered in-canvas.\n@return a view to display after a user declines authoriation. Defaults as a redirect to postDeclineUrl", "Adds a submodule to the module.\n\n<P>\nINFO: If the module is promoted, all added submodule will be promoted.\n\n@param submodule Module", "Find the index of this animation if it is in this animator.\n\n@param findme {@link GVRAnimation} to find.\n@returns 0 based index of animation or -1 if not found\n@see GVRAnimator#addAnimation(GVRAnimation)", "Use this API to fetch dospolicy resource of given name ." ]
public static final Date getTimestamp(byte[] data, int offset) { Date result; long days = getShort(data, offset + 2); if (days < 100) { // We are seeing some files which have very small values for the number of days. // When the relevant field is shown in MS Project it appears as NA. // We try to mimic this behaviour here. days = 0; } if (days == 0 || days == 65535) { result = null; } else { long time = getShort(data, offset); if (time == 65535) { time = 0; } result = DateHelper.getTimestampFromLong((EPOCH + (days * DateHelper.MS_PER_DAY) + ((time * DateHelper.MS_PER_MINUTE) / 10))); } return (result); }
[ "Reads a combined date and time value.\n\n@param data byte array of data\n@param offset location of data as offset into the array\n@return time value" ]
[ "Assign a new value to this field.\n@param numStrings - number of strings\n@param newValues - the new strings", "If the column name is a dotted column, returns the first part.\nReturns null otherwise.\n\n@param column the column that might have a prefix\n@return the first part of the prefix of the column or {@code null} if the column does not have a prefix.", "Emit information about all of suite's tests.", "Runs a Story with the given configuration and steps, applying the given\nmeta filter, and staring from given state.\n\n@param configuration the Configuration used to run story\n@param candidateSteps the List of CandidateSteps containing the candidate\nsteps methods\n@param story the Story to run\n@param filter the Filter to apply to the story Meta\n@param beforeStories the State before running any of the stories, if not\n<code>null</code>\n@throws Throwable if failures occurred and FailureStrategy dictates it to\nbe re-thrown.", "A comment.\n\n@param args the parameters", "Returns the full user record for the single user with the provided ID.\n\n@param user An identifier for the user. Can be one of an email address,\nthe globally unique identifier for the user, or the keyword `me`\nto indicate the current user making the request.\n@return Request object", "Return the discount factor within a given model context for a given maturity.\n@param model The model used as a context (not required for this class).\n@param maturity The maturity in terms of ACT/365 daycount form this curve reference date. Note that this parameter might get rescaled to a different time parameter.\n@see net.finmath.marketdata.model.curves.DiscountCurveInterface#getDiscountFactor(net.finmath.marketdata.model.AnalyticModelInterface, double)", "I promise that this is always a collection of HazeltaskTasks", "Executes the given side effecting function on each pixel.\n\n@param fn a function that accepts 3 parameters - the x,y coordinate and the pixel at that coordinate" ]
private float newRandomIndividualParticleRadius(@NonNull final SceneConfiguration scene) { return scene.getParticleRadiusMin() == scene.getParticleRadiusMax() ? scene.getParticleRadiusMin() : scene.getParticleRadiusMin() + (random.nextInt( (int) ((scene.getParticleRadiusMax() - scene.getParticleRadiusMin()) * 100f))) / 100f; }
[ "Generates new individual particle radius based on min and max radius setting.\n\n@return new particle radius" ]
[ "Translates the Fluo row, column, and value set into the persistent format that is stored in\nAccumulo.\n\n<p>\nThe objects returned by this method are reused each time its called. So each time this is\ncalled it invalidates what was returned by previous calls to this method.\n\n@return A an array of Accumulo key values in correct sorted order.", "This function is intended to detect the subset of IOException which are not\nconsidered recoverable, in which case we want to bubble up the exception, instead\nof retrying.\n\n@throws VoldemortException", "Add a IN clause so the column must be equal-to one of the objects passed in.", "Retrieve all addresses of a host by it's address. NetBIOS hosts can\nhave many names for a given IP address. The name and IP address make the\nNetBIOS address. This provides a way to retrieve the other names for a\nhost with the same IP address.\n\n@param addr the address to query\n@throws UnknownHostException if address cannot be resolved", "Extracts the row from a matrix.\n@param a Input matrix\n@param row Which row is to be extracted\n@param out output. Storage for the extracted row. If null then a new vector will be returned.\n@return The extracted row.", "Create a WebDriver backed EmbeddedBrowser.\n\n@param driver The WebDriver to use.\n@param filterAttributes the attributes to be filtered from DOM.\n@param crawlWaitReload the period to wait after a reload.\n@param crawlWaitEvent the period to wait after an event is fired.\n@return The EmbeddedBrowser.", "Get information about this database.\n\n@return DbInfo encapsulating the database info\n@see <a\nhref=\"https://console.bluemix.net/docs/services/Cloudant/api/database.html#getting-database-details\"\ntarget=\"_blank\">Databases - read</a>", "The max possible width can be calculated doing the sum of of the inner cells and its totals\n@param crosstabColumn\n@return", "Set the custom projection matrix with individual matrix elements." ]
public static boolean ensureJedisConnection(final Jedis jedis) { final boolean jedisOK = testJedisConnection(jedis); if (!jedisOK) { try { jedis.quit(); } catch (Exception e) { } // Ignore try { jedis.disconnect(); } catch (Exception e) { } // Ignore jedis.connect(); } return jedisOK; }
[ "Ensure that the given connection is established.\n\n@param jedis\na connection to Redis\n@return true if the supplied connection was already connected" ]
[ "Writes a resource assignment to a PM XML file.\n\n@param mpxj MPXJ ResourceAssignment instance", "Sets the bytecode compatibility mode\n\n@param version the bytecode compatibility mode", "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", "Creates a list of placeholders for use in a PreparedStatement\n\n@param length number of placeholders\n@return String of placeholders, seperated by comma", "Establish a new tempo master, and if it is a change from the existing one, report it to the listeners.\n\n@param newMaster the packet which caused the change of masters, or {@code null} if there is now no master.", "Find a column by its name\n\n@param columnName the name of the column\n@return the given Column, or <code>null</code> if not found", "Use this API to count sslcertkey_crldistribution_binding resources configued on NetScaler.", "Tries to load a property file with the specified name.\n\n@param localizedName the name\n@return the resource bundle if it was loaded, otherwise the backup", "Gets the status text from given session.\n\n@param lastActivity miliseconds since last activity\n@return status string" ]
public boolean hasValue(String fieldName) { return resultMap.containsKey(fieldName) && resultMap.get(fieldName) != null; }
[ "Checks that a field exists and contains a non-null value.\n@param fieldName the name of the field to check existence/value of.\n@return true if the field exists in the result set and has a non-null value; false otherwise." ]
[ "Replies the elements of the left map without the pairs in the right map.\nIf the pair's values differ from\nthe value within the map, the map entry is not removed.\n\n<p>\nThe difference is an immutable\nsnapshot of the state of the maps at the time this method is called. It\nwill never change, even if the maps change at a later time.\n</p>\n\n<p>\nSince this method uses {@code HashMap} instances internally, the keys of\nthe supplied maps must be well-behaved with respect to\n{@link Object#equals} and {@link Object#hashCode}.\n</p>\n\n@param <K> type of the map keys.\n@param <V> type of the map values.\n@param left the map to update.\n@param right the pairs to remove.\n@return the map with the content of the left map except the pairs of the right map.\n@since 2.15", "Returns a Pair constructed from X and Y. Convenience method; the\ncompiler will disambiguate the classes used for you so that you\ndon't have to write out potentially long class names.", "adds a CmsJspImageBean as hi-DPI variant to this image\n@param factor the variant multiplier, e.g. \"2x\" (the common retina multiplier)\n@param image the image to be used for this variant", "Inits the ws client.\n\n@param context the context\n@throws Exception the exception", "Computes the null space using QR decomposition. This is much faster than using SVD\n@param A (Input) Matrix\n@param totalSingular Number of singular values\n@return Null space", "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.", "Parses the list of query items for the query facet.\n@param queryFacetObject JSON object representing the node with the query facet.\n@return list of query options\n@throws JSONException if the list cannot be parsed.", "Helper method to abstract out the common logic from the various users methods.\n\n@param api the API connection to be used when retrieving the users.\n@param filterTerm The filter term to lookup users by (login for external, login or name for managed)\n@param userType The type of users we want to search with this request.\nValid values are 'managed' (enterprise users), 'external' or 'all'\n@param externalAppUserId the external app user id that has been set for an app user\n@param fields the fields to retrieve. Leave this out for the standard fields.\n@return An iterator over the selected users.", "Get the VCS url from the Jenkins build environment. The search will one of \"SVN_REVISION\", \"GIT_COMMIT\",\n\"P4_CHANGELIST\" in the environment.\n\n@param env Th Jenkins build environment.\n@return The vcs url for supported VCS" ]
private void validateSameDay(ProjectCalendar calendar, LinkedList<TimephasedWork> list) { for (TimephasedWork assignment : list) { Date assignmentStart = assignment.getStart(); Date calendarStartTime = calendar.getStartTime(assignmentStart); Date assignmentStartTime = DateHelper.getCanonicalTime(assignmentStart); Date assignmentFinish = assignment.getFinish(); Date calendarFinishTime = calendar.getFinishTime(assignmentFinish); Date assignmentFinishTime = DateHelper.getCanonicalTime(assignmentFinish); double totalWork = assignment.getTotalAmount().getDuration(); if (assignmentStartTime != null && calendarStartTime != null) { if ((totalWork == 0 && assignmentStartTime.getTime() != calendarStartTime.getTime()) || (assignmentStartTime.getTime() < calendarStartTime.getTime())) { assignmentStart = DateHelper.setTime(assignmentStart, calendarStartTime); assignment.setStart(assignmentStart); } } if (assignmentFinishTime != null && calendarFinishTime != null) { if ((totalWork == 0 && assignmentFinishTime.getTime() != calendarFinishTime.getTime()) || (assignmentFinishTime.getTime() > calendarFinishTime.getTime())) { assignmentFinish = DateHelper.setTime(assignmentFinish, calendarFinishTime); assignment.setFinish(assignmentFinish); } } } }
[ "Ensures that the start and end dates for ranges fit within the\nworking times for a given day.\n\n@param calendar current calendar\n@param list assignment data" ]
[ "Accessor method used to retrieve a char representing the\ncontents of an individual field. If the field does not exist in the\nrecord, the default character is returned.\n\n@param field the index number of the field to be retrieved\n@return the value of the required field", "Release the connection back to the pool.\n\n@throws SQLException Never really thrown", "Wrap a simple attribute def as list.\n\n@param def the attribute definition\n@return the list attribute def", "Set the value for a custom request\n\n@param pathId ID of path\n@param customRequest value of custom request\n@param clientUUID UUID of client", "Returns the bundle jar classpath element.", "Creates a random diagonal matrix where the diagonal elements are selected from a uniform\ndistribution that goes from min to max.\n\n@param N Dimension of the 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.", "Generate a string with all selected checkboxes separated with ','.\n\n@return a string with all selected checkboxes", "Determines whether or not a given feature matches this pattern.\n\n@param feature\nSpecified feature to examine.\n\n@return Flag confirming whether or not this feature is inside the filter.", "Runs the currently entered query and displays the results." ]
VersionExcludeData getVersionIgnoreData(int major, int minor, int micro) { VersionExcludeData result = registry.get(new VersionKey(major, minor, micro)); if (result == null) { result = registry.get(new VersionKey(major, minor, null)); } return result; }
[ "Gets the host-ignore data for a slave host running the given version.\n\n@param major the kernel management API major version\n@param minor the kernel management API minor version\n@param micro the kernel management API micro version\n\n@return the host-ignore data, or {@code null} if there is no matching registration" ]
[ "2-D Forward Discrete Hartley Transform.\n\n@param data Data.", "Use this API to unset the properties of nslimitselector resource.\nProperties that need to be unset are specified in args array.", "Add a 'IS NOT NULL' clause so the column must not be null. '&lt;&gt;' NULL does not work.", "Initialize elements from the duration panel.", "Reads all text of the XML tag and returns it as a String.\nAssumes that a '<' character has already been read.\n\n@param r The reader to read from\n@return The String representing the tag, or null if one couldn't be read\n(i.e., EOF). The returned item is a complete tag including angle\nbrackets, such as <code>&lt;TXT&gt;</code>", "Returns the corresponding ModuleSpec service name for the given module.\n\n@param identifier The module identifier\n@return The service name of the ModuleSpec service", "Samples a batch of indices in the range [0, numExamples) without replacement.", "Tries to return the single table to which all classes in the hierarchy with the given\nclass as the root map.\n\n@param classDef The root class of the hierarchy\n@return The table name or <code>null</code> if the classes map to more than one table\nor no class in the hierarchy maps to a table", "Use this API to add onlinkipv6prefix resources." ]
@SuppressWarnings("unchecked") public T[] nextCombinationAsArray() { T[] combination = (T[]) Array.newInstance(elements.getClass().getComponentType(), combinationIndices.length); return nextCombinationAsArray(combination); }
[ "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." ]
[ "Handles the cases in which we can use longs rather than BigInteger\n\n@param section\n@param increment\n@param addrCreator\n@param lowerProducer\n@param upperProducer\n@param prefixLength\n@return", "Use this API to export sslfipskey.", "Returns the next object in the table.\n\n@throws IllegalStateException\nIf there was a problem extracting the object from SQL.", "Pretty prints a task list of rebalancing tasks.\n\n@param infos list of rebalancing tasks (RebalancePartitionsInfo)\n@return pretty-printed string", "Initialize that Foundation Logging library.", "Begin a \"track;\" that is, begin logging at one level deeper.\nChannels other than the FORCE channel are ignored.\n@param args The title of the track to begin, with an optional FORCE flag.", "set ViewPager scroller to change animation duration when sliding", "Zeros an inner rectangle inside the matrix.\n\n@param A Matrix that is to be modified.\n@param row0 Start row.\n@param row1 Stop row+1.\n@param col0 Start column.\n@param col1 Stop column+1.", "Use this API to fetch a vpnglobal_appcontroller_binding resources." ]
public static Double checkLongitude(String name, Double longitude) { if (longitude == null) { throw new IndexException("{} required", name); } else if (longitude < MIN_LONGITUDE || longitude > MAX_LONGITUDE) { throw new IndexException("{} must be in range [{}, {}], but found {}", name, MIN_LONGITUDE, MAX_LONGITUDE, longitude); } return longitude; }
[ "Checks if the specified longitude is correct.\n\n@param name the name of the longitude field\n@param longitude the value of the longitude field\n@return the longitude" ]
[ "Get the collection of public contacts for the specified user ID.\n\nThis method does not require authentication.\n\n@param userId\nThe user ID\n@return The Collection of Contact objects\n@throws FlickrException", "Whether the address is IPv4-compatible\n\n@see java.net.Inet6Address#isIPv4CompatibleAddress()", "updates the groupname in the table given the id\n\n@param newGroupName new group name\n@param id ID of group", "Performs DBSCAN cluster analysis.\n\n@param points the points to cluster\n@return the list of clusters\n@throws NullArgumentException if the data points are null", "Convert a collection of objects to a JSON array with the string representations of that objects.\n@param collection the collection of objects.\n@return the JSON array with the string representations.", "Get the context for the specified photo.\n\nThis method does not require authentication.\n\n@param photoId\nThe photo ID\n@return The PhotoContext\n@throws FlickrException", "Returns an iterable containing the items in this folder and specifies which child fields to retrieve from the\nAPI.\n\n@param fields the fields to retrieve.\n@return an iterable containing the items in this folder.", "Use this API to disable Interface of given name.", "Generates an artifact regarding the parameters.\n\n<P> <b>WARNING:</b> The parameters grId/arId/version should be filled!!! Only classifier and type are not mandatory.\n\n@param groupId String\n@param artifactId String\n@param version String\n@param classifier String\n@param type String\n@param extension String\n@return Artifact" ]
BsonDocument getNextVersion() { if (!this.hasVersion() || this.getVersionDoc() == null) { return getFreshVersionDocument(); } final BsonDocument nextVersion = BsonUtils.copyOfDocument(this.getVersionDoc()); nextVersion.put( Fields.VERSION_COUNTER_FIELD, new BsonInt64(this.getVersion().getVersionCounter() + 1)); return nextVersion; }
[ "Given a DocumentVersionInfo, returns a BSON document representing the next version. This means\nand incremented version count for a non-empty version, or a fresh version document for an\nempty version.\n@return a BsonDocument representing a synchronization version" ]
[ "Set a new Cursor position if active and enabled.\n\n@param x x value of the position\n@param y y value of the position\n@param z z value of the position", "Use this method to enable device network-related information tracking, including IP address.\nThis reporting is disabled by default. To re-disable tracking call this method with enabled set to false.\n\n@param value boolean Whether device network info reporting should be enabled/disabled.", "Use this API to unset the properties of clusternodegroup resources.\nProperties that need to be unset are specified in args array.", "Adds a boolean refinement for the next queries.\n\n@param attribute the attribute to refine on.\n@param value the value to refine with.\n@return this {@link Searcher} for chaining.", "Sets an Integer attribute.\n\n@param key the key, non null.\n@param value the value\n@return the Builder, for chaining.", "A Maven stub is a Maven Project for which we have found information, but the project has not yet been located\nwithin the input application. If we have found an application of the same GAV within the input app, we should\nfill out this stub instead of creating a new one.", "Return a capitalized version of the specified property name.\n\n@param s\nThe property name", "Use this API to fetch a cmpglobal_cmppolicy_binding resources.", "Process any StepEvent. You can change last added to stepStorage\nstep using this method.\n\n@param event to process" ]
public final void setHost(final String host) throws UnknownHostException { this.host = host; final InetAddress[] inetAddresses = InetAddress.getAllByName(host); for (InetAddress address: inetAddresses) { final AddressHostMatcher matcher = new AddressHostMatcher(); matcher.setIp(address.getHostAddress()); this.matchersForHost.add(matcher); } }
[ "Set the host.\n\n@param host the host" ]
[ "Extract the generic type from the given Class object.\n@param clazz the Class to check\n@param source the expected raw source type (can be {@code null})\n@param typeIndex the index of the actual type argument\n@param nestingLevel the nesting level of the target type\n@param currentLevel the current nested level\n@return the generic type as Class, or {@code null} if none", "Removes the supplied marker from the map.\n\n@param marker", "Use this API to add dnspolicylabel.", "Plots the MSD curve with the trajectory t and adds the fitted model for free diffusion.\n@param t\n@param lagMin Minimum timelag (e.g. 1,2,3..) lagMin*timelag = elapsed time in seconds\n@param lagMax lagMax Maximum timelag (e.g. 1,2,3..) lagMax*timelag = elapsed time in seconds\n@param timelag Elapsed time between two frames.\n@param diffusionCoefficient Diffusion coefficient\n@param intercept", "Write a size prefixed string where the size is stored as a 2 byte\nshort\n\n@param buffer The buffer to write to\n@param s The string to write", "Extracts the version id from a string\n\n@param versionDir The string\n@return Returns the version id of the directory, else -1", "LRN cross-channel forward computation. Double parameters cast to tensor data type", "Use this API to add gslbsite resources.", "Use this API to fetch spilloverpolicy_lbvserver_binding resources of given name ." ]
public ItemRequest<Webhook> getById(String webhook) { String path = String.format("/webhooks/%s", webhook); return new ItemRequest<Webhook>(this, Webhook.class, path, "GET"); }
[ "Returns the full record for the given webhook.\n\n@param webhook The webhook to get.\n@return Request object" ]
[ "Returns the complete property list of a class\n@param c the class\n@return the property list of the class", "Use this API to expire cachecontentgroup resources.", "Ask the specified player for a Track menu.\n\n@param slotReference the player and slot for which the menu is desired\n@param sortOrder the order in which responses should be sorted, 0 for default, see Section 6.11.1 of the\n<a href=\"https://github.com/Deep-Symmetry/dysentery/blob/master/doc/Analysis.pdf\">Packet Analysis\ndocument</a> for details\n\n@return the entries in the track menu\n\n@throws Exception if there is a problem obtaining the menu", "Convert this path address to its model node representation.\n\n@return the model node list of properties", "Gets the SerialMessage as a byte array.\n@return the message", "Returns a single template.\n\n@param id id of the template to retrieve.\n@return {@link Response}\n\n@throws RequestException if request to transloadit server fails.\n@throws LocalOperationException if something goes wrong while running non-http operations.", "Returns the y-coordinate of a vertex tangent.\n\n@param vertex the vertex index\n@return the y coordinate", "Configure all UI elements in the exceptions panel.", "Use this API to restore appfwprofile." ]
private void loadCadidateString() { volumeUp = mGvrContext.getActivity().getResources().getString(R.string.volume_up); volumeDown = mGvrContext.getActivity().getResources().getString(R.string.volume_down); zoomIn = mGvrContext.getActivity().getResources().getString(R.string.zoom_in); zoomOut = mGvrContext.getActivity().getResources().getString(R.string.zoom_out); invertedColors = mGvrContext.getActivity().getResources().getString(R.string.inverted_colors); talkBack = mGvrContext.getActivity().getResources().getString(R.string.talk_back); disableTalkBack = mGvrContext.getActivity().getResources().getString(R.string.disable_talk_back); }
[ "Load all string recognize." ]
[ "Determine whether the user has followed bean-like naming convention or not.", "Determines if entry is accepted. For normal usage, this means confirming that the key is\nneeded. For orphan usage, this simply means confirming the key belongs to the node.\n\n@param key\n@return true iff entry is accepted.", "Returns the full path of the resource file with extension.\n\n@return path of the GVRAndroidResource. May return null if the\nresource is not associated with any file", "Convert the message to a FinishRequest", "Create new multipart with a text part and an attachment\n\n@param msg Message text\n@param attachment Attachment data\n@param contentType MIME content type of body\n@param filename File name of the attachment\n@param description Description of the attachment\n@return New multipart", "Creates a window visually showing the matrix's state. Block means an element is zero.\nRed positive and blue negative. More intense the color larger the element's absolute value\nis.\n\n@param A A matrix.\n@param title Name of the window.", "Use this API to update nslimitselector resources.", "Get the upload parameters.\n@return", "Creates a new Product in Grapes database\n\n@param dbProduct DbProduct" ]
public Weld addExtension(Extension extension) { extensions.add(new MetadataImpl<Extension>(extension, SYNTHETIC_LOCATION_PREFIX + extension.getClass().getName())); return this; }
[ "Add an extension to the set of extensions.\n\n@param extension an extension" ]
[ "Find the latest task finish date. We treat this as the\nfinish date for the project.\n\n@return finish date", "Print channels to the left of log messages\n@param width The width (in characters) to print the channels\n@return this", "creates a point array of all dockers and add it to the current shape\n@param modelJSON\n@param current\n@throws org.json.JSONException", "Sets the site root.\n\n@param siteRoot the site root", "Generates the Base64 encoded SHA-1 hash for content available in the stream.\nIt can be used to calculate the hash of a file.\n@param stream the input stream of the file or data.\n@return the Base64 encoded hash string.", "Shows a dialog with user information for given session.\n\n@param session to show information for", "Adds an index to the table for the given index descriptor.\n\n@param indexDescDef The index descriptor\n@param tableDef The table", "Process StepStartedEvent. New step will be created and added to\nstepStorage.\n\n@param event to process", "Loads the leap second rules from a URL, often in a jar file.\n\n@param url the jar file to load, not null\n@throws Exception if an error occurs" ]
private void modifyBeliefCount(int count){ introspector.setBeliefValue(getLocalName(), Definitions.RECEIVED_MESSAGE_COUNT, getBeliefCount()+count, null); }
[ "Modifies the \"msgCount\" belief\n\n@param int - the number to add or remove" ]
[ "Wrap getOperationStatus to avoid throwing exception over JMX", "Clears the dest ColumnBuffer and inserts all entries in dest where the timestamp passes the\ntimestampTest.\n\n@param dest Destination ColumnBuffer\n@param timestampTest Test to determine which timestamps get added to dest", "Register the agent in the platform\n\n@param agent_name\nThe name of the agent to be registered\n@param agent\nThe agent to register.\n@throws FIPAException", "Saves changes in properties file. It reads the property file into memory, modifies it and saves it back to the file.\n\n@throws IOException", "Creates the full sentence.\n\n@return the mtas CQL parser sentence condition\n@throws ParseException the parse exception", "Create an index of base font numbers and their associated base\nfont instances.\n@param data property data", "We have received an update that invalidates the waveform preview for a player, so clear it and alert\nany listeners if this represents a change. This does not affect the hot cues; they will stick around until the\nplayer loads a new track that overwrites one or more of them.\n\n@param update the update which means we have no waveform preview for the associated player", "Close the open stream.\n\nClose the stream if it was opened before", "Process an individual UDF.\n\n@param udf UDF definition" ]
public int addServerGroup(String groupName, int profileId) throws Exception { int groupId = -1; PreparedStatement statement = null; ResultSet results = null; try (Connection sqlConnection = sqlService.getConnection()) { statement = sqlConnection.prepareStatement("INSERT INTO " + Constants.DB_TABLE_SERVER_GROUPS + "(" + Constants.GENERIC_NAME + "," + Constants.GENERIC_PROFILE_ID + ")" + " VALUES (?, ?);", PreparedStatement.RETURN_GENERATED_KEYS); statement.setString(1, groupName); statement.setInt(2, profileId); statement.executeUpdate(); results = statement.getGeneratedKeys(); if (results.next()) { groupId = results.getInt(1); } else { // something went wrong throw new Exception("Could not add group"); } } catch (SQLException e) { e.printStackTrace(); } finally { try { if (results != null) { results.close(); } } catch (Exception e) { } try { if (statement != null) { statement.close(); } } catch (Exception e) { } } return groupId; }
[ "Add a new server group\n\n@param groupName name of the group\n@param profileId ID of associated profile\n@return id of server group\n@throws Exception" ]
[ "Go through all node IDs and determine which node\n\n@param cluster\n@param storeRoutingPlan\n@return", "Gets the data handler from event.\n\n@param event the event\n@return the data handler", "Starts listening for shakes on devices with appropriate hardware.\n\n@return true if the device supports shake detection.", "Generate a map file from a jar file.\n\n@param jarFile jar file\n@param mapFileName map file name\n@param mapClassMethods true if we want to produce .Net style class method names\n@throws XMLStreamException\n@throws IOException\n@throws ClassNotFoundException\n@throws IntrospectionException", "Mapping originator.\n\n@param originator the originator\n@return the originator type", "Adds a member to this group with the specified role.\n@param user the member to be added to this group.\n@param role the role of the user in this group. Can be null to assign the default role.\n@return info about the new group membership.", "Reads the current properties for a language. If not already done, the properties are read from the respective file.\n@param locale the locale for which the localization should be returned.\n@return the properties.\n@throws IOException thrown if reading the properties from a file fails.\n@throws CmsException thrown if reading the properties from a file fails.", "is there a faster algorithm out there? This one is a bit sluggish", "Get the last non-white Y point\n@param img Image in memory\n@return The trimmed height" ]
private int runCommitScript() { if (m_checkout && !m_fetchAndResetBeforeImport) { m_logStream.println("Skipping script...."); return 0; } try { m_logStream.flush(); String commandParam; if (m_resetRemoteHead) { commandParam = resetRemoteHeadScriptCommand(); } else if (m_resetHead) { commandParam = resetHeadScriptCommand(); } else if (m_checkout) { commandParam = checkoutScriptCommand(); } else { commandParam = checkinScriptCommand(); } String[] cmd = {"bash", "-c", commandParam}; m_logStream.println("Calling the script as follows:"); m_logStream.println(); m_logStream.println(cmd[0] + " " + cmd[1] + " " + cmd[2]); ProcessBuilder builder = new ProcessBuilder(cmd); m_logStream.close(); m_logStream = null; Redirect redirect = Redirect.appendTo(new File(DEFAULT_LOGFILE_PATH)); builder.redirectOutput(redirect); builder.redirectError(redirect); Process scriptProcess = builder.start(); int exitCode = scriptProcess.waitFor(); scriptProcess.getOutputStream().close(); m_logStream = new PrintStream(new FileOutputStream(DEFAULT_LOGFILE_PATH, true)); return exitCode; } catch (InterruptedException | IOException e) { e.printStackTrace(m_logStream); return -1; } }
[ "Runs the shell script for committing and optionally pushing the changes in the module.\n@return exit code of the script." ]
[ "Returns information about all clients for a profile\n\n@param model\n@param profileIdentifier\n@return\n@throws Exception", "generate a message for loglevel DEBUG\n\n@param pObject the message Object", "For missing objects associated by one-to-one with another object in the\nresult set, register the fact that the object is missing with the\nsession.\n\ncopied form Loader#registerNonExists", "Returns the latest change events, and clears them from the change stream listener.\n\n@return the latest change events.", "used by Error template", "Return the IP address as text such as \"192.168.1.15\".", "Process any StepEvent. You can change last added to stepStorage\nstep using this method.\n\n@param event to process", "used by Error template", "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" ]
public void forAllCollectionDefinitions(String template, Properties attributes) throws XDocletException { for (Iterator it = _curClassDef.getCollections(); it.hasNext(); ) { _curCollectionDef = (CollectionDescriptorDef)it.next(); if (!isFeatureIgnored(LEVEL_COLLECTION) && !_curCollectionDef.getBooleanProperty(PropertyHelper.OJB_PROPERTY_IGNORE, false)) { generate(template); } } _curCollectionDef = null; }
[ "Processes the template for all collection definitions of the current class definition.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\[email protected] type=\"block\"" ]
[ "Method to initialize the list.\n\n@param resList a given instance or null\n@return an instance", "Gets the name of the vertex attribute containing the texture\ncoordinates for the named texture.\n\n@param texName name of texture\n@return name of texture coordinate vertex attribute", "Extracts the column from a matrix.\n@param a Input matrix\n@param column Which column is to be extracted\n@param out output. Storage for the extracted column. If null then a new vector will be returned.\n@return The extracted column.", "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.", "Begin writing a named object attribute.\n\n@param name attribute name", "Helper for reading a mandatory String value list - throwing an Exception if parsing fails.\n@param json The JSON object where the list should be read from.\n@param key The key of the value to read.\n@return The value from the JSON.\n@throws JSONException thrown when parsing fails.", "Use this context as prototype for a new mutable builder. The new builder is\npre-populated with the current settings of this context instance.", "Use this API to fetch the statistics of all appfwprofile_stats resources that are configured on netscaler.", "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" ]
private boolean readNextRow() { while (!stop) { String row = getLineWrapped(); // end of stream - null indicates end of stream before we see last_seq which shouldn't // be possible but we should handle it if (row == null || row.startsWith("{\"last_seq\":")) { terminate(); return false; } else if (row.isEmpty()) { // heartbeat continue; } setNextRow(gson.fromJson(row, ChangesResult.Row.class)); return true; } // we were stopped, end of changes feed terminate(); return false; }
[ "Reads and sets the next feed in the stream." ]
[ "generate a prepared INSERT-Statement for the Class\ndescribed by cld.\n\n@param cld the ClassDescriptor", "Setter for the file format.\n@param fileFormat File format the configuration file is in.", "Concatenate all the arrays in the list into a vector.\n\n@param arrays List of arrays.\n@return Vector.", "converts Map of data to json string\n\n@param data map data to converted to json\n@return {@link String}", "Set the order in which sets are returned for the user.\n\nThis method requires authentication with 'write' permission.\n\n@param photosetIds\nAn array of Ids\n@throws FlickrException", "Obtain parameters from query\n\n@param query query to scan\n@return Map of parameters", "Gets the JVM memory usage.\n\n@return the JVM memory usage", "Searches for commas in the set of tokens. Used for inputs to functions.\n\nIgnore comma's which are inside a [ ] block\n\n@return List of output tokens between the commas", "Processes a stencilset template file\n@throws IOException" ]
public void poseFromBones() { for (int i = 0; i < getNumBones(); ++i) { GVRSceneObject bone = mBones[i]; if (bone == null) { continue; } if ((mBoneOptions[i] & BONE_LOCK_ROTATION) != 0) { continue; } GVRTransform trans = bone.getTransform(); mPose.setLocalMatrix(i, trans.getLocalModelMatrix4f()); } mPose.sync(); updateBonePose(); }
[ "Applies the matrices computed from the scene object's\nlinked to the skeleton bones to the current pose.\n@see #applyPose(GVRPose, int)\n@see #setPose(GVRPose)" ]
[ "Map the EventType.\n\n@param eventType the event type\n@return the event", "Log column data.\n\n@param column column data", "Saves the favorites.\n\n@param favorites the list of favorites to save\n@throws CmsException if something goes wrong", "Complete timing the operation with the given identifier. If you had not previously started a timing operation with this identifier, then this\nwill effectively be a noop.", "Called on mouse up in the caption area, ends dragging by ending event\ncapture.\n\n@param event the mouse up event that ended dragging\n\n@see DOM#releaseCapture\n@see #beginDragging\n@see #endDragging", "Renders in LI tags, Wraps with UL tags optionally.", "Returns the full path of the resource file with extension.\n\n@return path of the GVRAndroidResource. May return null if the\nresource is not associated with any file", "Use this API to add ntpserver resources.", "Set the serial pattern type.\n@param patternType the pattern type to set." ]
public void subscriptionRequestReceived(SubscriptionRequest sr) throws SubscriptionException { LOG.info("Subscriber -> (Hub), new subscription request received.", sr.getCallback()); try { verifySubscriberRequestedSubscription(sr); if ("subscribe".equals(sr.getMode())) { LOG.info("Adding callback {} to the topic {}", sr.getCallback(), sr.getTopic()); addCallbackToTopic(sr.getCallback(), sr.getTopic()); } else if ("unsubscribe".equals(sr.getMode())) { LOG.info("Removing callback {} from the topic {}", sr.getCallback(), sr.getTopic()); removeCallbackToTopic(sr.getCallback(), sr.getTopic()); } } catch (Exception e) { throw new SubscriptionException(e); } }
[ "Input method, called by a Subscriber indicating its intent into receive notification about a given topic.\n\n@param sr DTO containing the info given by the protocol" ]
[ "Remove contents from the deployment and attach a \"transformed\" slave operation to the operation context.\n\n@param context the operation context\n@param operation the original operation\n@param contentRepository the content repository\n@return the hash of the uploaded deployment content\n@throws IOException\n@throws OperationFailedException", "Return a Halton number, sequence starting at index = 0, base &gt; 1.\n\n@param index The index of the sequence.\n@param base The base of the sequence. Has to be greater than one (this is not checked).\n@return The Halton number.", "Prep for a new connection\n@return if stats are enabled, return the nanoTime when this connection was requested.\n@throws SQLException", "On host controller reload, remove a not running server registered in the process controller declared as down.", "Read an optional boolean value form a JSON Object.\n@param json the JSON object to read from.\n@param key the key for the boolean value in the provided JSON object.\n@return the boolean or null if reading the boolean fails.", "these are the iterators used by MACAddress", "Shrinks the alert message body so that the resulting payload\nmessage fits within the passed expected payload length.\n\nThis method performs best-effort approach, and its behavior\nis unspecified when handling alerts where the payload\nwithout body is already longer than the permitted size, or\nif the break occurs within word.\n\n@param payloadLength the expected max size of the payload\n@param postfix for the truncated body, e.g. \"...\"\n@return this", "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", "This method extracts predecessor data from a Planner file.\n\n@param plannerTask Task data" ]
void release() { if (mCurrentRequests != null) { synchronized (mCurrentRequests) { mCurrentRequests.clear(); mCurrentRequests = null; } } if (mDownloadQueue != null) { mDownloadQueue = null; } if (mDownloadDispatchers != null) { stop(); for (int i = 0; i < mDownloadDispatchers.length; i++) { mDownloadDispatchers[i] = null; } mDownloadDispatchers = null; } }
[ "Cancels all the pending & running requests and releases all the dispatchers." ]
[ "Checks that arguments and parameter types match.\n@param params method parameters\n@param args type arguments\n@return -1 if arguments do not match, 0 if arguments are of the exact type and >0 when one or more argument is\nnot of the exact type but still match", "Check that each emitted notification is properly described by its source.", "Gets the JsonObject representation of the Field Operation.\n@param fieldOperation represents the template update operation\n@return the json object", "Use this API to fetch all the systemeventhistory resources that are configured on netscaler.\nThis uses systemeventhistory_args which is a way to provide additional arguments while fetching the resources.", "Initialize dates panel elements.", "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)", "convert Event bean to EventType manually.\n\n@param event the event\n@return the event type", "Logs binary string as hexadecimal", "Use this API to update vpnclientlessaccesspolicy." ]
public ImmutableList<CandidateElement> extract(StateVertex currentState) throws CrawljaxException { LinkedList<CandidateElement> results = new LinkedList<>(); if (!checkedElements.checkCrawlCondition(browser)) { LOG.info("State {} did not satisfy the CrawlConditions.", currentState.getName()); return ImmutableList.of(); } LOG.debug("Looking in state: {} for candidate elements", currentState.getName()); try { Document dom = DomUtils.asDocument(browser.getStrippedDomWithoutIframeContent()); extractElements(dom, results, ""); } catch (IOException e) { LOG.error(e.getMessage(), e); throw new CrawljaxException(e); } if (randomizeElementsOrder) { Collections.shuffle(results); } currentState.setElementsFound(results); LOG.debug("Found {} new candidate elements to analyze!", results.size()); return ImmutableList.copyOf(results); }
[ "This method extracts candidate elements from the current DOM tree in the browser, based on\nthe crawl tags defined by the user.\n\n@param currentState the state in which this extract method is requested.\n@return a list of candidate elements that are not excluded.\n@throws CrawljaxException if the method fails." ]
[ "Process a single criteria block.\n\n@param list parent criteria list\n@param block current block", "Get the max extent as a envelop object.", "Whether the specified JavaBeans property exists on the given type or not.\n\n@param clazz the type of interest\n@param property the JavaBeans property name\n@param elementType the element type to check, must be either {@link ElementType#FIELD} or\n{@link ElementType#METHOD}.\n@return {@code true} if the specified property exists, {@code false} otherwise", "Processes the template for all index descriptors of the current class definition.\n\n@param template The template\n@param attributes The attributes of the tag\n@exception XDocletException if an error occurs\[email protected] type=\"block\"", "Populates a relation list.\n\n@param task parent task\n@param field target task field\n@param data MPX relation list data", "Apply a filter to the list of all resources, and show the results.\n\n@param project project file\n@param filter filter", "Import CountryList from RAW resource\n\n@param context Context\n@return CountryList", "Prepare a parallel HTTP POST Task.\n\n@param url\nthe UrlPostfix: e.g. in http://localhost:8080/index.html.,the url is \"/index.html\"\n@return the parallel task builder", "Send a metadata cache update announcement to all registered listeners.\n\n@param slot the media slot whose cache status has changed\n@param cache the cache which has been attached, or, if {@code null}, the previous cache has been detached" ]
public void replace( Token original , Token target ) { if( first == original ) first = target; if( last == original ) last = target; target.next = original.next; target.previous = original.previous; if( original.next != null ) original.next.previous = target; if( original.previous != null ) original.previous.next = target; original.next = original.previous = null; }
[ "Removes 'original' and places 'target' at the same location" ]
[ "Get the content-type, including the optional \";base64\".", "Copy the contents of the given InputStream into a String.\nLeaves the stream open when done.\n@param in the InputStream to copy from\n@return the String that has been copied to\n@throws IOException in case of I/O errors", "Checks to see if the two matrices are inverses of each other.\n\n@param a A matrix. Not modified.\n@param b A matrix. Not modified.", "Print a resource type.\n\n@param value ResourceType instance\n@return resource type value", "Dump the contents of a row from an MPD file.\n\n@param row row data", "Sets the real offset.\n\n@param start the start\n@param end the end", "Finds for the given project.\n\n@param name project name\n@return given project or an empty {@code Optional} if project does not exist\n@throws IllegalArgumentException", "Checks if two types are the same or are equivalent under a variable\nmapping given in the type map that was provided.", "Get the photos for the specified group pool, optionally filtering by taf.\n\nThis method does not require authentication.\n\n@see com.flickr4java.flickr.photos.Extras\n@param groupId\nThe group ID\n@param userId\nThe user ID (may be null)\n@param tags\nThe optional tags (may be null)\n@param extras\nSet of extra-attributes to include (may be null)\n@param perPage\nThe number of photos per page (0 to ignore)\n@param page\nThe page offset (0 to ignore)\n@return A Collection of Photo objects\n@throws FlickrException" ]
public static base_responses unset(nitro_service client, String username[], String args[]) throws Exception { base_responses result = null; if (username != null && username.length > 0) { systemuser unsetresources[] = new systemuser[username.length]; for (int i=0;i<username.length;i++){ unsetresources[i] = new systemuser(); unsetresources[i].username = username[i]; } result = unset_bulk_request(client, unsetresources,args); } return result; }
[ "Use this API to unset the properties of systemuser resources.\nProperties that need to be unset are specified in args array." ]
[ "Determines if a mouse event is inside a box.", "Get an exception reporting a missing, required XML child element.\n@param reader the stream reader\n@param required a set of enums whose toString method returns the\nattribute name\n@return the exception", "Removes double-quotes from around a string\n@param str\n@return", "This method writes project extended attribute data into an MSPDI file.\n\n@param project Root node of the MSPDI file", "Load the given metadata profile for the current thread.", "Retrieve and validate the timeout value from the REST request.\n\"X_VOLD_REQUEST_TIMEOUT_MS\" is the timeout header.\n\n@return true if present, false if missing", "For internal use! This method creates real new PB instances", "This method is called to alert project listeners to the fact that\na relation has been written to a project file.\n\n@param relation relation instance", "Validates the inputed color value.\n@param colorvalue the value of the color\n@return true if the inputed color value is valid" ]
@Beta public MSICredentials withObjectId(String objectId) { this.objectId = objectId; this.clientId = null; this.identityId = null; return this; }
[ "Specifies the object id associated with a user assigned managed service identity\nresource that should be used to retrieve the access token.\n\n@param objectId Object ID of the identity to use when authenticating to Azure AD.\n@return MSICredentials" ]
[ "Manual check because introducing a capability can't be done without a full refactoring.\nThis has to go as soon as the management interfaces are redesigned.\n@param context the OperationContext\n@param otherManagementEndpoint : the address to check that may provide an exposed jboss-remoting endpoint.\n@throws OperationFailedException in case we can't remove the management resource.", "Initialize the field factories for the messages table.", "Try to set specified property to given marshaller\n\n@param marshaller specified marshaller\n@param name name of property to set\n@param value value of property to set", "Gets the property and casts to the appropriate type\n\n@param <T>\n@param key The property name\n@param type The property type\n@return The value of the property", "Authenticates the API connection for Box Developer Edition.", "List all the environment variables for an app.\n@param appName App name. See {@link #listApps} for a list of apps that can be used.\n@return map of config vars", "Write a long attribute.\n\n@param name attribute name\n@param value attribute value", "Removes trailing and leading whitespace, and also reduces each\nsequence of internal whitespace to a single space.", "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" ]
private static Constructor retrieveCollectionProxyConstructor(Class proxyClass, Class baseType, String typeDesc) { if(proxyClass == null) { throw new MetadataException("No " + typeDesc + " specified."); } if(proxyClass.isInterface() || Modifier.isAbstract(proxyClass.getModifiers()) || !baseType.isAssignableFrom(proxyClass)) { throw new MetadataException("Illegal class " + proxyClass.getName() + " specified for " + typeDesc + ". Must be a concrete subclass of " + baseType.getName()); } Class[] paramType = {PBKey.class, Class.class, Query.class}; try { return proxyClass.getConstructor(paramType); } catch(NoSuchMethodException ex) { throw new MetadataException("The class " + proxyClass.getName() + " specified for " + typeDesc + " is required to have a public constructor with signature (" + PBKey.class.getName() + ", " + Class.class.getName() + ", " + Query.class.getName() + ")."); } }
[ "Retrieves the constructor that is used by OJB to create instances of the given collection proxy\nclass.\n\n@param proxyClass The proxy class\n@param baseType The required base type of the proxy class\n@param typeDesc The type of collection proxy\n@return The constructor" ]
[ "Get a bean from the application context. Returns null if the bean does not exist.\n@param name name of bean\n@param requiredType type of bean\n@return the bean or null", "Count the number of occurrences of a sub CharSequence.\n\n@param self a CharSequence\n@param text a sub CharSequence\n@return the number of occurrences of the given CharSequence inside this CharSequence\n@see #count(String, String)\n@since 1.8.2", "2-D Forward Discrete Cosine Transform.\n\n@param data Data.", "Get all categories\nGet all tags marked as categories\n@return ApiResponse&lt;TagsEnvelope&gt;\n@throws ApiException If fail to call the API, e.g. server error or cannot deserialize the response body", "User-initiated commands use this method.\n\n@param command The CLI command\n@return A Response object containing the command line, DMR request, and DMR response\n@throws CommandFormatException\n@throws IOException", "Append the given path segments to the existing path of this builder.\nEach given path segment may contain URI template variables.\n@param pathSegments the URI path segments\n@return this UriComponentsBuilder", "Get permissions for who may view geo data for a photo.\n\nThis method requires authentication with 'read' permission.\n\n@param photoId\nreqired photo id, not null\n@return the permissions\n@throws FlickrException\nif photo id is invalid, if photo has no geodata or if any other error has been reported in the response.", "Begin a \"track;\" that is, begin logging at one level deeper.\nChannels other than the FORCE channel are ignored.\n@param args The title of the track to begin, with an optional FORCE flag.", "Checks whether the folder exists for fileName, and creates it if necessary.\n\n@param fileName folder name.\n@throws IOException an IO exception." ]
private Set<String> findResourceNamesFromFileSystem(String classPathRootOnDisk, String scanRootLocation, File folder) { LOGGER.debug("Scanning for resources in path: {} ({})", folder.getPath(), scanRootLocation); File[] files = folder.listFiles(); if (files == null) { return emptySet(); } Set<String> resourceNames = new TreeSet<>(); for (File file : files) { if (file.canRead()) { if (file.isDirectory()) { resourceNames.addAll(findResourceNamesFromFileSystem(classPathRootOnDisk, scanRootLocation, file)); } else { resourceNames.add(toResourceNameOnClasspath(classPathRootOnDisk, file)); } } } return resourceNames; }
[ "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;" ]
[ "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", "Converts an object to an instance of the target type.\n\n@param mapper the object mapper\n@param source the source to convert\n@param targetType the target class type\n@return target instance\n@see SquigglyUtils#objectify(ObjectMapper, Object, Class)", "Synchronize the scroll positions of the scrollbars with the actual scroll\nposition of the content.", "Sets the hostname and port to connect to.\n\n@param hostname the host name\n@param port the port\n\n@return the builder", "Updates an existing enum option. Enum custom fields require at least one enabled enum option.\n\nReturns the full record of the updated enum option.\n\n@param enumOption Globally unique identifier for the enum option.\n@return Request object", "Create the close button UI Component.\n@return the close button.", "End building the prepared script, adding a return value statement\n@param value the value to return\n@param config the configuration for the script to build\n@return the new {@link LuaPreparedScript} instance", "Returns the specified process time out in milliseconds.\n\n@return The process time out in milliseconds.", "Emits a sentence fragment combining all the merge actions." ]
private void updateBaseCalendarNames(List<Pair<ProjectCalendar, Integer>> baseCalendars) { for (Pair<ProjectCalendar, Integer> pair : baseCalendars) { ProjectCalendar cal = pair.getFirst(); Integer baseCalendarID = pair.getSecond(); ProjectCalendar baseCal = m_calendarMap.get(baseCalendarID); if (baseCal != null) { cal.setParent(baseCal); } } }
[ "The way calendars are stored in an MPP8 file means that there\ncan be forward references between the base calendar unique ID for a\nderived calendar, and the base calendar itself. To get around this,\nwe initially populate the base calendar name attribute with the\nbase calendar unique ID, and now in this method we can convert those\nID values into the correct names.\n\n@param baseCalendars list of calendars and base calendar IDs" ]
[ "Create a JsonParser for a given json node.\n@param jsonNode the json node\n@return the json parser\n@throws IOException", "Pool configuration.\n@param props\n@throws HibernateException", "Creates a XopBean. The image on the disk is included as a byte array,\na DataHandler and java.awt.Image\n@return the bean\n@throws Exception", "Assemble the configuration section of the URL.", "Create a temporary directory with the same attributes as its parent directory.\n@param dir\nthe path to directory in which to create the directory\n@param prefix\nthe prefix string to be used in generating the directory's name;\nmay be {@code null}\n@return the path to the newly created directory that did not exist before\nthis method was invoked\n@throws IOException", "Specify the socket to be used as underlying socket to connect\nto the APN service.\n\nThis assumes that the socket connects to a SOCKS proxy.\n\n@deprecated use {@link ApnsServiceBuilder#withProxy(Proxy)} instead\n@param proxySocket the underlying socket for connections\n@return this", "Parses the equation and compiles it into a sequence which can be executed later on\n@param equation String in simple equation format.\n@param assignment if true an assignment is expected and an exception if thrown if there is non\n@param debug if true it will print out debugging information\n@return Sequence of operations on the variables", "Returns the class of datatype URI that best characterizes the range of\nthe given property based on its datatype.\n\n@param propertyIdValue\nthe property for which to get a range\n@return the range URI or null if the datatype could not be identified.", "Returns the bundle descriptor for the bundle with the provided base name.\n@param cms {@link CmsObject} used for searching.\n@param basename the bundle base name, for which the descriptor is searched.\n@return the bundle descriptor, or <code>null</code> if it does not exist or searching fails." ]
public boolean handleKeyDeletion(final String key) { if (m_keyset.getKeySet().contains(key)) { if (removeKeyForAllLanguages(key)) { m_keyset.removeKey(key); return true; } else { return false; } } return true; }
[ "Handles the deletion of a key.\n@param key the deleted key.\n@return <code>true</code> if the deletion was successful, <code>false</code> otherwise." ]
[ "Returns the corresponding mac section, or null if this address section does not correspond to a mac section.\nIf this address section has a prefix length it is ignored.\n\n@param extended\n@return", "Converts a number of bytes to a human-readable string\n@param bytes the bytes\n@return the human-readable string", "Add authentication information for the given host\n@param host the host\n@param credentials the credentials\n@param authScheme the scheme for preemptive authentication (should be\n<code>null</code> if adding authentication for a proxy server)\n@param context the context in which the authentication information\nshould be saved", "Register a new PerformanceMonitor with Spring if it does not already exist.\n\n@param beanName The name of the bean that this performance monitor is wrapped around\n@param registry The registry where all the spring beans are registered", "Convert an Object to a DateTime, without an Exception", "note that for read from file, this will just load all to memory. not fit\nif need to read a very large file. However for getting the host name.\nnormally it is fine.\n\nfor reading large file, should use iostream.\n\n@param sourcePath\nthe source path\n@param sourceType\nthe source type\n@return the content from path\n@throws IOException\nSignals that an I/O exception has occurred.", "Get all field attributes in an unmodifiable Map, or null if no attributes have been added\n\n@return all field attributes, or <code>NULL</code> if none exist", "Make a composite filter from the given sub-filters using AND to combine filters.", "Returns a map of URIs to package name, as specified by the packageNames\nparameter." ]
private void populateCalendarHours(Record record, ProjectCalendarHours hours) throws MPXJException { hours.setDay(Day.getInstance(NumberHelper.getInt(record.getInteger(0)))); addDateRange(hours, record.getTime(1), record.getTime(2)); addDateRange(hours, record.getTime(3), record.getTime(4)); addDateRange(hours, record.getTime(5), record.getTime(6)); }
[ "Populates a calendar hours instance.\n\n@param record MPX record\n@param hours calendar hours instance\n@throws MPXJException" ]
[ "Register a new SingleServiceWrapperInterceptor for the bean being\nwrapped, associate it with the PerformanceMonitor and tell it which methods\nto intercept.\n\n@param source An Attribute node from the spring configuration\n@param beanName The name of the bean that this performance monitor is wrapped around\n@param registry The registry where all the spring beans are registered", "Creates a map of identifiers or page titles to documents retrieved via\nthe API URL\n\n@param properties\nparameter setting for wbgetentities\n@return map of document identifiers or titles to documents retrieved via\nthe API URL\n@throws MediaWikiApiErrorException\nif the API returns an error\n@throws IOException\nif we encounter network issues or HTTP 500 errors from Wikibase", "Provides a RunAs client login context", "Gets the Kullback Leibler divergence.\n\n@param p P vector.\n@param q Q vector.\n@return The Kullback Leibler divergence between u and v.", "Given a date represented by a Calendar instance, set the time\ncomponent of the date based on the hours and minutes of the\ntime supplied by the Date instance.\n\n@param cal Calendar instance representing the date\n@param time Date instance representing the time of day", "Return the lines of a CharSequence as a List of String.\n\n@param self a CharSequence object\n@return a list of lines\n@throws java.io.IOException if an error occurs\n@since 1.8.2", "Checks the given model.\n\n@param modelDef The model\n@param checkLevel The amount of checks to perform\n@exception ConstraintException If a constraint has been violated", "This method writes calendar data to an MSPDI file.\n\n@param project Root node of the MSPDI file", "Use this API to update responderparam." ]
public void publish() { CmsDirectPublishDialogAction action = new CmsDirectPublishDialogAction(); List<CmsResource> resources = getBundleResources(); I_CmsDialogContext context = new A_CmsDialogContext("", ContextType.appToolbar, resources) { public void focus(CmsUUID structureId) { //Nothing to do. } public List<CmsUUID> getAllStructureIdsInView() { return null; } public void updateUserInfo() { //Nothing to do. } }; action.executeAction(context); updateLockInformation(); }
[ "Publish the bundle resources directly." ]
[ "Use this API to fetch the statistics of all appfwpolicylabel_stats resources that are configured on netscaler.", "Restores a trashed file to a new location with a new name.\n@param fileID the ID of the trashed file.\n@param newName an optional new name to give the file. This can be null to use the file's original name.\n@param newParentID an optional new parent ID for the file. This can be null to use the file's original\nparent.\n@return info about the restored file.", "Stops listening. Safe to call when already stopped. Ignored on devices\nwithout appropriate hardware.", "Returns all headers with the headers from the Payload\n\n@return All the headers", "Copy the given Collection into a Class array.\nThe Collection must contain Class elements only.\n@param collection the Collection to copy\n@return the Class array ({@code null} if the passed-in\nCollection was {@code null})", "Convert event type.\n\n@param eventType the event type\n@return the event enum type", "The third method to write caseManager. Its task is to write the call to\nthe story to be run.\n\n@param caseManager\nthe file where the test must be written\n@param storyName\nthe name of the story\n@param test_path\nthe path where the story can be found\n@param user\nthe user requesting the story\n@param feature\nthe feature requested by the user\n@param benefit\nthe benefit provided by the feature\n@throws BeastException", "Returns the name of the class to be instantiated.\n@param rs the Resultset\n@return null if the column is not available", "Helper to read an optional String value list.\n@param path The XML path of the element to read.\n@return The String list stored in the XML, or <code>null</code> if the value could not be read." ]
public void fireEvent(Type eventType, Object event, Annotation... qualifiers) { final EventMetadata metadata = new EventMetadataImpl(eventType, null, qualifiers); notifier.fireEvent(eventType, event, metadata, qualifiers); }
[ "Fire an event and notify observers that belong to this module.\n@param eventType\n@param event\n@param qualifiers" ]
[ "Gets the flags associated with this attribute.\n@return the flags. Will not return {@code null}", "Use this API to fetch all the configstatus resources that are configured on netscaler.", "Create and return a new Violation for this rule and the specified import className and alias\n@param sourceCode - the SourceCode\n@param className - the class name (as specified within the import statement)\n@param alias - the alias for the import statement\n@param violationMessage - the violation message; may be null\n@return a new Violation object", "Release the broker instance.", "Creates an operation to list the deployments.\n\n@return the operation", "Formats a percentage value.\n\n@param number MPXJ percentage value\n@return Primavera percentage value", "Checks the initialization-method of given class descriptor.\n\n@param classDef The class descriptor\n@param checkLevel The current check level (this constraint is only checked in strict)\n@exception ConstraintException If the constraint has been violated", "Overridden to add transform.", "Removes an element from the observation matrix.\n\n@param index which element is to be removed" ]
public static String expandLine(CharSequence self, int tabStop) { String s = self.toString(); int index; while ((index = s.indexOf('\t')) != -1) { StringBuilder builder = new StringBuilder(s); int count = tabStop - index % tabStop; builder.deleteCharAt(index); for (int i = 0; i < count; i++) builder.insert(index, " "); s = builder.toString(); } return s; }
[ "Expands all tabs into spaces. Assumes the CharSequence represents a single line of text.\n\n@param self A line to expand\n@param tabStop The number of spaces a tab represents\n@return The expanded toString() of this CharSequence\n@see #expandLine(String, int)\n@since 1.8.2" ]
[ "Return a list of the top 100 unique places clustered by a given placetype for a user.\n\n@param placeType\nUse Type-constants at {@link Place}\n@param woeId\nA Where On Earth (WOE) ID. Optional, can be null.\n@param placeId\nA Flickr Places ID. Optional, can be null.\n@param threshold\nThe minimum number of photos that a place type must have to be included. If the number of photos is lowered then the parent place type for\nthat place will be used. Optional, can be null.\n@param minUploadDate\nOptional, can be null.\n@param maxUploadDate\nOptional, can be null.\n@param minTakenDate\nOptional, can be null.\n@param maxTakenDate\nOptional, can be null.\n@return A PlacesList\n@throws FlickrException", "The document field must not exist in the list provided\n@param rhs The argument - one or more values\n@return PredicateExpression: $nin rhs", "Sends a multipart response. Each body part represents a versioned value\nof the given key.\n\n@throws IOException\n@throws MessagingException", "Returns a new index creation statement using the session's keyspace.\n\n@param keyspace the keyspace name\n@param table the table name\n@param name the index name\n@return a new index creation statement", "return either the first space or the first nbsp", "The Critical field indicates whether a task has any room in the schedule\nto slip, or if a task is on the critical path. The Critical field contains\nYes if the task is critical and No if the task is not critical.\n\n@return boolean", "Function to serialize the given Vector clock into a string. If something\ngoes wrong, it returns an empty string.\n\n@param vc The Vector clock to serialize\n@return The string (JSON) version of the specified Vector clock", "Use this API to fetch autoscaleaction resource of given name .", "Reads a markdown link ID.\n\n@param out\nThe StringBuilder to write to.\n@param in\nInput String.\n@param start\nStarting position.\n@return The new position or -1 if this is no valid markdown link ID." ]
private void setUserFieldValue(UDFAssignmentType udf, DataType dataType, Object value) { switch (dataType) { case DURATION: { udf.setTextValue(((Duration) value).toString()); break; } case CURRENCY: { if (!(value instanceof Double)) { value = Double.valueOf(((Number) value).doubleValue()); } udf.setCostValue((Double) value); break; } case BINARY: { udf.setTextValue(""); break; } case STRING: { udf.setTextValue((String) value); break; } case DATE: { udf.setStartDateValue((Date) value); break; } case NUMERIC: { if (!(value instanceof Double)) { value = Double.valueOf(((Number) value).doubleValue()); } udf.setDoubleValue((Double) value); break; } case BOOLEAN: { udf.setIntegerValue(BooleanHelper.getBoolean((Boolean) value) ? Integer.valueOf(1) : Integer.valueOf(0)); break; } case INTEGER: case SHORT: { udf.setIntegerValue(NumberHelper.getInteger((Number) value)); break; } default: { throw new RuntimeException("Unconvertible data type: " + dataType); } } }
[ "Sets the value of a UDF.\n\n@param udf user defined field\n@param dataType MPXJ data type\n@param value field value" ]
[ "Use this API to update ntpserver resources.", "Detects if the current device is a mobile device.\nThis method catches most of the popular modern devices.\nExcludes Apple iPads and other modern tablets.\n@return detection of any mobile device using the quicker method", "Use this API to fetch tmsessionpolicy_binding resource of given name .", "Convert weekly recurrence days into a bit field.\n\n@param task recurring task\n@return bit field as a string", "Append the text at the end of the File, using a specified encoding.\n\n@param file a File\n@param text the text to append at the end of the File\n@param charset the charset used\n@throws IOException if an IOException occurs.\n@since 1.0", "Is alternative.\n\n@param annotated the annotated\n@param mergedStereotypes merged stereotypes\n@return true if alternative, false otherwise", "Deploys application reading resources from specified classpath location\n\n@param applicationName to configure in cluster\n@param classpathLocations where resources are read\n@throws IOException", "Read resource assignment baseline values.\n\n@param row result set row", "Given a container, and a set of raw data blocks, this method extracts\nthe field data and writes it into the container.\n\n@param type expected type\n@param container field container\n@param id entity ID\n@param fixedData fixed data block\n@param varData var data block" ]