Member Junction
    Preparing search index...

    Class EntityAlternateBaseViewInfo

    Metadata describing a governed alternate SQL view on an entity that maintains 100% column parity with the entity's canonical BaseView while applying a curated canonical filter or join (for example, Active members or Open orders).

    Alternate base views can form a same-entity derivation hierarchy via ParentID (for example, ActiveAutoRenew selecting from vwActiveMembers).

    Maps to the MJ: Entity Alternate Base Views metadata entity.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    __mj_CreatedAt: Date = null
    __mj_UpdatedAt: Date = null
    CachePolicy: "Default" | "Bypass" = 'Default'
    Description: string = null
    DisplayName: string = null
    Entity: string = null
    EntityID: string = null
    ID: string = null

    Primary Key

    Name: string = null
    Parent: string = null
    ParentID: string = null
    RootParentID: string = null
    SchemaName: string = null
    Sequence: number = 0
    Status: "Active" | "Disabled" | "Deprecated" = 'Active'
    ViewName: string = null

    Accessors

    • get IsBypassCache(): boolean

      True when CachePolicy === 'Bypass' on this view or any ancestor in its ParentView chain, instructing ProviderBase to skip local/server result caching for reads through this alternate base view (used when the view reads the clock or joins other tables whose updates do not fire BaseEntity events on this entity).

      Returns boolean

    • get IsDeprecated(): boolean

      True when this view (or any ancestor in its ParentView chain) has Status === 'Deprecated'. Deprecated alternate base views remain usable at runtime so existing views and queries do not break, but emit a deprecation warning.

      Returns boolean

    • get IsUsable(): boolean

      True when this alternate base view (and every ancestor in its ParentView chain) has Status equal to 'Active' or 'Deprecated'. Disabled views (or views derived from a disabled or missing ancestor) return false.

      Returns boolean

    • get OwningProvider(): IMetadataProvider

      The metadata provider that built this Info object, when known.

      Info getters that resolve sibling metadata (an entity's IS-A children, a permission's RLS filter, a query's fields, an authorization's roles, …) must read from the SAME provider the object came from. In a multi-provider process — several GraphQLDataProvider instances with separateConnection, or a server servicing several connections — the global Metadata.Provider is a different provider or not set at all. Providers pass themselves to every Info constructor (new m.class(row, provider)), and container Info objects hand it to the child Info objects they construct.

      undefined for an Info object built outside a provider (tests, ad-hoc construction). Callers then fall back to the global provider, which is exactly the pre-existing behavior.

      Returns IMetadataProvider

    Methods

    • Copies initialization data from a plain object to the class instance. Only copies properties that already exist on the class to prevent creating new fields. Special handling for DefaultValue fields to extract actual values from SQL Server syntax.

      Parameters

      • initData: any

        The initialization data object

      • OptionalskipKeys: ReadonlySet<string>

        Optional set of property keys handled directly by the subclass constructor

      Returns void

    • Default JSON serialization for BaseInfo subclasses.

      Emits all non-underscored direct field declarations. For _-prefixed private backing fields (the MJ pattern for collection storage — e.g. _Fields, _RelatedEntities, _OrganicKeys), emits the value of the corresponding same-named public getter instead. Purely computed getters without a backing field (display-name formatters, derived flags) are intentionally skipped — they can throw when source fields are null and don't belong on the wire anyway.

      A _-backed getter that throws is omitted from the output rather than aborting the whole serialization. That omission is safe ONLY because such getters are recomputable: the backing field is a lazy cache over other serialized state (e.g. QueryInfo.CategoryPath over CategoryID), so the value is rebuilt on the next access after a warm boot. Do not add a _-backed getter whose value cannot be recomputed from the serialized fields — a throw would silently drop it.

      Nested BaseInfo instances and arrays of them unwrap automatically via JSON.stringify's native toJSON() protocol.

      Subclasses may override to emit a filtered subset or custom shape (see EntityFieldValueInfo).

      Returns Record<string, unknown>