CartoType Android API 7.8.2, 2022-03-25
for Java development on Android
Static Public Attributes | List of all members
com.cartotype.RoadType Class Reference

Static Public Attributes

static final int ROUTING_MASK = 0x3E
 
static final int ROAD_TYPE_MASK = 0xFC0
 
static final int MAJOR_ROAD_TYPE_MASK = 0xF00
 
static final int LEVEL_MASK = 0xF000
 
static final int TUNNEL_FLAG = 1
 
static final int BRIDGE_FLAG = 0x10000
 
static final int LEVEL_SHIFT = 12
 
static final int RAMP_FLAG = 64
 
static final int LINK_FLAG = 64
 
static final int LOWER_GRADE_FLAG = 128
 
static final int TOLL_FLAG = 2
 
static final int ROUNDABOUT_FLAG = 4
 
static final int RESTRICTION_FLAG = 8
 
static final int DIRECTION_MASK = 16 | 32
 
static final int DRIVE_ON_RIGHT_FLAG = 0
 
static final int DRIVE_ON_LFT_FLAG = 48
 
static final int ONE_WAY_FORWARD_FLAG = 16
 
static final int ONE_WAY_BACKWARD_FLAG = 32
 
static final int FIRST_OVER_LEVEL = 0x1000
 
static final int FIRST_UNDER_LEVEL = 0xF000
 
static final int SECOND_UNDER_LEVEL = 0xE000
 
static final int ROAD_ACCESS_MASK = 0xFFFE0000
 
static final int BICYCLE_ROAD_ACCESS_FLAG = 0x20000
 
static final int MOTOR_CYCLE_ROAD_ACCESS_FLAG = 0x40000
 
static final int MOTOR_CAR_ROAD_ACCESS_FLAG = 0x80000
 
static final int HIGH_OCCUPANCY_ROAD_ACCESS_FLAG = 0x100000
 
static final int GOODS_ROAD_ACCESS_FLAG = 0x200000
 
static final int HEAVY_GOODS_ROAD_ACCESS_FLAG = 0x400000
 
static final int BUS_ROAD_ACCESS_FLAG = 0x800000
 
static final int TAXI_ROAD_ACCESS_FLAG = 0x1000000
 
static final int PEDESTRIAN_ROAD_ACCESS_FLAG = 0x2000000
 
static final int AGRICULTURAL_ROAD_ACCESS_FLAG = 0x4000000
 
static final int FORESTRY_ROAD_ACCESS_FLAG = 0x8000000
 
static final int EMERGENCY_ROAD_ACCESS_FLAG = 0x10000000
 
static final int HAZARDOUS_ROAD_ACCESS_FLAG = 0x20000000
 
static final int WHEEL_CHAIR_ROAD_ACCESS_FLAG = 0x40000000
 
static final int DISABLED_ROAD_ACCESS_FLAG = 0x80000000
 
static final int MOTOR_VEHICLE_ROAD_ACCESS_MASK = 0xFFFE0000 & ~(BICYCLE_ROAD_ACCESS_FLAG | PEDESTRIAN_ROAD_ACCESS_FLAG | WHEEL_CHAIR_ROAD_ACCESS_FLAG)
 
static final int PUBLIC_SERVICE_VEHICLE_ROAD_ACCESS_MASK = BUS_ROAD_ACCESS_FLAG | TAXI_ROAD_ACCESS_FLAG
 
static final int UNKNOWN_MAJOR = 0
 
static final int PRIMARY_LIMITED_ACCESS = 0x100
 
static final int MOTORWAY = PRIMARY_LIMITED_ACCESS
 
static final int MOTORWAY_LINK = PRIMARY_LIMITED_ACCESS | LINK_FLAG
 
static final int PRIMARY_UNLIMITED_ACCESS = 0x200
 
static final int TRUNK = PRIMARY_UNLIMITED_ACCESS
 
static final int TRUNK_LINK = TRUNK | LINK_FLAG
 
static final int PRIMARY = PRIMARY_UNLIMITED_ACCESS | LOWER_GRADE_FLAG
 
static final int PRIMARY_LINK = PRIMARY | LINK_FLAG
 
static final int SECONDARY = 0x300
 
static final int SECONDARY_LINK = SECONDARY | LINK_FLAG
 
static final int TERTIARY = SECONDARY | LOWER_GRADE_FLAG
 
static final int TERTIARY_LINK = TERTIARY | LINK_FLAG
 
static final int MINOR = 0x400
 
static final int UNCLASSIFIED = MINOR
 
static final int RESIDENTIAL = MINOR | LOWER_GRADE_FLAG
 
static final int BYWAY = 0x500
 
static final int TRACK = BYWAY
 
static final int ACCESS_RAMP = 0x600
 
static final int SERVICE_ROAD = 0x700
 
static final int VEHICULAR_FERRY = 0x800
 
static final int PASSENGER_FERRY = 0x900
 
static final int PATH = 0xA00
 
static final int PEDESTRIAN = PATH
 
static final int STAIRWAY = 0xB00
 
static final int CYCLE_PATH = 0xC00
 
static final int FOOTPATH = 0xD00
 
static final int OTHER_0 = 0xE00
 
static final int OTHER_1 = 0xE00 | LOWER_GRADE_FLAG
 
static final int OTHER_2 = 0xE00 | LINK_FLAG
 
static final int OTHER_3 = 0xE00 | LOWER_GRADE_FLAG | LINK_FLAG
 
static final int OTHER_4 = 0xF00
 
static final int OTHER_5 = 0xF00 | LOWER_GRADE_FLAG
 
static final int OTHER_6 = 0xF00 | LINK_FLAG
 
static final int OTHER_7 = 0xF00 | LOWER_GRADE_FLAG | LINK_FLAG
 

Detailed Description

Road types and the masks, bit flags and shifts used to define fields within them.

Member Data Documentation

◆ ACCESS_RAMP

final int com.cartotype.RoadType.ACCESS_RAMP = 0x600
static

Access ramp to limited access road.

◆ AGRICULTURAL_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.AGRICULTURAL_ROAD_ACCESS_FLAG = 0x4000000
static

Access is forbidden to agricultural vehicles.

◆ BICYCLE_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.BICYCLE_ROAD_ACCESS_FLAG = 0x20000
static

Access is forbidden to bicycles.

◆ BRIDGE_FLAG

final int com.cartotype.RoadType.BRIDGE_FLAG = 0x10000
static

A bit flag to identify bridges.

◆ BUS_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.BUS_ROAD_ACCESS_FLAG = 0x800000
static

Access is forbidden to buses.

◆ BYWAY

final int com.cartotype.RoadType.BYWAY = 0x500
static

Byway: road or track open to motor vehicles.

◆ CYCLE_PATH

final int com.cartotype.RoadType.CYCLE_PATH = 0xC00
static

Cycle path.

◆ DIRECTION_MASK

final int com.cartotype.RoadType.DIRECTION_MASK = 16 | 32
static

A mask for the road direction and driving side.

◆ DISABLED_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.DISABLED_ROAD_ACCESS_FLAG = 0x80000000
static

Access is forbidden to vehicles with disabled persons' permits.

◆ DRIVE_ON_LFT_FLAG

final int com.cartotype.RoadType.DRIVE_ON_LFT_FLAG = 48
static

A road direction value indicating two-way traffic, driving on the left.

◆ DRIVE_ON_RIGHT_FLAG

final int com.cartotype.RoadType.DRIVE_ON_RIGHT_FLAG = 0
static

A road direction value indicating two-way traffic, driving on the right.

◆ EMERGENCY_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.EMERGENCY_ROAD_ACCESS_FLAG = 0x10000000
static

Access is forbidden to emergency vehicles.

◆ FIRST_OVER_LEVEL

