public class MT548_MxSese02200201_Translation extends
Modifier | Constructor and Description |
---|---|
|
MT548_MxSese02200201_Translation()
Creates the translation class initializing it with the proper MX identification.
|
protected |
MT548_MxSese02200201_Translation(MxId mxId,
String mxDescription)
This constructor is intended for subclasses to override the translation rules for other versions of MX.
|
Modifier and Type | Method and Description |
---|---|
Boolean |
logicalMessageCriteriaCheck(MT548 source)
Message criteria check
This method checks the content of the source MT548 and determines if it can be translated to the target MxSese02200201 SELECT CRITERIA MustBe (MT548 Settlement Status and Processing Advice\A\23G Function of the Message\23G\Function IsSameString 'INST') MustBe (MT548 Settlement Status and Processing Advice\A2[*]\25D Status\SPRC IsPresent) MustBe (MT548 Settlement Status and Processing Advice\A1[*]\20C Reference\RELA IsPresent) END |
List<PreconditionError> |
preconditionsCheck(MT548 source)
Precondition check
This method checks the precondition on the content of the source MT548 |
void |
preconditionSR1Check(MT548 source)
Precondition check
This method checks the precondition SR1 on the content of the source MT548 IF ((MT548 Settlement Status and Processing Advice\A2[*]\25D Status\SPRC Count) GreaterThan '1') THEN Fail ('05001', 'Only one status SPRC by message.', MT548 Settlement Status and Processing Advice\A2[*]\25D Status\SPRC) END |
protected Integer |
resolveComponentNumber(String field,
String component)
Static mapping of fields component names into its correspondent component number
|
MxSese02200201 |
translate(MT548 source)
Main entry point for the translation
|
protected void |
translateImpl(MT548 source)
Translation rules implementation
|
protected void |
translateTTR1(String targetElement,
MtPathResult content)
Translate method TTR1
1 TRANSLATE(98A, DateAndDateTimeChoice) 2 RULE 3 NODE (Date) 4 (Date FormatDateTime ('MT_YYYYMMDD', 'MX_Date')) CopyTo Date 5 END 6 END 7 END |
protected void |
translateTTR10(String targetElement,
String content)
Translate method TTR10
76 TRANSLATE(Identifier_FIN_35x, RestrictedFINXMax35Text) 77 RULE 78 Identifier_FIN_35x CopyTo RestrictedFINXMax35Text 79 END 80 END |
protected void |
translateTTR11(String targetElement,
MtPathResult content)
Translate method TTR11
81 TRANSLATE(97B_2, SecuritiesAccount17) 82 RULE 83 NODE (Identification) 84 AccountNumber CopyTo Identification 85 END 86 NODE (Type) 87 NODE (Identification) 88 AccountTypeCode CopyTo Type\Identification 89 END 90 DataSourceScheme TranslateTo Type 91 NODE (Issuer) 92 IF (Not (DataSourceScheme IsPresent)) 93 THEN 94 'NONE' CopyTo Type\Issuer 95 END 96 END 97 END 98 END 99 END |
protected void |
translateTTR12(String targetElement,
String content)
Translate method TTR12
100 TRANSLATE(Identifier_FIN_8c, GenericIdentification25) 101 RULE 102 NODE (Issuer) 103 (Identifier_FIN_8c Substring ('1', '4')) CopyTo Issuer 104 END 105 NODE (SchemeName) 106 IF (Not (((Identifier_FIN_8c Substring '5') Length) IsSameNumber '0')) 107 THEN 108 (Identifier_FIN_8c Substring '5') CopyTo SchemeName 109 END 110 END 111 END 112 END |
protected void |
translateTTR13(String targetElement,
MtPathResult content)
Translate method TTR13
113 TRANSLATE(24B_62, RejectionAndRepairReason5Choice) 114 RULE 115 NODE (Code) 116 IF (Not (DataSourceScheme IsPresent)) 117 THEN 118 ReasonCode TranslateTo Code 119 END 120 END 121 NODE (Proprietary) 122 DataSourceScheme TranslateTo Proprietary 123 NODE (Identification) 124 IF (DataSourceScheme IsPresent) 125 THEN 126 ReasonCode CopyTo Proprietary\Identification 127 END 128 END 129 END 130 END 131 END |
protected void |
translateTTR14(String targetElement,
String content)
Translate method TTR14
132 TRANSLATE(OptionalCode_4!c_382, RejectionReason24Code) 133 RULE 134 'ADEA' EquivalentTo 'ADEA' 135 'DSEC' EquivalentTo 'DSEC' 136 'LATE' EquivalentTo 'LATE' 137 'NARR' EquivalentTo 'OTHR' 138 'MISM' EquivalentTo 'MISM' 139 'REFE' EquivalentTo 'REFE' 140 'SAFE' EquivalentTo 'SAFE' 141 END 142 END |
protected void |
translateTTR15(String targetElement,
MtPathResult content)
Translate method TTR15
143 TRANSLATE(Identifier_FIN_8c, GenericIdentification25) 144 RULE 145 NODE (Issuer) 146 (Identifier_FIN_8c Substring ('1', '4')) CopyTo Issuer 147 END 148 NODE (SchemeName) 149 IF (Not (((Identifier_FIN_8c Substring '5') Length) IsSameNumber '0')) 150 THEN 151 (Identifier_FIN_8c Substring '5') CopyTo SchemeName 152 END 153 END 154 END 155 END |
protected void |
translateTTR16(String targetElement,
MtPathResult content)
Translate method TTR16
156 TRANSLATE(70D, RestrictedFINXMax210Text) 157 RULE 158 (Narrative\Line[*] Concatenate) CopyTo RestrictedFINXMax210Text 159 END 160 END |
protected void |
translateTTR17(String targetElement,
MtPathResult content)
Translate method TTR17
161 TRANSLATE(95P_2, PartyIdentification16Choice) 162 RULE 163 NODE (BICOrBEI) 164 IdentifierCode TranslateTo BICOrBEI 165 END 166 END 167 END |
protected void |
translateTTR18(String targetElement,
MtPathResult content)
Translate method TTR18
168 TRANSLATE(95Q, PartyIdentification16Choice) 169 RULE 170 NODE (NameAndAddress) 171 NameAndAddress TranslateTo NameAndAddress 172 END 173 END 174 END |
protected void |
translateTTR19(String targetElement,
String content)
Translate method TTR19
175 TRANSLATE(Text_FIN_4M35x, NameAndAddress12) 176 RULE 177 NODE (Name) 178 ((Line[*] ConcatenateWithSeparator '-') ReplaceAll ('/', '-')) CopyTo Name 179 END 180 END 181 END |
protected void |
translateTTR2(String targetElement,
MtPathResult content)
Translate method TTR2
8 TRANSLATE(98C, DateAndDateTimeChoice) 9 RULE 10 NODE (DateTime) 11 (Date FormatDateTime ('MT_YYYYMMDD', 'MX_Date')) CopyTo DateTime 12 'T' CopyTo DateTime 13 (Time FormatDateTime ('MT_HHMMSS', 'MX_Time')) CopyTo DateTime 14 END 15 END 16 END |
protected void |
translateTTR20(String targetElement,
MtPathResult content)
Translate method TTR20
182 TRANSLATE(95R, PartyIdentification16Choice) 183 RULE 184 NODE (ProprietaryIdentification) 185 NODE (Identification) 186 ProprietaryCode TranslateTo ProprietaryIdentification\Identification 187 END 188 DataSourceScheme TranslateTo ProprietaryIdentification 189 END 190 END 191 END |
protected void |
translateTTR3(String targetElement,
MtPathResult content)
Translate method TTR3
17 TRANSLATE(98E_1, DateAndDateTimeChoice) 18 RULE 19 NODE (DateTime) 20 IF (Decimals IsPresent) 21 THEN 22 ((((((Date FormatDateTime ('MT_YYYYMMDD', 'MX_Date')) Concatenate 'T') Concatenate (Time FormatDateTime ('MT_HHMMSS', 'MX_Time'))) Concatenate '.') Concatenate Decimals) Concatenate (UTCIndicator FormatDateTime ('MT_UTCIndicator', 'MX_TimeOffset'))) CopyTo DateTime 23 ELSE 24 ((((Date FormatDateTime ('MT_YYYYMMDD', 'MX_Date')) Concatenate 'T') Concatenate (Time FormatDateTime ('MT_HHMMSS', 'MX_Time'))) Concatenate (UTCIndicator FormatDateTime ('MT_UTCIndicator', 'MX_TimeOffset'))) CopyTo DateTime 25 END 26 END 27 END 28 END |
protected void |
translateTTR4(String targetElement,
MtPathResult content)
Translate method TTR4
29 TRANSLATE(95P_2, PartyIdentification18Choice) 30 RULE 31 NODE (BICOrBEI) 32 IdentifierCode TranslateTo BICOrBEI 33 END 34 END 35 END |
protected void |
translateTTR5(String targetElement,
String content)
Translate method TTR5
36 TRANSLATE(Identifier_BICBEI, AnyBICIdentifier) 37 RULE 38 Identifier_BICBEI CopyTo AnyBICIdentifier 39 END 40 END |
protected void |
translateTTR6(String targetElement,
MtPathResult content)
Translate method TTR6
41 TRANSLATE(95R, PartyIdentification18Choice) 42 RULE 43 NODE (ProprietaryIdentification) 44 NODE (Identification) 45 ProprietaryCode TranslateTo ProprietaryIdentification\Identification 46 END 47 DataSourceScheme TranslateTo ProprietaryIdentification 48 END 49 END 50 END |
protected void |
translateTTR7(String targetElement,
String content)
Translate method TTR7
51 TRANSLATE(Text_FIN_34x, RestrictedFINXMax34Text) 52 RULE 53 Text_FIN_34x CopyTo RestrictedFINXMax34Text 54 END 55 END |
protected void |
translateTTR8(String targetElement,
String content)
Translate method TTR8
56 TRANSLATE(Identifier_FIN_8c, GenericIdentification24) 57 RULE 58 NODE (Issuer) 59 (Identifier_FIN_8c Substring ('1', '4')) CopyTo Issuer 60 END 61 NODE (SchemeName) 62 IF (Not (((Identifier_FIN_8c Substring '5') Length) IsSameNumber '0')) 63 THEN 64 (Identifier_FIN_8c Substring '5') CopyTo SchemeName 65 END 66 END 67 END 68 END |
protected void |
translateTTR9(String targetElement,
MtPathResult content)
Translate method TTR9
69 TRANSLATE(97A, SecuritiesAccount17) 70 RULE 71 NODE (Identification) 72 AccountNumber TranslateTo Identification 73 END 74 END 75 END |
public MT548_MxSese02200201_Translation()
public final MxSese02200201 translate(MT548 source) throws LogicalMessageCriteriaException, TranslationPreconditionException
source
- a well formed MT548 objectLogicalMessageCriteriaException
TranslationPreconditionException
protected final void translateImpl(MT548 source) throws LogicalMessageCriteriaException, TranslationPreconditionException
source
- a well formed MT548 objectLogicalMessageCriteriaException
TranslationPreconditionException
protected void translateTTR1(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR2(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR3(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR4(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR5(String targetElement, String content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR6(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR7(String targetElement, String content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR8(String targetElement, String content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR9(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR10(String targetElement, String content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR11(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR12(String targetElement, String content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR13(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR14(String targetElement, String content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR15(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR16(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR17(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR18(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR19(String targetElement, String content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedprotected void translateTTR20(String targetElement, MtPathResult content)
source
- translation source message to read content fromcontent
- content to translate, gathered from a source selectortargetElement
- selector in target class where translated code will be addedpublic final Boolean logicalMessageCriteriaCheck(MT548 source)
source
- a well formed MT548 objectpublic final void preconditionSR1Check(MT548 source) throws TranslationPreconditionException
source
- a well formed MT548 objectTranslationPreconditionException
public final List<PreconditionError> preconditionsCheck(MT548 source)