public final class CameraPosition extends Object implements Parcelable
Modifier and Type | Class and Description |
---|---|
static class |
CameraPosition.Builder
Builder for composing CameraPosition objects.
|
Parcelable.ClassLoaderCreator<T>, Parcelable.Creator<T>
Modifier and Type | Field and Description |
---|---|
double |
bearing
Direction that the camera is pointing in, in degrees clockwise from north.
|
static Parcelable.Creator<CameraPosition> |
CREATOR |
static CameraPosition |
DEFAULT |
double[] |
padding
Padding in pixels.
|
LatLng |
target
The location that the camera is pointing at.
|
double |
tilt
The angle, in degrees, of the camera angle from the nadir (directly facing the Earth).
|
double |
zoom
Zoom level near the center of the screen.
|
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE
Modifier and Type | Method and Description |
---|---|
int |
describeContents()
Describe the kinds of special objects contained in this Parcelable's
marshalled representation.
|
boolean |
equals(Object o)
Compares this
CameraPosition object with another CameraPosition and
determines if their target, zoom, tilt, and bearing match. |
int |
hashCode()
Gives an integer which can be used as the bucket number for storing elements of the set/map.
|
String |
toString()
Returns a String with the camera target, zoom, bearing and tilt.
|
void |
writeToParcel(Parcel out,
int flags)
Flatten this object in to a Parcel.
|
public static final CameraPosition DEFAULT
public static final Parcelable.Creator<CameraPosition> CREATOR
public final double bearing
public final LatLng target
public final double tilt
CameraPosition.Builder.tilt(double)
for details of restrictions on the range of values.public final double zoom
CameraPosition.Builder.zoom(double)
for the definition of the camera's
zoom level.public final double[] padding
CameraPosition.Builder.padding(double[])
for the definition of the camera's padding.public int describeContents()
describeContents
in interface Parcelable
public void writeToParcel(Parcel out, int flags)
writeToParcel
in interface Parcelable
out
- The Parcel in which the object should be written.flags
- Additional flags about how the object should be written. May be 0 or
Parcelable.PARCELABLE_WRITE_RETURN_VALUE
.public String toString()
public boolean equals(Object o)
CameraPosition
object with another CameraPosition
and
determines if their target, zoom, tilt, and bearing match.equals
in class Object
o
- Another CameraPosition
to compare with this object.CameraPosition
object.
Else, false.public int hashCode()
© 2015–2019 Mapbox. All rights reserved.