@osdk/generator-converters 2.1.0-beta.19 → 2.1.0-beta.20

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.
Files changed (24) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/build/browser/__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js +1 -1
  3. package/build/browser/__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js.map +1 -1
  4. package/build/browser/wireObjectTypeFullMetadataToSdkObjectMetadata.js +1 -1
  5. package/build/browser/wireObjectTypeFullMetadataToSdkObjectMetadata.js.map +1 -1
  6. package/build/browser/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.d.ts.map +1 -1
  7. package/build/browser/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js +2 -0
  8. package/build/browser/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js.map +1 -1
  9. package/build/browser/wirePropertyV2ToSdkPropertyDefinition.d.ts +1 -1
  10. package/build/browser/wirePropertyV2ToSdkPropertyDefinition.d.ts.map +1 -1
  11. package/build/browser/wirePropertyV2ToSdkPropertyDefinition.js +27 -6
  12. package/build/browser/wirePropertyV2ToSdkPropertyDefinition.js.map +1 -1
  13. package/build/esm/__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js +1 -1
  14. package/build/esm/__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js.map +1 -1
  15. package/build/esm/wireObjectTypeFullMetadataToSdkObjectMetadata.js +1 -1
  16. package/build/esm/wireObjectTypeFullMetadataToSdkObjectMetadata.js.map +1 -1
  17. package/build/esm/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.d.ts.map +1 -1
  18. package/build/esm/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js +2 -0
  19. package/build/esm/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js.map +1 -1
  20. package/build/esm/wirePropertyV2ToSdkPropertyDefinition.d.ts +1 -1
  21. package/build/esm/wirePropertyV2ToSdkPropertyDefinition.d.ts.map +1 -1
  22. package/build/esm/wirePropertyV2ToSdkPropertyDefinition.js +27 -6
  23. package/build/esm/wirePropertyV2ToSdkPropertyDefinition.js.map +1 -1
  24. package/package.json +6 -5
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @osdk/generator-converters
2
2
 
3
+ ## 2.1.0-beta.20
4
+
5
+ ### Minor Changes
6
+
7
+ - 9d35a1f: Remove unused imports
8
+ - abfe4b3: Add support for reading struct properties.
9
+ - bf0e3b4: Ignore unknown property types.
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies [9d35a1f]
14
+ - Updated dependencies [abfe4b3]
15
+ - Updated dependencies [c537e2d]
16
+ - @osdk/api@2.1.0-beta.20
17
+
3
18
  ## 2.1.0-beta.19
4
19
 
5
20
  ### Patch Changes
@@ -24,7 +24,7 @@ export function __UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition(interfaceTyp
24
24
  implements: interfaceType.extendsInterfaces,
25
25
  properties: Object.fromEntries(Object.entries(interfaceType.properties).map(([key, value]) => {
26
26
  return [key, wirePropertyV2ToSdkPropertyDefinition(value, true)];
27
- })),
27
+ }).filter(([key, value]) => value != null)),
28
28
  links: {}
29
29
  };
30
30
  }
@@ -1 +1 @@
1
- {"version":3,"file":"__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js","names":["wirePropertyV2ToSdkPropertyDefinition","__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition","interfaceType","type","rid","apiName","displayName","description","implements","extendsInterfaces","properties","Object","fromEntries","entries","map","key","value","links"],"sources":["__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js"],"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 */\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function __UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition(interfaceType, v2) {\n return {\n type: \"interface\",\n rid: interfaceType.rid,\n apiName: interfaceType.apiName,\n displayName: interfaceType.displayName,\n description: interfaceType.description,\n implements: interfaceType.extendsInterfaces,\n properties: Object.fromEntries(Object.entries(interfaceType.properties).map(([key, value]) => {\n return [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, true),\n ];\n })),\n links: {},\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,qCAAqC,QAAQ,4CAA4C;AAClG,OAAO,SAASC,mDAAmDA,CAACC,aAAa,EAAM;EACnF,OAAO;IACHC,IAAI,EAAE,WAAW;IACjBC,GAAG,EAAEF,aAAa,CAACE,GAAG;IACtBC,OAAO,EAAEH,aAAa,CAACG,OAAO;IAC9BC,WAAW,EAAEJ,aAAa,CAACI,WAAW;IACtCC,WAAW,EAAEL,aAAa,CAACK,WAAW;IACtCC,UAAU,EAAEN,aAAa,CAACO,iBAAiB;IAC3CC,UAAU,EAAEC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAACX,aAAa,CAACQ,UAAU,CAAC,CAACI,GAAG,CAAC,CAAC,CAACC,GAAG,EAAEC,KAAK,CAAC,KAAK;MAC1F,OAAO,CACHD,GAAG,EACHf,qCAAqC,CAACgB,KAAK,EAAE,IAAI,CAAC,CACrD;IACL,CAAC,CAAC,CAAC;IACHC,KAAK,EAAE,CAAC;EACZ,CAAC;AACL","ignoreList":[]}
1
+ {"version":3,"file":"__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js","names":["wirePropertyV2ToSdkPropertyDefinition","__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition","interfaceType","type","rid","apiName","displayName","description","implements","extendsInterfaces","properties","Object","fromEntries","entries","map","key","value","filter","links"],"sources":["__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js"],"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 */\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function __UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition(interfaceType, v2) {\n return {\n type: \"interface\",\n rid: interfaceType.rid,\n apiName: interfaceType.apiName,\n displayName: interfaceType.displayName,\n description: interfaceType.description,\n implements: interfaceType.extendsInterfaces,\n properties: Object.fromEntries(Object.entries(interfaceType.properties).map(([key, value]) => {\n return [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, true),\n ];\n }).filter(([key, value]) => value != null)),\n links: {},\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,qCAAqC,QAAQ,4CAA4C;AAClG,OAAO,SAASC,mDAAmDA,CAACC,aAAa,EAAM;EACnF,OAAO;IACHC,IAAI,EAAE,WAAW;IACjBC,GAAG,EAAEF,aAAa,CAACE,GAAG;IACtBC,OAAO,EAAEH,aAAa,CAACG,OAAO;IAC9BC,WAAW,EAAEJ,aAAa,CAACI,WAAW;IACtCC,WAAW,EAAEL,aAAa,CAACK,WAAW;IACtCC,UAAU,EAAEN,aAAa,CAACO,iBAAiB;IAC3CC,UAAU,EAAEC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAACX,aAAa,CAACQ,UAAU,CAAC,CAACI,GAAG,CAAC,CAAC,CAACC,GAAG,EAAEC,KAAK,CAAC,KAAK;MAC1F,OAAO,CACHD,GAAG,EACHf,qCAAqC,CAACgB,KAAK,EAAE,IAAI,CAAC,CACrD;IACL,CAAC,CAAC,CAACC,MAAM,CAAC,CAAC,CAACF,GAAG,EAAEC,KAAK,CAAC,KAAKA,KAAK,IAAI,IAAI,CAAC,CAAC;IAC3CE,KAAK,EAAE,CAAC;EACZ,CAAC;AACL","ignoreList":[]}
@@ -36,7 +36,7 @@ export function wireObjectTypeFullMetadataToSdkObjectMetadata(objectTypeWithLink
36
36
  targetType: linkType.objectTypeApiName
37
37
  }];
38
38
  })),
39
- properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [key, wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key))])),
39
+ properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [key, wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key))]).filter(([key, value]) => value != null)),
40
40
  implements: objectTypeWithLink.implementsInterfaces,
41
41
  interfaceMap,
42
42
  inverseInterfaceMap: Object.fromEntries(Object.entries(interfaceMap).map(([interfaceApiName, props]) => [interfaceApiName, invertProps(props)])),
@@ -1 +1 @@
1
- {"version":3,"file":"wireObjectTypeFullMetadataToSdkObjectMetadata.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","wirePropertyV2ToSdkPropertyDefinition","wireObjectTypeFullMetadataToSdkObjectMetadata","objectTypeWithLink","v2","objectType","properties","primaryKey","undefined","Error","apiName","implementsInterfaces2","implementsInterfaces","interfaceMap","Object","fromEntries","entries","map","interfaceApiName","impl","type","description","primaryKeyApiName","primaryKeyType","links","linkTypes","linkType","multiplicity","cardinality","targetType","objectTypeApiName","key","value","implements","inverseInterfaceMap","props","invertProps","icon","supportedIconTypes","includes","titleProperty","displayName","pluralDisplayName","status","rid","visibility","a","k","v"],"sources":["wireObjectTypeFullMetadataToSdkObjectMetadata.js"],"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 */\nimport { wirePropertyV2ToSdkPrimaryKeyTypeDefinition } from \"./wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js\";\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function wireObjectTypeFullMetadataToSdkObjectMetadata(objectTypeWithLink, v2) {\n if (objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey] === undefined) {\n throw new Error(`Primary key ${objectTypeWithLink.objectType.primaryKey} not found in ${objectTypeWithLink.objectType.apiName}`);\n }\n // saved ontology.json files may not have this implementsInterfaces2 so we need to handle\n if (objectTypeWithLink.implementsInterfaces2 == null\n && objectTypeWithLink.implementsInterfaces != null) {\n throw new Error(\"Your ontology.json file is missing the implementsInterfaces2 field. Please regenerate it.\");\n }\n const interfaceMap = objectTypeWithLink.implementsInterfaces2\n ? Object.fromEntries(Object.entries(objectTypeWithLink.implementsInterfaces2).map(([interfaceApiName, impl]) => [interfaceApiName, impl.properties]))\n : {};\n return {\n type: \"object\",\n apiName: objectTypeWithLink.objectType.apiName,\n description: objectTypeWithLink.objectType.description,\n primaryKeyApiName: objectTypeWithLink.objectType.primaryKey,\n primaryKeyType: wirePropertyV2ToSdkPrimaryKeyTypeDefinition(objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey]),\n links: Object.fromEntries(objectTypeWithLink.linkTypes.map(linkType => {\n return [linkType.apiName, {\n multiplicity: linkType.cardinality === \"MANY\",\n targetType: linkType.objectTypeApiName,\n }];\n })),\n properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key)),\n ])),\n implements: objectTypeWithLink.implementsInterfaces,\n interfaceMap,\n inverseInterfaceMap: Object.fromEntries(Object.entries(interfaceMap).map(([interfaceApiName, props]) => [interfaceApiName, invertProps(props)])),\n icon: supportedIconTypes.includes(objectTypeWithLink.objectType.icon.type)\n ? objectTypeWithLink.objectType.icon\n : undefined,\n titleProperty: objectTypeWithLink.objectType.titleProperty,\n displayName: objectTypeWithLink.objectType.displayName,\n pluralDisplayName: objectTypeWithLink.objectType.pluralDisplayName,\n status: objectTypeWithLink.objectType.status,\n rid: objectTypeWithLink.objectType.rid,\n visibility: objectTypeWithLink.objectType.visibility,\n };\n}\nfunction invertProps(a) {\n return (a\n ? Object.fromEntries(Object.entries(a).map(([k, v]) => [v, k]))\n : undefined);\n}\nconst supportedIconTypes = [\"blueprint\"];\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,2CAA2C,QAAQ,kDAAkD;AAC9G,SAASC,qCAAqC,QAAQ,4CAA4C;AAClG,OAAO,SAASC,6CAA6CA,CAACC,kBAAkB,EAAEC,EAAE,EAAE;EAClF,IAAID,kBAAkB,CAACE,UAAU,CAC5BC,UAAU,CAACH,kBAAkB,CAACE,UAAU,CAACE,UAAU,CAAC,KAAKC,SAAS,EAAE;IACrE,MAAM,IAAIC,KAAK,CAAC,eAAeN,kB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AACnB;AACA,MAAM8B,kBAAkB,GAAG,CAAC,WAAW,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"wireObjectTypeFullMetadataToSdkObjectMetadata.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","wirePropertyV2ToSdkPropertyDefinition","wireObjectTypeFullMetadataToSdkObjectMetadata","objectTypeWithLink","v2","objectType","properties","primaryKey","undefined","Error","apiName","implementsInterfaces2","implementsInterfaces","interfaceMap","Object","fromEntries","entries","map","interfaceApiName","impl","type","description","primaryKeyApiName","primaryKeyType","links","linkTypes","linkType","multiplicity","cardinality","targetType","objectTypeApiName","key","value","filter","implements","inverseInterfaceMap","props","invertProps","icon","supportedIconTypes","includes","titleProperty","displayName","pluralDisplayName","status","rid","visibility","a","k","v"],"sources":["wireObjectTypeFullMetadataToSdkObjectMetadata.js"],"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 */\nimport { wirePropertyV2ToSdkPrimaryKeyTypeDefinition } from \"./wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js\";\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function wireObjectTypeFullMetadataToSdkObjectMetadata(objectTypeWithLink, v2) {\n if (objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey] === undefined) {\n throw new Error(`Primary key ${objectTypeWithLink.objectType.primaryKey} not found in ${objectTypeWithLink.objectType.apiName}`);\n }\n // saved ontology.json files may not have this implementsInterfaces2 so we need to handle\n if (objectTypeWithLink.implementsInterfaces2 == null\n && objectTypeWithLink.implementsInterfaces != null) {\n throw new Error(\"Your ontology.json file is missing the implementsInterfaces2 field. Please regenerate it.\");\n }\n const interfaceMap = objectTypeWithLink.implementsInterfaces2\n ? Object.fromEntries(Object.entries(objectTypeWithLink.implementsInterfaces2).map(([interfaceApiName, impl]) => [interfaceApiName, impl.properties]))\n : {};\n return {\n type: \"object\",\n apiName: objectTypeWithLink.objectType.apiName,\n description: objectTypeWithLink.objectType.description,\n primaryKeyApiName: objectTypeWithLink.objectType.primaryKey,\n primaryKeyType: wirePropertyV2ToSdkPrimaryKeyTypeDefinition(objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey]),\n links: Object.fromEntries(objectTypeWithLink.linkTypes.map(linkType => {\n return [linkType.apiName, {\n multiplicity: linkType.cardinality === \"MANY\",\n targetType: linkType.objectTypeApiName,\n }];\n })),\n properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key)),\n ]).filter(([key, value]) => value != null)),\n implements: objectTypeWithLink.implementsInterfaces,\n interfaceMap,\n inverseInterfaceMap: Object.fromEntries(Object.entries(interfaceMap).map(([interfaceApiName, props]) => [interfaceApiName, invertProps(props)])),\n icon: supportedIconTypes.includes(objectTypeWithLink.objectType.icon.type)\n ? objectTypeWithLink.objectType.icon\n : undefined,\n titleProperty: objectTypeWithLink.objectType.titleProperty,\n displayName: objectTypeWithLink.objectType.displayName,\n pluralDisplayName: objectTypeWithLink.objectType.pluralDisplayName,\n status: objectTypeWithLink.objectType.status,\n rid: objectTypeWithLink.objectType.rid,\n visibility: objectTypeWithLink.objectType.visibility,\n };\n}\nfunction invertProps(a) {\n return (a\n ? Object.fromEntries(Object.entries(a).map(([k, v]) => [v, k]))\n : undefined);\n}\nconst supportedIconTypes = [\"blueprint\"];\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA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AAEzC,kBAAkB,CAACE,UAAU,CAACuC,MAAM;IAC5CC,GAAG,EAAE1C,kBAAkB,CAACE,UAAU,CAACwC,GAAG;IACtCC,UAAU,EAAE3C,kBAAkB,CAACE,UAAU,CAACyC;EAC9C,CAAC;AACL;AACA,SAAST,WAAWA,CAACU,CAAC,EAAE;EACpB,OAAQA,CAAC,GACHjC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAAC+B,CAAC,CAAC,CAAC9B,GAAG,CAAC,CAAC,CAAC+B,CAAC,EAAEC,CAAC,CAAC,KAAK,CAACA,CAAC,EAAED,CAAC,CAAC,CAAC,CAAC,GAC7DxC,SAAS;AACnB;AACA,MAAM+B,kBAAkB,GAAG,CAAC,WAAW,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAE9D,wBAAgB,2CAA2C,CACzD,KAAK,EAAE,UAAU,GAChB,eAAe,CAoCjB"}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAE9D,wBAAgB,2CAA2C,CACzD,KAAK,EAAE,UAAU,GAChB,eAAe,CAsCjB"}
@@ -43,6 +43,8 @@ export function wirePropertyV2ToSdkPrimaryKeyTypeDefinition(input) {
43
43
  case "float":
44
44
  case "geotimeSeriesReference":
45
45
  case "mediaReference":
46
+ case "struct":
47
+ case "cipherText":
46
48
  throw new Error(`Type not supported for primaryKey: ${input.dataType.type}`);
47
49
  default:
48
50
  input.dataType;
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","input","dataType","type","Error"],"sources":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js"],"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 */\nexport function wirePropertyV2ToSdkPrimaryKeyTypeDefinition(input) {\n switch (input.dataType.type) {\n case \"integer\":\n case \"double\":\n case \"string\":\n case \"boolean\":\n case \"byte\":\n case \"long\":\n case \"short\": {\n return input.dataType.type;\n }\n case \"date\": {\n return \"datetime\";\n }\n case \"timestamp\": {\n return \"timestamp\";\n }\n case \"geopoint\":\n case \"geoshape\":\n case \"decimal\":\n case \"attachment\":\n case \"timeseries\":\n case \"array\":\n case \"marking\":\n case \"float\":\n case \"geotimeSeriesReference\":\n case \"mediaReference\":\n throw new Error(`Type not supported for primaryKey: ${input.dataType.type}`);\n default:\n const _ = input.dataType;\n throw new Error(`Unknown type encountered for primaryKey: ${input.dataType}`);\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,2CAA2CA,CAACC,KAAK,EAAE;EAC/D,QAAQA,KAAK,CAACC,QAAQ,CAACC,IAAI;IACvB,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,QAAQ;IACb,KAAK,SAAS;IACd,KAAK,MAAM;IACX,KAAK,MAAM;IACX,KAAK,OAAO;MAAE;QACV,OAAOF,KAAK,CAACC,QAAQ,CAACC,IAAI;MAC9B;IACA,KAAK,MAAM;MAAE;QACT,OAAO,UAAU;MACrB;IACA,KAAK,WAAW;MAAE;QACd,OAAO,WAAW;MACtB;IACA,KAAK,UAAU;IACf,KAAK,UAAU;IACf,KAAK,SAAS;IACd,KAAK,YAAY;IACjB,KAAK,YAAY;IACjB,KAAK,OAAO;IACZ,KAAK,SAAS;IACd,KAAK,OAAO;IACZ,KAAK,wBAAwB;IAC7B,KAAK,gBAAgB;MACjB,MAAM,IAAIC,KAAK,CAAC,sCAAsCH,KAAK,CAACC,QAAQ,CAACC,IAAI,EAAE,CAAC;IAChF;MACcF,KAAK,CAACC,QAAQ;MACxB,MAAM,IAAIE,KAAK,CAAC,4CAA4CH,KAAK,CAACC,QAAQ,EAAE,CAAC;EACrF;AACJ","ignoreList":[]}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","input","dataType","type","Error"],"sources":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js"],"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 */\nexport function wirePropertyV2ToSdkPrimaryKeyTypeDefinition(input) {\n switch (input.dataType.type) {\n case \"integer\":\n case \"double\":\n case \"string\":\n case \"boolean\":\n case \"byte\":\n case \"long\":\n case \"short\": {\n return input.dataType.type;\n }\n case \"date\": {\n return \"datetime\";\n }\n case \"timestamp\": {\n return \"timestamp\";\n }\n case \"geopoint\":\n case \"geoshape\":\n case \"decimal\":\n case \"attachment\":\n case \"timeseries\":\n case \"array\":\n case \"marking\":\n case \"float\":\n case \"geotimeSeriesReference\":\n case \"mediaReference\":\n case \"struct\":\n case \"cipherText\":\n throw new Error(`Type not supported for primaryKey: ${input.dataType.type}`);\n default:\n const _ = input.dataType;\n throw new Error(`Unknown type encountered for primaryKey: ${input.dataType}`);\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,2CAA2CA,CAACC,KAAK,EAAE;EAC/D,QAAQA,KAAK,CAACC,QAAQ,CAACC,IAAI;IACvB,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,QAAQ;IACb,KAAK,SAAS;IACd,KAAK,MAAM;IACX,KAAK,MAAM;IACX,KAAK,OAAO;MAAE;QACV,OAAOF,KAAK,CAACC,QAAQ,CAACC,IAAI;MAC9B;IACA,KAAK,MAAM;MAAE;QACT,OAAO,UAAU;MACrB;IACA,KAAK,WAAW;MAAE;QACd,OAAO,WAAW;MACtB;IACA,KAAK,UAAU;IACf,KAAK,UAAU;IACf,KAAK,SAAS;IACd,KAAK,YAAY;IACjB,KAAK,YAAY;IACjB,KAAK,OAAO;IACZ,KAAK,SAAS;IACd,KAAK,OAAO;IACZ,KAAK,wBAAwB;IAC7B,KAAK,gBAAgB;IACrB,KAAK,QAAQ;IACb,KAAK,YAAY;MACb,MAAM,IAAIC,KAAK,CAAC,sCAAsCH,KAAK,CAACC,QAAQ,CAACC,IAAI,EAAE,CAAC;IAChF;MACcF,KAAK,CAACC,QAAQ;MACxB,MAAM,IAAIE,KAAK,CAAC,4CAA4CH,KAAK,CAACC,QAAQ,EAAE,CAAC;EACrF;AACJ","ignoreList":[]}
@@ -2,5 +2,5 @@ import type { ObjectMetadata } from "@osdk/api";
2
2
  import type { PropertyV2, SharedPropertyType } from "@osdk/internal.foundry.core";
