|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.free2be.dimensions.device.DeviceFactory com.free2be.dimensions.device.SessionDeviceFactory
public class SessionDeviceFactory
Simply used to check for persistant devices in the session that have already been built.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class com.free2be.dimensions.device.DeviceFactory |
---|
DeviceFactory.ConfidenceLevel |
Field Summary | |
---|---|
static java.lang.String |
DEVICE_KEY
A constant referring to the key which the channel is stored in the session. |
Fields inherited from class com.free2be.dimensions.device.DeviceFactory |
---|
CONTENT, DEFAULT, DEVICE, MINIMUM_LEVEL_FOR_FINAL, MODEL, NONE, OVERRIDE, PRE_DETERMINED, STANDARD |
Constructor Summary | |
---|---|
SessionDeviceFactory()
|
Method Summary | |
---|---|
protected void |
assignDevice(Device device,
java.lang.Object informationSource)
|
void |
clearDevice(java.lang.Object informationSource)
Remove the device from the session. |
DeviceFactory.ConfidenceLevel |
getConfidenceLevel()
Retrieves the confidence level this factory has in fulfilling the request based on the information provided during intialization. |
Device |
getDevice()
Retrieves a device to represent the calling client's device. |
DeviceFactory.ConfidenceLevel |
getHighestConfidenceLevel()
Returns the highest confidence level the implementing device factory can provide. |
protected void |
initialize(java.lang.Object informationSource)
initalizes a factory after default construction giving some object as the source of information to determine confidence and build devices. |
void |
notifyOfBestDevice(Device bestDevice,
java.lang.Object informationSource)
Used to notify any persistent device factories of the best device chosen. |
Methods inherited from class com.free2be.dimensions.device.DeviceFactory |
---|
clearPersistantDevice, getDeviceFactory, getFactories, getPersistentFactories |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String DEVICE_KEY
Constructor Detail |
---|
public SessionDeviceFactory()
Method Detail |
---|
public Device getDevice()
getDevice
in class DeviceFactory
public DeviceFactory.ConfidenceLevel getConfidenceLevel()
getConfidenceLevel
in class DeviceFactory
public DeviceFactory.ConfidenceLevel getHighestConfidenceLevel()
getHighestConfidenceLevel
in class DeviceFactory
protected void initialize(java.lang.Object informationSource)
initialize
in class DeviceFactory
informationSource
- any object that a factory may use to determine device (usually javax.servlet.HttpServletRequest).public void notifyOfBestDevice(Device bestDevice, java.lang.Object informationSource)
PersistentDeviceFactory
notifyOfBestDevice
in interface PersistentDeviceFactory
public void clearDevice(java.lang.Object informationSource)
clearDevice
in interface PersistentDeviceFactory
protected void assignDevice(Device device, java.lang.Object informationSource)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |