IModel.As(string,bool) Method
Namespace: NextDesign.Core
Description
Checks if this instance is compatible with the specified class type.
Returns True if this instance is an instance of the specified class or its subclass.
See the IModel description for how to specify the class name and the fuzzy match option.
Arguments
Name | Type | Description |
---|---|---|
className | string | Class name Specify the name or fully qualified name of the class. If null or an empty string is specified, this method evaluates to False. If the class with the specified name is not found, this method evaluates to False. |
fuzzy | bool | Fuzzy match option Whether to treat the className argument as the name of a class rather than a fully qualified name. If False, the method evaluates as specifying a class whose fully qualified name matches className. If True, the method evaluates as specifying a class whose class name matches className. If multiple matches are found, this method evaluates as True if the instance is any one of them. The default value is True. |
Return value
- bool