3
3
  export declare function wirePropertyV2ToSdkPropertyDefinition(input: (PropertyV2 | SharedPropertyType) & {
4
4
  nullable?: boolean;
5
- }, isNullable?: boolean): ObjectMetadata.Property;
5
+ }, isNullable?: boolean): ObjectMetadata.Property | undefined;
6
6
  //# sourceMappingURL=wirePropertyV2ToSdkPropertyDefinition.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPropertyDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,cAAc,EAAqB,MAAM,WAAW,CAAC;AACnE,OAAO,KAAK,EAEV,UAAU,EACV,kBAAkB,EACnB,MAAM,6BAA6B,CAAC;AAErC,wBAAgB,qCAAqC,CACnD,KAAK,EAAE,CAAC,UAAU,GAAG,kBAAkB,CAAC,GAAG;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,EACjE,UAAU,GAAE,OAAc,GACzB,cAAc,CAAC,QAAQ,CA8CzB"}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPropertyDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EACV,cAAc,EAGf,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAEV,UAAU,EACV,kBAAkB,EACnB,MAAM,6BAA6B,CAAC;AAGrC,wBAAgB,qCAAqC,CACnD,KAAK,EAAE,CAAC,UAAU,GAAG,kBAAkB,CAAC,GAAG;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,EACjE,UAAU,GAAE,OAAc,GACzB,cAAc,CAAC,QAAQ,GAAG,SAAS,CAwDrC"}
@@ -13,7 +13,12 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
+ import { consola } from "consola";
16
17
  export function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true) {
18
+ const sdkPropDefinition = objectPropertyTypeToSdkPropertyDefinition(input.dataType);
19
+ if (sdkPropDefinition == null) {
20
+ return undefined;
21
+ }
17
22
  switch (input.dataType.type) {
18
23
  case "integer":
19
24
  case "string":
@@ -32,11 +37,12 @@ export function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true)
32
37
  case "timeseries":
33
38
  case "marking":
34
39
  case "geotimeSeriesReference":
40
+ case "struct":
35
41
  return {
36
42
  displayName: input.displayName,
37
43
  multiplicity: false,
38
44
  description: input.description,
39
- type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),
45
+ type: sdkPropDefinition,
40
46
  nullable: input.nullable == null ? isNullable : input.nullable
41
47
  };
42
48
  case "array":
@@ -45,17 +51,20 @@ export function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true)
45
51
  displayName: input.displayName,
46
52
  multiplicity: true,
47
53
  description: input.description,
48
- type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),
54
+ type: sdkPropDefinition,
49
55
  nullable: true
50
56
  };
51
57
  }
58
+ case "cipherText":
52
59
  case "mediaReference":
53
60
  {
54
- throw new Error(`Media references not supported yet`);
61
+ consola.info(`${JSON.stringify(input.dataType.type)} is not a supported dataType`);
62
+ return undefined;
55
63
  }
56
64
  default:
57
65
  input.dataType;
58
- throw new Error(`Unexpected data type ${JSON.stringify(input.dataType)}`);
66
+ consola.info(`${JSON.stringify(input.dataType)} is not a supported dataType`);
67
+ return undefined;
59
68
  }
60
69
  }