final int com.cartotype.RoadType.FIRST_OVER_LEVEL = 0x1000
static

The first raised level: the default level for a bridge or overpass.

◆ FIRST_UNDER_LEVEL

final int com.cartotype.RoadType.FIRST_UNDER_LEVEL = 0xF000
static

The first sub-surface level: the default value for an underpass.

◆ FOOTPATH

final int com.cartotype.RoadType.FOOTPATH = 0xD00
static

Footpath.

◆ FORESTRY_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.FORESTRY_ROAD_ACCESS_FLAG = 0x8000000
static

Access is forbidden to forestry vehicles.

◆ GOODS_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.GOODS_ROAD_ACCESS_FLAG = 0x200000
static

Access is forbidden to light goods vehicles.

◆ HAZARDOUS_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.HAZARDOUS_ROAD_ACCESS_FLAG = 0x20000000
static

Access is forbidden to vehicles carrying hazardous materials.

◆ HEAVY_GOODS_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.HEAVY_GOODS_ROAD_ACCESS_FLAG = 0x400000
static

Access is forbidden to heavy goods vehicles.

◆ HIGH_OCCUPANCY_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.HIGH_OCCUPANCY_ROAD_ACCESS_FLAG = 0x100000
static

Access is forbidden to high-occupancy vehicles.

◆ LEVEL_MASK

final int com.cartotype.RoadType.LEVEL_MASK = 0xF000
static

The level (0 = surface, positive = above surface, negative = below surface) is held as a signed nybble in bits 12...15. Levels above 0 are not necessarily bridges; they can be embankments or other raised structures, and levels below 0 are not necessarily tunnels. There are separate bits to mark bridges and tunnels: BRIDGE_FLAG and TUNNEL_FLAG.

The level mask is also used for levels in the 'Type' attribute of non-road objects.

◆ LEVEL_SHIFT

final int com.cartotype.RoadType.LEVEL_SHIFT = 12
static

The number of bits by which road levels are shifted.

◆ LINK_FLAG

final int com.cartotype.RoadType.LINK_FLAG = 64
static

A synonym for RAMP_FLAG

◆ LOWER_GRADE_FLAG

final int com.cartotype.RoadType.LOWER_GRADE_FLAG = 128
static

A bit flag to allow a distinction to be made between grades of road, within the major road type. It allows OSM data to distinguish trunk roads from primary roads in a backward-compatible way.

◆ MAJOR_ROAD_TYPE_MASK

final int com.cartotype.RoadType.MAJOR_ROAD_TYPE_MASK = 0xF00
static

The major road type is held in bits 8...11; bits 7 and 6 are used for finer distinctions.

◆ MINOR

final int com.cartotype.RoadType.MINOR = 0x400
static

Local road or town or city street.

◆ MOTOR_CAR_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.MOTOR_CAR_ROAD_ACCESS_FLAG = 0x80000
static

Access is forbidden to motor cars.

◆ MOTOR_CYCLE_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.MOTOR_CYCLE_ROAD_ACCESS_FLAG = 0x40000
static

Access is forbidden to motorcycles.

◆ MOTOR_VEHICLE_ROAD_ACCESS_MASK

final int com.cartotype.RoadType.MOTOR_VEHICLE_ROAD_ACCESS_MASK = 0xFFFE0000 & ~(BICYCLE_ROAD_ACCESS_FLAG | PEDESTRIAN_ROAD_ACCESS_FLAG | WHEEL_CHAIR_ROAD_ACCESS_FLAG)
static

Access is forbidden to motor vehicles.

◆ MOTORWAY

final int com.cartotype.RoadType.MOTORWAY = PRIMARY_LIMITED_ACCESS
static

Primary road with limited access (motorway, freeway, etc.).

◆ MOTORWAY_LINK

final int com.cartotype.RoadType.MOTORWAY_LINK = PRIMARY_LIMITED_ACCESS | LINK_FLAG
static

