code
stringlengths
10
174k
nl
stringlengths
3
129k
protected SecretKey engineGenerateKey(){ SecretKeySpec aesKey=null; if (this.random == null) { this.random=SunJCE.getRandom(); } byte[] keyBytes=new byte[keySize]; this.random.nextBytes(keyBytes); aesKey=new SecretKeySpec(keyBytes,"AES"); return aesKey; }
Generates the AES key.
default Builder withDatabase(String databaseName){ return with(DATABASE,databaseName); }
Use the given database name in the resulting configuration.
private final void _writeStringSegments(String text) throws IOException, JsonGenerationException { int left=text.length(); int offset=0; final char[] cbuf=_charBuffer; while (left > 0) { int len=Math.min(_outputMaxContiguous,left); text.getChars(offset,offset + len,cbuf,0); if ((_outputTail + len) >...
Method called when String to write is long enough not to fit completely in temporary copy buffer. If so, we will actually copy it in small enough chunks so it can be directly fed to single-segment writes (instead of maximum slices that would fit in copy buffer)
private void updateLessThanGwt25(List<String> programArgs,int indexDisabled,int indexEnabled){ if (indexDisabled > -1) { programArgs.remove(indexDisabled); } if (indexEnabled > -1) { programArgs.remove(indexEnabled); } }
Update program args for projects GWT < 2.5 that can't support Super Dev Mode, be sure that the arguments don't get used ever.
public void deleteLayoutBlock(LayoutBlock block){ deregister(block); }
Remove an existing LayoutBlock.
@Override public boolean isActive(){ return amIActive; }
Used by the Whitebox GUI to tell if this plugin is still running.
public void downloadFile(File file,String rootPassword,String sshPort,String dockerManagerAddress,String completeFilePath) throws CheckException { Channel channel=null; try { String dockerManagerIP=dockerManagerAddress.substring(0,dockerManagerAddress.length() - 5); channel=this.getSession("root",rootPasswo...
TODO : COMMENT
static String indentXPathText(String xp){ if ((xp.length() > 2) && (!Character.isWhitespace(xp.charAt(0)))) { return "\n" + xp + "\n"; } return xp; }
Method indentXPathText
public static boolean isWater(Block block){ if (block == null) return false; return block.getMaterial() == Material.water; }
Determines if block is a water block
protected void analyze(){ Arrays.asList(this.dto.getMethods()).stream().filter(null).forEach(null); fieldAttributes.entrySet().stream().forEach(null); }
Scan all getter/setter/with methods that are not inherited
public void mark(int readAheadLimit) throws IOException { synchronized (lock) { ensureOpen(); markedPos=pos; } }
Marks the present position in the stream. Subsequent calls to reset() will reposition the stream to this point.
@Override public void extentWrite(ObjectReference src,Address slot,Extent value,Word metaDataA,Word metaDataB,int mode){ VM.barriers.extentWrite(src,value,metaDataA,metaDataB,mode); }
Write an Extent. Take appropriate write barrier actions.
public JSONObject fetchDiff() throws IOException, ConduitAPIException { JSONObject params=new JSONObject().element("ids",new String[]{diffID}); JSONObject query=this.callConduit("differential.querydiffs",params); JSONObject response; try { response=query.getJSONObject("result"); } catch ( JSONException ...
Fetch a differential from Conduit
public Boolean hasBeenStopped(){ return runner.hasBeenStopped(); }
This method can be used to check if the environment has been stopped prematurely by e.g. a timeout.
@Override public void close(){ if (null != m_chunkcollector) { m_chunkcollector.close(); m_chunkcollector=null; } if (null != m_bufcollector) { m_bufcollector.close(); m_bufcollector=null; } }
close both of resource collectors for this allocator
public boolean elementAvailable(String ns,String elemName) throws javax.xml.transform.TransformerException { return false; }
Is the extension element available?
@Override public void run(){ amIActive=true; String inputFile; String outputHeader; String assignmentFieldName; int assignmentFieldNum=-1; String baseFileHeader="not specified"; double backgroundValue=0; int row, col; double rowYCoord, colXCoord, value, z; int progress=0; double cellSize=-1.0; i...
Used to execute this plugin tool.
@Override public TemporaryQueue createTemporaryQueue() throws JMSException { if (cri.getType() == ActiveMQRAConnectionFactory.TOPIC_CONNECTION || cri.getType() == ActiveMQRAConnectionFactory.XA_TOPIC_CONNECTION) { throw new IllegalStateException("Cannot create temporary queue for javax.jms.TopicSession"); } l...
Create a temporary queue
public UniqueIdentity(DerValue derVal) throws IOException { id=derVal.getUnalignedBitString(true); }
Create the object, decoding the values from the passed DER stream.
public static void removeQueryListener(IQueryListener l){ InternalSearchUI.getInstance().removeQueryListener(l); }
Removes the given query listener. Does nothing if the listener is not present.
@Override public void execute(StepInstance stepInstance,String temporaryFileDirectory){ Map<String,RawProtein<PirsfHmmer3RawMatch>> rawMatches=rawMatchDAO.getRawMatchesForProteinIdsInRange(stepInstance.getBottomProtein(),stepInstance.getTopProtein(),signatureLibraryRelease); try { Map<String,RawProtein<PirsfHmm...
This method is called to execute the action that the StepInstance must perform. <p/> If an error occurs that cannot be immediately recovered from, the implementation of this method MUST throw a suitable Exception, as the call to execute is performed within a transaction with the reply to the JMSBroker.
public void stop(int delay){ httpSrv.stop(delay); }
Stops server by closing the listening socket and disallowing any new exchanges from being processed.
private static void checkAxisBounds(Axis axis){ if ((axis.getMin().doubleValue() < 0.0) || (axis.getMax().doubleValue() < 0.0)) { throw new IllegalStateException("Axis bounds must be greater than or equal to zero for logarithmic axes."); } }
Utility method that makes sure that axis bounds comply to rules of logarithmic axes.
public Object visit(ASTElseStatement node,Object data){ return showNode(node,data); }
Display an ASTElseStatement node
public FractionAtom(Atom num,Atom den,boolean noDef,int unit,float t) throws InvalidUnitException { SpaceAtom.checkUnit(unit); numerator=num; denominator=den; noDefault=noDef; thickness=t; this.unit=unit; type=TeXConstants.TYPE_INNER; }
Depending on noDef, the given thickness and unit will be used (<-> the default thickness).
public void error(SourceLocator srcLctr,Node styleNode,Node sourceNode,String msg) throws TransformerException { error(srcLctr,styleNode,sourceNode,msg,null); }
Tell the user of an error, and probably throw an exception.
public KeyBuilder alt(){ modifiers|=ModifierKeys.ALT; return this; }
Add ALT modifier
public MAssetGroupAcct copy(MAssetGroup grp){ MAssetGroupAcct newAcct=new MAssetGroupAcct(grp.getCtx(),0,grp.get_TrxName()); copyValues(this,newAcct,grp.getAD_Client_ID(),grp.getAD_Org_ID()); newAcct.setA_Asset_Group_ID(grp.getA_Asset_Group_ID()); return newAcct; }
Clone this object, using specified group
public Number toNumber(){ if (value instanceof Boolean) return booleanValue() ? 1 : 0; if (isNumber()) return (Number)value; throw new ClassCastException("Variant is not a Number; CompositeClass=" + compositeClass); }
Returns the value of the specified Variant as a <code>Number</code>
private static String resolvePrincipal(Session session){ String principalName=session.getAttribute(PRINCIPAL_NAME_INDEX_NAME); if (principalName != null) { return principalName; } SecurityContext securityContext=session.getAttribute("SPRING_SECURITY_CONTEXT"); if (securityContext != null && securityContex...
Tries to determine the principal's name from the given Session.
public static void registerMetadata(MetadataRegistry registry){ if (registry.isRegistered(KEY)) { return; } ElementCreator builder=registry.build(KEY); }
Registers the metadata for this element.
public boolean domainMatch(String domain){ if (domain == null || groupDistinguishedName == null) { return false; } if (StringUtils.isBlank(this.groupDomain)) { this.groupDomain=getDomainFromDN(); } if (domain.equalsIgnoreCase(this.groupDomain)) { return true; } return false; }
validate if the group object match the specified domain
private RepositoryHolder createRepositoryHolder(RepositoryMetaData repositoryMetaData){ logger.debug("creating repository [{}][{}]",repositoryMetaData.type(),repositoryMetaData.name()); Injector repositoryInjector=null; try { ModulesBuilder modules=new ModulesBuilder(); RepositoryName name=new RepositoryN...
Creates repository holder
private static String determineMacLibrary(final String library){ String resourceName; String platform="darwin"; String fileExtension="dylib"; resourceName="/" + platform + "/"+ library+ "."+ fileExtension; return resourceName; }
Determine the right mac library depending on the architecture.
public static void fill(char[] array,char value){ for (int i=0; i < array.length; i++) { array[i]=value; } }
Fills the specified array with the specified element.
public String validateQuery(SolrQueryRequest req,String... tests) throws Exception { String res=query(req); return validateXPath(res,tests); }
Validates a "query" response against an array of XPath test strings
public static int toModifier(int accflags){ return accflags; }
Converts a javassist.bytecode.AccessFlag into a javassist.Modifier.
public void sync() throws IOException { if (forceSync) { nioFile.force(false); } }
Syncs any unstored data to the hash file.
public Enumeration<Option> listOptions(){ Vector<Option> optVector=new Vector<Option>(3); optVector.addElement(new Option("\tManual blend setting (default 20%)\n","B",1,"-B <num>")); optVector.addElement(new Option("\tEnable entropic auto-blend setting (symbolic class only)\n","E",0,"-E")); optVector.addElement...
Returns an enumeration describing the available options.
public boolean isHasAlias(){ Object oo=get_Value(COLUMNNAME_HasAlias); if (oo != null) { if (oo instanceof Boolean) return ((Boolean)oo).booleanValue(); return "Y".equals(oo); } return false; }
Get Use Account Alias.
public String[] indices(){ return indices; }
Returns the indices the operation needs to be executed on
public static String toString(boolean[] array){ StringBuffer buf=new StringBuffer(); buf.append("["); int maxIndex=array.length - 1; for (int i=0; i <= maxIndex; i++) { buf.append(array[i]); if (i < maxIndex) buf.append(", "); } buf.append("]"); return buf.toString(); }
Returns a string representation of the specified array. The string representation consists of a list of the arrays's elements, enclosed in square brackets (<tt>"[]"</tt>). Adjacent elements are separated by the characters <tt>", "</tt> (comma and space).
public DataModelTestCaseBase(String name){ super(name); }
Construct a new instance of this test case.
public boolean isIncludeNullsOrgTrx(){ Object oo=get_Value(COLUMNNAME_IsIncludeNullsOrgTrx); if (oo != null) { if (oo instanceof Boolean) return ((Boolean)oo).booleanValue(); return "Y".equals(oo); } return false; }
Get Include Nulls in Org Trx.
public String nextToken(boolean trim){ for (int i=0; i < regexps.length; i++) { if (!matchers[i].region(position,input.length()).lookingAt()) continue; position=matchers[i].end(); matchingIndex=i; return (trim ? matchers[i].group().trim() : matchers[i].group()); } matchingIndex=-1; return nu...
Returns the next token as a string. If *trim* is true, then the string is first trimmed of whitespace.
@Override public String toString(){ return "CUevent[" + "nativePointer=0x" + Long.toHexString(getNativePointer()) + "]"; }
Returns a String representation of this object.
protected boolean convertToUppercase(){ return false; }
Method convertToUppercase.
public URLImageCache(){ }
Let people create there own caches.
public long tryOptimisticRead(){ long s; return (((s=state) & WBIT) == 0L) ? (s & SBITS) : 0L; }
Returns a stamp that can later be validated, or zero if exclusively locked.
public void addFragment(@NonNull final Fragment from,@NonNull final Fragment to){ if (System.currentTimeMillis() - currentTime > CLICK_SPACE) { currentTime=System.currentTimeMillis(); FragmentTransaction transaction=context.getSupportFragmentManager().beginTransaction(); if (nextIn != 0 && nextOut != 0 &&...
Jump to the specified fragment
public T caseDeclaredTypeWithAccessModifier(DeclaredTypeWithAccessModifier object){ return null; }
Returns the result of interpreting the object as an instance of '<em>Declared Type With Access Modifier</em>'. <!-- begin-user-doc --> This implementation returns null; returning a non-null result will terminate the switch. <!-- end-user-doc -->
public boolean isRunnable(){ return getState().isRunnable(); }
Returns true for the a runnable state, including warmup
private BasicBlock convertBasicBlock(SsaBasicBlock block){ IntList successorList=block.getRopLabelSuccessorList(); int primarySuccessorLabel=block.getPrimarySuccessorRopLabel(); SsaBasicBlock exitBlock=ssaMeth.getExitBlock(); int exitRopLabel=(exitBlock == null) ? -1 : exitBlock.getRopLabel(); if (successorLi...
Converts a single basic block to rop form.
public ContainsSymbolConstraint(){ super(REGEX); }
Creates a new constraint, which allows to verify texts in order to check, if they contain at least one symbol.
private String normalizeUrl(String url){ if (!normalize) { return url; } String normalized=null; if (urlNormalizers != null) { try { normalized=urlNormalizers.normalize(url,URLNormalizers.SCOPE_INDEXER); normalized=normalized.trim(); } catch ( Exception e) { LOG.warn("Skipping ...
Normalizes and trims extra whitespace from the given url.
public void zoomReset(){ if (mFitZoom != null) { mFitZoom.apply(); mZoomIn.notifyZoomResetListeners(); repaint(); } }
Do a chart zoom reset / fit zoom.
private void updateEmptyStatus(){ boolean empty=getAdapter() == null || getAdapter().isEmpty(); if (isInFilterMode()) { empty=false; } View emptyView=getEmptyView(); if (empty) { if (emptyView != null) { emptyView.setVisibility(View.VISIBLE); setVisibility(View.GONE); } else { s...
Update the status of the list based on the empty parameter. If empty is true and we have an empty view, display it. In all the other cases, make sure that the listview is VISIBLE and that the empty view is GONE (if it's not null).
ObjectStreamField(String signature,String name){ if (name == null) { throw new NullPointerException("name == null"); } this.name=name; this.typeString=signature.replace('.','/').intern(); defaultResolve(); this.isDeserialized=true; }
Constructs an ObjectStreamField with the given name and the given type. The type may be null.
@NonNull public static Date toLastSecond(@NonNull Date date){ Date followingDay=getFollowingDay(date); Calendar calendar=DateUtils.toCalendar(followingDay); calendar.add(Calendar.SECOND,-1); return calendar.getTime(); }
Sets the <code>date</code> to the last second of the day it's in
public static UsernameAttribute createUsernameAttribute(byte username[]){ UsernameAttribute attribute=new UsernameAttribute(); attribute.setUsername(username); return attribute; }
Create a UsernameAttribute.
public static void updateMail(){ String envName=Ini.getAdempiereHome(); if (envName == null) return; envName+=File.separator + "AdempiereEnv.properties"; File envFile=new File(envName); if (!envFile.exists()) return; Properties env=new Properties(); try { FileInputStream in=new FileInputStream(env...
Update Mail Settings for System Client and System User
private Set<String> pickReplicasTobeDeleted(Slice slice,String shard,String collectionName,int count){ validateReplicaAvailability(slice,shard,collectionName,count); Collection<Replica> allReplicas=slice.getReplicas(); Set<String> replicasToBeRemoved=new HashSet<String>(); Replica leader=slice.getLeader(); fo...
Pick replicas to be deleted. Avoid picking the leader.
public static RefactoringStatus checkTypeParameterName(String name,IJavaElement context){ return checkName(name,JavaConventionsUtil.validateTypeVariableName(name,context)); }
Checks if the given name is a valid Java type parameter name.
public BigInteger[] generateSignature(byte[] message){ DSAParameters params=key.getParameters(); BigInteger q=params.getQ(); BigInteger m=calculateE(q,message); BigInteger x=((DSAPrivateKeyParameters)key).getX(); if (kCalculator.isDeterministic()) { kCalculator.init(q,x,message); } else { kCalculat...
generate a signature for the given message using the key we were initialised with. For conventional DSA the message should be a SHA-1 hash of the message of interest.
public NameGetter(Locale _locale){ this.locale=_locale; }
Initializes a NameGetter so that it will return messages in the specified locale.
protected Query newPhraseQuery(String text,int slop){ BooleanQuery.Builder bq=new BooleanQuery.Builder(); for ( Map.Entry<String,Float> entry : weights.entrySet()) { Query q=createPhraseQuery(entry.getKey(),text,slop); if (q != null) { float boost=entry.getValue(); if (boost != 1f) { q=...
Factory method to generate a phrase query with slop.
public byte[] createImageFromLayers(Projection proj,int scaledWidth,int scaledHeight,List<Layer> showLayers){ return createImageFromLayers(proj,scaledWidth,scaledHeight,showLayers,getBackground()); }
Use the ProjectionPainter interface of the layers to create an image. This approach avoids some of the timing issues that the thread model of the MapBean and Layers that seem to pop up from time to time. They are Swing components, you know. They were designed to be part of a GUI. So, this is a serialized, safe way to d...
public boolean isComplete(){ String ds=getDocStatus(); return DOCSTATUS_Completed.equals(ds) || DOCSTATUS_Closed.equals(ds) || DOCSTATUS_Reversed.equals(ds); }
Document Status is Complete or Closed
public NBTTagCompound writeToNBT(NBTTagCompound nbt){ nbt.setTag("item",this.original.writeToNBT(new NBTTagCompound())); return nbt; }
Writes this aspect item to the specified NBT
@Override public Candidates foldEdges(Candidates candidates,Long v1,Long v2,NullValue edgeVal) throws Exception { return candidates.merge(edgeToCandidate(v1,v2)); }
Implements foldEdges method of EdgesFold interface for combining two edges values into same type using merge method of the Candidates class. In this case it checks the Bipartiteness of the sub-graph in a partition by separating vertices into two groups such that there is no edge between the vertices of the same group. ...
public void testFindSingleIssue() throws Exception { Task[] found=myRepository.getIssues("UT-6",0,1,true); assertEquals(1,found.length); assertEquals("Summary contains 'bar'",found[0].getSummary()); }
If query string looks like task ID, separate request will be made to download issue.
public static <E>FastList<E> newWithNValues(int size,Function0<E> factory){ FastList<E> newFastList=FastList.newList(size); for (int i=0; i < size; i++) { newFastList.add(factory.value()); } return newFastList; }
Creates a new FastList pre-sized to the specified size filled with default values generated by the specified function.
public boolean forEachEntry(TLongDoubleProcedure procedure){ byte[] states=_states; long[] keys=_set; double[] values=_values; for (int i=keys.length; i-- > 0; ) { if (states[i] == FULL && !procedure.execute(keys[i],values[i])) { return false; } } return true; }
Executes <tt>procedure</tt> for each key/value entry in the map.
public static boolean isHighSurrogate(int c){ return (0xD800 <= c && c <= 0xDBFF); }
Returns whether the given character is a high surrogate
@SuppressWarnings("unchecked") public void removeAllEdges(Object from,Object to){ if (!containsAnyEdge(from,to)) return; List labels=this.getLabelsForEdges(from,to); List lablesClone=new ArrayList(); lablesClone.addAll(labels); for ( Object label : lablesClone) { this.removeEdge(from,to,label); } }
The existing removeAllEdges in the parent class seems to be throwing concurrentmodification exception most of the time. Here is a version that doesn't throw that exception.
public Pair<InputDocument,List<InputDocument>> selectSample(List<InputDocument> documents,int n){ int i=random.nextInt(documents.size()); InputDocument testDoc=documents.get(i); List<InputDocument> others=filter(documents,null); List<InputDocument> corpusSubset=getRandomDocuments(others,n); return new Pair<>(...
Select one document at random, then n others w/o replacement as corpus
public static Set<Emoticon> parseRoomEmotes(String json){ try { JSONParser parser=new JSONParser(); JSONObject o=(JSONObject)parser.parse(json); JSONObject room=(JSONObject)o.get("room"); String roomId=(String)room.get("id"); int set=((Number)room.get("set")).intValue(); JSONObject sets=(JSONO...
Parse the result of a request for a single room. Request: /room/:room
private void checkDuplicateImageServer(URI id,String imageServerAddress,String imageServerName){ if (StringUtils.isNotBlank(imageServerName)) { checkDuplicateLabel(ComputeImageServer.class,imageServerName); } List<URI> existingImageServers=_dbClient.queryByType(ComputeImageServer.class,false); for ( URI ur...
Check if the imageServer already exists, this method checks by both name/label and IP.
public static void assertEntryEquals(SynonymMap synonynMap,String word,boolean includeOrig,String[] synonyms) throws Exception { word=word.replace(' ',SynonymMap.WORD_SEPARATOR); BytesRef value=Util.get(synonynMap.fst,Util.toUTF32(new CharsRef(word),new IntsRefBuilder())); assertNotNull("No synonyms found for: " ...
Helper method to validate synonym parsing.
public static boolean isCategory(int M_Product_Category_ID,int M_Product_ID){ if (M_Product_ID == 0 || M_Product_Category_ID == 0) return false; Integer product=new Integer(M_Product_ID); Integer category=(Integer)s_products.get(product); if (category != null) return category.intValue() == M_Product_Categor...
Is Product in Category
public WETriangleMesh(String name){ this(name,DEFAULT_NUM_VERTICES,DEFAULT_NUM_FACES); }
Creates a new mesh instance with initial default buffer sizes.
public IndicesAliasesRequest removeAlias(String[] indices,String... aliases){ addAliasAction(new AliasActions(AliasAction.Type.REMOVE,indices,aliases)); return this; }
Removes an alias to the index.
@Override public void sessionCreated(HttpSessionEvent event){ log("sessionCreated('" + event.getSession().getId() + "')"); }
Record the fact that a session has been created.
public static void begin(){ logger=new Logger("Verification",Logger.ATTR_TIME); worker=new VerificationWorker(); worker.start(); }
Begin the Verification Routine. This is called automatically by Toast when launched with the --verify arguments
public void trapFieldWrite(String name,Object value){ Class jc=getJavaClass(); try { jc.getField(name).set(null,value); } catch ( NoSuchFieldException e) { throw new RuntimeException(e.toString()); } catch ( IllegalAccessException e) { throw new RuntimeException(e.toString()); } }
Is invoked when <code>static</code> fields of the base-level class are modified and the runtime system intercepts it. This method simply sets the field to the given value. <p>Every subclass of this class should redefine this method.
public void calcMinTick(){ minTick=1; if (minData > 1) { while ((minTick * 10) < minData) minTick*=10; } else if (minData < 1) { while (minTick > minData) minTick/=10; } }
Calculate the optimum minimum tick. For a log scale this is always a power of 10
public BeanFactoryException(String msg){ super(msg); }
Constructs an instance of <code>BeanFactoryException</code> with the specified detail message.
public static _QueryMembership fromString(final String value) throws SOAPSerializationException { return (_QueryMembership)Enumeration.fromString(value,_QueryMembership.VALUES_TO_INSTANCES); }
Gets the specific enumeration value in this class appropriate for the given XML attribute value. If no value is known, null is returned (_DEFAULT is not used; that value is for when the attribute is not present).
public static void removeCSSClass(Element e,String cssclass){ String oldval=e.getAttribute(SVGConstants.SVG_CLASS_ATTRIBUTE); if (oldval == null) { return; } String[] classes=oldval.split(" "); if (classes.length == 1) { if (cssclass.equals(classes[0])) { e.removeAttribute(SVGConstants.SVG_CLASS...
Remove a CSS class from an Element.
protected static void requestParamToSession(HttpServletRequest httpRequest,String parameterName){ String parameterValue=httpRequest.getParameter(parameterName); if (!ADMStringUtils.isBlank(parameterValue)) { httpRequest.getSession().setAttribute(parameterName,parameterValue); } }
Reads a request parameter and stores its value, if it is not blank, to the session.
public XMPPException(String message,Throwable wrappedThrowable){ super(message); this.wrappedThrowable=wrappedThrowable; }
Creates a new XMPPException with a description of the exception and the Throwable that was the root cause of the exception.
public Avg2(){ super("avg2",2); }
The average of 2 parameters.
public void runTest() throws Throwable { Document doc; EntityReference badEntityRef; doc=(Document)load("hc_staff",true); if (("text/html".equals(getContentType()))) { { boolean success=false; try { badEntityRef=doc.createEntityReference("foo"); } catch ( DOMException ex) { ...
Runs the test case.
private void incrementCurrentInterval(){ if (currentIntervalMillis >= maxIntervalMillis / multiplier) { currentIntervalMillis=maxIntervalMillis; } else { currentIntervalMillis*=multiplier; } }
Increments the current interval by multiplying it with the multiplier.
public CursorBuilder beforeFirst(){ _beforeFirst=true; return this; }
Sets the cursor so that it will start at the beginning (unless a savepoint is given).
private Token viewToToken(Point p){ return modelToToken(viewToModel(p)); }
Returns the token at the specified position in the view.
private void checkLowerValue(){ if (lowerValue < minimum) { lowerValue=minimum; } if (lowerValue > maximum) { lowerValue=maximum; } if (lowerValue > upperValue) { lowerValue=upperValue; } }
Check if the lower value is in ranges
public static Date minus(Date self,int days){ return plus(self,-days); }
Subtract a number of days from this date and returns the new date.
public void close(){ Logger.getRootLogger().removeAppender(splashOutputWriter); dispose(); }
Close current splash screen
public static int round(Float number){ return Math.round(number.floatValue()); }
Round the value