com.fitbit.api.common.model.body
Enum DataPeriod

java.lang.Object
  extended by java.lang.Enum<DataPeriod>
      extended by com.fitbit.api.common.model.body.DataPeriod
All Implemented Interfaces:
Serializable, Comparable<DataPeriod>

public enum DataPeriod
extends Enum<DataPeriod>

Created by IntelliJ IDEA. User: Kiryl Date: 2/11/12 Time: 4:59 AM


Enum Constant Summary
ONE_DAY
           
ONE_MONTH
           
ONE_WEEK
           
SEVEN_DAYS
           
THIRTY_DAYS
           
 
Method Summary
static DataPeriod findByShortForm(String shortForm)
           
static DataPeriod findCeil(int days)
           
 int getDays()
           
 String getShortForm()
           
static DataPeriod valueOf(String name)
          Returns the enum constant of this type with the specified name.
static DataPeriod[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

ONE_DAY

public static final DataPeriod ONE_DAY

SEVEN_DAYS

public static final DataPeriod SEVEN_DAYS

THIRTY_DAYS

public static final DataPeriod THIRTY_DAYS

ONE_WEEK

public static final DataPeriod ONE_WEEK

ONE_MONTH

public static final DataPeriod ONE_MONTH
Method Detail

values

public static DataPeriod[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (DataPeriod c : DataPeriod.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static DataPeriod valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name
NullPointerException - if the argument is null

findByShortForm

public static DataPeriod findByShortForm(String shortForm)

findCeil

public static DataPeriod findCeil(int days)

getDays

public int getDays()

getShortForm

public String getShortForm()


Copyright © 2012. All Rights Reserved.