Access ramp or link to primary road with limited access (motorway, freeway, etc.).

◆ ONE_WAY_BACKWARD_FLAG

final int com.cartotype.RoadType.ONE_WAY_BACKWARD_FLAG = 32
static

A road direction value indicating that the road is one-way in the reverse direction to that in which it is defined.

◆ ONE_WAY_FORWARD_FLAG

final int com.cartotype.RoadType.ONE_WAY_FORWARD_FLAG = 16
static

A road direction value indicating that the road is one-way in the direction in which it is defined.

◆ OTHER_0

final int com.cartotype.RoadType.OTHER_0 = 0xE00
static

User-defined road type 0.

◆ OTHER_1

final int com.cartotype.RoadType.OTHER_1 = 0xE00 | LOWER_GRADE_FLAG
static

User-defined road type 1.

◆ OTHER_2

final int com.cartotype.RoadType.OTHER_2 = 0xE00 | LINK_FLAG
static

User-defined road type 2.

◆ OTHER_3

final int com.cartotype.RoadType.OTHER_3 = 0xE00 | LOWER_GRADE_FLAG | LINK_FLAG
static

User-defined road type 3.

◆ OTHER_4

final int com.cartotype.RoadType.OTHER_4 = 0xF00
static

User-defined road type 4.

◆ OTHER_5

final int com.cartotype.RoadType.OTHER_5 = 0xF00 | LOWER_GRADE_FLAG
static

User-defined road type 5.

◆ OTHER_6

final int com.cartotype.RoadType.OTHER_6 = 0xF00 | LINK_FLAG
static

User-defined road type 6.

◆ OTHER_7

final int com.cartotype.RoadType.OTHER_7 = 0xF00 | LOWER_GRADE_FLAG | LINK_FLAG
static

User-defined road type 7.

◆ PASSENGER_FERRY

final int com.cartotype.RoadType.PASSENGER_FERRY = 0x900
static

Passenger-only ferry route.

◆ PATH

final int com.cartotype.RoadType.PATH = 0xA00
static

Path or walkway for pedestrians.

◆ PEDESTRIAN

final int com.cartotype.RoadType.PEDESTRIAN = PATH
static

Path or walkway for pedestrians.

◆ PEDESTRIAN_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.PEDESTRIAN_ROAD_ACCESS_FLAG = 0x2000000
static

Access is forbidden to pedestrians.

◆ PRIMARY

final int com.cartotype.RoadType.PRIMARY = PRIMARY_UNLIMITED_ACCESS | LOWER_GRADE_FLAG
static

Primary road: UK 'A' road.

◆ PRIMARY_LIMITED_ACCESS

final int com.cartotype.RoadType.PRIMARY_LIMITED_ACCESS = 0x100
static

Primary road with limited access (motorway, freeway, etc.).

◆ PRIMARY_LINK

final int com.cartotype.RoadType.PRIMARY_LINK = PRIMARY | LINK_FLAG
static

Access ramp or link to primary road.

◆ PRIMARY_UNLIMITED_ACCESS

final int com.cartotype.RoadType.PRIMARY_UNLIMITED_ACCESS = 0x200
static

Primary road: UK trunk road.

◆ PUBLIC_SERVICE_VEHICLE_ROAD_ACCESS_MASK

final int com.cartotype.RoadType.PUBLIC_SERVICE_VEHICLE_ROAD_ACCESS_MASK = BUS_ROAD_ACCESS_FLAG | TAXI_ROAD_ACCESS_FLAG
static

Access is forbidden to public service vehicles (buses and taxis).

◆ RAMP_FLAG

final int com.cartotype.RoadType.RAMP_FLAG = 64
static

A bit flag to allow access ramps to be marked as sub-types of a major road type.

◆ RESIDENTIAL

final int com.cartotype.RoadType.RESIDENTIAL = MINOR | LOWER_GRADE_FLAG
static

Narrow road or street with residential housing.

