Class OptionGroup<T, TDeclarations>
Type Parameters
-
T extends Record<string, any>
-
Constructors
constructor
- new OptionGroup<T, TDeclarations>(plugin: ABasePlugin, optionDeclarations: TDeclarations, mappers: { [ k in string | number | symbol]: ((v: any) => T[k]) }): OptionGroup<T, TDeclarations>
-
Parameters
-
-
optionDeclarations: TDeclarations
-
mappers: { [ k in string | number | symbol]: ((v: any) => T[k]) }
Returns OptionGroup<T, TDeclarations>
Methods
setValue
- setValue(value: string | OptionGroupSetValue<TDeclarations>): void
-
Parameters
-
value: string | OptionGroupSetValue<TDeclarations>
Returns void
- setValue<TK>(key: TK, value: ParameterValueType<TDeclarations[TK]>): void
-
Type Parameters
-
TK extends string | number | symbol
Returns void
- setValue(...args: [string | OptionGroupSetValue<TDeclarations>] | [key: keyof TDeclarations, value: ParameterValueType<TDeclarations[keyof TDeclarations]>]): void
-
Parameters
-
Rest
...args: [string | OptionGroupSetValue<TDeclarations>] | [key: keyof TDeclarations, value: ParameterValueType<TDeclarations[keyof TDeclarations]>]
Returns void
Static
factory
- factory<T2>(plugin: ABasePlugin): Builder<T2, Record<never, DeclarationOption>>
-
Type Parameters
-
T2 extends Record<never, unknown>
Returns Builder<T2, Record<never, DeclarationOption>>
Get the mapped values.
Returns
the group values.