org.apache.myfaces.trinidad.context
Interface Agent


public interface Agent

The Agent interface describes the client that is making the request that will display the rendered output.

Implementations that provide the set of capabilities must clearly define the names of these capabilities and their values.

Capability names that are implementation private must be defined so using appropriate naming schemes. Trinidad private capability names are prefixed using "-adfinternal-xxx", and such capability names (and their values) may change at anytime (and not guaranteed to be supported in future releases).


Field Summary
static String AGENT_BLACKBERRY
          Constant for BlackBerry Browser agent.
static String AGENT_EMAIL
          Constant for email agent.
static String AGENT_GECKO
          Constant for Gecko agent.
static String AGENT_GENERIC_DESKTOP
          Constant for a generic desktop agent that is unknown but relatively powerful
static String AGENT_GENERICPDA
          Constant for basic HTML (without JavaScript) Browser agent.
static String AGENT_GOOGLEBOT
          Constant for Google web crawler
static String AGENT_IE
          Constant for Internet Explorer agent
static String AGENT_KONQUEROR
          Constant for Konqueror agent
static String AGENT_MSNBOT
          Constant for MSN web crawler (currently used by Bing and Yahoo)
static String AGENT_NOKIA_S60
          Constant for Symbian Nokia S60 agent.
static String AGENT_OPERA
          Constant for Opera agent.
static String AGENT_ORACLE_SES
          Constant for Oracle SES web crawler
static String AGENT_UNKNOWN
          Constant for when the agent is not supported or not recognized
static String AGENT_VERSION_UNKNOWN
          Constant for unknown Agent version
static String AGENT_WEBKIT
          Constant for Apple Webkit agent.
static String MAKE_MODEL_UNKNOWN
          Constant for unknown make model version
static String PLATFORM_ANDROID
          Constant for android device browsers
static String PLATFORM_BLACKBERRY
          Constant for blackberry platform
static String PLATFORM_GENERICPDA
          Constant for generic PDA device browser
static String PLATFORM_IPHONE
          Constant for the iOS (iPhone/iPod touch/iPad) platform
static String PLATFORM_LINUX
          Constant for linux platform
static String PLATFORM_MAC
          Deprecated.  
static String PLATFORM_MACOS
          Constant for MacOS platform
static String PLATFORM_NOKIA_S60
          /** Constant for Nokia S60 platform
static String PLATFORM_PALM
          Constant for plam platform
static String PLATFORM_PPC
          Constant for pocket pc platform
static String PLATFORM_SOLARIS
          Constant for solaris platform
static String PLATFORM_UNKNOWN
          Constant for unknown platform
static String PLATFORM_VERSION_UNKNOWN
          Constant for unknown platform version
static String PLATFORM_WINDOWS
          Constant for windows platform
static Object TYPE_DESKTOP
          Constant for desktop devices
static Object TYPE_PDA
          Constant for handheld sized devices (Pocket-PC, Palm)
static Object TYPE_PHONE
          Constant for Phone sized devices
static Object TYPE_TELNET
          Constant for telnet device type
static Object TYPE_UNKNOWN
          Constant for Unknown device type
static Object TYPE_WEBCRAWLER
          Constant for Web Crawlers
 
Method Summary
 String getAgentName()
           
 String getAgentVersion()
           
 Map<Object,Object> getCapabilities()
           
 String getHardwareMakeModel()
           
 String getPlatformName()
           
 String getPlatformVersion()
           
 Object getType()
           
 

Field Detail

TYPE_UNKNOWN

static final Object TYPE_UNKNOWN
Constant for Unknown device type


TYPE_TELNET

static final Object TYPE_TELNET
Constant for telnet device type


TYPE_DESKTOP

static final Object TYPE_DESKTOP
Constant for desktop devices


TYPE_PDA

static final Object TYPE_PDA
Constant for handheld sized devices (Pocket-PC, Palm)


TYPE_PHONE

static final Object TYPE_PHONE
Constant for Phone sized devices


TYPE_WEBCRAWLER

static final Object TYPE_WEBCRAWLER
Constant for Web Crawlers


PLATFORM_UNKNOWN

static final String PLATFORM_UNKNOWN
Constant for unknown platform

See Also:
Constant Field Values

PLATFORM_WINDOWS

static final String PLATFORM_WINDOWS
Constant for windows platform

See Also:
Constant Field Values

PLATFORM_LINUX

static final String PLATFORM_LINUX
Constant for linux platform

See Also:
Constant Field Values

PLATFORM_MACOS

static final String PLATFORM_MACOS
Constant for MacOS platform

See Also:
Constant Field Values

PLATFORM_MAC

@Deprecated
static final String PLATFORM_MAC
Deprecated. 
Constant for Mac platform

See Also:
Constant Field Values

PLATFORM_IPHONE

static final String PLATFORM_IPHONE
Constant for the iOS (iPhone/iPod touch/iPad) platform

See Also:
Constant Field Values

PLATFORM_PALM

static final String PLATFORM_PALM
Constant for plam platform

See Also:
Constant Field Values

PLATFORM_SOLARIS

static final String PLATFORM_SOLARIS
Constant for solaris platform

See Also:
Constant Field Values

PLATFORM_PPC

static final String PLATFORM_PPC
Constant for pocket pc platform

See Also:
Constant Field Values

PLATFORM_BLACKBERRY

static final String PLATFORM_BLACKBERRY
Constant for blackberry platform

See Also:
Constant Field Values

PLATFORM_NOKIA_S60

static final String PLATFORM_NOKIA_S60
/** Constant for Nokia S60 platform

See Also:
Constant Field Values

PLATFORM_GENERICPDA

static final String PLATFORM_GENERICPDA
Constant for generic PDA device browser

See Also:
Constant Field Values

PLATFORM_ANDROID

static final String PLATFORM_ANDROID
Constant for android device browsers

See Also:
Constant Field Values

PLATFORM_VERSION_UNKNOWN

static final String PLATFORM_VERSION_UNKNOWN
Constant for unknown platform version

See Also:
Constant Field Values

AGENT_UNKNOWN

static final String AGENT_UNKNOWN
Constant for when the agent is not supported or not recognized

See Also:
Constant Field Values

AGENT_KONQUEROR

static final String AGENT_KONQUEROR
Constant for Konqueror agent

See Also:
Constant Field Values

AGENT_IE

static final String AGENT_IE
Constant for Internet Explorer agent

See Also:
Constant Field Values

AGENT_GECKO

static final String AGENT_GECKO
Constant for Gecko agent. Used for all Gecko based agents like Mozilla, Netscape 6+

See Also:
Constant Field Values

AGENT_GENERIC_DESKTOP

static final String AGENT_GENERIC_DESKTOP
Constant for a generic desktop agent that is unknown but relatively powerful

See Also:
Constant Field Values

AGENT_OPERA

static final String AGENT_OPERA
Constant for Opera agent.

See Also:
Constant Field Values

AGENT_EMAIL

static final String AGENT_EMAIL
Constant for email agent. Used for all email agents like Outlook 2007 and Thunderbird

See Also:
Constant Field Values

AGENT_WEBKIT

static final String AGENT_WEBKIT
Constant for Apple Webkit agent. Used for all Webkit based agent like Safari

See Also:
Constant Field Values

AGENT_BLACKBERRY

static final String AGENT_BLACKBERRY
Constant for BlackBerry Browser agent. (Note the distinction from the BlackBerry platform. The BlackBerry Browser agent runs on the BlackBerry platform. It is possible for other agents to run on the BlackBerry platform.)

See Also:
Constant Field Values

AGENT_NOKIA_S60

static final String AGENT_NOKIA_S60
Constant for Symbian Nokia S60 agent. Used for Nokia Series 60 3rd Edition or later

See Also:
Constant Field Values

AGENT_GENERICPDA

static final String AGENT_GENERICPDA
Constant for basic HTML (without JavaScript) Browser agent.

See Also:
Constant Field Values

AGENT_MSNBOT

static final String AGENT_MSNBOT
Constant for MSN web crawler (currently used by Bing and Yahoo)

See Also:
Constant Field Values

AGENT_GOOGLEBOT

static final String AGENT_GOOGLEBOT
Constant for Google web crawler

See Also:
Constant Field Values

AGENT_ORACLE_SES

static final String AGENT_ORACLE_SES
Constant for Oracle SES web crawler

See Also:
Constant Field Values

AGENT_VERSION_UNKNOWN

static final String AGENT_VERSION_UNKNOWN
Constant for unknown Agent version

See Also:
Constant Field Values

MAKE_MODEL_UNKNOWN

static final String MAKE_MODEL_UNKNOWN
Constant for unknown make model version

See Also:
Constant Field Values
Method Detail

getType

Object getType()
Returns:
return the Type of Agent. Returns TYPE_UNKNOWN if not available.
E.g. desktop, pda, phone

getAgentName

String getAgentName()
Returns:
return the canonical name of the agent (browser application). Returns null if not available.
E.g. gecko, ie, opera, pocketie

getAgentVersion

String getAgentVersion()
Returns:
return the version number of the agent (browser application). Return null if not available.

getPlatformName

String getPlatformName()
Returns:
return the canonical name for the platform. Returns null if not available.
E.g ppc, series60, windows, mac, linux, solaris

getPlatformVersion

String getPlatformVersion()
Returns:
return the version number for the platform. Returns null if not available.

getHardwareMakeModel

String getHardwareMakeModel()
Returns:
return a canonical name for the Hardware make and Model. Re turns null if not available.
E.g nokia6600, sonyericssonP900, nokai3650i

getCapabilities

Map<Object,Object> getCapabilities()
Returns:
Map of capability names and their values for the current client request.
Some of the available capability names are:
height- provides the screen height in pixels of the Agent as an Integer.
width- provides the screen width in pixels of the Agent as an Integer.
dom- provides the DOM API support of the agent as a String. Possible values are: level2, level1, form, and none.
frames- returns a Boolean value signifying whether or not the Agent supports frames.
accessKeys- returns a Boolean value signifying whether or not the Agent supports accessKeys.


Copyright © 2001-2012 The Apache Software Foundation. All Rights Reserved.