|
POST
|
Good question. I don't know many of the details here but the browser must have access to the filesystem at some level. For instance, modern browsers include a database called indexedDB, which ultimately sits in the local filesystem (cookies, like you mentioned, and local storage must also sit in the local filesystem). You can write to and read from indexedDB from JavaScript, but the browser mediates this; there's no direct access from JavaScript to the filesystem. It does seem like it would be possible to write your list of items to indexedDB (or local storage, or a cookie) from inside the browser and subsequently pull the list from those sources (or write it out, if it doesn't exist). On some level you are interacting with the local filesystem when you do this, but not directly. If you want to directly access files directly you have three options as far as I know: files must be dragged and dropped into the browser using the drag and drop API, or selected by a user using the file input, or retrieved from an http server using an http request. My understanding is that node's fs module is just a nice JavaScript wrapper around your operating system's syscalls to read/write files, it doesn't actually represent a native JavaScript way to read/write files.
... View more
08-10-2017
08:56 AM
|
0
|
0
|
2607
|
|
POST
|
I think this is the best solution. You should note that the node fs module doesn't exist in browser javascript. Browser javascript can't directly interact with the local filesystem.
... View more
08-10-2017
06:29 AM
|
1
|
2
|
2607
|
|
POST
|
For a polygons and polylines, you'll have to transform every point in every ring/path by adding a z value or changing the current z value to whatever you like. I don't see a Created_Date attribute, but I assume that should be fetched if outFields = ['*']. In terms of transforming a timestamp into a height, or somethign that could be used as a height, I think you could do this by scaling your total set of timestamps from 0 to X ms where X is the difference between the smallest timestamp and the largest timestamp and 0 is the smallest timestamp. Of course you could use seconds, minutes, etc instead of ms.
... View more
08-10-2017
06:26 AM
|
0
|
0
|
463
|
|
POST
|
I think this is possible but I'm not sure. I think the spatial reference of the elevation layer needs to match the spatial reference of the view, which will be the same as the spatial reference of your basemap (31463). I can't access the elevation layer you linked Here's a sample that adds your basemap in a local scene: JS Bin - Collaborative JavaScript Debugging and sets the ground to be "world-elevation." This doesn't work because the SRs don't match. You can try creating a new elevation layer using the url you provided and passing the resulting layer into the ground property on the map, ie: const elevLayer = new ElevationLayer({
url: 'http://ripsraster.lubw.bwl.de/arcgis/rest/services/Imageservices/DGM005/ImageServer'
});
const map = new Map({
...,
ground: [elevLayer]
});
... View more
08-09-2017
06:55 AM
|
1
|
2
|
2515
|
|
POST
|
Promises in node are the same as promises in the browser. If you're pulling in dojo, you can use dojo/deferred. The JS standard library also has a promise implementation, just Promise, that is mostly compatible with the dojo version. This looks helpful for information about using dojo in node: Dojo and Node.js - Dojo Toolkit Tutorial
... View more
08-07-2017
07:09 AM
|
1
|
0
|
929
|
|
POST
|
I don't see an ETA in the functionality matrix. This feature exists in the 3.X API though, so it may make its way to the 4.XX version eventually. It seems pretty important to me, although there may be other workarounds for this kind of functionality I'm unaware of.
... View more
08-04-2017
12:43 PM
|
2
|
0
|
2185
|
|
POST
|
I'm not sure what the issue is here. I would try generating an entirely new symbol every time you move the graphic to start with.
... View more
08-04-2017
06:27 AM
|
0
|
0
|
904
|
|
POST
|
This workflow tends to be tricky and the documentation isn't great. What has generally worked for me in the 4.XX version of esriRequest is creating a FormData and appending a File to it, and then passing that FormData in to the query parameter of esriRequest. To get the file to begin with, you can access the file input element and look at the .files property to get a list of user selected files, append them to the FormData, and so on. edit - it looks like you're interested in doing this without a file input. I don't think this is really possibly. You can access a file in the browser through drag and drop or a file input. There's no way to provide a path and get back a File object. This would be a security issue.
... View more
08-04-2017
06:03 AM
|
0
|
0
|
2209
|
|
POST
|
The JSON you're feeding it here is a symbol JSON, not a renderer JSON. In this situation you should probably create a symbol and a simpleRenderer and pass the symbol into the SimpleRenderer. I wouldn't do this using fromJSON, although you could. The from/to JSON methods are there so that instances of classes can be passed over a network or stored in a database. If you're creating the renderer in the browser in your code, it's not necessary to use those methods.
... View more
08-03-2017
03:51 PM
|
2
|
0
|
2248
|
|
POST
|
I haven't managed identity in 3.XX but I would think you could pass in "popupCallbackUrl" to the OAuthInfo constructor, ie: var info = new OAuthInfo({
appId: "<pass in your application id here>",
popup: true,
popupCallbackUrl: "<url to redirect to>"
});
esriId.registerOAuthInfos([info]);
... View more
08-03-2017
05:59 AM
|
1
|
1
|
1456
|
|
POST
|
Okay, looks like the issue with MapView is that that renderers on a graphics layer are not supported on a MapView. The documentation says GraphicsLayer doesn't support renderers at all (which doesn't appear to be true in 3D). You can work around this issue by setting the symbol manually on each returned feature: JS Bin - Collaborative JavaScript Debugging
... View more
08-02-2017
01:08 PM
|
1
|
0
|
2185
|
|
POST
|
I don't believe this functionality exists yet, though I'm sure it's on the way. You can query a feature serviced by extent manually, so it would be possible to set this up yourself for the time being. Here's a sample that queries by extent whenever the extent changes, with a 200 ms debounce: JS Bin - Collaborative JavaScript Debugging That sample uses a graphics layer as a proxy for the features. Every time the feature service is queried, the graphics layer is cleared and the new features are added. I also could only get that to work in a Scene View. There's some issue/bug that prevents the renderer from being cloned in a MapView.
... View more
08-02-2017
10:11 AM
|
2
|
4
|
2185
|
|
POST
|
Here's a sample to demonstrate the problem I've seen with labels and elevation layers: JS Bin - Collaborative JavaScript Debugging The labels are usually are drawn very high up, way above the ground, so you may have to zoom out after the view zooms to the layer's extent. My feeling is that the labels are drawn once, when the view and layer loads, and then not updated as the elevation updates as the camera moves around. (login: viewer1234/password1234)
... View more
08-02-2017
08:00 AM
|
0
|
1
|
5809
|
|
POST
|
Thanks for the sample. I spent a while looking at this because it wasn't clear to me how it differed from the sample I made. What I finally came up with was that removing the outFields: ['*'] from the feature layer constructor fixes this problem in your sample and adding outFields: ['*'] causes the problem to appear in my sample. I'm not sure why this is the case. It may be because the features returned by queryFeatures have their layer set to the existing feature layer and the layer is trying to optimize at some level and use the queried graphics in the feature layer. One way around this is to make a new graphic from each result in the queryFeatures call: featureLayer.queryFeatures(query, featureSet => {
let features = featureSet.features;
if (features.length > 0) {
let graphicsLyr = map.getLayer("pointCIP_GL");
features.forEach(f => {
// create new graphic from feature geometry
// we don't need a symbol, the renderer on the graphics layer
// will take care of that
let g = new Graphic(f.geometry);
graphicsLyr.add(g);
});
}
});
... View more
08-01-2017
09:08 AM
|
0
|
0
|
3914
|
|
POST
|
If you have all the geometries that you're searching for in the client then you can perform the query there, without making a network request. In my experience the bottleneck is usually the network request, so performing the search in the client should speed things up. Which version of the API are you using? And for each "census layer," are all features in the client? Or are they being fetched on demand (only available in the 3.XX API)?
... View more
08-01-2017
06:28 AM
|
0
|
0
|
968
|
| Title | Kudos | Posted |
|---|---|---|
| 1 | 05-03-2017 08:23 AM | |
| 1 | 11-02-2017 08:36 AM | |
| 1 | 11-02-2017 09:23 AM | |
| 1 | 09-20-2017 02:07 PM | |
| 1 | 10-06-2017 05:54 AM |
| Online Status |
Offline
|
| Date Last Visited |
11-11-2020
02:24 AM
|