◆ RESTRICTION_FLAG

final int com.cartotype.RoadType.RESTRICTION_FLAG = 8
static

A bit flag indicating that the road has one or more restrictions (e.g., right turn only). The details of the restrictions are stored in string attributes.

◆ ROAD_ACCESS_MASK

final int com.cartotype.RoadType.ROAD_ACCESS_MASK = 0xFFFE0000
static

Access rules. These flags occupy the bits used for the OSM type in non-road layers, so may be used only where an OSM type is not used. Each flag forbids access to a certain type of vehicle.

◆ ROAD_TYPE_MASK

final int com.cartotype.RoadType.ROAD_TYPE_MASK = 0xFC0
static

The road type is held in bits 6...11.

◆ ROUNDABOUT_FLAG

final int com.cartotype.RoadType.ROUNDABOUT_FLAG = 4
static

A bit flag indicating that the road is part of a roundabout.

◆ ROUTING_MASK

final int com.cartotype.RoadType.ROUTING_MASK = 0x3E
static

The toll, roundabout, restriction and direction flags are held in bits 1...5.

◆ SECOND_UNDER_LEVEL

final int com.cartotype.RoadType.SECOND_UNDER_LEVEL = 0xE000
static

The second sub-surface level: the default value for a tunnel.

◆ SECONDARY

final int com.cartotype.RoadType.SECONDARY = 0x300
static

Secondary road: UK 'B' road.

◆ SECONDARY_LINK

final int com.cartotype.RoadType.SECONDARY_LINK = SECONDARY | LINK_FLAG
static

Access ramp or link to secondary road.

◆ SERVICE_ROAD

final int com.cartotype.RoadType.SERVICE_ROAD = 0x700
static

Service road or access road.

◆ STAIRWAY

final int com.cartotype.RoadType.STAIRWAY = 0xB00
static

Stairway or escalator for pedestrians.

◆ TAXI_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.TAXI_ROAD_ACCESS_FLAG = 0x1000000
static

Access is forbidden to taxis.

◆ TERTIARY

final int com.cartotype.RoadType.TERTIARY = SECONDARY | LOWER_GRADE_FLAG
static

Tertiary road: one level above minor and residential roads.

◆ TERTIARY_LINK

final int com.cartotype.RoadType.TERTIARY_LINK = TERTIARY | LINK_FLAG
static

Access ramp or link to tertiary road.

◆ TOLL_FLAG

final int com.cartotype.RoadType.TOLL_FLAG = 2
static

A toll must be paid to use this road. More details may be available in a the string attributes of a map object.

◆ TRACK

final int com.cartotype.RoadType.TRACK = BYWAY
static

Byway: road or track open to motor vehicles.

◆ TRUNK

final int com.cartotype.RoadType.TRUNK = PRIMARY_UNLIMITED_ACCESS
static

Primary road: UK trunk road.

◆ TRUNK_LINK

final int com.cartotype.RoadType.TRUNK_LINK = TRUNK | LINK_FLAG
static

Access ramp or link to trunk road.

◆ TUNNEL_FLAG

final int com.cartotype.RoadType.TUNNEL_FLAG = 1
static

A bit flag to identify tunnels.

◆ UNCLASSIFIED

final int com.cartotype.RoadType.UNCLASSIFIED = MINOR
static

Local road or town or city street.

◆ UNKNOWN_MAJOR

final int com.cartotype.RoadType.UNKNOWN_MAJOR = 0
static

Roads of unknown type.

◆ VEHICULAR_FERRY

final int com.cartotype.RoadType.VEHICULAR_FERRY = 0x800
static

Vehicular ferry route.

◆ WHEEL_CHAIR_ROAD_ACCESS_FLAG

final int com.cartotype.RoadType.WHEEL_CHAIR_ROAD_ACCESS_FLAG = 0x40000000
static

Access is forbidden to wheelchairs.


The documentation for this class was generated from the following file: