net.rim.device.api.io
Interface IOProperties

All Known Implementing Classes:
DatagramBase, DatagramConnectionBase

public interface IOProperties

Defines an interface for manipulating properties and flags.

Since:
BlackBerry API 4.0.0

Field Summary
static int CDMA_SET_FAST_DORMANCY_FLAG
          Set fast dormancy (CDMA-specific).
static int FLAG_INVALID
          Flag is invalid.
static int FLAG_SET
          Flag is set.
static int FLAG_UNSET
          Flag is unset.
static int GME_ADD_SRC_FIELD_FLAG
          Add the GME source field to outgoing packets (GME-specific).
static int GME_DELAYED_ACK_FLAG
          Indicates whether any acknowledgements for this datagram are in a delayed state pending "processing" of the datagram (GME-specific).
static int GME_FAIL_ON_MISSING_ROUTING_INFO_FLAG
          Indicates that GME should fail when fetchable routing information is not present, instead of waiting for that information to be acquired (GME-specific).
static int GME_REQUEST_CONFIRMATION_FLAG
          Request a delivery confirmation to be sent (GME-specific).
static int MDP_DATAGRAM_ACK_FLAG
          Request a datagram acknowledgement (MDP-specific).
static int MDP_DONT_SET_FAST_DORMANCY_FLAG
          Don't set fast dormancy (CDMA/MDP-specific).
static int MDP_PACKET_ACK_FLAG
          Request a packet acknowledgement (MDP-specific).
static int MOBITEX_MAILBOX_FLAG
          Use mailbox (Mobitex-specific).
static int MOBITEX_REQUEST_ACK_FLAG
          Requests an acknowledgement (Mobitex-specific).
static int UDP_RETRY_ON_NO_CONTEXT
          Indicates whether a "no context" transmission error is treated as non-critical (UDP-specific).
 
Method Summary
 int getFlag(int flag)
          Retrieves the value for the indicated flag.
 Object getProperty(String property)
          Retrieves a property by name.
 boolean isFlagSet(int flag)
          Determines if flag is set.
 void setFlag(int flag, boolean b)
          Sets state of provided flag.
 Object setProperty(String property, Object data)
          Associates a property with the datagram.
 



Field Detail

FLAG_INVALID

static final int FLAG_INVALID
Flag is invalid.

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

FLAG_UNSET

static final int FLAG_UNSET
Flag is unset.

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

FLAG_SET

static final int FLAG_SET
Flag is set.

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

MOBITEX_MAILBOX_FLAG

static final int MOBITEX_MAILBOX_FLAG
Use mailbox (Mobitex-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

MOBITEX_REQUEST_ACK_FLAG

static final int MOBITEX_REQUEST_ACK_FLAG
Requests an acknowledgement (Mobitex-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

CDMA_SET_FAST_DORMANCY_FLAG

static final int CDMA_SET_FAST_DORMANCY_FLAG
Set fast dormancy (CDMA-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

UDP_RETRY_ON_NO_CONTEXT

static final int UDP_RETRY_ON_NO_CONTEXT
Indicates whether a "no context" transmission error is treated as non-critical (UDP-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

MDP_DATAGRAM_ACK_FLAG

static final int MDP_DATAGRAM_ACK_FLAG
Request a datagram acknowledgement (MDP-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

MDP_PACKET_ACK_FLAG

static final int MDP_PACKET_ACK_FLAG
Request a packet acknowledgement (MDP-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

MDP_DONT_SET_FAST_DORMANCY_FLAG

static final int MDP_DONT_SET_FAST_DORMANCY_FLAG
Don't set fast dormancy (CDMA/MDP-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.1.0

GME_REQUEST_CONFIRMATION_FLAG

static final int GME_REQUEST_CONFIRMATION_FLAG
Request a delivery confirmation to be sent (GME-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

GME_ADD_SRC_FIELD_FLAG

static final int GME_ADD_SRC_FIELD_FLAG
Add the GME source field to outgoing packets (GME-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

GME_FAIL_ON_MISSING_ROUTING_INFO_FLAG

static final int GME_FAIL_ON_MISSING_ROUTING_INFO_FLAG
Indicates that GME should fail when fetchable routing information is not present, instead of waiting for that information to be acquired (GME-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0

GME_DELAYED_ACK_FLAG

static final int GME_DELAYED_ACK_FLAG
Indicates whether any acknowledgements for this datagram are in a delayed state pending "processing" of the datagram (GME-specific).

See Also:
Constant Field Values
Since:
BlackBerry API 4.0.0


Method Detail

setProperty

Object setProperty(String property,
                   Object data)
Associates a property with the datagram.

Parameters:
property - Name of the property.
data - Data associated with the named property; if null, the named property is removed if it already exists.
Returns:
The previous data associated with the named property, or null if its been newly created or removed.
Since:
BlackBerry API 4.0.0

getProperty

Object getProperty(String property)
Retrieves a property by name.

Parameters:
name - Name of the property to retrieve
Returns:
Property object.
Since:
BlackBerry API 4.0.0

setFlag

void setFlag(int flag,
             boolean b)
Sets state of provided flag.

Parameters:
flag - Flag to set.
b - True if the flag should be set, false if the flag should be cleared.
Since:
BlackBerry API 4.0.0

getFlag

int getFlag(int flag)
Retrieves the value for the indicated flag.

Parameters:
flag - Flag to check.
Returns:
IOProperties.FLAG_SET if the flag is set, IOProperties.FLAG_UNSET if it is unset or IOProperties.FLAG_INVALID if the flag's state never set with IOProperties.setFlag(int, boolean).
Since:
BlackBerry API 4.0.0

isFlagSet

boolean isFlagSet(int flag)
Determines if flag is set.

Returns:
True if (and only if) flag is set; otherwise, false.
Since:
BlackBerry API 4.0.0





Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal