@osdk/api 2.3.0-beta.8 → 2.3.0-rc.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/build/browser/derivedProperties/DerivedProperty.js +16 -1
- package/build/browser/derivedProperties/DerivedProperty.js.map +1 -1
- package/build/browser/index.js.map +1 -1
- package/build/browser/mapping/DataValueMapping.js.map +1 -1
- package/build/browser/object/Media.js.map +1 -1
- package/build/browser/objectSet/ObjectSet.test.js +4 -205
- package/build/browser/objectSet/ObjectSet.test.js.map +1 -1
- package/build/cjs/{ObjectSet-C67LQ5JX.d.cts → ObjectSet-C3Ud9v-e.d.cts} +6 -57
- package/build/cjs/index.d.cts +4 -4
- package/build/cjs/public/unstable.d.cts +2 -2
- package/build/esm/derivedProperties/DerivedProperty.js +16 -1
- package/build/esm/derivedProperties/DerivedProperty.js.map +1 -1
- package/build/esm/index.js.map +1 -1
- package/build/esm/mapping/DataValueMapping.js.map +1 -1
- package/build/esm/object/Media.js.map +1 -1
- package/build/esm/objectSet/ObjectSet.test.js +4 -205
- package/build/esm/objectSet/ObjectSet.test.js.map +1 -1
- package/build/types/derivedProperties/DerivedProperty.d.ts +6 -32
- package/build/types/derivedProperties/DerivedProperty.d.ts.map +1 -1
- package/build/types/index.d.ts +1 -1
- package/build/types/index.d.ts.map +1 -1
- package/build/types/mapping/DataValueMapping.d.ts +2 -2
- package/build/types/mapping/DataValueMapping.d.ts.map +1 -1
- package/build/types/object/Media.d.ts +0 -7
- package/build/types/object/Media.d.ts.map +1 -1
- package/build/types/objectSet/ObjectSet.test.d.ts.map +1 -1
- package/package.json +1 -1
- package/build/browser/derivedProperties/Expressions.js +0 -2
- package/build/browser/derivedProperties/Expressions.js.map +0 -1
- package/build/esm/derivedProperties/Expressions.js +0 -2
- package/build/esm/derivedProperties/Expressions.js.map +0 -1
- package/build/types/derivedProperties/Expressions.d.ts +0 -53
- package/build/types/derivedProperties/Expressions.d.ts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ObjectSet.test.js","names":["describe","expectTypeOf","it","test","vi","createMockObjectSet","fauxObject","fauxResults","fauxObjectSet","$link","peeps","$objectSetInternals","def","data","where","fn","withProperties","fetchPage","Promise","resolve","fetchOne","asyncIter","aggregate","pivotTo","toEqualTypeOf","fetchPageResult","class","$includeAllBaseObjectProperties","asyncIterResult","$select","x","$includeRid","subselect","withA","base","selectProperty","withFamily","withMom","withParents","todo","withAggregations","whereResults","aggTestObjectSet","result","maxHasSameType","minHasSameType","approximateDistinctNumberNoUndefined","exactDistinctNumberNoUndefined","countNumberNoUndefined","sumNumber","avgNumber","branded","selectedInteger","add","subtract","multiply","divide","abs","negate","max","min","extractPart","maxAggregation","collectList","plus","intAndLong","intAndDouble","longAndDouble","longAndLong","intAndInt","intLongDoubleChain","shortAndIntReturnsInt","shortAndFloatReturnsDouble","constant","double","intPlusIntReturnsInt","integer","nested","selectedDatetime","dateAndDateReturnDate","datetime","dateAndTimeReturnTime","timestamp"],"sources":["ObjectSet.test.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { describe, expectTypeOf, it, test, vi } from \"vitest\";\n\nimport type {\n DerivedProperty,\n NullabilityAdherence,\n ObjectOrInterfaceDefinition,\n ObjectSet as $ObjectSet,\n Osdk,\n PageResult,\n PropertyKeys,\n} from \"../index.js\";\nimport type { DerivedObjectOrInterfaceDefinition } from \"../ontology/ObjectOrInterface.js\";\nimport type { EmployeeApiTest } from \"../test/EmployeeApiTest.js\";\n\nexport function createMockObjectSet<\n Q extends ObjectOrInterfaceDefinition,\n>(): $ObjectSet<Q, never> {\n let fauxObject: Osdk.Instance<Q>,\n fauxResults: any,\n fauxObjectSet: $ObjectSet<Q>;\n\n // eslint-disable-next-line prefer-const\n fauxObject = {\n $link: {\n peeps: {\n $objectSetInternals: {\n def: {},\n },\n },\n },\n } as Osdk.Instance<Q>;\n\n fauxResults = {\n data: [fauxObject],\n };\n\n fauxObjectSet = {\n where: vi.fn(() => {\n return fauxObjectSet;\n }),\n withProperties: vi.fn(() => {\n return fauxObjectSet;\n }),\n fetchPage: vi.fn(() => Promise.resolve(fauxResults)),\n fetchOne: vi.fn(() => fauxObject),\n asyncIter: vi.fn(() => {\n return {};\n }),\n aggregate: vi.fn(() => {\n return {};\n }),\n pivotTo: vi.fn(() => {\n return fauxObjectSet;\n }),\n } as any as $ObjectSet<Q>;\n\n return fauxObjectSet;\n}\n\ndescribe(\"ObjectSet\", () => {\n const fauxObjectSet = createMockObjectSet<EmployeeApiTest>();\n\n describe(\"normal\", () => {\n test(\"select none\", async () => {\n const result = await fauxObjectSet.fetchPage();\n expectTypeOf<typeof result.data[0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>>\n >();\n\n // Do it again but be explicit about the params to be sure\n // we don't break them\n const result2 = await fauxObjectSet.fetchPage<\n PropertyKeys<EmployeeApiTest>,\n false,\n never,\n NullabilityAdherence.Default,\n false\n >();\n });\n\n test(\"select one\", async () => {\n const result = await fauxObjectSet.fetchPage({ \"$select\": [\"fullName\"] });\n expectTypeOf<typeof result.data[0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, \"fullName\">\n >();\n });\n });\n\n describe(\"includeAllBaseObjectProperties\", () => {\n it(\"has the right types if you pass true\", async () => {\n const fetchPageResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({ $includeAllBaseObjectProperties: true });\n\n expectTypeOf(fetchPageResult).toEqualTypeOf<\n PageResult<\n Osdk.Instance<EmployeeApiTest, \"$allBaseProperties\">\n >\n >();\n\n const asyncIterResult = fauxObjectSet\n .where({ class: \"idk\" })\n .asyncIter({ $includeAllBaseObjectProperties: true });\n\n expectTypeOf(asyncIterResult).toEqualTypeOf<\n AsyncIterableIterator<\n Osdk.Instance<EmployeeApiTest, \"$allBaseProperties\">\n >\n >();\n });\n\n it(\"does not let you pass partial $select and true\", async () => {\n const fetchPageResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({\n // @ts-expect-error\n $includeAllBaseObjectProperties: true,\n $select: [\"attachment\"],\n });\n\n const asyncIterResult = fauxObjectSet\n .where({ class: \"idk\" })\n .asyncIter({\n // @ts-expect-error\n $includeAllBaseObjectProperties: true,\n $select: [\"attachment\"],\n });\n });\n\n it(\"does let you pass full select options and false\", async () => {\n const fetchPageResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({\n $includeAllBaseObjectProperties: true,\n\n // this select list is intended to represent all properties on `EmployeeApiTest`,\n // so if you get an error here later and you added properties to that object,\n // be sure to add them here too.\n $select: [\n \"attachment\",\n \"class\",\n \"employeeId\",\n \"fullName\",\n \"geopoint\",\n \"geotimeSeriesReference\",\n \"isActive\",\n \"mediaReference\",\n \"timeseries\",\n \"dateOfJoining\",\n \"hourlyRate\",\n \"yearsOfExperience\",\n \"rank\",\n \"performanceScore\",\n \"mediaReference\",\n \"lastUpdated\",\n ],\n });\n\n const asyncIterResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({\n $includeAllBaseObjectProperties: true,\n\n // this select list is intended to represent all properties on `EmployeeApiTest`,\n // so if you get an error here later and you added properties to that object,\n // be sure to add them here too.\n $select: [\n \"attachment\",\n \"class\",\n \"employeeId\",\n \"fullName\",\n \"geopoint\",\n \"geotimeSeriesReference\",\n \"isActive\",\n \"mediaReference\",\n \"timeseries\",\n \"dateOfJoining\",\n \"hourlyRate\",\n \"yearsOfExperience\",\n \"rank\",\n \"performanceScore\",\n \"mediaReference\",\n \"lastUpdated\",\n ],\n });\n });\n });\n\n test(\"includeRid\", async () => {\n const x = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({ $includeRid: true });\n\n expectTypeOf(x).toEqualTypeOf<\n PageResult<\n Osdk.Instance<EmployeeApiTest, \"$rid\">\n >\n >();\n });\n\n test(\"pivotTo\", async () => {\n const noArgs = await fauxObjectSet.pivotTo(\"peeps\").fetchPage({});\n const subselect = await fauxObjectSet.pivotTo(\"peeps\").fetchPage({\n $select: [\"employeeId\", \"class\"],\n });\n\n expectTypeOf(subselect).toEqualTypeOf<\n PageResult<\n Osdk.Instance<EmployeeApiTest, never, \"employeeId\" | \"class\">\n >\n >();\n });\n\n describe(\".withProperties\", () => {\n test(\"single property\", async () => {\n const withA = fauxObjectSet.withProperties({\n \"a\": (base) => {\n return base.pivotTo(\"lead\").aggregate(\"class:exactDistinct\");\n },\n });\n\n const isWithAAssignable: $ObjectSet<EmployeeApiTest, {}> = withA;\n\n expectTypeOf(withA).toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n a: \"integer\";\n }>\n >();\n\n const withAResults = await withA.fetchPage();\n\n expectTypeOf<typeof withAResults[\"data\"][0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n a: \"integer\";\n }>\n >();\n\n expectTypeOf<typeof withAResults[\"data\"][0][\"a\"]>()\n .toEqualTypeOf<number>();\n });\n\n it(\"can be sub-selected\", () => {\n const objectWithUndefinedRdp = fauxObjectSet.withProperties({\n \"derivedPropertyName\": (base) =>\n base.pivotTo(\"lead\").selectProperty(\"employeeId\"),\n }).fetchOne(3, {\n $select: [\"derivedPropertyName\"],\n });\n });\n\n test(\"multiple properties\", async () => {\n const withFamily = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"dad\": (base) => base.pivotTo(\"lead\").selectProperty(\"fullName\"),\n \"sister\": (base) => base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n });\n expectTypeOf(withFamily).toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }>\n >();\n\n const withFamilyResults = await withFamily.fetchPage();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }>\n >();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"mom\"]>()\n .toEqualTypeOf<number>();\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"dad\"]>()\n .toEqualTypeOf<string | undefined>();\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"sister\"]>()\n .toEqualTypeOf<string[] | undefined>();\n });\n\n describe(\"called in succession\", () => {\n test(\"independently\", () => {\n const withMom = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n });\n\n const withParents = withMom.withProperties({\n \"dad\": (base) => base.pivotTo(\"lead\").selectProperty(\"fullName\"),\n });\n\n expectTypeOf(withParents).toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n mom: \"integer\";\n dad: \"string\" | undefined;\n }>\n >();\n });\n\n test.todo(\"with calculated properties\");\n });\n\n describe(\"nullability\", () => {\n it(\"count, exactDistinct, and approximateDistinct aren't nullable\", async () => {\n const withFamily = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"dad\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:exactDistinct\"),\n \"sis\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:approximateDistinct\"),\n });\n\n const withFamilyResults = await withFamily.fetchPage();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n mom: \"integer\";\n dad: \"integer\";\n sis: \"integer\";\n }>\n >();\n });\n\n it(\n \"collectToSet, collectToList, selectProperty, and numeric aggregations are nullable\",\n async () => {\n const withAggregations = fauxObjectSet.withProperties({\n \"collectSet\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:collectSet\"),\n \"select\": (base) => base.pivotTo(\"lead\").selectProperty(\"fullName\"),\n \"collectList\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n \"min\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:max\"),\n \"max\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:min\"),\n \"sum\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:sum\"),\n \"avg\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:avg\"),\n \"approximatePercentile\": (base) =>\n base.pivotTo(\"lead\").aggregate(\n \"employeeId:approximatePercentile\",\n ),\n });\n\n const withAggregationResults = await withAggregations.fetchPage();\n\n expectTypeOf<typeof withAggregationResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n collectSet: \"string\"[] | undefined;\n select: \"string\" | undefined;\n collectList: \"string\"[] | undefined;\n min: \"double\" | undefined;\n max: \"double\" | undefined;\n sum: \"double\" | undefined;\n avg: \"double\" | undefined;\n approximatePercentile: \"double\" | undefined;\n }\n >\n >();\n },\n );\n });\n\n describe(\"fetch functions return correct Osdk.Instance\", () => {\n const withFamily = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"dad\": (base) => base.pivotTo(\"lead\").selectProperty(\"fullName\"),\n \"sister\": (base) => base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n });\n\n it(\"works with .where\", async () => {\n const where = withFamily.where({ \"mom\": 1 });\n const whereResults = await where.fetchPage();\n\n // Checks that if you did an `await where.fetchPage()` that you can then\n // pass/assign it to something explicit.\n const _assignPreviouslyInferredPages: PageResult<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }\n >\n > = whereResults;\n\n // Checks that if you did an `await where.fetchPage()` that you can then\n // pass/assign it to something explicit.\n const _assignPreviouslyInferredInstance: Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }\n > = whereResults.data[0];\n\n const q = whereResults.data[0].$link.peeps.$objectSetInternals.def;\n\n // same as above but with expectTypeOf\n expectTypeOf<typeof where>().toEqualTypeOf<typeof withFamily>();\n expectTypeOf<typeof whereResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }\n >\n >();\n\n // Checks that when you directly assign, it infers correctly.\n // Sometimes an explicit assignment can affect how typescript infers\n // types.\n const shouldBeAssignablePage: PageResult<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }\n >\n > = await where.fetchPage();\n\n const _shouldBeAssignableSingle: Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }\n > = await withFamily.fetchOne(1);\n await withFamily.fetchOne(1);\n });\n\n it(\"works with .async\", () => {\n const asyncIter = withFamily.asyncIter();\n expectTypeOf<typeof asyncIter>().toEqualTypeOf<\n AsyncIterableIterator<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }\n >\n >\n >();\n });\n\n it(\"Works with no select\", async () => {\n const withFamilyResults = await withFamily.fetchPage();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }\n >\n >();\n });\n\n it(\"Works with selecting all RDPs\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"mom\", \"dad\", \"sister\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, never, {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }>\n >();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"mom\"]>()\n .toEqualTypeOf<number>();\n });\n\n it(\"Works with selecting some RDPs\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"mom\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, never, {\n mom: \"integer\";\n }>\n >();\n });\n\n it(\"Works with selecting all non-RDP's\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\n \"employeeId\",\n \"fullName\",\n \"class\",\n \"attachment\",\n \"geopoint\",\n \"timeseries\",\n \"mediaReference\",\n \"geotimeSeriesReference\",\n \"isActive\",\n \"yearsOfExperience\",\n \"rank\",\n \"performanceScore\",\n \"hourlyRate\",\n \"dateOfJoining\",\n \"lastUpdated\",\n ],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {}\n >\n >();\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"class\"]>()\n .toEqualTypeOf<\n string | undefined\n >();\n });\n\n it(\"Works with selecting some non-RDP's\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"class\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, \"class\", {}>\n >();\n });\n\n it(\"Works with selecting a mix\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"class\", \"mom\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n \"class\",\n { mom: \"integer\" }\n >\n >();\n });\n });\n\n it(\"allows extracting the type\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n });\n\n type ObjectSetType = typeof objectSet;\n\n expectTypeOf<ObjectSetType>().toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n mom: \"integer\";\n }>\n >();\n\n const objectSet2 = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n }) satisfies ObjectSetType;\n });\n\n it(\"Defining the Type\", () => {\n type ObjectSetType = $ObjectSet<\n EmployeeApiTest,\n {\n mom: \"integer\";\n }\n >;\n\n fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n }) satisfies ObjectSetType;\n });\n\n it(\"has correct aggregation keys\", () => {\n fauxObjectSet.withProperties({\n \"integer\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"integerNumericAgg\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"employeeId:sum\"),\n \"string\": (base) => base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n \"stringDoesNotHaveNumericAgg\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"class:sum\"),\n \"isActive\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"isActive:approximateDistinct\"),\n \"attachment\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"attachment:collectList\"),\n \"geopoint\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"geopoint:collectList\"),\n \"numericTimeseries\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"timeseries:sum\"),\n \"numericTimeseriesExactDistinct\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"timeseries:exactDistinct\"),\n \"mediaReference\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"mediaReference:avg\"),\n \"mediaReferenceExactDistinct\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"mediaReference:exactDistinct\"),\n \"geotimeSeriesReference\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"geotimeSeriesReference:sum\"),\n \"geotimeSeriesReferenceExactDistinct\": (base) =>\n base.pivotTo(\"lead\").aggregate(\n \"geotimeSeriesReference:exactDistinct\",\n ),\n \"lastUpdated\": (base) => {\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:approximateDistinct\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:exactDistinct\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:max\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:min\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:collectList\");\n return base.pivotTo(\"lead\").aggregate(\"lastUpdated:collectSet\");\n },\n \"dateOfJoining\": (base) => {\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:approximateDistinct\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:exactDistinct\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:max\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:min\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:collectList\");\n return base.pivotTo(\"lead\").aggregate(\"dateOfJoining:collectSet\");\n },\n });\n });\n\n it(\"has correct aggregation return types\", async () => {\n const aggTestObjectSet = fauxObjectSet.withProperties({\n \"maxHasSameType\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:max\"),\n \"minHasSameType\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:min\"),\n \"approximateDistinctNumberNoUndefined\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"employeeId:approximateDistinct\"),\n \"exactDistinctNumberNoUndefined\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"employeeId:exactDistinct\"),\n \"countNumberNoUndefined\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"sumNumber\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:sum\"),\n \"avgNumber\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:avg\"),\n }).fetchPage();\n\n const result = (await aggTestObjectSet).data[0];\n expectTypeOf((await aggTestObjectSet).data[0]).toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n maxHasSameType: \"datetime\" | undefined;\n minHasSameType: \"datetime\" | undefined;\n avgNumber: \"double\" | undefined;\n approximateDistinctNumberNoUndefined: \"integer\";\n exactDistinctNumberNoUndefined: \"integer\";\n countNumberNoUndefined: \"integer\";\n sumNumber: \"double\" | undefined;\n }>\n >();\n\n expectTypeOf(result.maxHasSameType).toEqualTypeOf<string | undefined>();\n expectTypeOf(result.minHasSameType).toEqualTypeOf<string | undefined>();\n expectTypeOf(result.approximateDistinctNumberNoUndefined).toEqualTypeOf<\n number\n >();\n expectTypeOf(result.exactDistinctNumberNoUndefined).toEqualTypeOf<\n number\n >();\n expectTypeOf(result.countNumberNoUndefined).toEqualTypeOf<number>();\n expectTypeOf(result.sumNumber).toEqualTypeOf<number | undefined>();\n expectTypeOf(result.avgNumber).toEqualTypeOf<number | undefined>();\n });\n\n it(\"Merged object type is equivalent to original\", () => {\n const a = {} as EmployeeApiTest;\n let b = {} as DerivedObjectOrInterfaceDefinition.WithDerivedProperties<\n EmployeeApiTest,\n {}\n >;\n\n b = a; // should be assignable. testing explicitly due to break in 2.2 release.\n\n expectTypeOf<\n EmployeeApiTest\n >().branded.toEqualTypeOf<\n DerivedObjectOrInterfaceDefinition.WithDerivedProperties<\n EmployeeApiTest,\n {}\n >\n >();\n });\n });\n describe(\"aggregate\", () => {\n it(\"has correct aggregation keys\", () => {\n void fauxObjectSet.aggregate({\n \"$select\": {\n \"lastUpdated:max\": \"asc\",\n \"lastUpdated:min\": \"desc\",\n \"lastUpdated:approximateDistinct\": \"asc\",\n \"lastUpdated:exactDistinct\": \"desc\",\n \"dateOfJoining:max\": \"desc\",\n \"dateOfJoining:min\": \"asc\",\n \"dateOfJoining:approximateDistinct\": \"asc\",\n \"dateOfJoining:exactDistinct\": \"desc\",\n },\n });\n });\n });\n describe(\"expressions\", () => {\n \"Test all property types\";\n describe(\"numeric expressions\", () => {\n it(\"provides correct methods off of selected numeric derived property definitions\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const selectedInteger = base.pivotTo(\"lead\").selectProperty(\n \"employeeId\",\n );\n\n expectTypeOf(selectedInteger).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"integer\" | undefined,\n EmployeeApiTest\n >\n >;\n\n selectedInteger.add(1);\n selectedInteger.subtract(1);\n selectedInteger.multiply(1);\n selectedInteger.divide(1);\n selectedInteger.abs();\n selectedInteger.negate();\n selectedInteger.max(1);\n selectedInteger.min(1);\n\n // @ts-expect-error\n selectedInteger.extractPart(\"1\");\n\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"performanceScore\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\" | undefined,\n EmployeeApiTest\n >\n >();\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"rank\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"short\" | undefined,\n EmployeeApiTest\n >\n >();\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"yearsOfExperience\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"long\" | undefined,\n EmployeeApiTest\n >\n >();\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"hourlyRate\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"float\" | undefined,\n EmployeeApiTest\n >\n >();\n\n return selectedInteger;\n },\n });\n });\n\n it(\"provides correct methods off of selection definitions\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const selectedInteger = base.pivotTo(\"lead\").selectProperty(\n \"employeeId\",\n );\n\n expectTypeOf(selectedInteger).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"integer\" | undefined,\n EmployeeApiTest\n >\n >;\n\n selectedInteger.add(1);\n selectedInteger.subtract(1);\n selectedInteger.multiply(1);\n selectedInteger.divide(1);\n selectedInteger.abs();\n selectedInteger.negate();\n selectedInteger.max(1);\n selectedInteger.min(1);\n\n // @ts-expect-error\n selectedInteger.extractPart(\"1\");\n\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"performanceScore\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\" | undefined,\n EmployeeApiTest\n >\n >();\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"rank\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"short\" | undefined,\n EmployeeApiTest\n >\n >();\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"yearsOfExperience\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"long\" | undefined,\n EmployeeApiTest\n >\n >();\n expectTypeOf(\n base.pivotTo(\"lead\").selectProperty(\n \"hourlyRate\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"float\" | undefined,\n EmployeeApiTest\n >\n >();\n\n return selectedInteger;\n },\n });\n });\n\n it(\"provides correct methods off of aggregated properties\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const maxAggregation = base.pivotTo(\"lead\").aggregate(\n \"employeeId:max\",\n );\n\n expectTypeOf(maxAggregation).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"integer\" | undefined,\n EmployeeApiTest\n >\n >;\n\n maxAggregation.add(1);\n maxAggregation.subtract(1);\n maxAggregation.multiply(1);\n maxAggregation.divide(1);\n maxAggregation.abs();\n maxAggregation.negate();\n maxAggregation.max(1);\n maxAggregation.min(1);\n\n expectTypeOf(\n base.pivotTo(\"peeps\").aggregate(\"employeeId:sum\"),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\" | undefined,\n EmployeeApiTest\n >\n >();\n\n expectTypeOf(\n base.pivotTo(\"peeps\").aggregate(\"employeeId:avg\"),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\" | undefined,\n EmployeeApiTest\n >\n >();\n\n expectTypeOf(\n base.pivotTo(\"peeps\").aggregate(\"employeeId:min\"),\n ).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"integer\" | undefined,\n EmployeeApiTest\n >\n >();\n\n const collectList = base.pivotTo(\"peeps\").aggregate(\n \"employeeId:collectList\",\n );\n expectTypeOf(\n collectList,\n ).toEqualTypeOf<\n DerivedProperty.Definition<\n \"integer\"[] | undefined,\n EmployeeApiTest\n >\n >();\n\n // @ts-expect-error\n collectList.plus(1);\n\n expectTypeOf(\n base.pivotTo(\"peeps\").aggregate(\n \"employeeId:collectList\",\n ),\n ).toEqualTypeOf<\n DerivedProperty.Definition<\n \"integer\"[] | undefined,\n EmployeeApiTest\n >\n >();\n\n return maxAggregation;\n },\n });\n });\n\n it(\"correctly coerces numeric types\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const intAndLong = base.pivotTo(\"lead\").selectProperty(\"employeeId\")\n .add(base.selectProperty(\"yearsOfExperience\")).add(\n base.selectProperty(\"employeeId\"),\n );\n expectTypeOf(intAndLong).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\"long\", EmployeeApiTest>\n >();\n\n const intAndDouble = base.pivotTo(\"lead\").selectProperty(\n \"employeeId\",\n )\n .add(base.selectProperty(\"performanceScore\")).add(\n base.selectProperty(\"employeeId\"),\n );\n expectTypeOf(intAndDouble).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n const longAndDouble = base.pivotTo(\"lead\").selectProperty(\n \"yearsOfExperience\",\n )\n .add(base.selectProperty(\"performanceScore\")).add(\n base.selectProperty(\"yearsOfExperience\"),\n );\n expectTypeOf(longAndDouble).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n const longAndLong = base.pivotTo(\"lead\").selectProperty(\n \"yearsOfExperience\",\n )\n .add(base.selectProperty(\"yearsOfExperience\"));\n expectTypeOf(longAndLong).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\"long\", EmployeeApiTest>\n >();\n\n const intAndInt = base.pivotTo(\"lead\").selectProperty(\"employeeId\")\n .add(base.selectProperty(\"employeeId\"));\n expectTypeOf(intAndInt).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"integer\",\n EmployeeApiTest\n >\n >();\n\n const intLongDoubleChain = base.pivotTo(\"lead\").selectProperty(\n \"employeeId\",\n ).add(base.selectProperty(\"yearsOfExperience\")).add(\n base.selectProperty(\"employeeId\"),\n ).add(\n base.selectProperty(\"performanceScore\"),\n ).add(base.selectProperty(\"employeeId\"));\n expectTypeOf(intLongDoubleChain).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n const shortAndIntReturnsInt = base.pivotTo(\"lead\").selectProperty(\n \"rank\",\n ).add(base.selectProperty(\"employeeId\"));\n expectTypeOf(shortAndIntReturnsInt).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"integer\",\n EmployeeApiTest\n >\n >();\n\n const shortAndFloatReturnsDouble = base.pivotTo(\"lead\")\n .selectProperty(\n \"rank\",\n ).add(base.selectProperty(\"hourlyRate\"));\n expectTypeOf(shortAndFloatReturnsDouble).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n return intLongDoubleChain;\n },\n });\n });\n\n it(\"allows adding number literals as a double\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const plus = base.pivotTo(\"lead\").selectProperty(\"employeeId\")\n .add(1);\n expectTypeOf(plus).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n return plus;\n },\n });\n });\n\n it(\"allows adding literals via base.constant\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const plus = base.pivotTo(\"lead\").selectProperty(\"employeeId\")\n .add(base.constant.double(1));\n expectTypeOf(plus).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n const intPlusIntReturnsInt = base.pivotTo(\"lead\").selectProperty(\n \"employeeId\",\n )\n .add(base.constant.integer(1));\n expectTypeOf(intPlusIntReturnsInt).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"integer\",\n EmployeeApiTest\n >\n >();\n\n return plus;\n },\n });\n });\n\n it(\"allows correctly typed nested property definitions\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const nested = base.pivotTo(\"lead\").selectProperty(\"employeeId\")\n .add(\n base.pivotTo(\"peeps\").aggregate(\"employeeId:sum\"),\n );\n expectTypeOf(nested).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n return nested;\n },\n });\n });\n\n it(\"allows correctly types property keys off the linked OT\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const nested = base.pivotTo(\"lead\").selectProperty(\"employeeId\")\n .add(\n base.selectProperty(\"performanceScore\"),\n );\n expectTypeOf(nested).toEqualTypeOf<\n DerivedProperty.NumericPropertyDefinition<\n \"double\",\n EmployeeApiTest\n >\n >();\n\n return nested;\n },\n });\n });\n\n // it(\"allows correctly types property keys off the base OT\", () => {});\n });\n describe(\"datetime expressions\", () => {\n it(\"provides correct methods off of datetime selections\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const selectedDatetime = base.pivotTo(\"lead\").selectProperty(\n \"dateOfJoining\",\n );\n\n expectTypeOf(selectedDatetime).toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"datetime\" | undefined,\n EmployeeApiTest\n >\n >();\n\n selectedDatetime.max(base.selectProperty(\"dateOfJoining\"));\n selectedDatetime.min(base.selectProperty(\"lastUpdated\"));\n\n expectTypeOf(base.pivotTo(\"lead\").selectProperty(\"lastUpdated\"))\n .toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"timestamp\" | undefined,\n EmployeeApiTest\n >\n >();\n\n return selectedDatetime;\n },\n });\n });\n\n it(\"correctly coerces datetime types\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const max = base.pivotTo(\"lead\").selectProperty(\"dateOfJoining\")\n .max(base.selectProperty(\"lastUpdated\"));\n expectTypeOf(max).toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"timestamp\",\n EmployeeApiTest\n >\n >();\n\n const min = base.pivotTo(\"lead\").selectProperty(\"dateOfJoining\")\n .min(base.selectProperty(\"dateOfJoining\"));\n expectTypeOf(min).toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"datetime\",\n EmployeeApiTest\n >\n >();\n\n return max;\n },\n });\n });\n\n it(\"allows adding literals via base.constant\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const dateAndDateReturnDate = base.pivotTo(\"lead\").selectProperty(\n \"dateOfJoining\",\n )\n .min(base.constant.datetime(\"2025-01-01T00:00:00Z\"));\n expectTypeOf(dateAndDateReturnDate).toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"datetime\",\n EmployeeApiTest\n >\n >();\n\n const dateAndTimeReturnTime = base.pivotTo(\"lead\").selectProperty(\n \"dateOfJoining\",\n )\n .min(base.constant.timestamp(\"2025-01-01T00:00:00Z\"));\n expectTypeOf(dateAndTimeReturnTime).toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"timestamp\",\n EmployeeApiTest\n >\n >();\n\n return dateAndTimeReturnTime;\n },\n });\n });\n\n it(\"allows correctly typed nested property definitions\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const nested = base.pivotTo(\"lead\").selectProperty(\"dateOfJoining\")\n .min(\n base.pivotTo(\"lead\").pivotTo(\"lead\").selectProperty(\n \"lastUpdated\",\n ),\n );\n expectTypeOf(nested).toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"timestamp\",\n EmployeeApiTest\n >\n >();\n\n return nested;\n },\n });\n });\n\n it(\"allows correctly typed property keys off the linked OT\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"myProp1\": (base) => {\n const nested = base.pivotTo(\"lead\").selectProperty(\"dateOfJoining\")\n .min(\n base.selectProperty(\"lastUpdated\"),\n );\n expectTypeOf(nested).toEqualTypeOf<\n DerivedProperty.DatetimePropertyDefinition<\n \"timestamp\",\n EmployeeApiTest\n >\n >();\n\n return nested;\n },\n });\n });\n\n // it(\"allows correctly typed property keys off the base OT\", () => {});\n });\n });\n});\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,QAAQ,EAAEC,YAAY,EAAE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QACF,CAAC,CAAC;MACJ,CAAC,CAAC;MAEF3E,EAAE,CAAC,wDAAwD,EAAE,MAAM;QAC/CM,aAAa,CAACQ,cAAc,CAAC;UAC7C,SAAS,EAAGkB,IAAI,IAAK;YACnB,MAAM2C,MAAM,GAAG3C,IAAI,CAACX,OAAO,CAAC,MAAM,CAAC,CAACY,cAAc,CAAC,eAAe,CAAC,CAChEyB,GAAG,CACF1B,IAAI,CAACC,cAAc,CAAC,aAAa,CACnC,CAAC;YACHlC,YAAY,CAAC4E,MAAM,CAAC,CAACrD,aAAa,CAKhC,CAAC;YAEH,OAAOqD,MAAM;UACf;QACF,CAAC,CAAC;MACJ,CAAC,CAAC;;MAEF;IACF,CAAC,CAAC;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC","ignoreList":[]}
|
|
1
|
+
{"version":3,"file":"ObjectSet.test.js","names":["describe","expectTypeOf","it","test","vi","createMockObjectSet","fauxObject","fauxResults","fauxObjectSet","$link","peeps","$objectSetInternals","def","data","where","fn","withProperties","fetchPage","Promise","resolve","fetchOne","asyncIter","aggregate","pivotTo","toEqualTypeOf","fetchPageResult","class","$includeAllBaseObjectProperties","asyncIterResult","$select","x","$includeRid","subselect","withA","base","withFamily","withMom","withParents","todo","withAggregations","whereResults","aggTestObjectSet","result","maxHasSameType","minHasSameType","approximateDistinctNumberNoUndefined","exactDistinctNumberNoUndefined","countNumberNoUndefined","sumNumber","avgNumber","branded"],"sources":["ObjectSet.test.ts"],"sourcesContent":["/*\n * Copyright 2025 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { describe, expectTypeOf, it, test, vi } from \"vitest\";\n\nimport type {\n NullabilityAdherence,\n ObjectOrInterfaceDefinition,\n ObjectSet as $ObjectSet,\n Osdk,\n PageResult,\n PropertyKeys,\n} from \"../index.js\";\nimport type { DerivedObjectOrInterfaceDefinition } from \"../ontology/ObjectOrInterface.js\";\nimport type { EmployeeApiTest } from \"../test/EmployeeApiTest.js\";\n\nexport function createMockObjectSet<\n Q extends ObjectOrInterfaceDefinition,\n>(): $ObjectSet<Q, never> {\n let fauxObject: Osdk.Instance<Q>,\n fauxResults: any,\n fauxObjectSet: $ObjectSet<Q>;\n\n // eslint-disable-next-line prefer-const\n fauxObject = {\n $link: {\n peeps: {\n $objectSetInternals: {\n def: {},\n },\n },\n },\n } as Osdk.Instance<Q>;\n\n fauxResults = {\n data: [fauxObject],\n };\n\n fauxObjectSet = {\n where: vi.fn(() => {\n return fauxObjectSet;\n }),\n withProperties: vi.fn(() => {\n return fauxObjectSet;\n }),\n fetchPage: vi.fn(() => Promise.resolve(fauxResults)),\n fetchOne: vi.fn(() => fauxObject),\n asyncIter: vi.fn(() => {\n return {};\n }),\n aggregate: vi.fn(() => {\n return {};\n }),\n pivotTo: vi.fn(() => {\n return fauxObjectSet;\n }),\n } as any as $ObjectSet<Q>;\n\n return fauxObjectSet;\n}\n\ndescribe(\"ObjectSet\", () => {\n const fauxObjectSet = createMockObjectSet<EmployeeApiTest>();\n\n describe(\"normal\", () => {\n test(\"select none\", async () => {\n const result = await fauxObjectSet.fetchPage();\n expectTypeOf<typeof result.data[0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>>\n >();\n\n // Do it again but be explicit about the params to be sure\n // we don't break them\n const result2 = await fauxObjectSet.fetchPage<\n PropertyKeys<EmployeeApiTest>,\n false,\n never,\n NullabilityAdherence.Default,\n false\n >();\n });\n\n test(\"select one\", async () => {\n const result = await fauxObjectSet.fetchPage({ \"$select\": [\"fullName\"] });\n expectTypeOf<typeof result.data[0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, \"fullName\">\n >();\n });\n });\n\n describe(\"includeAllBaseObjectProperties\", () => {\n it(\"has the right types if you pass true\", async () => {\n const fetchPageResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({ $includeAllBaseObjectProperties: true });\n\n expectTypeOf(fetchPageResult).toEqualTypeOf<\n PageResult<\n Osdk.Instance<EmployeeApiTest, \"$allBaseProperties\">\n >\n >();\n\n const asyncIterResult = fauxObjectSet\n .where({ class: \"idk\" })\n .asyncIter({ $includeAllBaseObjectProperties: true });\n\n expectTypeOf(asyncIterResult).toEqualTypeOf<\n AsyncIterableIterator<\n Osdk.Instance<EmployeeApiTest, \"$allBaseProperties\">\n >\n >();\n });\n\n it(\"does not let you pass partial $select and true\", async () => {\n const fetchPageResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({\n // @ts-expect-error\n $includeAllBaseObjectProperties: true,\n $select: [\"attachment\"],\n });\n\n const asyncIterResult = fauxObjectSet\n .where({ class: \"idk\" })\n .asyncIter({\n // @ts-expect-error\n $includeAllBaseObjectProperties: true,\n $select: [\"attachment\"],\n });\n });\n\n it(\"does let you pass full select options and false\", async () => {\n const fetchPageResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({\n $includeAllBaseObjectProperties: true,\n\n // this select list is intended to represent all properties on `EmployeeApiTest`,\n // so if you get an error here later and you added properties to that object,\n // be sure to add them here too.\n $select: [\n \"attachment\",\n \"class\",\n \"employeeId\",\n \"fullName\",\n \"geopoint\",\n \"geotimeSeriesReference\",\n \"isActive\",\n \"mediaReference\",\n \"timeseries\",\n \"dateOfJoining\",\n \"hourlyRate\",\n \"yearsOfExperience\",\n \"rank\",\n \"performanceScore\",\n \"mediaReference\",\n \"lastUpdated\",\n ],\n });\n\n const asyncIterResult = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({\n $includeAllBaseObjectProperties: true,\n\n // this select list is intended to represent all properties on `EmployeeApiTest`,\n // so if you get an error here later and you added properties to that object,\n // be sure to add them here too.\n $select: [\n \"attachment\",\n \"class\",\n \"employeeId\",\n \"fullName\",\n \"geopoint\",\n \"geotimeSeriesReference\",\n \"isActive\",\n \"mediaReference\",\n \"timeseries\",\n \"dateOfJoining\",\n \"hourlyRate\",\n \"yearsOfExperience\",\n \"rank\",\n \"performanceScore\",\n \"mediaReference\",\n \"lastUpdated\",\n ],\n });\n });\n });\n\n test(\"includeRid\", async () => {\n const x = await fauxObjectSet\n .where({ class: \"idk\" })\n .fetchPage({ $includeRid: true });\n\n expectTypeOf(x).toEqualTypeOf<\n PageResult<\n Osdk.Instance<EmployeeApiTest, \"$rid\">\n >\n >();\n });\n\n test(\"pivotTo\", async () => {\n const noArgs = await fauxObjectSet.pivotTo(\"peeps\").fetchPage({});\n const subselect = await fauxObjectSet.pivotTo(\"peeps\").fetchPage({\n $select: [\"employeeId\", \"class\"],\n });\n\n expectTypeOf(subselect).toEqualTypeOf<\n PageResult<\n Osdk.Instance<EmployeeApiTest, never, \"employeeId\" | \"class\">\n >\n >();\n });\n\n describe(\".withProperties\", () => {\n test(\"single property\", async () => {\n const withA = fauxObjectSet.withProperties({\n \"a\": (base) => {\n return base.pivotTo(\"lead\").aggregate(\"class:exactDistinct\");\n },\n });\n\n const isWithAAssignable: $ObjectSet<EmployeeApiTest, {}> = withA;\n\n expectTypeOf(withA).toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n a: \"integer\";\n }>\n >();\n\n const withAResults = await withA.fetchPage();\n\n expectTypeOf<typeof withAResults[\"data\"][0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n a: \"integer\";\n }>\n >();\n\n expectTypeOf<typeof withAResults[\"data\"][0][\"a\"]>()\n .toEqualTypeOf<number>();\n });\n\n it(\"can be sub-selected\", () => {\n const objectWithUndefinedRdp = fauxObjectSet.withProperties({\n \"derivedPropertyName\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:max\"),\n }).fetchOne(3, {\n $select: [\"derivedPropertyName\"],\n });\n });\n\n test(\"multiple properties\", async () => {\n const withFamily = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"dad\": (base) => base.pivotTo(\"lead\").aggregate(\"dateOfJoining:max\"),\n \"sister\": (base) => base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n });\n expectTypeOf(withFamily).toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n mom: \"integer\";\n dad: \"datetime\" | undefined;\n sister: \"string\"[] | undefined;\n }>\n >();\n\n const withFamilyResults = await withFamily.fetchPage();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n mom: \"integer\";\n dad: \"string\" | undefined;\n sister: \"string\"[] | undefined;\n }>\n >();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"mom\"]>()\n .toEqualTypeOf<number>();\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"dad\"]>()\n .toEqualTypeOf<string | undefined>();\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"sister\"]>()\n .toEqualTypeOf<string[] | undefined>();\n });\n\n describe(\"called in succession\", () => {\n test(\"independently\", () => {\n const withMom = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n });\n\n const withParents = withMom.withProperties({\n \"dad\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"fullName:approximateDistinct\"),\n });\n\n expectTypeOf(withParents).toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n mom: \"integer\";\n dad: \"integer\";\n }>\n >();\n });\n\n test.todo(\"with calculated properties\");\n });\n\n describe(\"nullability\", () => {\n it(\"count, exactDistinct, and approximateDistinct aren't nullable\", async () => {\n const withFamily = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"dad\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:exactDistinct\"),\n \"sis\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:approximateDistinct\"),\n });\n\n const withFamilyResults = await withFamily.fetchPage();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>().toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n mom: \"integer\";\n dad: \"integer\";\n sis: \"integer\";\n }>\n >();\n });\n\n it(\n \"collectToSet, collectToList, selectProperty, and numeric aggregations are nullable\",\n async () => {\n const withAggregations = fauxObjectSet.withProperties({\n \"collectSet\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:collectSet\"),\n \"collectList\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n \"min\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:max\"),\n \"max\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:min\"),\n \"sum\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:sum\"),\n \"avg\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:avg\"),\n \"approximatePercentile\": (base) =>\n base.pivotTo(\"lead\").aggregate(\n \"employeeId:approximatePercentile\",\n ),\n });\n\n const withAggregationResults = await withAggregations.fetchPage();\n\n expectTypeOf<typeof withAggregationResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n collectSet: \"string\"[] | undefined;\n collectList: \"string\"[] | undefined;\n min: \"double\" | undefined;\n max: \"double\" | undefined;\n sum: \"double\" | undefined;\n avg: \"double\" | undefined;\n approximatePercentile: \"double\" | undefined;\n }\n >\n >();\n },\n );\n });\n\n describe(\"fetch functions return correct Osdk.Instance\", () => {\n const withFamily = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"sister\": (base) => base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n });\n\n it(\"works with .where\", async () => {\n const where = withFamily.where({ \"mom\": 1 });\n const whereResults = await where.fetchPage();\n\n // Checks that if you did an `await where.fetchPage()` that you can then\n // pass/assign it to something explicit.\n const _assignPreviouslyInferredPages: PageResult<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }\n >\n > = whereResults;\n\n // Checks that if you did an `await where.fetchPage()` that you can then\n // pass/assign it to something explicit.\n const _assignPreviouslyInferredInstance: Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }\n > = whereResults.data[0];\n\n const q = whereResults.data[0].$link.peeps.$objectSetInternals.def;\n\n // same as above but with expectTypeOf\n expectTypeOf<typeof where>().toEqualTypeOf<typeof withFamily>();\n expectTypeOf<typeof whereResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }\n >\n >();\n\n // Checks that when you directly assign, it infers correctly.\n // Sometimes an explicit assignment can affect how typescript infers\n // types.\n const shouldBeAssignablePage: PageResult<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }\n >\n > = await where.fetchPage();\n\n const _shouldBeAssignableSingle: Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }\n > = await withFamily.fetchOne(1);\n await withFamily.fetchOne(1);\n });\n\n it(\"works with .async\", () => {\n const asyncIter = withFamily.asyncIter();\n expectTypeOf<typeof asyncIter>().toEqualTypeOf<\n AsyncIterableIterator<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }\n >\n >\n >();\n });\n\n it(\"Works with no select\", async () => {\n const withFamilyResults = await withFamily.fetchPage();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }\n >\n >();\n });\n\n it(\"Works with selecting all RDPs\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"mom\", \"sister\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, never, {\n mom: \"integer\";\n sister: \"string\"[] | undefined;\n }>\n >();\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"mom\"]>()\n .toEqualTypeOf<number>();\n });\n\n it(\"Works with selecting some RDPs\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"mom\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, never, {\n mom: \"integer\";\n }>\n >();\n });\n\n it(\"Works with selecting all non-RDP's\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\n \"employeeId\",\n \"fullName\",\n \"class\",\n \"attachment\",\n \"geopoint\",\n \"timeseries\",\n \"mediaReference\",\n \"geotimeSeriesReference\",\n \"isActive\",\n \"yearsOfExperience\",\n \"rank\",\n \"performanceScore\",\n \"hourlyRate\",\n \"dateOfJoining\",\n \"lastUpdated\",\n ],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n PropertyKeys<EmployeeApiTest>,\n {}\n >\n >();\n expectTypeOf<typeof withFamilyResults[\"data\"][0][\"class\"]>()\n .toEqualTypeOf<\n string | undefined\n >();\n });\n\n it(\"Works with selecting some non-RDP's\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"class\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, \"class\", {}>\n >();\n });\n\n it(\"Works with selecting a mix\", async () => {\n const withFamilyResults = await withFamily.fetchPage({\n $select: [\"class\", \"mom\"],\n });\n\n expectTypeOf<typeof withFamilyResults[\"data\"][0]>()\n .toEqualTypeOf<\n Osdk.Instance<\n EmployeeApiTest,\n never,\n \"class\",\n { mom: \"integer\" }\n >\n >();\n });\n });\n\n it(\"allows extracting the type\", () => {\n const objectSet = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n });\n\n type ObjectSetType = typeof objectSet;\n\n expectTypeOf<ObjectSetType>().toEqualTypeOf<\n $ObjectSet<EmployeeApiTest, {\n mom: \"integer\";\n }>\n >();\n\n const objectSet2 = fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n }) satisfies ObjectSetType;\n });\n\n it(\"Defining the Type\", () => {\n type ObjectSetType = $ObjectSet<\n EmployeeApiTest,\n {\n mom: \"integer\";\n }\n >;\n\n fauxObjectSet.withProperties({\n \"mom\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n }) satisfies ObjectSetType;\n });\n\n it(\"has correct aggregation keys\", () => {\n fauxObjectSet.withProperties({\n \"integer\": (base) => base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"integerNumericAgg\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"employeeId:sum\"),\n \"string\": (base) => base.pivotTo(\"lead\").aggregate(\"class:collectList\"),\n \"stringDoesNotHaveNumericAgg\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"class:sum\"),\n \"isActive\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"isActive:approximateDistinct\"),\n \"attachment\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"attachment:collectList\"),\n \"geopoint\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"geopoint:collectList\"),\n \"numericTimeseries\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"timeseries:sum\"),\n \"numericTimeseriesExactDistinct\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"timeseries:exactDistinct\"),\n \"mediaReference\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"mediaReference:avg\"),\n \"mediaReferenceExactDistinct\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"mediaReference:exactDistinct\"),\n \"geotimeSeriesReference\": (base) =>\n // @ts-expect-error\n base.pivotTo(\"lead\").aggregate(\"geotimeSeriesReference:sum\"),\n \"geotimeSeriesReferenceExactDistinct\": (base) =>\n base.pivotTo(\"lead\").aggregate(\n \"geotimeSeriesReference:exactDistinct\",\n ),\n \"lastUpdated\": (base) => {\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:approximateDistinct\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:exactDistinct\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:max\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:min\");\n base.pivotTo(\"lead\").aggregate(\"lastUpdated:collectList\");\n return base.pivotTo(\"lead\").aggregate(\"lastUpdated:collectSet\");\n },\n \"dateOfJoining\": (base) => {\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:approximateDistinct\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:exactDistinct\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:max\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:min\");\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:collectList\");\n return base.pivotTo(\"lead\").aggregate(\"dateOfJoining:collectSet\");\n },\n });\n });\n\n it(\"has correct aggregation return types\", async () => {\n const aggTestObjectSet = fauxObjectSet.withProperties({\n \"maxHasSameType\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:max\"),\n \"minHasSameType\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"dateOfJoining:min\"),\n \"approximateDistinctNumberNoUndefined\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"employeeId:approximateDistinct\"),\n \"exactDistinctNumberNoUndefined\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"employeeId:exactDistinct\"),\n \"countNumberNoUndefined\": (base) =>\n base.pivotTo(\"lead\").aggregate(\"$count\"),\n \"sumNumber\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:sum\"),\n \"avgNumber\": (base) => base.pivotTo(\"lead\").aggregate(\"employeeId:avg\"),\n }).fetchPage();\n\n const result = (await aggTestObjectSet).data[0];\n expectTypeOf((await aggTestObjectSet).data[0]).toEqualTypeOf<\n Osdk.Instance<EmployeeApiTest, never, PropertyKeys<EmployeeApiTest>, {\n maxHasSameType: \"datetime\" | undefined;\n minHasSameType: \"datetime\" | undefined;\n avgNumber: \"double\" | undefined;\n approximateDistinctNumberNoUndefined: \"integer\";\n exactDistinctNumberNoUndefined: \"integer\";\n countNumberNoUndefined: \"integer\";\n sumNumber: \"double\" | undefined;\n }>\n >();\n\n expectTypeOf(result.maxHasSameType).toEqualTypeOf<string | undefined>();\n expectTypeOf(result.minHasSameType).toEqualTypeOf<string | undefined>();\n expectTypeOf(result.approximateDistinctNumberNoUndefined).toEqualTypeOf<\n number\n >();\n expectTypeOf(result.exactDistinctNumberNoUndefined).toEqualTypeOf<\n number\n >();\n expectTypeOf(result.countNumberNoUndefined).toEqualTypeOf<number>();\n expectTypeOf(result.sumNumber).toEqualTypeOf<number | undefined>();\n expectTypeOf(result.avgNumber).toEqualTypeOf<number | undefined>();\n });\n\n it(\"Merged object type is equivalent to original\", () => {\n const a = {} as EmployeeApiTest;\n let b = {} as DerivedObjectOrInterfaceDefinition.WithDerivedProperties<\n EmployeeApiTest,\n {}\n >;\n\n b = a; // should be assignable. testing explicitly due to break in 2.2 release.\n\n expectTypeOf<\n EmployeeApiTest\n >().branded.toEqualTypeOf<\n DerivedObjectOrInterfaceDefinition.WithDerivedProperties<\n EmployeeApiTest,\n {}\n >\n >();\n });\n });\n describe(\"aggregate\", () => {\n it(\"has correct aggregation keys\", () => {\n void fauxObjectSet.aggregate({\n \"$select\": {\n \"lastUpdated:max\": \"asc\",\n \"lastUpdated:min\": \"desc\",\n \"lastUpdated:approximateDistinct\": \"asc\",\n \"lastUpdated:exactDistinct\": \"desc\",\n \"dateOfJoining:max\": \"desc\",\n \"dateOfJoining:min\": \"asc\",\n \"dateOfJoining:approximateDistinct\": \"asc\",\n \"dateOfJoining:exactDistinct\": \"desc\",\n },\n });\n });\n });\n});\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,QAAQ,EAAEC,YAAY,EAAEC,EAAE,EAAEC,IAAI,EAAEC,EAAE,QAAQ,QAAQ;AAa7D,OAAO,SAASC,mBAAmBA,CAAA,EAET;EACxB,IAAIC,UAA4B,EAC9BC,WAAgB,EAChBC,aAA4B;;EAE9B;EACAF,UAAU,GAAG;IACXG,KAAK,EAAE;MACLC,KAAK,EAAE;QACLC,mBAAmB,EAAE;UACnBC,GAAG,EAAE,CAAC;QACR;MACF;IACF;EACF,CAAqB;EAErBL,WAAW,GAAG;IACZM,IAAI,EAAE,CAACP,UAAU;EACnB,CAAC;EAEDE,aAAa,GAAG;IACdM,KAAK,EAAEV,EAAE,CAACW,EAAE,CAAC,MAAM;MACjB,OAAOP,aAAa;IACtB,CAAC,CAAC;IACFQ,cAAc,EAAEZ,EAAE,CAACW,EAAE,CAAC,MAAM;MAC1B,OAAOP,aAAa;IACtB,CAAC,CAAC;IACFS,SAAS,EAAEb,EAAE,CAACW,EAAE,CAAC,MAAMG,OAAO,CAACC,OAAO,CAACZ,WAAW,CAAC,CAAC;IAC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","ignoreList":[]}
|
|
@@ -52,13 +52,6 @@ interface MediaReference {
|
|
|
52
52
|
};
|
|
53
53
|
};
|
|
54
54
|
}
|
|
55
|
-
/**
|
|
56
|
-
* Object for uploading Media
|
|
57
|
-
*/
|
|
58
|
-
interface MediaUpload {
|
|
59
|
-
readonly path: string;
|
|
60
|
-
readonly data: Blob;
|
|
61
|
-
}
|
|
62
55
|
/**
|
|
63
56
|
* Metadata of a media item
|
|
64
57
|
*/
|
|
@@ -958,80 +951,36 @@ type WhereClause<T extends ObjectOrInterfaceDefinition> = OrWhereClause<T> | And
|
|
|
958
951
|
type LinkNames<Q extends ObjectOrInterfaceDefinition> = keyof CompileTimeMetadata<Q>["links"] & string;
|
|
959
952
|
type LinkedType<Q extends ObjectOrInterfaceDefinition, L extends LinkNames<Q>> = NonNullable<CompileTimeMetadata<Q>["links"][L]["__OsdkLinkTargetType"]>;
|
|
960
953
|
|
|
961
|
-
type WithPropertiesNumerics = "integer" | "double" | "float" | "short" | "long";
|
|
962
|
-
type WithPropertiesDatetime = "datetime" | "timestamp";
|
|
963
|
-
type DefinitionForType<Q extends ObjectOrInterfaceDefinition, T extends SimplePropertyDef> = SimplePropertyDef.ExtractMultiplicity<T> extends "array" ? DerivedProperty.Definition<T, Q> : SimplePropertyDef.ExtractWirePropertyType<T> extends WithPropertiesNumerics ? DerivedProperty.NumericPropertyDefinition<T, Q> : SimplePropertyDef.ExtractWirePropertyType<T> extends WithPropertiesDatetime ? DerivedProperty.DatetimePropertyDefinition<T, Q> : DerivedProperty.Definition<T, Q>;
|
|
964
|
-
type NumericExpressionArg<Q extends ObjectOrInterfaceDefinition> = number | DerivedProperty.NumericPropertyDefinition<any, Q>;
|
|
965
|
-
type ReturnTypeForNumericMethod<Q extends ObjectOrInterfaceDefinition, LEFT extends WirePropertyTypes, RIGHT extends WirePropertyTypes> = "double" extends (LEFT | RIGHT) ? DerivedProperty.NumericPropertyDefinition<SimplePropertyDef.Make<"double", "non-nullable", "single">, Q> : "float" extends (LEFT | RIGHT) ? DerivedProperty.NumericPropertyDefinition<SimplePropertyDef.Make<"double", "non-nullable", "single">, Q> : "long" extends (LEFT | RIGHT) ? DerivedProperty.NumericPropertyDefinition<SimplePropertyDef.Make<"long", "non-nullable", "single">, Q> : DerivedProperty.NumericPropertyDefinition<SimplePropertyDef.Make<"integer", "non-nullable", "single">, Q>;
|
|
966
|
-
type ReturnTypeForDatetimeMethod<Q extends ObjectOrInterfaceDefinition, LEFT extends WirePropertyTypes, RIGHT extends WirePropertyTypes> = "timestamp" extends (LEFT | RIGHT) ? DerivedProperty.DatetimePropertyDefinition<SimplePropertyDef.Make<"timestamp", "non-nullable", "single">, Q> : DerivedProperty.DatetimePropertyDefinition<SimplePropertyDef.Make<"datetime", "non-nullable", "single">, Q>;
|
|
967
|
-
type ExtractWirePropertyTypeFromNumericArg<Q extends ObjectOrInterfaceDefinition, ARG extends NumericExpressionArg<Q>> = ARG extends number ? "double" : ARG extends DerivedProperty.NumericPropertyDefinition<infer T, Q> ? T extends SimplePropertyDef ? SimplePropertyDef.ExtractWirePropertyType<T> : never : ARG extends PropertyKeys.Filtered<Q, WithPropertiesNumerics> ? NonNullable<CompileTimeMetadata<Q>["properties"][ARG]["type"]> : never;
|
|
968
|
-
type NumericExpressions<Q extends ObjectOrInterfaceDefinition, LEFT_PROPERTY_TYPE extends SimplePropertyDef> = {
|
|
969
|
-
readonly add: <A extends NumericExpressionArg<Q>>(value: A) => ReturnTypeForNumericMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractWirePropertyTypeFromNumericArg<Q, A>>;
|
|
970
|
-
readonly subtract: <A extends NumericExpressionArg<Q>>(value: A) => ReturnTypeForNumericMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractWirePropertyTypeFromNumericArg<Q, A>>;
|
|
971
|
-
readonly multiply: <A extends NumericExpressionArg<Q>>(value: A) => ReturnTypeForNumericMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractWirePropertyTypeFromNumericArg<Q, A>>;
|
|
972
|
-
readonly divide: <A extends NumericExpressionArg<Q>>(value: A) => ReturnTypeForNumericMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractWirePropertyTypeFromNumericArg<Q, A>>;
|
|
973
|
-
readonly abs: () => DerivedProperty.NumericPropertyDefinition<LEFT_PROPERTY_TYPE, Q>;
|
|
974
|
-
readonly negate: () => DerivedProperty.NumericPropertyDefinition<LEFT_PROPERTY_TYPE, Q>;
|
|
975
|
-
readonly max: <A extends NumericExpressionArg<Q>>(value: A) => ReturnTypeForNumericMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractWirePropertyTypeFromNumericArg<Q, A>>;
|
|
976
|
-
readonly min: <A extends NumericExpressionArg<Q>>(value: A) => ReturnTypeForNumericMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractWirePropertyTypeFromNumericArg<Q, A>>;
|
|
977
|
-
};
|
|
978
|
-
type DatetimeExpressionArg<Q extends ObjectOrInterfaceDefinition> = DerivedProperty.DatetimePropertyDefinition<any, Q>;
|
|
979
|
-
type ExtractPropertyTypeFromDatetimeArg<Q extends ObjectOrInterfaceDefinition, ARG extends DatetimeExpressionArg<Q>> = ARG extends DerivedProperty.DatetimePropertyDefinition<infer T, Q> ? T extends SimplePropertyDef ? SimplePropertyDef.ExtractWirePropertyType<T> : never : ARG extends PropertyKeys.Filtered<Q, WithPropertiesDatetime> ? NonNullable<CompileTimeMetadata<Q>["properties"][ARG]["type"]> : never;
|
|
980
|
-
type DatetimeExpressions<Q extends ObjectOrInterfaceDefinition, LEFT_PROPERTY_TYPE extends SimplePropertyDef> = {
|
|
981
|
-
readonly min: <A extends DatetimeExpressionArg<Q>>(value: A) => ReturnTypeForDatetimeMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractPropertyTypeFromDatetimeArg<Q, A>>;
|
|
982
|
-
readonly max: (value: DatetimeExpressionArg<Q>) => ReturnTypeForDatetimeMethod<Q, SimplePropertyDef.ExtractWirePropertyType<LEFT_PROPERTY_TYPE>, ExtractPropertyTypeFromDatetimeArg<Q, typeof value>>;
|
|
983
|
-
readonly extractPart: (value: DerivedProperty.ValidParts) => DerivedProperty.Definition<SimplePropertyDef.Make<"string", "non-nullable", "single">, Q>;
|
|
984
|
-
};
|
|
985
|
-
|
|
986
954
|
declare const DerivedPropertyDefinitionBrand: unique symbol;
|
|
987
955
|
declare namespace DerivedProperty {
|
|
988
956
|
export interface Definition<T extends SimplePropertyDef, Q extends ObjectOrInterfaceDefinition> {
|
|
989
957
|
readonly [DerivedPropertyDefinitionBrand]: true;
|
|
990
958
|
}
|
|
991
|
-
export interface NumericPropertyDefinition<T extends SimplePropertyDef, Q extends ObjectOrInterfaceDefinition> extends Definition<T, Q>, NumericExpressions<Q, T> {
|
|
992
|
-
}
|
|
993
|
-
export interface DatetimePropertyDefinition<T extends SimplePropertyDef, Q extends ObjectOrInterfaceDefinition> extends Definition<T, Q>, DatetimeExpressions<Q, T> {
|
|
994
|
-
}
|
|
995
959
|
export type Clause<Q extends ObjectOrInterfaceDefinition> = {
|
|
996
960
|
[key: string]: DerivedPropertyCreator<Q, SimplePropertyDef>;
|
|
997
961
|
};
|
|
998
962
|
interface BaseBuilder<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> extends Filterable<Q, CONSTRAINED>, Pivotable<Q, CONSTRAINED> {
|
|
999
963
|
}
|
|
1000
|
-
export interface Builder<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> extends BaseBuilder<Q, CONSTRAINED
|
|
964
|
+
export interface Builder<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> extends BaseBuilder<Q, CONSTRAINED> {
|
|
1001
965
|
}
|
|
1002
966
|
export interface AggregateBuilder<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> extends BaseBuilder<Q, CONSTRAINED>, Aggregatable<Q> {
|
|
1003
967
|
}
|
|
1004
|
-
export interface SelectPropertyBuilder<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> extends AggregateBuilder<Q, CONSTRAINED>, Selectable<Q> {
|
|
1005
|
-
}
|
|
1006
|
-
export type ValidParts = "DAYS" | "MONTHS" | "QUARTERS" | "YEARS";
|
|
1007
968
|
export { };
|
|
1008
969
|
}
|
|
1009
|
-
type DerivedPropertyCreator<Q extends ObjectOrInterfaceDefinition, T extends SimplePropertyDef> = (baseObjectSet: DerivedProperty.Builder<Q, false>) => DerivedProperty.Definition<T, Q
|
|
1010
|
-
type BuilderTypeFromConstraint<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> = CONSTRAINED extends true ? DerivedProperty.AggregateBuilder<Q, true> : DerivedProperty.
|
|
970
|
+
type DerivedPropertyCreator<Q extends ObjectOrInterfaceDefinition, T extends SimplePropertyDef> = (baseObjectSet: DerivedProperty.Builder<Q, false>) => DerivedProperty.Definition<T, Q>;
|
|
971
|
+
type BuilderTypeFromConstraint<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> = CONSTRAINED extends true ? DerivedProperty.AggregateBuilder<Q, true> : DerivedProperty.AggregateBuilder<Q, false>;
|
|
1011
972
|
type Filterable<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> = {
|
|
1012
973
|
readonly where: (clause: WhereClause<Q>) => BuilderTypeFromConstraint<Q, CONSTRAINED>;
|
|
1013
974
|
};
|
|
1014
975
|
type Pivotable<Q extends ObjectOrInterfaceDefinition, CONSTRAINED extends boolean> = {
|
|
1015
|
-
readonly pivotTo: <L extends LinkNames<Q>>(type: L) => CONSTRAINED extends true ? DerivedProperty.AggregateBuilder<LinkedType<Q, L>, true> : NonNullable<CompileTimeMetadata<Q>["links"][L]["multiplicity"]> extends true ? DerivedProperty.AggregateBuilder<LinkedType<Q, L>, true> : DerivedProperty.
|
|
1016
|
-
};
|
|
1017
|
-
type Constant<Q extends ObjectOrInterfaceDefinition> = {
|
|
1018
|
-
readonly constant: {
|
|
1019
|
-
readonly double: (value: number) => DerivedProperty.NumericPropertyDefinition<SimplePropertyDef.Make<"double", "non-nullable", "single">, Q>;
|
|
1020
|
-
readonly integer: (value: number) => DerivedProperty.NumericPropertyDefinition<SimplePropertyDef.Make<"integer", "non-nullable", "single">, Q>;
|
|
1021
|
-
readonly long: (value: string) => DerivedProperty.NumericPropertyDefinition<SimplePropertyDef.Make<"long", "non-nullable", "single">, Q>;
|
|
1022
|
-
readonly datetime: (value: string) => DerivedProperty.DatetimePropertyDefinition<SimplePropertyDef.Make<"datetime", "non-nullable", "single">, Q>;
|
|
1023
|
-
readonly timestamp: (value: string) => DerivedProperty.DatetimePropertyDefinition<SimplePropertyDef.Make<"timestamp", "non-nullable", "single">, Q>;
|
|
1024
|
-
};
|
|
976
|
+
readonly pivotTo: <L extends LinkNames<Q>>(type: L) => CONSTRAINED extends true ? DerivedProperty.AggregateBuilder<LinkedType<Q, L>, true> : NonNullable<CompileTimeMetadata<Q>["links"][L]["multiplicity"]> extends true ? DerivedProperty.AggregateBuilder<LinkedType<Q, L>, true> : DerivedProperty.AggregateBuilder<LinkedType<Q, L>, false>;
|
|
1025
977
|
};
|
|
1026
978
|
type Aggregatable<Q extends ObjectOrInterfaceDefinition> = {
|
|
1027
979
|
readonly aggregate: <V extends ValidAggregationKeys<Q, "withPropertiesAggregate">>(aggregationSpecifier: V, opts?: V extends `${any}:${infer P}` ? P extends CollectWithPropAggregations ? {
|
|
1028
980
|
limit: number;
|
|
1029
981
|
} : P extends "approximatePercentile" ? {
|
|
1030
982
|
percentile: number;
|
|
1031
|
-
} : never : never) =>
|
|
1032
|
-
};
|
|
1033
|
-
type Selectable<Q extends ObjectOrInterfaceDefinition> = {
|
|
1034
|
-
readonly selectProperty: <R extends PropertyKeys<Q>>(propertyName: R) => DefinitionForType<Q, SimplePropertyDef.Make<CompileTimeMetadata<Q>["properties"][R]["type"], CompileTimeMetadata<Q>["properties"][R]["nullable"] extends true ? "nullable" : "non-nullable", CompileTimeMetadata<Q>["properties"][R]["multiplicity"] extends true ? "array" : "single">>;
|
|
983
|
+
} : never : never) => DerivedProperty.Definition<V extends `${infer N}:${infer P}` ? P extends CollectWithPropAggregations ? SimplePropertyDef.Make<CompileTimeMetadata<Q>["properties"][N]["type"], "nullable", "array"> : P extends MinMaxWithPropAggregateOption ? SimplePropertyDef.Make<CompileTimeMetadata<Q>["properties"][N]["type"], "nullable", "single"> : P extends "approximateDistinct" | "exactDistinct" ? SimplePropertyDef.Make<"integer", "non-nullable", "single"> : SimplePropertyDef.Make<"double", "nullable", "single"> : V extends "$count" ? SimplePropertyDef.Make<"integer", "non-nullable", "single"> : never, Q>;
|
|
1035
984
|
};
|
|
1036
985
|
|
|
1037
986
|
interface BaseObjectSet<Q extends ObjectOrInterfaceDefinition> {
|
|
@@ -1280,4 +1229,4 @@ interface Subscribe<Q extends ObjectOrInterfaceDefinition> {
|
|
|
1280
1229
|
interface ObjectSetCleanedTypes<Q extends ObjectOrInterfaceDefinition, D extends Record<string, SimplePropertyDef>, MERGED extends ObjectOrInterfaceDefinition & Q> extends MinimalObjectSet<Q, D>, WithProperties<Q, D>, Aggregate<MERGED>, SetArithmetic<MERGED>, PivotTo<Q>, FetchOne<Q, D>, Subscribe<MERGED> {
|
|
1281
1230
|
}
|
|
1282
1231
|
|
|
1283
|
-
export {
|
|
1232
|
+
export { type ObjectSpecifier as $, type AttachmentUpload as A, type SelectArg as B, type CompileTimeMetadata as C, DistanceUnitMapping as D, type SelectArgToKeys as E, type FetchPageArgs as F, type GeoFilterOptions as G, type FetchPageResult as H, type InterfaceDefinition as I, type SingleOsdkResult as J, type Media as K, type MediaMetadata as L, type MediaReference as M, NullabilityAdherence as N, type ObjectTypeDefinition as O, type PropertyValueWireToClient as P, isOk as Q, type ReleaseStatus as R, type SingleLinkAccessor as S, type Result as T, type BaseObjectSet as U, type ValidAggregationKeys as V, type WhereClause as W, ObjectSetSubscription as X, type InterfaceMetadata as Y, type ObjectOrInterfaceDefinition as Z, PropertyKeys as _, type Attachment as a, ObjectMetadata as a0, type PropertyDef as a1, type VersionBound as a2, type BaseWirePropertyTypes as a3, type WirePropertyTypes as a4, type PrimaryKeyType as a5, type ConvertProps as a6, Osdk as a7, type PageResult as a8, TimeseriesDurationMapping as a9, type GeotimeSeriesProperty as aa, type TimeSeriesPoint as ab, type TimeSeriesProperty as ac, type TimeSeriesQuery as ad, type LinkedType as ae, type LinkNames as af, type ExtractOptions as ag, type MinimalObjectSet as ah, type ObjectIdentifiers as b, type OsdkObjectPrimaryKeyType as c, type ObjectSet as d, type OsdkMetadata as e, type PrimaryKeyTypes as f, type OsdkBase as g, type AggregateOpts as h, type AggregateOptsThatErrorsAndDisallowsOrderingWithMultipleGroupBy as i, type AggregationResultsWithGroups as j, type AggregationResultsWithoutGroups as k, type AggregationClause as l, type AggregationsResults as m, type GeoFilter_Intersects as n, type GeoFilter_Within as o, type PossibleWhereClauseFilters as p, type OsdkObjectPropertyType as q, type OsdkObjectLinksObject as r, DerivedProperty as s, DurationMapping as t, type AllGroupByValues as u, type GroupByClause as v, type GroupByRange as w, type AsyncIterArgs as x, type Augment as y, type Augments as z };
|
package/build/cjs/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as AttachmentUpload, M as MediaReference, a as
|
|
2
|
-
export {
|
|
1
|
+
import { A as AttachmentUpload, M as MediaReference, a as Attachment, O as ObjectTypeDefinition, b as ObjectIdentifiers, c as OsdkObjectPrimaryKeyType, d as ObjectSet, I as InterfaceDefinition, C as CompileTimeMetadata, e as OsdkMetadata, R as ReleaseStatus, P as PropertyValueWireToClient, f as PrimaryKeyTypes, g as OsdkBase } from './ObjectSet-C3Ud9v-e.cjs';
|
|
2
|
+
export { h as AggregateOpts, i as AggregateOptsThatErrorsAndDisallowsOrderingWithMultipleGroupBy, l as AggregationClause, j as AggregationResultsWithGroups, k as AggregationResultsWithoutGroups, m as AggregationsResults, u as AllGroupByValues, x as AsyncIterArgs, y as Augment, z as Augments, U as BaseObjectSet, a3 as BaseWirePropertyTypes, a6 as ConvertProps, s as DerivedProperty, D as DistanceUnitMapping, t as DurationMapping, F as FetchPageArgs, H as FetchPageResult, G as GeoFilterOptions, n as GeoFilter_Intersects, o as GeoFilter_Within, aa as GeotimeSeriesProperty, v as GroupByClause, w as GroupByRange, Y as InterfaceMetadata, af as LinkNames, ae as LinkedType, K as Media, L as MediaMetadata, N as NullabilityAdherence, a0 as ObjectMetadata, Z as ObjectOrInterfaceDefinition, X as ObjectSetSubscription, $ as ObjectSpecifier, a7 as Osdk, r as OsdkObjectLinksObject, q as OsdkObjectPropertyType, a8 as PageResult, p as PossibleWhereClauseFilters, a5 as PrimaryKeyType, a1 as PropertyDef, _ as PropertyKeys, T as Result, B as SelectArg, E as SelectArgToKeys, S as SingleLinkAccessor, J as SingleOsdkResult, ab as TimeSeriesPoint, ac as TimeSeriesProperty, ad as TimeSeriesQuery, a9 as TimeseriesDurationMapping, V as ValidAggregationKeys, a2 as VersionBound, W as WhereClause, a4 as WirePropertyTypes, Q as isOk } from './ObjectSet-C3Ud9v-e.cjs';
|
|
3
3
|
import 'type-fest';
|
|
4
4
|
import 'geojson';
|
|
5
5
|
|
|
@@ -62,7 +62,7 @@ interface DataValueClientToWire {
|
|
|
62
62
|
string: string;
|
|
63
63
|
timestamp: string;
|
|
64
64
|
set: Set<any>;
|
|
65
|
-
mediaReference: MediaReference
|
|
65
|
+
mediaReference: MediaReference;
|
|
66
66
|
twoDimensionalAggregation: {
|
|
67
67
|
key: AllowedBucketKeyTypes$1;
|
|
68
68
|
value: AllowedBucketTypes$1;
|
|
@@ -447,4 +447,4 @@ declare namespace Logger {
|
|
|
447
447
|
}
|
|
448
448
|
}
|
|
449
449
|
|
|
450
|
-
export { type ActionDefinition, type ActionEditResponse, ActionMetadata, ActionParam, type ActionReturnTypeForOptions, type ActionValidationResponse, type AllowedBucketKeyTypes$1 as AllowedBucketKeyTypes, type AllowedBucketTypes$1 as AllowedBucketTypes, type ApplyActionOptions, type ApplyBatchActionOptions, Attachment, AttachmentUpload, CompileTimeMetadata, type DataValueClientToWire, type DataValueWireToClient, InterfaceDefinition, Logger, MediaReference,
|
|
450
|
+
export { type ActionDefinition, type ActionEditResponse, ActionMetadata, ActionParam, type ActionReturnTypeForOptions, type ActionValidationResponse, type AllowedBucketKeyTypes$1 as AllowedBucketKeyTypes, type AllowedBucketTypes$1 as AllowedBucketTypes, type ApplyActionOptions, type ApplyBatchActionOptions, Attachment, AttachmentUpload, CompileTimeMetadata, type DataValueClientToWire, type DataValueWireToClient, InterfaceDefinition, Logger, MediaReference, ObjectIdentifiers, type ObjectQueryDataType, type ObjectSet, type ObjectSetQueryDataType, ObjectTypeDefinition, type OntologyMetadata, OsdkBase, type OsdkObject, PrimaryKeyTypes, PropertyValueWireToClient, type QueryDataTypeDefinition, type QueryDefinition, type QueryMetadata, QueryParam, type QueryParameterDefinition, QueryResult, type Range, type ThreeDimensionalAggregation, type ThreeDimensionalQueryAggregationDefinition, type TwoDimensionalAggregation, type TwoDimensionalQueryAggregationDefinition };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export {
|
|
1
|
+
import { Z as ObjectOrInterfaceDefinition, _ as PropertyKeys, M as MediaReference, O as ObjectTypeDefinition, N as NullabilityAdherence, B as SelectArg, a7 as Osdk, ag as ExtractOptions, F as FetchPageArgs, H as FetchPageResult, g as OsdkBase } from '../ObjectSet-C3Ud9v-e.cjs';
|
|
2
|
+
export { ah as MinimalObjectSet } from '../ObjectSet-C3Ud9v-e.cjs';
|
|
3
3
|
import 'type-fest';
|
|
4
4
|
import 'geojson';
|
|
5
5
|
|
|
@@ -13,5 +13,20 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
export let DerivedProperty;
|
|
16
|
+
export let DerivedProperty; // type Selectable<Q extends ObjectOrInterfaceDefinition> = {
|
|
17
|
+
// readonly selectProperty: <R extends PropertyKeys<Q>>(
|
|
18
|
+
// propertyName: R,
|
|
19
|
+
// ) => DefinitionForType<
|
|
20
|
+
// Q,
|
|
21
|
+
// SimplePropertyDef.Make<
|
|
22
|
+
// CompileTimeMetadata<Q>["properties"][R]["type"],
|
|
23
|
+
// CompileTimeMetadata<Q>["properties"][R]["nullable"] extends true
|
|
24
|
+
// ? "nullable"
|
|
25
|
+
// : "non-nullable",
|
|
26
|
+
// CompileTimeMetadata<Q>["properties"][R]["multiplicity"] extends true
|
|
27
|
+
// ? "array"
|
|
28
|
+
// : "single"
|
|
29
|
+
// >
|
|
30
|
+
// >;
|
|
31
|
+
// };
|
|
17
32
|
//# sourceMappingURL=DerivedProperty.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DerivedProperty.js","names":["DerivedProperty"],"sources":["DerivedProperty.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { ValidAggregationKeys } from \"../aggregate/AggregatableKeys.js\";\nimport type { WhereClause } from \"../aggregate/WhereClause.js\";\nimport type {\n ObjectOrInterfaceDefinition,\n
|
|
1
|
+
{"version":3,"file":"DerivedProperty.js","names":["DerivedProperty"],"sources":["DerivedProperty.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { ValidAggregationKeys } from \"../aggregate/AggregatableKeys.js\";\nimport type { WhereClause } from \"../aggregate/WhereClause.js\";\nimport type {\n ObjectOrInterfaceDefinition,\n} from \"../ontology/ObjectOrInterface.js\";\nimport type { CompileTimeMetadata } from \"../ontology/ObjectTypeDefinition.js\";\nimport type { SimplePropertyDef } from \"../ontology/SimplePropertyDef.js\";\nimport type { LinkedType, LinkNames } from \"../util/LinkUtils.js\";\nimport type {\n CollectWithPropAggregations,\n MinMaxWithPropAggregateOption,\n} from \"./WithPropertiesAggregationOptions.js\";\n\ndeclare const DerivedPropertyDefinitionBrand: unique symbol;\n\nexport namespace DerivedProperty {\n export interface Definition<\n T extends SimplePropertyDef,\n Q extends ObjectOrInterfaceDefinition,\n > {\n readonly [DerivedPropertyDefinitionBrand]: true;\n }\n\n export type Clause<\n Q extends ObjectOrInterfaceDefinition,\n > = {\n [key: string]: DerivedPropertyCreator<Q, SimplePropertyDef>;\n };\n\n interface BaseBuilder<\n Q extends ObjectOrInterfaceDefinition,\n CONSTRAINED extends boolean,\n > extends Filterable<Q, CONSTRAINED>, Pivotable<Q, CONSTRAINED> {\n }\n\n export interface Builder<\n Q extends ObjectOrInterfaceDefinition,\n CONSTRAINED extends boolean,\n > extends BaseBuilder<Q, CONSTRAINED> {\n }\n\n export interface AggregateBuilder<\n Q extends ObjectOrInterfaceDefinition,\n CONSTRAINED extends boolean,\n > extends BaseBuilder<Q, CONSTRAINED>, Aggregatable<Q> {\n }\n\n // export interface SelectPropertyBuilder<\n // Q extends ObjectOrInterfaceDefinition,\n // CONSTRAINED extends boolean,\n // > extends AggregateBuilder<Q, CONSTRAINED> {\n // }\n}\n\nexport type DerivedPropertyCreator<\n Q extends ObjectOrInterfaceDefinition,\n T extends SimplePropertyDef,\n> = (\n baseObjectSet: DerivedProperty.Builder<Q, false>,\n) => DerivedProperty.Definition<T, Q>;\n\ntype BuilderTypeFromConstraint<\n Q extends ObjectOrInterfaceDefinition,\n CONSTRAINED extends boolean,\n> = CONSTRAINED extends true ? DerivedProperty.AggregateBuilder<Q, true>\n : DerivedProperty.AggregateBuilder<Q, false>;\n\ntype Filterable<\n Q extends ObjectOrInterfaceDefinition,\n CONSTRAINED extends boolean,\n> = {\n readonly where: (\n clause: WhereClause<Q>,\n ) => BuilderTypeFromConstraint<Q, CONSTRAINED>;\n};\n\ntype Pivotable<\n Q extends ObjectOrInterfaceDefinition,\n CONSTRAINED extends boolean,\n> = {\n readonly pivotTo: <L extends LinkNames<Q>>(\n type: L,\n ) => CONSTRAINED extends true\n ? DerivedProperty.AggregateBuilder<LinkedType<Q, L>, true>\n : NonNullable<CompileTimeMetadata<Q>[\"links\"][L][\"multiplicity\"]> extends\n true ? DerivedProperty.AggregateBuilder<LinkedType<Q, L>, true>\n : DerivedProperty.AggregateBuilder<LinkedType<Q, L>, false>;\n};\n\ntype Aggregatable<\n Q extends ObjectOrInterfaceDefinition,\n> = {\n readonly aggregate: <\n V extends ValidAggregationKeys<\n Q,\n \"withPropertiesAggregate\"\n >,\n >(\n aggregationSpecifier: V,\n opts?: V extends `${any}:${infer P}`\n ? P extends CollectWithPropAggregations ? { limit: number }\n : P extends \"approximatePercentile\" ? { percentile: number }\n : never\n : never,\n ) => DerivedProperty.Definition<\n V extends `${infer N}:${infer P}`\n ? P extends CollectWithPropAggregations ? SimplePropertyDef.Make<\n CompileTimeMetadata<Q>[\"properties\"][N][\"type\"],\n \"nullable\",\n \"array\"\n >\n : P extends MinMaxWithPropAggregateOption ? SimplePropertyDef.Make<\n CompileTimeMetadata<Q>[\"properties\"][N][\"type\"],\n \"nullable\",\n \"single\"\n >\n : P extends \"approximateDistinct\" | \"exactDistinct\"\n ? SimplePropertyDef.Make<\n \"integer\",\n \"non-nullable\",\n \"single\"\n >\n : SimplePropertyDef.Make<\n \"double\",\n \"nullable\",\n \"single\"\n >\n : V extends \"$count\" ? SimplePropertyDef.Make<\n \"integer\",\n \"non-nullable\",\n \"single\"\n >\n : never,\n Q\n >;\n};\n\n// type Selectable<Q extends ObjectOrInterfaceDefinition> = {\n// readonly selectProperty: <R extends PropertyKeys<Q>>(\n// propertyName: R,\n// ) => DefinitionForType<\n// Q,\n// SimplePropertyDef.Make<\n// CompileTimeMetadata<Q>[\"properties\"][R][\"type\"],\n// CompileTimeMetadata<Q>[\"properties\"][R][\"nullable\"] extends true\n// ? \"nullable\"\n// : \"non-nullable\",\n// CompileTimeMetadata<Q>[\"properties\"][R][\"multiplicity\"] extends true\n// ? \"array\"\n// : \"single\"\n// >\n// >;\n// };\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAdA,WA+BiBA,eAAe,EA0HhC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","ignoreList":[]}
|
package/build/esm/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["DistanceUnitMapping","DurationMapping","isOk","TimeseriesDurationMapping"],"sources":["index.ts"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport type { ActionReturnTypeForOptions } from \"./actions/ActionReturnTypeForOptions.js\";\nexport type {\n ActionEditResponse,\n ActionParam,\n ActionValidationResponse,\n ApplyActionOptions,\n ApplyBatchActionOptions,\n} from \"./actions/Actions.js\";\nexport type { ValidAggregationKeys } from \"./aggregate/AggregatableKeys.js\";\nexport type { AggregateOpts } from \"./aggregate/AggregateOpts.js\";\nexport type { AggregateOptsThatErrorsAndDisallowsOrderingWithMultipleGroupBy } from \"./aggregate/AggregateOptsThatErrors.js\";\nexport type { AggregationResultsWithGroups } from \"./aggregate/AggregationResultsWithGroups.js\";\nexport type { AggregationResultsWithoutGroups } from \"./aggregate/AggregationResultsWithoutGroups.js\";\nexport type { AggregationClause } from \"./aggregate/AggregationsClause.js\";\nexport type { AggregationsResults } from \"./aggregate/AggregationsResults.js\";\nexport type { GeoFilterOptions } from \"./aggregate/GeoFilter.js\";\nexport { DistanceUnitMapping } from \"./aggregate/WhereClause.js\";\nexport type {\n GeoFilter_Intersects,\n GeoFilter_Within,\n PossibleWhereClauseFilters,\n WhereClause,\n} from \"./aggregate/WhereClause.js\";\nexport type { OsdkObjectPropertyType } from \"./Definitions.js\";\nexport type {\n OsdkObjectLinksObject,\n SingleLinkAccessor,\n} from \"./definitions/LinkDefinitions.js\";\nexport type { DerivedProperty } from \"./derivedProperties/DerivedProperty.js\";\nexport { DurationMapping } from \"./groupby/GroupByClause.js\";\nexport type {\n AllGroupByValues,\n GroupByClause,\n GroupByRange,\n} from \"./groupby/GroupByClause.js\";\nexport type {\n AllowedBucketKeyTypes,\n AllowedBucketTypes,\n DataValueClientToWire,\n DataValueWireToClient,\n} from \"./mapping/DataValueMapping.js\";\nexport type {\n PropertyValueWireToClient,\n} from \"./mapping/PropertyValueMapping.js\";\nexport type { Attachment, AttachmentUpload } from \"./object/Attachment.js\";\nexport type {\n AsyncIterArgs,\n Augment,\n Augments,\n FetchPageArgs,\n NullabilityAdherence,\n SelectArg,\n SelectArgToKeys,\n} from \"./object/FetchPageArgs.js\";\nexport type {\n FetchPageResult,\n SingleOsdkResult,\n} from \"./object/FetchPageResult.js\";\nexport type {
|
|
1
|
+
{"version":3,"file":"index.js","names":["DistanceUnitMapping","DurationMapping","isOk","TimeseriesDurationMapping"],"sources":["index.ts"],"sourcesContent":["/*\n * Copyright 2023 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport type { ActionReturnTypeForOptions } from \"./actions/ActionReturnTypeForOptions.js\";\nexport type {\n ActionEditResponse,\n ActionParam,\n ActionValidationResponse,\n ApplyActionOptions,\n ApplyBatchActionOptions,\n} from \"./actions/Actions.js\";\nexport type { ValidAggregationKeys } from \"./aggregate/AggregatableKeys.js\";\nexport type { AggregateOpts } from \"./aggregate/AggregateOpts.js\";\nexport type { AggregateOptsThatErrorsAndDisallowsOrderingWithMultipleGroupBy } from \"./aggregate/AggregateOptsThatErrors.js\";\nexport type { AggregationResultsWithGroups } from \"./aggregate/AggregationResultsWithGroups.js\";\nexport type { AggregationResultsWithoutGroups } from \"./aggregate/AggregationResultsWithoutGroups.js\";\nexport type { AggregationClause } from \"./aggregate/AggregationsClause.js\";\nexport type { AggregationsResults } from \"./aggregate/AggregationsResults.js\";\nexport type { GeoFilterOptions } from \"./aggregate/GeoFilter.js\";\nexport { DistanceUnitMapping } from \"./aggregate/WhereClause.js\";\nexport type {\n GeoFilter_Intersects,\n GeoFilter_Within,\n PossibleWhereClauseFilters,\n WhereClause,\n} from \"./aggregate/WhereClause.js\";\nexport type { OsdkObjectPropertyType } from \"./Definitions.js\";\nexport type {\n OsdkObjectLinksObject,\n SingleLinkAccessor,\n} from \"./definitions/LinkDefinitions.js\";\nexport type { DerivedProperty } from \"./derivedProperties/DerivedProperty.js\";\nexport { DurationMapping } from \"./groupby/GroupByClause.js\";\nexport type {\n AllGroupByValues,\n GroupByClause,\n GroupByRange,\n} from \"./groupby/GroupByClause.js\";\nexport type {\n AllowedBucketKeyTypes,\n AllowedBucketTypes,\n DataValueClientToWire,\n DataValueWireToClient,\n} from \"./mapping/DataValueMapping.js\";\nexport type {\n PropertyValueWireToClient,\n} from \"./mapping/PropertyValueMapping.js\";\nexport type { Attachment, AttachmentUpload } from \"./object/Attachment.js\";\nexport type {\n AsyncIterArgs,\n Augment,\n Augments,\n FetchPageArgs,\n NullabilityAdherence,\n SelectArg,\n SelectArgToKeys,\n} from \"./object/FetchPageArgs.js\";\nexport type {\n FetchPageResult,\n SingleOsdkResult,\n} from \"./object/FetchPageResult.js\";\nexport type { Media, MediaMetadata, MediaReference } from \"./object/Media.js\";\nexport { isOk } from \"./object/Result.js\";\nexport type { Result } from \"./object/Result.js\";\nexport type { BaseObjectSet } from \"./objectSet/BaseObjectSet.js\";\nexport type { ObjectSet } from \"./objectSet/ObjectSet.js\";\nexport type { ObjectSetSubscription } from \"./objectSet/ObjectSetListener.js\";\nexport type {\n ActionDefinition,\n ActionMetadata,\n} from \"./ontology/ActionDefinition.js\";\nexport type {\n InterfaceDefinition,\n InterfaceMetadata,\n} from \"./ontology/InterfaceDefinition.js\";\nexport type {\n ObjectOrInterfaceDefinition,\n PropertyKeys,\n} from \"./ontology/ObjectOrInterface.js\";\nexport type { ObjectSpecifier } from \"./ontology/ObjectSpecifier.js\";\nexport type {\n CompileTimeMetadata,\n ObjectMetadata,\n ObjectTypeDefinition,\n PropertyDef,\n VersionBound,\n} from \"./ontology/ObjectTypeDefinition.js\";\nexport type { OntologyMetadata } from \"./ontology/OntologyMetadata.js\";\nexport type { PrimaryKeyTypes } from \"./ontology/PrimaryKeyTypes.js\";\nexport type {\n ObjectQueryDataType,\n ObjectSetQueryDataType,\n QueryDataTypeDefinition,\n QueryDefinition,\n QueryMetadata,\n QueryParameterDefinition,\n ThreeDimensionalQueryAggregationDefinition,\n TwoDimensionalQueryAggregationDefinition,\n} from \"./ontology/QueryDefinition.js\";\nexport type {\n BaseWirePropertyTypes,\n WirePropertyTypes,\n} from \"./ontology/WirePropertyTypes.js\";\nexport type {\n ObjectIdentifiers,\n OsdkBase,\n PrimaryKeyType,\n} from \"./OsdkBase.js\";\nexport type { OsdkObject } from \"./OsdkObject.js\";\nexport type { ConvertProps, Osdk } from \"./OsdkObjectFrom.js\";\nexport type { PageResult } from \"./PageResult.js\";\nexport type {\n Range,\n ThreeDimensionalAggregation,\n TwoDimensionalAggregation,\n} from \"./queries/Aggregations.js\";\nexport type { QueryParam, QueryResult } from \"./queries/Queries.js\";\nexport { TimeseriesDurationMapping } from \"./timeseries/timeseries.js\";\nexport type {\n GeotimeSeriesProperty,\n TimeSeriesPoint,\n TimeSeriesProperty,\n TimeSeriesQuery,\n} from \"./timeseries/timeseries.js\";\nexport type { LinkedType, LinkNames } from \"./util/LinkUtils.js\";\nexport {};\nexport type { Logger } from \"./Logger.js\";\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAkBA,SAASA,mBAAmB,QAAQ,4BAA4B;AAahE,SAASC,eAAe,QAAQ,4BAA4B;AA8B5D,SAASC,IAAI,QAAQ,oBAAoB;AAuDzC,SAASC,yBAAyB,QAAQ,4BAA4B;AAQtE","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataValueMapping.js","names":[],"sources":["DataValueMapping.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { Attachment, AttachmentUpload } from \"../object/Attachment.js\";\nimport type { MediaReference
|
|
1
|
+
{"version":3,"file":"DataValueMapping.js","names":[],"sources":["DataValueMapping.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport type { Attachment, AttachmentUpload } from \"../object/Attachment.js\";\nimport type { MediaReference } from \"../object/Media.js\";\n\n/**\n * Map from the DataValue type to the typescript type that we return\n */\nexport interface DataValueWireToClient {\n attachment: Attachment;\n boolean: boolean;\n byte: number;\n datetime: string;\n date: string;\n decimal: string;\n float: number;\n double: number;\n integer: number;\n long: string;\n marking: string;\n null: null;\n short: number;\n string: string;\n timestamp: string;\n mediaReference: MediaReference;\n twoDimensionalAggregation: {\n key: AllowedBucketKeyTypes;\n value: AllowedBucketTypes;\n }[];\n threeDimensionalAggregation: {\n key: AllowedBucketKeyTypes;\n groups: { key: AllowedBucketKeyTypes; value: AllowedBucketTypes }[];\n }[];\n struct: Record<string, any>;\n set: Set<any>;\n objectType: string;\n geohash: GeoJSON.Point;\n geoshape: GeoJSON.GeoJSON;\n}\n\n/**\n * Map from the DataValue type to the typescript type that we accept\n */\nexport interface DataValueClientToWire {\n attachment: string | AttachmentUpload | Blob & { readonly name: string };\n boolean: boolean;\n byte: number;\n datetime: string;\n date: string;\n decimal: string | number;\n float: number;\n double: number;\n integer: number;\n long: string | number;\n marking: string;\n null: null;\n short: number;\n string: string;\n timestamp: string;\n set: Set<any>;\n mediaReference: MediaReference;\n twoDimensionalAggregation: {\n key: AllowedBucketKeyTypes;\n value: AllowedBucketTypes;\n }[];\n threeDimensionalAggregation: {\n key: AllowedBucketKeyTypes;\n groups: { key: AllowedBucketKeyTypes; value: AllowedBucketTypes }[];\n }[];\n struct: Record<string, any>;\n objectType: string;\n geohash: GeoJSON.Point;\n geoshape: GeoJSON.GeoJSON;\n}\n\nexport type AllowedBucketTypes = string | number | boolean;\nexport type AllowedBucketKeyTypes =\n | AllowedBucketTypes\n | {\n startValue: AllowedBucketTypes;\n endValue: AllowedBucketTypes;\n };\n"],"mappings":"","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Media.js","names":[],"sources":["Media.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport interface Media {\n /**\n * Fetches metadata for media reference property\n */\n fetchMetadata(): Promise<MediaMetadata>;\n /**\n * Fetches content of a media reference property\n */\n fetchContents(): Promise<Response>;\n /**\n * Returns the media reference\n */\n getMediaReference(): MediaReference;\n}\n\n/**\n * Unique identifier of a media item in Foundry.\n */\nexport interface MediaReference {\n mimeType: string;\n reference: {\n type: \"mediaSetViewItem\";\n mediaSetViewItem: {\n mediaItemRid: string;\n mediaSetRid: string;\n mediaSetViewRid: string;\n readToken?: string;\n };\n };\n}\n\n/**\n *
|
|
1
|
+
{"version":3,"file":"Media.js","names":[],"sources":["Media.ts"],"sourcesContent":["/*\n * Copyright 2024 Palantir Technologies, Inc. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport interface Media {\n /**\n * Fetches metadata for media reference property\n */\n fetchMetadata(): Promise<MediaMetadata>;\n /**\n * Fetches content of a media reference property\n */\n fetchContents(): Promise<Response>;\n /**\n * Returns the media reference\n */\n getMediaReference(): MediaReference;\n}\n\n/**\n * Unique identifier of a media item in Foundry.\n */\nexport interface MediaReference {\n mimeType: string;\n reference: {\n type: \"mediaSetViewItem\";\n mediaSetViewItem: {\n mediaItemRid: string;\n mediaSetRid: string;\n mediaSetViewRid: string;\n readToken?: string;\n };\n };\n}\n\n/**\n * Metadata of a media item\n */\nexport interface MediaMetadata {\n path?: string;\n sizeBytes: number;\n mediaType: string;\n}\n"],"mappings":"","ignoreList":[]}
|