net.sf.uadetector
Enum ReadableDeviceCategory.Category

java.lang.Object
  extended by java.lang.Enum<ReadableDeviceCategory.Category>
      extended by net.sf.uadetector.ReadableDeviceCategory.Category
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<ReadableDeviceCategory.Category>
Enclosing interface:
ReadableDeviceCategory

public static enum ReadableDeviceCategory.Category
extends java.lang.Enum<ReadableDeviceCategory.Category>

Contains all at the time of implementation known device categories, so that a caller can easily and type-safe test against them.


Enum Constant Summary
GAME_CONSOLE
          A game console is an interactive computer that produces a video display signal which can be used with a display device (a television, monitor, etc.) to display a video game.
OTHER
          A device that doesn't match the other categories
PDA
          A personal digital assistant (PDA), also known as a palmtop computer, or personal data assistant, is a mobile device that functions as a personal information manager.
PERSONAL_COMPUTER
          A personal computer (PC) is a general-purpose computer, whose size, capabilities, and original sale price makes it useful for individuals, and which is intended to be operated directly by an end-user with no intervening computer operator.
SMART_TV
          A smart TV, sometimes referred to as connected TV or hybrid TV
SMARTPHONE
          A smartphone is a mobile phone built on a mobile operating system, with more advanced computing capability and connectivity than a feature phone
TABLET
          A tablet computer, or simply tablet, is a mobile computer with display, circuitry and battery in a single unit.
UNKNOWN
          An unknown device category
WEARABLE_COMPUTER
          Wearable computers, also known as body-borne computers are miniature electronic devices that are worn by the bearer under, with or on top of clothing.
 
Method Summary
static ReadableDeviceCategory.Category evaluate(java.lang.String categoryName)
          Tries to find by the given category name a matching enum value.
 java.lang.String getName()
          Returns the name of the device category.
static ReadableDeviceCategory.Category valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static ReadableDeviceCategory.Category[] 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

GAME_CONSOLE

public static final ReadableDeviceCategory.Category GAME_CONSOLE
A game console is an interactive computer that produces a video display signal which can be used with a display device (a television, monitor, etc.) to display a video game. The term "game console" is used to distinguish a machine designed for people to buy and use primarily for playing video games on a TV in contrast to arcade machines, handheld game consoles, or home computers.


OTHER

public static final ReadableDeviceCategory.Category OTHER
A device that doesn't match the other categories


PDA

public static final ReadableDeviceCategory.Category PDA
A personal digital assistant (PDA), also known as a palmtop computer, or personal data assistant, is a mobile device that functions as a personal information manager. PDAs are largely considered obsolete with the widespread adoption of smartphones.


PERSONAL_COMPUTER

public static final ReadableDeviceCategory.Category PERSONAL_COMPUTER
A personal computer (PC) is a general-purpose computer, whose size, capabilities, and original sale price makes it useful for individuals, and which is intended to be operated directly by an end-user with no intervening computer operator.


SMART_TV

public static final ReadableDeviceCategory.Category SMART_TV
A smart TV, sometimes referred to as connected TV or hybrid TV


SMARTPHONE

public static final ReadableDeviceCategory.Category SMARTPHONE
A smartphone is a mobile phone built on a mobile operating system, with more advanced computing capability and connectivity than a feature phone


TABLET

public static final ReadableDeviceCategory.Category TABLET
A tablet computer, or simply tablet, is a mobile computer with display, circuitry and battery in a single unit. Tablets are often equipped with sensors, including cameras, microphone, accelerometer and touchscreen, with finger or stylus gestures replacing computer mouse and keyboard.


UNKNOWN

public static final ReadableDeviceCategory.Category UNKNOWN
An unknown device category


WEARABLE_COMPUTER

public static final ReadableDeviceCategory.Category WEARABLE_COMPUTER
Wearable computers, also known as body-borne computers are miniature electronic devices that are worn by the bearer under, with or on top of clothing.

Method Detail

values

public static ReadableDeviceCategory.Category[] 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 (ReadableDeviceCategory.Category c : ReadableDeviceCategory.Category.values())
    System.out.println(c);

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

valueOf

public static ReadableDeviceCategory.Category valueOf(java.lang.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:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

evaluate

public static ReadableDeviceCategory.Category evaluate(@Nonnull
                                                       java.lang.String categoryName)
Tries to find by the given category name a matching enum value. The category name must match against an device entry in the UAS data.

Parameters:
categoryName - name of an device category
Returns:
the matching enum value or UNKNOWN
Throws:
net.sf.qualitycheck.exception.IllegalNullArgumentException - if the given argument is null

getName

@Nonnull
public java.lang.String getName()
Returns the name of the device category.

Returns:
name of the category


Copyright © 2011-2014. All Rights Reserved.