public static final int MESSAGE_TYPE_DELIVER_REPORT = 0x07;
public static final int MESSAGE_TYPE_SUBMIT_REPORT = 0x08;
- public byte messageType;
+ public int messageType;
/**
* 16-bit value indicating the message ID, which increments modulo 65536.
public static final int PRIORITY_EMERGENCY = 0x3;
public boolean priorityIndicatorSet = false;
- public byte priority = PRIORITY_NORMAL;
+ public int priority = PRIORITY_NORMAL;
/**
* Supported privacy modes for CDMA SMS messages
public static final int PRIVACY_SECRET = 0x3;
public boolean privacyIndicatorSet = false;
- public byte privacy = PRIVACY_NOT_RESTRICTED;
+ public int privacy = PRIVACY_NOT_RESTRICTED;
/**
* Supported alert priority modes for CDMA SMS messages
public static final int DISPLAY_MODE_USER = 0x2;
public boolean displayModeSet = false;
- public byte displayMode = DISPLAY_MODE_DEFAULT;
+ public int displayMode = DISPLAY_MODE_DEFAULT;
/**
* Language Indicator values. NOTE: the spec (3GPP2 C.S0015-B,
if (inStream.read(8) != 3) {
throw new CodingException("MESSAGE_IDENTIFIER subparam size incorrect");
}
- bData.messageType = (byte)inStream.read(4);
+ bData.messageType = inStream.read(4);
bData.messageId = inStream.read(8) << 8;
bData.messageId |= inStream.read(8);
bData.hasUserDataHeader = (inStream.read(1) == 1);
{
int paramBytes = inStream.read(8);
CdmaSmsAddress addr = new CdmaSmsAddress();
- addr.digitMode = (byte)inStream.read(1);
+ addr.digitMode = inStream.read(1);
byte fieldBits = 4;
byte consumedBits = 1;
if (addr.digitMode == CdmaSmsAddress.DIGIT_MODE_8BIT_CHAR) {
addr.ton = inStream.read(3);
- addr.numberPlan = (byte)inStream.read(4);
+ addr.numberPlan = inStream.read(4);
fieldBits = 8;
consumedBits += 7;
}
- addr.numberOfDigits = (byte)inStream.read(8);
+ addr.numberOfDigits = inStream.read(8);
consumedBits += 8;
int remainingBits = (paramBytes * 8) - consumedBits;
int dataBits = addr.numberOfDigits * fieldBits;
if (inStream.read(8) != 1) {
throw new CodingException("PRIVACY_INDICATOR subparam size incorrect");
}
- bData.privacy = (byte)inStream.read(2);
+ bData.privacy = inStream.read(2);
inStream.skip(6);
bData.privacyIndicatorSet = true;
}
if (inStream.read(8) != 1) {
throw new CodingException("DISPLAY_MODE subparam size incorrect");
}
- bData.displayMode = (byte)inStream.read(2);
+ bData.displayMode = inStream.read(2);
inStream.skip(6);
bData.displayModeSet = true;
}
if (inStream.read(8) != 1) {
throw new CodingException("PRIORITY_INDICATOR subparam size incorrect");
}
- bData.priority = (byte)inStream.read(2);
+ bData.priority = inStream.read(2);
inStream.skip(6);
bData.priorityIndicatorSet = true;
}
static public final int DIGIT_MODE_4BIT_DTMF = 0x00;
static public final int DIGIT_MODE_8BIT_CHAR = 0x01;
- public byte digitMode;
+ public int digitMode;
/**
* Number Mode Indicator is 1-bit value that indicates whether the
static public final int NUMBER_MODE_NOT_DATA_NETWORK = 0x00;
static public final int NUMBER_MODE_DATA_NETWORK = 0x01;
- public byte numberMode;
+ public int numberMode;
/**
* Number Types for data networks.
* This field shall be set to the number of address digits
* (See 3GPP2 C.S0015-B, v2, 3.4.3.3)
*/
- public byte numberOfDigits;
+ public int numberOfDigits;
/**
* Numbering Plan identification is a 0 or 4-bit value that
//static protected final int NUMBERING_PLAN_TELEX = 0x4;
//static protected final int NUMBERING_PLAN_PRIVATE = 0x9;
- public byte numberPlan;
+ public int numberPlan;
/**
* NOTE: the parsed string address and the raw byte array values