Pattern
Hierarchy
Index
Properties
Accessors
Methods
- describe
- getInitializer
- getKind
- hasInitializer
- hasOwnProperty
- isPrototypeOf
- propertyIsEnumerable
- setInitializer
- toLocaleString
- toString
- valueOf
- getDescriber
- setDescriber
Properties
constructor
• constructor: Function
Inherited from Pattern.constructor
Overrides Pattern.constructor
The initial value of Object.prototype.constructor is the standard built-in Object constructor.
should
• should: Assertion
Static
Object
▪ Object: ObjectConstructor
Provides functionality common to all JavaScript objects. Provides functionality common to all JavaScript objects.
Static
describer
▪ describer: Describer
Static
kind
▪ kind: string = ""
Accessors
isOptional
• get isOptional(): Optional
Make current pattern optional.
Returns: Optional
Pattern wrapped with instance of Optional pattern.
isRequired
• get isRequired(): any
Ensures that current pattern is required.
Returns: any
Pattern that is unwrapped from Optional pattern.
Methods
describe
▸ describe(value
: any): string
Describes value in human readable form.
Parameters:
Name | Type | Description |
---|---|---|
value | any | Value that needs to be described. |
Returns: string
Human readable value described as a string.
getInitializer
▸ getInitializer(): any | undefined
Returns the initializing value.
Returns: any | undefined
Initializing value, else undefined.
getKind
▸ getKind(): string
Returns for which kind pattern is created.
Returns: string
Kind represented as a string.
hasInitializer
▸ hasInitializer(): boolean
Evaluates if initializing value was assigned to type.
Returns: boolean
Returns true
if initializing value is set for type, else false.
hasOwnProperty
▸ hasOwnProperty(v
: PropertyKey): boolean
Inherited from Pattern.hasOwnProperty
Overrides Pattern.hasOwnProperty
Determines whether an object has a property with the specified name.
Parameters:
Name | Type | Description |
---|---|---|
v | PropertyKey | A property name. |
Returns: boolean
isPrototypeOf
▸ isPrototypeOf(v
: Object): boolean
Inherited from Pattern.isPrototypeOf
Overrides Pattern.isPrototypeOf
Determines whether an object exists in another object's prototype chain.
Parameters:
Name | Type | Description |
---|---|---|
v | Object | Another object whose prototype chain is to be checked. |
Returns: boolean
propertyIsEnumerable
▸ propertyIsEnumerable(v
: PropertyKey): boolean
Inherited from Pattern.propertyIsEnumerable
Overrides Pattern.propertyIsEnumerable
Determines whether a specified property is enumerable.
Parameters:
Name | Type | Description |
---|---|---|
v | PropertyKey | A property name. |
Returns: boolean
setInitializer
▸ setInitializer(initializer
: any): void
Sets as non-enumerable the initializing value for type if present on conversion.
Parameters:
Name | Type | Description |
---|---|---|
initializer | any | Initializer value provided on conversion. |
Returns: void
toLocaleString
▸ toLocaleString(): string
Inherited from Pattern.toLocaleString
Overrides Pattern.toLocaleString
Returns a date converted to a string using the current locale.
Returns: string
toString
▸ toString(): string
Inherited from Pattern.toString
Returns a string representation of an object.
Returns: string
valueOf
▸ valueOf(): Object
Inherited from Pattern.valueOf
Returns the primitive value of the specified object.
Returns: Object
Static
getDescriber
▸ getDescriber(): Describer
Returns describing library.
Returns: Describer
Describer library instance.
Static
setDescriber
▸ setDescriber(describer
: Describer): void
Sets describing library.
Parameters:
Name | Type | Description |
---|---|---|
describer | Describer | Describer library instance. |
Returns: void