Tuesday, August 18, 2009

JavaFX Script Access Modifiers

JavaFX has access modifier similar to the access modifier in Java.
Access Modifier
Behavior
When no modifier is specified, only that script can access it.
package
The variable, function and class can be accessed on that package.
protected
Function and variable accessible in that package and to the subclasses in
other packages
as well.
public
Can be accessed from anywhere.
public-read
Readable as per public modifier, writable only in current script. Other modifiers can
be appended to it to make it writable in wider scope. "package public-read"
will make
it writable within a package also.
public-init
Can be publicly initialized. After that the writable behaviour is similar to public-read.
Other modifiers can be appended to it to make it writable in wider scope.
"package public-init" will make it writable within a package also.writablily

No comments:

Post a Comment