/
Coordinates.cljs
187 lines (134 loc) · 5.8 KB
/
Coordinates.cljs
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
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
(ns web.geolocation.Coordinates
"The Coordinates interface represents the position and altitude
the device on Earth, as well as the accuracy with which these
are calculated."
(:refer-clojure :exclude []))
(defn latitude
"Property.
The Coordinates.latitude read-only property is a double representing
latitude of the position in decimal degrees.
`lat = coordinates.latitude`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/latitude`"
[this]
(-> this (.latitude)))
(defn set-latitude!
"Property.
The Coordinates.latitude read-only property is a double representing
latitude of the position in decimal degrees.
`lat = coordinates.latitude`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/latitude`"
[this val]
(aset this "latitude" val))
(defn accuracy
"Property.
The Coordinates.accuracy read-only property is a strictly positive
representing the accuracy, with a 95% confidence level, of the
and `Coordinates.longitude` properties expressed in meters.
`acc = coordinates.accuracy`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/accuracy`"
[this]
(-> this (.accuracy)))
(defn set-accuracy!
"Property.
The Coordinates.accuracy read-only property is a strictly positive
representing the accuracy, with a 95% confidence level, of the
and `Coordinates.longitude` properties expressed in meters.
`acc = coordinates.accuracy`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/accuracy`"
[this val]
(aset this "accuracy" val))
(defn altitude
"Property.
The Coordinates.altitude read-only property is a double representing
altitude of the position in meters, relative to sea level. This
is null if the implementation cannot provide this data.
`alt = coordinates.altitude`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/altitude`"
[this]
(-> this (.altitude)))
(defn set-altitude!
"Property.
The Coordinates.altitude read-only property is a double representing
altitude of the position in meters, relative to sea level. This
is null if the implementation cannot provide this data.
`alt = coordinates.altitude`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/altitude`"
[this val]
(aset this "altitude" val))
(defn altitude-accuracy
"Property.
The Coordinates.altitudeAccuracy read-only property is a strictly
double representing the accuracy, with a 95% confidence level,
the altitude expressed in meters. This value is null if the implementation
support measuring altitude.
`altAcc = coordinates.altitudeAccuracy`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/altitudeAccuracy`"
[this]
(-> this (.altitudeAccuracy)))
(defn set-altitude-accuracy!
"Property.
The Coordinates.altitudeAccuracy read-only property is a strictly
double representing the accuracy, with a 95% confidence level,
the altitude expressed in meters. This value is null if the implementation
support measuring altitude.
`altAcc = coordinates.altitudeAccuracy`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/altitudeAccuracy`"
[this val]
(aset this "altitudeAccuracy" val))
(defn heading
"Property.
The Coordinates.heading read-only property is a double representing
direction in which the device is traveling. This value, specified
degrees, indicates how far off from heading due north the device
Zero degrees represents true true north, and the direction is
clockwise (which means that east is 90 degrees and west is 270
If `Coordinates.speed` is 0, heading is NaN. If the device is
able to provide heading information, this value is null.
`heading = coordinates.heading`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/heading`"
[this]
(-> this (.heading)))
(defn set-heading!
"Property.
The Coordinates.heading read-only property is a double representing
direction in which the device is traveling. This value, specified
degrees, indicates how far off from heading due north the device
Zero degrees represents true true north, and the direction is
clockwise (which means that east is 90 degrees and west is 270
If `Coordinates.speed` is 0, heading is NaN. If the device is
able to provide heading information, this value is null.
`heading = coordinates.heading`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/heading`"
[this val]
(aset this "heading" val))
(defn longitude
"Property.
The `web.geolocation.Coordinates` interface's read-only longitude
is a double-precision floating point value which represents the
of a geographical position, specified in decimal degrees. Together
a `web.dom.DOMTimeStamp` indicating a time of measurement, the
object is part of the `web.geolocation.Position` interface which
the object type returned by Geolocation API functions that obtain
return a geographical position.
`longitude = coordinates.longitude`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/longitude`"
[this]
(-> this (.longitude)))
(defn speed
"Property.
The Coordinates.speed read-only property is a double representing
velocity of the device in meters per second. This value is null
the implementation is not able to measure it.
`speed = coordinates.speed`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/speed`"
[this]
(-> this (.speed)))
(defn set-speed!
"Property.
The Coordinates.speed read-only property is a double representing
velocity of the device in meters per second. This value is null
the implementation is not able to measure it.
`speed = coordinates.speed`
See also: `https://developer.mozilla.org/en-US/docs/Web/API/Coordinates/speed`"
[this val]
(aset this "speed" val))