ie.omk.smpp.message
Class QueryMsgDetailsResp

java.lang.Object
  extended by ie.omk.smpp.message.SMPPPacket
      extended by ie.omk.smpp.message.SMPPResponse
          extended by ie.omk.smpp.message.QueryMsgDetailsResp

public class QueryMsgDetailsResp
extends SMPPResponse

Response to Query message details. Gives all details of a specified message at the SMSC. Relevant inherited fields from SMPPPacket:

Version:
1.0
Author:
Oran Kelly

Field Summary
 
Fields inherited from class ie.omk.smpp.message.SMPPPacket
ALERT_NOTIFICATION, BIND_RECEIVER, BIND_RECEIVER_RESP, BIND_TRANSCEIVER, BIND_TRANSCEIVER_RESP, BIND_TRANSMITTER, BIND_TRANSMITTER_RESP, CANCEL_SM, CANCEL_SM_RESP, commandId, commandStatus, DATA_SM, DATA_SM_RESP, dataCoding, defaultMsg, DELIVER_SM, DELIVER_SM_RESP, deliveryTime, destination, ENQUIRE_LINK, ENQUIRE_LINK_RESP, errorCode, esmClass, ESME_ROK, expiryTime, finalDate, GENERIC_NACK, message, messageId, messageStatus, OUTBIND, PARAM_RETRIEVE, PARAM_RETRIEVE_RESP, priority, protocolID, QUERY_LAST_MSGS, QUERY_LAST_MSGS_RESP, QUERY_MSG_DETAILS, QUERY_MSG_DETAILS_RESP, QUERY_SM, QUERY_SM_RESP, registered, REPLACE_SM, REPLACE_SM_RESP, replaceIfPresent, sequenceNum, serviceType, SM_STATE_ACCEPTED, SM_STATE_DELETED, SM_STATE_DELIVERED, SM_STATE_EN_ROUTE, SM_STATE_EXPIRED, SM_STATE_INVALID, SM_STATE_UNDELIVERABLE, SMC_CAS_DL, SMC_DEFMSG, SMC_DLIST, SMC_ESCALATED, SMC_LOOPBACK_RECEIPT, SMC_MCE, SMC_MO, SMC_MOMT, SMC_MT, SMC_MULTI, SMC_RECEIPT, SMC_RECEIPT_SWAP, SMC_STORE, SMC_STORE_FORWARD, SMC_SUBMIT_REPLACE, source, SUBMIT_MULTI, SUBMIT_MULTI_RESP, SUBMIT_SM, SUBMIT_SM_RESP, tlvTable, UNBIND, UNBIND_RESP, version
 
Constructor Summary
QueryMsgDetailsResp()
          Construct a new QueryMsgDetailsResp.
QueryMsgDetailsResp(int seqNum)
          Deprecated.  
QueryMsgDetailsResp(QueryMsgDetails r)
          Create a new QueryMsgDetailsResp packet in response to a BindReceiver.
 
Method Summary
 int addDestination(Address d)
          Add an address to the destination table.
 int addDestination(String d)
          Add a distribution list to the destination table.
protected  void encodeBody(OutputStream out)
          Write a byte representation of this packet to an OutputStream
 int getBodyLength()
          Get the number of bytes the body of this packet would encode as.
 DestinationTable getDestinationTable()
          Get a handle to the destination table.
 int getNoOfDests()
          Deprecated. Use getNumDests.
 int getNumDests()
          Get the current number of destination addresses.
 void readBodyFrom(byte[] body, int offset)
          Read this packet's mandatory parameters from a byte array.
 String toString()
          Convert this packet to a String.
 
Methods inherited from class ie.omk.smpp.message.SMPPResponse
setCommandStatus
 
