Increase Line Length (Production Mapping)
Краткая информация
Increases the lengths of lines from the center until they meet a specified length.
Рисунок
Использование
A warning is raised if the input features are not in a projected coordinate system. This tool relies on linear distance units, which will create unexpected results in an unprojected coordinate system. It is strongly suggested that you run this tool on data in a projected coordinate system to ensure valid results. An error is raised and the tool will not process if the coordinate system is missing or unknown.
This tool cannot be run on data that is registered as versioned.
-
The lines are extended from both sides of the center point.
If this tool is run in an edit session in ArcMap, you can stop the edit session without saving changes to restore features that have been deleted.
Этот инструмент изменяет входные данные. Более подробно о стратегиях предотвращения неожиданных изменений данных см. в разделе Инструменты, не создающие выходных данных (Tools with no outputs).
Синтаксис
Параметр | Объяснение | Тип данных |
Input_Line_Features |
The line features to be lengthened. | Feature Layer |
Minimum_Length |
Any feature shorter than this length will be extended in both directions until it meets the minimum length value. | Linear unit |
Пример кода
This sample script increases the length of roads until they reach 400 feet.
# Name: IncreaseLineLength_Example.py
# Description:
# Author: Esri
# Date: February 2014
# Import arcpy module
import arcpy
# Check out Production Mapping license
arcpy.CheckOutExtension("Foundation")
# set environment
arcpy.env.workspace="c:/data/LocalGovernment.gdb"
# Define variables
inFeatures="ReferenceData/RoadCenterline"
inFeatureLyr="RoadLayer"
minLength="400 feet"
# make a feature layer from road centerlines
arcpy.MakeFeatureLayer_management(inFeatures,inFeatureLyr)
# Execute ExtendPolygonSides
arcpy.IncreaseLineLength_production(inFeatureLyr,minLength)