Search Results for

    / fm / liveswitch / Future

    Class: Future<T>

    fm.liveswitch.Future

    Type parameters

    Name
    T

    Hierarchy

    • FutureBase<T>

      ↳ Future

      ↳↳ PromiseBase

    Table of contents

    Constructors

    • constructor

    Methods

    • fail
    • getException
    • getResult
    • getState
    • getTypeString
    • setException
    • setResult
    • setState
    • then

    Constructors

    constructor

    + new Future<T>(): Future<T>

    Type parameters:

    Name
    T

    Returns: Future<T>

    Inherited from: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/FutureBase.ts:17

    Methods

    fail

    ▸ Abstractfail(rejectAction: IAction1<Exception>): Future<T>

    Parameters:

    Name Type
    rejectAction IAction1<Exception>

    Returns: Future<T>

    Defined in: Generated/TypeScript/fm.liveswitch/Future.ts:7


    getException

    ▸ getException(): Exception

    Gets the exception if rejected.

    Returns: Exception

    Inherited from: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/FutureBase.ts:35


    getResult

    ▸ getResult(): T

    Gets the result if resolved.

    Returns: T

    Inherited from: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/FutureBase.ts:47


    getState

    ▸ getState(): FutureState

    Gets the current state.

    Returns: FutureState

    Inherited from: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/FutureBase.ts:59


    getTypeString

    ▸ getTypeString(): string

    Returns: string

    Overrides: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/Future.ts:4


    setException

    ▸ ProtectedsetException(value: Exception): void

    Sets the exception if rejected.

    Parameters:

    Name Type
    value Exception

    Returns: void

    Inherited from: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/FutureBase.ts:71


    setResult

    ▸ ProtectedsetResult(value: T): void

    Sets the result if resolved.

    Parameters:

    Name Type
    value T

    Returns: void

    Inherited from: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/FutureBase.ts:83


    setState

    ▸ ProtectedsetState(value: FutureState): void

    Sets the current state.

    Parameters:

    Name Type
    value FutureState

    Returns: void

    Inherited from: FutureBase

    Defined in: Generated/TypeScript/fm.liveswitch/FutureBase.ts:95


    then

    ▸ Abstractthen<R>(resolve: IAction1<T> | IFunction1<T, Future<R>>): Future<R>

    Type parameters:

    Name
    R

    Parameters:

    Name Type
    resolve IAction1<T> | IFunction1<T, Future<R>>

    Returns: Future<R>

    Defined in: Generated/TypeScript/fm.liveswitch/Future.ts:8

    ▸ Abstractthen<R>(resolve: IAction1<T> | IFunction1<T, Future<R>>, reject: IAction1<Exception>): Future<R>

    Type parameters:

    Name
    R

    Parameters:

    Name Type
    resolve IAction1<T> | IFunction1<T, Future<R>>
    reject IAction1<Exception>

    Returns: Future<R>

    Defined in: Generated/TypeScript/fm.liveswitch/Future.ts:9

    In This Article
    Back to top Copyright © LiveSwitch Inc. All Rights Reserved. Doc build for LiveSwitch v1.15.0