Zh-hans:Key:gtfs:trip_id:sample

From OpenStreetMap Wiki
Jump to navigation Jump to search
gtfs:trip_id:sample
说明
某 GTFS 数据集中与该线路变体相对应的那一行 trip_id 列的确切取值。
组: public transport
用于这些元素
不可用于节点不可用于路径不可用于区域可用于关系
常用组合

One of:

另见
状态:导入Page for proposal
本页面由 AI 从英文页面翻译而来,内容需要人工复核。

键 gtfs:trip_id:sample=* 用于 公共交通 标注,为一个 PTv2 的 type=route 关系添加一个来自 GTFS trips.txt 文件的 trip_id 作为示例。

如果 trips.txt 或 shapes.txt 中存在 gtfs:shape_id=*,请使用它,因为那样更合适。

如果该线路变体只表示一条班次且只有一个 service_id,那么 gtfs:trip_id=* 是可用的替代键。

该键用于在 GTFS 数据集中查找对应的班次。为此需要使用数据源代码后缀来指定数据集(参见 List of GTFS feeds)。关于如何引用 GTFS 数据集的更详细说明,请参见 GTFS。

示例

查看线路 Bus 10: Ringlijn Nijmegen Centraal Station => Universiteit HAN。它是一个 relation route,因此我们可以在 trips.txt 中找到对应的班次

下面是该表的一个片段。

trips.txt
route_id service_id trip_id trip_headsign trip_short_name trip_long_name direction_id shape_id ...
87987 457 177374763 Heyendaal 79 0 1127909
87987 457 177374758 Heyendaal 69 0 1127909
87987 457 177374753 Heyendaal 59 0 1127909

我们可以用 gtfs:trip_id:sample:NL-OVApi=177374763 来引用其中之一。

更推荐使用 gtfs:shape_id:NL-OVApi=1127909,因为这个数据集在不同版本中具有不同的班次 ID。

PTNA

PTNA 在其关于 GTFS 班次的页面以及网络分析(概览)的标签摘要中表示 gtfs:trip_id:sample=*。

PTNA 会评估 gtfs:trip_id:sample=*,以便在同时存在 gtfs:feed=*、operator:guid=* 或 network:guid=*(按此顺序)时从分析结果链接到 GTFS 数据(示例)。
添加 gtfs:route_id=* 无害,但并非必需,因为它可以从 gtfs:trip_id:sample=* 推导得出