com.android.sdklib.devices
Class Camera

java.lang.Object
  extended by com.android.sdklib.devices.Camera

public class Camera
extends java.lang.Object


Constructor Summary
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.
 
Method Summary
 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)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Camera

public Camera()
Creates a Camera with reasonable defaults. The resulting Camera with be on the CameraLocation.BACK with both autofocus and flash.


Camera

public Camera(@NonNull
              CameraLocation location,
              boolean autofocus,
              boolean flash)
Creates a new Camera which describes an on device camera and it's features.

Parameters:
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.
Method Detail

getLocation

@NonNull
public CameraLocation getLocation()

setLocation

public void setLocation(@NonNull
                        CameraLocation location)

hasAutofocus

public boolean hasAutofocus()

setAutofocus

public void setAutofocus(boolean hasAutofocus)

hasFlash

public boolean hasFlash()

setFlash

public void setFlash(boolean flash)

deepCopy

@NonNull
public Camera deepCopy()
Returns a copy of the object that shares no state with it, but is initialized to equivalent values.

Returns:
A copy of the object.

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object