Object
Table of contents
Object
To make use of the Object module an import is required.
import Object;
Object.getClassRef(String) -> Result
This method will attempt to get a class reference from the class name provided as a string.
Returns a Result and unwraps to an Object upon success.
NOTE: This currently only works if the class is defined in the global scope
class Test {}
Object.getClassRef("Test").unwrap(); // <Cls Test>
Object.createFrom(String) -> Result
This method will attempt to create a new object from the class name provided as a string.
Returns a Result and unwraps to an Object upon success.
NOTE: This currently only works if the class is defined in the global scope
class Test {}
Object.createFrom("Test").unwrap(); // <Test instance>