com.javadocmd.simplelatlng.window
Class SortWrapper<E>

java.lang.Object
  extended by com.javadocmd.simplelatlng.window.SortWrapper<E>
Type Parameters:
E - the type that SortWrapper is wrapping.

public class SortWrapper<E>
extends Object

This class wraps another class in order to attach a distance value to it. A list of SortWrappers may then be easily sorted.

Author:
Tyler Coles

Nested Class Summary
static class SortWrapper.DistanceComparator<E>
          Compares SortWrappers by their associated distance value.
 
Constructor Summary
SortWrapper(E value, double distance)
           
 
Method Summary
 double getDistance()
           
 E getValue()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SortWrapper

public SortWrapper(E value,
                   double distance)
Method Detail

getValue

public E getValue()

getDistance

public double getDistance()


Copyright © 2010-2013. All Rights Reserved.