61
70
  function objectPropertyTypeToSdkPropertyDefinition(propertyType) {
@@ -86,12 +95,24 @@ function objectPropertyTypeToSdkPropertyDefinition(propertyType) {
86
95
  } else if (propertyType.itemType?.type === "double") {
87
96
  return "numericTimeseries";
88
97
  } else return "sensorTimeseries";
98
+ case "struct":
99
+ {
100
+ return propertyType.structFieldTypes.reduce((structMap, structField) => {
101
+ structMap[structField.apiName] = objectPropertyTypeToSdkPropertyDefinition(structField.dataType);
102
+ return structMap;
103
+ }, {});
104
+ }
89
105
  case "mediaReference":
106
+ case "cipherText":
90
107
  {
91
- throw new Error(`Media references not supported yet`);
108
+ consola.info(`${JSON.stringify(propertyType.type)} is not a supported propertyType`);
109
+ return undefined;
92
110
  }
93
111
  default:
94
- throw new Error(`Unexpected data type ${JSON.stringify(propertyType)}`);
112
+ {
113
+ consola.info(`${JSON.stringify(propertyType)} is not a supported propertyType`);
114
+ return undefined;
115
+ }
95
116
  }
96
117
  }
97
118
  //# sourceMappingURL=wirePropertyV2ToSdkPropertyDefinition.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.js","names":["wirePropertyV2ToSdkPropertyDefinition","input","isNullable","dataType","type","displayName","multiplicity","description","objectPropertyTypeToSdkPropertyDefinition","nullable","Error","JSON","stringify","propertyType","subType","itemType"],"sources":["wirePropertyV2ToSdkPropertyDefinition.js"],"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 */\nexport function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true) {\n switch (input.dataType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"date\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"timeseries\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n return {\n displayName: input.displayName,\n multiplicity: false,\n description: input.description,\n type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),\n nullable: input.nullable == null ? isNullable : input.nullable,\n };\n case \"array\": {\n return {\n displayName: input.displayName,\n multiplicity: true,\n description: input.description,\n type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),\n nullable: true,\n };\n }\n case \"mediaReference\": {\n throw new Error(`Media references not supported yet`);\n }\n default:\n const _ = input.dataType;\n throw new Error(`Unexpected data type ${JSON.stringify(input.dataType)}`);\n }\n}\nfunction objectPropertyTypeToSdkPropertyDefinition(propertyType) {\n switch (propertyType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n return propertyType.type;\n case \"date\":\n return \"datetime\";\n case \"array\":\n return objectPropertyTypeToSdkPropertyDefinition(propertyType.subType);\n case \"timeseries\":\n if (propertyType.itemType?.type === \"string\") {\n return \"stringTimeseries\";\n }\n else if (propertyType.itemType?.type === \"double\") {\n return \"numericTimeseries\";\n }\n else\n return \"sensorTimeseries\";\n case \"mediaReference\": {\n throw new Error(`Media references not supported yet`);\n }\n default:\n const _ = propertyType;\n throw new Error(`Unexpected data type ${JSON.stringify(propertyType)}`);\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,qCAAqCA,CAACC,KAAK,EAAEC,UAAU,GAAG,IAAI,EAAE;EAC5E,QAAQD,KAAK,CAACE,QAAQ,CAACC,IAAI;IACvB,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,MAAM;IACX,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,OAAO;IACZ,KAAK,MAAM;IACX,KAAK,OAAO;IACZ,KAAK,SAAS;IACd,KAAK,MAAM;IACX,KAAK,YAAY;IACjB,KAAK,UAAU;IACf,KAAK,UAAU;I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OAAOI,yCAAyC,CAACK,YAAY,CAACC,OAAO,CAAC;IAC1E,KAAK,YAAY;MACb,IAAID,YAAY,CAACE,QAAQ,EAAEX,IAAI,KAAK,QAAQ,EAAE;QAC1C,OAAO,kBAAkB;MAC7B,CAAC,MACI,IAAIS,YAAY,CAACE,QAAQ,EAAEX,IAAI,KAAK,QAAQ,EAAE;QAC/C,OAAO,mBAAmB;MAC9B,CAAC,MAEG,OAAO,kBAAkB;IACjC,KAAK,gBAAgB;MAAE;QACnB,MAAM,IAAIM,KAAK,CAAC,oCAAoC,CAAC;MACzD;IACA;MAEI,MAAM,IAAIA,KAAK,CAAC,wBAAwBC,IAAI,CAACC,SAAS,CAACC,YAAY,CAAC,EAAE,CAAC;EAC/E;AACJ","ignoreList":[]}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.js","names":["consola","wirePropertyV2ToSdkPropertyDefinition","input","isNullable","sdkPropDefinition","objectPropertyTypeToSdkPropertyDefinition","dataType","undefined","type","displayName","multiplicity","description","nullable","info","JSON","stringify","propertyType","subType","itemType","structFieldTypes","reduce","structMap","structField","apiName"],"sources":["wirePropertyV2ToSdkPropertyDefinition.js"],"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 */\nimport { consola } from \"consola\";\nexport function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true) {\n const sdkPropDefinition = objectPropertyTypeToSdkPropertyDefinition(input.dataType);\n if (sdkPropDefinition == null) {\n return undefined;\n }\n switch (input.dataType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"date\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"timeseries\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n case \"struct\":\n return {\n displayName: input.displayName,\n multiplicity: false,\n description: input.description,\n type: sdkPropDefinition,\n nullable: input.nullable == null ? isNullable : input.nullable,\n };\n case \"array\": {\n return {\n displayName: input.displayName,\n multiplicity: true,\n description: input.description,\n type: sdkPropDefinition,\n nullable: true,\n };\n }\n case \"cipherText\":\n case \"mediaReference\": {\n consola.info(`${JSON.stringify(input.dataType.type)} is not a supported dataType`);\n return undefined;\n }\n default:\n const _ = input.dataType;\n consola.info(`${JSON.stringify(input.dataType)} is not a supported dataType`);\n return undefined;\n }\n}\nfunction objectPropertyTypeToSdkPropertyDefinition(propertyType) {\n switch (propertyType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n return propertyType.type;\n case \"date\":\n return \"datetime\";\n case \"array\":\n return objectPropertyTypeToSdkPropertyDefinition(propertyType.subType);\n case \"timeseries\":\n if (propertyType.itemType?.type === \"string\") {\n return \"stringTimeseries\";\n }\n else if (propertyType.itemType?.type === \"double\") {\n return \"numericTimeseries\";\n }\n else\n return \"sensorTimeseries\";\n case \"struct\": {\n return propertyType.structFieldTypes.reduce((structMap, structField) => {\n structMap[structField.apiName] =\n objectPropertyTypeToSdkPropertyDefinition(structField.dataType);\n return structMap;\n }, {});\n }\n case \"mediaReference\":\n case \"cipherText\": {\n consola.info(`${JSON.stringify(propertyType.type)} is not a supported propertyType`);\n return undefined;\n }\n default: {\n const _ = propertyType;\n consola.info(`${JSON.stringify(propertyType)} is not a supported propertyType`);\n return undefined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ACA,KAAK,gBAAgB;IACrB,KAAK,YAAY;MAAE;QACfrB,OAAO,CAACa,IAAI,CAAC,GAAGC,IAAI,CAACC,SAAS,CAACC,YAAY,CAACR,IAAI,CAAC,kCAAkC,CAAC;QACpF,OAAOD,SAAS;MACpB;IACA;MAAS;QAELP,OAAO,CAACa,IAAI,CAAC,GAAGC,IAAI,CAACC,SAAS,CAACC,YAAY,CAAC,kCAAkC,CAAC;QAC/E,OAAOT,SAAS;MACpB;EACJ;AACJ","ignoreList":[]}
@@ -24,7 +24,7 @@ export function __UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition(interfaceTyp
24
24
  implements: interfaceType.extendsInterfaces,
25
25
  properties: Object.fromEntries(Object.entries(interfaceType.properties).map(([key, value]) => {
26
26
  return [key, wirePropertyV2ToSdkPropertyDefinition(value, true)];
27
- })),
27
+ }).filter(([key, value]) => value != null)),
28
28
  links: {}
29
29
  };
30
30
  }
@@ -1 +1 @@
1
- {"version":3,"file":"__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js","names":["wirePropertyV2ToSdkPropertyDefinition","__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition","interfaceType","type","rid","apiName","displayName","description","implements","extendsInterfaces","properties","Object","fromEntries","entries","map","key","value","links"],"sources":["__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js"],"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 */\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function __UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition(interfaceType, v2) {\n return {\n type: \"interface\",\n rid: interfaceType.rid,\n apiName: interfaceType.apiName,\n displayName: interfaceType.displayName,\n description: interfaceType.description,\n implements: interfaceType.extendsInterfaces,\n properties: Object.fromEntries(Object.entries(interfaceType.properties).map(([key, value]) => {\n return [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, true),\n ];\n })),\n links: {},\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,qCAAqC,QAAQ,4CAA4C;AAClG,OAAO,SAASC,mDAAmDA,CAACC,aAAa,EAAM;EACnF,OAAO;IACHC,IAAI,EAAE,WAAW;IACjBC,GAAG,EAAEF,aAAa,CAACE,GAAG;IACtBC,OAAO,EAAEH,aAAa,CAACG,OAAO;IAC9BC,WAAW,EAAEJ,aAAa,CAACI,WAAW;IACtCC,WAAW,EAAEL,aAAa,CAACK,WAAW;IACtCC,UAAU,EAAEN,aAAa,CAACO,iBAAiB;IAC3CC,UAAU,EAAEC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAACX,aAAa,CAACQ,UAAU,CAAC,CAACI,GAAG,CAAC,CAAC,CAACC,GAAG,EAAEC,KAAK,CAAC,KAAK;MAC1F,OAAO,CACHD,GAAG,EACHf,qCAAqC,CAACgB,KAAK,EAAE,IAAI,CAAC,CACrD;IACL,CAAC,CAAC,CAAC;IACHC,KAAK,EAAE,CAAC;EACZ,CAAC;AACL","ignoreList":[]}
1
+ {"version":3,"file":"__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js","names":["wirePropertyV2ToSdkPropertyDefinition","__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition","interfaceType","type","rid","apiName","displayName","description","implements","extendsInterfaces","properties","Object","fromEntries","entries","map","key","value","filter","links"],"sources":["__UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition.js"],"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 */\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function __UNSTABLE_wireInterfaceTypeV2ToSdkObjectDefinition(interfaceType, v2) {\n return {\n type: \"interface\",\n rid: interfaceType.rid,\n apiName: interfaceType.apiName,\n displayName: interfaceType.displayName,\n description: interfaceType.description,\n implements: interfaceType.extendsInterfaces,\n properties: Object.fromEntries(Object.entries(interfaceType.properties).map(([key, value]) => {\n return [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, true),\n ];\n }).filter(([key, value]) => value != null)),\n links: {},\n };\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,qCAAqC,QAAQ,4CAA4C;AAClG,OAAO,SAASC,mDAAmDA,CAACC,aAAa,EAAM;EACnF,OAAO;IACHC,IAAI,EAAE,WAAW;IACjBC,GAAG,EAAEF,aAAa,CAACE,GAAG;IACtBC,OAAO,EAAEH,aAAa,CAACG,OAAO;IAC9BC,WAAW,EAAEJ,aAAa,CAACI,WAAW;IACtCC,WAAW,EAAEL,aAAa,CAACK,WAAW;IACtCC,UAAU,EAAEN,aAAa,CAACO,iBAAiB;IAC3CC,UAAU,EAAEC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAACX,aAAa,CAACQ,UAAU,CAAC,CAACI,GAAG,CAAC,CAAC,CAACC,GAAG,EAAEC,KAAK,CAAC,KAAK;MAC1F,OAAO,CACHD,GAAG,EACHf,qCAAqC,CAACgB,KAAK,EAAE,IAAI,CAAC,CACrD;IACL,CAAC,CAAC,CAACC,MAAM,CAAC,CAAC,CAACF,GAAG,EAAEC,KAAK,CAAC,KAAKA,KAAK,IAAI,IAAI,CAAC,CAAC;IAC3CE,KAAK,EAAE,CAAC;EACZ,CAAC;AACL","ignoreList":[]}
@@ -36,7 +36,7 @@ export function wireObjectTypeFullMetadataToSdkObjectMetadata(objectTypeWithLink
36
36
  targetType: linkType.objectTypeApiName
37
37
  }];
38
38
  })),
39
- properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [key, wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key))])),
39
+ properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [key, wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key))]).filter(([key, value]) => value != null)),
40
40
  implements: objectTypeWithLink.implementsInterfaces,
41
41
  interfaceMap,
42
42
  inverseInterfaceMap: Object.fromEntries(Object.entries(interfaceMap).map(([interfaceApiName, props]) => [interfaceApiName, invertProps(props)])),
