org.openstreetmap.josm.data.gpx
Class ImmutableGpxTrack

java.lang.Object
  extended by org.openstreetmap.josm.data.gpx.ImmutableGpxTrack
All Implemented Interfaces:
GpxTrack

public class ImmutableGpxTrack
extends java.lang.Object
implements GpxTrack


Field Summary
private  java.util.Map<java.lang.String,java.lang.Object> attributes
           
private  Bounds bounds
           
private  double length
           
private  java.util.Collection<GpxTrackSegment> segments
           
 
Constructor Summary
ImmutableGpxTrack(java.util.Collection<java.util.Collection<WayPoint>> trackSegs, java.util.Map<java.lang.String,java.lang.Object> attributes)
           
 
Method Summary
private  Bounds calculateBounds()
           
private  double calculateLength()
           
 java.util.Map<java.lang.String,java.lang.Object> getAttributes()
           
 Bounds getBounds()
           
 java.util.Collection<GpxTrackSegment> getSegments()
           
 int getUpdateCount()
           
 double length()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

attributes

private final java.util.Map<java.lang.String,java.lang.Object> attributes

segments

private final java.util.Collection<GpxTrackSegment> segments

length

private final double length

bounds

private final Bounds bounds
Constructor Detail

ImmutableGpxTrack

public ImmutableGpxTrack(java.util.Collection<java.util.Collection<WayPoint>> trackSegs,
                         java.util.Map<java.lang.String,java.lang.Object> attributes)
Method Detail

calculateLength

private double calculateLength()

calculateBounds

private Bounds calculateBounds()

getAttributes

public java.util.Map<java.lang.String,java.lang.Object> getAttributes()
Specified by:
getAttributes in interface GpxTrack

getBounds

public Bounds getBounds()
Specified by:
getBounds in interface GpxTrack

length

public double length()
Specified by:
length in interface GpxTrack

getSegments

public java.util.Collection<GpxTrackSegment> getSegments()
Specified by:
getSegments in interface GpxTrack

getUpdateCount

public int getUpdateCount()
Specified by:
getUpdateCount in interface GpxTrack
Returns:
Number of times this track has been changed. Always 0 for read-only tracks


JOSM