Objects are created by using the new keyword followed by the name of the class. | |
| |
The first line creates a new instance of Object and stores it in the variable oObject; | |
The second line creates a new instance of String and stores it in the variable oStringObject. | |
The parentheses aren't required when the constructor doesn't require arguments, so these two lines could be rewritten as follows: | |
|