@arcgis/core 6.0.0-next.23 → 6.0.0-next.25

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 (237) hide show
  1. package/Graphic.d.ts +47 -14
  2. package/PopupTemplate.js +1 -1
  3. package/WebScene.d.ts +3 -0
  4. package/arcade/functions/string.js +1 -1
  5. package/assets/esri/core/workers/RemoteClient.js +1 -1
  6. package/assets/esri/core/workers/chunks/{db9921fbda556f142c4a.js → 04d55ed51e8b2683c4b4.js} +1 -1
  7. package/assets/esri/core/workers/chunks/{435b90168f79c5587a07.js → 04ecf15524ff3838c01c.js} +1 -1
  8. package/assets/esri/core/workers/chunks/{e2f42aec02bff33b25dd.js → 09300e74e5b014ce6269.js} +1 -1
  9. package/assets/esri/core/workers/chunks/{fcb86d24fc7e0666b564.js → 096b2bf1c0d69d27f20c.js} +1 -1
  10. package/assets/esri/core/workers/chunks/{612345f17f5eeb99ea8f.js → 0d9c4c6c571ce26d356b.js} +1 -1
  11. package/assets/esri/core/workers/chunks/{0f725cf79ce00e790a7d.js → 1168bc5c9f0a7e1f63a2.js} +1 -1
  12. package/assets/esri/core/workers/chunks/{12a7997a40c77f5c9160.js → 151e5799ede763a03ee2.js} +1 -1
  13. package/assets/esri/core/workers/chunks/{a64446a3328a7323e307.js → 173f89c55a5c79ff065b.js} +1 -1
  14. package/assets/esri/core/workers/chunks/{8715661a838361d4211a.js → 1b24a40c0fa197014873.js} +1 -1
  15. package/assets/esri/core/workers/chunks/{ca0d4ce453d8eb35467d.js → 277263466837e1673f56.js} +1 -1
  16. package/assets/esri/core/workers/chunks/{b1d989b72203113a06fe.js → 2a36fe3f3f257a779a1b.js} +1 -1
  17. package/assets/esri/core/workers/chunks/{ffcb99693182a621a93e.js → 2cf8172be83b10b11bdc.js} +1 -1
  18. package/assets/esri/core/workers/chunks/{fcaf9450642fcef83286.js → 3048e74e6246324ce6fc.js} +1 -1
  19. package/assets/esri/core/workers/chunks/{95b82cbbe355266c65d7.js → 30af63b3b750142faadb.js} +1 -1
  20. package/assets/esri/core/workers/chunks/30dcf2cfb31cb70de7df.js +1 -0
  21. package/assets/esri/core/workers/chunks/{9f0a973a0dd28953ce25.js → 371e2ddb88cc6b9a41e8.js} +1 -1
  22. package/assets/esri/core/workers/chunks/3fd5c3cd8457ddc68798.js +1 -0
  23. package/assets/esri/core/workers/chunks/{62fec1816907f070f079.js → 3fe04f13215474accb09.js} +1 -1
  24. package/assets/esri/core/workers/chunks/{f47fe4433b05fca5c3ad.js → 42f6194633c2d879c8da.js} +1 -1
  25. package/assets/esri/core/workers/chunks/{cddc3e285f763ccf33c2.js → 4869e097261ded90b8bb.js} +1 -1
  26. package/assets/esri/core/workers/chunks/{d8a7eba588d374b2f961.js → 4bb9a5f4ca944d3fc206.js} +1 -1
  27. package/assets/esri/core/workers/chunks/{8052da8be251c3ff2176.js → 4d93bed14945e3d34d5c.js} +1 -1
  28. package/assets/esri/core/workers/chunks/{65cb5e39c467a35621ca.js → 56e903ccef66cbe18f92.js} +1 -1
  29. package/assets/esri/core/workers/chunks/{44d5508042cacdfcac47.js → 58da3f8cf0f7f6a7e4fa.js} +1 -1
  30. package/assets/esri/core/workers/chunks/{bc915fb182d463d804e6.js → 5c04835b0b52461183cd.js} +1 -1
  31. package/assets/esri/core/workers/chunks/{7e8611cb709f105946f5.js → 6061232c96e11eb7b25d.js} +1 -1
  32. package/assets/esri/core/workers/chunks/{1e514e1c9aabefa04201.js → 64382363d6dc04ff1eac.js} +1 -1
  33. package/assets/esri/core/workers/chunks/{c82daefb193aae895bc0.js → 67e06d606c7fd2064adf.js} +1 -1
  34. package/assets/esri/core/workers/chunks/{434a8ba841a59e0deab9.js → 67e533748435253aaba6.js} +1 -1
  35. package/assets/esri/core/workers/chunks/{feb41abc03d677df6f73.js → 6b9961261241fdce0e94.js} +1 -1
  36. package/assets/esri/core/workers/chunks/{949bee7b304e625a7891.js → 6db0f8fe1402643fbe1a.js} +1 -1
  37. package/assets/esri/core/workers/chunks/{96c4ea9cfa3930f1c3fb.js → 6f1d6453184e0a1530ad.js} +1 -1
  38. package/assets/esri/core/workers/chunks/6f897b4e7ddd1dd1672b.js +1 -0
  39. package/assets/esri/core/workers/chunks/{0049b66ccbfb168caa76.js → 7124ad8dc5ad40dc66f3.js} +1 -1
  40. package/assets/esri/core/workers/chunks/{6e107ce73633de8ac257.js → 72f4dad65e16a7d7c58f.js} +1 -1
  41. package/assets/esri/core/workers/chunks/{0df9a906f7823c23d426.js → 7566321c6a2913f2852b.js} +1 -1
  42. package/assets/esri/core/workers/chunks/{c4ddac23bd649d24f3f2.js → 75d551a449bba61ce238.js} +1 -1
  43. package/assets/esri/core/workers/chunks/{af349c7bc8ef41a0e1bd.js → 7748c2886d0122b40eeb.js} +1 -1
  44. package/assets/esri/core/workers/chunks/{b4c3ec081874b49ff89b.js → 78fbe330f16bdbdb886e.js} +1 -1
  45. package/assets/esri/core/workers/chunks/79483c05867ba1386f5a.js +1 -0
  46. package/assets/esri/core/workers/chunks/7b482afb9fd1229f5707.js +1 -0
  47. package/assets/esri/core/workers/chunks/7c631e2947243e2c9bde.js +1 -0
  48. package/assets/esri/core/workers/chunks/7db9e615e60d824eac1b.js +1 -0
  49. package/assets/esri/core/workers/chunks/{8a7b02037151767542f1.js → 7dbf4c7480bf9c72820d.js} +1 -1
  50. package/assets/esri/core/workers/chunks/{64b360625c68cb863a08.js → 84940d8e14caf5a27e04.js} +1 -1
  51. package/assets/esri/core/workers/chunks/{1b1d3f6916d2cb751435.js → 87177e0f82e8a6ae3189.js} +1 -1
  52. package/assets/esri/core/workers/chunks/{5cb26bbaa08114aec5ce.js → 89cc1a5539b82fb46216.js} +1 -1
  53. package/assets/esri/core/workers/chunks/{9d40786c5ceface786ba.js → 8a485130781b49dbf608.js} +1 -1
  54. package/assets/esri/core/workers/chunks/8b5dcc4282772bf6b675.js +1 -0
  55. package/assets/esri/core/workers/chunks/{8c12269d26f5a4c753cb.js → 8ebaf5754e86a45b0497.js} +1 -1
  56. package/assets/esri/core/workers/chunks/{542e5640ea1b80ef801a.js → 9189dfe19a2a2ccd5173.js} +1 -1
  57. package/assets/esri/core/workers/chunks/{67a35155b8b4d36f171e.js → 926e0a3827eaf16ca8b4.js} +1 -1
  58. package/assets/esri/core/workers/chunks/{dc1761cba0454fda3cf9.js → 9630234267098115de4d.js} +1 -1
  59. package/assets/esri/core/workers/chunks/{10d80e793019dfb45ca2.js → 987424121cf30b0f3c50.js} +1 -1
  60. package/assets/esri/core/workers/chunks/9afc87474cef1fc4fe4a.js +1 -0
  61. package/assets/esri/core/workers/chunks/{facd1ff23203fed67686.js → 9b048f80c2d28d527373.js} +1 -1
  62. package/assets/esri/core/workers/chunks/9dd48e75b4e8d9811d81.js +1 -0
  63. package/assets/esri/core/workers/chunks/{ee08ae5b73439a1ff666.js → a163c6005aba3378edaa.js} +1 -1
  64. package/assets/esri/core/workers/chunks/{517106048980a3cbe072.js → a4b822ee45810c4c292a.js} +1 -1
  65. package/assets/esri/core/workers/chunks/{092e311cb7aea92a6a26.js → acb265a22be5e12f38e5.js} +1 -1
  66. package/assets/esri/core/workers/chunks/{1a411ddae7a47015370c.js → acf4737ba509cbd73cce.js} +1 -1
  67. package/assets/esri/core/workers/chunks/{d247dd53788d512b9c9f.js → af3c6794334626b94f00.js} +1 -1
  68. package/assets/esri/core/workers/chunks/{532e9cda8ac3601d8892.js → b12acf1f694f82e00df9.js} +1 -1
  69. package/assets/esri/core/workers/chunks/{636cd05abfbdff19029e.js → ba3d5abff65aefcb8dee.js} +1 -1
  70. package/assets/esri/core/workers/chunks/{504184828048310a052c.js → bdc221d94300c225665a.js} +1 -1
  71. package/assets/esri/core/workers/chunks/c0eb27263f608dc3684b.js +1 -0
  72. package/assets/esri/core/workers/chunks/c2318c014e97ba519be8.js +1 -0
  73. package/assets/esri/core/workers/chunks/{7f8e327acad48c9e75ea.js → c62237c344e341619341.js} +1 -1
  74. package/assets/esri/core/workers/chunks/{a2ad3e620c98e2b2eb06.js → cd355baab983033c3ef0.js} +1 -1
  75. package/assets/esri/core/workers/chunks/{7be6d621a0d1e33dfff4.js → d070fcb73ce274ab80e4.js} +1 -1
  76. package/assets/esri/core/workers/chunks/{6d41444b46677aa762a7.js → db41490bd39d863305bf.js} +1 -1
  77. package/assets/esri/core/workers/chunks/{fc5a36e54929e03efa86.js → dba5f44c4e4a3f075df2.js} +1 -1
  78. package/assets/esri/core/workers/chunks/{3e30b96a8c75bd5b9ae2.js → ddc95cdac6c06fc4794c.js} +1 -1
  79. package/assets/esri/core/workers/chunks/{a5c8f9f5be4ef5063b42.js → df26ec0b508cf4716e0a.js} +1 -1
  80. package/assets/esri/core/workers/chunks/{f426da2210888cc264b4.js → e83f9abee611c5b80009.js} +1 -1
  81. package/assets/esri/core/workers/chunks/{8487727f1197cf7dbf50.js → ef12fa3574d4cbf8b084.js} +1 -1
  82. package/assets/esri/core/workers/chunks/f10c883eb26330e3421c.js +1 -0
  83. package/assets/esri/core/workers/chunks/f46e92c67986c8c09bdd.js +1 -0
  84. package/assets/esri/core/workers/chunks/{709e019885822b1f6f3e.js → f905f1a1aa4c123cbe83.js} +1 -1
  85. package/assets/esri/core/workers/chunks/{5b91e2dffdc84c006539.js → fb37f0848196c28b7fd7.js} +1 -1
  86. package/assets/esri/libs/librust-parquet/pkg/parquet_bg.wasm +0 -0
  87. package/assets/esri/libs/librust-text/pkg/text_bg.wasm +0 -0
  88. package/chunks/MultiPathImpl.js +1 -1
  89. package/chunks/OperatorProximityGeodesic.js +1 -1
  90. package/chunks/basis_encoder.js +1 -1
  91. package/chunks/basis_transcoder.js +1 -1
  92. package/chunks/draco_mesh_decoder.js +1 -1
  93. package/chunks/dxt_encoder.js +1 -1
  94. package/chunks/i3s.js +1 -1
  95. package/chunks/lclayout.js +1 -1
  96. package/chunks/lerc-wasm.js +1 -1
  97. package/chunks/libtess-f32.js +1 -1
  98. package/chunks/libtess-f64.js +1 -1
  99. package/chunks/lyr3DMain.js +1 -1
  100. package/chunks/lyr3DWorker.js +1 -1
  101. package/chunks/parquet.js +1 -1
  102. package/chunks/qb3-wasm.js +1 -1
  103. package/chunks/rbush.js +1 -1
  104. package/chunks/text.js +1 -1
  105. package/chunks/vxlLayer.js +1 -1
  106. package/config.js +1 -1
  107. package/core/workers/WorkerFallback.js +4 -2
  108. package/core/workers/workerFactory.js +1 -1
  109. package/core/workers/workers.js +4 -2
  110. package/geometry/support/labelPoint.js +1 -1
  111. package/graphic/AnnotationFeatureGraphicOrigin.d.ts +49 -9
  112. package/graphic/BuildingGraphicOrigin.d.ts +49 -0
  113. package/graphic/CSVGraphicOrigin.d.ts +42 -9
  114. package/graphic/CatalogGraphicOrigin.d.ts +42 -9
  115. package/graphic/DimensionFeatureGraphicOrigin.d.ts +42 -9
  116. package/graphic/FeatureGraphicOrigin.d.ts +42 -9
  117. package/graphic/GeoJSONGraphicOrigin.d.ts +42 -9
  118. package/graphic/GeoRSSGraphicOrigin.d.ts +42 -9
  119. package/graphic/GraphicOrigin.d.ts +52 -12
  120. package/graphic/ImageryGraphicOrigin.d.ts +42 -9
  121. package/graphic/ImageryTileGraphicOrigin.d.ts +42 -9
  122. package/graphic/KMLGraphicOrigin.d.ts +47 -10
  123. package/graphic/KnowledgeGraphGraphicOrigin.d.ts +49 -1
  124. package/graphic/LinkChartGraphicOrigin.d.ts +49 -1
  125. package/graphic/MapImageGraphicOrigin.d.ts +49 -1
  126. package/graphic/MapNotesGraphicOrigin.d.ts +48 -1
  127. package/graphic/OGCFeatureGraphicOrigin.d.ts +42 -9
  128. package/graphic/OrientedImageryGraphicOrigin.d.ts +42 -9
  129. package/graphic/ParquetGraphicOrigin.d.ts +42 -9
  130. package/graphic/PointCloudGraphicOrigin.d.ts +43 -0
  131. package/graphic/SceneGraphicOrigin.d.ts +43 -0
  132. package/graphic/SketchGraphicOrigin.d.ts +43 -0
  133. package/graphic/StreamGraphicOrigin.d.ts +43 -0
  134. package/graphic/SubtypeGroupGraphicOrigin.d.ts +49 -1
  135. package/graphic/TileGraphicOrigin.d.ts +49 -1
  136. package/graphic/VectorTileGraphicOrigin.d.ts +43 -14
  137. package/graphic/VoxelGraphicOrigin.d.ts +43 -0
  138. package/graphic/WCSGraphicOrigin.d.ts +43 -0
  139. package/graphic/WFSGraphicOrigin.d.ts +42 -9
  140. package/graphic/getGraphicOriginTitle.d.ts +21 -3
  141. package/kernel.js +1 -1
  142. package/layers/GaussianSplatLayer.d.ts +2 -1
  143. package/layers/ParquetLayer.d.ts +24 -1
  144. package/layers/ParquetLayer.js +1 -1
  145. package/layers/mixins/ReloadableLayer.js +1 -1
  146. package/layers/orientedImagery/transformations/utils.js +1 -1
  147. package/layers/save/featureLayerUtils.js +1 -1
  148. package/layers/save/imageryUtils.js +1 -1
  149. package/layers/save/mapImageLayerUtils.js +1 -1
  150. package/layers/save/mediaLayerUtils.js +1 -1
  151. package/layers/save/parquetLayerUtils.js +2 -0
  152. package/layers/save/streamLayerUtils.js +1 -1
  153. package/layers/support/LabelClass.d.ts +8 -2
  154. package/layers/support/layersMapping.js +1 -1
  155. package/layers/support/rasterJobHelper.js +1 -1
  156. package/layers/video/VideoController.js +5 -5
  157. package/package.json +2 -2
  158. package/popup/content.js +1 -1
  159. package/portal/schemas/definitions.js +1 -1
  160. package/portal/schemas/webScene.js +1 -1
  161. package/rest/query/operations/pbfDehydratedFeatureSet.js +1 -1
  162. package/rest/query/operations/pbfFlatFeatureSet.js +1 -1
  163. package/rest/query/operations/pbfJSONFeatureSet.js +1 -1
  164. package/undoredo/support/ApplySet.js +1 -1
  165. package/views/2d/engine/flow/ProcessingTimeEstimate.js +1 -1
  166. package/views/2d/engine/vectorTiles/VectorTileContainer.js +1 -1
  167. package/views/2d/engine/vectorTiles/buckets/SymbolBucket.js +1 -1
  168. package/views/2d/engine/webgl/mesh/templates/shapingUtils.js +1 -1
  169. package/views/2d/engine/webgl/shaderGraph/techniques/markers/MarkerMeshWriter.js +1 -1
  170. package/views/3d/interactive/editingTools/reshape/ReshapeOperation.js +1 -1
  171. package/views/3d/layers/IntegratedMesh3DTilesLayerView3D.js +1 -1
  172. package/views/3d/layers/SceneLayerGraphicsView3D.js +1 -1
  173. package/views/3d/layers/graphics/Deconflictor.js +1 -1
  174. package/views/3d/layers/graphics/ElevationAligners.js +1 -1
  175. package/views/3d/layers/graphics/Graphics3DCore.js +1 -1
  176. package/views/3d/layers/graphics/Graphics3DIconSymbolLayer.js +1 -1
  177. package/views/3d/layers/graphics/Graphics3DTextSymbolLayer.js +1 -1
  178. package/views/3d/layers/graphics/LabelParameters.js +1 -1
  179. package/views/3d/layers/graphics/Labeler.js +1 -1
  180. package/views/3d/layers/graphics/elevationAlignmentUtils.js +1 -1
  181. package/views/3d/layers/graphics/pointUtils.js +1 -1
  182. package/views/3d/layers/i3s/I3SIndex.js +1 -1
  183. package/views/3d/layers/i3s/I3SOverrides.js +1 -1
  184. package/views/3d/layers/support/Tiles3DBVH.js +1 -1
  185. package/views/3d/layers/support/featureTileQuery3D.js +1 -1
  186. package/views/3d/state/controllers/ZoomControllerLocal.js +1 -1
  187. package/views/3d/state/controllers/ZoomStepControllerLocal.js +1 -1
  188. package/views/3d/state/helpers/SceneIntersectionHelper.js +1 -1
  189. package/views/3d/state/utils/groundNavigationUtils.js +1 -1
  190. package/views/3d/state/utils/navigationUtils.js +1 -1
  191. package/views/3d/terrain/TerrainRenderer.js +1 -1
  192. package/views/3d/terrain/TerrainSurface.js +1 -1
  193. package/views/3d/webgl-engine/effects/magnifier/Magnifier.js +1 -1
  194. package/views/3d/webgl-engine/effects/shadowAccumulation/ShadowCastRenderer.js +1 -1
  195. package/views/3d/webgl-engine/lib/RenderingContext.js +1 -1
  196. package/views/3d/webgl-engine/lib/TextureRepository.js +1 -1
  197. package/views/3d/webgl-engine/lib/depthRangeUtils.js +1 -1
  198. package/views/3d/webgl-engine/lib/screenPolygonTriangleIntersections.js +1 -1
  199. package/views/3d/webgl-engine/materials/ColorMaterial.js +1 -1
  200. package/views/3d/webgl-engine/materials/DefaultMaterial.js +1 -1
  201. package/views/3d/webgl-engine/materials/PathMaterial.js +1 -1
  202. package/views/3d/webgl-engine/materials/RibbonLineMaterial.js +1 -1
  203. package/views/3d/webgl-engine/materials/TriangleMaterial.js +1 -1
  204. package/views/3d/webgl-engine/materials/internal/worldSizedRibbonLineIntersectionUtils.js +1 -1
  205. package/views/DOMContainer.js +1 -1
  206. package/views/draw/SegmentDrawAction.js +1 -1
  207. package/views/interactive/snapping/SnappingManagerPool.js +1 -1
  208. package/views/interactive/tooltip/content/TooltipContent.js +1 -1
  209. package/views/interactive/tooltip/fields/TooltipField.js +1 -1
  210. package/views/support/LayerViewManager.js +1 -1
  211. package/views/support/ScheduledQueueProcessor.js +1 -1
  212. package/views/support/screenshotUtils.js +1 -1
  213. package/views/ui/UI.js +1 -1
  214. package/webdoc/support/webdocSaveUtils.js +1 -1
  215. package/webscene/Slide.d.ts +1 -2
  216. package/widgets/Editor/UpdateRecordWorkflow.js +1 -1
  217. package/widgets/Feature/FeatureRelationship/FeatureRelationshipViewModel.js +1 -1
  218. package/widgets/FeatureForm/UtilityNetworkAssociationAddAssociationViewModel.js +1 -1
  219. package/widgets/FeatureTable/RelationshipColumn.js +1 -1
  220. package/widgets/OrientedImageryViewer/ImageMeasurementWorker.js +1 -1
  221. package/widgets/OrientedImageryViewer/OrientedImageryViewerViewModel.js +1 -1
  222. package/widgets/OrientedImageryViewer/imageMeasurementUtils.js +1 -1
  223. package/widgets/OrientedImageryViewer/services/ImageMeasurementService.js +1 -1
  224. package/widgets/Sketch/SketchViewModel.js +1 -1
  225. package/assets/esri/core/workers/chunks/14d5d219e7fe017f23f0.js +0 -1
  226. package/assets/esri/core/workers/chunks/42753cf4965a94bc91ca.js +0 -1
  227. package/assets/esri/core/workers/chunks/42e985a576d7aaeed0cf.js +0 -1
  228. package/assets/esri/core/workers/chunks/5046214dd32029cb733d.js +0 -1
  229. package/assets/esri/core/workers/chunks/58865772bed48141a56a.js +0 -1
  230. package/assets/esri/core/workers/chunks/72e6d594b7262430ae55.js +0 -1
  231. package/assets/esri/core/workers/chunks/7d11710e1586a3d75887.js +0 -1
  232. package/assets/esri/core/workers/chunks/8f74d92ac69714b9fd4e.js +0 -1
  233. package/assets/esri/core/workers/chunks/947674b2ca8be65b9bcc.js +0 -1
  234. package/assets/esri/core/workers/chunks/9e7c4eda135c4911b268.js +0 -1
  235. package/assets/esri/core/workers/chunks/a09d2e1e2540921e4717.js +0 -1
  236. package/assets/esri/core/workers/chunks/dfa5f1311806473e473f.js +0 -1
  237. package/assets/esri/core/workers/chunks/fc76aff0f7d95e517d8f.js +0 -1
@@ -4,21 +4,58 @@ import type KMLSublayer from "../layers/support/KMLSublayer.js";
4
4
 
5
5
  /**
6
6
  * Provides information about the [KMLLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/KMLLayer/) from which a graphic originates.
7
- * Also provides access to the [KMLSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/support/KMLSublayer/) that contains the graphic.
7
+ * The [layer](https://developers.arcgis.com/javascript/latest/references/core/graphic/KMLGraphicOrigin/#layer) property references the KMLLayer, and the
8
+ * [sublayer](https://developers.arcgis.com/javascript/latest/references/core/graphic/KMLGraphicOrigin/#sublayer) property references the [KMLSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/support/KMLSublayer/) that contains the graphic.
8
9
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
9
10
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest).
10
11
  *
12
+ * Before accessing the layer properties, use [isKMLGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isKMLGraphicOrigin/) to check
13
+ * whether the graphic's origin is a KMLGraphicOrigin.
14
+ *
15
+ * If you only need the title of the originating KMLSublayer, use [getGraphicOriginTitle](https://developers.arcgis.com/javascript/latest/references/core/graphic/getGraphicOriginTitle/).
16
+ * To get the popup template applicable to the graphic, call [Graphic.getEffectivePopupTemplate()](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#getEffectivePopupTemplate) on the graphic.
17
+ *
11
18
  * @since 5.0
12
19
  * @example
13
- * // get a point from view's click event
14
- * view.on("click", async (event) => {
15
- * // Search for all features only on included layer at the clicked location
16
- * const response = await view.hitTest(event, {include: layer});
17
- * // if graphics are returned from layer, get the layer id from graphic origin
18
- * if (response.results.length > 0) {
19
- * const originId = response.results[0].graphic?.origin?.layer?.id;
20
- * }
21
- * });
20
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
21
+ * ```js
22
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
23
+ *
24
+ * const origin = graphic.origin;
25
+ *
26
+ * // Check whether the graphic came from a MapImageLayer
27
+ * if (isMapImageGraphicOrigin(origin)) {
28
+ * console.log(origin.layer.title);
29
+ * console.log(origin.sublayer.title);
30
+ * }
31
+ * ```
32
+ * @example
33
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
34
+ * ```js
35
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
36
+ *
37
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
38
+ * // Get hit-test results from the VectorTileLayer at the clicked location
39
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
40
+ *
41
+ * for (const result of response.results) {
42
+ * // Only graphic results contain a graphic with origin information
43
+ * if (result.type !== "graphic") {
44
+ * continue;
45
+ * }
46
+ *
47
+ * const graphic = result.graphic;
48
+ * const origin = graphic.origin;
49
+ *
50
+ * // Check whether the graphic came from a VectorTileLayer
51
+ * if (isVectorTileGraphicOrigin(origin)) {
52
+ * // layerId identifies a style layer within the VectorTileLayer
53
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
54
+ * console.log(styleLayer);
55
+ * }
56
+ * }
57
+ * });
58
+ * ```
22
59
  */
23
60
  export default class KMLGraphicOrigin extends GraphicOrigin {
24
61
  constructor(layer: KMLLayer, sublayer: KMLSublayer);
@@ -4,11 +4,59 @@ import type KnowledgeGraphSublayer from "../layers/knowledgeGraph/KnowledgeGraph
4
4
 
5
5
  /**
6
6
  * Provides information about the [KnowledgeGraphLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/KnowledgeGraphLayer/) from which a graphic originates.
7
- * Also provides access to the [KnowledgeGraphSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/knowledgeGraph/KnowledgeGraphSublayer/) that contains the graphic.
7
+ * The [layer](https://developers.arcgis.com/javascript/latest/references/core/graphic/KnowledgeGraphGraphicOrigin/#layer) property references the KnowledgeGraphLayer, and the
8
+ * [sublayer](https://developers.arcgis.com/javascript/latest/references/core/graphic/KnowledgeGraphGraphicOrigin/#sublayer) property references the [KnowledgeGraphSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/knowledgeGraph/KnowledgeGraphSublayer/) that contains the graphic.
8
9
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
9
10
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest) or [queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/layers/knowledgeGraph/KnowledgeGraphSublayer/#queryFeatures).
10
11
  *
12
+ * Before accessing the layer properties, use [isKnowledgeGraphGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isKnowledgeGraphGraphicOrigin/) to check
13
+ * whether the graphic's origin is a KnowledgeGraphGraphicOrigin.
14
+ *
15
+ * If you only need the title of the originating sublayer, use [getGraphicOriginTitle](https://developers.arcgis.com/javascript/latest/references/core/graphic/getGraphicOriginTitle/).
16
+ * To get the popup template applicable to the graphic, call [Graphic.getEffectivePopupTemplate()](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#getEffectivePopupTemplate) on the graphic
17
+ * instead of accessing the sublayer's template directly.
18
+ *
11
19
  * @since 5.0
20
+ * @example
21
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
22
+ * ```js
23
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
24
+ *
25
+ * const origin = graphic.origin;
26
+ *
27
+ * // Check whether the graphic came from a MapImageLayer
28
+ * if (isMapImageGraphicOrigin(origin)) {
29
+ * console.log(origin.layer.title);
30
+ * console.log(origin.sublayer.title);
31
+ * }
32
+ * ```
33
+ * @example
34
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
35
+ * ```js
36
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
37
+ *
38
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
39
+ * // Get hit-test results from the VectorTileLayer at the clicked location
40
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
41
+ *
42
+ * for (const result of response.results) {
43
+ * // Only graphic results contain a graphic with origin information
44
+ * if (result.type !== "graphic") {
45
+ * continue;
46
+ * }
47
+ *
48
+ * const graphic = result.graphic;
49
+ * const origin = graphic.origin;
50
+ *
51
+ * // Check whether the graphic came from a VectorTileLayer
52
+ * if (isVectorTileGraphicOrigin(origin)) {
53
+ * // layerId identifies a style layer within the VectorTileLayer
54
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
55
+ * console.log(styleLayer);
56
+ * }
57
+ * }
58
+ * });
59
+ * ```
12
60
  */
13
61
  export default class KnowledgeGraphGraphicOrigin extends GraphicOrigin {
14
62
  constructor(layer: KnowledgeGraphLayer, sublayer: KnowledgeGraphSublayer);
@@ -4,11 +4,59 @@ import type KnowledgeGraphSublayer from "../layers/knowledgeGraph/KnowledgeGraph
4
4
 
5
5
  /**
6
6
  * Provides information about the [LinkChartLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/LinkChartLayer/) from which a graphic originates.
7
- * Also provides access to the [KnowledgeGraphSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/knowledgeGraph/KnowledgeGraphSublayer/) that contains the graphic.
7
+ * The [layer](https://developers.arcgis.com/javascript/latest/references/core/graphic/LinkChartGraphicOrigin/#layer) property references the LinkChartLayer, and the
8
+ * [sublayer](https://developers.arcgis.com/javascript/latest/references/core/graphic/LinkChartGraphicOrigin/#sublayer) property references the [KnowledgeGraphSublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/knowledgeGraph/KnowledgeGraphSublayer/) that contains the graphic.
8
9
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
9
10
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest) or [queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/layers/knowledgeGraph/KnowledgeGraphSublayer/#queryFeatures).
10
11
  *
12
+ * Before accessing the layer properties, use [isLinkChartGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isLinkChartGraphicOrigin/) to check
13
+ * whether the graphic's origin is a LinkChartGraphicOrigin.
14
+ *
15
+ * If you only need the title of the originating sublayer, use [getGraphicOriginTitle](https://developers.arcgis.com/javascript/latest/references/core/graphic/getGraphicOriginTitle/).
16
+ * To get the popup template applicable to the graphic, call [Graphic.getEffectivePopupTemplate()](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#getEffectivePopupTemplate) on the graphic
17
+ * instead of accessing the sublayer's template directly.
18
+ *
11
19
  * @since 5.0
20
+ * @example
21
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
22
+ * ```js
23
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
24
+ *
25
+ * const origin = graphic.origin;
26
+ *
27
+ * // Check whether the graphic came from a MapImageLayer
28
+ * if (isMapImageGraphicOrigin(origin)) {
29
+ * console.log(origin.layer.title);
30
+ * console.log(origin.sublayer.title);
31
+ * }
32
+ * ```
33
+ * @example
34
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
35
+ * ```js
36
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
37
+ *
38
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
39
+ * // Get hit-test results from the VectorTileLayer at the clicked location
40
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
41
+ *
42
+ * for (const result of response.results) {
43
+ * // Only graphic results contain a graphic with origin information
44
+ * if (result.type !== "graphic") {
45
+ * continue;
46
+ * }
47
+ *
48
+ * const graphic = result.graphic;
49
+ * const origin = graphic.origin;
50
+ *
51
+ * // Check whether the graphic came from a VectorTileLayer
52
+ * if (isVectorTileGraphicOrigin(origin)) {
53
+ * // layerId identifies a style layer within the VectorTileLayer
54
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
55
+ * console.log(styleLayer);
56
+ * }
57
+ * }
58
+ * });
59
+ * ```
12
60
  */
13
61
  export default class LinkChartGraphicOrigin extends GraphicOrigin {
14
62
  constructor(layer: LinkChartLayer, sublayer: KnowledgeGraphSublayer);
@@ -4,10 +4,58 @@ import type Sublayer from "../layers/support/Sublayer.js";
4
4
 
5
5
  /**
6
6
  * Provides information about the [MapImageLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/MapImageLayer/) from which a graphic originates.
7
- * Also provides access to the [Sublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/support/Sublayer/) that contains the graphic.
7
+ * The [layer](https://developers.arcgis.com/javascript/latest/references/core/graphic/MapImageGraphicOrigin/#layer) property references the MapImageLayer, and the
8
+ * [sublayer](https://developers.arcgis.com/javascript/latest/references/core/graphic/MapImageGraphicOrigin/#sublayer) property references the [Sublayer](https://developers.arcgis.com/javascript/latest/references/core/layers/support/Sublayer/) that contains the graphic.
8
9
  * You can access the graphic's origin through the graphic's [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) property.
9
10
  *
11
+ * Before accessing the layer properties, use [isMapImageGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isMapImageGraphicOrigin/) to check
12
+ * whether the graphic's origin is a MapImageGraphicOrigin.
13
+ *
14
+ * If you only need the title of the originating sublayer, use [getGraphicOriginTitle](https://developers.arcgis.com/javascript/latest/references/core/graphic/getGraphicOriginTitle/).
15
+ * To get the popup template applicable to the graphic, call [Graphic.getEffectivePopupTemplate()](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#getEffectivePopupTemplate) on the graphic
16
+ * instead of accessing the sublayer's template directly.
17
+ *
10
18
  * @since 5.0
19
+ * @example
20
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
21
+ * ```js
22
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
23
+ *
24
+ * const origin = graphic.origin;
25
+ *
26
+ * // Check whether the graphic came from a MapImageLayer
27
+ * if (isMapImageGraphicOrigin(origin)) {
28
+ * console.log(origin.layer.title);
29
+ * console.log(origin.sublayer.title);
30
+ * }
31
+ * ```
32
+ * @example
33
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
34
+ * ```js
35
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
36
+ *
37
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
38
+ * // Get hit-test results from the VectorTileLayer at the clicked location
39
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
40
+ *
41
+ * for (const result of response.results) {
42
+ * // Only graphic results contain a graphic with origin information
43
+ * if (result.type !== "graphic") {
44
+ * continue;
45
+ * }
46
+ *
47
+ * const graphic = result.graphic;
48
+ * const origin = graphic.origin;
49
+ *
50
+ * // Check whether the graphic came from a VectorTileLayer
51
+ * if (isVectorTileGraphicOrigin(origin)) {
52
+ * // layerId identifies a style layer within the VectorTileLayer
53
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
54
+ * console.log(styleLayer);
55
+ * }
56
+ * }
57
+ * });
58
+ * ```
11
59
  */
12
60
  export default class MapImageGraphicOrigin extends GraphicOrigin {
13
61
  constructor(layer: MapImageLayer, sublayer: Sublayer);
@@ -4,13 +4,60 @@ import type MapNotesLayer from "../layers/MapNotesLayer.js";
4
4
 
5
5
  /**
6
6
  * Provides information about the [MapNotesLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/MapNotesLayer/) from which a graphic originates.
7
- * Also provides access to the sub [GraphicsLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/GraphicsLayer/) that contains the graphic.
7
+ * The [layer](https://developers.arcgis.com/javascript/latest/references/core/graphic/MapNotesGraphicOrigin/#layer) property references the MapNotesLayer, and the
8
+ * [sublayer](https://developers.arcgis.com/javascript/latest/references/core/graphic/MapNotesGraphicOrigin/#sublayer) property references the child [GraphicsLayer](https://developers.arcgis.com/javascript/latest/references/core/layers/GraphicsLayer/) that contains the graphic.
8
9
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
9
10
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest).
10
11
  *
12
+ * Before accessing the layer properties, use [isMapNotesGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isMapNotesGraphicOrigin/) to check
13
+ * whether the graphic's origin is a MapNotesGraphicOrigin.
14
+ *
15
+ * If you only need the title of the child GraphicsLayer, use [getGraphicOriginTitle](https://developers.arcgis.com/javascript/latest/references/core/graphic/getGraphicOriginTitle/).
16
+ * To get the popup template applicable to the graphic, call [Graphic.getEffectivePopupTemplate()](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#getEffectivePopupTemplate) on the graphic.
17
+ *
11
18
  * @since 5.0
12
19
  * @see [MapView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest)
13
20
  * @see [Map component hitTest()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-map/#hitTest)
21
+ * @example
22
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
23
+ * ```js
24
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
25
+ *
26
+ * const origin = graphic.origin;
27
+ *
28
+ * // Check whether the graphic came from a MapImageLayer
29
+ * if (isMapImageGraphicOrigin(origin)) {
30
+ * console.log(origin.layer.title);
31
+ * console.log(origin.sublayer.title);
32
+ * }
33
+ * ```
34
+ * @example
35
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
36
+ * ```js
37
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
38
+ *
39
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
40
+ * // Get hit-test results from the VectorTileLayer at the clicked location
41
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
42
+ *
43
+ * for (const result of response.results) {
44
+ * // Only graphic results contain a graphic with origin information
45
+ * if (result.type !== "graphic") {
46
+ * continue;
47
+ * }
48
+ *
49
+ * const graphic = result.graphic;
50
+ * const origin = graphic.origin;
51
+ *
52
+ * // Check whether the graphic came from a VectorTileLayer
53
+ * if (isVectorTileGraphicOrigin(origin)) {
54
+ * // layerId identifies a style layer within the VectorTileLayer
55
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
56
+ * console.log(styleLayer);
57
+ * }
58
+ * }
59
+ * });
60
+ * ```
14
61
  */
15
62
  export default class MapNotesGraphicOrigin extends GraphicOrigin {
16
63
  constructor(layer: MapNotesLayer, sublayer: GraphicsLayer);
@@ -6,6 +6,9 @@ import type OGCFeatureLayer from "../layers/OGCFeatureLayer.js";
6
6
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
7
7
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest) or [queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/views/layers/OGCFeatureLayerView/#queryFeatures).
8
8
  *
9
+ * Before accessing the layer properties, use [isOGCFeatureGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isOGCFeatureGraphicOrigin/) to check
10
+ * whether the graphic's origin is an OGCFeatureGraphicOrigin.
11
+ *
9
12
  * @since 5.0
10
13
  * @see [MapView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest)
11
14
  * @see [SceneView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/SceneView/#hitTest)
@@ -13,15 +16,45 @@ import type OGCFeatureLayer from "../layers/OGCFeatureLayer.js";
13
16
  * @see [Scene component hitTest()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-scene/#hitTest)
14
17
  * @see [OGCFeatureLayerView.queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/views/layers/OGCFeatureLayerView/#queryFeatures)
15
18
  * @example
16
- * // get a point from view's click event
17
- * view.on("click", async (event) => {
18
- * // Search for all features only on included layer at the clicked location
19
- * const response = await view.hitTest(event, {include: layer});
20
- * // if graphics are returned from layer, get the layer id from graphic origin
21
- * if (response.results.length > 0) {
22
- * const originId = response.results[0].graphic?.origin?.layer?.id;
23
- * }
24
- * });
19
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
20
+ * ```js
21
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
22
+ *
23
+ * const origin = graphic.origin;
24
+ *
25
+ * // Check whether the graphic came from a MapImageLayer
26
+ * if (isMapImageGraphicOrigin(origin)) {
27
+ * console.log(origin.layer.title);
28
+ * console.log(origin.sublayer.title);
29
+ * }
30
+ * ```
31
+ * @example
32
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
33
+ * ```js
34
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
35
+ *
36
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
37
+ * // Get hit-test results from the VectorTileLayer at the clicked location
38
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
39
+ *
40
+ * for (const result of response.results) {
41
+ * // Only graphic results contain a graphic with origin information
42
+ * if (result.type !== "graphic") {
43
+ * continue;
44
+ * }
45
+ *
46
+ * const graphic = result.graphic;
47
+ * const origin = graphic.origin;
48
+ *
49
+ * // Check whether the graphic came from a VectorTileLayer
50
+ * if (isVectorTileGraphicOrigin(origin)) {
51
+ * // layerId identifies a style layer within the VectorTileLayer
52
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
53
+ * console.log(styleLayer);
54
+ * }
55
+ * }
56
+ * });
57
+ * ```
25
58
  */
26
59
  export default class OGCFeatureGraphicOrigin extends GraphicOrigin {
27
60
  constructor(layer: OGCFeatureLayer);
@@ -6,6 +6,9 @@ import type OrientedImageryLayer from "../layers/OrientedImageryLayer.js";
6
6
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
7
7
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest) or [queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/layers/OrientedImageryLayer/#queryFeatures).
8
8
  *
9
+ * Before accessing the layer properties, use [isOrientedImageryGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isOrientedImageryGraphicOrigin/) to check
10
+ * whether the graphic's origin is an OrientedImageryGraphicOrigin.
11
+ *
9
12
  * @since 5.0
10
13
  * @see [MapView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest)
11
14
  * @see [SceneView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/SceneView/#hitTest)
@@ -13,15 +16,45 @@ import type OrientedImageryLayer from "../layers/OrientedImageryLayer.js";
13
16
  * @see [Scene component hitTest()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-scene/#hitTest)
14
17
  * @see [OrientedImageryLayer.queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/layers/OrientedImageryLayer/#queryFeatures)
15
18
  * @example
16
- * // get a point from view's click event
17
- * view.on("click", async (event) => {
18
- * // Search for all features only on included layer at the clicked location
19
- * const response = await view.hitTest(event, {include: layer});
20
- * // if graphics are returned from layer, get the layer id from graphic origin
21
- * if (response.results.length > 0) {
22
- * const originId = response.results[0].graphic?.origin?.layer?.id;
23
- * }
24
- * });
19
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
20
+ * ```js
21
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
22
+ *
23
+ * const origin = graphic.origin;
24
+ *
25
+ * // Check whether the graphic came from a MapImageLayer
26
+ * if (isMapImageGraphicOrigin(origin)) {
27
+ * console.log(origin.layer.title);
28
+ * console.log(origin.sublayer.title);
29
+ * }
30
+ * ```
31
+ * @example
32
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
33
+ * ```js
34
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
35
+ *
36
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
37
+ * // Get hit-test results from the VectorTileLayer at the clicked location
38
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
39
+ *
40
+ * for (const result of response.results) {
41
+ * // Only graphic results contain a graphic with origin information
42
+ * if (result.type !== "graphic") {
43
+ * continue;
44
+ * }
45
+ *
46
+ * const graphic = result.graphic;
47
+ * const origin = graphic.origin;
48
+ *
49
+ * // Check whether the graphic came from a VectorTileLayer
50
+ * if (isVectorTileGraphicOrigin(origin)) {
51
+ * // layerId identifies a style layer within the VectorTileLayer
52
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
53
+ * console.log(styleLayer);
54
+ * }
55
+ * }
56
+ * });
57
+ * ```
25
58
  */
26
59
  export default class OrientedImageryGraphicOrigin extends GraphicOrigin {
27
60
  constructor(layer: OrientedImageryLayer);
@@ -6,19 +6,52 @@ import type ParquetLayer from "../layers/ParquetLayer.js";
6
6
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
7
7
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest).
8
8
  *
9
+ * Before accessing the layer properties, use [isParquetGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isParquetGraphicOrigin/) to check
10
+ * whether the graphic's origin is a ParquetGraphicOrigin.
11
+ *
9
12
  * @since 5.0
10
13
  * @see [MapView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/MapView/#hitTest)
11
14
  * @see [Map component hitTest()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-map/#hitTest)
12
15
  * @example
13
- * // get a point from view's click event
14
- * view.on("click", async (event) => {
15
- * // Search for all features only on included layer at the clicked location
16
- * const response = await view.hitTest(event, {include: layer});
17
- * // if graphics are returned from layer, get the layer id from graphic origin
18
- * if (response.results.length > 0) {
19
- * const originId = response.results[0].graphic?.origin?.layer?.id;
20
- * }
21
- * });
16
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
17
+ * ```js
18
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
19
+ *
20
+ * const origin = graphic.origin;
21
+ *
22
+ * // Check whether the graphic came from a MapImageLayer
23
+ * if (isMapImageGraphicOrigin(origin)) {
24
+ * console.log(origin.layer.title);
25
+ * console.log(origin.sublayer.title);
26
+ * }
27
+ * ```
28
+ * @example
29
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
30
+ * ```js
31
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
32
+ *
33
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
34
+ * // Get hit-test results from the VectorTileLayer at the clicked location
35
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
36
+ *
37
+ * for (const result of response.results) {
38
+ * // Only graphic results contain a graphic with origin information
39
+ * if (result.type !== "graphic") {
40
+ * continue;
41
+ * }
42
+ *
43
+ * const graphic = result.graphic;
44
+ * const origin = graphic.origin;
45
+ *
46
+ * // Check whether the graphic came from a VectorTileLayer
47
+ * if (isVectorTileGraphicOrigin(origin)) {
48
+ * // layerId identifies a style layer within the VectorTileLayer
49
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
50
+ * console.log(styleLayer);
51
+ * }
52
+ * }
53
+ * });
54
+ * ```
22
55
  */
23
56
  export default class ParquetGraphicOrigin extends GraphicOrigin {
24
57
  constructor(layer: ParquetLayer);
@@ -6,9 +6,52 @@ import type PointCloudLayer from "../layers/PointCloudLayer.js";
6
6
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
7
7
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/SceneView/#hitTest) or [PointCloudLayerView.queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/views/layers/PointCloudLayerView/#queryFeatures).
8
8
  *
9
+ * Before accessing the layer properties, use [isPointCloudGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isPointCloudGraphicOrigin/) to check
10
+ * whether the graphic's origin is a PointCloudGraphicOrigin.
11
+ *
9
12
  * @since 5.0
10
13
  * @see [SceneView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/SceneView/#hitTest)
11
14
  * @see [Scene component hitTest()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-scene/#hitTest)
15
+ * @example
16
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
17
+ * ```js
18
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
19
+ *
20
+ * const origin = graphic.origin;
21
+ *
22
+ * // Check whether the graphic came from a MapImageLayer
23
+ * if (isMapImageGraphicOrigin(origin)) {
24
+ * console.log(origin.layer.title);
25
+ * console.log(origin.sublayer.title);
26
+ * }
27
+ * ```
28
+ * @example
29
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
30
+ * ```js
31
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
32
+ *
33
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
34
+ * // Get hit-test results from the VectorTileLayer at the clicked location
35
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
36
+ *
37
+ * for (const result of response.results) {
38
+ * // Only graphic results contain a graphic with origin information
39
+ * if (result.type !== "graphic") {
40
+ * continue;
41
+ * }
42
+ *
43
+ * const graphic = result.graphic;
44
+ * const origin = graphic.origin;
45
+ *
46
+ * // Check whether the graphic came from a VectorTileLayer
47
+ * if (isVectorTileGraphicOrigin(origin)) {
48
+ * // layerId identifies a style layer within the VectorTileLayer
49
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
50
+ * console.log(styleLayer);
51
+ * }
52
+ * }
53
+ * });
54
+ * ```
12
55
  */
13
56
  export default class PointCloudGraphicOrigin extends GraphicOrigin {
14
57
  constructor(layer: PointCloudLayer);
@@ -6,11 +6,54 @@ import type SceneLayer from "../layers/SceneLayer.js";
6
6
  * The [origin](https://developers.arcgis.com/javascript/latest/references/core/Graphic/#origin) information may be available when a graphic is returned from methods such as
7
7
  * [hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/SceneView/#hitTest) or [queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/layers/SceneLayer/#queryFeatures).
8
8
  *
9
+ * Before accessing the layer properties, use [isSceneGraphicOrigin](https://developers.arcgis.com/javascript/latest/references/core/graphic/isSceneGraphicOrigin/) to check
10
+ * whether the graphic's origin is a SceneGraphicOrigin.
11
+ *
9
12
  * @since 5.0
10
13
  * @see [SceneView.hitTest()](https://developers.arcgis.com/javascript/latest/references/core/views/SceneView/#hitTest)
11
14
  * @see [Scene component hitTest()](https://developers.arcgis.com/javascript/latest/references/map-components/components/arcgis-scene/#hitTest)
12
15
  * @see [SceneLayer.queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/layers/SceneLayer/#queryFeatures)
13
16
  * @see [SceneLayerView.queryFeatures()](https://developers.arcgis.com/javascript/latest/references/core/views/layers/SceneLayerView/#queryFeatures)
17
+ * @example
18
+ * Access the layer and sublayer of a graphic that originated from a MapImageLayer.
19
+ * ```js
20
+ * import { isMapImageGraphicOrigin } from "@arcgis/core/graphic/isMapImageGraphicOrigin.js";
21
+ *
22
+ * const origin = graphic.origin;
23
+ *
24
+ * // Check whether the graphic came from a MapImageLayer
25
+ * if (isMapImageGraphicOrigin(origin)) {
26
+ * console.log(origin.layer.title);
27
+ * console.log(origin.sublayer.title);
28
+ * }
29
+ * ```
30
+ * @example
31
+ * Access the vector tile style layer associated with a graphic returned by hitTest().
32
+ * ```js
33
+ * import { isVectorTileGraphicOrigin } from "@arcgis/core/graphic/isVectorTileGraphicOrigin.js";
34
+ *
35
+ * viewElement.addEventListener("arcgisViewClick", async (event) => {
36
+ * // Get hit-test results from the VectorTileLayer at the clicked location
37
+ * const response = await view.hitTest(event.detail, { include: vectorTileLayer });
38
+ *
39
+ * for (const result of response.results) {
40
+ * // Only graphic results contain a graphic with origin information
41
+ * if (result.type !== "graphic") {
42
+ * continue;
43
+ * }
44
+ *
45
+ * const graphic = result.graphic;
46
+ * const origin = graphic.origin;
47
+ *
48
+ * // Check whether the graphic came from a VectorTileLayer
49
+ * if (isVectorTileGraphicOrigin(origin)) {
50
+ * // layerId identifies a style layer within the VectorTileLayer
51
+ * const styleLayer = origin.layer.getStyleLayer(origin.layerId);
52
+ * console.log(styleLayer);
53
+ * }
54
+ * }
55
+ * });
56
+ * ```
14
57
  */
15
58
  export default class SceneGraphicOrigin extends GraphicOrigin {
16
59
  constructor(layer: SceneLayer);