Skip to main content

Junction Source

汇总

提供有关网络数据集中交汇点源的信息。

属性

名称 说明 数据类型

name

(只读)

与该网络源相关的要素类名称。

String

sourceID

(只读)

网络数据集内此网络源的唯一标识符。

Integer

sourceType

(只读)

网络源类型。 此属性返回以下关键字:

  • EdgeFeature

  • JunctionFeature

  • SystemJunction

  • TurnFeature

  • NetworkSource

String

elementType

(只读)

网络源的网络元素类型。 此属性返回以下关键字:

  • Edge

  • Junction

  • Turn

String

connectivityPolicies

(读取和写入)

网络数据集交汇点 连通性策略 对象。 该对象可用于确定连通性信息(例如连通性策略和连通性组),以供网络数据集的交汇点源使用。

Object

elevationFieldName

(只读)

与给定交汇点要素源有关的要素类字段名称,当确定重合折点的连通性时交汇点要素源会用作高程字段。

String

代码示例

交汇点源属性示例

显示网络数据集中交汇点源的信息。

# Name: NDSJunctionSourceProperties_ex01.py
# Description: Print the information about the junction sources defined for the
#              network dataset

import arcpy
import sys

# Set workspace
arcpy.env.workspace = "C:/Data/Paris.gdb/Transportation"

#Create a Describe object from the network dataset
desc = arcpy.Describe("ParisMultimodal_ND")

justify = 35
print("------- Junction sources")

#Get all the junction sources for the network dataset
junctions = desc.junctionSources

if not junctions:
    print(" %*s" % (justify, "(No junction sources)"))
    sys.exit(0)

for junction in junctions:
    print(" %*s: %s" % (justify, "Source Name" , junction.name))
    print(" %*s: %s" % (justify, "Source ID" , str(junction.sourceID)))
    print(" %*s: %s" % (justify, "Source Type", junction.sourceType))
    print(" %*s: %s" % (justify, "Element Type", junction.elementType))
    print(" %*s: %s" % (justify, "Elevation Field",
                        junction.elevationFieldName))
    print(" ")