|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sourceforge.wurfl.core.DefaultDevice
public class DefaultDevice
This is a default Device implementation.
It uses a CapabilitiesHolder to retrieve capabilities values and MarkupResolver to resolve MarkUp.
| Constructor Summary | |
|---|---|
protected |
DefaultDevice(ModelDevice modelDevice,
String deviceRootId,
CapabilitiesHolder capabilitiesHolder,
MarkupResolver markupResolver)
|
protected |
DefaultDevice(ModelDevice modelDevice,
String deviceRootId,
CapabilitiesHolder capabilitiesHolder,
MarkupResolver markupResolver,
DeviceInfo info)
Build a Device. |
| Method Summary | |
|---|---|
boolean |
equals(Object obj)
It assumes two DefaultDevices with equals root ModelDevices are equals. |
Map<String,String> |
getCapabilities()
Returns a device's capabilities values by name Map. |
String |
getCapability(String name)
Return a device's capability value. |
String |
getDeviceRootId()
|
String |
getId()
Return the WURFL id of this device |
MarkUp |
getMarkUp()
Get the markUp handled by this device. |
String |
getMatcherName()
|
MatchType |
getMatchType()
|
String |
getUserAgent()
Return the user-agent string for this device as defined in WURFL. |
int |
hashCode()
|
boolean |
isActualDeviceRoot()
|
boolean |
isGeneric()
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
protected DefaultDevice(ModelDevice modelDevice,
String deviceRootId,
CapabilitiesHolder capabilitiesHolder,
MarkupResolver markupResolver)
protected DefaultDevice(ModelDevice modelDevice,
String deviceRootId,
CapabilitiesHolder capabilitiesHolder,
MarkupResolver markupResolver,
DeviceInfo info)
modelDevice - The ModelDevice instance modelDevice of this Device.deviceRootId - Ancestor idcapabilitiesHolder - The CapabilitiesHolder used to get capabilities values.markupResolver - The MarkupResolver used to obtain MarkUp for this Device.| Method Detail |
|---|
public String getId()
getId in interface Devicepublic String getUserAgent()
getUserAgent in interface Device
public String getCapability(String name)
throws CapabilityNotDefinedException
getCapability in interface Devicename - The identifier of capability to get.
CapabilityNotDefinedException - If this device do not define the given capability.public Map<String,String> getCapabilities()
getCapabilities in interface Devicepublic MarkUp getMarkUp()
getMarkUp in interface Devicepublic boolean isActualDeviceRoot()
isActualDeviceRoot in interface Devicepublic String getDeviceRootId()
getDeviceRootId in interface Devicepublic boolean isGeneric()
isGeneric in interface Devicepublic MatchType getMatchType()
getMatchType in interface Devicepublic String getMatcherName()
public boolean equals(Object obj)
equals in class Objectpublic int hashCode()
hashCode in class Objectpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||