code
stringlengths
10
174k
nl
stringlengths
3
129k
public ArtifactStoreException(final String message){ super(message); }
Constructs a ArtifactStoreException with message.
@SuppressWarnings("unchecked") public E valueAt(int index){ if (mGarbage) { gc(); } return (E)mValues[index]; }
Given an index in the range <code>0...size()-1</code>, returns the value from the <code>index</code>th key-value mapping that this LongSparseArray stores.
public static final byte[] unzip(byte[] in) throws IOException { ByteArrayOutputStream outStream=new ByteArrayOutputStream(EXPECTED_COMPRESSION_RATIO * in.length); GZIPInputStream inStream=new GZIPInputStream(new ByteArrayInputStream(in)); byte[] buf=new byte[BUF_SIZE]; while (true) { int size=inStream.read...
Returns an gunzipped copy of the input array.
public String toString(){ final StringBuffer buf=new StringBuffer(); if (directory) { buf.append(DIRECTORY_PREFIX); } else { buf.append('/'); } if (fileName != null) { buf.append(fileName); buf.append('/'); if (revision != null) { buf.append(revision); } buf.append('/'); ...
Create a string representation of the entry line. Create the standard CVS 1.10 entry line format.
public void registerParameterDataType(String parameterName,ICalDataType dataType){ parameterName=parameterName.toLowerCase(); if (dataType == null) { parameterDataTypes.remove(parameterName); } else { parameterDataTypes.put(parameterName,dataType); } }
Registers the data type of an experimental parameter. Experimental parameters use the "unknown" data type by default.
private TreePath findTreePathByObject(TreeModel model,TreeNode base,TreePath parent,Object tofind){ int childCount=model.getChildCount(base); for (int i=0; i < childCount; i++) { DefaultMutableTreeNode child=(DefaultMutableTreeNode)model.getChild(base,i); if (child.getUserObject().equals(tofind)) { re...
Method findTreePathByObject.
public static VulnerabilityGroup transformToGroup(IItem item){ VulnerabilityGroup vulnGroup=new VulnerabilityGroup(); if (item.getName() != null) { vulnGroup.setTitel(item.getName().replaceAll("\\s"," ")); } return vulnGroup; }
Transforms a catalog item to a control group.
public boolean isNodeAfter(int nodeHandle1,int nodeHandle2){ return false; }
Figure out whether nodeHandle2 should be considered as being later in the document than nodeHandle1, in Document Order as defined by the XPath model. This may not agree with the ordering defined by other XML applications. <p> There are some cases where ordering isn't defined, and neither are the results of this functio...
@Field(26) public __VARIANT_NAME_3_union pbstrVal(Pointer<Pointer<Byte>> pbstrVal){ this.io.setPointerField(this,26,pbstrVal); return this; }
VT_BYREF|VT_BSTR<br> C type : BSTR
public static boolean isElementsPositive(double[][] m){ for (int i=0; i < m.length; i++) { for (int j=0; j < m[i].length; j++) { if (m[i][j] < 0) return false; } } return true; }
isElementsPositive returns true if each element in the matrix is positive
private static void findOraHomes(){ String path=System.getenv(OracleConstants.VAR_PATH); if (path != null) { for ( String token : path.split(System.getProperty("path.separator"))) { if (token.toLowerCase().contains("oracle")) { token=CommonUtils.removeTrailingSlash(token); if (token.toL...
Searches Oracle home locations.
protected Object processInStreamOutObject(int type,BinaryRawReaderEx reader) throws IgniteCheckedException { return throwUnsupported(type); }
Process IN operation with managed object as result.
private void propagate(AugmentedNode<K> t){ AugmentedNode<K> lf; AugmentedNode<K> rt; while (t != null) { lf=t.left(); rt=t.right(); boolean updated=false; if (!t.min.equals(lf.min)) { t.min=lf.min; updated=true; } if (!t.max.equals(rt.max)) { t.max=rt.max; updated=...
Update min/max segments up the tree.
public SlideOutAnimation(View view){ this.view=view; direction=DIRECTION_LEFT; interpolator=new AccelerateDecelerateInterpolator(); duration=DURATION_LONG; listener=null; }
This animation causes the view to slide out to the borders of the screen. On animation end, the view is restored to its original state and is set to <code>View.INVISIBLE</code>.
public Sensors(){ mSensorManager=(SensorManager)Util.getContext().getSystemService(Context.SENSOR_SERVICE); mAccelerometer=mSensorManager.getDefaultSensor(Sensor.TYPE_ACCELEROMETER); mMagneticField=mSensorManager.getDefaultSensor(Sensor.TYPE_MAGNETIC_FIELD); resume(); }
Instantiate a sensor reader class
public String toString(){ return name; }
Returns a string presentation of the host.
public static String formatTime(int hour,int minute){ String s=""; String t=Integer.toString(hour); if (t.length() == 2) { s=t + ":"; } else if (t.length() == 1) { s="0" + t + ":"; } t=Integer.toString(minute); if (t.length() == 2) { s=s + t; } else if (t.length() == 1) { s=s + "0"...
Formats time to hh:mm given integer hour and minute
public void registerOutParameter(int parameterIndex,SQLType sqlType) throws SQLException { super.registerOutParameter(parameterIndex,translateAndCheckSqlType(sqlType)); }
Support for java.sql.JDBCType/java.sql.SQLType.
@DSComment("From safe class list") @DSSafe(DSCat.SAFE_LIST) @DSGenerator(tool_name="Doppelganger",tool_version="2.0",generated_on="2013-12-30 12:57:11.565 -0500",hash_original_method="043D89A921444ACFFC25D3711EECF0CA",hash_generated_method="1EC3AF62B1106EC64D8195D6B4E8C3D2") public TimeoutException(){ }
Constructs a <tt>TimeoutException</tt> with no specified detail message.
private Object invokeGetter(Object target,String getter){ try { Method getAddress=target.getClass().getMethod(getter); return getAddress.invoke(target); } catch ( NoSuchMethodException nsme) { } catch ( IllegalAccessException iae) { } catch ( IllegalArgumentException iae) { } catch ( InvocationTa...
Utility method used to invoke getters for javamail implementation specific classes.
public CharSequenceReader(CharSequence seq){ this.seq=checkNotNull(seq); }
Creates a new reader wrapping the given character sequence.
void initialize(){ mProvisioningOperationHandler=allocateBgHandler(PROVISIONING_OPERATIONS_THREAD_NAME); mRcsAccountManager=new RcsAccountManager(mCtx,mContactManager); mNetworkCnx=new HttpsProvisioningConnection(this,mCtx); mSmsManager=new HttpsProvisioningSMS(this,mCtx); }
Initialize Provisioning Manager
public static ProgressDialog showProgressDialog(Context context,String title,String message,OnCancelListener cancelListener){ ProgressDialog progressDialog=ProgressDialog.show(context,title,message,true); progressDialog.setCancelable(true); progressDialog.setOnCancelListener(cancelListener); return progressDial...
Shows the ProgressDialog.
public LargeValueFormatter(String appendix){ this(); mText=appendix; }
Creates a formatter that appends a specified text to the result string
protected void onIdle(){ final int turn=SingletonRepository.getRuleProcessor().getTurn() + timingAdjust; if (owner == null) { if (((turn % 15) == 0) && isEnemyNear(getPerceptionRange())) { logger.debug("Sheep (ownerless) moves randomly"); setIdea("walk"); maybeMakeSound(20); moveRandomly...
Called when the sheep is idle.
private Object[] inliningContext(){ if (!Debug.isDumpEnabled(Debug.INFO_LOG_LEVEL)) { return NO_CONTEXT; } Object[] result=new Object[graphQueue.size()]; int i=0; for ( CallsiteHolder g : graphQueue) { result[i++]=g.method(); } return result; }
Gets the call hierarchy of this inlining from outer most call to inner most callee.
@Override public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException { super.readExternal(in); this.knnDistance=in.readDouble(); }
Calls the super method and reads the knn distance of this entry from the specified input stream.
public void fireAnnotationMiscChanged(WorkflowAnnotation anno){ List<WorkflowAnnotation> list=new LinkedList<>(); list.add(anno); fireAnnotationsChanged(AnnotationEvent.MISC_CHANGED,list); }
Fire when the something minor with workflow annotations has changed which only requires a repaint.
public void save(OutputStream output) throws IOException { DataOutputStream os=new DataOutputStream(output); os.writeInt(glyphCount); if ((name == null) || (psname == null)) { name=""; psname=""; } os.writeInt(11); os.writeInt(size); os.writeInt(0); os.writeInt(ascent); os.writeInt(descent); ...
Write this PFont to an OutputStream. <p> This is used by the Create Font tool, or whatever anyone else dreams up for messing with fonts themselves. <p> It is assumed that the calling class will handle closing the stream when finished.
public SQLClientInfoException(Map<String,ClientInfoStatus> failedProperties){ this.failedProperties=new HashMap<String,ClientInfoStatus>(failedProperties); }
Creates an SQLClientInfoException object. The Reason string is set to the given reason string, the SQLState string is set to null and the Error Code is set to 0, and the Map<String,ClientInfoStatus> object is set to the failed properties.
String normalizePath(String segment,boolean generateRelative){ if (_userPrefix == null) { PathImpl userPath=VfsOld.lookup(CauchoUtil.getUserDir()); char sep=CauchoUtil.getFileSeparatorChar(); _userPrefix=userPath.getNativePath(); if (_userPrefix.length() == 0 || _userPrefix.charAt(_userPrefix.length()...
Normalizes a path.
@SuppressWarnings("unchecked") public Object[] toArray(Object[] array){ synchronized (children) { return children.keySet().toArray(array); } }
Returns an array of children of this context.
public void testSpanOrVersusBooleanNear() throws Exception { Term t1=randomTerm(); Term t2=randomTerm(); Term t3=randomTerm(); Term t4=randomTerm(); SpanQuery near1=spanQuery(new SpanNearQuery(new SpanQuery[]{spanQuery(new SpanTermQuery(t1)),spanQuery(new SpanTermQuery(t2))},10,random().nextBoolean())); Spa...
SpanOrQuery(SpanNearQuery[A B], SpanNearQuery[C D]) = (SpanNearQuery[A B], SpanNearQuery[C D])
@Override public ImmutableSet<Entry<K,V>> entrySet(){ return super.entrySet(); }
Returns an immutable set of the mappings in this map, sorted by the key ordering.
protected E buildValue(final IScope scope,final Object object){ final IType ct=type.getContentType(); return (E)ct.cast(scope,object,null,false); }
Method buildValue()
protected void parseRotate() throws ParseException, IOException { current=reader.read(); if (current != 'o') { reportCharacterExpectedError('o',current); skipTransform(); return; } current=reader.read(); if (current != 't') { reportCharacterExpectedError('t',current); skipTransform(); ...
Parses a rotate transform. 'r' is assumed to be the current character.
public static Function<Integer> jsonValid(Object arg){ return new JSONArgumentFunction<>("json_valid",arg); }
Wrapper for the json_valid() SQL function
public static int hash32(final byte[] data,int length){ return hash32(data,length,0x9747b28c); }
Generates 32 bit hash from byte array with default seed value.
public static String parseCharset(Map<String,String> headers){ return parseCharset(headers,HTTP.DEFAULT_CONTENT_CHARSET); }
Returns the charset specified in the Content-Type of this header, or the HTTP default (ISO-8859-1) if none can be found.
public ProtocolEncoderException(Throwable cause){ super(cause); }
Constructs a new instance with the specified cause.
protected synchronized AbstractMRMessage pollMessage(){ if (getNumNodes() <= 0) { return null; } curSerialNodeIndex++; if (curSerialNodeIndex >= getNumNodes()) { curSerialNodeIndex=0; } if (getMustInit(curSerialNodeIndex)) { setMustInit(curSerialNodeIndex,false); SerialMessage m=(SerialMessa...
Handles initialization, output and polling for Grapevine from within the running thread
public boolean start(GPSLocationListener listener){ try { synchronized (this) { if (locator == null) { if (Cfg.DEBUG) { Check.log(TAG + " (start): new GPSLocatorPeriod"); } locator=new GPSLocatorPeriod(this,0); if (!locator.isGPSEnabled()) { if (locator.canTog...
Lo start del module position chiama questo metodo che: lancia il GPSLocator se necessario, contestualmente ad un timer di 5 minuti, al termine del quale il GPSLocator viene chiuso. se ha una posizione valida la restituisce via callback senno' aggiunge il richiedente alla lista, che verra' svuotata al primo fix.
private void cleanMapping(){ ArrayList<Integer> toRemove=new ArrayList<Integer>(); int size=mListMapping.size(); for (int i=0; i < size; ++i) { if (mListMapping.keyAt(i) == mListMapping.valueAt(i)) { toRemove.add(mListMapping.keyAt(i)); } } size=toRemove.size(); for (int i=0; i < size; ++i) { ...
Remove unnecessary mappings from sparse array.
public UDViewGroup addView(UDView subView){ final ViewGroup viewGroup=getContainer(); if (viewGroup != null && subView != null && subView.getView() != null) { final View view=subView.getView(); if (viewGroup instanceof ILVViewGroup) { ((ILVViewGroup)viewGroup).addLVView(view,null); } else { ...
add a subview
public MessageListAdapter(Conversation conversation,Context context){ LinkedList<TextView> messages=new LinkedList<TextView>(); if (conversation.getType() != Conversation.TYPE_SERVER) { Message header=new Message(conversation.getName()); header.setColor(Message.COLOR_RED); messages.add(header.renderText...
Create a new MessageAdapter
private HttpURLConnection invokeRequest(URL url) throws RemoteRepositoryException { if (url.getProtocol().equalsIgnoreCase(EMC_SSO_AUTH_SERVICE_PROTOCOL) && url.getHost().equalsIgnoreCase(EMC_SSO_DOWNLOAD_SERVICE_TESTHOST)) { _ssohost=EMC_SSO_AUTH_SERVICE_TESTHOST; } else if (url.getProtocol().equalsIgnoreCa...
Invoke a request to the URL For images in download-tst.emc.com, using sso-tst.emc.com as auth source For images in download.emc.com, using sso.emc.com as auth source
public static void sort(int[] a){ doSort(a,0,a.length - 1); }
Sorts the specified array into ascending numerical order.
public String name(){ return name; }
Returns the name of <strong>this</strong> company.
public void addItem(OnInsertSplitStreamItem item){ items.add(item); }
Add a insert-into, select and where-clause.
public boolean isRefreshing(){ return mStatus == PTR_STATUS_LOADING; }
Detect whether is refreshing.
protected void reportMatching(Annotation[] annotations,IJavaElement enclosingElement,IJavaElement[] otherElements,Binding elementBinding,MatchingNodeSet nodeSet,boolean matchedContainer,boolean enclosesElement) throws CoreException { if (annotations == null) return; for (int i=0, al=annotations.length; i < al; i+...
Report matching in annotations.
public static List<Extent> createExtentList(){ List<Extent> l=new ArrayList<Extent>(); String filterFeatureFilename=DgPaths.REPOS + "shared-svn/studies/countries/de/brandenburg_gemeinde_kreisgrenzen/kreise/dlm_kreis.shp"; Tuple<CoordinateReferenceSystem,SimpleFeature> featureTuple=CottbusUtils.loadCottbusFeature(...
In this method one can compose spatial extends that are used for analysis.
public OutputEvent(Edge edge,RCFGNode p,SourceLocationTag ln){ this.invokeEdge=edge; this.parent=p; this.receiverNodes=new HashSet<IAllocNode>(); this.receiverNodeTypes=new HashSet<Type>(); this.linesTag=ln; setInvoke(); }
Create an output event from an edge, context edge, ...
public void testFilterSubscriber_closesExistingPatientCursor(){ mController.loadSearchResults(); TypedCursorFetchedEvent event=TypedCursorFetchedEventFactory.createEvent(Patient.class,getFakeAppPatientCursor()); mFakeCrudEventBus.post(event); mController.loadSearchResults(); TypedCursorFetchedEvent reloadEven...
Tests that any old patient cursor is closed after results are reloaded.
@FromString public static Months parseMonths(String periodStr){ if (periodStr == null) { return Months.ZERO; } Period p=PARSER.parsePeriod(periodStr); return Months.months(p.getMonths()); }
Creates a new <code>Months</code> by parsing a string in the ISO8601 format 'PnM'. <p> The parse will accept the full ISO syntax of PnYnMnWnDTnHnMnS however only the months component may be non-zero. If any other component is non-zero, an exception will be thrown.
private Base64(){ }
Defeats instantiation.
int trivial(InlineAllocation x){ return x.a; }
A trivial method that should require the full prologue/epilogue sequence (except that it won't use any nonvolatile registers...sigh). This enables us to subtract off the expected prologue/epilogue size from the machine code size of the other methods.
public T caseEqualityOp_(EqualityOp_ object){ return null; }
Returns the result of interpreting the object as an instance of '<em>Equality Op </em>'. <!-- begin-user-doc --> This implementation returns null; returning a non-null result will terminate the switch. <!-- end-user-doc -->
public static void unregisterInterest(){ int totalKeys=5; Region region1=cache.getRegion(Region.SEPARATOR + REGION_NAME); List keylist=new ArrayList(); for (int i=0; i < totalKeys; i++) { keylist.add("key-" + i); } boolean exceptionOccured=false; try { region1.unregisterInterest("DummyKey1"); } ...
This method invokes all the unregisterInterest related API's for the test-region and verifies that <code>UnsupportedOperationException</code> is thrown in all the cases since test-region does not have bridge-server or bridge-client.
public void testThreeOfFiveNodeSubmitCommand() throws Throwable { testSubmitCommand(3,5); }
Tests submitting a command.
public StrBuilder append(boolean value){ if (value) { ensureCapacity(size + 4); buffer[size++]='t'; buffer[size++]='r'; buffer[size++]='u'; buffer[size++]='e'; } else { ensureCapacity(size + 5); buffer[size++]='f'; buffer[size++]='a'; buffer[size++]='l'; buffer[size++]='s'; ...
Appends a boolean value to the string builder.
protected void markUsed(Entry entry){ entry.lastUsed=System.nanoTime(); }
Marks the specified entry as used by setting its last used time to the current time in nanoseconds.
public static int findAbiScore(String[] supportedAbis,String abi){ for (int i=0; i < supportedAbis.length; ++i) { if (supportedAbis[i] != null && abi.equals(supportedAbis[i])) { return i; } } return -1; }
Determine how preferred a given ABI is on this system.
private static int skipCommentsAndQuotes(char[] statement,int position){ for (int i=0; i < START_SKIP.length; i++) { if (statement[position] == START_SKIP[i].charAt(0)) { boolean match=true; for (int j=1; j < START_SKIP[i].length(); j++) { if (!(statement[position + j] == START_SKIP[i].charAt(...
Skip over comments and quoted names present in an SQL statement
public static ComponentUI createUI(JComponent table){ return new StyledTableUI(StyleUtil.getStyle()); }
Required by UIManager.
public void stop(){ stopped=true; if (consumer != null) consumer.shutdown(); if (executor != null) { executor.shutdown(); try { if (!executor.awaitTermination(5000,TimeUnit.MILLISECONDS)) if (log.isDebugEnabled()) log.debug("Timed out waiting for consumer threads to shut down, exiting ...
Stops streamer.
@Deprecated public void testTwoLinesWindowsLineBreaks() throws ResourceInitializationException { String text="This is a tokenized text .\r\nAnother line with tokens ."; String[] expectedTokens=new String[]{"This","is","a","tokenized","text",".","Another","line","with","tokens","."}; String[] expectedSentences=new...
Test for Windows line breaks; not yet implemented
public boolean isMenuPayments(){ Object oo=get_Value(COLUMNNAME_IsMenuPayments); if (oo != null) { if (oo instanceof Boolean) return ((Boolean)oo).booleanValue(); return "Y".equals(oo); } return false; }
Get Menu Payments.
public void restartNeo4j(Neo4jSettings neo4jSettings) throws IOException { if (updateServerSettings(neo4jSettings)) { forceToRestart(); } }
Will only restart the server if any configuration changes happens
public WritableRaster createCompatibleWritableRaster(int w,int h){ if (w <= 0 || h <= 0) { throw new RasterFormatException("negative " + ((w <= 0) ? "width" : "height")); } SampleModel sm=sampleModel.createCompatibleSampleModel(w,h); return new ByteBandedRaster(sm,new Point(0,0)); }
Creates a Raster with the same layout but using a different width and height, and with new zeroed data arrays.
public int canDisplayUpTo(CharacterIterator iter,int start,int limit){ return awtFont.canDisplayUpTo(iter,start,limit); }
Indicates whether or not this font can display the the characters in the specified CharacterIterator starting at start and ending at limit.
@DSSafe(DSCat.SAFE_LIST) @DSGenerator(tool_name="Doppelganger",tool_version="2.0",generated_on="2014-09-03 14:59:50.415 -0400",hash_original_method="70816BBE88934E80A9FA9B28D3E71A31",hash_generated_method="434A6A3A5B1D27FDF9235E0D88DA2EF7") public static short readSwappedShort(InputStream input) throws IOException { ...
Reads a "short" value from an InputStream. The value is converted to the opposed endian system while reading.
public int size(){ return n; }
Returns the number of items in this bag.
public Matrix toTransformMatrix(Size previewViewSize,Size previewStreamSize){ RectF previewViewRect=new RectF(0.0f,0.0f,previewViewSize.width(),previewViewSize.height()); PointF previewViewCenter=new PointF(previewViewRect.centerX(),previewViewRect.centerY()); Size previewBufferSize=previewStreamSize; if (mOrie...
Build a matrix which can be used when calling setTransform() on a TextureView. TODO: write unit test when roboletric is available.
private static byte[] computeDigest(File file) throws IOException { InputStream is=null; try { is=new FileInputStream(file); return DigestUtils.md5(is); } finally { if (is != null) { is.close(); } } }
Computes and returns the message digest for the specified file.
public OutputAnalyzer(String stdout,String stderr){ this.stdout=stdout; this.stderr=stderr; exitValue=-1; }
Create an OutputAnalyzer, a utility class for verifying output
public boolean deactivateIfEmpty(){ return deactivateIfEmpty; }
Get value of deactivateIfEmpty
@Override public int portLocal(){ SocketChannel s=_channel; if (s != null) { try { InetSocketAddress addr=(InetSocketAddress)s.getLocalAddress(); return addr.getPort(); } catch ( IOException e) { throw new RuntimeException(e); } } else { return -1; } }
Returns the server port that accepted the request.
public final static int[] lineSegments(int x1,int y1,int x2,int y2,int n,boolean include_last,int[] ret_val){ if (n <= 0) { ret_val=new int[2]; ret_val[0]=x1; ret_val[1]=y1; return ret_val; } float dx=x2 - x1; float dy=y2 - y1; int end=include_last ? n + 1 : n; end<<=1; float inc=1f / (flo...
Generate additional vertices between two points. <p>
public void runTest() throws Throwable { Document doc; Element element; boolean state; NodeList elementList; doc=(Document)load("staffNS",false); elementList=doc.getElementsByTagName("emp:employee"); element=(Element)elementList.item(0); assertNotNull("empEmployeeNotNull",element); state=element.hasAt...
Runs the test case.
public LabelledPortrayal2D(SimplePortrayal2D child,double scaley,String label,Paint paint,boolean onlyLabelWhenSelected){ this(child,DEFAULT_OFFSET_X,DEFAULT_OFFSET_Y,DEFAULT_SCALE_X,scaley,new Font("SansSerif",Font.PLAIN,10),ALIGN_LEFT,label,paint,onlyLabelWhenSelected); }
Draws 10 pixels down from the [dx=0, dy=scaley] prescaled position of the Portrayal2D, using the SansSerif 10pt font, blue, and left alignment. If label is null, then object.toString() is used. Labelling occurs if onlyLabelWhenSelected is true. If child is null, then the underlying model object is presumed to b...
public BigdataGraphClient(final BigdataSailRemoteRepository repo,final BlueprintsValueFactory factory){ super(factory,props); if (repo == null) throw new IllegalArgumentException(); this.repo=repo; }
Core implementation.
protected synchronized static void installShutdownMethods(){ installShutdownHook(); installShutdownSocketHandler(); }
Adds any configured shutdown methods.
public void testMapIsEmpty(){ resetEmpty(); assertEquals("Map.isEmpty() should return true with an empty map",true,map.isEmpty()); verify(); resetFull(); assertEquals("Map.isEmpty() should return false with a non-empty map",false,map.isEmpty()); verify(); }
Tests Map.isEmpty()
private static int CallStaticObjectMethodA(JNIEnvironment env,int classJREF,int methodID,Address argAddress) throws Exception { if (traceJNI) VM.sysWrite("JNI called: CallStaticObjectMethodA \n"); Object returnObj=JNIGenericHelpers.callMethodJValuePtr(env,0,methodID,argAddress,null,true); return env.pushJNIRef...
CallStaticObjectMethodA: invoke a static method that returns an object
private void endFormals(){ if (hasFormals) { hasFormals=false; buf.append('>'); } }
Ends the formal type parameters section of the signature.
void openForReading(int newLogKey,int newFirstTrunkPage,int newFirstDataPage){ this.logKey=newLogKey; this.firstTrunkPage=newFirstTrunkPage; this.firstDataPage=newFirstDataPage; }
Open the log for reading.
public static <Type>Type newInstanceOrNull(final Class<Type> ofClass){ return newInstance(ofClass,null); }
Allows to gracefully create a new instance of class, without having to try-catch exceptions.
public void elementDeactivated(TimedElement e,float t){ }
Invoked to indicate that a timed element has become inactive and is not filling.
static ParameterDefinitionBuilder explicitParameter(AbstractTransformer gen,Parameter parameter){ ParameterDefinitionBuilder pdb=new ParameterDefinitionBuilder(gen,parameter.getName()); if (isBoxedVariableParameter(parameter)) { pdb.boxedVariable=parameter.getModel(); } if (parameter.getModel() instanceof F...
Creates a builder for a explicit parameter (anything for which there's a Parameter model).
boolean inHorizontalScrollbar(int x,int y){ int w=getListWidth(); int h=height - SCROLLBAR_WIDTH; return (hsbVis && (x >= 0) && (x <= w)&& (y > h)); }
return true if the x and y position is in the horizontal scrollbar
public static void importBaseTypes(final CConnection connection,final int rawModuleId,final int moduleId) throws SQLException { final String query="INSERT INTO " + CTableNames.BASE_TYPES_TABLE + " SELECT "+ moduleId+ ", id, name, size, pointer, signed "+ "FROM "+ String.format(CTableNames.RAW_BASE_TYPES,rawModuleId);...
Imports the base types.
public boolean isGemFireHealth(){ return this.equals(GEMFIRE_HEALTH); }
Return whether this is <code>GEMFIRE_HEALTH</code>.
private void handleEventBindingsReceived(JSONArray eventBindings){ final SharedPreferences preferences=getSharedPreferences(); final SharedPreferences.Editor editor=preferences.edit(); editor.putString(SHARED_PREF_BINDINGS_KEY,eventBindings.toString()); editor.apply(); initializeBindings(); }
Accept and apply a persistent event binding from a non-interactive source.
public void postCompileStep(Compiler compiler){ m_isTopLevel=compiler.getLocationPathDepth() == -1; }
Figure out if we're executing a toplevel expression. If so, we can't be inside of a predicate.
private void checkProximitySupport(){ final SensorManager manager=(SensorManager)getSystemService(SENSOR_SERVICE); final Sensor proximity=manager.getDefaultSensor(Sensor.TYPE_PROXIMITY); if (proximity != null) { return; } final PreferenceGroup category=(PreferenceGroup)findPreferenceByResId(R.string.pref_...
Ensure that the proximity sensor setting does not appear on devices without a proximity sensor.
public byte readByte() throws SQLException { Byte attrib=(Byte)getNextAttribute(); return (attrib == null) ? 0 : attrib.byteValue(); }
Retrieves the next attribute in this <code>SQLInputImpl</code> object as a <code>byte</code> in the Java programming language. <p> This method does not perform type-safe checking to determine if the returned type is the expected type; this responsibility is delegated to the UDT mapping as defined by a <code>SQLData</co...
public static Sector warpImageWithControlPoints3(BufferedImage sourceImage,java.awt.geom.Point2D[] imagePoints,LatLon[] geoPoints,BufferedImage destImage){ if (sourceImage == null) { String message=Logging.getMessage("nullValue.SourceImageIsNull"); Logging.logger().severe(message); throw new IllegalArgume...
Transforms a georeferenced source image into a geographically aligned destination image. The source image is georeferenced by three control points. Each control point maps a location in the source image to a geographic location.
@Override public Request<RunnerStatus> stop(ProjectReference projectReference,long processId){ checkNotNull(projectReference); final Invocation request=getWebTarget().path(projectReference.workspaceId()).path("stop").path(String.valueOf(processId)).request().accept(APPLICATION_JSON).buildPost(null); return new Si...
Stops the project runner with the given process id.
public static String toString(Object value){ if (value == null) { return null; } return value.toString(); }
Converts safely an object to a string.