QGeoRouteSegment Class

QGeoRouteSegment 클래스는 경로의 세그먼트를 나타냅니다. 더 보기...

Header: #include <QGeoRouteSegment>
qmake: QT += location

속성

공공 기능

QGeoRouteSegment()
QGeoRouteSegment(const QGeoRouteSegment &other)
~QGeoRouteSegment()
qreal distance() const
bool isLegLastSegment() const
bool isValid() const
QGeoManeuver maneuver() const
QGeoRouteSegment nextRouteSegment() const
QList<QGeoCoordinate> path() const
void setNextRouteSegment(const QGeoRouteSegment &routeSegment)
int travelTime() const
QGeoRouteSegment &operator=(const QGeoRouteSegment &other)
bool operator!=(const QGeoRouteSegment &lhs, const QGeoRouteSegment &rhs)
bool operator==(const QGeoRouteSegment &lhs, const QGeoRouteSegment &rhs)

상세 설명

QGeoRouteSegment 인스턴스는 경로 세그먼트의 물리적 레이아웃, 경로 길이, 경로 세그먼트 통과에 필요한 예상 시간, 경로 세그먼트의 시작과 관련된 QGeoManeuver (선택 사항)에 대한 정보를 가지고 있습니다.

QGeoRouteSegment 인스턴스는 라우팅 그래프의 가장자리로 생각할 수 있으며, QGeoManeuver 인스턴스는 그래프의 꼭지점에 부착된 선택적 레이블로 간주할 수 있습니다.

속성 문서

[read-only] distance : const qreal

이 속성은 경로의 이 구간이 커버하는 거리를 미터 단위로 저장합니다.

액세스 기능:

qreal distance() const

[read-only] maneuver : const QGeoManeuver

이 속성은 이 경로 구간에 대한 기동을 보유합니다.

이 경로 세그먼트의 시작 지점에 정보가 첨부되지 않은 경우 잘못된 QGeoManeuver 을 보유합니다.

기능에 액세스합니다:

QGeoManeuver maneuver() const

[read-only] path : const QList<QGeoCoordinate>

이 속성은 경로의 이 경로 세그먼트의 기하학적 모양을 보유합니다.

좌표는 경로의 이 세그먼트를 따라 이동하는 사람이 통과하는 순서대로 나열되어야 합니다.

함수 액세스:

QList<QGeoCoordinate> path() const

[read-only] travelTime : const int

이 속성은 이 세그먼트를 통과하는 데 걸리는 예상 시간(초)을 저장합니다.

함수에 액세스합니다:

int travelTime() const

멤버 함수 문서

QGeoRouteSegment::QGeoRouteSegment()

잘못된 경로 세그먼트 객체를 생성합니다.

경로 세그먼트는 setNextRouteSegment(), setTravelTime(), setDistance(), setPath() 또는 setManeuver() 중 하나가 호출될 때까지 유효하지 않은 상태로 유지됩니다.

[noexcept] QGeoRouteSegment::QGeoRouteSegment(const QGeoRouteSegment &other)

other 의 콘텐츠로 경로 세그먼트 객체를 구성합니다.

[noexcept] QGeoRouteSegment::~QGeoRouteSegment()

이 경로 세그먼트 개체를 삭제합니다.

bool QGeoRouteSegment::isLegLastSegment() const

이 경로 세그먼트가 경로 구간 중 마지막 세그먼트인지 여부를 반환합니다.

bool QGeoRouteSegment::isValid() const

이 경로 세그먼트가 유효한지 여부를 반환합니다.

경로의 마지막 경로 세그먼트에서 nextRouteSegment()를 호출하면 반환되는 값은 유효하지 않은 경로 세그먼트가 됩니다.

QGeoRouteSegment QGeoRouteSegment::nextRouteSegment() const

경로의 다음 경로 세그먼트를 반환합니다.

경로의 마지막 경로 세그먼트인 경우 유효하지 않은 경로 세그먼트를 반환합니다.

setNextRouteSegment()도 참조하세요 .

void QGeoRouteSegment::setNextRouteSegment(const QGeoRouteSegment &routeSegment)

경로의 다음 경로 구간을 routeSegment 으로 설정합니다.

nextRouteSegment()도 참조하세요 .

[noexcept] QGeoRouteSegment &QGeoRouteSegment::operator=(const QGeoRouteSegment &other)

이 경로 세그먼트 객체에 other 을 할당하고 이 경로 세그먼트 객체에 대한 참조를 반환합니다.

관련 비회원

[noexcept] bool operator!=(const QGeoRouteSegment &lhs, const QGeoRouteSegment &rhs)

경로 세그먼트 lhsrhs 가 같지 않은지 여부를 반환합니다.

nextRouteSegment()의 값은 비교에서 고려되지 않습니다.

[noexcept] bool operator==(const QGeoRouteSegment &lhs, const QGeoRouteSegment &rhs)

경로 세그먼트 lhsrhs 가 동일한지 여부를 반환합니다.

nextRouteSegment()의 값은 비교에서 고려되지 않습니다.

© 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.