routeSegment QML Type
routeSegment 유형은 경로의 세그먼트를 나타냅니다. 더 보기...
Import Statement: | import QtLocation 6.8 |
Since: | QtLocation 5.5 |
속성
- distance : real
- maneuver : RouteManeuver
- path : list<coordinate>
- travelTime : int
상세 설명
routeSegment 인스턴스는 경로 세그먼트의 물리적 레이아웃, 경로 길이, 경로 세그먼트를 통과하는 데 필요한 예상 시간, 경로 세그먼트의 끝과 연결된 선택적 routeManeuver에 대한 정보를 가지고 있습니다.
routeSegment의 인스턴스는 라우팅 그래프의 가장자리로 생각할 수 있으며, routeManeuver 인스턴스는 그래프의 꼭지점에 부착된 선택적 레이블로 볼 수 있습니다.
Route 객체를 획득하는 주요 수단은 RouteModel 을 통한 경로입니다.
예제
다음 QML 스니펫은 경로 세그먼트에 대한 정보를 인쇄하는 방법을 보여줍니다:
import QtQuick import QtPositioning import QtLocation Text { text: "Segment distance " + routeSegment.distance + " meters, " + routeSegment.path.length + " points." }
속성 문서
distance : real |
경로의 이 세그먼트가 커버하는 거리를 미터 단위로 저장하는 읽기 전용 속성입니다.
maneuver : RouteManeuver |
이 경로 세그먼트에 대한 기동을 보유하는 읽기 전용 속성입니다.
이 경로 세그먼트의 엔드포인트에 정보가 첨부되지 않은 경우 유효하지 않은 기동을 반환합니다.
path : list<coordinate> |
이 세그먼트의 지리적 좌표를 보유하는 읽기 전용 속성입니다. 좌표는 경로의 이 세그먼트를 따라 이동하는 사람이 통과하는 순서대로 나열됩니다.
개별 세그먼트에 액세스하려면 표준 목록 접근자를 사용할 수 있습니다: 'path.length'는 개체의 수를 나타내고 'path[0으로 시작하는 인덱스]'는 실제 개체를 나타냅니다.
QtPositioning::coordinate 를참조하세요 .
travelTime : int |
이 세그먼트를 통과하는 데 걸리는 예상 시간(초)을 저장하는 읽기 전용 속성입니다.
© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.