|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.norther.tammi.spray.filter.chain.AbstractExtension org.norther.tammi.spray.terminal.chain.TerminalRequest.TerminalRequestExtension
protected static class TerminalRequest.TerminalRequestExtension
The terminal extension class being static to safely save in sessions.
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 |
getDefaultCharactedEncoding()
Gets the default character extension of the MIME type 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. |
MimeType |
getPreferredContentType()
Gets the preferred MIME type of the terminal. |
Profile |
getProfile()
Gets the profile. |
String |
getTerminalId()
Gets the terminal id from the HTTP request headers. |
Locale |
getTerminalLocale()
Gets the current locale with terminal specific variants. |
Locale |
getTerminalLocale(Locale locale)
Gets the specified locale with terminal specific variants. |
String |
getUserAgentVariant()
Gets the user agent variant. |
protected void |
setSuggestedContentType(MimeType mime)
Sets the suggested MIME type of the terminal. |
void |
setTerminalLocale(Locale locale)
Sets the current locale with terminal specific variants. |
void |
valueBound(ServletRequestBindingEvent event)
Notifies the object that it is being bound to a request. |
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 |
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 Profile getProfile()
TerminalExtension
getProfile
in interface TerminalExtension
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 TerminalExtension
public String getMobileStationIsdn()
TerminalExtension
getMobileStationIsdn
in interface TerminalExtension
public MimeType getPreferredContentType()
TerminalExtension
getPreferredContentType
in interface TerminalExtension
public String getDefaultCharactedEncoding()
TerminalExtension
getDefaultCharactedEncoding
in interface TerminalExtension
public String getDefaultExtension()
TerminalExtension
getDefaultExtension
in interface TerminalExtension
public String getUserAgentVariant()
TerminalExtension
getUserAgentVariant
in interface TerminalExtension
public Locale getTerminalLocale()
TerminalExtension
getTerminalLocale
in interface TerminalExtension
public void setTerminalLocale(Locale locale)
TerminalExtension
setTerminalLocale
in interface TerminalExtension
locale
- the terminal specific locale.public Locale getTerminalLocale(Locale locale)
TerminalExtension
getTerminalLocale
in interface TerminalExtension
locale
- the locale to customize.
public void valueBound(ServletRequestBindingEvent event)
ServletRequestBindingListener
valueBound
in interface ServletRequestBindingListener
valueBound
in class AbstractExtension
event
- the binding event.public void valueUnbound(ServletRequestBindingEvent event)
ServletRequestBindingListener
valueUnbound
in interface ServletRequestBindingListener
valueUnbound
in class AbstractExtension
event
- the binding event.protected void setSuggestedContentType(MimeType mime)
mime
- the MIME type.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |