Public and private methods
All of the methods you created in STCalculator are public methods. Most of the methods are internal to the operation of the calculator, so you can make them private methods. The only method you will leave public is open.
The private status of a method is not strictly enforced. That is, an object of one class could still call a private method of another class. It is good practice, however, to make certain methods private. Besides aiding in browsing, this practice helps prevent other programmers from calling methods that are internal to the operation of your class.
To make the STCalculator methods private, do the following in the Applications Browser:
1. Select all of the STCalculator methods. Then, deselect the method open by clicking on it while pressing the Ctrl key.
2. From the Methods pop-up menu, select Change Public/Private. All of the selected methods are now private.
Last modified date: 06/27/2019