etincidunt 1.0.0
Sign up to get free protection for your applications and to get access to all the features.
- package/.prettierignore +2 -0
- package/.travis.yml +29 -0
- package/.vscode/launch.json +24 -0
- package/.vscode/settings.json +3 -0
- package/demos/ago-node-cli/README.md +29 -0
- package/demos/ago-node-cli/ago.js +32 -0
- package/demos/ago-node-cli/index.js +11 -0
- package/demos/ago-node-cli/lib/item-export-command.js +48 -0
- package/demos/ago-node-cli/lib/item-search-command.js +35 -0
- package/demos/ago-node-cli/package-lock.json +172 -0
- package/demos/ago-node-cli/package.json +30 -0
- package/demos/attachments/README.md +5 -0
- package/demos/attachments/index.html +164 -0
- package/demos/attachments/package-lock.json +182 -0
- package/demos/attachments/package.json +18 -0
- package/demos/batch-geocoder-node/NYC_Restaurant_Inspection_Results.csv +100 -0
- package/demos/batch-geocoder-node/README.md +14 -0
- package/demos/batch-geocoder-node/batch-geocode.js +112 -0
- package/demos/batch-geocoder-node/config-template.js +18 -0
- package/demos/batch-geocoder-node/package-lock.json +109 -0
- package/demos/batch-geocoder-node/package.json +37 -0
- package/demos/express/README.md +10 -0
- package/demos/express/config.json.template +3 -0
- package/demos/express/package-lock.json +388 -0
- package/demos/express/package.json +18 -0
- package/demos/express/server.js +28 -0
- package/demos/feature-service-browser/README.md +6 -0
- package/demos/feature-service-browser/index.html +122 -0
- package/demos/feature-service-browser/package-lock.json +182 -0
- package/demos/feature-service-browser/package.json +18 -0
- package/demos/geocoder-browser/README.md +10 -0
- package/demos/geocoder-browser/config.js.template +1 -0
- package/demos/geocoder-browser/index.html +131 -0
- package/demos/geocoder-browser/package-lock.json +163 -0
- package/demos/geocoder-browser/package.json +19 -0
- package/demos/geocoder-browser/post-sign-in.html +25 -0
- package/demos/jsapi-integration/README.md +8 -0
- package/demos/jsapi-integration/config.js +6 -0
- package/demos/jsapi-integration/index.html +79 -0
- package/demos/jsapi-integration/package-lock.json +184 -0
- package/demos/jsapi-integration/package.json +19 -0
- package/demos/oauth2-browser/README.md +12 -0
- package/demos/oauth2-browser/authenticate.html +32 -0
- package/demos/oauth2-browser/config.js.template +6 -0
- package/demos/oauth2-browser/index.html +202 -0
- package/demos/oauth2-browser/logo.svg +4 -0
- package/demos/oauth2-browser/package-lock.json +163 -0
- package/demos/oauth2-browser/package.json +18 -0
- package/demos/oauth2-browser/style.css +36 -0
- package/demos/vue/.babelrc +6 -0
- package/demos/vue/.env.example +8 -0
- package/demos/vue/README.md +17 -0
- package/demos/vue/index.html +21 -0
- package/demos/vue/package-lock.json +7236 -0
- package/demos/vue/package.json +39 -0
- package/demos/vue/src/assets/logo.svg +29 -0
- package/demos/vue/src/components/App.vue +302 -0
- package/demos/vue/src/components/Authenticate.vue +68 -0
- package/demos/vue/src/components/Loader.vue +216 -0
- package/demos/vue/src/main.js +75 -0
- package/demos/vue/webpack.config.js +84 -0
- package/docs/FAQ.md +28 -0
- package/docs/HISTORY.md +62 -0
- package/docs/acetate.config.js +214 -0
- package/docs/build-typedoc.js +301 -0
- package/docs/src/_layout.html +82 -0
- package/docs/src/api/_declaration.html +496 -0
- package/docs/src/api/_layout.html +127 -0
- package/docs/src/api/_package.html +13 -0
- package/docs/src/api/index.html +23 -0
- package/docs/src/guides/_layout.html +24 -0
- package/docs/src/guides/amd-requirejs-dojo.md +40 -0
- package/docs/src/guides/babel-and-rollup.md +30 -0
- package/docs/src/guides/babel-and-webpack.md +30 -0
- package/docs/src/guides/browser-authentication.md +9 -0
- package/docs/src/guides/browserify.md +9 -0
- package/docs/src/guides/cli-authentication.md +9 -0
- package/docs/src/guides/client-server-authentication.md +9 -0
- package/docs/src/guides/from-a-cdn.md +36 -0
- package/docs/src/guides/index.md +52 -0
- package/docs/src/guides/node.md +30 -0
- package/docs/src/guides/package-overview.md +8 -0
- package/docs/src/guides/server-authentication.md +9 -0
- package/docs/src/guides/typescript-and-webpack.md +9 -0
- package/docs/src/img/icons.png +0 -0
- package/docs/src/img/icons@2x.png +0 -0
- package/docs/src/index.html +12 -0
- package/docs/src/js/api-search.js +113 -0
- package/docs/src/js/index.js +1 -0
- package/docs/src/js/nav-toggle.js +41 -0
- package/docs/src/sass/_highlight.scss +96 -0
- package/docs/src/sass/_icons.scss +157 -0
- package/docs/src/sass/style.scss +169 -0
- package/jasmine.json +7 -0
- package/karma.conf.js +100 -0
- package/lerna.json +8 -0
- package/notes/README.md +88 -0
- package/package.json +91 -0
- package/packages/arcgis-rest-auth/README.md +64 -0
- package/packages/arcgis-rest-auth/package-lock.json +11 -0
- package/packages/arcgis-rest-auth/package.json +51 -0
- package/packages/arcgis-rest-auth/src/ApplicationSession.ts +91 -0
- package/packages/arcgis-rest-auth/src/UserSession.ts +829 -0
- package/packages/arcgis-rest-auth/src/authenticated-request-options.ts +21 -0
- package/packages/arcgis-rest-auth/src/fetch-token.ts +55 -0
- package/packages/arcgis-rest-auth/src/generate-token.ts +36 -0
- package/packages/arcgis-rest-auth/src/index.ts +5 -0
- package/packages/arcgis-rest-auth/test/ApplicationSession.test.ts +121 -0
- package/packages/arcgis-rest-auth/test/UserSession.test.ts +883 -0
- package/packages/arcgis-rest-auth/test/fetchToken.test.ts +76 -0
- package/packages/arcgis-rest-auth/test/generateToken.test.ts +36 -0
- package/packages/arcgis-rest-auth/test/utils.ts +11 -0
- package/packages/arcgis-rest-auth/tsconfig.json +6 -0
- package/packages/arcgis-rest-common-types/README.md +61 -0
- package/packages/arcgis-rest-common-types/package.json +38 -0
- package/packages/arcgis-rest-common-types/src/group.ts +51 -0
- package/packages/arcgis-rest-common-types/src/index.ts +467 -0
- package/packages/arcgis-rest-common-types/src/item.ts +45 -0
- package/packages/arcgis-rest-common-types/src/webmap.ts +1225 -0
- package/packages/arcgis-rest-common-types/tsconfig.json +11 -0
- package/packages/arcgis-rest-feature-service/README.md +70 -0
- package/packages/arcgis-rest-feature-service/package-lock.json +11 -0
- package/packages/arcgis-rest-feature-service/package.json +50 -0
- package/packages/arcgis-rest-feature-service/src/add.ts +82 -0
- package/packages/arcgis-rest-feature-service/src/addAttachment.ts +65 -0
- package/packages/arcgis-rest-feature-service/src/delete.ts +85 -0
- package/packages/arcgis-rest-feature-service/src/deleteAttachments.ts +68 -0
- package/packages/arcgis-rest-feature-service/src/getAttachments.ts +64 -0
- package/packages/arcgis-rest-feature-service/src/helpers.ts +77 -0
- package/packages/arcgis-rest-feature-service/src/index.ts +8 -0
- package/packages/arcgis-rest-feature-service/src/query.ts +174 -0
- package/packages/arcgis-rest-feature-service/src/update.ts +81 -0
- package/packages/arcgis-rest-feature-service/src/updateAttachment.ts +74 -0
- package/packages/arcgis-rest-feature-service/test/attachments.test.ts +179 -0
- package/packages/arcgis-rest-feature-service/test/features.test.ts +172 -0
- package/packages/arcgis-rest-feature-service/test/mocks/feature.ts +220 -0
- package/packages/arcgis-rest-feature-service/test/mocks/foo.txt +1 -0
- package/packages/arcgis-rest-feature-service/tsconfig.json +6 -0
- package/packages/arcgis-rest-geocoder/README.md +73 -0
- package/packages/arcgis-rest-geocoder/package-lock.json +11 -0
- package/packages/arcgis-rest-geocoder/package.json +52 -0
- package/packages/arcgis-rest-geocoder/src/bulk.ts +102 -0
- package/packages/arcgis-rest-geocoder/src/geocode.ts +117 -0
- package/packages/arcgis-rest-geocoder/src/helpers.ts +81 -0
- package/packages/arcgis-rest-geocoder/src/index.ts +4 -0
- package/packages/arcgis-rest-geocoder/src/reverse.ts +84 -0
- package/packages/arcgis-rest-geocoder/src/suggest.ts +72 -0
- package/packages/arcgis-rest-geocoder/test/geocoder.test.ts +510 -0
- package/packages/arcgis-rest-geocoder/test/mocks/responses.ts +588 -0
- package/packages/arcgis-rest-geocoder/tsconfig.json +6 -0
- package/packages/arcgis-rest-groups/README.md +64 -0
- package/packages/arcgis-rest-groups/package-lock.json +11 -0
- package/packages/arcgis-rest-groups/package.json +52 -0
- package/packages/arcgis-rest-groups/src/groups.ts +272 -0
- package/packages/arcgis-rest-groups/src/index.ts +1 -0
- package/packages/arcgis-rest-groups/test/groups.test.ts +280 -0
- package/packages/arcgis-rest-groups/test/mocks/responses.ts +137 -0
- package/packages/arcgis-rest-groups/tsconfig.json +6 -0
- package/packages/arcgis-rest-items/README.md +66 -0
- package/packages/arcgis-rest-items/package-lock.json +11 -0
- package/packages/arcgis-rest-items/package.json +52 -0
- package/packages/arcgis-rest-items/src/index.ts +1 -0
- package/packages/arcgis-rest-items/src/items.ts +498 -0
- package/packages/arcgis-rest-items/test/items.test.ts +1153 -0
- package/packages/arcgis-rest-items/test/mocks/foo.zip +0 -0
- package/packages/arcgis-rest-items/test/mocks/item.ts +30 -0
- package/packages/arcgis-rest-items/test/mocks/resources.ts +28 -0
- package/packages/arcgis-rest-items/test/mocks/search.ts +60 -0
- package/packages/arcgis-rest-items/tsconfig.json +6 -0
- package/packages/arcgis-rest-request/README.md +65 -0
- package/packages/arcgis-rest-request/package-lock.json +11 -0
- package/packages/arcgis-rest-request/package.json +42 -0
- package/packages/arcgis-rest-request/src/index.ts +10 -0
- package/packages/arcgis-rest-request/src/request.ts +259 -0
- package/packages/arcgis-rest-request/src/utils/ArcGISAuthError.ts +67 -0
- package/packages/arcgis-rest-request/src/utils/ArcGISRequestError.ts +73 -0
- package/packages/arcgis-rest-request/src/utils/ErrorTypes.ts +29 -0
- package/packages/arcgis-rest-request/src/utils/check-for-errors.ts +65 -0
- package/packages/arcgis-rest-request/src/utils/encode-form-data.ts +29 -0
- package/packages/arcgis-rest-request/src/utils/encode-query-string.ts +23 -0
- package/packages/arcgis-rest-request/src/utils/get-portal-url.ts +25 -0
- package/packages/arcgis-rest-request/src/utils/get-portal.ts +45 -0
- package/packages/arcgis-rest-request/src/utils/process-params.ts +99 -0
- package/packages/arcgis-rest-request/test/mocks/errors.ts +59 -0
- package/packages/arcgis-rest-request/test/mocks/geojson-feature-collection.ts +10 -0
- package/packages/arcgis-rest-request/test/mocks/portal.ts +109 -0
- package/packages/arcgis-rest-request/test/mocks/sharing-rest-info.ts +38 -0
- package/packages/arcgis-rest-request/test/mocks/webmap.ts +38 -0
- package/packages/arcgis-rest-request/test/request.test.ts +296 -0
- package/packages/arcgis-rest-request/test/utils/ArcGISAuthError.test.ts +167 -0
- package/packages/arcgis-rest-request/test/utils/ArcGISRequestError.test.ts +40 -0
- package/packages/arcgis-rest-request/test/utils/check-for-errors.test.ts +101 -0
- package/packages/arcgis-rest-request/test/utils/encode-form-data.test.ts +112 -0
- package/packages/arcgis-rest-request/test/utils/get-portal-url.test.ts +34 -0
- package/packages/arcgis-rest-request/test/utils/portal.test.ts +94 -0
- package/packages/arcgis-rest-request/test/utils/process-params.test.ts +190 -0
- package/packages/arcgis-rest-request/tsconfig.json +6 -0
- package/packages/arcgis-rest-sharing/README.md +67 -0
- package/packages/arcgis-rest-sharing/package-lock.json +11 -0
- package/packages/arcgis-rest-sharing/package.json +55 -0
- package/packages/arcgis-rest-sharing/src/access.ts +91 -0
- package/packages/arcgis-rest-sharing/src/group-sharing.ts +212 -0
- package/packages/arcgis-rest-sharing/src/helpers.ts +92 -0
- package/packages/arcgis-rest-sharing/src/index.ts +2 -0
- package/packages/arcgis-rest-sharing/test/access.test.ts +153 -0
- package/packages/arcgis-rest-sharing/test/group-sharing.test.ts +436 -0
- package/packages/arcgis-rest-sharing/test/mocks/sharing.ts +15 -0
- package/packages/arcgis-rest-sharing/tsconfig.json +6 -0
- package/packages/arcgis-rest-users/README.md +71 -0
- package/packages/arcgis-rest-users/package-lock.json +11 -0
- package/packages/arcgis-rest-users/package.json +51 -0
- package/packages/arcgis-rest-users/src/index.ts +1 -0
- package/packages/arcgis-rest-users/src/users.ts +70 -0
- package/packages/arcgis-rest-users/test/mocks/responses.ts +170 -0
- package/packages/arcgis-rest-users/test/users.test.ts +97 -0
- package/packages/arcgis-rest-users/tsconfig.json +6 -0
- package/support/FormData.d.ts +1 -0
- package/support/changelog.js +388 -0
- package/support/commit-template.txt +19 -0
- package/support/deploy-doc-site.js +16 -0
- package/support/publish.sh +40 -0
- package/support/test-helpers.js +8 -0
- package/tsconfig.json +69 -0
- package/tslint.json +14 -0
- package/umd-base-profile.js +82 -0
- package/umd-production-profile.js +13 -0
@@ -0,0 +1,467 @@
|
|
1
|
+
/* Copyright (c) 2017-2018 Environmental Systems Research Institute, Inc.
|
2
|
+
* Apache-2.0 */
|
3
|
+
|
4
|
+
import { IGroup } from "./group";
|
5
|
+
|
6
|
+
export * from "./webmap";
|
7
|
+
export * from "./item";
|
8
|
+
export * from "./group";
|
9
|
+
|
10
|
+
/**
|
11
|
+
* an arc can be represented as a JSON curve object
|
12
|
+
*/
|
13
|
+
export interface IArc {
|
14
|
+
a: [
|
15
|
+
Position, // End point: x, y, <z>, <m>
|
16
|
+
Position2D, // Center point: center_x, center_y
|
17
|
+
number, // minor
|
18
|
+
number, // clockwise
|
19
|
+
number, // rotation
|
20
|
+
number, // axis
|
21
|
+
number // ratio
|
22
|
+
];
|
23
|
+
}
|
24
|
+
|
25
|
+
/**
|
26
|
+
* a bezier curve can be represented as a JSON curve object
|
27
|
+
*/
|
28
|
+
export interface IBezierCurve {
|
29
|
+
b: [Position, Position2D, Position2D];
|
30
|
+
}
|
31
|
+
|
32
|
+
/**
|
33
|
+
* a circular arc can be represented as a JSON curve object
|
34
|
+
*/
|
35
|
+
export interface ICircularArc {
|
36
|
+
c: [Position, Position2D];
|
37
|
+
}
|
38
|
+
|
39
|
+
/**
|
40
|
+
*
|
41
|
+
*/
|
42
|
+
export type Color = [number, number, number, number];
|
43
|
+
|
44
|
+
/**
|
45
|
+
*
|
46
|
+
*/
|
47
|
+
export type ElipticArc = IArc;
|
48
|
+
|
49
|
+
/**
|
50
|
+
* a spatial entity and its corresponding properties
|
51
|
+
*/
|
52
|
+
export interface IFeature {
|
53
|
+
geometry?: IGeometry;
|
54
|
+
attributes: { [key: string]: any };
|
55
|
+
symbol?: ISymbol;
|
56
|
+
}
|
57
|
+
|
58
|
+
/**
|
59
|
+
* Field type.
|
60
|
+
*/
|
61
|
+
export type esriFieldType =
|
62
|
+
| "esriFieldTypeBlob"
|
63
|
+
| "esriFieldTypeDate"
|
64
|
+
| "esriFieldTypeDouble"
|
65
|
+
| "esriFieldTypeGeometry"
|
66
|
+
| "esriFieldTypeGlobalID"
|
67
|
+
| "esriFieldTypeGUID"
|
68
|
+
| "esriFieldTypeInteger"
|
69
|
+
| "esriFieldTypeOID"
|
70
|
+
| "esriFieldTypeRaster"
|
71
|
+
| "esriFieldTypeSingle"
|
72
|
+
| "esriFieldTypeSmallInteger"
|
73
|
+
| "esriFieldTypeString"
|
74
|
+
| "esriFieldTypeXML";
|
75
|
+
|
76
|
+
/**
|
77
|
+
* Contains information about an attribute field.
|
78
|
+
*/
|
79
|
+
export interface IField {
|
80
|
+
/** A string defining the field name. */
|
81
|
+
name: string;
|
82
|
+
/** A string defining the field type. */
|
83
|
+
type: esriFieldType;
|
84
|
+
/** A string defining the field alias. */
|
85
|
+
alias?: string;
|
86
|
+
/** The domain objects if applicable. */
|
87
|
+
domain?: any;
|
88
|
+
/** A Boolean defining whether this field is editable. */
|
89
|
+
editable?: boolean;
|
90
|
+
/** A Boolean defining whether or not the field is an exact match. */
|
91
|
+
exactMatch?: boolean;
|
92
|
+
/** A number defining how many characters are allowed in a string. field. */
|
93
|
+
length?: number;
|
94
|
+
/** A Boolean defining whether this field can have a null value. */
|
95
|
+
nullable?: boolean;
|
96
|
+
}
|
97
|
+
|
98
|
+
/**
|
99
|
+
* a building block for discrete geometries
|
100
|
+
*/
|
101
|
+
export interface IGeometry {
|
102
|
+
spatialReference?: ISpatialReference;
|
103
|
+
}
|
104
|
+
|
105
|
+
/**
|
106
|
+
* An envelope is a rectangle defined by a range of values for each coordinate and attribute.
|
107
|
+
*/
|
108
|
+
export interface IEnvelope extends IGeometry {
|
109
|
+
xmin: number;
|
110
|
+
xmax: number;
|
111
|
+
ymin: number;
|
112
|
+
ymax: number;
|
113
|
+
|
114
|
+
zmin?: number;
|
115
|
+
zmax?: number;
|
116
|
+
|
117
|
+
mmin?: number;
|
118
|
+
mmax?: number;
|
119
|
+
}
|
120
|
+
|
121
|
+
/**
|
122
|
+
*
|
123
|
+
*/
|
124
|
+
export type esriGeometryType = // why is this type camelCased?
|
125
|
+
| "esriGeometryPoint"
|
126
|
+
| "esriGeometryMultipoint"
|
127
|
+
| "esriGeometryPolyline"
|
128
|
+
| "esriGeometryPolygon"
|
129
|
+
| "esriGeometryEnvelope";
|
130
|
+
|
131
|
+
/**
|
132
|
+
* The spatial relationship used to compare input geometries
|
133
|
+
*/
|
134
|
+
export type SpatialRelationship =
|
135
|
+
| "esriSpatialRelIntersects"
|
136
|
+
| "esriSpatialRelContains"
|
137
|
+
| "esriSpatialRelCrosses"
|
138
|
+
| "esriSpatialRelEnvelopeIntersects"
|
139
|
+
| "esriSpatialRelIndexIntersects"
|
140
|
+
| "esriSpatialRelOverlaps"
|
141
|
+
| "esriSpatialRelTouches"
|
142
|
+
| "esriSpatialRelWithin";
|
143
|
+
|
144
|
+
/**
|
145
|
+
* Extents are used to define rectangles and bounding boxes.
|
146
|
+
*/
|
147
|
+
export interface IExtent {
|
148
|
+
xmin: number;
|
149
|
+
ymin: number;
|
150
|
+
xmax: number;
|
151
|
+
ymax: number;
|
152
|
+
spatialReference?: ISpatialReference;
|
153
|
+
}
|
154
|
+
|
155
|
+
/**
|
156
|
+
*
|
157
|
+
*/
|
158
|
+
export interface IHasZM {
|
159
|
+
hasZ?: boolean;
|
160
|
+
hasM?: boolean;
|
161
|
+
}
|
162
|
+
|
163
|
+
/**
|
164
|
+
*
|
165
|
+
*/
|
166
|
+
export interface IFeatureSet extends IHasZM {
|
167
|
+
objectIdFieldName?: string; // optional
|
168
|
+
globalIdFieldName?: string; // optional
|
169
|
+
displayFieldName?: string; // optional
|
170
|
+
geometryType?: esriGeometryType; // for feature layers only
|
171
|
+
spatialReference?: ISpatialReference; // for feature layers only.
|
172
|
+
fields?: IField[];
|
173
|
+
features: IFeature[];
|
174
|
+
}
|
175
|
+
|
176
|
+
/**
|
177
|
+
*
|
178
|
+
*/
|
179
|
+
export interface IFont {
|
180
|
+
family?: string; // "<fontFamily>";
|
181
|
+
size?: number; // <fontSize>;
|
182
|
+
style?: "italic" | "normal" | "oblique";
|
183
|
+
weight?: "bold" | "bolder" | "lighter" | "normal";
|
184
|
+
decoration?: "line-through" | "underline" | "none";
|
185
|
+
}
|
186
|
+
|
187
|
+
/**
|
188
|
+
*
|
189
|
+
*/
|
190
|
+
export type JsonCurve = ICircularArc | IArc | IOldCircularArc | IBezierCurve;
|
191
|
+
|
192
|
+
/**
|
193
|
+
*
|
194
|
+
*/
|
195
|
+
export interface IOldCircularArc {
|
196
|
+
a: [
|
197
|
+
Position, // End point: x, y, <z>, <m>
|
198
|
+
Position2D, // Center point: center_x, center_y
|
199
|
+
number, // minor
|
200
|
+
number // clockwise
|
201
|
+
];
|
202
|
+
}
|
203
|
+
|
204
|
+
/**
|
205
|
+
*
|
206
|
+
*/
|
207
|
+
export interface ISymbol {
|
208
|
+
type: SymbolType;
|
209
|
+
style?: string;
|
210
|
+
}
|
211
|
+
|
212
|
+
/**
|
213
|
+
*
|
214
|
+
*/
|
215
|
+
export interface IMarkerSymbol extends ISymbol {
|
216
|
+
angle?: number;
|
217
|
+
xoffset?: number;
|
218
|
+
yoffset?: number;
|
219
|
+
}
|
220
|
+
|
221
|
+
/**
|
222
|
+
* A multipoint contains an array of points.
|
223
|
+
*/
|
224
|
+
export interface IMultipoint extends IHasZM, IGeometry {
|
225
|
+
points: Position[];
|
226
|
+
}
|
227
|
+
|
228
|
+
/**
|
229
|
+
* Params for paging operations
|
230
|
+
*/
|
231
|
+
export interface IPagingParams {
|
232
|
+
start?: number;
|
233
|
+
num?: number;
|
234
|
+
}
|
235
|
+
|
236
|
+
/**
|
237
|
+
*
|
238
|
+
*/
|
239
|
+
export interface IPictureSourced {
|
240
|
+
url?: string; // Relative URL for static layers and full URL for dynamic layers. Access relative URL using http://<mapservice-url>/<layerId1>/images/<imageUrl11>
|
241
|
+
imageData?: string; // "<base64EncodedImageData>";
|
242
|
+
contentType?: string;
|
243
|
+
width?: number;
|
244
|
+
height?: number;
|
245
|
+
angle?: number;
|
246
|
+
xoffset?: number;
|
247
|
+
yoffset?: number;
|
248
|
+
}
|
249
|
+
|
250
|
+
/**
|
251
|
+
*
|
252
|
+
*/
|
253
|
+
export interface IPictureFillSymbol extends ISymbol, IPictureSourced {
|
254
|
+
type: "esriPFS";
|
255
|
+
outline?: ISimpleLineSymbol; // if outline has been specified
|
256
|
+
xscale?: number;
|
257
|
+
yscale?: number;
|
258
|
+
}
|
259
|
+
|
260
|
+
/**
|
261
|
+
*
|
262
|
+
*/
|
263
|
+
export interface IPictureMarkerSymbol extends IMarkerSymbol, IPictureSourced {
|
264
|
+
type: "esriPMS";
|
265
|
+
}
|
266
|
+
|
267
|
+
/**
|
268
|
+
* A simple point geometry, with spatial reference defined.
|
269
|
+
*/
|
270
|
+
export interface IPoint extends IHasZM, IGeometry {
|
271
|
+
x: number;
|
272
|
+
y: number;
|
273
|
+
}
|
274
|
+
|
275
|
+
/**
|
276
|
+
*
|
277
|
+
*/
|
278
|
+
export interface IPolyline extends IHasZM, IGeometry {
|
279
|
+
paths: Position[][];
|
280
|
+
}
|
281
|
+
|
282
|
+
/**
|
283
|
+
*
|
284
|
+
*/
|
285
|
+
export interface IPolylineWithCurves extends IHasZM, IGeometry {
|
286
|
+
curvePaths: Array<Array<Position | JsonCurve>>;
|
287
|
+
}
|
288
|
+
|
289
|
+
/**
|
290
|
+
*
|
291
|
+
*/
|
292
|
+
export interface IPolygon extends IHasZM, IGeometry {
|
293
|
+
rings: Position[][];
|
294
|
+
}
|
295
|
+
|
296
|
+
/**
|
297
|
+
*
|
298
|
+
*/
|
299
|
+
export interface IPolygonWithCurves extends IHasZM, IGeometry {
|
300
|
+
curveRings: Array<Array<Position | JsonCurve>>;
|
301
|
+
}
|
302
|
+
|
303
|
+
/**
|
304
|
+
*
|
305
|
+
*/
|
306
|
+
export type Position =
|
307
|
+
| Position2D
|
308
|
+
| [number, number, number]
|
309
|
+
| [number, number, number, number];
|
310
|
+
|
311
|
+
/**
|
312
|
+
*
|
313
|
+
*/
|
314
|
+
export type Position2D = [number, number];
|
315
|
+
|
316
|
+
/**
|
317
|
+
*
|
318
|
+
*/
|
319
|
+
export type SimpleMarkerSymbolStyle =
|
320
|
+
| "esriSMSCircle"
|
321
|
+
| "esriSMSCross"
|
322
|
+
| "esriSMSDiamond"
|
323
|
+
| "esriSMSSquare"
|
324
|
+
| "esriSMSX"
|
325
|
+
| "esriSMSTriangle";
|
326
|
+
|
327
|
+
/**
|
328
|
+
*
|
329
|
+
*/
|
330
|
+
export type SimpleLineSymbolStyle =
|
331
|
+
| "esriSLSDash"
|
332
|
+
| "esriSLSDashDot"
|
333
|
+
| "esriSLSDashDotDot"
|
334
|
+
| "esriSLSDot"
|
335
|
+
| "esriSLSNull"
|
336
|
+
| "esriSLSSolid";
|
337
|
+
|
338
|
+
/**
|
339
|
+
*
|
340
|
+
*/
|
341
|
+
export type SimpleFillSymbolStyle =
|
342
|
+
| "esriSFSBackwardDiagonal"
|
343
|
+
| "esriSFSCross"
|
344
|
+
| "esriSFSDiagonalCross"
|
345
|
+
| "esriSFSForwardDiagonal"
|
346
|
+
| "esriSFSHorizontal"
|
347
|
+
| "esriSFSNull"
|
348
|
+
| "esriSFSSolid"
|
349
|
+
| "esriSFSVertical";
|
350
|
+
|
351
|
+
/**
|
352
|
+
*
|
353
|
+
*/
|
354
|
+
export type SymbolType =
|
355
|
+
| "esriSLS"
|
356
|
+
| "esriSMS"
|
357
|
+
| "esriSFS"
|
358
|
+
| "esriPMS"
|
359
|
+
| "esriPFS"
|
360
|
+
| "esriTS";
|
361
|
+
|
362
|
+
/**
|
363
|
+
*
|
364
|
+
*/
|
365
|
+
export interface ISimpleFillSymbol extends ISymbol {
|
366
|
+
type: "esriSFS";
|
367
|
+
style?: SimpleFillSymbolStyle;
|
368
|
+
color?: Color;
|
369
|
+
outline?: ISimpleLineSymbol; // if outline has been specified
|
370
|
+
}
|
371
|
+
|
372
|
+
/**
|
373
|
+
*
|
374
|
+
*/
|
375
|
+
export interface ISimpleLineSymbol extends ISymbol {
|
376
|
+
type: "esriSLS";
|
377
|
+
style?: SimpleLineSymbolStyle;
|
378
|
+
color?: Color;
|
379
|
+
width?: number;
|
380
|
+
}
|
381
|
+
|
382
|
+
/**
|
383
|
+
*
|
384
|
+
*/
|
385
|
+
export interface ISimpleMarkerSymbol extends IMarkerSymbol {
|
386
|
+
type: "esriSMS";
|
387
|
+
style?: SimpleMarkerSymbolStyle;
|
388
|
+
color?: Color;
|
389
|
+
size?: number;
|
390
|
+
outline?: ISimpleLineSymbol;
|
391
|
+
}
|
392
|
+
|
393
|
+
/**
|
394
|
+
* Spatial reference systems define mathematical transformations and coordinate systems for displaying spatial information in 2D and 3D.
|
395
|
+
*/
|
396
|
+
export interface ISpatialReference {
|
397
|
+
wkid?: number;
|
398
|
+
latestWkid?: number;
|
399
|
+
vcsWkid?: number;
|
400
|
+
latestVcsWkid?: number;
|
401
|
+
wkt?: string;
|
402
|
+
latestWkt?: string;
|
403
|
+
}
|
404
|
+
|
405
|
+
/**
|
406
|
+
*
|
407
|
+
*/
|
408
|
+
export interface ITextSymbol extends IMarkerSymbol {
|
409
|
+
type: "esriTS";
|
410
|
+
color?: Color;
|
411
|
+
backgroundColor?: Color;
|
412
|
+
borderLineSize?: number; // <size>;
|
413
|
+
borderLineColor?: Color;
|
414
|
+
haloSize?: number; // <size>;
|
415
|
+
haloColor?: Color;
|
416
|
+
verticalAlignment?: "baseline" | "top" | "middle" | "bottom";
|
417
|
+
horizontalAlignment?: "left" | "right" | "center" | "justify";
|
418
|
+
rightToLeft?: boolean;
|
419
|
+
kerning?: boolean;
|
420
|
+
font?: IFont;
|
421
|
+
text?: string; // only applicable when specified as a client-side graphic.
|
422
|
+
}
|
423
|
+
|
424
|
+
/**
|
425
|
+
* An ArcGIS Online or Enterprise user
|
426
|
+
*/
|
427
|
+
export interface IUser {
|
428
|
+
username?: string;
|
429
|
+
fullName?: string;
|
430
|
+
availableCredits?: number;
|
431
|
+
assignedCredits?: number;
|
432
|
+
firstName?: string;
|
433
|
+
lastName?: string;
|
434
|
+
preferredView?: any;
|
435
|
+
description?: string;
|
436
|
+
email?: string;
|
437
|
+
idpUsername?: string;
|
438
|
+
favGroupId?: string;
|
439
|
+
lastLogin?: number;
|
440
|
+
mfaEnabled?: boolean;
|
441
|
+
access?: string;
|
442
|
+
storageUsage?: number;
|
443
|
+
storageQuota?: number;
|
444
|
+
orgId?: string;
|
445
|
+
role?: "org_admin" | "org_publisher" | "org_user";
|
446
|
+
privileges?: string[];
|
447
|
+
roleId?: string;
|
448
|
+
level?: string;
|
449
|
+
disabled?: boolean;
|
450
|
+
units?: string;
|
451
|
+
tags?: string[];
|
452
|
+
culture?: string;
|
453
|
+
region?: string;
|
454
|
+
thumbnail?: string;
|
455
|
+
created?: number;
|
456
|
+
modified?: number;
|
457
|
+
groups?: IGroup[];
|
458
|
+
provider?: "arcgis" | "enterprise" | "facebook" | "google";
|
459
|
+
}
|
460
|
+
|
461
|
+
export type esriUnits =
|
462
|
+
| "esriSRUnit_Meter"
|
463
|
+
| "esriSRUnit_StatuteMile"
|
464
|
+
| "esriSRUnit_Foot"
|
465
|
+
| "esriSRUnit_Kilometer"
|
466
|
+
| "esriSRUnit_NauticalMile"
|
467
|
+
| "esriSRUnit_USNauticalMile";
|
@@ -0,0 +1,45 @@
|
|
1
|
+
/* Copyright (c) 2018 Environmental Systems Research Institute, Inc.
|
2
|
+
* Apache-2.0 */
|
3
|
+
|
4
|
+
import { ISpatialReference } from "./index";
|
5
|
+
|
6
|
+
/**
|
7
|
+
* A Portal [Item](https://developers.arcgis.com/rest/users-groups-and-items/common-parameters.htm) that has not been created yet.
|
8
|
+
*/
|
9
|
+
export interface IItemAdd {
|
10
|
+
title: string;
|
11
|
+
type: string;
|
12
|
+
owner?: string;
|
13
|
+
typeKeywords?: string[];
|
14
|
+
description?: string;
|
15
|
+
snippet?: string;
|
16
|
+
documentation?: string;
|
17
|
+
extent?: number[][];
|
18
|
+
categories?: string[];
|
19
|
+
spatialReference?: ISpatialReference;
|
20
|
+
culture?: string;
|
21
|
+
properties?: any;
|
22
|
+
url?: string;
|
23
|
+
tags?: string[];
|
24
|
+
[key: string]: any;
|
25
|
+
}
|
26
|
+
|
27
|
+
/**
|
28
|
+
* A Portal [Item](https://developers.arcgis.com/rest/users-groups-and-items/common-parameters.htm) to be updated.
|
29
|
+
*/
|
30
|
+
export interface IItemUpdate {
|
31
|
+
id: string;
|
32
|
+
[key: string]: any;
|
33
|
+
}
|
34
|
+
|
35
|
+
/**
|
36
|
+
* Existing Portal [Item](https://developers.arcgis.com/rest/users-groups-and-items/item.htm).
|
37
|
+
*/
|
38
|
+
export interface IItem extends IItemAdd {
|
39
|
+
id: string;
|
40
|
+
owner: string;
|
41
|
+
tags: string[];
|
42
|
+
created: number;
|
43
|
+
modified: number;
|
44
|
+
protected: boolean;
|
45
|
+
}
|