code
stringlengths
10
174k
nl
stringlengths
3
129k
private void rebootDevice(){ Log.i(TAG,"Reboot request initiated by admin."); try { Thread.sleep(5000); PowerManager powerManager=(PowerManager)getSystemService(Context.POWER_SERVICE); powerManager.reboot(null); } catch ( InterruptedException e) { Log.e(TAG,"Reboot initiating thread interrupted....
Rebooting the device.
@org.junit.Test public void verifyGetBigDecimalResponse() throws Exception { Map<String,String> queryParams=new HashMap<String,String>(); String str=client.invokeAPI("/mockResponses/primitiveBigDecimalResponse","GET",queryParams,null,new HashMap<String,String>(),null,"application/json",null,new String[0]); assert...
verifies that the BigDecimal return value is automatically created
protected Transform(){ }
Makes this class non instantiable, but still let's others inherit from it.
public PhoneNumber(String value){ this(); setValue(value); }
Constructs a new instance with the given value.
public final void testMaxLengthWithContextAndResourceIdParameters(){ assertNotNull(Validators.maxLength(getContext(),android.R.string.cancel,1)); }
Tests the functionality of the maxLength-method, which expects a context and a resource id as parameters.
public Comms(EventHandler parent,String host,int port) throws StreamCorruptedException, IOException, UnknownHostException { this.parent=parent; this.isServer=false; this.host=host; this.port=port; parent.debug("Creating client"); networkThread=new SocketThread(); new Thread(networkThread).start(); waitF...
Initialize as client This starts the network thread, which does the initialization of the socket and connects. TODO: Do callers rely on the socket being connected as soon as this returns?
public final Scanner scanner(){ return scanner; }
Returns the Scanner object used by this parser.
public HttpMethodClient(final int connectionTimeout,final int socketTimeout,final int requestTimeout){ final RequestConfig config=RequestConfig.custom().setConnectTimeout(connectionTimeout).setConnectionRequestTimeout(connectionTimeout).setSocketTimeout(socketTimeout).setRedirectsEnabled(false).build(); this.httpCl...
Creates a new HTTP method client.
public static double metersToDegreesLatitude(double meters){ return meters / EARTH_CIRCUMFERENCE_METERS * 360; }
Convert meters to degrees of latitude
public void testAllConnectedBrokerNetwork() throws Exception { bridgeBrokers("BrokerA","BrokerB"); bridgeBrokers("BrokerB","BrokerA"); bridgeBrokers("BrokerB","BrokerC"); bridgeBrokers("BrokerC","BrokerB"); bridgeBrokers("BrokerA","BrokerC"); bridgeBrokers("BrokerC","BrokerA"); startAllBrokers(); Destin...
BrokerA <-> BrokerB <-> BrokerC
private void checkShutdownAccess(){ SecurityManager security=System.getSecurityManager(); if (security != null) { security.checkPermission(shutdownPerm); final ReentrantLock mainLock=this.mainLock; mainLock.lock(); try { for ( Worker w : workers) security.checkAccess(w.thread); ...
If there is a security manager, makes sure caller has permission to shut down threads in general (see shutdownPerm). If this passes, additionally makes sure the caller is allowed to interrupt each worker thread. This might not be true even if first check passed, if the SecurityManager treats some threads specially.
@Deprecated public void addDatasource(String name,String sourceName,double percentile){ sources.put(name,new VDef(name,sourceName,new Variable.PERCENTILE(percentile))); }
Creates a datasource that performs a percentile calculation on an another named datasource to yield a single value. Requires that the other datasource has already been defined; otherwise, it'll end up with no data
public static void addSingleCrystallization(String input,String output,float xp){ if (!OreDictionary.getOres(output).isEmpty()) for ( ItemStack stack : OreDictionary.getOres(input)) addSingleCrystallization(stack,OreDictionary.getOres(output).get(0),xp); }
OreDictionary specific single-output Crystallization
public static void write(char[] data,Writer output) throws IOException { if (data != null) { output.write(data); } }
Writes chars from a <code>char[]</code> to a <code>Writer</code> using the default character encoding of the platform.
public void startMessagingApp(Activity context){ if (messenger.isLoggedIn()) { startMessagingActivity(context); } else { startAuthActivity(context); } }
Call this method for staring messaging app
public Reference(String className,RefAddr addr){ this.className=className; addrs=new Vector<>(); addrs.addElement(addr); }
Constructs a new reference for an object with class name 'className' and an address. Class factory and class factory location are set to null.
public void put(String id,String str){ tab.put(id,str); if (str.endsWith(".dtd")) { int i=str.lastIndexOf(File.separator); if (i >= 0) { tab.put(str.substring(i + 1,str.length() - 4),str); } } }
Add a mapping from a public identifier to a path.
public KDTreeDecorator(DrawingCanvas inner,ElementCanvas<IMultiPoint> canvas,IRetrieveKDTree m){ super(inner); this.canvas=canvas; this.model=m; }
Decorates a canvas by processing potential intersections among the elements already being drawn on the canvas. We need to have the base canvas to be able to access the 'drawElement' implementation. Because it is a decorator, it knows the inner one.
public XMLOptions() throws Exception { m_XMLDocument=new XMLDocument(); m_XMLDocument.setRootNode(ROOT_NODE); m_XMLDocument.setDocType(DOCTYPE); setValidating(true); }
Creates a new instance of XMLOptions.
@DSComment("Package priviledge") @DSBan(DSCat.DEFAULT_MODIFIER) @DSGenerator(tool_name="Doppelganger",tool_version="2.0",generated_on="2013-12-30 12:33:10.437 -0500",hash_original_method="C4EA5DCF4A3C62F4A8277EC33D71D823",hash_generated_method="881CA721F8739CA30DE597C7F8A1024A") WebHistoryItem(byte[] data){ mUrl=null...
Construct a new WebHistoryItem with initial flattened data.
public static int[] bestSubsequence(String completion,String token){ int bestScore=-1; int[] bestSequence=EMPTY_SEQUENCE; for ( int[] s1 : findSequences(completion,token)) { int score=scoreSubsequence(s1); if (score > bestScore) { bestScore=score; bestSequence=s1; } } return bestSeque...
Returns the best, i.e, the longest continuous sequence - or the empty sequence if no subsequence could be found.
@DSGenerator(tool_name="Doppelganger",tool_version="2.0",generated_on="2014-03-25 14:54:54.302 -0400",hash_original_method="4D77A4D18E5F8068BB808BBC9D02F043",hash_generated_method="ECB4C35609396350B0902950CCC50B79") public void addFileSuffix(String fileSuffix){ mFileSuffixList.add(fileSuffix); }
Adds the specified file suffix to the list of file suffixes this DRM plug-in supports.
public void onActivityCreated(@Nullable Bundle savedInstanceState){ }
Called when the fragment's activity has been created and this fragment's view hierarchy instantiated. It can be used to do final initialization once these pieces are in place, such as retrieving views or restoring state. It is also useful for fragments that use setRetainInstance(boolean) to retain their instance, as th...
public static double[] randomDoubleArray(int len,Random r){ final double[] ret=new double[len]; for (int i=0; i < len; i++) { ret[i]=r.nextDouble(); } return ret; }
Produce an array of random numbers in [0:1].
default void licenceCheck(){ }
checks if the function you are about to call is part of an enterprise product, if the licence fails a runtime exception will be thrown
public static boolean isProxyType(Class<?> type){ String name=type.getName(); if (name.startsWith("net.sf.cglib.proxy.") || name.startsWith("org.hibernate.proxy.")) { return true; } return false; }
Helper method used to weed out dynamic Proxy types; types that do not expose concrete method API that we could use to figure out automatic Bean (property) based serialization.
public AWTFontFamily(GVTFontFace fontFace,Font font){ this.fontFace=fontFace; this.font=font; }
Constructs an AWTFontFamily with the specified familyName.
public long length() throws SerialException { isValid(); return len; }
Retrieves the number of bytes in this <code>SerialBlob</code> object's array of bytes.
public double interceptStdErr(){ return Math.sqrt(svar0); }
Returns the standard error of the estimate for the intercept.
private OracleCollection createCollection(String collectionName,CollectionDescriptor options) throws OracleException { return createCollection(collectionName,options,COLLECTION_CREATION_MODE); }
Create a collection with the specified name and options.
@Override protected boolean isInAlphabet(final byte octet){ return octet >= 0 && octet < decodeTable.length && decodeTable[octet] != -1; }
Returns whether or not the <code>octet</code> is in the Base64 alphabet.
protected void onMeasureChild(View child,int position,int widthMeasureSpec,int heightMeasureSpec){ child.measure(widthMeasureSpec,heightMeasureSpec); }
this method is called every time a new child is mesaure.
public boolean contains(byte shieldId){ return shieldsIds.contains(shieldId); }
Checks whether the shields list contains a shield with a specific id.
protected void sequence_BlockMinusBraces(ISerializationContext context,Block semanticObject){ genericSequencer.createSequence(context,semanticObject); }
Contexts: BlockMinusBraces<Yield> returns Block BlockMinusBraces returns Block Constraint: statements+=Statement
public boolean isHeartbeatActive(){ return _serverBartender.isUp(); }
Test if the server is active, i.e. has received an active message.
public ToStringBuilder append(String fieldName,byte value){ style.append(buffer,fieldName,value); return this; }
<p>Append to the <code>toString</code> an <code>byte</code> value.</p>
@SuppressWarnings("unchecked") FullArray(Class<L> linearArrayType,L real,L imag,int[] dimensions){ _dimensions=dimensions; _numberOfElements=ArrayUtils.getNumberOfElements(_dimensions); _real=linearArrayType.cast(real); _imag=linearArrayType.cast(imag); _baseComponentType=linearArrayType.getComponentType(); ...
Data from MATLAB. Provided as the linear arrays and dimensions.
public static void register(){ CommandCenter.register(FACE,new FaceAction()); }
register the action
public static String changeReturnType(String classname,String desc){ int i=desc.indexOf(')'); if (i < 0) return desc; else { StringBuffer newdesc=new StringBuffer(); newdesc.append(desc.substring(0,i + 1)); newdesc.append('L'); newdesc.append(classname.replace('.','/')); newdesc.append(';'); ...
Changes the return type included in the given descriptor. <p><code>classname</code> must not be an array type.
@Inline public static boolean needsCheckArgs(ReflectionBase invoker){ return !bytecodeReflection && !cacheInvokerInJavaLangReflect; }
Does the reflective method scheme need to check the arguments are valid? Bytecode reflection doesn't need arguments checking as they are checking as they are unwrapped
public static void callEMCRefresh(SmisCommandHelper helper,StorageSystem storage){ try { _log.info("Refreshing storagesystem: {}",storage.getId()); helper.callRefreshSystem(storage,null); } catch ( Exception e) { _log.error("Exception callEMCRefresh",e); } }
Refresh the given storagesystem.
public boolean isRequired(){ if (parameter.isConfigurable()) { return false; } return parameterDefinition.isMandatory(); }
Checks whether the parameter value is required. If the parameter is set to be configurable for the customer, the supplier is not required to provide a value for it, by creating/updating service. If the parameter is set to be not configurable for the customer, the parameter definition decides if the value is required (m...
public ConnectionConfig(jmri.jmrix.NetworkPortAdapter p){ super(p); }
Ctor for an object being created during load process; Swing init is deferred.
public static PrivKey load(byte[] keyBytes,final String password) throws IOException, NoSuchAlgorithmException, InvalidKeySpecException, NoSuchPaddingException, InvalidKeyException, InvalidAlgorithmParameterException, IllegalBlockSizeException, BadPaddingException, InvalidParameterSpecException { boolean isEncrypted=...
Load private key from key data
@Override public boolean supportsOpenStatementsAcrossRollback(){ debugCodeCall("supportsOpenStatementsAcrossRollback"); return true; }
Returns whether open statements across rollback are supported.
public String encodeBody(){ return optionTag; }
Encode in canonical form.
public static String toPropertyName(String httpHeader){ httpHeader=httpHeader.replace('-','$'); return "http_" + httpHeader.toLowerCase(); }
Converts an HTTP header name to a selector compatible property name. '-' character is converted to '$'. The return property name will also be all lower case with an "http_" prepended. For example "Content-Type" would be converted to "http_content$type";
public Outline(){ }
Constructs an empty Outline. Call one of the setter methods to make the outline valid for use with a View.
public TechnicalServiceNotAliveException(){ super(); }
Constructs a new exception with <code>null</code> as its detail message. The cause is not initialized.
@DSComment("Package priviledge") @DSBan(DSCat.DEFAULT_MODIFIER) @DSGenerator(tool_name="Doppelganger",tool_version="2.0",generated_on="2013-12-30 12:36:31.759 -0500",hash_original_method="3D77B6F49E03B0770D03717F27BECD0E",hash_generated_method="3D77B6F49E03B0770D03717F27BECD0E") void calculateValue(float fraction){ m...
Function used to calculate the value according to the evaluator set up for this PropertyValuesHolder object. This function is called by ValueAnimator.animateValue().
public void clearRect(int x,int y,int width,int height){ g.clearRect(x,y,width,height); }
Clears the specified rectangle by filling it with the background color of the current drawing surface. This operation does not use the current paint mode. <p> Beginning with Java&nbsp;1.1, the background color of offscreen images may be system dependent. Applications should use <code>setColor</code> followed by <code>f...
public boolean init(){ log.config(""); MClient client=MClient.get(Env.getCtx()); String ASPFilter=""; if (client.isUseASP()) ASPFilter=" AND ( p.AD_Process_Para_ID IN ( " + " SELECT pp.AD_Process_Para_ID " + " FROM ASP_Process_Para pp, ASP_Process p, ASP_Level l, ASP_ClientLeve...
Read Fields to display
@DSGenerator(tool_name="Doppelganger",tool_version="2.0",generated_on="2013-12-30 13:01:15.607 -0500",hash_original_method="BCFC763048FB40D22AF5E3F4AE92979E",hash_generated_method="A6B30A4741083A789C035F2D9F29B245") public static boolean isSupported(String name){ return protocolsByName.containsKey(name); }
Returns true if provider supports protocol version
public Ed25519GroupElement add(final Ed25519GroupElement g){ if (this.coordinateSystem != CoordinateSystem.P3) { throw new UnsupportedOperationException(); } if (g.coordinateSystem != CoordinateSystem.CACHED) { throw new IllegalArgumentException(); } final Ed25519FieldElement YPlusX; final Ed25519Fi...
Ed25519GroupElement addition using the twisted Edwards addition law for extended coordinates. this must be given in P^3 coordinate system and g in CACHED coordinate system. r = this + g where this = (X1 : Y1 : Z1 : T1), g = (g.X, g.Y, g.Z, g.T) = (Y2 + X2, Y2 - X2, Z2, 2 * d * T2) <br> r in P x P coordinate system.: X'...
protected boolean isSplitable(JobContext context,Path filename){ return false; }
Always returns false, as WARC files cannot be split.
private int countToken(String token,String target){ int tokenIndex=0; int count=0; while (tokenIndex != -1) { tokenIndex=target.indexOf(token,tokenIndex); if (tokenIndex > -1) { tokenIndex++; count++; } } return count; }
Returns the number of times the token appears in the target.
public static void shutdown(final Context context,boolean confirm){ mReboot=false; mRebootSafeMode=false; shutdownInner(context,confirm); }
Request a clean shutdown, waiting for subsystems to clean up their state etc. Must be called from a Looper thread in which its UI is shown.
public void load(ArrayList<String> lines){ boolean[][] loaded=new boolean[_size][_size]; for (int j=0; j < _size; j++) { String l=lines.get(j); for (int k=0; k < _size; k++) { _cells[j][k].resetBeenAlive(); if (l.charAt(k) == '.') { _cells[j][k].setAlive(false); loaded[j][k]=fals...
Load in a previously saved Game of Life configuration.
public boolean process(){ return this.process; }
Should the node Process be returned.
public void computeUtlimateDependencies(CompiledValue cv,Set set){ Set dependencySet=this.getDependencySet(cv,true); if (dependencySet != Collections.EMPTY_SET) { Iterator iter=dependencySet.iterator(); RuntimeIterator rIter; while (iter.hasNext()) { rIter=(RuntimeIterator)iter.next(); Set i...
Calculates set of Runtime Iterators on which a given CompiledValue ultimately depends. The independent iterators may belong to other scopes. <P> author Asif/Ketan
public static org.oscm.vo.VOServiceOperationParameter convertToApi(org.oscm.internal.vo.VOServiceOperationParameter oldVO){ if (oldVO == null) { return null; } org.oscm.vo.VOServiceOperationParameter newVO=new org.oscm.vo.VOServiceOperationParameter(); newVO.setKey(oldVO.getKey()); newVO.setVersion(oldVO....
Convert source version VO to target version VO.
protected void release() throws IOException { }
Called when reference counting hits 0. By default this method does nothing, but extensions can override to e.g. release resources attached to object that is managed by this class.
public boolean intersects(R1Interval y){ if (lo() <= y.lo()) { return y.lo() <= hi() && y.lo() <= y.hi(); } else { return lo() <= y.hi() && lo() <= hi(); } }
Return true if this interval intersects the given interval, i.e. if they have any points in common.
public void closeDriver(){ if (camera != null) { FlashlightManager.disableFlashlight(); camera.release(); camera=null; } }
Closes the camera driver if still in use.
protected WebDriver createWebDriverWithTimeout(){ long time=0; while (time < getTimeout()) { try { driver=createNativeDriver(); return driver; } catch ( WebDriverException ex) { if (ex.getMessage().contains("SocketException") || ex.getMessage().contains("Failed to connect to binary Fir...
Create webDriver, capture socket customexception and retry with timeout.
private void emit2(int od){ if (!alive) return; if (cp + 2 > code.length) { emit1(od >> 8); emit1(od); } else { code[cp++]=(byte)(od >> 8); code[cp++]=(byte)od; } }
Emit two bytes of code.
private void updateProgress(String progressLabel,int progress){ if (myHost != null && ((progress != previousProgress) || (!progressLabel.equals(previousProgressLabel)))) { myHost.updateProgress(progressLabel,progress); } previousProgress=progress; previousProgressLabel=progressLabel; }
Used to communicate a progress update between a plugin tool and the main Whitebox user interface.
private static String constructSetChildrenErrorMessage(ViewGroup viewToManage,ViewGroupManager viewManager,ReadableArray childrenTags){ ViewAtIndex[] viewsToAdd=new ViewAtIndex[childrenTags.size()]; for (int i=0; i < childrenTags.size(); i++) { viewsToAdd[i]=new ViewAtIndex(childrenTags.getInt(i),i); } retu...
Simplified version of constructManageChildrenErrorMessage that only deals with adding children views
public final void popExpressionState(){ m_currentNodes.quickPop(1); m_currentExpressionNodes.quickPop(1); m_prefixResolvers.pop(); }
Pop the current context node, expression node, and prefix resolver.
public VerbTag(String name){ super(name); }
Create a new VerbTag.
public CombinedXYChart(XYMultipleSeriesDataset dataset,XYMultipleSeriesRenderer renderer,CombinedXYChart.XYCombinedChartDef[] chartDefinitions,XYChart[] charts){ super(dataset,renderer); this.chartDefinitions=chartDefinitions; this.mCharts=charts; }
Builds a new combined XY chart instance using the given charts. This allows users to specify parameters like smoothness for CombinedXYCharts.
public boolean canChangeContents(){ return true; }
Flag indicating that the contents of this RosterGroup can be changed by the user. The default implementation always returns true.
private void updateProgress(String progressLabel,int progress){ if (pluginHost != null && ((progress != previousProgress) || (!progressLabel.equals(previousProgressLabel)))) { pluginHost.updateProgress(progressLabel,progress); } else { System.out.println(progressLabel + " " + progress+ "%"); } previous...
Used to communicate a progress update between a plugin tool and the main Whitebox user interface.
public int process(Buffer input,Buffer output){ if (input == null || output == null) { return BUFFER_PROCESSED_FAILED; } extractNalUnitHeader(input); if (mNalUnitHeader.isFragmentationUnit()) { return handleFragmentationUnitPacket(input,output); } else if (mNalUnitHeader.isAggregationPacket()) { ...
Performs the media processing defined by this codec
@Override public void run(){ amIActive=true; String inputHeader=null; String pointerHeader=null; String outputHeader=null; int row, col; double x, y; int i; int progress=0; WhiteboxRaster.DataType dataType=WhiteboxRaster.DataType.FLOAT; String whatToAssign=null; if (args.length <= 0) { showFee...
Used to execute this plugin tool.
public static double rho(ExampleSet eSet,Attribute a,Attribute b) throws OperatorException { return rho(eSet,a,b,0.0); }
Calculates the Spearman rank correlation between two attributes.
@SuppressWarnings("unchecked") private <T>T allowStaticAccessToMember(T member,boolean staticOnly){ if (member == null) return null; if (!staticOnly) return member; boolean isStatic; if (member instanceof Variable) { Variable v=(Variable)member; isStatic=Modifier.isStatic(v.getModifiers()); } els...
This method is used to filter search results in which null means "no match", to filter out illegal access to instance members from a static context. Return null if the given member is not static, but we want to access in a static way (staticOnly=true). If we want to access in a non-static way we always return the membe...
public void saveReferences(Collection<ExpressionObject<?>> references){ for ( ExpressionObject<?> ref : references) { if (ref.isInternalDynamic()) { ref.setDynamic(false); if (ref instanceof Dimension) { ref=DAOFactory.getDAOFactory().getDAO(Dimension.class).create(universe.getContext(),(Dime...
check the reference list and make sure the dynamic ones are persisted
public double maxX(){ return Math.max(p0.x,p1.x); }
Gets the maximum X ordinate.
public static ProvisionNamespaceTransaction createProvisionNamespaceTransaction(){ return new ProvisionNamespaceTransaction(TimeInstant.ZERO,Utils.generateRandomAccount(),Utils.generateRandomAccount(),Amount.fromNem(50_000),new NamespaceIdPart("bar"),new NamespaceId("foo")); }
Creates a provision namespace transaction.
public static void callbackRegistration(String method,String modname){ String[] splitName=method.split("\\."); String methodName=splitName[splitName.length - 1]; String className=method.substring(0,method.length() - methodName.length() - 1); APIInstanceProvider providerinst=InternalAPI.getAPIProviderInstance(mo...
This handles the classpath and method location and calling for API IMC calls Based on some code from WAILA.
@SuppressWarnings("rawtypes") public static Object autoVivifyListOrMap(Object property){ String str=property.toString(); boolean isList=("add".equals(str) || str.startsWith("insert@")); if (!isList && !"java.lang.String".equals(property.getClass().getName())) { Integer index=UtilMisc.toIntegerObject(property)...
Evaluates a property <code>Object</code> and returns a new <code>List</code> or <code>Map</code>. If <code>property</code> is not a String object type and it evaluates to an integer value, a new <code>List</code> instance is returned, otherwise a new <code>Map</code> instance is returned.
@Override public void run(){ response.setContentType(PLAIN_TEXT_UTF_8); try { Registry registry=Registry.get(tld); String resultMsg; if (registry.getReservedLists().isEmpty() && isNullOrEmpty(registry.getDriveFolderId())) { resultMsg="No reserved lists configured"; logger.infofmt("No reserve...
Exports the reserved terms for the TLD specified via the "tld" param to a newline-delimited UTF-8-formatted CSV file (with one column) named "reserved_terms.txt" in the Google Drive folder with the id specified for that TLD. <p>This servlet prints the ID of the file in GoogleDrive that was created/updated.
@DSSafe(DSCat.SAFE_LIST) @DSGenerator(tool_name="Doppelganger",tool_version="2.0",generated_on="2013-12-30 12:56:44.474 -0500",hash_original_method="D48176638CA08E926D8083B62CC7EB27",hash_generated_method="F8A2DBAD4957C2E8530D4BBC1D7A1A43") public boolean exists(){ return true; }
Returns a boolean indicating whether this file can be found on the underlying file system.
private void addEmptyLine(Paragraph paragraph,int number){ for (int i=0; i < number; i++) { paragraph.add(new Paragraph(" ")); } }
Crea un salto de linea ** Create a line Break
private boolean doCharacterAVM(int position) throws SolverTimeoutException { checkpointVar(DistanceEstimator.getDistance(cnstr)); boolean done=false; boolean hasImproved=false; while (!done) { if (isFinished()) { throw new SolverTimeoutException(); } done=true; String origString=strVar.get...
Apply AVM to an individual character within a string
private void updateProgress(String progressLabel,int progress){ if (myHost != null && ((progress != previousProgress) || (!progressLabel.equals(previousProgressLabel)))) { myHost.updateProgress(progressLabel,progress); } previousProgress=progress; previousProgressLabel=progressLabel; }
Used to communicate a progress update between a plugin tool and the main Whitebox user interface.
@Inject public DefaultMailService(SystemConfiguration config){ super(config); requireArgument(config != null,"Configuration cannot be null."); _config=config; }
Creates a new DefaultMailService object.
@Override protected void doPost(HttpServletRequest request,HttpServletResponse response){ processRequest(request,response); }
Handles the HTTP <code>POST</code> method.
private String addEnableImageAccessForCreateReplicaStep(Workflow workflow,ProtectionSystem rpSystem,Class<? extends DataObject> clazz,List<URI> copyList,String bookmarkName,Set<String> volumeWWNs,String waitFor) throws InternalException { String stepId=workflow.createStepId(); Workflow.Method enableImageAccessExecu...
Method that adds the steps to the workflow to enable image access before create native array replica operation
public void expandTree(){ _bugTree.getTreeHelper().expandTree(3); }
Expand the error tree to the fullest.
public TouchHandlerOld(GraphicalView view,AbstractChart chart){ graphicalView=view; zoomR=graphicalView.getZoomRectangle(); if (chart instanceof XYChart) { mRenderer=((XYChart)chart).getRenderer(); } else { mRenderer=((RoundChart)chart).getRenderer(); } if (mRenderer.isPanEnabled()) { mPan=new ...
Creates an implementation of the old version of the touch handler.
public long optLong(int index,long defaultValue){ try { return this.getLong(index); } catch ( Exception e) { return defaultValue; } }
Get the optional long value associated with an index. The defaultValue is returned if there is no value for the index, or if the value is not a number and cannot be converted to a number.
public static void releaseSystemSensorManager(){ if (systemSensorManager != null) { systemSensorManager.stopSensor(); } systemSensorManager=null; }
Releases the system sensor manager.
public void merge(final WroModel importedModel){ Validate.notNull(importedModel,"imported model cannot be null!"); LOG.debug("merging importedModel: {}",importedModel); for ( final String groupName : new WroModelInspector(importedModel).getGroupNames()) { if (new WroModelInspector(this).getGroupNames().conta...
Merge this model with another model. This is useful for supporting model imports.
public void deleteMax(){ if (isEmpty()) throw new NoSuchElementException("called deleteMax() with empty symbol table"); root=deleteMax(root); assert check(); }
Removes the largest key and associated value from the symbol table.
public void visitAnnotation(@DottedClassName String annotationClass,Map<String,ElementValue> map,boolean runtimeVisible){ if (DEBUG) { System.out.println("Annotation: " + annotationClass); for ( Map.Entry<String,ElementValue> e : map.entrySet()) { System.out.println(" " + e.getKey()); System...
Visit annotation on a class, field or method
private void updateUiAfterResponse(String feature,String state,String featureMetadata,String ruleMetadata,boolean cached){ featureButton.setText(feature + " is " + (state == Toggle.ENABLED ? "enabled" : "disabled")); featureButton.setEnabled(state == Toggle.ENABLED); featureMetadataTextView.setText("Feature Metad...
Update the UI as per the feature state
public MultiMineServer(){ partiallyMinedBlocksListByDimension=Maps.<Integer,List<PartiallyMinedBlock>>newHashMap(); instance=this; blockRegenQueue=new BlockRegenQueue(30,new BlockAgeComparator()); blacklistedBlocksAndTools=Maps.<String,Boolean>newHashMap(); final Set<Entry<String,Property>> setblocks=MultiMin...
Server instance of Multi Mine Mod. Keeps track of Players having the Mod installed, the Blocks they damage, and the Block regeneration Queue, which is watched by the integrated Tick Handler.
void startHttpServer() throws IOException { httpServer=com.sun.net.httpserver.HttpServer.create(new InetSocketAddress(0),0); HttpContext ctx=httpServer.createContext("/test/",new MyHandler()); httpServer.start(); }
Http Server