net.sourceforge.wurfl.core
Interface Device

All Known Implementing Classes:
DefaultDevice

public interface Device

This is interface represent a device connected to the WURFL application.

It enable the user to obtain the capability of the actual device and other useful info. It hides the WURFL repository structure to the other API parts.

Version:
$Id: Device.java 432 2010-05-06 12:12:53Z filippo.deluca $
Author:
Fantayeneh Asres Gizaw, Filippo De Luca

Method Summary
 Map getCapabilities()
          Returns a device's capabilities values by name Map.
 String getCapability(String name)
          Return a device's capability value.
 String getId()
          Return the WURFL id of this device
 MarkUp getMarkUp()
          Get the markUp handled by this device.
 String getUserAgent()
          Return the user-agent string for this device as defined in WURFL.
 

Method Detail

getId

String getId()
Return the WURFL id of this device

Returns:
A string representing this device identifier.

getUserAgent

String getUserAgent()
Return the user-agent string for this device as defined in WURFL.

Returns:
A String containing the defined user-agent.

getCapability

String getCapability(String name)
                     throws CapabilityNotDefinedException
Return a device's capability value.

Parameters:
name - The identifier of capability to get.
Returns:
The value of capability.
Throws:
CapabilityNotDefinedException - If this device do not define the given capability.

getCapabilities

Map getCapabilities()
Returns a device's capabilities values by name Map.

Returns:
Map containing couples name-value of device's capabilities.

getMarkUp

MarkUp getMarkUp()
Get the markUp handled by this device.

Returns:
A MarkUp instance this device can handle.


Copyright © 2008-2010 WURFL-Pro srl. All Rights Reserved.