Class Distance

java.lang.Object
  extended by Distance
All Implemented Interfaces:
java.lang.Comparable<Distance>

public class Distance
extends java.lang.Object
implements java.lang.Comparable<Distance>


Field Summary
private  int myFeet
           
private  int myInches
           
 
Constructor Summary
Distance()
           
Distance(Distance arg)
           
Distance(int x)
           
Distance(int x, int y)
           
 
Method Summary
 int compareTo(Distance d)
           
 boolean equals(Distance arg)
           
 int getFeet()
           
 int getInches()
           
 void setFeet(int x)
           
 void setInches(int x)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

myFeet

private int myFeet

myInches

private int myInches
Constructor Detail

Distance

public Distance()

Distance

public Distance(int x)

Distance

public Distance(int x,
                int y)

Distance

public Distance(Distance arg)
Method Detail

getFeet

public int getFeet()

getInches

public int getInches()

setFeet

public void setFeet(int x)

setInches

public void setInches(int x)

compareTo

public int compareTo(Distance d)
Specified by:
compareTo in interface java.lang.Comparable<Distance>

equals

public boolean equals(Distance arg)

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object