ArcGIS Pro 3.1 API Reference Guide
ArcGIS.Desktop.Mapping Namespace / SceneLayerDataSourceType Enumeration
Example Example

In This Topic
    SceneLayerDataSourceType Enumeration
    In This Topic
    An enumeration to represent the scene layer data source type.
    Syntax
    public enum SceneLayerDataSourceType : System.Enum, System.IComparable, System.IConvertible, System.IFormattable  
    Public Enum SceneLayerDataSourceType 
       Inherits System.Enum
       Implements System.IComparable, System.IConvertible, System.IFormattable 
    Members
    MemberDescription
    Service The data source is a scene service
    SLPK The data source is an slpk file
    Unknown The data source is unknown
    Example
    Get the Data Source type
    //Must be called on the MCT
    var dataSourceType = featSceneLayer?.GetDataSourceType() ?? 
                               SceneLayerDataSourceType.Unknown;
    if (dataSourceType == SceneLayerDataSourceType.SLPK)
    {
      //Uses SLPK - only cached attributes
    }
    else if (dataSourceType == SceneLayerDataSourceType.Service)
    {
      //Hosted service - can have live attributes - check HasAssociatedFeatureService
    }
    
    Get Data Source type for PointCloudSceneLayer
    //var pcsl = ...;
    //At 2.x - ISceneLayerInfo slInfo = pcsl as ISceneLayerInfo;
    //         SceneLayerDataSourceType dataSourceType = slInfo.GetDataSourceType();
    
    SceneLayerDataSourceType dataSourceType = pcsl.GetDataSourceType();
    if (dataSourceType == SceneLayerDataSourceType.Service)
    {
      //TODO...
    }
    else if (dataSourceType == SceneLayerDataSourceType.SLPK)
    {
    
    }
    Inheritance Hierarchy

    System.Object
       System.ValueType
          System.Enum
             ArcGIS.Desktop.Mapping.SceneLayerDataSourceType

    Requirements

    Target Platforms: Windows 11, Windows 10

    ArcGIS Pro version: 3.0 or higher.
    See Also