. (dot) \ Language (API) \ Processing 1.0
Search processing.org:
Language (A-Z) \
Libraries \
Tools \
Environment \
Compare \
Troubleshooting
Reference for Processing version 1.0+. If you have a previous version, use the reference included with your software. If you see any errors or have any comments, let us know.
Name
. (dot)
Examples
// Declare and contruct two objects (h1, h2) from the class HLine
HLine h1 = new HLine(20, 1.0);
HLine h2 = new HLine(50, 5.0);
void setup() {
size(200, 200);
}
void draw() {
if(h2.speed > 1.0) {
h2.speed -= 0.01;
}
h1.update();
h2.update();
}
class HLine {
float ypos, speed;
HLine (float y, float s) {
ypos = y;
speed = s;
}
void update() {
ypos += speed;
if (ypos > width) {
ypos = 0;
}
line(0, ypos, width, ypos);
}
}
Description
Provides access to an object's methods and data. An object is an instance of a class and contains is a grouping of methods (object functions) and data (object variables and constants). The dot operator directs the program to the information encapsulated within an object.
Syntax
object.method()object.data
Parameters
object
the object you want to access
method()
method encapsulated in the object
data
variable or constant encapsulated in the object
Usage
Web & Application
Related
Object
Updated on November 22, 2008 08:39:25pm PST
Processing was initiated by Ben Fry and Casey Reas. It is developed by a small team of volunteers.
© Info \
Site hosted by Media Temple!
Wyszukiwarka
Podobne podstrony:
Lil´Kim Aunt Dotocena zachowan dot grania hazardowegoinformacje EC2 dot szczegółów konstruowania zbrojeniaDotDesperate Housewives S05E01 HDTV XViD DOT(1)arm dot prod q31? source2015 07 12?33 Prezentacja dot zmiany ustawy PRAWO?RMACEUTYCZNEarm cmplx dot prod q31? sourceEfekt prawie jak Polka Dotgroup cmplx dot prodzagadnienia dot obrotu instrumentami finansowymikoncepcje dot przyczyn autyzmuWymagania przepisów dot maszyn i urządzeń technicznych barwy i znakiu bezpieczeństwaWytyczne dot archiwizacji MRPOReguly dot rezonansu i hybrydyzacjiwięcej podobnych podstron