oracle.panama.messaging.transport
Interface XDriver
- All Superinterfaces:
- DriverBase
- public interface XDriver
- extends DriverBase
The extended driver interface. Driver is used by Messenger to access devices. More devices can be supported by the transport system via plug in more drivers. The extended driver interface makes it easier to customize the message for individual recipient. It also makes it possible for messaging server to suspend a driver in case of any problem.
- See Also:
Driver
getDriverStatus
public int getDriverStatus()
- Check if a driver is still able to send/receive. The driver instance should check the network connection to the gateway, the status of the gateway and so on. The driver instance can re-initialize itself if necessary.
-
- Returns:
- a status code similar to method init().
send
public Report[] send(Address[] addrs,
Profile prof,
Message message)
throws DriverException
- Send a message to a list of addresses with this driver.
-
- Parameters:
addrs
- the destination addresses.
prof
- the sending request profile.
message
- the message to send.
- Returns:
- a list of sending reports.
- Throws:
DriverException.
DriverException
send
public Report send(Address addr,
Profile prof,
Message message)
throws DriverException
- Send a message to a single address with this driver. Drivers implement this method to perform whatever is appropriate for their particular protocols to send out messages. The content to delivery is stored in the Message object passed onto the send() method, while the address parameter specifies one or more recipients to deliver the message to. Further, the driver is expected to return a unique id for each recipient, or ids one for each of the recipients. These ids will be used by the transport to query status of the delivery when necessary. The unique message id passed to the driver can be used as the base to generate the messaged id for the recipient.
-
- Parameters:
addr
- the destination address.
prof
- the sending request profile.
message
- the message to send.
- Returns:
- a sending report object.
- Throws:
DriverException.
DriverException
Copyright © 2004 Oracle Corporation. All Rights Reserved.