Browse Source

rename to transform

JonStargaryen 4 years ago
parent
commit
e3768805a6

+ 1 - 1
src/servers/model/server/api-web.ts

@@ -64,7 +64,7 @@ function mapQuery(app: express.Express, queryName: string, queryDefinition: Quer
                 queryParams,
                 modelNums: commonParams.model_nums,
                 copyAllCategories: !!commonParams.copy_all_categories,
-                transformation: commonParams.transformation
+                transform: commonParams.transform
             })],
             writer: createResultWriter(res, commonParams.encoding!, entryId, queryName),
             options: { binary: commonParams.encoding === 'bcif', encoding: commonParams.encoding }

+ 2 - 2
src/servers/model/server/api.ts

@@ -57,7 +57,7 @@ export interface CommonQueryParamsInfo {
     encoding?: Encoding,
     copy_all_categories?: boolean
     data_source?: string,
-    transformation?: Mat4
+    transform?: Mat4
 }
 
 export const AtomSiteSchemaElement = {
@@ -292,7 +292,7 @@ export function normalizeRestCommonParams(params: any): CommonQueryParamsInfo {
         data_source: params.data_source,
         copy_all_categories: Boolean(params.copy_all_categories),
         encoding: mapEncoding(('' + params.encoding).toLocaleLowerCase()),
-        transformation: params.transformation ? createMat4(('' + params.transformation).split(',').map(n => n.trim()).map(n => +n)) : Mat4.identity()
+        transform: params.transform ? createMat4(('' + params.transform).split(',').map(n => n.trim()).map(n => +n)) : Mat4.identity()
     };
 }
 

+ 3 - 3
src/servers/model/server/jobs.ts

@@ -43,7 +43,7 @@ export interface JobEntry {
     normalizedParams: any,
     modelNums?: number[],
     copyAllCategories: boolean,
-    transformation?: Mat4
+    transform?: Mat4
 }
 
 interface JobEntryDefinition<Name extends QueryName> {
@@ -53,7 +53,7 @@ interface JobEntryDefinition<Name extends QueryName> {
     queryParams: QueryParams<Name>,
     modelNums?: number[],
     copyAllCategories: boolean,
-    transformation?: Mat4
+    transform?: Mat4
 }
 
 export function JobEntry<Name extends QueryName>(definition: JobEntryDefinition<Name>): JobEntry {
@@ -72,7 +72,7 @@ export function JobEntry<Name extends QueryName>(definition: JobEntryDefinition<
         normalizedParams,
         modelNums: definition.modelNums,
         copyAllCategories: !!definition.copyAllCategories,
-        transformation: definition.transformation
+        transform: definition.transform
     };
 }
 

+ 2 - 2
src/servers/model/server/query.ts

@@ -216,10 +216,10 @@ async function resolveJobEntry(entry: JobEntry, structure: StructureWrapper, enc
         for (let i = 0; i < structures.length; i++) {
             const s = StructureSelection.unionStructure(StructureQuery.run(queries[i], structures[i], { timeoutMs: Config.queryTimeoutMs }));
             if (s.elementCount > 0) {
-                if (!entry.transformation || Mat4.isIdentity(entry.transformation)) {
+                if (!entry.transform || Mat4.isIdentity(entry.transform)) {
                     result.push(s);
                 } else {
-                    result.push(Structure.transform(s, entry.transformation));
+                    result.push(Structure.transform(s, entry.transform));
                 }
             }
         }