public class Camera
extends java.lang.Object
Constructor and Description |
---|
Camera()
Creates a
Camera with reasonable defaults. |
Camera(CameraLocation location,
boolean autofocus,
boolean flash)
Creates a new
Camera which describes an on device camera and it's features. |
Modifier and Type | Method and Description |
---|---|
Camera |
deepCopy()
Returns a copy of the object that shares no state with it,
but is initialized to equivalent values.
|
boolean |
equals(java.lang.Object o) |
CameraLocation |
getLocation() |
boolean |
hasAutofocus() |
boolean |
hasFlash() |
int |
hashCode() |
void |
setAutofocus(boolean hasAutofocus) |
void |
setFlash(boolean flash) |
void |
setLocation(CameraLocation location) |
java.lang.String |
toString() |
public Camera()
Camera
with reasonable defaults.
The resulting Camera
with be on the CameraLocation.BACK
with both autofocus
and flash.public Camera(@NonNull CameraLocation location, boolean autofocus, boolean flash)
Camera
which describes an on device camera and it's features.location
- The location of the Camera
on the device. Either
CameraLocation.FRONT
or CameraLocation.BACK
.autofocus
- Whether the Camera
can auto-focus.flash
- Whether the Camera
has flash.@NonNull public CameraLocation getLocation()
public void setLocation(@NonNull CameraLocation location)
public boolean hasAutofocus()
public void setAutofocus(boolean hasAutofocus)
public boolean hasFlash()
public void setFlash(boolean flash)
@NonNull public Camera deepCopy()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object