Chapter 3. JavaFX Script code and structure
This chapter covers
- Writing, inheriting, and using classes
- Mixing code with conditions and loops
- Running code when a variable changes
- Dealing with accidents and the unexpected
In chapter 2 we looked at JavaFX Script’s data types and manipulations; this chapter looks at its code constructs. Separating the two is somewhat arbitrary—we saw plenty of code hiding in the previous chapter’s examples because code and data are flip sides of the same coin. Ahead we’ll see how the concepts we discovered last chapter integrate into the syntax as a whole. Our grounding in data will hopefully engender a more immediate understanding as we encounter conditions, loops, functions, classes, and the like.
As mentioned ...
Get JavaFX in Action now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.