Synthèse
The properties below are returned by the outputFilters object when using Describe on a utility network.
Learn more about controlling what is returned by a trace operation
Propriétés
| Propriété | Explication | Type de données | 
| assetGroupCode (Lecture seule) | The asset group code. | Integer | 
| assetTypeCode (Lecture seule) | The asset type code. | Integer | 
| networkSourceID (Lecture seule) | The ID of the network source. | Integer | 
Exemple de code
This stand-alone Python script prints a report of some utility network properties.
# Import required modules
import arcpy
# Describe functions on a Utility Network
UN = "C:\\Projects\\MyProject\\unowner.sde\\Naperville.UNOWNER.Naperville\\Naperville.UNOWNER.Naperville" 
d = arcpy.Describe(UN)
# Domain Network properties
domnets = d.domainNetworks
# For each domain network in the utility network
for dom in domnets:
    print(f"Domain Network Name: {dom.domainNetworkName}")
    
    # For each tier in the domain network
    for tier in dom.tiers:
        print(f"Tier Name: {tier.name}")
                
        # Update Subnetwork Trace Configuration Properties     
        ust = tier.updateSubnetworkTraceConfiguration
        # Output Filter Properties
        print(" - Output Filter Properties - ")
        for ofp in ust.outputFilters:
            # Try to get these properties if the exist, else, print the empty list
            try:
                for of in ofp:
                    print(f"Network Source ID: {of.networkSourceID}")
                    print(f"Asset Group Code: {of.assetGroupCode}")
                    print(f"Asset Type Code: {of.assetTypeCode} \n")
            except:
                print("Skipped output filter properties. \n")Vous avez un commentaire à formuler concernant cette rubrique ?