|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.norther.tammi.spray.filter.chain.AbstractExtension
org.norther.tammi.spray.terminal.chain.TerminalRequest.TerminalRequestExtension
protected static class TerminalRequest.TerminalRequestExtension
The terminal extension class.
| Field Summary |
|---|
| Fields inherited from interface org.norther.tammi.spray.terminal.chain.TerminalExtension |
|---|
KEY |
| Constructor Summary | |
|---|---|
TerminalRequest.TerminalRequestExtension()
Constructs a new extension. |
|
| Method Summary | |
|---|---|
String |
getContentType()
Gets the preferred MIME type of the terminal. |
String |
getContentTypeVariant()
Gets the content type variant of the terminal. |
String |
getDefaultExtension()
Gets the default file extension of the MIME type of the terminal. |
String |
getMobileStationIsdn()
Gets the MSISDN (phone number) of the terminal. |
String |
getTerminalId()
Gets the terminal id from the HTTP request headers. |
Locale |
getTerminalLocale()
Gets the current locale with the terminal specific variants. |
Locale |
getTerminalLocale(Locale locale)
Gets the specified locale with the terminal specific variants. |
String |
getUserAgentVariant()
Gets the user agent variant of the terminal. |
void |
setContentTypeVariant(String variant)
Sets the content type variant of the terminal. |
void |
setUserAgentVariant(String variant)
Sets the user agent variant of the terminal. |
void |
valueUnbound(ServletRequestBindingEvent event)
Notifies the object that it is being unbound from a request. |
| Methods inherited from class org.norther.tammi.spray.filter.chain.AbstractExtension |
|---|
getFilterChain, getFilteredRequest, getFilteredResponse, isBound, valueBound |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public TerminalRequest.TerminalRequestExtension()
| Method Detail |
|---|
public String getTerminalId()
In WML, different gateways put the terminal id information in different places. See e.g.:
Phone.com's identification. There is a variety of ways to identify the handset, e.g.:
The unique id that is sent via the x-uplink-subno header is unrelated to the original method of identification. The id may be e.g. "959911264-777_wapd.mobilenet.telstra.net". The right half of the string (separated e.g. by underscore) is the DNS name of the gateway host. The left half is sometimes phone number.
IP addresses in identification: E.g. x-network-info and x-up-subno may contain or be based on IP address. The IP address environment in often dynamic. In this case the addresses can't much be relied on. The address may change between different connection from the same terminal.
MSISDN in identification: MSISDN is sensitive information and is often not passed out of the operator's domain.
getTerminalId in interface TerminalExtensionpublic String getMobileStationIsdn()
TerminalExtension
getMobileStationIsdn in interface TerminalExtensionpublic String getContentType()
TerminalExtension
getContentType in interface TerminalExtensionpublic String getDefaultExtension()
TerminalExtension
getDefaultExtension in interface TerminalExtensionpublic String getUserAgentVariant()
TerminalExtension
getUserAgentVariant in interface TerminalExtensionpublic void setUserAgentVariant(String variant)
TerminalExtensionThe variant is a token matching request specific user agent information unless explicitly specified.
setUserAgentVariant in interface TerminalExtensionvariant - the user agent variant.public String getContentTypeVariant()
TerminalExtension
getContentTypeVariant in interface TerminalExtensionpublic void setContentTypeVariant(String variant)
TerminalExtensionThe variant is a token matching the subtype of the MIME type of the terminal unless explicitly specified.
setContentTypeVariant in interface TerminalExtensionvariant - the content type variant (HTML, WML, SMS, ...).public Locale getTerminalLocale()
TerminalExtension
getTerminalLocale in interface TerminalExtensionpublic Locale getTerminalLocale(Locale locale)
TerminalExtension
getTerminalLocale in interface TerminalExtensionlocale - the locale to adjust.
public void valueUnbound(ServletRequestBindingEvent event)
ServletRequestBindingListener
valueUnbound in interface ServletRequestBindingListenervalueUnbound in class AbstractExtensionevent - the binding event.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||