Build 1.0_r1(from source)

android.telephony.gsm
Class GsmCellLocation

java.lang.Object
  extended by android.telephony.CellLocation
      extended by android.telephony.gsm.GsmCellLocation

public class GsmCellLocation
extends CellLocation

Represents the cell location on a GSM phone.


Constructor Summary
GsmCellLocation()
          Empty constructor.
GsmCellLocation(Bundle bundle)
          Initialize the object from a bundle.
 
Method Summary
 boolean equals(Object o)
          Compares the argument to the receiver, and returns true if they represent the same object using a class specific comparison.
 void fillInNotifierBundle(Bundle m)
          Set intent notifier Bundle based on service state
 int getCid()
           
 int getLac()
           
 int hashCode()
          Returns an integer hash code for the receiver.
 void setLacAndCid(int lac, int cid)
          Set the location area code and the cell id.
 void setStateInvalid()
          Invalidate this object.
 String toString()
          Returns a string containing a concise, human-readable description of the receiver.
 
Methods inherited from class android.telephony.CellLocation
getEmpty, newFromBundle, requestLocationUpdate
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GsmCellLocation

public GsmCellLocation()
Empty constructor. Initializes the LAC and CID to -1.


GsmCellLocation

public GsmCellLocation(Bundle bundle)
Initialize the object from a bundle.

Method Detail

getLac

public int getLac()
Returns:
gsm location area code, -1 if unknown, 0xffff max legal value

getCid

public int getCid()
Returns:
gsm cell id, -1 if unknown, 0xffff max legal value

setStateInvalid

public void setStateInvalid()
Invalidate this object. The location area code and the cell id are set to -1.


setLacAndCid

public void setLacAndCid(int lac,
                         int cid)
Set the location area code and the cell id.


hashCode

public int hashCode()
Description copied from class: Object
Returns an integer hash code for the receiver. Any two objects which answer true when passed to .equals must answer the same value for this method.

Overrides:
hashCode in class Object
Returns:
int the receiver's hash.
See Also:
Object.equals(java.lang.Object)

equals

public boolean equals(Object o)
Description copied from class: Object
Compares the argument to the receiver, and returns true if they represent the same object using a class specific comparison. The implementation in Object returns true only if the argument is the exact same object as the receiver (==).

Overrides:
equals in class Object
Parameters:
o - Object the object to compare with this object.
Returns:
boolean true if the object is the same as this object false if it is different from this object.
See Also:
Object.hashCode()

toString

public String toString()
Description copied from class: Object
Returns a string containing a concise, human-readable description of the receiver.

Overrides:
toString in class Object
Returns:
String a printable representation for the receiver.

fillInNotifierBundle

public void fillInNotifierBundle(Bundle m)
Set intent notifier Bundle based on service state

Specified by:
fillInNotifierBundle in class CellLocation
Parameters:
m - intent notifier Bundle

Build 1.0_r1(from source)

Please submit a feedback, bug or feature