Methods inherited from class ie.omk.smpp.message.SMPPPacket
getCommandId, getCommandLen, getCommandStatus, getDataCoding, getDefaultMsg, getDefaultMsgId, getDeliveryTime, getDestination, getErrorCode, getEsmClass, getExpiryTime, getFinalDate, getLength, getMessage, getMessageEncoding, getMessageId, getMessageLen, getMessageStatus, getMessageText, getMessageText, getOptionalParameter, getPriority, getProtocolId, getProtocolID, getRegistered, getReplaceIfPresent, getSequenceNum, getServiceType, getSource, getTLVTable, getVersion, isPriority, isRegistered, isReplaceIfPresent, isRequest, isSet, readFrom, setAlphabet, setAlphabet, setDataCoding, setDefaultMsg, setDeliveryTime, setDeliveryTime, setDestination, setErrorCode, setEsmClass, setExpiryTime, setExpiryTime, setFinalDate, setFinalDate, setMessage, setMessage, setMessage, setMessageEncoding, setMessageId, setMessageStatus, setMessageText, setMessageText, setOptionalParameter, setPriority, setProtocolId, setProtocolID, setRegistered, setRegistered, setReplaceIfPresent, setReplaceIfPresent, setSequenceNum, setServiceType, setSource, setTLVTable, setVersion, writeTo, writeTo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

QueryMsgDetailsResp

public QueryMsgDetailsResp()
Construct a new QueryMsgDetailsResp.


QueryMsgDetailsResp

public QueryMsgDetailsResp(int seqNum)
Deprecated. 

Construct a new QueryMsgDetailsResp with specified sequence number.

Parameters:
seqNum - The sequence number to use

QueryMsgDetailsResp

public QueryMsgDetailsResp(QueryMsgDetails r)
Create a new QueryMsgDetailsResp packet in response to a BindReceiver. This constructor will set the sequence number to it's expected value.

Parameters:
r - The Request packet the response is to
Method Detail

addDestination

public int addDestination(Address d)
Add an address to the destination table.

Parameters:
d - The SME destination address
Returns:
The current number of destination addresses (including the new one).
See Also:
Address

addDestination

public int addDestination(String d)
                   throws InvalidParameterValueException
Add a distribution list to the destination table.

Parameters:
d - the distribution list name.
Returns:
The current number of destination addresses (including the new
Throws:
InvalidParameterValueException - if the distribution list name is too long.

getNoOfDests

public int getNoOfDests()
Deprecated. Use getNumDests.

Get the current number of destination addresses.


getNumDests

public int getNumDests()
Get the current number of destination addresses.


getDestinationTable

public DestinationTable getDestinationTable()
Get a handle to the destination table.


getBodyLength

public int getBodyLength()
Description copied from class: SMPPPacket
Get the number of bytes the body of this packet would encode as. This method should only return the number of bytes the fields in the mandatory parameters section of the packet would encode as. The total size of the packet then is 16 (header length) + getBodyLength() + SUM(foreach optionalParameter: getLength()).

Specified by:
getBodyLength in class SMPPPacket

encodeBody

protected void encodeBody(OutputStream out)
                   throws IOException
Write a byte representation of this packet to an OutputStream

Overrides:
encodeBody in class SMPPPacket
Parameters:
out - The OutputStream to write to
Throws:
IOException - if there's an error writing to the output stream.

readBodyFrom

public void readBodyFrom(byte[] body,
                         int offset)
                  throws SMPPProtocolException
Description copied from class: SMPPPacket
Read this packet's mandatory parameters from a byte array.

Specified by:
readBodyFrom in class SMPPPacket
Parameters:
body - the byte array to read the mandatory parameters from.
offset - the offset into b that the mandatory parameter's begin at.
Throws:
SMPPProtocolException - if there is an error parsing the packet fields.

toString

public String toString()
Convert this packet to a String. Not to be interpreted programmatically, it's just dead handy for debugging!

Overrides:
toString in class SMPPPacket


Copyright © 2011 smppapi at Sourceforge. All Rights Reserved.