Function PseudoMember

  • Creates a class amendment (and decorator) that declares a pseudo-member of the target class.

    A pseudo-member does not alter the class prototype or instance. Instead, its value is read and written by the given accessor.

    Type Parameters

    • TValue

      Pseudo-member value type.

    • TClass extends AmendableClass<any, TClass> = Class<any>

      A type of amended class.

    • TUpdate = TValue

      Pseudo-member update type accepted by its setter.

    • TAmended extends AeMember<TValue, TClass, TUpdate, TAmended> = AeMember<TValue, TClass, TUpdate>

      A type of the entity representing a pseudo-member.

    Parameters

    • accessor: PseudoAccessor<InstanceType<TClass>, TValue, TUpdate>

      Pseudo-member accessor.

    • Rest ...amendments: Amendment<TAmended>[]

      Amendments to apply to pseudo-member.

    Returns PseudoMemberAmendment<TValue, TClass, TUpdate, TAmended>

    New pseudo-member amendment.

Generated using TypeDoc