Object-Oriented Programming in BBj
BBj has three distinct layers of object orientation that you work with daily:
- Language-level classes -- BBj's own
class/method/fieldsyntax for defining custom types, with inheritance, interfaces, and constructors. - Java interop -- Direct use of Java classes (
HashMap,ArrayList,Iterator, etc.) from BBj code, plus the ability to implement Java interfaces in BBj. - The BBjAPI object model -- The built-in API accessed through
BBjAPI()that provides GUI controls, collections, namespaces, file utilities, and system services. This is the object system you interact with most frequently.
Each layer is covered in its own section. Together they form the complete picture of how objects work in BBj.
If you already know OOP from Java, C#, or a similar language, the concepts transfer directly -- the syntax is different. BBj does not require OOP; procedural code is also valid.
For a comprehensive reference, see the official Custom Objects Tutorial in the BASIS documentation.