diff --git a/assets/navigation.js b/assets/navigation.js index a20b455..ce01c23 100644 --- a/assets/navigation.js +++ b/assets/navigation.js @@ -1 +1 @@ -window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAAA6WUUU+DMBSF/0ufiZNlm7o3onswWZZpND4se+jgDhpLS8plkZj9d8N0roXSEn2kPffj9tzTbj4JwgeSOVmDKqUgASkoZmROcplUHMrR9/pVhjknAXlnIiHzSUDijPFEgSDzzS/iEPaWH8JBhHYTTCCoPY0NkK2j8XR2DFqYN4bZkgmgKQwianoXPAW84PaViJFJodNSQLN+NjHLI869hIhzN2RtHKuHsu6cpY2xmtRD6zVoNjluj1t9AJzGYAlDs/z3KJ2qhybJ7EAf+xlj6aYVo0bgTZGB+2eGzixvhHxj00DDp/ZUUc72DFTX+9+tQebfS4E0xpe6AAsT68Ig2tQt867vbsLpWGv1tWLJALQh8zF3tdaJzdULyZA6JrWrmw58rEbjgLDS7acNaq9x/qTHUjvdYewpVhfwozhQzpJIpVUOAhdKSY0ec1qWUI5sKhMbjm816gNF2pyw+bLdSm3fdQ9XUizyAutIKVq3Y2Rs+sKzqjinOw4dyM+6rz4FbHouZaVia/gMgftxWMqYcqtDBq4tc0OfIZcIfmpH103HFzgRiMd1CAAA" \ No newline at end of file +window.navigationData = "data:application/octet-stream;base64,H4sIAAAAAAAAA6WSX0+DMBTFv0uficqyYeTNqG/LoibGh2UPHVygsbSkXBaJ4bsbNjfaUv7EPbY995fTc+72hyB8IwnJK6hSCuKRgmJGQpLLuOJQ3p7ubzLMOfHIFxMxCZceiTLGYwWChNsL4uAPjh/8WQTbBBMIKqGRAXI5WqyCxrMwnwyzNRNAU5hF1PRj8BSwwyWViJBJodNSQHM+WJrjTmMDpEFTwbLZNTv905xG4Cigvf5/fcfpue2ZDvSozxiHG6u6VjDZnIG7srcz6+raNND81t4qylnCQPWzvzzNCv+jYrEDhnVhoAyZFdfdw72/Wmjm9nUrd322Q5w0I8mxcsCai2aJHeF14GeK9EmK48m1Jdr72F5spHjJC6wflaK1HZzxOBXXpuKc7jn0IH/3U/MpYOu5lJWKnCtmCMaXdS0jyp0JGThbNg59h1wiTFN7un6Pv4DXMPV5BgAA" \ No newline at end of file diff --git a/assets/search.js b/assets/search.js index 4250261..5ec9b67 100644 --- a/assets/search.js +++ b/assets/search.js @@ -1 +1 @@ -window.searchData = "data:application/octet-stream;base64,H4sIAAAAAAAAA92cS2/jOBKA/4tydTvhm8wtMzuHAQaL7GJ352AEgWKrE2EdO2vLmQ6C/u8LypTFUpE2Fcnd6D45kVkv1sfiw5Les836r212PXvP/luuFtm15JNslT8X2XX2WFR/y6t8u95t5kU2yXabZXadfd6t5lW5Xm0vwffTp+p5mU2y+TLfbottdp1lXycHpUIwedB7f1+9vaQpvICXDpKelUn2km+KVdV1eArdb50hV7SN8ZV83I9pLdzblSaKc3XP9JW4vz4N8c9GF+m0p3x7W2yey+3W+jWOp1OkdIDj37KLO4431/koEXR7JZ6Qm9Vb23C8yLpqf6CkANebb+hoaYE9E0nMyzJPLJ2nQ2p0/SgpqP09/CvG6fh9J0R6+7Gofnn7965cnCeC6UH/0MIKovmeSfFDOlyV4wfX2jmZuz/L6umPclXkj2eP2TP1E2YURHdooM+ZXD93sYpYbLajTVAHZT9MTawdbv4fa6Dte+FbFUUYwtTXP1ow3zMpbUTNJXOG0L5vRYxFDE39ZOn0gju0Hqvsh1ObUA8fi+o2fyx+efvXWXsA2Php8tpGdWjGzpRQrwOPjdfzZvHnyyDMnjrbaOwkjl4ZRQQ9hPn33XKZPyzbQK3k9rK5fPRwC+lar357fqnebjab/K2r0P/uuFbRJsHG+ut6VRVfqoO+clUVm8/5vNheel8fVQlofbCXEpRduIbhtPieJSJ0ytapQz5fqPbNswsG4x/reb4MdR2AuNvq+DkmMPDP4nldFSctoGbHk0T1wcbvq9d8WS5uNo+752JV/bbZrDcHG076MtToqAVBWlbn69W22uzmVR/FF1AqnKag760TbUfewg3B83qxWxbby/3lo4EET3E78q8koMJz87a7dvbHXcc1j9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hwEybdsqq7aolzdH/YF/Zd4rx9z9jLsGeDxyVjf3r/uVfjrV88DubumSAvXG/GZLesdI3JhW3iXPTf6/Bi9YpYOMUyrlC6H67olXkwM7dic7di87gVrNVJFYu3lMnIoNuXbbx4PR3CtWEZx4v77aJel0+za+wuWhUZ7enBK69GPPi0c9DENadGHTF3wut1Os67cAl75xxZXH8bPILk5dPzSbhTIenOvrTjx8Sx2LwW5GXZI1G4VUHGLTjD0xDuBSy69LpK1N2pbJxqel30FtksDkb7/LrnpLfUuHrriIxoyDdp8lQ+FZaa5Hp98/37/wGqocceUVEAAA=="; \ No newline at end of file diff --git a/classes/InvalidArgumentError.html b/classes/InvalidArgumentError.html deleted file mode 100644 index 41e020f..0000000 --- a/classes/InvalidArgumentError.html +++ /dev/null @@ -1,17 +0,0 @@ -InvalidArgumentError | @medic/cht-datasource

Represents an error that occurs when an invalid argument is provided. -This error is typically thrown when a function or method receives an argument -that doesn't meet the expected criteria or constraints.

-

Hierarchy

  • Error
    • InvalidArgumentError

Constructors

Properties

cause?: unknown
message: string
name: string
stack?: string
prepareStackTrace?: ((err: Error, stackTraces: CallSite[]) => any)

Optional override for formatting stack traces

-
stackTraceLimit: number

Methods

  • Create .stack property on a target object

    -

    Parameters

    • targetObject: object
    • OptionalconstructorOpt: Function

    Returns void

diff --git a/functions/Person.v1.get.html b/functions/Person.v1.get.html index d7bc69d..6ffa278 100644 --- a/functions/Person.v1.get.html +++ b/functions/Person.v1.get.html @@ -2,4 +2,4 @@

Error if the provided context or qualifier is invalid

+
diff --git a/functions/Person.v1.getAll.html b/functions/Person.v1.getAll.html deleted file mode 100644 index 58c3cb0..0000000 --- a/functions/Person.v1.getAll.html +++ /dev/null @@ -1,9 +0,0 @@ -getAll | @medic/cht-datasource

Returns a function for getting a generator that fetches people from the given data context.

-

Error if a data context is not provided

-
  • Parameters

    Returns ((personType: Readonly<{
        contactType: string;
    }>) => AsyncGenerator<Person, null, unknown>)

    a function for getting a generator that fetches people

    -
      • (personType): AsyncGenerator<Person, null, unknown>
      • Returns a generator for fetching all people with the given type

        -

        Parameters

        • personType: Readonly<{
              contactType: string;
          }>

          the type of people to return

          -

        Returns AsyncGenerator<Person, null, unknown>

        a generator for fetching all people with the given type

        -

        Error if no type is provided or if the type is not for a person

        -
diff --git a/functions/Person.v1.getPage.html b/functions/Person.v1.getPage.html deleted file mode 100644 index 33840e6..0000000 --- a/functions/Person.v1.getPage.html +++ /dev/null @@ -1,15 +0,0 @@ -getPage | @medic/cht-datasource

Returns a function for retrieving a paged array of people from the given data context.

-

Error if a data context is not provided

-

getAll which provides the same data, but without having to manually account for paging

-
  • Parameters

    Returns ((personType: Readonly<{
        contactType: string;
    }>, cursor?: Nullable<string>, limit?: number) => Promise<Page<Person>>)

    a function for retrieving a paged array of people

    -
      • (personType, cursor?, limit?): Promise<Page<Person>>
      • Returns an array of people for the provided page specifications.

        -

        Parameters

        • personType: Readonly<{
              contactType: string;
          }>

          the type of people to return

          -
        • cursor: Nullable<string> = null

          the token identifying which page to retrieve. A null value indicates the first page should be -returned. Subsequent pages can be retrieved by providing the cursor returned with the previous page.

          -
        • limit: number = 100

          the maximum number of people to return. Default is 100.

          -

        Returns Promise<Page<Person>>

        a page of people for the provided specification

        -

        Error if no type is provided or if the type is not for a person

        -

        Error if the provided limit value is <=0

        -

        Error if the provided cursor is not a valid page token or null

        -
diff --git a/functions/Person.v1.getWithLineage.html b/functions/Person.v1.getWithLineage.html index f4ba617..1f265bb 100644 --- a/functions/Person.v1.getWithLineage.html +++ b/functions/Person.v1.getWithLineage.html @@ -2,4 +2,4 @@

Error if the provided context or qualifier is invalid

+
diff --git a/functions/Place.v1.get.html b/functions/Place.v1.get.html index e0d3e96..fea5f31 100644 --- a/functions/Place.v1.get.html +++ b/functions/Place.v1.get.html @@ -2,4 +2,4 @@

Error if the provided context or qualifier is invalid

+
diff --git a/functions/Place.v1.getWithLineage.html b/functions/Place.v1.getWithLineage.html index 5c37f0d..026197a 100644 --- a/functions/Place.v1.getWithLineage.html +++ b/functions/Place.v1.getWithLineage.html @@ -2,4 +2,4 @@

Error if the provided context or qualifier is invalid

+
diff --git a/functions/Qualifier.byContactType.html b/functions/Qualifier.byContactType.html deleted file mode 100644 index 84de15d..0000000 --- a/functions/Qualifier.byContactType.html +++ /dev/null @@ -1,5 +0,0 @@ -byContactType | @medic/cht-datasource

Build the TypeQualifier that categorizes an entity by its type

-

Error if the type is invalid

-
  • Parameters

    • contactType: string

      the type of the entity

      -

    Returns Readonly<{
        contactType: string;
    }>

    the type

    -
diff --git a/functions/Qualifier.byUuid.html b/functions/Qualifier.byUuid.html index e868e47..a2f59c8 100644 --- a/functions/Qualifier.byUuid.html +++ b/functions/Qualifier.byUuid.html @@ -2,4 +2,4 @@

Error if the UUID is invalid

+
diff --git a/functions/Qualifier.isContactTypeQualifier.html b/functions/Qualifier.isContactTypeQualifier.html deleted file mode 100644 index 992ec73..0000000 --- a/functions/Qualifier.isContactTypeQualifier.html +++ /dev/null @@ -1,4 +0,0 @@ -isContactTypeQualifier | @medic/cht-datasource

Returns true if the given qualifier is a ContactTypeQualifier otherwise false.

-
  • Parameters

    • contactType: unknown

      the type to check

      -

    Returns contactType is Readonly<{
        contactType: string;
    }>

    true if the given type is a ContactTypeQualifier, otherwise false.

    -
diff --git a/functions/Qualifier.isUuidQualifier.html b/functions/Qualifier.isUuidQualifier.html index c63f3f5..be97287 100644 --- a/functions/Qualifier.isUuidQualifier.html +++ b/functions/Qualifier.isUuidQualifier.html @@ -2,4 +2,4 @@
+
diff --git a/functions/getDatasource.html b/functions/getDatasource.html index 4bd7918..3ae7691 100644 --- a/functions/getDatasource.html +++ b/functions/getDatasource.html @@ -1,8 +1,8 @@ getDatasource | @medic/cht-datasource

Returns the source for CHT data.

Error if the provided context is invalid

-
  • Parameters

    Returns {
        v1: {
            hasAnyPermission: ((permissionsGroupList: string[][], userRoles: string[], chtPermissionsSettings: object) => boolean);
            hasPermissions: ((permissions: string | string[], userRoles: string[], chtPermissionsSettings: object) => boolean);
            person: {
                getByType: ((personType: string) => AsyncGenerator<Person, null, unknown>);
                getByUuid: ((uuid: string) => Promise<Nullable<Person>>);
                getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PersonWithLineage>>);
                getPageByType: ((personType: string, cursor?: Nullable<string>, limit?: number) => Promise<Page<Person>>);
            };
            place: {
                getByUuid: ((uuid: string) => Promise<Nullable<Place>>);
                getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PlaceWithLineage>>);
            };
        };
    }

    the CHT datasource API

    -
    • v1: {
          hasAnyPermission: ((permissionsGroupList: string[][], userRoles: string[], chtPermissionsSettings: object) => boolean);
          hasPermissions: ((permissions: string | string[], userRoles: string[], chtPermissionsSettings: object) => boolean);
          person: {
              getByType: ((personType: string) => AsyncGenerator<Person, null, unknown>);
              getByUuid: ((uuid: string) => Promise<Nullable<Person>>);
              getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PersonWithLineage>>);
              getPageByType: ((personType: string, cursor?: Nullable<string>, limit?: number) => Promise<Page<Person>>);
          };
          place: {
              getByUuid: ((uuid: string) => Promise<Nullable<Place>>);
              getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PlaceWithLineage>>);
          };
      }
      • hasAnyPermission: ((permissionsGroupList: string[][], userRoles: string[], chtPermissionsSettings: object) => boolean)
          • (permissionsGroupList, userRoles, chtPermissionsSettings): boolean
          • Verify if the user's role has all the permissions of any of the provided groups.

            +
  • Parameters

    Returns {
        v1: {
            hasAnyPermission: ((permissionsGroupList: string[][], userRoles: string[], chtPermissionsSettings: object) => boolean);
            hasPermissions: ((permissions: string | string[], userRoles: string[], chtPermissionsSettings: object) => boolean);
            person: {
                getByUuid: ((uuid: string) => Promise<Nullable<Person>>);
                getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PersonWithLineage>>);
            };
            place: {
                getByUuid: ((uuid: string) => Promise<Nullable<Place>>);
                getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PlaceWithLineage>>);
            };
        };
    }

    the CHT datasource API

    +
    • v1: {
          hasAnyPermission: ((permissionsGroupList: string[][], userRoles: string[], chtPermissionsSettings: object) => boolean);
          hasPermissions: ((permissions: string | string[], userRoles: string[], chtPermissionsSettings: object) => boolean);
          person: {
              getByUuid: ((uuid: string) => Promise<Nullable<Person>>);
              getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PersonWithLineage>>);
          };
          place: {
              getByUuid: ((uuid: string) => Promise<Nullable<Place>>);
              getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PlaceWithLineage>>);
          };
      }
      • hasAnyPermission: ((permissionsGroupList: string[][], userRoles: string[], chtPermissionsSettings: object) => boolean)
          • (permissionsGroupList, userRoles, chtPermissionsSettings): boolean
          • Verify if the user's role has all the permissions of any of the provided groups.

            Parameters

            • permissionsGroupList: string[][]

              {string[][]} Array of groups of permissions due to the complexity of permission grouping

            • userRoles: string[]

              {string[]} Array of user roles.

            • chtPermissionsSettings: object

              {object} Object of configured permissions in CHT-Core's settings.

              @@ -10,34 +10,20 @@

              Parameters

              • permissions: string | string[]

                {string | string[]} Permission(s) to verify

              • userRoles: string[]

                {string[]} Array of user roles.

              • chtPermissionsSettings: object

                {object} Object of configured permissions in CHT-Core's settings.

                -

              Returns boolean

        • person: {
              getByType: ((personType: string) => AsyncGenerator<Person, null, unknown>);
              getByUuid: ((uuid: string) => Promise<Nullable<Person>>);
              getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PersonWithLineage>>);
              getPageByType: ((personType: string, cursor?: Nullable<string>, limit?: number) => Promise<Page<Person>>);
          }
          • getByType: ((personType: string) => AsyncGenerator<Person, null, unknown>)

            Returns a generator for fetching all people with the given type.

            -

            Error if no type is provided or if the type is not for a person

            -
              • (personType): AsyncGenerator<Person, null, unknown>
              • Parameters

                • personType: string

                  the type of people to return

                  -

                Returns AsyncGenerator<Person, null, unknown>

                a generator for fetching all people with the given type

                -
          • getByUuid: ((uuid: string) => Promise<Nullable<Person>>)

            Returns a person by their UUID.

            -

            Error if no UUID is provided

            -
              • (uuid): Promise<Nullable<Person>>
              • Parameters

                • uuid: string

                  the UUID of the person to retrieve

                  +

                Returns boolean

          • person: {
                getByUuid: ((uuid: string) => Promise<Nullable<Person>>);
                getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PersonWithLineage>>);
            }
            • getByUuid: ((uuid: string) => Promise<Nullable<Person>>)

              Returns a person by their UUID.

              +

              Error if no UUID is provided

              +
                • (uuid): Promise<Nullable<Person>>
                • Parameters

                  • uuid: string

                    the UUID of the person to retrieve

                  Returns Promise<Nullable<Person>>

                  the person or null if no person is found for the UUID

            • getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PersonWithLineage>>)

              Returns a person by their UUID along with the person's parent lineage.

              -

              Error if no UUID is provided

              -
                • (uuid): Promise<Nullable<PersonWithLineage>>
                • Parameters

                  • uuid: string

                    the UUID of the person to retrieve

                    +

                    Error if no UUID is provided

                    +
                  • getPageByType: ((personType: string, cursor?: Nullable<string>, limit?: number) => Promise<Page<Person>>)

                    Returns an array of people for the provided page specifications.

                    -

                    Error if no type is provided or if the type is not for a person

                    -

                    Error if the provided limit is <= 0

                    -

                    Error if the provided cursor is not a valid page token or null

                    -

                    getByType which provides the same data, but without having to manually account for paging

                    -
                      • (personType, cursor?, limit?): Promise<Page<Person>>
                      • Parameters

                        • personType: string

                          the type of people to return

                          -
                        • cursor: Nullable<string> = null

                          the token identifying which page to retrieve. A null value indicates the first page should be -returned. Subsequent pages can be retrieved by providing the cursor returned with the previous page.

                          -
                        • limit: number = 100

                          the maximum number of people to return. Default is 100.

                          -

                        Returns Promise<Page<Person>>

                        a page of people for the provided specifications

                • place: {
                      getByUuid: ((uuid: string) => Promise<Nullable<Place>>);
                      getByUuidWithLineage: ((uuid: string) => Promise<Nullable<PlaceWithLineage>>);
                  }
                  • getByUuid: ((uuid: string) => Promise<Nullable<Place>>)

                    Returns a place by its UUID.

                    -

                    Error if no UUID is provided

                    -
+
diff --git a/functions/getLocalDataContext.html b/functions/getLocalDataContext.html index 96b965e..7c9fa4b 100644 --- a/functions/getLocalDataContext.html +++ b/functions/getLocalDataContext.html @@ -4,4 +4,4 @@
+
diff --git a/functions/getRemoteDataContext.html b/functions/getRemoteDataContext.html index bb1e8d5..0ad31b4 100644 --- a/functions/getRemoteDataContext.html +++ b/functions/getRemoteDataContext.html @@ -3,4 +3,4 @@
+
diff --git a/interfaces/DataContext.html b/interfaces/DataContext.html index 930a4f2..644263f 100644 --- a/interfaces/DataContext.html +++ b/interfaces/DataContext.html @@ -1,8 +1,8 @@ DataContext | @medic/cht-datasource

Context for interacting with the data. This may represent a local data context where data can be accessed even while offline. Or it may represent a remote data context where all data operations are performed against a remote CHT instance.

-
interface DataContext {
    bind: (<T>(fn: ((ctx: DataContext) => T)) => T);
}

Properties

interface DataContext {
    bind: (<T>(fn: ((ctx: DataContext) => T)) => T);
}

Properties

Properties

bind: (<T>(fn: ((ctx: DataContext) => T)) => T)

Executes the provided function with this data context as the argument.

