summaryrefslogtreecommitdiff
path: root/api/franca/navigation/NavigationTypes.fidl
blob: 3282f3e7e0b4ab2949a1b94862fb6b3ff8b12375 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
// SPDX-License-Identifier: MPL-2.0
// Copyright (C) 2014, PCA Peugeot Citro�n, XS Embedded GmbH, TomTom International B.V., Continental Automotive GmbH, BMW Car IT GmbH,  Alpine Electronics R&D Europe GmbH, AISIN AW CO., LTD.,  Neusoft Technology Solutions GmbH, Jaguar Land Rover Limited, Visteon Corporation, Elektrobit Automotive GmbH
// This Source Code Form is subject to the terms of the
// Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with
// this file, you can obtain one at http://mozilla.org/MPL/2.0/.

package org.genivi.navigation

typeCollection NavigationTypes {

	<** @description: version.**>			
	struct Version {
		<** @description : when the major changes, then backward compatibility with previous releases is not granted.**>
		UInt16 ^versionMajor
		<** @description : when the minor changes, then backward compatibility with previous releases is granted, but something changed in the implementation of the API (e.g. new methods may have been added).**>
		UInt16 ^versionMinor
		<** @description : when the micro changes, then backward compatibility with previous releases is granted (bug fixes or documentation modifications).**>
		UInt16 ^versionMicro
		<** @description : release date (e.g. 21-06-2011).**>
		String date
	}

	typedef Handle is UInt32

	typedef Timestamp is UInt64
	
	typedef LinkId is ByteBuffer
	
    <** @description: Handle to a location.
    	Range[0:0x7fffffff]
	**>
    typedef LocationHandle is Handle	


/* geometric types */		

	struct Coordinate2D {
		Double latitude
		Double longitude
	}

	struct Coordinate3D extends Coordinate2D {
		Int32 altitude
	}

	struct Rectangle {
		Coordinate2D topLeft
		Coordinate2D bottomRight
	}
	
	array Polygon of Coordinate2D
	
	typedef Area is Polygon

    <** @description: Kind of shapes. **>
    enumeration ShapeType {
        CIRCLE
        RECTANGLE
        POLYGON
    }
    
    <** @description: A radius in meters.
        Range[0x0:0xffffffff]
    **>	
	typedef Radius is UInt32

	<** @description: A circle given as center and radius. **>			
	struct Circle {
		<**	@description : The center of the circle.**>
		Coordinate2D center
		<**	@description : The radius of the circle.**>
		Radius radius
	}

	typedef Distance is Double

/* enumerations */
	
// for the time being, no use of inheritance (extends) for the enumerations, to be implemented later
	enumeration BasicEnum {
		INVALID 	= 0
	}

 	enumeration TimeStampedEnum {
// 	enumeration TimeStampedEnum extends BasicEnum {
		TIMESTAMP	= 16
	}

//	enumeration GeoLocalizedEnum extends TimeStampedEnum {
	enumeration GeoLocalizedEnum {
		INVALID 	= 0
		TIMESTAMP	= 16
		LATITUDE	= 160
		LONGITUDE	= 161
		ALTITUDE	= 162
	}

    <** @description: Settings**>
    enumeration Settings {
        INVALID 				= 0
        UNITS_OF_MEASUREMENT 	= 48 //Base 0x0030
        LOCALE 					= 37
        TIME_FORMAT 			= 3
        COORDINATES_FORMAT 		= 6
    }

	enumeration Units {
		METER		= 50
		MILE		= 51
		KM			= 52
		YARD		= 53
		FOOT		= 54
	}

	enumeration TimeFormat {
		INVALID		= 0
		TWELVEH     = 1
		TWENTYFOURH	= 2
	}

	enumeration CoordinatesFormat {
		INVALID		= 0
		<** @description:DEGREES format = d.dº**>
		DEGREES     = 1
        <** @description:MINUTES format = dºm.m'**>		
		MINUTES		= 2
        <** @description:SECONDS format = dºm's"**>
		SECONDS		= 3
	}

	struct Locales
	{
		<** @description : the language used. ISO 639‐3 language code (lower case)**>
		String languageCode				
		<** @description : the country specific variant for the language used. ISO 3166‐1 alpha 3 country code (upper case)**>
		String countryCode				
		<** @description : the script specific variant for the language used. ISO 15924 alpha 4 script code (upper case)**>
		String scriptCode						
	}
}