O'Reilly logo

JavaFX™ Developer’s Guide by Kim Topley

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

6. Expressions, Functions, and Object Literals

Almost everything in JavaFX is an expression, even things that you would ordinarily not think of as an expression, such as an if statement or a for statement. In fact, we probably shouldn’t even call them “statements” because they can both return a value and be used as part of another expression. The first part of this chapter discusses JavaFX expressions with the more limited meaning of expressions in other languages like Java. You’ll see all the operators that are available in JavaFX and the data types to which they can be applied. The second part of this chapter takes a closer look at JavaFX functions, which are more powerful than Java methods in the sense that they can appear outside class definitions, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required