mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
Merge pull request #3 from designsystemsinternational/fixing-comments
Fixing comments
This commit is contained in:
@@ -1029,7 +1029,7 @@ public class PGraphicsJava2D extends PGraphics {
|
||||
*
|
||||
*
|
||||
* @webref Rendering
|
||||
* @webBrief Blends the pixels in the display window according to a defined mode.
|
||||
* @webBrief Blends the pixels in the display window according to a defined mode
|
||||
* @param mode the blending mode to use
|
||||
*/
|
||||
@Override
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -135,7 +135,7 @@ public interface PConstants {
|
||||
*
|
||||
* @webref constants
|
||||
* @webBrief PI is a mathematical constant with the value
|
||||
* 3.14159265358979323846.
|
||||
* 3.14159265358979323846
|
||||
* @see PConstants#TWO_PI
|
||||
* @see PConstants#TAU
|
||||
* @see PConstants#HALF_PI
|
||||
@@ -152,7 +152,7 @@ public interface PConstants {
|
||||
*
|
||||
* @webref constants
|
||||
* @webBrief HALF_PI is a mathematical constant with the value
|
||||
* 1.57079632679489661923.
|
||||
* 1.57079632679489661923
|
||||
* @see PConstants#PI
|
||||
* @see PConstants#TWO_PI
|
||||
* @see PConstants#TAU
|
||||
@@ -168,7 +168,7 @@ public interface PConstants {
|
||||
* <b>sin()</b> and <b>cos()</b>.
|
||||
*
|
||||
* @webref constants
|
||||
* @webBrief QUARTER_PI is a mathematical constant with the value 0.7853982.
|
||||
* @webBrief QUARTER_PI is a mathematical constant with the value 0.7853982
|
||||
* @see PConstants#PI
|
||||
* @see PConstants#TWO_PI
|
||||
* @see PConstants#TAU
|
||||
@@ -183,7 +183,7 @@ public interface PConstants {
|
||||
* <b>sin()</b> and <b>cos()</b>.
|
||||
*
|
||||
* @webref constants
|
||||
* @webBrief TWO_PI is a mathematical constant with the value 6.28318530717958647693.
|
||||
* @webBrief TWO_PI is a mathematical constant with the value 6.28318530717958647693
|
||||
* @see PConstants#PI
|
||||
* @see PConstants#TAU
|
||||
* @see PConstants#HALF_PI
|
||||
@@ -199,7 +199,7 @@ public interface PConstants {
|
||||
* <b>cos()</b>.
|
||||
*
|
||||
* @webref constants
|
||||
* @webBrief An alias for TWO_PI
|
||||
* @webBrief An alias for <b>TWO_PI</b>
|
||||
* @see PConstants#PI
|
||||
* @see PConstants#TWO_PI
|
||||
* @see PConstants#HALF_PI
|
||||
|
||||
@@ -72,7 +72,7 @@ import java.util.HashMap;
|
||||
* </PRE>
|
||||
*
|
||||
* @webref typography
|
||||
* @webBrief Grayscale bitmap font class used by Processing.
|
||||
* @webBrief Grayscale bitmap font class used by Processing
|
||||
* @see PApplet#loadFont(String)
|
||||
* @see PApplet#createFont(String, float, boolean, char[])
|
||||
* @see PGraphics#textFont(PFont)
|
||||
@@ -876,7 +876,7 @@ public class PFont implements PConstants {
|
||||
*
|
||||
*
|
||||
* @webref pfont
|
||||
* @webBrief Gets a list of the fonts installed on the system.
|
||||
* @webBrief Gets a list of the fonts installed on the system
|
||||
* @usage application
|
||||
* @brief Gets a list of the fonts installed on the system
|
||||
*/
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -54,7 +54,7 @@ import processing.awt.ShimAWT;
|
||||
*
|
||||
*
|
||||
* @webref image
|
||||
* @webBrief Datatype for storing images.
|
||||
* @webBrief Datatype for storing images
|
||||
* @usage Web & Application
|
||||
* @instanceName pimg any object of type PImage
|
||||
* @see PApplet#loadImage(String)
|
||||
@@ -83,7 +83,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
|
||||
/**
|
||||
*
|
||||
* The pixels[] array contains the values for all the pixels in the image. These
|
||||
* The <b>pixels[]</b> array contains the values for all the pixels in the image. These
|
||||
* values are of the color datatype. This array is the size of the image,
|
||||
* meaning if the image is 100 x 100 pixels, there will be 10,000 values and if
|
||||
* the window is 200 x 300 pixels, there will be 60,000 values. <br />
|
||||
@@ -96,7 +96,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
*
|
||||
*
|
||||
* @webref image:pixels
|
||||
* @webBrief Array containing the color of every pixel in the image.
|
||||
* @webBrief Array containing the color of every pixel in the image
|
||||
* @usage web_application
|
||||
*/
|
||||
public int[] pixels;
|
||||
@@ -113,7 +113,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
* The width of the image in units of pixels.
|
||||
*
|
||||
* @webref pimage:field
|
||||
* @webBrief The width of the image in units of pixels.
|
||||
* @webBrief The width of the image in units of pixels
|
||||
* @usage web_application
|
||||
*/
|
||||
public int width;
|
||||
@@ -123,7 +123,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
* The height of the image in units of pixels.
|
||||
*
|
||||
* @webref pimage:field
|
||||
* @webBrief The height of the image in units of pixels.
|
||||
* @webBrief The height of the image in units of pixels
|
||||
* @usage web_application
|
||||
*/
|
||||
public int height;
|
||||
@@ -379,7 +379,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
* copy all data into the pixels[] array
|
||||
*
|
||||
* @webref pimage:pixels
|
||||
* @webBrief Loads the pixel data for the image into its <b>pixels[]</b> array.
|
||||
* @webBrief Loads the pixel data for the image into its <b>pixels[]</b> array
|
||||
* @usage web_application
|
||||
*/
|
||||
public void loadPixels() { // ignore
|
||||
@@ -408,7 +408,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
* future.
|
||||
*
|
||||
* @webref pimage:pixels
|
||||
* @webBrief Updates the image with the data in its <b>pixels[]</b> array.
|
||||
* @webBrief Updates the image with the data in its <b>pixels[]</b> array
|
||||
* @usage web_application
|
||||
* @param x x-coordinate of the upper-left corner
|
||||
* @param y y-coordinate of the upper-left corner
|
||||
@@ -464,17 +464,17 @@ public class PImage implements PConstants, Cloneable {
|
||||
* Resize the image to a new width and height. To make the image scale
|
||||
* proportionally, use 0 as the value for the <b>wide</b> or <b>high</b>
|
||||
* parameter. For instance, to make the width of an image 150 pixels, and
|
||||
* change the height using the same proportion, use resize(150, 0).<br />
|
||||
* change the height using the same proportion, use <b>resize(150, 0)</b>.<br />
|
||||
* <br />
|
||||
* Even though a PGraphics is technically a PImage, it is not possible to
|
||||
* rescale the image data found in a PGraphics. (It's simply not possible
|
||||
* Even though a PGraphics is technically a <b>PImage</b>, it is not possible to
|
||||
* rescale the image data found in a <b>PGraphics</b>. (It's simply not possible
|
||||
* to do this consistently across renderers: technically infeasible with
|
||||
* P3D, or what would it even do with PDF?) If you want to resize PGraphics
|
||||
* P3D, or what would it even do with PDF?) If you want to resize <b>PGraphics</b>
|
||||
* content, first get a copy of its image data using the <b>get()</b>
|
||||
* method, and call <b>resize()</b> on the PImage that is returned.
|
||||
*
|
||||
* @webref pimage:method
|
||||
* @webBrief Resize the image to a new width and height.
|
||||
* @webBrief Resize the image to a new width and height
|
||||
* @usage web_application
|
||||
* @param w the resized image width
|
||||
* @param h the resized image height
|
||||
@@ -551,7 +551,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
* pixels[] array directly.
|
||||
*
|
||||
* @webref image:pixels
|
||||
* @webBrief Reads the color of any pixel or grabs a rectangle of pixels.
|
||||
* @webBrief Reads the color of any pixel or grabs a rectangle of pixels
|
||||
* @usage web_application
|
||||
* @param x x-coordinate of the pixel
|
||||
* @param y y-coordinate of the pixel
|
||||
@@ -1582,7 +1582,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
*
|
||||
* @webref color:creating_reading
|
||||
* @webBrief Blends two color values together based on the blending mode given as the
|
||||
* <b>MODE</b> parameter.
|
||||
* <b>MODE</b> parameter
|
||||
* @usage web_application
|
||||
* @param c1 the first color to blend
|
||||
* @param c2 the second color to blend
|
||||
@@ -1631,16 +1631,16 @@ public class PImage implements PConstants, Cloneable {
|
||||
* of the following modes to blend the colors of source pixels (A) with the
|
||||
* ones of pixels in the destination image (B):<br />
|
||||
* <br />
|
||||
* BLEND - linear interpolation of colours: C = A*factor + B<br />
|
||||
* BLEND - linear interpolation of colours: <b>C = A*factor + B</b><br />
|
||||
* <br />
|
||||
* ADD - additive blending with white clip: C = min(A*factor + B, 255)<br />
|
||||
* ADD - additive blending with white clip: <b>C = min(A*factor + B, 255)</b><br />
|
||||
* <br />
|
||||
* SUBTRACT - subtractive blending with black clip: C = max(B - A*factor,
|
||||
* 0)<br />
|
||||
* SUBTRACT - subtractive blending with black clip: <b>C = max(B - A*factor,
|
||||
* 0)</b><br />
|
||||
* <br />
|
||||
* DARKEST - only the darkest colour succeeds: C = min(A*factor, B)<br />
|
||||
* DARKEST - only the darkest colour succeeds: <b>C = min(A*factor, B)</b><br />
|
||||
* <br />
|
||||
* LIGHTEST - only the lightest colour succeeds: C = max(A*factor, B)<br />
|
||||
* LIGHTEST - only the lightest colour succeeds: <b>C = max(A*factor, B)</b><br />
|
||||
* <br />
|
||||
* DIFFERENCE - subtract colors from underlying image.<br />
|
||||
* <br />
|
||||
@@ -1674,7 +1674,7 @@ public class PImage implements PConstants, Cloneable {
|
||||
*
|
||||
*
|
||||
* @webref image:pixels
|
||||
* @webBrief Copies a pixel or rectangle of pixels using different blending modes.
|
||||
* @webBrief Copies a pixel or rectangle of pixels using different blending modes
|
||||
* @param src an image variable referring to the source image
|
||||
* @param sx X coordinate of the source's upper left corner
|
||||
* @param sy Y coordinate of the source's upper left corner
|
||||
@@ -3289,7 +3289,7 @@ int testFunction(int dst, int src) {
|
||||
* file with no error.
|
||||
*
|
||||
* @webref pimage:method
|
||||
* @webBrief Saves the image to a TIFF, TARGA, PNG, or JPEG file.
|
||||
* @webBrief Saves the image to a TIFF, TARGA, PNG, or JPEG file
|
||||
* @usage application
|
||||
* @param filename a sequence of letters and numbers
|
||||
*/
|
||||
|
||||
@@ -87,7 +87,7 @@ import java.util.Base64;
|
||||
* </p>
|
||||
*
|
||||
* @webref shape
|
||||
* @webBrief Datatype for storing shapes.
|
||||
* @webBrief Datatype for storing shapes
|
||||
* @usage Web & Application
|
||||
* @see PApplet#loadShape(String)
|
||||
* @see PApplet#createShape()
|
||||
@@ -145,7 +145,7 @@ public class PShape implements PConstants {
|
||||
|
||||
/**
|
||||
*
|
||||
* The width of the PShape document.
|
||||
* The width of the <b>PShape</b> document.
|
||||
*
|
||||
* @webref pshape:field
|
||||
* @usage web_application
|
||||
@@ -155,7 +155,7 @@ public class PShape implements PConstants {
|
||||
public float width;
|
||||
/**
|
||||
*
|
||||
* The height of the PShape document.
|
||||
* The height of the <b>PShape</b> document.
|
||||
*
|
||||
* @webref pshape:field
|
||||
* @usage web_application
|
||||
@@ -400,7 +400,7 @@ public class PShape implements PConstants {
|
||||
|
||||
/**
|
||||
*
|
||||
* Returns a boolean value "true" if the image is set to be visible, "false" if
|
||||
* Returns a boolean value <b>true</b> if the image is set to be visible, <b>false</b> if
|
||||
* not. This value can be modified with the <b>setVisible()</b> method.<br />
|
||||
* <br />
|
||||
* The default visibility of a shape is usually controlled by whatever program
|
||||
@@ -409,8 +409,8 @@ public class PShape implements PConstants {
|
||||
*
|
||||
* @webref pshape:method
|
||||
* @usage web_application
|
||||
* @webBrief Returns a boolean value "true" if the image is set to be visible,
|
||||
* "false" if not
|
||||
* @webBrief Returns a boolean value <b>true</b> if the image is set to be visible,
|
||||
* <b>false</b> if not
|
||||
* @see PShape#setVisible(boolean)
|
||||
*/
|
||||
public boolean isVisible() {
|
||||
@@ -781,7 +781,7 @@ public class PShape implements PConstants {
|
||||
* function. It's always and only used with <b>createShape()</b>.
|
||||
*
|
||||
* @webref pshape:method
|
||||
* @webBrief Starts the creation of a new PShape
|
||||
* @webBrief Starts the creation of a new <b>PShape</b>
|
||||
* @see PApplet#endShape()
|
||||
*/
|
||||
public void beginShape() {
|
||||
@@ -799,7 +799,7 @@ public class PShape implements PConstants {
|
||||
* function. It's always and only used with <b>createShape()</b>.
|
||||
*
|
||||
* @webref pshape:method
|
||||
* @webBrief Finishes the creation of a new PShape
|
||||
* @webBrief Finishes the creation of a new <b>PShape</b>
|
||||
* @see PApplet#beginShape()
|
||||
*/
|
||||
public void endShape() {
|
||||
@@ -2005,7 +2005,7 @@ public class PShape implements PConstants {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the number of children within the PShape.
|
||||
* Returns the number of children within the <b>PShape</b>.
|
||||
*
|
||||
* @webref
|
||||
* @webBrief Returns the number of children
|
||||
@@ -2037,7 +2037,7 @@ public class PShape implements PConstants {
|
||||
*
|
||||
* @webref pshape:method
|
||||
* @usage web_application
|
||||
* @webBrief Returns a child element of a shape as a PShape object
|
||||
* @webBrief Returns a child element of a shape as a <b>PShape</b> object
|
||||
* @param index the layer position of the shape to get
|
||||
* @see PShape#addChild(PShape)
|
||||
*/
|
||||
@@ -2256,7 +2256,7 @@ public class PShape implements PConstants {
|
||||
|
||||
/**
|
||||
* The <b>getVertexCount()</b> method returns the number of vertices that
|
||||
* make up a PShape. In the above example, the value 4 is returned by the
|
||||
* make up a <b>PShape</b>. In the above example, the value 4 is returned by the
|
||||
* <b>getVertexCount()</b> method because 4 vertices are defined in
|
||||
* <b>setup()</b>.
|
||||
*
|
||||
@@ -2274,7 +2274,7 @@ public class PShape implements PConstants {
|
||||
|
||||
|
||||
/**
|
||||
* The <b>getVertex()</b> method returns a PVector with the coordinates of
|
||||
* The <b>getVertex()</b> method returns a <b>PVector</b> with the coordinates of
|
||||
* the vertex point located at the position defined by the <b>index</b>
|
||||
* parameter. This method works when shapes are created as shown in the
|
||||
* example above, but won't work properly when a shape is defined explicitly
|
||||
@@ -3309,7 +3309,7 @@ public class PShape implements PConstants {
|
||||
/**
|
||||
*
|
||||
* Replaces the current matrix of a shape with the identity matrix. The
|
||||
* equivalent function in OpenGL is glLoadIdentity().
|
||||
* equivalent function in OpenGL is <b>glLoadIdentity()</b>.
|
||||
*
|
||||
* @webref pshape:method
|
||||
* @webBrief Replaces the current matrix of a shape with the identity matrix
|
||||
|
||||
@@ -62,7 +62,7 @@ import java.io.Serializable;
|
||||
* <a href="http://www.shiffman.net">Dan Shiffman</a>.
|
||||
*
|
||||
* @webref math
|
||||
* @webBrief A class to describe a two or three dimensional vector.
|
||||
* @webBrief A class to describe a two or three dimensional vector
|
||||
*/
|
||||
public class PVector implements Serializable {
|
||||
/**
|
||||
@@ -138,7 +138,7 @@ public class PVector implements Serializable {
|
||||
/**
|
||||
*
|
||||
* Sets the x, y, and z component of the vector using two or three separate
|
||||
* variables, the data from a PVector, or the values from a float array.
|
||||
* variables, the data from a <b>PVector</b>, or the values from a float array.
|
||||
*
|
||||
*
|
||||
* @webref pvector:method
|
||||
@@ -205,7 +205,7 @@ public class PVector implements Serializable {
|
||||
* @webref pvector:method
|
||||
* @usage web_application
|
||||
* @return the random PVector
|
||||
* @webBrief Make a new 2D unit vector with a random direction.
|
||||
* @webBrief Make a new 2D unit vector with a random direction
|
||||
* @see PVector#random3D()
|
||||
*/
|
||||
static public PVector random2D() {
|
||||
@@ -255,7 +255,7 @@ public class PVector implements Serializable {
|
||||
* @webref pvector:method
|
||||
* @usage web_application
|
||||
* @return the random PVector
|
||||
* @webBrief Make a new 3D unit vector with a random direction.
|
||||
* @webBrief Make a new 3D unit vector with a random direction
|
||||
* @see PVector#random2D()
|
||||
*/
|
||||
static public PVector random3D() {
|
||||
@@ -345,7 +345,7 @@ public class PVector implements Serializable {
|
||||
|
||||
/**
|
||||
*
|
||||
* Copies the components of the vector and returns the result as a PVector.
|
||||
* Copies the components of the vector and returns the result as a <b>PVector</b>.
|
||||
*
|
||||
*
|
||||
* @webref pvector:method
|
||||
@@ -420,7 +420,7 @@ public class PVector implements Serializable {
|
||||
*
|
||||
* Adds x, y, and z components to a vector, adds one vector to another, or adds
|
||||
* two independent vectors together. The version of the method that adds two
|
||||
* vectors together is a static method and returns a new PVector, the others act
|
||||
* vectors together is a static method and returns a new <b>PVector</b>, the others act
|
||||
* directly on the vector itself. See the examples for more context.
|
||||
*
|
||||
*
|
||||
@@ -488,7 +488,7 @@ public class PVector implements Serializable {
|
||||
*
|
||||
* Subtracts x, y, and z components from a vector, subtracts one vector from
|
||||
* another, or subtracts two independent vectors. The version of the method that
|
||||
* substracts two vectors is a static method and returns a PVector, the others
|
||||
* substracts two vectors is a static method and returns a <b>PVector</b>, the others
|
||||
* act directly on the vector. See the examples for more context. In all cases,
|
||||
* the second vector (v2) is subtracted from the first (v1), resulting in v1-v2.
|
||||
*
|
||||
@@ -557,8 +557,8 @@ public class PVector implements Serializable {
|
||||
*
|
||||
* Multiplies a vector by a scalar. The version of the method that uses a float
|
||||
* acts directly on the vector upon which it is called (as in the first example
|
||||
* above). The versions that receive both a PVector and a float as arguments are
|
||||
* static methods, and each returns a new PVector that is the result of the
|
||||
* above). The versions that receive both a <b>PVector</b> and a float as arguments are
|
||||
* static methods, and each returns a new <b>PVector</b> that is the result of the
|
||||
* multiplication operation. Both examples above produce the same visual output.
|
||||
*
|
||||
*
|
||||
@@ -601,8 +601,8 @@ public class PVector implements Serializable {
|
||||
*
|
||||
* Divides a vector by a scalar. The version of the method that uses a float
|
||||
* acts directly on the vector upon which it is called (as in the first example
|
||||
* above). The version that receives both a PVector and a float as arguments is
|
||||
* a static methods, and returns a new PVector that is the result of the
|
||||
* above). The version that receives both a <b>PVector</b> and a <b>float</b> as arguments is
|
||||
* a static methods, and returns a new <b>PVector</b> that is the result of the
|
||||
* division operation. Both examples above produce the same visual output.
|
||||
*
|
||||
* @webref pvector:method
|
||||
@@ -898,7 +898,7 @@ public class PVector implements Serializable {
|
||||
* static version is used by referencing the PVector class directly. (See the
|
||||
* middle example above.) The non-static versions, <b>lerp(v, amt)</b> and
|
||||
* <b>lerp(x, y, z, amt)</b>, do not create a new PVector, but transform the
|
||||
* values of the PVector on which they are called. These non-static versions
|
||||
* values of the <b>PVector</b> on which they are called. These non-static versions
|
||||
* perform the same operation, but the former takes another vector as input,
|
||||
* while the latter takes three float values. (See the top and bottom examples
|
||||
* above, respectively.)
|
||||
|
||||
@@ -9,12 +9,12 @@ import processing.core.PApplet;
|
||||
|
||||
|
||||
/**
|
||||
* A simple class to use a String as a lookup for an float value. String "keys"
|
||||
* A simple class to use a <b>String</b> as a lookup for a float value. String "keys"
|
||||
* are associated with floating-point values.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief A simple table class to use a String as a lookup for an float
|
||||
* value.
|
||||
* @webBrief A simple table class to use a <b>String</b> as a lookup for a float
|
||||
* value
|
||||
* @see IntDict
|
||||
* @see StringDict
|
||||
*/
|
||||
@@ -415,7 +415,7 @@ public class FloatDict {
|
||||
|
||||
|
||||
/**
|
||||
* Add to a value. If the key does not exist, an new pair is initialized with
|
||||
* Add to a value. If the key does not exist, a new pair is initialized with
|
||||
* the value supplied.
|
||||
*
|
||||
* @webref floatdict:method
|
||||
|
||||
@@ -11,14 +11,14 @@ import processing.core.PApplet;
|
||||
|
||||
/**
|
||||
* Helper class for a list of floats. Lists are designed to have some of the
|
||||
* features of ArrayLists, but to maintain the simplicity and efficiency of
|
||||
* features of <b>ArrayLists</b>, but to maintain the simplicity and efficiency of
|
||||
* working with arrays.
|
||||
*
|
||||
* Functions like sort() and shuffle() always act on the list itself. To get
|
||||
* a sorted copy, use list.copy().sort().
|
||||
* Functions like <b>sort()</b> and <b>shuffle()</b> always act on the list itself. To get
|
||||
* a sorted copy, use <b>list.copy().sort()</b>.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief Helper class for a list of floats.
|
||||
* @webBrief Helper class for a list of floats
|
||||
* @see IntList
|
||||
* @see StringList
|
||||
*/
|
||||
@@ -678,7 +678,7 @@ public class FloatList implements Iterable<Float> {
|
||||
* <b>reverse()</b>, but is more efficient than running each separately.
|
||||
*
|
||||
* @webref floatlist:method
|
||||
* @webBrief A sort in reverse.
|
||||
* @webBrief A sort in reverse
|
||||
*/
|
||||
public void sortReverse() {
|
||||
new Sort() {
|
||||
|
||||
@@ -9,11 +9,11 @@ import processing.core.PApplet;
|
||||
|
||||
|
||||
/**
|
||||
* A simple class to use a String as a lookup for an int value. String "keys" are
|
||||
* A simple class to use a <b>String</b> as a lookup for an int value. String "keys" are
|
||||
* associated with integer values.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief A simple class to use a String as a lookup for an int value.
|
||||
* @webBrief A simple class to use a <b>String</b> as a lookup for an int value
|
||||
* @see FloatDict
|
||||
* @see StringDict
|
||||
*/
|
||||
|
||||
@@ -16,14 +16,14 @@ import processing.core.PApplet;
|
||||
|
||||
/**
|
||||
* Helper class for a list of ints. Lists are designed to have some of the
|
||||
* features of ArrayLists, but to maintain the simplicity and efficiency of
|
||||
* features of <b>ArrayLists</b>, but to maintain the simplicity and efficiency of
|
||||
* working with arrays.
|
||||
*
|
||||
* Functions like sort() and shuffle() always act on the list itself. To get
|
||||
* a sorted copy, use list.copy().sort().
|
||||
* Functions like <b>sort()</b> and <b>shuffle()</b> always act on the list itself. To get
|
||||
* a sorted copy, use <b>list.copy().sort()</b>.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief Helper class for a list of ints.
|
||||
* @webBrief Helper class for a list of ints
|
||||
* @see FloatList
|
||||
* @see StringList
|
||||
*/
|
||||
|
||||
@@ -96,7 +96,7 @@ import processing.core.PApplet;
|
||||
* @author JSON.org
|
||||
* @version 2012-11-13
|
||||
* @webref data:composite
|
||||
* @webBrief A JSONArray is an ordered sequence of values.
|
||||
* @webBrief A JSONArray is an ordered sequence of values
|
||||
* @see JSONObject
|
||||
* @see PApplet#loadJSONObject(String)
|
||||
* @see PApplet#loadJSONArray(String)
|
||||
@@ -279,7 +279,7 @@ public class JSONArray {
|
||||
|
||||
|
||||
/**
|
||||
* Gets the String value associated with the specified index.
|
||||
* Gets the <b>String</b> value associated with the specified index.
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Gets the String value associated with an index
|
||||
@@ -317,7 +317,7 @@ public class JSONArray {
|
||||
* Gets the int value associated with the specified index.
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Gets the int value associated with the specified index.
|
||||
* @webBrief Gets the int value associated with the specified index
|
||||
* @param index must be between 0 and length() - 1
|
||||
* @return The value.
|
||||
* @throws RuntimeException If the key is not found or if the value is not a number.
|
||||
@@ -395,7 +395,7 @@ public class JSONArray {
|
||||
* Gets the float value associated with the specified index.
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Gets the float value associated with the specified index.
|
||||
* @webBrief Gets the float value associated with the specified index
|
||||
* @param index must be between 0 and length() - 1
|
||||
* @see JSONArray#getInt(int)
|
||||
* @see JSONArray#getString(int)
|
||||
@@ -457,7 +457,7 @@ public class JSONArray {
|
||||
* Gets the boolean value associated with the specified index.
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Gets the boolean value associated with the specified index.
|
||||
* @webBrief Gets the boolean value associated with the specified index
|
||||
* @param index must be between 0 and length() - 1
|
||||
* @return The truth.
|
||||
* @throws RuntimeException If there is no value for the index or if the
|
||||
@@ -503,7 +503,7 @@ public class JSONArray {
|
||||
* Retrieves the <b>JSONArray</b> with the associated index value.
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Retrieves the <b>JSONArray</b> with the associated index value.
|
||||
* @webBrief Retrieves the <b>JSONArray</b> with the associated index value
|
||||
* @param index must be between 0 and length() - 1
|
||||
* @return A JSONArray value.
|
||||
* @throws RuntimeException If there is no value for the index. or if the
|
||||
@@ -534,7 +534,7 @@ public class JSONArray {
|
||||
* Retrieves the <b>JSONObject</b> with the associated index value.
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Retrieves the <b>JSONObject</b> with the associated index value.
|
||||
* @webBrief Retrieves the <b>JSONObject</b> with the associated index value
|
||||
* @param index the index value of the object to get
|
||||
* @return A JSONObject value.
|
||||
* @throws RuntimeException If there is no value for the index or if the
|
||||
@@ -562,11 +562,11 @@ public class JSONArray {
|
||||
|
||||
|
||||
/**
|
||||
* Returns the entire <b>JSONArray</b> as an array of Strings.
|
||||
* (All values in the array must be of the String type.)
|
||||
* Returns the entire <b>JSONArray</b> as an array of <b>Strings</b>.
|
||||
* (All values in the array must be of the <b>String</b> type.)
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Returns the entire <b>JSONArray</b> as an array of Strings
|
||||
* @webBrief Returns the entire <b>JSONArray</b> as an array of <b>Strings</b>
|
||||
* @see JSONArray#getIntArray()
|
||||
*/
|
||||
public String[] getStringArray() {
|
||||
@@ -579,11 +579,11 @@ public class JSONArray {
|
||||
|
||||
|
||||
/**
|
||||
* Returns the entire <b>JSONArray</b> as an array of ints.
|
||||
* Returns the entire <b>JSONArray</b> as an array of <b>ints</b>.
|
||||
* (All values in the array must be of the int type.)
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Returns the entire <b>JSONArray</b> as an array of ints
|
||||
* @webBrief Returns the entire <b>JSONArray</b> as an array of <b>ints</b>
|
||||
* @see JSONArray#getStringArray()
|
||||
*/
|
||||
public int[] getIntArray() {
|
||||
@@ -702,8 +702,8 @@ public class JSONArray {
|
||||
|
||||
/**
|
||||
* Appends a new value to the <b>JSONArray</b>, increasing the array's length
|
||||
* by one. New values may be of the following types: int, float, String,
|
||||
* boolean, <b>JSONObject</b>, or <b>JSONArray</b>.
|
||||
* by one. New values may be of the following types: <b>int</b>, <b>float</b>, <b>String</b>,
|
||||
* <b>boolean</b>, <b>JSONObject</b>, or <b>JSONArray</b>.
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Appends a value, increasing the array's length by one
|
||||
@@ -862,7 +862,7 @@ public class JSONArray {
|
||||
* necessary to pad it out.
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
* @webBrief Inserts a new value into the <b>JSONArray</b> at the specified index position.
|
||||
* @webBrief Inserts a new value into the <b>JSONArray</b> at the specified index position
|
||||
* @param index an index value
|
||||
* @param value the value to assign
|
||||
* @return this.
|
||||
@@ -1080,7 +1080,7 @@ public class JSONArray {
|
||||
|
||||
/**
|
||||
* Removes the element from a <b>JSONArray</b> in the specified index position.
|
||||
* Returns either the value associated with the given index, or null, if there
|
||||
* Returns either the value associated with the given index, or <b>null</b>, if there
|
||||
* is no value.
|
||||
*
|
||||
* @webref jsonarray:method
|
||||
|
||||
@@ -52,7 +52,7 @@ import processing.core.PApplet;
|
||||
|
||||
/**
|
||||
* A <b>JSONObject</b> stores JSON data with multiple name/value pairs. Values
|
||||
* can be numeric, Strings, booleans, other <b>JSONObject</b>s or
|
||||
* can be numeric, <b>Strings</b>, <b>booleans</b>, other <b>JSONObject</b>s or
|
||||
* <b>JSONArray</b>s, or null. <b>JSONObject</b> and <b>JSONArray</b> objects
|
||||
* are quite similar and share most of the same methods; the primary difference
|
||||
* is that the latter stores an array of JSON objects, while the former
|
||||
@@ -116,7 +116,7 @@ import processing.core.PApplet;
|
||||
* @author JSON.org
|
||||
* @version 2012-12-01
|
||||
* @webref data:composite
|
||||
* @webBrief A JSONObject is an unordered collection of name/value pairs.
|
||||
* @webBrief A <b>JSONObject</b> is an unordered collection of name/value pairs
|
||||
* @see JSONArray
|
||||
* @see PApplet#loadJSONObject(String)
|
||||
* @see PApplet#loadJSONArray(String)
|
||||
@@ -567,10 +567,10 @@ public class JSONObject {
|
||||
|
||||
|
||||
/**
|
||||
* Gets the String value associated with the specified key.
|
||||
* Gets the <b>String</b> value associated with the specified key.
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Gets the String value associated with the specified key
|
||||
* @webBrief Gets the <b>String</b> value associated with the specified key
|
||||
* @param key a key string
|
||||
* @return A string which is the value.
|
||||
* @throws RuntimeException if there is no string value for the key.
|
||||
@@ -606,10 +606,10 @@ public class JSONObject {
|
||||
|
||||
|
||||
/**
|
||||
* Gets the int value associated with the specified key.
|
||||
* Gets the <b>int</b> value associated with the specified key.
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Gets the int value associated with the specified key
|
||||
* @webBrief Gets the <b>int</b> value associated with the specified key
|
||||
* @param key A key string.
|
||||
* @return The integer value.
|
||||
* @throws RuntimeException if the key is not found or if the value cannot
|
||||
@@ -691,10 +691,10 @@ public class JSONObject {
|
||||
|
||||
|
||||
/**
|
||||
* Gets the float value associated with the specified key
|
||||
* Gets the <b>float</b> value associated with the specified key
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Gets the float value associated with a key
|
||||
* @webBrief Gets the <b>float</b> value associated with a key
|
||||
* @param key a key string
|
||||
* @see JSONObject#getInt(String)
|
||||
* @see JSONObject#getString(String)
|
||||
@@ -753,10 +753,10 @@ public class JSONObject {
|
||||
|
||||
|
||||
/**
|
||||
* Gets the boolean value associated with the specified key.
|
||||
* Gets the <b>boolean</b> value associated with the specified key.
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Gets the boolean value associated with the specified key
|
||||
* @webBrief Gets the <b>boolean</b> value associated with the specified key
|
||||
* @param key a key string
|
||||
* @return The truth.
|
||||
* @throws RuntimeException if the value is not a Boolean or the String "true" or "false".
|
||||
@@ -933,7 +933,7 @@ public class JSONObject {
|
||||
*
|
||||
* @webref
|
||||
* @webBrief Determines if the value associated with the key is <b>null</b>, that is has
|
||||
* no defined value (<b>false</b>) or if it has a value (<b>true</b>).
|
||||
* no defined value (<b>false</b>) or if it has a value (<b>true</b>)
|
||||
* @param key A key string.
|
||||
* @return true if there is no value associated with the key or if
|
||||
* the value is the JSONObject.NULL object.
|
||||
@@ -1227,7 +1227,7 @@ public class JSONObject {
|
||||
* the specified key already exists, assigns a new value.
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Put a key/float pair in the JSONObject
|
||||
* @webBrief Put a key/float pair in the <b>JSONObject</b>
|
||||
* @param key a key string
|
||||
* @param value the value to assign
|
||||
* @throws RuntimeException If the key is null or if the number is NaN or infinite.
|
||||
@@ -1260,7 +1260,7 @@ public class JSONObject {
|
||||
* with the specified key already exists, assigns a new value.
|
||||
*
|
||||
* @webref jsonobject:method
|
||||
* @webBrief Put a key/boolean pair in the JSONObject
|
||||
* @webBrief Put a key/boolean pair in the <b>JSONObject</b>
|
||||
* @param key a key string
|
||||
* @param value the value to assign
|
||||
* @return this.
|
||||
|
||||
@@ -710,7 +710,7 @@ public class LongList implements Iterable<Long> {
|
||||
|
||||
/**
|
||||
* Randomize the order of the list elements. Note that this does not
|
||||
* obey the randomSeed() function in PApplet.
|
||||
* obey the <b>randomSeed()</b> function in PApplet.
|
||||
*
|
||||
* @webref intlist:method
|
||||
* @webBrief Randomize the order of the list elements
|
||||
|
||||
@@ -9,11 +9,11 @@ import processing.core.PApplet;
|
||||
|
||||
|
||||
/**
|
||||
* A simple class to use a String as a lookup for an String value. String "keys"
|
||||
* are associated with String values.
|
||||
* A simple class to use a <b>String</b> as a lookup for a <b>String</b> value. String "keys"
|
||||
* are associated with <b>String</b> values.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief A simple class to use a String as a lookup for an String value
|
||||
* @webBrief A simple class to use a <b>String</b> as a lookup for an <b>String</b> value
|
||||
* @see IntDict
|
||||
* @see FloatDict
|
||||
*/
|
||||
|
||||
@@ -9,15 +9,15 @@ import java.util.Random;
|
||||
import processing.core.PApplet;
|
||||
|
||||
/**
|
||||
* Helper class for a list of Strings. Lists are designed to have some of the
|
||||
* features of ArrayLists, but to maintain the simplicity and efficiency of
|
||||
* Helper class for a list of <b>Strings</b>. Lists are designed to have some of the
|
||||
* features of <b>ArrayLists</b>, but to maintain the simplicity and efficiency of
|
||||
* working with arrays.
|
||||
*
|
||||
* Functions like sort() and shuffle() always act on the list itself. To get
|
||||
* a sorted copy, use list.copy().sort().
|
||||
* Functions like <b>sort()</b> and <b>shuffle()</b> always act on the list itself. To get
|
||||
* a sorted copy, use <b>list.copy().sort()</b>.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief Helper class for a list of Strings.
|
||||
* @webBrief Helper class for a list of Strings
|
||||
* @see IntList
|
||||
* @see FloatList
|
||||
*/
|
||||
@@ -149,7 +149,7 @@ public class StringList implements Iterable<String> {
|
||||
/**
|
||||
* Set the entry at a particular index. If the index is past the length of
|
||||
* the list, it'll expand the list to accommodate, and fill the intermediate
|
||||
* entries with "null".
|
||||
* entries with <b>null</b>.
|
||||
*
|
||||
* @webref stringlist:method
|
||||
* @webBrief Set an entry at a particular index
|
||||
|
||||
@@ -76,7 +76,7 @@ import processing.core.PConstants;
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief Generic class for handling tabular data, typically from a CSV, TSV,
|
||||
* or other sort of spreadsheet file.
|
||||
* or other sort of spreadsheet file
|
||||
* @see PApplet#loadTable(String)
|
||||
* @see PApplet#saveTable(Table, String)
|
||||
* @see TableRow
|
||||
@@ -1806,9 +1806,9 @@ public class Table {
|
||||
* Use <b>addColumn()</b> to add a new column to a <b>Table</b> object.
|
||||
* Typically, you will want to specify a title, so the column may be easily
|
||||
* referenced later by name. (If no title is specified, the new column's title
|
||||
* will be null.) A column type may also be specified, in which case all values
|
||||
* stored in this column must be of the same type (e.g., Table.INT or
|
||||
* Table.FLOAT). If no type is specified, the default type of STRING is used.
|
||||
* will be <b>null</b>.) A column type may also be specified, in which case all values
|
||||
* stored in this column must be of the same type (e.g., <b>Table.INT</b> or
|
||||
* <b>Table.FLOAT</b>). If no type is specified, the default type of <b>STRING</b> is used.
|
||||
*
|
||||
* @webref table:method
|
||||
* @webBrief Adds a new column to a table
|
||||
@@ -1886,7 +1886,7 @@ public class Table {
|
||||
/**
|
||||
* Use <b>removeColumn()</b> to remove an existing column from a <b>Table</b>
|
||||
* object. The column to be removed may be identified by either its title (a
|
||||
* String) or its index value (an int). <b>removeColumn(0)</b> would remove the
|
||||
* <b>String</b>) or its index value (an <b>int</b>). <b>removeColumn(0)</b> would remove the
|
||||
* first column, <b>removeColumn(1)</b> would remove the second column, and so
|
||||
* on.
|
||||
*
|
||||
@@ -2285,10 +2285,10 @@ public class Table {
|
||||
// . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
|
||||
|
||||
/**
|
||||
* Returns the total number of rows in a table.
|
||||
* Returns the total number of rows in a <b>Table</b>.
|
||||
*
|
||||
* @webref table:method
|
||||
* @webBrief Returns the total number of rows in a table
|
||||
* @webBrief Returns the total number of rows in a <b>Table</b>
|
||||
* @see Table#getColumnCount()
|
||||
*/
|
||||
public int getRowCount() {
|
||||
@@ -3609,7 +3609,7 @@ public class Table {
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves all values in the specified column, and returns them as a String
|
||||
* Retrieves all values in the specified column, and returns them as a <b>String</b>
|
||||
* array. The column may be specified by either its ID or title.
|
||||
*
|
||||
* @webref table:method
|
||||
|
||||
@@ -4,13 +4,13 @@ import java.io.PrintWriter;
|
||||
|
||||
/**
|
||||
* A <b>TableRow</b> object represents a single row of data values,
|
||||
* stored in columns, from a table.<br />
|
||||
* stored in columns, from a <b>Table</b>.<br />
|
||||
* <br />
|
||||
* Additional <b>TableRow</b> methods are documented in the
|
||||
* <a href="http://processing.github.io/processing-javadocs/core/">Processing Data Javadoc</a>.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief represents a single row of data values, stored in columns, from a table.
|
||||
* @webBrief Represents a single row of data values, stored in columns, from a <b>Table<b>
|
||||
* @see Table
|
||||
* @see Table#addRow()
|
||||
* @see Table#removeRow(int)
|
||||
@@ -25,7 +25,7 @@ public interface TableRow {
|
||||
* The column may be specified by either its ID or title.
|
||||
*
|
||||
* @webref tablerow:method
|
||||
* @webBrief Get an String value from the specified column
|
||||
* @webBrief Get a <b>String</b> value from the specified column
|
||||
* @param column ID number of the column to reference
|
||||
* @see TableRow#getInt(int)
|
||||
* @see TableRow#getFloat(int)
|
||||
@@ -42,7 +42,7 @@ public interface TableRow {
|
||||
* The column may be specified by either its ID or title.
|
||||
*
|
||||
* @webref tablerow:method
|
||||
* @webBrief Get an integer value from the specified column
|
||||
* @webBrief Get an <b>integer</b> value from the specified column
|
||||
* @param column ID number of the column to reference
|
||||
* @see TableRow#getFloat(int)
|
||||
* @see TableRow#getString(int)
|
||||
@@ -55,7 +55,7 @@ public interface TableRow {
|
||||
public int getInt(String columnName);
|
||||
|
||||
/**
|
||||
* @webBrief Get a long value from the specified column
|
||||
* @webBrief Get a <b>long</b> value from the specified column
|
||||
* @param column ID number of the column to reference
|
||||
* @see TableRow#getFloat(int)
|
||||
* @see TableRow#getString(int)
|
||||
@@ -73,7 +73,7 @@ public interface TableRow {
|
||||
* The column may be specified by either its ID or title.
|
||||
*
|
||||
* @webref tablerow:method
|
||||
* @webBrief Get a float value from the specified column
|
||||
* @webBrief Get a <b>float</b> value from the specified column
|
||||
* @param column ID number of the column to reference
|
||||
* @see TableRow#getInt(int)
|
||||
* @see TableRow#getString(int)
|
||||
@@ -86,7 +86,7 @@ public interface TableRow {
|
||||
public float getFloat(String columnName);
|
||||
|
||||
/**
|
||||
* @webBrief Get a double value from the specified column
|
||||
* @webBrief Get a <b>double</b> value from the specified column
|
||||
* @param column ID number of the column to reference
|
||||
* @see TableRow#getInt(int)
|
||||
* @see TableRow#getString(int)
|
||||
@@ -99,11 +99,11 @@ public interface TableRow {
|
||||
public double getDouble(String columnName);
|
||||
|
||||
/**
|
||||
* Stores a String value in the <b>TableRow</b>'s specified column. The column
|
||||
* Stores a <b>String</b> value in the <b>TableRow</b>'s specified column. The column
|
||||
* may be specified by either its ID or title.
|
||||
*
|
||||
* @webref tablerow:method
|
||||
* @webBrief Store a String value in the specified column
|
||||
* @webBrief Store a <b>String</b> value in the specified column
|
||||
* @param column ID number of the target column
|
||||
* @param value value to assign
|
||||
* @see TableRow#setInt(int, int)
|
||||
@@ -116,11 +116,11 @@ public interface TableRow {
|
||||
public void setString(String columnName, String value);
|
||||
|
||||
/**
|
||||
* Stores an integer value in the <b>TableRow</b>'s specified column. The column
|
||||
* Stores an <b>integer</b> value in the <b>TableRow</b>'s specified column. The column
|
||||
* may be specified by either its ID or title.
|
||||
*
|
||||
* @webref tablerow:method
|
||||
* @webBrief Store an integer value in the specified column
|
||||
* @webBrief Store an <b>integer</b> value in the specified column
|
||||
* @param column ID number of the target column
|
||||
* @param value value to assign
|
||||
* @see TableRow#setFloat(int, float)
|
||||
@@ -134,7 +134,7 @@ public interface TableRow {
|
||||
public void setInt(String columnName, int value);
|
||||
|
||||
/**
|
||||
* @webBrief Store a long value in the specified column
|
||||
* @webBrief Store a <b>long</b> value in the specified column
|
||||
* @param column ID number of the target column
|
||||
* @param value value to assign
|
||||
* @see TableRow#setFloat(int, float)
|
||||
@@ -148,11 +148,11 @@ public interface TableRow {
|
||||
public void setLong(String columnName, long value);
|
||||
|
||||
/**
|
||||
* Stores a float value in the <b>TableRow</b>'s specified column. The column
|
||||
* Stores a <b>float</b> value in the <b>TableRow</b>'s specified column. The column
|
||||
* may be specified by either its ID or title.
|
||||
*
|
||||
* @webref tablerow:method
|
||||
* @webBrief Store a float value in the specified column
|
||||
* @webBrief Store a <b>float</b> value in the specified column
|
||||
* @param column ID number of the target column
|
||||
* @param value value to assign
|
||||
* @see TableRow#setInt(int, int)
|
||||
@@ -166,7 +166,7 @@ public interface TableRow {
|
||||
public void setFloat(String columnName, float value);
|
||||
|
||||
/**
|
||||
* @webBrief Store a double value in the specified column
|
||||
* @webBrief Store a <b>double</b> value in the specified column
|
||||
* @param column ID number of the target column
|
||||
* @param value value to assign
|
||||
* @see TableRow#setFloat(int, float)
|
||||
@@ -183,13 +183,13 @@ public interface TableRow {
|
||||
* Returns the number of columns in a <b>TableRow</b>.
|
||||
*
|
||||
* @webref tablerow:method
|
||||
* @webBrief Get the column count.
|
||||
* @webBrief Get the column count
|
||||
* @return count of all columns
|
||||
*/
|
||||
public int getColumnCount();
|
||||
|
||||
/**
|
||||
* @webBrief Get the column type.
|
||||
* @webBrief Get the column type
|
||||
* @param columnName title of the target column
|
||||
* @return type of the column
|
||||
*/
|
||||
|
||||
@@ -41,16 +41,16 @@ import processing.core.PApplet;
|
||||
|
||||
|
||||
/**
|
||||
* <b>XML</b> is a representation of an XML object, able to parse XML code. Use
|
||||
* <b>XML</b> is a representation of an <b>XML</b> object, able to parse <b>XML</b> code. Use
|
||||
* <b>loadXML()</b> to load external XML files and create <b>XML</b>
|
||||
* objects.<br />
|
||||
* <br />
|
||||
* Only files encoded as UTF-8 (or plain ASCII) are parsed properly; the
|
||||
* encoding parameter inside XML files is ignored.
|
||||
* encoding parameter inside <b>XML</b> files is ignored.
|
||||
*
|
||||
* @webref data:composite
|
||||
* @webBrief This is the base class used for the Processing XML library,
|
||||
* representing a single node of an XML tree.
|
||||
* representing a single node of an <b>XML</b> tree
|
||||
* @see PApplet#loadXML(String)
|
||||
* @see PApplet#parseXML(String)
|
||||
* @see PApplet#saveXML(XML, String)
|
||||
@@ -253,10 +253,10 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Converts String content to an XML object
|
||||
* Converts <b>String</b> content to an <b>XML</b> object
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Converts String content to an XML object
|
||||
* @webBrief Converts <b>String</b> content to an <b>XML</b> object
|
||||
* @param data the content to be parsed as XML
|
||||
* @return an XML object, or null
|
||||
* @throws SAXException
|
||||
@@ -305,7 +305,7 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Gets a copy of the element's parent. Returns the parent as another XML object.
|
||||
* Gets a copy of the element's parent. Returns the parent as another <b>XML</b> object.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets a copy of the element's parent
|
||||
@@ -323,7 +323,7 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Gets the element's full name, which is returned as a String.
|
||||
* Gets the element's full name, which is returned as a <b>String</b>.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets the element's full name
|
||||
@@ -335,7 +335,7 @@ public class XML implements Serializable {
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the element's name, which is specified as a String.
|
||||
* Sets the element's name, which is specified as a <b>String</b>.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Sets the element's name
|
||||
@@ -388,7 +388,7 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Checks whether or not the element has any children, and returns the result as a boolean.
|
||||
* Checks whether or not the element has any children, and returns the result as a <b>boolean</b>.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Checks whether or not an element has any children
|
||||
@@ -401,7 +401,7 @@ public class XML implements Serializable {
|
||||
|
||||
/**
|
||||
* Get the names of all of the element's children, and returns the names as an
|
||||
* array of Strings. This is the same as looping through and calling getName()
|
||||
* array of <b>Strings</b>. This is the same as looping through and calling <b>getName()</b>
|
||||
* on each child element individually.
|
||||
*
|
||||
* @webref xml:method
|
||||
@@ -427,7 +427,7 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Returns all of the element's children as an array of XML objects. When
|
||||
* Returns all of the element's children as an array of <b>XML</b> objects. When
|
||||
* the <b>name</b> parameter is specified, then it will return all children
|
||||
* that match that name or path. The path is a series of elements and
|
||||
* sub-elements, separated by slashes.
|
||||
@@ -572,10 +572,10 @@ public class XML implements Serializable {
|
||||
|
||||
/**
|
||||
* Appends a new child to the element. The child can be specified with either a
|
||||
* String, which will be used as the new tag's name, or as a reference to an
|
||||
* existing XML object.<br />
|
||||
* <b>String</b>, which will be used as the new tag's name, or as a reference to an
|
||||
* existing <b>XML</b> object.<br />
|
||||
* <br />
|
||||
* A reference to the newly created child is returned as an XML object.
|
||||
* A reference to the newly created child is returned as an <b>XML</b> object.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Appends a new child to the element
|
||||
@@ -695,7 +695,7 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Counts the specified element's number of attributes, returned as an int.
|
||||
* Counts the specified element's number of attributes, returned as an <b>int</b>.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Counts the specified element's number of attributes
|
||||
@@ -706,7 +706,7 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Gets all of the specified element's attributes, and returns them as an array of Strings.
|
||||
* Gets all of the specified element's attributes, and returns them as an array of <b>Strings</b>.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Returns a list of names of all attributes as an array
|
||||
@@ -722,7 +722,7 @@ public class XML implements Serializable {
|
||||
|
||||
/**
|
||||
* Checks whether or not an element has the specified attribute. The attribute
|
||||
* must be specified as a String, and a boolean is returned.
|
||||
* must be specified as a <b>String</b>, and a <b>boolean</b> is returned.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Checks whether or not an element has the specified attribute
|
||||
@@ -757,13 +757,13 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Returns an attribute value of the element as a String. If the <b>defaultValue</b>
|
||||
* Returns an attribute value of the element as a <b>String</b>. If the <b>defaultValue</b>
|
||||
* parameter is specified and the attribute doesn't exist, then <b>defaultValue</b>
|
||||
* is returned. If no <b>defaultValue</b> is specified and the attribute doesn't
|
||||
* exist, null is returned.
|
||||
* exist, <b>null</b> is returned.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets the content of an attribute as a String
|
||||
* @webBrief Gets the content of an attribute as a <b>String</b>
|
||||
*/
|
||||
public String getString(String name) {
|
||||
return getString(name, null);
|
||||
@@ -783,11 +783,11 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Sets the content of an element's attribute as a String. The first String
|
||||
* Sets the content of an element's attribute as a <b>String</b>. The first <b>String</b>
|
||||
* specifies the attribute name, while the second specifies the new content.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Sets the content of an attribute as a String
|
||||
* @webBrief Sets the content of an attribute as a <b>String</b>
|
||||
*/
|
||||
public void setString(String name, String value) {
|
||||
((Element) node).setAttribute(name, value);
|
||||
@@ -795,13 +795,13 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Returns an attribute value of the element as an int. If the <b>defaultValue</b>
|
||||
* Returns an attribute value of the element as an <b>int</b>. If the <b>defaultValue</b>
|
||||
* parameter is specified and the attribute doesn't exist, then <b>defaultValue</b>
|
||||
* is returned. If no <b>defaultValue</b> is specified and the attribute doesn't
|
||||
* exist, the value 0 is returned.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets the content of an attribute as an int
|
||||
* @webBrief Gets the content of an attribute as an <b>int</b>
|
||||
*/
|
||||
public int getInt(String name) {
|
||||
return getInt(name, 0);
|
||||
@@ -809,11 +809,11 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Sets the content of an element's attribute as an int. A String specifies
|
||||
* Sets the content of an element's attribute as an <b>int</b>. A <b>String</b> specifies
|
||||
* the attribute name, while the int specifies the new content.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Sets the content of an attribute as an int
|
||||
* @webBrief Sets the content of an attribute as an <b>int</b>
|
||||
*/
|
||||
public void setInt(String name, int value) {
|
||||
setString(name, String.valueOf(value));
|
||||
@@ -834,10 +834,10 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Sets the content of an element as an int
|
||||
* Sets the content of an element as an <b>int</b>
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Sets the content of an element as an int
|
||||
* @webBrief Sets the content of an element as an <b>int</b>
|
||||
*/
|
||||
public void setLong(String name, long value) {
|
||||
setString(name, String.valueOf(value));
|
||||
@@ -864,7 +864,7 @@ public class XML implements Serializable {
|
||||
* and the attribute doesn't exist, the value 0.0 is returned.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets the content of an attribute as a float
|
||||
* @webBrief Gets the content of an attribute as a <b>float</b>
|
||||
*/
|
||||
public float getFloat(String name) {
|
||||
return getFloat(name, 0);
|
||||
@@ -885,11 +885,11 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Sets the content of an element's attribute as a float. A String specifies
|
||||
* the attribute name, while the float specifies the new content.
|
||||
* Sets the content of an element's attribute as a <b>float</b>. A <b>String</b> specifies
|
||||
* the attribute name, while the <b>float</b> specifies the new content.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Sets the content of an attribute as a float
|
||||
* @webBrief Sets the content of an attribute as a <b>float</b>
|
||||
*/
|
||||
public void setFloat(String name, float value) {
|
||||
setString(name, String.valueOf(value));
|
||||
@@ -941,11 +941,11 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Returns the content of an element as an int. If there is no such content,
|
||||
* Returns the content of an element as an <b>int</b>. If there is no such content,
|
||||
* either <b>null</b> or the provided default value is returned.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets the content of an element as an int
|
||||
* @webBrief Gets the content of an element as an <b>int</b>
|
||||
* @return the content.
|
||||
* @see XML#getContent()
|
||||
* @see XML#getFloatContent()
|
||||
@@ -964,11 +964,11 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Returns the content of an element as a float. If there is no such content,
|
||||
* Returns the content of an element as a <b>float</b>. If there is no such content,
|
||||
* either <b>null</b> or the provided default value is returned.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets the content of an element as a float
|
||||
* @webBrief Gets the content of an element as a <b>float</b>
|
||||
* @return the content.
|
||||
* @see XML#getContent()
|
||||
* @see XML#getIntContent()
|
||||
@@ -1019,7 +1019,7 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Sets the element's content, which is specified as a String.
|
||||
* Sets the element's content, which is specified as a <b>String</b>.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Sets the content of an element
|
||||
@@ -1050,19 +1050,19 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Takes an XML object and converts it to a String, formatting its content as
|
||||
* Takes an <b>XML</b> object and converts it to a <b>String</b>, formatting its content as
|
||||
* specified with the <b>indent</b> parameter.<br />
|
||||
* <br />
|
||||
* If indent is set to -1, then the String is returned with no line breaks, no
|
||||
* indentation, and no XML declaration.<br />
|
||||
* indentation, and no <b>XML</b> declaration.<br />
|
||||
* <br />
|
||||
* If indent is set to 0 or greater, then the String is returned with line
|
||||
* If indent is set to 0 or greater, then the <b>String</b> is returned with line
|
||||
* breaks, and the specified number of spaces as indent values. Meaning, there
|
||||
* will be no indentation if 0 is specified, or each indent will be replaced
|
||||
* with the corresponding number of spaces: 1, 2, 3, and so on.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Formats XML data as a String
|
||||
* @webBrief Formats <b>XML</b> data as a <b>String</b>
|
||||
* @param indent -1 for a single line (and no declaration), >= 0 for indents and
|
||||
* newlines
|
||||
* @return the content
|
||||
@@ -1204,13 +1204,13 @@ public class XML implements Serializable {
|
||||
|
||||
|
||||
/**
|
||||
* Takes an XML object and converts it to a String, using default formatting
|
||||
* Takes an <b>XML</b> object and converts it to a <b>String</b>, using default formatting
|
||||
* rules (includes an XML declaration, line breaks, and two spaces for indents).
|
||||
* These are the same formatting rules used by <b>println()</b> when printing an
|
||||
* XML object. This method produces the same results as using <b>format(2)</b>.
|
||||
* <b>XML</b> object. This method produces the same results as using <b>format(2)</b>.
|
||||
*
|
||||
* @webref xml:method
|
||||
* @webBrief Gets XML data as a String using default formatting
|
||||
* @webBrief Gets <b>XML</b> data as a <b>String</b> using default formatting
|
||||
* @return the content
|
||||
* @see XML#format(int)
|
||||
*/
|
||||
|
||||
@@ -37,12 +37,12 @@ import java.util.HashMap;
|
||||
* fragment shader. It's compatible with the P2D and P3D renderers, but not with
|
||||
* the default renderer. Use the <b>loadShader()</b> function to load your
|
||||
* shader code. [Note: It's strongly encouraged to use <b>loadShader()</b> to
|
||||
* create a PShader object, rather than calling the PShader constructor
|
||||
* create a <b>PShader</b> object, rather than calling the <b>PShader</b> constructor
|
||||
* manually.]
|
||||
*
|
||||
* @webref rendering:shaders
|
||||
* @webBrief This class encapsulates a GLSL shader program, including a vertex
|
||||
* and a fragment shader.
|
||||
* and a fragment shader
|
||||
*/
|
||||
public class PShader implements PConstants {
|
||||
static protected final int POINT = 0;
|
||||
|
||||
@@ -94,16 +94,16 @@ public class GPIO {
|
||||
/**
|
||||
* Calls a function when the value of an input pin changes<br/>
|
||||
* <br/>
|
||||
* The sketch method provided must accept a single integer (int) parameter, which is the
|
||||
* The sketch method provided must accept a single <b>integer</b> (int) parameter, which is the
|
||||
* number of the GPIO pin that the interrupt occured on. As this method might be called
|
||||
* at any time, including when drawing to the display window isn't permitted, it is best
|
||||
* to only set simple variables that are being responded to in the next draw() call, as
|
||||
* to only set simple variables that are being responded to in the next <b>draw()</b> call, as
|
||||
* shown above. Calling functions of the Hardware I/O library at this point is certainly
|
||||
* possible.<br/>
|
||||
* <br/>
|
||||
* The mode parameter determines when the function will be called: GPIO.FALLING occurs
|
||||
* when the level changes from high to low, GPIO.RISING when the level changes from low
|
||||
* to high, and GPIO.CHANGE when either occurs.
|
||||
* The mode parameter determines when the function will be called: <b>GPIO.FALLING</b> occurs
|
||||
* when the level changes from high to low, <b>GPIO.RISING</b> when the level changes from low
|
||||
* to high, and <b>GPIO.CHANGE</b> when either occurs.
|
||||
*
|
||||
* @param pin GPIO pin
|
||||
* @param parent typically use "this"
|
||||
@@ -333,7 +333,7 @@ public class GPIO {
|
||||
* Allows interrupts to happen<br/>
|
||||
* <br/>
|
||||
* You can use <a href="GPIO_noInterrupts_.html">noInterrupts()</a>
|
||||
* and interrupts() in tandem to make sure no interrupts are occuring
|
||||
* and <b>interrupts()</b> in tandem to make sure no interrupts are occuring
|
||||
* while your sketch is doing a particular task. By default, interrupts
|
||||
* are enabled.
|
||||
*
|
||||
@@ -351,7 +351,7 @@ public class GPIO {
|
||||
/**
|
||||
* Prevents interrupts from happpening<br/>
|
||||
* <br/>
|
||||
* You can use noInterrupts() and <a href="GPIO_interrupts_.html">interrupts()</a>
|
||||
* You can use <b>noInterrupts()</b> and <a href="GPIO_interrupts_.html">interrupts()</a>
|
||||
* in tandem to make sure no interrupts are occuring while your sketch is doing a
|
||||
* particular task.<br/>
|
||||
* br/>
|
||||
@@ -529,9 +529,9 @@ public class GPIO {
|
||||
/**
|
||||
* Waits for the value of an input pin to change<br/>
|
||||
* <br/>
|
||||
* The mode parameter determines when the function will return: GPIO.FALLING occurs
|
||||
* when the level changes from high to low, GPIO.RISING when the level changes from
|
||||
* low to high, and GPIO.CHANGE when either occurs.<br/>
|
||||
* The mode parameter determines when the function will return: <b>GPIO.FALLING</b> occurs
|
||||
* when the level changes from high to low, <b>GPIO.RISING</b> when the level changes from
|
||||
* low to high, and <b>GPIO.CHANGE</b> when either occurs.<br/>
|
||||
* <br/>
|
||||
* The optional timeout parameter determines how many milliseconds the function will
|
||||
* wait at the most. If the value of the input pin hasn't changed at this point, an
|
||||
@@ -550,9 +550,9 @@ public class GPIO {
|
||||
/**
|
||||
* Waits for the value of an input pin to change<br/>
|
||||
* <br/>
|
||||
* The mode parameter determines when the function will return: GPIO.FALLING occurs
|
||||
* when the level changes from high to low, GPIO.RISING when the level changes from
|
||||
* low to high, and GPIO.CHANGE when either occurs.<br/>
|
||||
* The mode parameter determines when the function will return: <b>GPIO.FALLING</b> occurs
|
||||
* when the level changes from high to low, <b>GPIO.RISING</b> when the level changes from
|
||||
* low to high, and <b>GPIO.CHANGE</b> when either occurs.<br/>
|
||||
* <br/>
|
||||
* The optional timeout parameter determines how many milliseconds the function will
|
||||
* wait at the most. If the value of the input pin hasn't changed at this point, an
|
||||
|
||||
@@ -124,7 +124,7 @@ public class I2C {
|
||||
* time.
|
||||
*
|
||||
* @webref I2C
|
||||
* @webBrief Closes the I2C device.
|
||||
* @webBrief Closes the I2C device
|
||||
*/
|
||||
public void close() {
|
||||
if (NativeInterface.isSimulated()) {
|
||||
@@ -150,12 +150,12 @@ public class I2C {
|
||||
* <br/>
|
||||
* This executes any queued writes. <a href="I2C_read_.html">Read()</a>
|
||||
* implicitly ends the current transmission as well, hence calling
|
||||
* endTransmission() afterwards is not necessary.
|
||||
* <b>endTransmission()</b> afterwards is not necessary.
|
||||
*
|
||||
* @see beginTransmission
|
||||
* @see write
|
||||
* @webref I2C
|
||||
* @webBrief Ends the current transmissions.
|
||||
* @webBrief Ends the current transmissions
|
||||
*/
|
||||
public void endTransmission() {
|
||||
if (!transmitting) {
|
||||
@@ -212,10 +212,10 @@ public class I2C {
|
||||
/**
|
||||
* Read bytes from the attached device<br/>
|
||||
* <br/>
|
||||
* You must call beginTransmission() before calling this function. This function
|
||||
* You must call <b>beginTransmission()</b> before calling this function. This function
|
||||
* also ends the current transmission and sends any data that was queued using
|
||||
* write() before. It is not necessary to call
|
||||
* <a href="I2C_endTransmission_.html">endTransmission()</a> after read().
|
||||
* <b>write()</b> before. It is not necessary to call
|
||||
* <a href="I2C_endTransmission_.html">endTransmission()</a> after <b>read()</b>.
|
||||
*
|
||||
* @param len number of bytes to read
|
||||
* @return bytes read from device
|
||||
@@ -223,7 +223,7 @@ public class I2C {
|
||||
* @see write
|
||||
* @see endTransmission
|
||||
* @webref I2C
|
||||
* @webBrief Read bytes from the attached device.
|
||||
* @webBrief Read bytes from the attached device
|
||||
*/
|
||||
public byte[] read(int len) {
|
||||
if (!transmitting) {
|
||||
@@ -253,15 +253,15 @@ public class I2C {
|
||||
/**
|
||||
* Add bytes to be written to the device<br/>
|
||||
* <br/>
|
||||
* You must call beginTransmission() before calling this function. The actual
|
||||
* writing takes part when read() or endTransmission() is being called.
|
||||
* You must call <b>beginTransmission()</b> before calling this function. The actual
|
||||
* writing takes part when <b>read()</b> or <b>endTransmission()</b> is being called.
|
||||
*
|
||||
* @param out bytes to be written
|
||||
* @see beginTransmission
|
||||
* @see read
|
||||
* @see endTransmission
|
||||
* @webref I2C
|
||||
* @webBrief Add bytes to be written to the device.
|
||||
* @webBrief Add bytes to be written to the device
|
||||
*/
|
||||
public void write(byte[] out) {
|
||||
if (!transmitting) {
|
||||
|
||||
@@ -83,10 +83,10 @@ public class SoftwareServo {
|
||||
/**
|
||||
* Attaches a servo motor to a GPIO pin<br/>
|
||||
* <br/>
|
||||
* You must call this function before calling write(). Note that the servo motor
|
||||
* will only be instructed to move after the first time write() is called.<br/>
|
||||
* You must call this function before calling <b>write()</b>. Note that the servo motor
|
||||
* will only be instructed to move after the first time <b>write()</b> is called.<br/>
|
||||
* <br/>
|
||||
* The optional parameters minPulse and maxPulse control the minimum and maximum
|
||||
* The optional parameters <b>minPulse</b> and <b>maxPulse</b> control the minimum and maximum
|
||||
* pulse width durations. The default values, identical to those of Arduino's
|
||||
* Servo class, should be compatible with most servo motors.
|
||||
*
|
||||
@@ -105,8 +105,8 @@ public class SoftwareServo {
|
||||
/**
|
||||
* Attaches a servo motor to a GPIO pin<br/>
|
||||
* <br/>
|
||||
* You must call this function before calling write(). Note that the servo motor
|
||||
* will only be instructed to move after the first time write() is called.<br/>
|
||||
* You must call this function before calling <b>write()</b>. Note that the servo motor
|
||||
* will only be instructed to move after the first time <b>write()</b> is called.<br/>
|
||||
* <br/>
|
||||
* The optional parameters minPulse and maxPulse control the minimum and maximum
|
||||
* pulse width durations. The default values, identical to those of Arduino's
|
||||
|
||||
@@ -37,7 +37,7 @@ import java.net.*;
|
||||
* listening on a different port, an exception is thrown.
|
||||
*
|
||||
* @webref client
|
||||
* @webBrief The client class is used to create client Objects which connect to a server to exchange data.
|
||||
* @webBrief The client class is used to create client Objects which connect to a server to exchange data
|
||||
* @instanceName client any variable of type Client
|
||||
* @usage Application
|
||||
* @see_external LIB_net/clientEvent
|
||||
@@ -321,7 +321,7 @@ public class Client implements Runnable {
|
||||
*
|
||||
* @webref client
|
||||
* @usage application
|
||||
* @webBrief Returns the IP address of the machine as a String
|
||||
* @webBrief Returns the IP address of the machine as a <b>String</b>
|
||||
*/
|
||||
public String ip() {
|
||||
if (socket != null){
|
||||
@@ -422,7 +422,7 @@ public class Client implements Runnable {
|
||||
*
|
||||
* @webref client
|
||||
* @usage application
|
||||
* @webBrief Reads a group of bytes from the buffer.
|
||||
* @webBrief Reads a group of bytes from the buffer
|
||||
*/
|
||||
public byte[] readBytes() {
|
||||
synchronized (bufferLock) {
|
||||
@@ -596,7 +596,7 @@ public class Client implements Runnable {
|
||||
|
||||
/**
|
||||
*
|
||||
* Returns the all the data from the buffer as a String. This method
|
||||
* Returns the all the data from the buffer as a <b>String</b>. This method
|
||||
* assumes the incoming characters are ASCII. If you want to transfer
|
||||
* Unicode data, first convert the String to a byte stream in the
|
||||
* representation of your choice (i.e. UTF8 or two-byte Unicode data), and
|
||||
@@ -604,7 +604,7 @@ public class Client implements Runnable {
|
||||
*
|
||||
* @webref client
|
||||
* @usage application
|
||||
* @webBrief Returns the buffer as a String
|
||||
* @webBrief Returns the buffer as a <b>String</b>
|
||||
*/
|
||||
public String readString() {
|
||||
byte b[] = readBytes();
|
||||
@@ -626,7 +626,7 @@ public class Client implements Runnable {
|
||||
*
|
||||
* @webref client
|
||||
* @usage application
|
||||
* @webBrief Returns the buffer as a String up to and including a particular character
|
||||
* @webBrief Returns the buffer as a <b>String</b> up to and including a particular character
|
||||
* @param interesting character designated to mark the end of the data
|
||||
*/
|
||||
public String readStringUntil(int interesting) {
|
||||
@@ -644,7 +644,7 @@ public class Client implements Runnable {
|
||||
*
|
||||
* @webref client
|
||||
* @usage application
|
||||
* @webBrief Writes bytes, chars, ints, bytes[], Strings
|
||||
* @webBrief Writes <b>bytes</b>, <b>chars</b>, <b>ints</b>, <b>bytes[]</b>, <b>Strings</b>
|
||||
* @param data data to write
|
||||
*/
|
||||
public void write(int data) { // will also cover char
|
||||
|
||||
@@ -44,7 +44,7 @@ import java.net.*;
|
||||
* @webref server
|
||||
* @usage application
|
||||
* @webBrief The server class is used to create server objects which send
|
||||
* and receives data to and from its associated clients (other programs connected to it).
|
||||
* and receives data to and from its associated clients (other programs connected to it)
|
||||
* @instanceName server any variable of type Server
|
||||
*/
|
||||
public class Server implements Runnable {
|
||||
@@ -118,7 +118,7 @@ public class Server implements Runnable {
|
||||
* Disconnect a particular client.
|
||||
*
|
||||
* @webref server
|
||||
* @webBrief Disconnect a particular client.
|
||||
* @webBrief Disconnect a particular client
|
||||
* @param client the client to disconnect
|
||||
*/
|
||||
public void disconnect(Client client) {
|
||||
@@ -188,7 +188,7 @@ public class Server implements Runnable {
|
||||
* into any trouble.
|
||||
*
|
||||
* @webref server
|
||||
* @webBrief Return true if this server is still active.
|
||||
* @webBrief Return <b>true</b> if this server is still active
|
||||
*/
|
||||
public boolean active() {
|
||||
return thread != null;
|
||||
@@ -215,7 +215,7 @@ public class Server implements Runnable {
|
||||
* Returns the next client in line with a new message.
|
||||
*
|
||||
* @webref server
|
||||
* @webBrief Returns the next client in line with a new message.
|
||||
* @webBrief Returns the next client in line with a new message
|
||||
* @usage application
|
||||
*/
|
||||
public Client available() {
|
||||
@@ -255,7 +255,7 @@ public class Server implements Runnable {
|
||||
* is still running. Otherwise, it will be automatically be shut down by the
|
||||
* host PApplet using dispose(), which is identical.
|
||||
* @webref server
|
||||
* @webBrief Disconnects all clients and stops the server.
|
||||
* @webBrief Disconnects all clients and stops the server
|
||||
* @usage application
|
||||
*/
|
||||
public void stop() {
|
||||
|
||||
@@ -38,7 +38,7 @@ import jssc.*;
|
||||
* Class for sending and receiving data using the serial communication protocol.
|
||||
*
|
||||
* @webref serial
|
||||
* @webBrief Class for sending and receiving data using the serial communication protocol.
|
||||
* @webBrief Class for sending and receiving data using the serial communication protocol
|
||||
* @instanceName serial any variable of type Serial
|
||||
* @usage Application
|
||||
* @see_external LIB_serial/serialEvent
|
||||
@@ -189,7 +189,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_available.xml
|
||||
* @webref serial
|
||||
* @webBrief Returns the number of bytes available.
|
||||
* @webBrief Returns the number of bytes available
|
||||
* @usage web_application
|
||||
*/
|
||||
public int available() {
|
||||
@@ -198,10 +198,10 @@ public class Serial implements SerialPortEventListener {
|
||||
|
||||
|
||||
/**
|
||||
* Sets the number of bytes to buffer before calling serialEvent()
|
||||
* Sets the number of bytes to buffer before calling <b>serialEvent()</b>
|
||||
* @generate Serial_buffer.xml
|
||||
* @webref serial
|
||||
* @webBrief Sets the number of bytes to buffer before calling serialEvent()
|
||||
* @webBrief Sets the number of bytes to buffer before calling <b>serialEvent()</b>
|
||||
* @usage web_application
|
||||
* @param size number of bytes to buffer
|
||||
*/
|
||||
@@ -215,7 +215,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_bufferUntil.xml
|
||||
* @webref serial
|
||||
* @webBrief Sets a specific byte to buffer until before calling <b>serialEvent()</b>.
|
||||
* @webBrief Sets a specific byte to buffer until before calling <b>serialEvent()</b>
|
||||
* @usage web_application
|
||||
* @param inByte the value to buffer until
|
||||
*/
|
||||
@@ -230,7 +230,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_clear.xml
|
||||
* @webref serial
|
||||
* @webBrief Empty the buffer, removes all the data stored there.
|
||||
* @webBrief Empty the buffer, removes all the data stored there
|
||||
* @usage web_application
|
||||
*/
|
||||
public void clear() {
|
||||
@@ -273,7 +273,7 @@ public class Serial implements SerialPortEventListener {
|
||||
* and clears the buffer. Useful when you just want the most
|
||||
* recent value sent over the port.
|
||||
* @webref serial
|
||||
* @webBrief Returns last byte received or -1 if there is none available.
|
||||
* @webBrief Returns last byte received or -1 if there is none available
|
||||
* @usage web_application
|
||||
*/
|
||||
public int last() {
|
||||
@@ -295,7 +295,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_lastChar.xml
|
||||
* @webref serial
|
||||
* @webBrief Returns the last byte received as a char or -1 if there is none available.
|
||||
* @webBrief Returns the last byte received as a char or -1 if there is none available
|
||||
* @usage web_application
|
||||
*/
|
||||
public char lastChar() {
|
||||
@@ -309,7 +309,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_list.xml
|
||||
* @webref serial
|
||||
* @webBrief Gets a list of all available serial ports.
|
||||
* @webBrief Gets a list of all available serial ports
|
||||
* @usage web_application
|
||||
*/
|
||||
public static String[] list() {
|
||||
@@ -326,7 +326,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_read.xml
|
||||
* @webref serial
|
||||
* @webBrief Returns a number between 0 and 255 for the next byte that's waiting in the buffer.
|
||||
* @webBrief Returns a number between 0 and 255 for the next byte that's waiting in the buffer
|
||||
* @usage web_application
|
||||
*/
|
||||
public int read() {
|
||||
@@ -354,7 +354,7 @@ public class Serial implements SerialPortEventListener {
|
||||
* <b>byteBuffer</b>, only those that fit are read.
|
||||
* @generate Serial_readBytes.xml
|
||||
* @webref serial
|
||||
* @webBrief Reads a group of bytes from the buffer or <b>null</b> if there are none available.
|
||||
* @webBrief Reads a group of bytes from the buffer or <b>null</b> if there are none available
|
||||
* @usage web_application
|
||||
*/
|
||||
public byte[] readBytes() {
|
||||
@@ -446,7 +446,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_readBytesUntil.xml
|
||||
* @webref serial
|
||||
* @webBrief Reads from the port into a buffer of bytes up to and including a particular character.
|
||||
* @webBrief Reads from the port into a buffer of bytes up to and including a particular character
|
||||
* @usage web_application
|
||||
* @param inByte character designated to mark the end of the data
|
||||
*/
|
||||
@@ -532,7 +532,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_readChar.xml
|
||||
* @webref serial
|
||||
* @webBrief Returns the next byte in the buffer as a char.
|
||||
* @webBrief Returns the next byte in the buffer as a char
|
||||
* @usage web_application
|
||||
*/
|
||||
public char readChar() {
|
||||
@@ -541,14 +541,14 @@ public class Serial implements SerialPortEventListener {
|
||||
|
||||
|
||||
/**
|
||||
* Returns all the data from the buffer as a String or <b>null</b> if there is nothing available.
|
||||
* Returns all the data from the buffer as a <b>String</b> or <b>null</b> if there is nothing available.
|
||||
* This method assumes the incoming characters are ASCII. If you want to transfer Unicode data,
|
||||
* first convert the String to a byte stream in the representation of your choice (i.e. UTF8 or
|
||||
* two-byte Unicode data), and send it as a byte array.
|
||||
*
|
||||
* @generate Serial_readString.xml
|
||||
* @webref serial
|
||||
* @webBrief Returns all the data from the buffer as a String or <b>null</b> if there is nothing available.
|
||||
* @webBrief Returns all the data from the buffer as a <b>String</b> or <b>null</b> if there is nothing available
|
||||
* @usage web_application
|
||||
*/
|
||||
public String readString() {
|
||||
@@ -570,7 +570,7 @@ public class Serial implements SerialPortEventListener {
|
||||
* (i.e. UTF8 or two-byte Unicode data), and send it as a byte array.
|
||||
*
|
||||
* @webref serial
|
||||
* @webBrief Combination of <b>readBytesUntil()</b> and <b>readString()</b>.
|
||||
* @webBrief Combination of <b>readBytesUntil()</b> and <b>readString()</b>
|
||||
* @usage web_application
|
||||
* @param inByte character designated to mark the end of the data
|
||||
*/
|
||||
@@ -594,7 +594,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate serialEvent.xml
|
||||
* @webref serial_event
|
||||
* @webBrief Called when data is available.
|
||||
* @webBrief Called when data is available
|
||||
* @usage web_application
|
||||
* @param event the port where new data is available
|
||||
*/
|
||||
@@ -679,7 +679,7 @@ public class Serial implements SerialPortEventListener {
|
||||
*
|
||||
* @generate Serial_stop.xml
|
||||
* @webref serial
|
||||
* @webBrief Stops data communication on this port.
|
||||
* @webBrief Stops data communication on this port
|
||||
* @usage web_application
|
||||
*/
|
||||
public void stop() {
|
||||
@@ -722,7 +722,7 @@ public class Serial implements SerialPortEventListener {
|
||||
|
||||
|
||||
/**
|
||||
* Writes bytes, chars, ints, bytes[], Strings to the serial port
|
||||
* Writes <b>bytes</b>, <b>chars</b>, <b>ints</b>, <b>bytes[]</b>, <b>Strings</b> to the serial port
|
||||
*
|
||||
* <h3>Advanced</h3>
|
||||
* Write a String to the output. Note that this doesn't account
|
||||
@@ -737,7 +737,7 @@ public class Serial implements SerialPortEventListener {
|
||||
* (i.e. UTF8 or two-byte Unicode data), and send it as a byte array.
|
||||
*
|
||||
* @webref serial
|
||||
* @webBrief Writes bytes, chars, ints, bytes[], Strings to the serial port
|
||||
* @webBrief Writes <b>bytes</b>, <b>chars</b>, <b>ints</b>, <b>bytes[]</b>, <b>Strings</b> to the serial port
|
||||
* @usage web_application
|
||||
* @param src data to write
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user