bruce-models 7.1.84 → 7.1.85
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/dist/bruce-models.es5.js +20 -1
- package/dist/bruce-models.es5.js.map +1 -1
- package/dist/bruce-models.umd.js +20 -1
- package/dist/bruce-models.umd.js.map +1 -1
- package/dist/lib/bruce-models.js +1 -1
- package/dist/lib/import/import-assembly.js +19 -0
- package/dist/lib/import/import-assembly.js.map +1 -1
- package/dist/types/bruce-models.d.ts +1 -1
- package/dist/types/import/import-assembly.d.ts +22 -5
- package/package.json +1 -1
package/dist/lib/bruce-models.js
CHANGED
|
@@ -131,5 +131,5 @@ __exportStar(require("./util/object-utils"), exports);
|
|
|
131
131
|
__exportStar(require("./util/path-utils"), exports);
|
|
132
132
|
__exportStar(require("./util/url-utils"), exports);
|
|
133
133
|
// This is updated with the package.json version on build.
|
|
134
|
-
exports.VERSION = "7.1.
|
|
134
|
+
exports.VERSION = "7.1.85";
|
|
135
135
|
//# sourceMappingURL=bruce-models.js.map
|
|
@@ -49,5 +49,24 @@ var ImportAssembly;
|
|
|
49
49
|
return null;
|
|
50
50
|
}
|
|
51
51
|
ImportAssembly.ParseAnalysisResult = ParseAnalysisResult;
|
|
52
|
+
/**
|
|
53
|
+
* Returns the analysis itself, wherever the API decided to put it.
|
|
54
|
+
*/
|
|
55
|
+
function ResolveAnalysisResult(params) {
|
|
56
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
57
|
+
let { api, paResult, req: reqParams } = params;
|
|
58
|
+
const parsed = ParseAnalysisResult(paResult);
|
|
59
|
+
const tempFileId = parsed === null || parsed === void 0 ? void 0 : parsed["Analysis.TempFile.ID"];
|
|
60
|
+
if (!parsed || !tempFileId) {
|
|
61
|
+
return parsed;
|
|
62
|
+
}
|
|
63
|
+
if (!api) {
|
|
64
|
+
api = environment_1.ENVIRONMENT.Api().GetBruceApi();
|
|
65
|
+
}
|
|
66
|
+
const analysis = yield api.GET("tempfile/" + tempFileId, api_1.Api.PrepReqParams(reqParams));
|
|
67
|
+
return typeof analysis === "string" ? ParseAnalysisResult(analysis) : analysis;
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
ImportAssembly.ResolveAnalysisResult = ResolveAnalysisResult;
|
|
52
71
|
})(ImportAssembly = exports.ImportAssembly || (exports.ImportAssembly = {}));
|
|
53
72
|
//# sourceMappingURL=import-assembly.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"import-assembly.js","sourceRoot":"","sources":["../../../src/import/import-assembly.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oCAAiC;AAGjC,gDAA6C;AAE7C,IAAiB,cAAc,
|
|
1
|
+
{"version":3,"file":"import-assembly.js","sourceRoot":"","sources":["../../../src/import/import-assembly.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,oCAAiC;AAGjC,gDAA6C;AAE7C,IAAiB,cAAc,CAsJ9B;AAtJD,WAAiB,cAAc;IA+C3B,SAAsB,OAAO,CAAC,MAI7B;;YACG,IAAI,EAAE,GAAG,EAAE,WAAW,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC;YAClD,IAAI,CAAC,GAAG,EAAE;gBACN,GAAG,GAAG,yBAAW,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE,CAAC;aACzC;YAED,OAAO,GAAG,CAAC,IAAI,CAAC,yBAAyB,EAAE,WAAW,EAAE,SAAG,CAAC,aAAa,CAAC,SAAS,CAAC,CAAC,CAAC;QAC1F,CAAC;KAAA;IAXqB,sBAAO,UAW5B,CAAA;IAED,SAAsB,cAAc,CAAC,MAIpC;;YACG,IAAI,EAAE,GAAG,EAAE,UAAU,EAAE,GAAG,EAAE,SAAS,EAAE,GAAG,MAAM,CAAC;YACjD,IAAI,CAAC,GAAG,EAAE;gBACN,GAAG,GAAG,yBAAW,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE,CAAC;aACzC;YAED,OAAO,GAAG,CA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}
|
|
@@ -7,6 +7,7 @@ export declare namespace ImportAssembly {
|
|
|
7
7
|
"TempFile.Name"?: string;
|
|
8
8
|
"ClientFile.ID"?: string;
|
|
9
9
|
"PrimaryProject"?: string;
|
|
10
|
+
"Analysis.AsTempFile"?: boolean;
|
|
10
11
|
}
|
|
11
12
|
interface IAnalyzeRes {
|
|
12
13
|
"PendingActionID": number;
|
|
@@ -46,16 +47,18 @@ export declare namespace ImportAssembly {
|
|
|
46
47
|
req?: Api.IReqParams;
|
|
47
48
|
}): Promise<IImportRes>;
|
|
48
49
|
/**
|
|
49
|
-
*
|
|
50
|
-
* This will return the root entity's id if any is present.
|
|
51
|
-
* @param paResult
|
|
50
|
+
* The analysis of an uploaded file, as produced by the analyze step.
|
|
52
51
|
*/
|
|
53
|
-
|
|
52
|
+
interface IAnalysisResult {
|
|
54
53
|
"TotalItems"?: number;
|
|
55
54
|
"Converted.TempFile.ID"?: string;
|
|
56
55
|
"Converted.ClientFile.ID"?: string;
|
|
57
56
|
"ClientFile.ID"?: string;
|
|
58
57
|
"TempFile.ID"?: string;
|
|
58
|
+
"Analysis.TempFile.ID"?: string;
|
|
59
|
+
"Analysis.TempFile.URL"?: string;
|
|
60
|
+
"Preview.TempFile.ID"?: string;
|
|
61
|
+
"ScaleToMeters"?: number;
|
|
59
62
|
"RecommendedSettings"?: {
|
|
60
63
|
"CreateStrictTypes"?: boolean;
|
|
61
64
|
"LoadTypeTemplates"?: boolean;
|
|
@@ -76,5 +79,19 @@ export declare namespace ImportAssembly {
|
|
|
76
79
|
"minZ": number;
|
|
77
80
|
};
|
|
78
81
|
"DataSchema"?: EntityType.IDataSchema;
|
|
79
|
-
}
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* Parses the completed pending action result from running "ImportEntities".
|
|
85
|
+
* This will return the root entity's id if any is present.
|
|
86
|
+
* @param paResult
|
|
87
|
+
*/
|
|
88
|
+
function ParseAnalysisResult(paResult: string | Object): IAnalysisResult;
|
|
89
|
+
/**
|
|
90
|
+
* Returns the analysis itself, wherever the API decided to put it.
|
|
91
|
+
*/
|
|
92
|
+
function ResolveAnalysisResult(params: {
|
|
93
|
+
api?: BruceApi.Api;
|
|
94
|
+
paResult: string | Object;
|
|
95
|
+
req?: Api.IReqParams;
|
|
96
|
+
}): Promise<IAnalysisResult>;
|
|
80
97
|
}
|