Sports Lib API - v17.3.0
GitHub
npm
Preparing search index...
API
RouteFileInterface
Interface RouteFileInterface
A collection of planned routes and file-level waypoints imported from or exported to a route format.
interface
RouteFileInterface
{
createdAt
:
Date
|
null
;
creator
:
CreatorInterface
;
name
:
string
;
srcFileType
:
string
;
addRoute
(
route
:
RouteInterface
)
:
this
;
addRoutes
(
routes
:
RouteInterface
[]
)
:
this
;
addStat
(
stat
:
DataInterface
<
unknown
>
)
:
void
;
addWaypoint
(
waypoint
:
RouteWaypointInterface
)
:
this
;
addWaypoints
(
waypoints
:
RouteWaypointInterface
[]
)
:
this
;
clearRoutes
()
:
this
;
clearStats
()
:
void
;
getDistance
()
:
DataDistance
;
getFirstRoute
()
:
RouteInterface
;
getID
()
:
string
|
null
;
getRoutes
()
:
RouteInterface
[]
;
getStat
<
TValue
=
DefaultDataValue
>
(
statType
:
string
,
)
:
void
|
DataInterface
<
TValue
>
;
getStats
<
TValue
=
DefaultDataValue
>
()
:
Map
<
string
,
DataInterface
<
TValue
>
>
;
getStatsAsArray
<
TValue
=
DefaultDataValue
>
()
:
DataInterface
<
TValue
>
[]
;
getWaypoints
()
:
RouteWaypointInterface
[]
;
hasRoutes
()
:
boolean
;
removeStat
(
statType
:
string
)
:
void
;
setDistance
(
distance
:
DataDistance
)
:
void
;
setID
(
id
:
string
|
null
)
:
this
;
toJSON
()
:
RouteFileJSONInterface
;
}
Hierarchy (
View Summary
)
SerializableClassInterface
IDClassInterface
StatsClassInterface
RouteFileInterface
Implemented by
RouteFile
Index
Properties
created
At
creator
name
src
File
Type
Methods
add
Route
add
Routes
add
Stat
add
Waypoint
add
Waypoints
clear
Routes
clear
Stats
get
Distance
get
First
Route
get
ID
get
Routes
get
Stat
get
Stats
get
Stats
As
Array
get
Waypoints
has
Routes
remove
Stat
set
Distance
set
ID
to
JSON
Properties
created
At
createdAt
:
Date
|
null
creator
creator
:
CreatorInterface
name
name
:
string
src
File
Type
srcFileType
:
string
Methods
add
Route
addRoute
(
route
:
RouteInterface
)
:
this
Parameters
route
:
RouteInterface
Returns
this
add
Routes
addRoutes
(
routes
:
RouteInterface
[]
)
:
this
Parameters
routes
:
RouteInterface
[]
Returns
this
add
Stat
addStat
(
stat
:
DataInterface
<
unknown
>
)
:
void
Parameters
stat
:
DataInterface
<
unknown
>
Returns
void
add
Waypoint
addWaypoint
(
waypoint
:
RouteWaypointInterface
)
:
this
Parameters
waypoint
:
RouteWaypointInterface
Returns
this
add
Waypoints
addWaypoints
(
waypoints
:
RouteWaypointInterface
[]
)
:
this
Parameters
waypoints
:
RouteWaypointInterface
[]
Returns
this
clear
Routes
clearRoutes
()
:
this
Returns
this
clear
Stats
clearStats
()
:
void
Returns
void
get
Distance
getDistance
()
:
DataDistance
Returns
DataDistance
get
First
Route
getFirstRoute
()
:
RouteInterface
Returns
RouteInterface
get
ID
getID
()
:
string
|
null
Returns
string
|
null
get
Routes
getRoutes
()
:
RouteInterface
[]
Returns
RouteInterface
[]
get
Stat
getStat
<
TValue
=
DefaultDataValue
>
(
statType
:
string
,
)
:
void
|
DataInterface
<
TValue
>
Type Parameters
TValue
=
DefaultDataValue
Parameters
statType
:
string
Returns
void
|
DataInterface
<
TValue
>
get
Stats
getStats
<
TValue
=
DefaultDataValue
>
()
:
Map
<
string
,
DataInterface
<
TValue
>
>
Type Parameters
TValue
=
DefaultDataValue
Returns
Map
<
string
,
DataInterface
<
TValue
>
>
get
Stats
As
Array
getStatsAsArray
<
TValue
=
DefaultDataValue
>
()
:
DataInterface
<
TValue
>
[]
Type Parameters
TValue
=
DefaultDataValue
Returns
DataInterface
<
TValue
>
[]
get
Waypoints
getWaypoints
()
:
RouteWaypointInterface
[]
Returns
RouteWaypointInterface
[]
has
Routes
hasRoutes
()
:
boolean
Returns
boolean
remove
Stat
removeStat
(
statType
:
string
)
:
void
Parameters
statType
:
string
Returns
void
set
Distance
setDistance
(
distance
:
DataDistance
)
:
void
Parameters
distance
:
DataDistance
Returns
void
set
ID
setID
(
id
:
string
|
null
)
:
this
Parameters
id
:
string
|
null
Returns
this
to
JSON
toJSON
()
:
RouteFileJSONInterface
Returns
RouteFileJSONInterface
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
On This Page
Properties
created
At
creator
name
src
File
Type
Methods
add
Route
add
Routes
add
Stat
add
Waypoint
add
Waypoints
clear
Routes
clear
Stats
get
Distance
get
First
Route
get
ID
get
Routes
get
Stat
get
Stats
get
Stats
As
Array
get
Waypoints
has
Routes
remove
Stat
set
Distance
set
ID
to
JSON
GitHub
npm
Sports Lib API - v17.3.0
Loading...
A collection of planned routes and file-level waypoints imported from or exported to a route format.