@@ -1 +1 @@
1
- {"version":3,"file":"wireObjectTypeFullMetadataToSdkObjectMetadata.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","wirePropertyV2ToSdkPropertyDefinition","wireObjectTypeFullMetadataToSdkObjectMetadata","objectTypeWithLink","v2","objectType","properties","primaryKey","undefined","Error","apiName","implementsInterfaces2","implementsInterfaces","interfaceMap","Object","fromEntries","entries","map","interfaceApiName","impl","type","description","primaryKeyApiName","primaryKeyType","links","linkTypes","linkType","multiplicity","cardinality","targetType","objectTypeApiName","key","value","implements","inverseInterfaceMap","props","invertProps","icon","supportedIconTypes","includes","titleProperty","displayName","pluralDisplayName","status","rid","visibility","a","k","v"],"sources":["wireObjectTypeFullMetadataToSdkObjectMetadata.js"],"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 */\nimport { wirePropertyV2ToSdkPrimaryKeyTypeDefinition } from \"./wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js\";\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function wireObjectTypeFullMetadataToSdkObjectMetadata(objectTypeWithLink, v2) {\n if (objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey] === undefined) {\n throw new Error(`Primary key ${objectTypeWithLink.objectType.primaryKey} not found in ${objectTypeWithLink.objectType.apiName}`);\n }\n // saved ontology.json files may not have this implementsInterfaces2 so we need to handle\n if (objectTypeWithLink.implementsInterfaces2 == null\n && objectTypeWithLink.implementsInterfaces != null) {\n throw new Error(\"Your ontology.json file is missing the implementsInterfaces2 field. Please regenerate it.\");\n }\n const interfaceMap = objectTypeWithLink.implementsInterfaces2\n ? Object.fromEntries(Object.entries(objectTypeWithLink.implementsInterfaces2).map(([interfaceApiName, impl]) => [interfaceApiName, impl.properties]))\n : {};\n return {\n type: \"object\",\n apiName: objectTypeWithLink.objectType.apiName,\n description: objectTypeWithLink.objectType.description,\n primaryKeyApiName: objectTypeWithLink.objectType.primaryKey,\n primaryKeyType: wirePropertyV2ToSdkPrimaryKeyTypeDefinition(objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey]),\n links: Object.fromEntries(objectTypeWithLink.linkTypes.map(linkType => {\n return [linkType.apiName, {\n multiplicity: linkType.cardinality === \"MANY\",\n targetType: linkType.objectTypeApiName,\n }];\n })),\n properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key)),\n ])),\n implements: objectTypeWithLink.implementsInterfaces,\n interfaceMap,\n inverseInterfaceMap: Object.fromEntries(Object.entries(interfaceMap).map(([interfaceApiName, props]) => [interfaceApiName, invertProps(props)])),\n icon: supportedIconTypes.includes(objectTypeWithLink.objectType.icon.type)\n ? objectTypeWithLink.objectType.icon\n : undefined,\n titleProperty: objectTypeWithLink.objectType.titleProperty,\n displayName: objectTypeWithLink.objectType.displayName,\n pluralDisplayName: objectTypeWithLink.objectType.pluralDisplayName,\n status: objectTypeWithLink.objectType.status,\n rid: objectTypeWithLink.objectType.rid,\n visibility: objectTypeWithLink.objectType.visibility,\n };\n}\nfunction invertProps(a) {\n return (a\n ? Object.fromEntries(Object.entries(a).map(([k, v]) => [v, k]))\n : undefined);\n}\nconst supportedIconTypes = [\"blueprint\"];\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,2CAA2C,QAAQ,kDAAkD;AAC9G,SAASC,qCAAqC,QAAQ,4CAA4C;AAClG,OAAO,SAASC,6CAA6CA,CAACC,kBAAkB,EAAEC,EAAE,EAAE;EAClF,IAAID,kBAAkB,CAACE,UAAU,CAC5BC,UAAU,CAACH,kBAAkB,CAACE,UAAU,CAACE,UAAU,CAAC,KAAKC,SAAS,EAAE;IACrE,MAAM,IAAIC,KAAK,CAAC,eAAeN,kBAAkB,CAACE,UAAU,CAACE,UAAU,iBAAiBJ,kBAAkB,CAACE,UAAU,CAACK,OAAO,EAAE,CAAC;EACpI;EACA;EACA,IAAIP,kBAAkB,CAACQ,qBAAqB,IAAI,IAAI,IAC7CR,kBAAkB,CAACS,oBAAoB,IAAI,IAAI,EAAE;IACpD,MAAM,IAAIH,KAA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AAE9B,kBAAkB,CAACS,oBAAoB;IACnDC,YAAY;IACZqB,mBAAmB,EAAEpB,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAACH,YAAY,CAAC,CAACI,GAAG,CAAC,CAAC,CAACC,gBAAgB,EAAEiB,KAAK,CAAC,KAAK,CAACjB,gBAAgB,EAAEkB,WAAW,CAACD,KAAK,CAAC,CAAC,CAAC,CAAC;IAChJE,IAAI,EAAEC,kBAAkB,CAACC,QAAQ,CAACpC,kBAAkB,CAACE,UAAU,CAACgC,IAAI,CAACjB,IAAI,CAAC,GACpEjB,kBAAkB,CAACE,UAAU,CAACgC,IAAI,GAClC7B,SAAS;IACfgC,aAAa,EAAErC,kBAAkB,CAACE,UAAU,CAACmC,aAAa;IAC1DC,WAAW,EAAEtC,kBAAkB,CAACE,UAAU,CAACoC,WAAW;IACtDC,iBAAiB,EAAEvC,kBAAkB,CAACE,UAAU,CAACqC,iBAAiB;IAClEC,MAAM,EAAExC,kBAAkB,CAACE,UAAU,CAACsC,MAAM;IAC5CC,GAAG,EAAEzC,kBAAkB,CAACE,UAAU,CAACuC,GAAG;IACtCC,UAAU,EAAE1C,kBAAkB,CAACE,UAAU,CAACwC;EAC9C,CAAC;AACL;AACA,SAAST,WAAWA,CAACU,CAAC,EAAE;EACpB,OAAQA,CAAC,GACHhC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAAC8B,CAAC,CAAC,CAAC7B,GAAG,CAAC,CAAC,CAAC8B,CAAC,EAAEC,CAAC,CAAC,KAAK,CAACA,CAAC,EAAED,CAAC,CAAC,CAAC,CAAC,GAC7DvC,SAAS;AACnB;AACA,MAAM8B,kBAAkB,GAAG,CAAC,WAAW,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"wireObjectTypeFullMetadataToSdkObjectMetadata.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","wirePropertyV2ToSdkPropertyDefinition","wireObjectTypeFullMetadataToSdkObjectMetadata","objectTypeWithLink","v2","objectType","properties","primaryKey","undefined","Error","apiName","implementsInterfaces2","implementsInterfaces","interfaceMap","Object","fromEntries","entries","map","interfaceApiName","impl","type","description","primaryKeyApiName","primaryKeyType","links","linkTypes","linkType","multiplicity","cardinality","targetType","objectTypeApiName","key","value","filter","implements","inverseInterfaceMap","props","invertProps","icon","supportedIconTypes","includes","titleProperty","displayName","pluralDisplayName","status","rid","visibility","a","k","v"],"sources":["wireObjectTypeFullMetadataToSdkObjectMetadata.js"],"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 */\nimport { wirePropertyV2ToSdkPrimaryKeyTypeDefinition } from \"./wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js\";\nimport { wirePropertyV2ToSdkPropertyDefinition } from \"./wirePropertyV2ToSdkPropertyDefinition.js\";\nexport function wireObjectTypeFullMetadataToSdkObjectMetadata(objectTypeWithLink, v2) {\n if (objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey] === undefined) {\n throw new Error(`Primary key ${objectTypeWithLink.objectType.primaryKey} not found in ${objectTypeWithLink.objectType.apiName}`);\n }\n // saved ontology.json files may not have this implementsInterfaces2 so we need to handle\n if (objectTypeWithLink.implementsInterfaces2 == null\n && objectTypeWithLink.implementsInterfaces != null) {\n throw new Error(\"Your ontology.json file is missing the implementsInterfaces2 field. Please regenerate it.\");\n }\n const interfaceMap = objectTypeWithLink.implementsInterfaces2\n ? Object.fromEntries(Object.entries(objectTypeWithLink.implementsInterfaces2).map(([interfaceApiName, impl]) => [interfaceApiName, impl.properties]))\n : {};\n return {\n type: \"object\",\n apiName: objectTypeWithLink.objectType.apiName,\n description: objectTypeWithLink.objectType.description,\n primaryKeyApiName: objectTypeWithLink.objectType.primaryKey,\n primaryKeyType: wirePropertyV2ToSdkPrimaryKeyTypeDefinition(objectTypeWithLink.objectType\n .properties[objectTypeWithLink.objectType.primaryKey]),\n links: Object.fromEntries(objectTypeWithLink.linkTypes.map(linkType => {\n return [linkType.apiName, {\n multiplicity: linkType.cardinality === \"MANY\",\n targetType: linkType.objectTypeApiName,\n }];\n })),\n properties: Object.fromEntries(Object.entries(objectTypeWithLink.objectType.properties).map(([key, value]) => [\n key,\n wirePropertyV2ToSdkPropertyDefinition(value, !(v2 && objectTypeWithLink.objectType.primaryKey === key)),\n ]).filter(([key, value]) => value != null)),\n implements: objectTypeWithLink.implementsInterfaces,\n interfaceMap,\n inverseInterfaceMap: Object.fromEntries(Object.entries(interfaceMap).map(([interfaceApiName, props]) => [interfaceApiName, invertProps(props)])),\n icon: supportedIconTypes.includes(objectTypeWithLink.objectType.icon.type)\n ? objectTypeWithLink.objectType.icon\n : undefined,\n titleProperty: objectTypeWithLink.objectType.titleProperty,\n displayName: objectTypeWithLink.objectType.displayName,\n pluralDisplayName: objectTypeWithLink.objectType.pluralDisplayName,\n status: objectTypeWithLink.objectType.status,\n rid: objectTypeWithLink.objectType.rid,\n visibility: objectTypeWithLink.objectType.visibility,\n };\n}\nfunction invertProps(a) {\n return (a\n ? Object.fromEntries(Object.entries(a).map(([k, v]) => [v, k]))\n : undefined);\n}\nconst supportedIconTypes = [\"blueprint\"];\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,2CAA2C,QAAQ,kDAAkD;AAC9G,SAASC,qCAAqC,QAAQ,4CAA4C;AAClG,OAAO,SAASC,6CAA6CA,CAACC,kBAAkB,EAAEC,EAAE,EAAE;EAClF,IAAID,kBAAkB,CAACE,UAAU,CAC5BC,UA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AC,GACHjC,MAAM,CAACC,WAAW,CAACD,MAAM,CAACE,OAAO,CAAC+B,CAAC,CAAC,CAAC9B,GAAG,CAAC,CAAC,CAAC+B,CAAC,EAAEC,CAAC,CAAC,KAAK,CAACA,CAAC,EAAED,CAAC,CAAC,CAAC,CAAC,GAC7DxC,SAAS;AACnB;AACA,MAAM+B,kBAAkB,GAAG,CAAC,WAAW,CAAC","ignoreList":[]}
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAE9D,wBAAgB,2CAA2C,CACzD,KAAK,EAAE,UAAU,GAChB,eAAe,CAoCjB"}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPrimaryKeyTypeDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AACjD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAE9D,wBAAgB,2CAA2C,CACzD,KAAK,EAAE,UAAU,GAChB,eAAe,CAsCjB"}
@@ -43,6 +43,8 @@ export function wirePropertyV2ToSdkPrimaryKeyTypeDefinition(input) {
43
43
  case "float":
44
44
  case "geotimeSeriesReference":
45
45
  case "mediaReference":
46
+ case "struct":
47
+ case "cipherText":
46
48
  throw new Error(`Type not supported for primaryKey: ${input.dataType.type}`);
47
49
  default:
48
50
  input.dataType;
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","input","dataType","type","Error"],"sources":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js"],"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 */\nexport function wirePropertyV2ToSdkPrimaryKeyTypeDefinition(input) {\n switch (input.dataType.type) {\n case \"integer\":\n case \"double\":\n case \"string\":\n case \"boolean\":\n case \"byte\":\n case \"long\":\n case \"short\": {\n return input.dataType.type;\n }\n case \"date\": {\n return \"datetime\";\n }\n case \"timestamp\": {\n return \"timestamp\";\n }\n case \"geopoint\":\n case \"geoshape\":\n case \"decimal\":\n case \"attachment\":\n case \"timeseries\":\n case \"array\":\n case \"marking\":\n case \"float\":\n case \"geotimeSeriesReference\":\n case \"mediaReference\":\n throw new Error(`Type not supported for primaryKey: ${input.dataType.type}`);\n default:\n const _ = input.dataType;\n throw new Error(`Unknown type encountered for primaryKey: ${input.dataType}`);\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,2CAA2CA,CAACC,KAAK,EAAE;EAC/D,QAAQA,KAAK,CAACC,QAAQ,CAACC,IAAI;IACvB,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,QAAQ;IACb,KAAK,SAAS;IACd,KAAK,MAAM;IACX,KAAK,MAAM;IACX,KAAK,OAAO;MAAE;QACV,OAAOF,KAAK,CAACC,QAAQ,CAACC,IAAI;MAC9B;IACA,KAAK,MAAM;MAAE;QACT,OAAO,UAAU;MACrB;IACA,KAAK,WAAW;MAAE;QACd,OAAO,WAAW;MACtB;IACA,KAAK,UAAU;IACf,KAAK,UAAU;IACf,KAAK,SAAS;IACd,KAAK,YAAY;IACjB,KAAK,YAAY;IACjB,KAAK,OAAO;IACZ,KAAK,SAAS;IACd,KAAK,OAAO;IACZ,KAAK,wBAAwB;IAC7B,KAAK,gBAAgB;MACjB,MAAM,IAAIC,KAAK,CAAC,sCAAsCH,KAAK,CAACC,QAAQ,CAACC,IAAI,EAAE,CAAC;IAChF;MACcF,KAAK,CAACC,QAAQ;MACxB,MAAM,IAAIE,KAAK,CAAC,4CAA4CH,KAAK,CAACC,QAAQ,EAAE,CAAC;EACrF;AACJ","ignoreList":[]}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js","names":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition","input","dataType","type","Error"],"sources":["wirePropertyV2ToSdkPrimaryKeyTypeDefinition.js"],"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 */\nexport function wirePropertyV2ToSdkPrimaryKeyTypeDefinition(input) {\n switch (input.dataType.type) {\n case \"integer\":\n case \"double\":\n case \"string\":\n case \"boolean\":\n case \"byte\":\n case \"long\":\n case \"short\": {\n return input.dataType.type;\n }\n case \"date\": {\n return \"datetime\";\n }\n case \"timestamp\": {\n return \"timestamp\";\n }\n case \"geopoint\":\n case \"geoshape\":\n case \"decimal\":\n case \"attachment\":\n case \"timeseries\":\n case \"array\":\n case \"marking\":\n case \"float\":\n case \"geotimeSeriesReference\":\n case \"mediaReference\":\n case \"struct\":\n case \"cipherText\":\n throw new Error(`Type not supported for primaryKey: ${input.dataType.type}`);\n default:\n const _ = input.dataType;\n throw new Error(`Unknown type encountered for primaryKey: ${input.dataType}`);\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,2CAA2CA,CAACC,KAAK,EAAE;EAC/D,QAAQA,KAAK,CAACC,QAAQ,CAACC,IAAI;IACvB,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,QAAQ;IACb,KAAK,SAAS;IACd,KAAK,MAAM;IACX,KAAK,MAAM;IACX,KAAK,OAAO;MAAE;QACV,OAAOF,KAAK,CAACC,QAAQ,CAACC,IAAI;MAC9B;IACA,KAAK,MAAM;MAAE;QACT,OAAO,UAAU;MACrB;IACA,KAAK,WAAW;MAAE;QACd,OAAO,WAAW;MACtB;IACA,KAAK,UAAU;IACf,KAAK,UAAU;IACf,KAAK,SAAS;IACd,KAAK,YAAY;IACjB,KAAK,YAAY;IACjB,KAAK,OAAO;IACZ,KAAK,SAAS;IACd,KAAK,OAAO;IACZ,KAAK,wBAAwB;IAC7B,KAAK,gBAAgB;IACrB,KAAK,QAAQ;IACb,KAAK,YAAY;MACb,MAAM,IAAIC,KAAK,CAAC,sCAAsCH,KAAK,CAACC,QAAQ,CAACC,IAAI,EAAE,CAAC;IAChF;MACcF,KAAK,CAACC,QAAQ;MACxB,MAAM,IAAIE,KAAK,CAAC,4CAA4CH,KAAK,CAACC,QAAQ,EAAE,CAAC;EACrF;AACJ","ignoreList":[]}
@@ -2,5 +2,5 @@ import type { ObjectMetadata } from "@osdk/api";
2
2
  import type { PropertyV2, SharedPropertyType } from "@osdk/internal.foundry.core";
