About Classes in EasyLanguage
An EasyLanguage class defines the structure for an object that can contain members such as properties, members, and events. Much like a blueprint, a class describes the actions (behavior) an object can perform and the information (data) it can access.
The following are some of the terms are commonly associated with classes:
- Objects - Instances of a class that allow users to access the methods and properties defined by the class from which it is created. Multiple instances of the same class may be declared and used in an EasyLanguage document.
- Properties - Members of a class that allow your code to read and/or write stored values. Each instance of a class (object) shares the same property definitions but can have different property values specific to that object.
- Methods - Members of a class that perform specific actions (much like a function) within a class such as data retrieval and calculations. Methods often accept parameters (input values). They can return data of a specified type or can be void (not return a value). See Method for a description of the EasyLanguage reserved word used to create a local method.
- Constructors - Special methods that execute each time a new instance of a class (object) is created. Use constructors to initialize the state of your new object See Class Declaration for a generic class declaration and initialization example.
- Dot operator - The period symbol (.) to the right of an object name is used to refer to a child element of an object (such as a property or method). For instance, in the expression PositionProvider1.Count, the dot operator indicates that the term Count is referring to an element of the object named PositionProvider1 that returns the number of available market positions within object.