Defines the code to execute when an instance of a class is destroyed.
Destructor [ statements ] End [ Destructor ]
- Optional executable statements.
- Completes the statement.
You can also use
- You can change the syntax of this part. See @Option Directive for more information.
Typically, a destructor is needed to free a system resource, such as an Internet socket, for example.
Only one destructor is permitted within a class.
You must put the destructor after all constructors and before all procedures of the types