3
3
  export declare function wirePropertyV2ToSdkPropertyDefinition(input: (PropertyV2 | SharedPropertyType) & {
4
4
  nullable?: boolean;
5
- }, isNullable?: boolean): ObjectMetadata.Property;
5
+ }, isNullable?: boolean): ObjectMetadata.Property | undefined;
6
6
  //# sourceMappingURL=wirePropertyV2ToSdkPropertyDefinition.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPropertyDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,cAAc,EAAqB,MAAM,WAAW,CAAC;AACnE,OAAO,KAAK,EAEV,UAAU,EACV,kBAAkB,EACnB,MAAM,6BAA6B,CAAC;AAErC,wBAAgB,qCAAqC,CACnD,KAAK,EAAE,CAAC,UAAU,GAAG,kBAAkB,CAAC,GAAG;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,EACjE,UAAU,GAAE,OAAc,GACzB,cAAc,CAAC,QAAQ,CA8CzB"}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.d.ts","sourceRoot":"","sources":["../../src/wirePropertyV2ToSdkPropertyDefinition.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EACV,cAAc,EAGf,MAAM,WAAW,CAAC;AACnB,OAAO,KAAK,EAEV,UAAU,EACV,kBAAkB,EACnB,MAAM,6BAA6B,CAAC;AAGrC,wBAAgB,qCAAqC,CACnD,KAAK,EAAE,CAAC,UAAU,GAAG,kBAAkB,CAAC,GAAG;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,EACjE,UAAU,GAAE,OAAc,GACzB,cAAc,CAAC,QAAQ,GAAG,SAAS,CAwDrC"}
@@ -13,7 +13,12 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
+ import { consola } from "consola";
16
17
  export function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true) {
18
+ const sdkPropDefinition = objectPropertyTypeToSdkPropertyDefinition(input.dataType);
19
+ if (sdkPropDefinition == null) {
20
+ return undefined;
21
+ }
17
22
  switch (input.dataType.type) {
18
23
  case "integer":
19
24
  case "string":
@@ -32,11 +37,12 @@ export function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true)
32
37
  case "timeseries":
33
38
  case "marking":
34
39
  case "geotimeSeriesReference":
40
+ case "struct":
35
41
  return {
36
42
  displayName: input.displayName,
37
43
  multiplicity: false,
38
44
  description: input.description,
39
- type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),
45
+ type: sdkPropDefinition,
40
46
  nullable: input.nullable == null ? isNullable : input.nullable
41
47
  };
42
48
  case "array":
@@ -45,17 +51,20 @@ export function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true)
45
51
  displayName: input.displayName,
46
52
  multiplicity: true,
47
53
  description: input.description,
48
- type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),
54
+ type: sdkPropDefinition,
49
55
  nullable: true
50
56
  };
51
57
  }
58
+ case "cipherText":
52
59
  case "mediaReference":
53
60
  {
54
- throw new Error(`Media references not supported yet`);
61
+ consola.info(`${JSON.stringify(input.dataType.type)} is not a supported dataType`);
62
+ return undefined;
55
63
  }
56
64
  default:
57
65
  input.dataType;
58
- throw new Error(`Unexpected data type ${JSON.stringify(input.dataType)}`);
66
+ consola.info(`${JSON.stringify(input.dataType)} is not a supported dataType`);
67
+ return undefined;
59
68
  }
60
69
  }
61
70
  function objectPropertyTypeToSdkPropertyDefinition(propertyType) {
@@ -86,12 +95,24 @@ function objectPropertyTypeToSdkPropertyDefinition(propertyType) {
86
95
  } else if (propertyType.itemType?.type === "double") {
87
96
  return "numericTimeseries";
88
97
  } else return "sensorTimeseries";
98
+ case "struct":
99
+ {
100
+ return propertyType.structFieldTypes.reduce((structMap, structField) => {
101
+ structMap[structField.apiName] = objectPropertyTypeToSdkPropertyDefinition(structField.dataType);
102
+ return structMap;
103
+ }, {});
104
+ }
89
105
  case "mediaReference":
106
+ case "cipherText":
90
107
  {
91
- throw new Error(`Media references not supported yet`);
108
+ consola.info(`${JSON.stringify(propertyType.type)} is not a supported propertyType`);
109
+ return undefined;
92
110
  }
93
111
  default:
94
- throw new Error(`Unexpected data type ${JSON.stringify(propertyType)}`);
112
+ {
113
+ consola.info(`${JSON.stringify(propertyType)} is not a supported propertyType`);
114
+ return undefined;
115
+ }
95
116
  }