Type declaration

    • <T>(fn): T
    • Type Parameters

      • T

      Parameters

      Returns T

      the result of the function

      -
+
diff --git a/interfaces/Person.v1.Person.html b/interfaces/Person.v1.Person.html index 9b22d62..d5ddd48 100644 --- a/interfaces/Person.v1.Person.html +++ b/interfaces/Person.v1.Person.html @@ -1,5 +1,5 @@ Person | @medic/cht-datasource

Immutable data about a person contact.

-
interface Person {
    _id: string;
    _rev: string;
    contact_type?: string;
    date_of_birth?: Date;
    name?: string;
    parent?: NormalizedParent;
    patient_id?: string;
    phone?: string;
    reported_date?: Date;
    sex?: string;
    type: string;
}

Hierarchy (view full)

Properties

_id +
interface Person {
    _id: string;
    _rev: string;
    contact_type?: string;
    date_of_birth?: Date;
    name?: string;
    parent?: NormalizedParent;
    patient_id?: string;
    phone?: string;
    reported_date?: Date;
    sex?: string;
    type: string;
}

Hierarchy (view full)

Properties

_id: string
_rev: string
contact_type?: string
date_of_birth?: Date
name?: string
parent?: NormalizedParent
patient_id?: string
phone?: string
reported_date?: Date
sex?: string
type: string
+

Properties

_id: string
_rev: string
contact_type?: string
date_of_birth?: Date
name?: string
parent?: NormalizedParent
patient_id?: string
phone?: string
reported_date?: Date
sex?: string
type: string
diff --git a/interfaces/Person.v1.PersonWithLineage.html b/interfaces/Person.v1.PersonWithLineage.html index a6b1a77..986b7d3 100644 --- a/interfaces/Person.v1.PersonWithLineage.html +++ b/interfaces/Person.v1.PersonWithLineage.html @@ -1,5 +1,5 @@ PersonWithLineage | @medic/cht-datasource

Immutable data about a person contact, including the full records of the parent place lineage.

-
interface PersonWithLineage {
    _id: string;
    _rev: string;
    contact_type?: string;
    date_of_birth?: Date;
    name?: string;
    parent?: NormalizedParent | PlaceWithLineage;
    patient_id?: string;
    phone?: string;
    reported_date?: Date;
    sex?: string;
    type: string;
}

Hierarchy (view full)

Properties

_id +
interface PersonWithLineage {
    _id: string;
    _rev: string;
    contact_type?: string;
    date_of_birth?: Date;
    name?: string;
    parent?: NormalizedParent | PlaceWithLineage;
    patient_id?: string;
    phone?: string;
    reported_date?: Date;
    sex?: string;
    type: string;
}

Hierarchy (view full)

Properties

_id: string
_rev: string
contact_type?: string
date_of_birth?: Date
name?: string
parent?: NormalizedParent | PlaceWithLineage
patient_id?: string
phone?: string
reported_date?: Date
sex?: string
type: string
+

Properties

_id: string
_rev: string
contact_type?: string
date_of_birth?: Date
name?: string
parent?: NormalizedParent | PlaceWithLineage
patient_id?: string
phone?: string
reported_date?: Date
sex?: string
type: string
diff --git a/interfaces/Place.v1.Place.html b/interfaces/Place.v1.Place.html index aa0e9c4..488a49e 100644 --- a/interfaces/Place.v1.Place.html +++ b/interfaces/Place.v1.Place.html @@ -1,5 +1,5 @@ Place | @medic/cht-datasource

Immutable data about a place contact.

-
interface Place {
    _id: string;
    _rev: string;
    contact?: NormalizedParent;
    contact_type?: string;
    name?: string;
    parent?: NormalizedParent;
    place_id?: string;
    reported_date?: Date;
    type: string;
}

Hierarchy (view full)

Properties

_id +
interface Place {
    _id: string;
    _rev: string;
    contact?: NormalizedParent;
    contact_type?: string;
    name?: string;
    parent?: NormalizedParent;
    place_id?: string;
    reported_date?: Date;
    type: string;
}

Hierarchy (view full)

Properties

_id: string
_rev: string
contact?: NormalizedParent
contact_type?: string
name?: string
parent?: NormalizedParent
place_id?: string
reported_date?: Date
type: string
+

Properties

_id: string
_rev: string
contact?: NormalizedParent
contact_type?: string
name?: string
parent?: NormalizedParent
place_id?: string
reported_date?: Date
type: string
diff --git a/interfaces/Place.v1.PlaceWithLineage.html b/interfaces/Place.v1.PlaceWithLineage.html index 0a94b97..558738d 100644 --- a/interfaces/Place.v1.PlaceWithLineage.html +++ b/interfaces/Place.v1.PlaceWithLineage.html @@ -1,6 +1,6 @@ PlaceWithLineage | @medic/cht-datasource

Immutable data about a place contact, including the full records of the parent place lineage and the primary contact for the place.

-
interface PlaceWithLineage {
    _id: string;
    _rev: string;
    contact?: NormalizedParent | PersonWithLineage;
    contact_type?: string;
    name?: string;
    parent?: NormalizedParent | PlaceWithLineage;
    place_id?: string;
    reported_date?: Date;
    type: string;
}

Hierarchy (view full)

Properties

_id +
interface PlaceWithLineage {
    _id: string;
    _rev: string;
    contact?: NormalizedParent | PersonWithLineage;
    contact_type?: string;
    name?: string;
    parent?: NormalizedParent | PlaceWithLineage;
    place_id?: string;
    reported_date?: Date;
    type: string;
}

Hierarchy (view full)

Properties

_id: string
_rev: string
contact?: NormalizedParent | PersonWithLineage
contact_type?: string
name?: string
parent?: NormalizedParent | PlaceWithLineage
place_id?: string
reported_date?: Date
type: string
+

Properties

_id: string
_rev: string
contact?: NormalizedParent | PersonWithLineage
contact_type?: string
name?: string
parent?: NormalizedParent | PlaceWithLineage
place_id?: string
reported_date?: Date
type: string
diff --git a/modules.html b/modules.html index 846c878..61eefa2 100644 --- a/modules.html +++ b/modules.html @@ -1,7 +1,6 @@ @medic/cht-datasource

@medic/cht-datasource

Index

Namespaces

Classes

Interfaces

Type Aliases

NonEmptyArray Nullable diff --git a/modules/Person.html b/modules/Person.html index ab520c8..8014648 100644 --- a/modules/Person.html +++ b/modules/Person.html @@ -1,2 +1,2 @@ -Person | @medic/cht-datasource

Index

Namespaces

v1 +Person | @medic/cht-datasource

Index

Namespaces

diff --git a/modules/Person.v1.html b/modules/Person.v1.html index 204e681..4eb9ac1 100644 --- a/modules/Person.v1.html +++ b/modules/Person.v1.html @@ -1,7 +1,5 @@ -v1 | @medic/cht-datasource

Index

Interfaces

Person +v1 | @medic/cht-datasource
diff --git a/modules/Place.html b/modules/Place.html index b9425bc..d71e57e 100644 --- a/modules/Place.html +++ b/modules/Place.html @@ -1,2 +1,2 @@ -Place | @medic/cht-datasource

Index

Namespaces

v1 +Place | @medic/cht-datasource

Index

Namespaces

diff --git a/modules/Place.v1.html b/modules/Place.v1.html index 43c7d03..d3f6de6 100644 --- a/modules/Place.v1.html +++ b/modules/Place.v1.html @@ -1,4 +1,4 @@ -v1 | @medic/cht-datasource

Index

Interfaces

Place +v1 | @medic/cht-datasource

Index

Interfaces

Functions

get getWithLineage diff --git a/modules/Qualifier.html b/modules/Qualifier.html index 1ab4447..e215011 100644 --- a/modules/Qualifier.html +++ b/modules/Qualifier.html @@ -1,7 +1,4 @@ -Qualifier | @medic/cht-datasource

Index

Type Aliases

Functions

byContactType -byUuid -isContactTypeQualifier +Qualifier | @medic/cht-datasource

Index

Type Aliases

Functions

diff --git a/types/NonEmptyArray.html b/types/NonEmptyArray.html index 86d440c..9d21bd6 100644 --- a/types/NonEmptyArray.html +++ b/types/NonEmptyArray.html @@ -1,2 +1,2 @@ NonEmptyArray | @medic/cht-datasource

Type Alias NonEmptyArray<T>

NonEmptyArray<T>: [T, ...T[]]

An array that is guaranteed to have at least one element.

-

Type Parameters

  • T
+

Type Parameters

  • T
diff --git a/types/Nullable.html b/types/Nullable.html index 1e19a37..917b10a 100644 --- a/types/Nullable.html +++ b/types/Nullable.html @@ -1,2 +1,2 @@ Nullable | @medic/cht-datasource

Type Alias Nullable<T>

Nullable<T>: T | null

A value that could be null.

-

Type Parameters

  • T
+

Type Parameters

  • T
diff --git a/types/Qualifier.ContactTypeQualifier.html b/types/Qualifier.ContactTypeQualifier.html deleted file mode 100644 index 78c4344..0000000 --- a/types/Qualifier.ContactTypeQualifier.html +++ /dev/null @@ -1,2 +0,0 @@ -ContactTypeQualifier | @medic/cht-datasource
ContactTypeQualifier: Readonly<{
    contactType: string;
}>

A qualifier that identifies contacts based on type.

-
diff --git a/types/Qualifier.UuidQualifier.html b/types/Qualifier.UuidQualifier.html index 297c451..85740c0 100644 --- a/types/Qualifier.UuidQualifier.html +++ b/types/Qualifier.UuidQualifier.html @@ -1,2 +1,2 @@ UuidQualifier | @medic/cht-datasource
UuidQualifier: Readonly<{
    uuid: string;
}>

A qualifier that identifies an entity by its UUID.

-
+