|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.prowidesoftware.swift.model.SwiftBlock
com.prowidesoftware.swift.model.SwiftValueBlock
com.prowidesoftware.swift.model.SwiftBlock2
public abstract class SwiftBlock2
Base class for SWIFT Application Header Block (block 2).
The Application Header contains information about the
message type and the destination of the message.
This is an optional blockin SWIFT messages.
There are two types of application headers: Input and Output.
Both, input and output block 2 flavors are fixed-length and continuous with no field delimiters.
The fields that conform the blocks's value are represented in the subclasses
as individual attributes for easier managment.
This is an abstract class so especific block 2 subclasses should be instantiated.
Field Summary | |
---|---|
protected java.lang.String |
messagePriority
String of 1 character containing the message priority as follows: S = System N = Normal U = Urgent |
protected java.lang.String |
messageType
String of 3 character containing the Message Type (MT) as classified and numbered by SWIFT. |
Fields inherited from class com.prowidesoftware.swift.model.SwiftBlock |
---|
blockType, id, input, output, unparsedTexts |
Constructor Summary | |
---|---|
SwiftBlock2()
Default Constructor |
Method Summary | |
---|---|
void |
clean()
Sets all attributes to null |
boolean |
equals(java.lang.Object obj)
|
java.lang.String |
getMessagePriority()
Gets the message priority |
java.lang.String |
getMessageType()
Gets the Message Type (MT) as classified and numbered by SWIFT. |
java.lang.String |
getName()
Returns the block name (the value 2 as a string) |
java.lang.Integer |
getNumber()
Returns the block number (the value 2 as an integer) |
int |
hashCode()
|
boolean |
isInput()
Returns true if this block 2 is an input block 2. |
boolean |
isOutput()
Returns true if this block 2 is an output block 2. |
protected void |
setBlockName(java.lang.String blockName)
Sets the block name. |
protected void |
setBlockNumber(java.lang.Integer blockNumber)
Sets the block number. |
void |
setMessagePriority(java.lang.String messagePriority)
Set the message priority |
void |
setMessageType(java.lang.String messageType)
Sets the Message Type (MT) as classified and numbered by SWIFT. |
java.lang.String |
toString()
convert this to string |
Methods inherited from class com.prowidesoftware.swift.model.SwiftValueBlock |
---|
getBlockValue, getValue, getValuePart, isEmpty, setBlockValue, setValue, size |
Methods inherited from class com.prowidesoftware.swift.model.SwiftBlock |
---|
getBlockType, getId, getInput, getOutput, getUnparsedTexts, getUnparsedTextsSize, isTagBlock, setBlockType, setId, setInput, setOutput, setUnparsedTexts, unparsedTextAddText, unparsedTextAddText, unparsedTextGetAsMessage, unparsedTextGetText, unparsedTextIsMessage, unparsedTextVerify |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected java.lang.String messagePriority
protected java.lang.String messageType
Constructor Detail |
---|
public SwiftBlock2()
Method Detail |
---|
protected void setBlockNumber(java.lang.Integer blockNumber)
setBlockNumber
in class SwiftBlock
blockNumber
- the block number to set
java.lang.IllegalArgumentException
- if parameter blockName is not the integer 2protected void setBlockName(java.lang.String blockName)
setBlockName
in class SwiftBlock
blockName
- the block name to set
java.lang.IllegalArgumentException
- if parameter blockName is not the string "2"public java.lang.Integer getNumber()
getNumber
in class SwiftBlock
public java.lang.String getName()
getName
in class SwiftBlock
public java.lang.String toString()
toString
in class SwiftBlock
public void setMessageType(java.lang.String messageType)
messageType
- String of 3 characterpublic java.lang.String getMessageType()
public void setMessagePriority(java.lang.String messagePriority)
messagePriority
- the message prioritypublic java.lang.String getMessagePriority()
public boolean isInput()
true
if this block 2 is an input block 2.
true
if block 2 is input, of false
in other casepublic boolean isOutput()
true
if this block 2 is an output block 2.
true
if block 2 is output, of false
in other casepublic void clean()
public int hashCode()
hashCode
in class SwiftBlock
public boolean equals(java.lang.Object obj)
equals
in class SwiftBlock
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |