-
Notifications
You must be signed in to change notification settings - Fork 175
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'dui3/alpha' into DUI3-124-Receiving-Curves-Arcs-Ellipse…
…s-Nurbs-Curves
- Loading branch information
Showing
19 changed files
with
163 additions
and
71 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
DUI3-DX/Connectors/ArcGIS/Speckle.Connectors.ArcGIS3/Utils/MapMemberFeature.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
using ArcGIS.Desktop.Mapping; | ||
|
||
namespace Speckle.Connectors.ArcGIS.Utils; | ||
|
||
// bind together a layer object on the map, and auto-assigned ID if the specific feature | ||
public readonly struct MapMemberFeature | ||
{ | ||
public int? FeatureId { get; } // unique feature id (start from 0) of a feature in the layer | ||
public MapMember MapMember { get; } // layer object on the Map | ||
|
||
public MapMemberFeature(MapMember mapMember, int? featureId) | ||
{ | ||
MapMember = mapMember; | ||
FeatureId = featureId; | ||
} | ||
} |
38 changes: 38 additions & 0 deletions
38
DUI3-DX/Connectors/ArcGIS/Speckle.Connectors.ArcGIS3/Utils/ObjectID.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
namespace Speckle.Connectors.ArcGIS.Utils; | ||
|
||
// this struct is needed to be able to parse single-string value into IDs of both a layer, and it's individual feature | ||
public struct ObjectID | ||
{ | ||
private const string FEATURE_ID_SEPARATOR = "__speckleFeatureId__"; | ||
public string MappedLayerURI { get; } // unique ID of the layer on the map | ||
public int? FeatureId { get; } // unique feature id (start from 0) of a feature in the layer | ||
|
||
public ObjectID(string encodedId) | ||
{ | ||
List<string> stringParts = encodedId.Split(FEATURE_ID_SEPARATOR).ToList(); | ||
MappedLayerURI = stringParts[0]; | ||
FeatureId = null; | ||
if (stringParts.Count > 1) | ||
{ | ||
FeatureId = Convert.ToInt32(stringParts[1]); | ||
} | ||
} | ||
|
||
public ObjectID(string layerId, int? featureId) | ||
{ | ||
MappedLayerURI = layerId; | ||
FeatureId = featureId; | ||
} | ||
|
||
public readonly string ObjectIdToString() | ||
{ | ||
if (FeatureId == null) | ||
{ | ||
return $"{MappedLayerURI}"; | ||
} | ||
else | ||
{ | ||
return $"{MappedLayerURI}{FEATURE_ID_SEPARATOR}{FeatureId}"; | ||
} | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.