96
117
  }
97
118
  //# sourceMappingURL=wirePropertyV2ToSdkPropertyDefinition.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.js","names":["wirePropertyV2ToSdkPropertyDefinition","input","isNullable","dataType","type","displayName","multiplicity","description","objectPropertyTypeToSdkPropertyDefinition","nullable","Error","JSON","stringify","propertyType","subType","itemType"],"sources":["wirePropertyV2ToSdkPropertyDefinition.js"],"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 */\nexport function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true) {\n switch (input.dataType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"date\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"timeseries\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n return {\n displayName: input.displayName,\n multiplicity: false,\n description: input.description,\n type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),\n nullable: input.nullable == null ? isNullable : input.nullable,\n };\n case \"array\": {\n return {\n displayName: input.displayName,\n multiplicity: true,\n description: input.description,\n type: objectPropertyTypeToSdkPropertyDefinition(input.dataType),\n nullable: true,\n };\n }\n case \"mediaReference\": {\n throw new Error(`Media references not supported yet`);\n }\n default:\n const _ = input.dataType;\n throw new Error(`Unexpected data type ${JSON.stringify(input.dataType)}`);\n }\n}\nfunction objectPropertyTypeToSdkPropertyDefinition(propertyType) {\n switch (propertyType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n return propertyType.type;\n case \"date\":\n return \"datetime\";\n case \"array\":\n return objectPropertyTypeToSdkPropertyDefinition(propertyType.subType);\n case \"timeseries\":\n if (propertyType.itemType?.type === \"string\") {\n return \"stringTimeseries\";\n }\n else if (propertyType.itemType?.type === \"double\") {\n return \"numericTimeseries\";\n }\n else\n return \"sensorTimeseries\";\n case \"mediaReference\": {\n throw new Error(`Media references not supported yet`);\n }\n default:\n const _ = propertyType;\n throw new Error(`Unexpected data type ${JSON.stringify(propertyType)}`);\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,qCAAqCA,CAACC,KAAK,EAAEC,UAAU,GAAG,IAAI,EAAE;EAC5E,QAAQD,KAAK,CAACE,QAAQ,CAACC,IAAI;IACvB,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,MAAM;IACX,KAAK,SAAS;IACd,KAAK,QAAQ;IACb,KAAK,OAAO;IACZ,KAAK,MAAM;IACX,KAAK,OAAO;IACZ,KAAK,SAAS;IACd,KAAK,MAAM;IACX,KAAK,YAAY;IACjB,KAAK,UAAU;IACf,KAAK,UAAU;IACf,KAAK,WAAW;IAChB,KAAK,YAAY;IACjB,KAAK,SAAS;IACd,KAAK,wBAAwB;MACzB,OAAO;QACHC,WAAW,EAAEJ,KAAK,CAACI,WAAW;QAC9BC,YAAY,EAAE,KAAK;QACnBC,WAAW,EAAEN,KAAK,CAACM,WAAW;QAC9BH,IAAI,EAAEI,yCAAyC,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Q,EAAE;QAC/C,OAAO,mBAAmB;MAC9B,CAAC,MAEG,OAAO,kBAAkB;IACjC,KAAK,gBAAgB;MAAE;QACnB,MAAM,IAAIM,KAAK,CAAC,oCAAoC,CAAC;MACzD;IACA;MAEI,MAAM,IAAIA,KAAK,CAAC,wBAAwBC,IAAI,CAACC,SAAS,CAACC,YAAY,CAAC,EAAE,CAAC;EAC/E;AACJ","ignoreList":[]}
1
+ {"version":3,"file":"wirePropertyV2ToSdkPropertyDefinition.js","names":["consola","wirePropertyV2ToSdkPropertyDefinition","input","isNullable","sdkPropDefinition","objectPropertyTypeToSdkPropertyDefinition","dataType","undefined","type","displayName","multiplicity","description","nullable","info","JSON","stringify","propertyType","subType","itemType","structFieldTypes","reduce","structMap","structField","apiName"],"sources":["wirePropertyV2ToSdkPropertyDefinition.js"],"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 */\nimport { consola } from \"consola\";\nexport function wirePropertyV2ToSdkPropertyDefinition(input, isNullable = true) {\n const sdkPropDefinition = objectPropertyTypeToSdkPropertyDefinition(input.dataType);\n if (sdkPropDefinition == null) {\n return undefined;\n }\n switch (input.dataType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"date\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"timeseries\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n case \"struct\":\n return {\n displayName: input.displayName,\n multiplicity: false,\n description: input.description,\n type: sdkPropDefinition,\n nullable: input.nullable == null ? isNullable : input.nullable,\n };\n case \"array\": {\n return {\n displayName: input.displayName,\n multiplicity: true,\n description: input.description,\n type: sdkPropDefinition,\n nullable: true,\n };\n }\n case \"cipherText\":\n case \"mediaReference\": {\n consola.info(`${JSON.stringify(input.dataType.type)} is not a supported dataType`);\n return undefined;\n }\n default:\n const _ = input.dataType;\n consola.info(`${JSON.stringify(input.dataType)} is not a supported dataType`);\n return undefined;\n }\n}\nfunction objectPropertyTypeToSdkPropertyDefinition(propertyType) {\n switch (propertyType.type) {\n case \"integer\":\n case \"string\":\n case \"byte\":\n case \"decimal\":\n case \"double\":\n case \"float\":\n case \"long\":\n case \"short\":\n case \"boolean\":\n case \"attachment\":\n case \"geopoint\":\n case \"geoshape\":\n case \"timestamp\":\n case \"marking\":\n case \"geotimeSeriesReference\":\n return propertyType.type;\n case \"date\":\n return \"datetime\";\n case \"array\":\n return objectPropertyTypeToSdkPropertyDefinition(propertyType.subType);\n case \"timeseries\":\n if (propertyType.itemType?.type === \"string\") {\n return \"stringTimeseries\";\n }\n else if (propertyType.itemType?.type === \"double\") {\n return \"numericTimeseries\";\n }\n else\n return \"sensorTimeseries\";\n case \"struct\": {\n return propertyType.structFieldTypes.reduce((structMap, structField) => {\n structMap[structField.apiName] =\n objectPropertyTypeToSdkPropertyDefinition(structField.dataType);\n return structMap;\n }, {});\n }\n case \"mediaReference\":\n case \"cipherText\": {\n consola.info(`${JSON.stringify(propertyType.type)} is not a supported propertyType`);\n return undefined;\n }\n default: {\n const _ = propertyType;\n consola.info(`${JSON.stringify(propertyType)} is not a supported propertyType`);\n return undefined;\n }\n }\n}\n"],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,SAASA,OAAO,QAAQ,SAAS;AACjC,OAAO,SAASC,qCAAqCA,CAACC,KAAK,EAAEC,UAAU,GAAG,IAAI,EAAE;EAC5E,MAAMC,iBA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IAAI,CAACC,SAAS,CAACC,YAAY,CAAC,kCAAkC,CAAC;QAC/E,OAAOT,SAAS;MACpB;EACJ;AACJ","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@osdk/generator-converters",
3
- "version": "2.1.0-beta.19",
3
+ "version": "2.1.0-beta.20",
4
4
  "description": "",
5
5
  "access": "public",
6
6
  "license": "Apache-2.0",
@@ -21,16 +21,17 @@
21
21
  }
22
22
  },
23
23
  "dependencies": {
24
- "@osdk/internal.foundry.core": "2.6.0-beta.1",
25
- "@osdk/api": "~2.1.0-beta.19"
24
+ "@osdk/internal.foundry.core": "2.8.0",
25
+ "consola": "^3.2.3",
26
+ "@osdk/api": "~2.1.0-beta.20"
26
27
  },
27
28
  "devDependencies": {
28
29
  "ts-expect": "^1.3.0",
29
30
  "typescript": "~5.5.4",
30
31
  "vitest": "^2.1.2",
31
32
  "@osdk/monorepo.api-extractor": "~0.0.0",
32
- "@osdk/monorepo.tsup": "~0.0.0",
33
- "@osdk/monorepo.tsconfig": "~0.0.0"
33
+ "@osdk/monorepo.tsconfig": "~0.0.0",
34
+ "@osdk/monorepo.tsup": "~0.0.0"
34
35
  },
35
36
  "publishConfig": {
36
37
  "access": "public"