This reference is for Processing 3.0+. If you have a previous version, use the reference included with your software in the Help menu. If you see any errors or have suggestions, please let us know. If you prefer a more technical reference, visit the Processing Core Javadoc and Libraries Javadoc.



final float constant = 12.84753;
println(constant);  // Prints "12.84753" to the console
constant += 12.84;  // ERROR! It's not possible to change a "final" value
Description Keyword used to state that a value, class, or method can't be changed. If the final keyword is used to define a variable, the variable can't be changed within the program. When used to define a class, a final class cannot be subclassed. When used to define a function or method, a final method can't be overridden by subclasses.

This keyword is an essential part of Java programming and is not usually used with Processing. Consult a Java language reference or tutorial for more information.
Updated on August 17, 2018 03:36:37pm EDT

Creative Commons License