From 89ac5b7f5471a1f88c677ad7176a76b94dbc5d1c Mon Sep 17 00:00:00 2001 From: ptorres-prowide Date: Thu, 11 Jul 2024 17:22:04 -0300 Subject: [PATCH] CU-86b14j4e0_check-code-security-reports-at-GitHub-for-all-repos --- build.gradle | 1 + .../swift/model/field/Field101.java | 7 +- .../swift/model/field/Field102.java | 7 +- .../swift/model/field/Field103.java | 7 +- .../swift/model/field/Field104.java | 7 +- .../swift/model/field/Field105.java | 7 +- .../swift/model/field/Field106.java | 7 +- .../swift/model/field/Field107.java | 7 +- .../swift/model/field/Field108.java | 7 +- .../swift/model/field/Field109.java | 9 +- .../swift/model/field/Field110.java | 7 +- .../swift/model/field/Field111.java | 7 +- .../swift/model/field/Field113.java | 7 +- .../swift/model/field/Field114.java | 7 +- .../swift/model/field/Field115.java | 7 +- .../swift/model/field/Field116.java | 7 +- .../swift/model/field/Field117.java | 7 +- .../swift/model/field/Field118.java | 7 +- .../swift/model/field/Field119.java | 7 +- .../swift/model/field/Field11A.java | 17 +- .../swift/model/field/Field11R.java | 15 +- .../swift/model/field/Field11S.java | 15 +- .../swift/model/field/Field12.java | 7 +- .../swift/model/field/Field120.java | 7 +- .../swift/model/field/Field121.java | 7 +- .../swift/model/field/Field122.java | 7 +- .../swift/model/field/Field123.java | 7 +- .../swift/model/field/Field124.java | 7 +- .../swift/model/field/Field125.java | 7 +- .../swift/model/field/Field126.java | 7 +- .../swift/model/field/Field127.java | 7 +- .../swift/model/field/Field128.java | 10 +- .../swift/model/field/Field129.java | 8 +- .../swift/model/field/Field12A.java | 11 +- .../swift/model/field/Field12B.java | 11 +- .../swift/model/field/Field12C.java | 11 +- .../swift/model/field/Field12D.java | 7 +- .../swift/model/field/Field12E.java | 7 +- .../swift/model/field/Field12F.java | 7 +- .../swift/model/field/Field12G.java | 7 +- .../swift/model/field/Field130.java | 14 +- .../swift/model/field/Field132.java | 8 +- .../swift/model/field/Field133.java | 8 +- .../swift/model/field/Field134.java | 16 +- .../swift/model/field/Field135.java | 7 +- .../swift/model/field/Field136.java | 8 +- .../swift/model/field/Field137.java | 8 +- .../swift/model/field/Field13A.java | 11 +- .../swift/model/field/Field13B.java | 11 +- .../swift/model/field/Field13C.java | 8 +- .../swift/model/field/Field13D.java | 9 +- .../swift/model/field/Field13J.java | 11 +- .../swift/model/field/Field13K.java | 19 +- .../swift/model/field/Field140.java | 7 +- .../swift/model/field/Field141.java | 7 +- .../swift/model/field/Field142.java | 15 +- .../swift/model/field/Field143.java | 15 +- .../swift/model/field/Field144.java | 7 +- .../swift/model/field/Field14A.java | 7 +- .../swift/model/field/Field14B.java | 7 +- .../swift/model/field/Field14C.java | 7 +- .../swift/model/field/Field14D.java | 7 +- .../swift/model/field/Field14E.java | 7 +- .../swift/model/field/Field14F.java | 7 +- .../swift/model/field/Field14G.java | 8 +- .../swift/model/field/Field14H.java | 7 +- .../swift/model/field/Field14J.java | 7 +- .../swift/model/field/Field14K.java | 7 +- .../swift/model/field/Field14L.java | 7 +- .../swift/model/field/Field14M.java | 7 +- .../swift/model/field/Field14N.java | 7 +- .../swift/model/field/Field14O.java | 7 +- .../swift/model/field/Field14S.java | 8 +- .../swift/model/field/Field151.java | 7 +- .../swift/model/field/Field152.java | 7 +- .../swift/model/field/Field153.java | 7 +- .../swift/model/field/Field15A.java | 7 +- .../swift/model/field/Field15B.java | 7 +- .../swift/model/field/Field15C.java | 7 +- .../swift/model/field/Field15D.java | 7 +- .../swift/model/field/Field15E.java | 7 +- .../swift/model/field/Field15F.java | 7 +- .../swift/model/field/Field15G.java | 7 +- .../swift/model/field/Field15H.java | 7 +- .../swift/model/field/Field15I.java | 7 +- .../swift/model/field/Field15J.java | 7 +- .../swift/model/field/Field15K.java | 7 +- .../swift/model/field/Field15L.java | 7 +- .../swift/model/field/Field15M.java | 7 +- .../swift/model/field/Field15N.java | 7 +- .../swift/model/field/Field15O.java | 7 +- .../swift/model/field/Field15P.java | 7 +- .../swift/model/field/Field165.java | 8 +- .../swift/model/field/Field16A.java | 7 +- .../swift/model/field/Field16C.java | 7 +- .../swift/model/field/Field16R.java | 7 +- .../swift/model/field/Field16S.java | 7 +- .../swift/model/field/Field171.java | 13 +- .../swift/model/field/Field172.java | 14 +- .../swift/model/field/Field173.java | 15 +- .../swift/model/field/Field174.java | 7 +- .../swift/model/field/Field175.java | 12 +- .../swift/model/field/Field177.java | 15 +- .../swift/model/field/Field179.java | 12 +- .../swift/model/field/Field17A.java | 7 +- .../swift/model/field/Field17B.java | 11 +- .../swift/model/field/Field17C.java | 7 +- .../swift/model/field/Field17E.java | 7 +- .../swift/model/field/Field17F.java | 7 +- .../swift/model/field/Field17G.java | 7 +- .../swift/model/field/Field17H.java | 7 +- .../swift/model/field/Field17I.java | 7 +- .../swift/model/field/Field17L.java | 7 +- .../swift/model/field/Field17M.java | 7 +- .../swift/model/field/Field17N.java | 7 +- .../swift/model/field/Field17O.java | 7 +- .../swift/model/field/Field17P.java | 7 +- .../swift/model/field/Field17Q.java | 7 +- .../swift/model/field/Field17R.java | 7 +- .../swift/model/field/Field17S.java | 7 +- .../swift/model/field/Field17T.java | 7 +- .../swift/model/field/Field17U.java | 7 +- .../swift/model/field/Field17V.java | 7 +- .../swift/model/field/Field17W.java | 7 +- .../swift/model/field/Field17X.java | 7 +- .../swift/model/field/Field17Y.java | 7 +- .../swift/model/field/Field17Z.java | 7 +- .../swift/model/field/Field18A.java | 7 +- .../swift/model/field/Field18B.java | 7 +- .../swift/model/field/Field18C.java | 7 +- .../swift/model/field/Field18D.java | 7 +- .../swift/model/field/Field19.java | 15 +- .../swift/model/field/Field199.java | 7 +- .../swift/model/field/Field19A.java | 25 +- .../swift/model/field/Field19B.java | 25 +- .../swift/model/field/Field19C.java | 16 +- .../swift/model/field/Field19Y.java | 15 +- .../swift/model/field/Field19Z.java | 15 +- .../swift/model/field/Field20.java | 7 +- .../swift/model/field/Field202.java | 7 +- .../swift/model/field/Field203.java | 7 +- .../swift/model/field/Field204.java | 7 +- .../swift/model/field/Field206.java | 7 +- .../swift/model/field/Field208.java | 7 +- .../swift/model/field/Field209.java | 7 +- .../swift/model/field/Field20C.java | 11 +- .../swift/model/field/Field20D.java | 11 +- .../swift/model/field/Field20U.java | 11 +- .../swift/model/field/Field21.java | 7 +- .../swift/model/field/Field21A.java | 7 +- .../swift/model/field/Field21B.java | 7 +- .../swift/model/field/Field21C.java | 7 +- .../swift/model/field/Field21D.java | 7 +- .../swift/model/field/Field21E.java | 7 +- .../swift/model/field/Field21F.java | 7 +- .../swift/model/field/Field21G.java | 7 +- .../swift/model/field/Field21H.java | 8 +- .../swift/model/field/Field21N.java | 7 +- .../swift/model/field/Field21P.java | 7 +- .../swift/model/field/Field21R.java | 7 +- .../swift/model/field/Field22.java | 8 +- .../swift/model/field/Field22A.java | 7 +- .../swift/model/field/Field22B.java | 7 +- .../swift/model/field/Field22C.java | 8 +- .../swift/model/field/Field22D.java | 7 +- .../swift/model/field/Field22E.java | 7 +- .../swift/model/field/Field22F.java | 11 +- .../swift/model/field/Field22G.java | 7 +- .../swift/model/field/Field22H.java | 11 +- .../swift/model/field/Field22J.java | 7 +- .../swift/model/field/Field22K.java | 8 +- .../swift/model/field/Field22L.java | 7 +- .../swift/model/field/Field22M.java | 7 +- .../swift/model/field/Field22N.java | 7 +- .../swift/model/field/Field22P.java | 7 +- .../swift/model/field/Field22Q.java | 7 +- .../swift/model/field/Field22R.java | 7 +- .../swift/model/field/Field22S.java | 8 +- .../swift/model/field/Field22T.java | 7 +- .../swift/model/field/Field22U.java | 7 +- .../swift/model/field/Field22V.java | 7 +- .../swift/model/field/Field22W.java | 7 +- .../swift/model/field/Field22X.java | 7 +- .../swift/model/field/Field22Y.java | 7 +- .../swift/model/field/Field22Z.java | 7 +- .../swift/model/field/Field23.java | 14 +- .../swift/model/field/Field23A.java | 8 +- .../swift/model/field/Field23B.java | 7 +- .../swift/model/field/Field23C.java | 7 +- .../swift/model/field/Field23D.java | 7 +- .../swift/model/field/Field23E.java | 8 +- .../swift/model/field/Field23F.java | 8 +- .../swift/model/field/Field23G.java | 8 +- .../swift/model/field/Field23H.java | 7 +- .../swift/model/field/Field23R.java | 14 +- .../swift/model/field/Field23S.java | 7 +- .../swift/model/field/Field23X.java | 8 +- .../swift/model/field/Field242.java | 7 +- .../swift/model/field/Field243.java | 7 +- .../swift/model/field/Field24B.java | 11 +- .../swift/model/field/Field24D.java | 8 +- .../swift/model/field/Field24E.java | 8 +- .../swift/model/field/Field24G.java | 14 +- .../swift/model/field/Field25.java | 7 +- .../swift/model/field/Field251.java | 7 +- .../swift/model/field/Field252.java | 13 +- .../swift/model/field/Field253.java | 7 +- .../swift/model/field/Field254.java | 13 +- .../swift/model/field/Field255.java | 14 +- .../swift/model/field/Field256.java | 14 +- .../swift/model/field/Field257.java | 9 +- .../swift/model/field/Field258.java | 14 +- .../swift/model/field/Field259.java | 14 +- .../swift/model/field/Field25A.java | 7 +- .../swift/model/field/Field25D.java | 11 +- .../swift/model/field/Field25P.java | 16 +- .../swift/model/field/Field260.java | 9 +- .../swift/model/field/Field263.java | 9 +- .../swift/model/field/Field264.java | 9 +- .../swift/model/field/Field26A.java | 8 +- .../swift/model/field/Field26B.java | 7 +- .../swift/model/field/Field26C.java | 8 +- .../swift/model/field/Field26D.java | 14 +- .../swift/model/field/Field26E.java | 7 +- .../swift/model/field/Field26F.java | 7 +- .../swift/model/field/Field26H.java | 7 +- .../swift/model/field/Field26K.java | 7 +- .../swift/model/field/Field26T.java | 7 +- .../swift/model/field/Field27.java | 8 +- .../swift/model/field/Field270.java | 9 +- .../swift/model/field/Field271.java | 9 +- .../swift/model/field/Field272.java | 9 +- .../swift/model/field/Field28.java | 8 +- .../swift/model/field/Field280.java | 8 +- .../swift/model/field/Field281.java | 8 +- .../swift/model/field/Field28C.java | 8 +- .../swift/model/field/Field28D.java | 8 +- .../swift/model/field/Field28E.java | 8 +- .../swift/model/field/Field29A.java | 6 + .../swift/model/field/Field29B.java | 14 +- .../swift/model/field/Field29E.java | 13 +- .../swift/model/field/Field29H.java | 7 +- .../swift/model/field/Field29I.java | 7 +- .../swift/model/field/Field29J.java | 13 +- .../swift/model/field/Field29K.java | 13 +- .../swift/model/field/Field29L.java | 14 +- .../swift/model/field/Field29M.java | 13 +- .../swift/model/field/Field29N.java | 14 +- .../swift/model/field/Field29O.java | 13 +- .../swift/model/field/Field30.java | 13 +- .../swift/model/field/Field301.java | 7 +- .../swift/model/field/Field302.java | 7 +- .../swift/model/field/Field303.java | 7 +- .../swift/model/field/Field304.java | 8 +- .../swift/model/field/Field305.java | 7 +- .../swift/model/field/Field307.java | 7 +- .../swift/model/field/Field30F.java | 13 +- .../swift/model/field/Field30G.java | 14 +- .../swift/model/field/Field30H.java | 13 +- .../swift/model/field/Field30I.java | 14 +- .../swift/model/field/Field30J.java | 8 +- .../swift/model/field/Field30M.java | 13 +- .../swift/model/field/Field30N.java | 13 +- .../swift/model/field/Field30P.java | 13 +- .../swift/model/field/Field30Q.java | 13 +- .../swift/model/field/Field30S.java | 13 +- .../swift/model/field/Field30T.java | 13 +- .../swift/model/field/Field30U.java | 13 +- .../swift/model/field/Field30V.java | 13 +- .../swift/model/field/Field30X.java | 13 +- .../swift/model/field/Field30Y.java | 13 +- .../swift/model/field/Field30Z.java | 13 +- .../swift/model/field/Field311.java | 7 +- .../swift/model/field/Field312.java | 7 +- .../swift/model/field/Field313.java | 7 +- .../swift/model/field/Field31C.java | 13 +- .../swift/model/field/Field31D.java | 9 +- .../swift/model/field/Field31E.java | 13 +- .../swift/model/field/Field31F.java | 9 +- .../swift/model/field/Field31G.java | 9 +- .../swift/model/field/Field31L.java | 13 +- .../swift/model/field/Field31P.java | 9 +- .../swift/model/field/Field31R.java | 14 +- .../swift/model/field/Field31S.java | 13 +- .../swift/model/field/Field31X.java | 9 +- .../swift/model/field/Field329.java | 7 +- .../swift/model/field/Field32A.java | 23 +- .../swift/model/field/Field32B.java | 22 +- .../swift/model/field/Field32C.java | 23 +- .../swift/model/field/Field32D.java | 23 +- .../swift/model/field/Field32E.java | 13 +- .../swift/model/field/Field32F.java | 16 +- .../swift/model/field/Field32G.java | 22 +- .../swift/model/field/Field32H.java | 22 +- .../swift/model/field/Field32K.java | 22 +- .../swift/model/field/Field32M.java | 22 +- .../swift/model/field/Field32Q.java | 14 +- .../swift/model/field/Field32R.java | 16 +- .../swift/model/field/Field32U.java | 22 +- .../swift/model/field/Field330.java | 8 +- .../swift/model/field/Field331.java | 9 +- .../swift/model/field/Field332.java | 8 +- .../swift/model/field/Field333.java | 9 +- .../swift/model/field/Field334.java | 13 +- .../swift/model/field/Field335.java | 13 +- .../swift/model/field/Field336.java | 8 +- .../swift/model/field/Field337.java | 7 +- .../swift/model/field/Field338.java | 7 +- .../swift/model/field/Field339.java | 7 +- .../swift/model/field/Field33A.java | 23 +- .../swift/model/field/Field33B.java | 16 +- .../swift/model/field/Field33C.java | 23 +- .../swift/model/field/Field33D.java | 23 +- .../swift/model/field/Field33E.java | 22 +- .../swift/model/field/Field33F.java | 22 +- .../swift/model/field/Field33G.java | 15 +- .../swift/model/field/Field33H.java | 22 +- .../swift/model/field/Field33J.java | 16 +- .../swift/model/field/Field33K.java | 22 +- .../swift/model/field/Field33S.java | 16 +- .../swift/model/field/Field33T.java | 16 +- .../swift/model/field/Field33Z.java | 15 +- .../swift/model/field/Field340.java | 8 +- .../swift/model/field/Field341.java | 7 +- .../swift/model/field/Field342.java | 13 +- .../swift/model/field/Field343.java | 8 +- .../swift/model/field/Field344.java | 8 +- .../swift/model/field/Field345.java | 8 +- .../swift/model/field/Field346.java | 8 +- .../swift/model/field/Field347.java | 8 +- .../swift/model/field/Field348.java | 7 +- .../swift/model/field/Field349.java | 7 +- .../swift/model/field/Field34A.java | 23 +- .../swift/model/field/Field34B.java | 22 +- .../swift/model/field/Field34C.java | 22 +- .../swift/model/field/Field34E.java | 22 +- .../swift/model/field/Field34F.java | 22 +- .../swift/model/field/Field34J.java | 16 +- .../swift/model/field/Field34P.java | 23 +- .../swift/model/field/Field34R.java | 23 +- .../swift/model/field/Field35A.java | 16 +- .../swift/model/field/Field35B.java | 14 +- .../swift/model/field/Field35C.java | 8 +- .../swift/model/field/Field35D.java | 13 +- .../swift/model/field/Field35E.java | 14 +- .../swift/model/field/Field35G.java | 14 +- .../swift/model/field/Field35H.java | 16 +- .../swift/model/field/Field35L.java | 14 +- .../swift/model/field/Field35N.java | 16 +- .../swift/model/field/Field35S.java | 16 +- .../swift/model/field/Field35U.java | 9 +- .../swift/model/field/Field36.java | 15 +- .../swift/model/field/Field36B.java | 19 +- .../swift/model/field/Field36C.java | 11 +- .../swift/model/field/Field36D.java | 11 +- .../swift/model/field/Field36E.java | 19 +- .../swift/model/field/Field37A.java | 10 +- .../swift/model/field/Field37B.java | 10 +- .../swift/model/field/Field37C.java | 10 +- .../swift/model/field/Field37D.java | 10 +- .../swift/model/field/Field37E.java | 10 +- .../swift/model/field/Field37F.java | 10 +- .../swift/model/field/Field37G.java | 16 +- .../swift/model/field/Field37H.java | 16 +- .../swift/model/field/Field37J.java | 15 +- .../swift/model/field/Field37K.java | 16 +- .../swift/model/field/Field37L.java | 15 +- .../swift/model/field/Field37M.java | 16 +- .../swift/model/field/Field37N.java | 6 + .../swift/model/field/Field37P.java | 15 +- .../swift/model/field/Field37R.java | 16 +- .../swift/model/field/Field37U.java | 15 +- .../swift/model/field/Field37V.java | 16 +- .../swift/model/field/Field38A.java | 7 +- .../swift/model/field/Field38D.java | 7 +- .../swift/model/field/Field38E.java | 8 +- .../swift/model/field/Field38G.java | 8 +- .../swift/model/field/Field38H.java | 8 +- .../swift/model/field/Field38J.java | 8 +- .../swift/model/field/Field39A.java | 8 +- .../swift/model/field/Field39B.java | 7 +- .../swift/model/field/Field39C.java | 14 +- .../swift/model/field/Field39D.java | 14 +- .../swift/model/field/Field39E.java | 14 +- .../swift/model/field/Field39F.java | 14 +- .../swift/model/field/Field39M.java | 7 +- .../swift/model/field/Field401.java | 7 +- .../swift/model/field/Field405.java | 8 +- .../swift/model/field/Field40A.java | 7 +- .../swift/model/field/Field40B.java | 14 +- .../swift/model/field/Field40C.java | 8 +- .../swift/model/field/Field40D.java | 7 +- .../swift/model/field/Field40E.java | 8 +- .../swift/model/field/Field40F.java | 7 +- .../swift/model/field/Field41A.java | 16 +- .../swift/model/field/Field41D.java | 14 +- .../swift/model/field/Field41F.java | 9 +- .../swift/model/field/Field41G.java | 14 +- .../swift/model/field/Field421.java | 7 +- .../swift/model/field/Field422.java | 8 +- .../swift/model/field/Field423.java | 7 +- .../swift/model/field/Field424.java | 7 +- .../swift/model/field/Field425.java | 8 +- .../swift/model/field/Field42A.java | 8 + .../swift/model/field/Field42C.java | 14 +- .../swift/model/field/Field42D.java | 6 + .../swift/model/field/Field42M.java | 14 +- .../swift/model/field/Field42P.java | 14 +- .../swift/model/field/Field431.java | 7 +- .../swift/model/field/Field432.java | 7 +- .../swift/model/field/Field433.java | 8 +- .../swift/model/field/Field434.java | 8 +- .../swift/model/field/Field43P.java | 7 +- .../swift/model/field/Field43T.java | 7 +- .../swift/model/field/Field443.java | 7 +- .../swift/model/field/Field44A.java | 7 +- .../swift/model/field/Field44B.java | 7 +- .../swift/model/field/Field44C.java | 13 +- .../swift/model/field/Field44D.java | 14 +- .../swift/model/field/Field44E.java | 7 +- .../swift/model/field/Field44F.java | 7 +- .../swift/model/field/Field44H.java | 8 +- .../swift/model/field/Field44J.java | 14 +- .../swift/model/field/Field451.java | 7 +- .../swift/model/field/Field45A.java | 13 +- .../swift/model/field/Field45B.java | 6 + .../swift/model/field/Field45C.java | 13 +- .../swift/model/field/Field45D.java | 13 +- .../swift/model/field/Field45L.java | 13 +- .../swift/model/field/Field461.java | 7 +- .../swift/model/field/Field46A.java | 13 +- .../swift/model/field/Field46B.java | 6 + .../swift/model/field/Field47A.java | 13 +- .../swift/model/field/Field47B.java | 6 + .../swift/model/field/Field48.java | 8 +- .../swift/model/field/Field48B.java | 7 +- .../swift/model/field/Field48D.java | 7 +- .../swift/model/field/Field49.java | 7 +- .../swift/model/field/Field49A.java | 14 +- .../swift/model/field/Field49G.java | 13 +- .../swift/model/field/Field49H.java | 13 +- .../swift/model/field/Field49M.java | 6 + .../swift/model/field/Field49N.java | 6 + .../swift/model/field/Field50.java | 14 +- .../swift/model/field/Field503.java | 7 +- .../swift/model/field/Field50A.java | 16 +- .../swift/model/field/Field50B.java | 14 +- .../swift/model/field/Field50C.java | 9 +- .../swift/model/field/Field50D.java | 6 + .../swift/model/field/Field50F.java | 17 +- .../swift/model/field/Field50G.java | 8 + .../swift/model/field/Field50H.java | 6 + .../swift/model/field/Field50K.java | 6 + .../swift/model/field/Field51.java | 14 +- .../swift/model/field/Field51A.java | 8 + .../swift/model/field/Field51D.java | 6 + .../swift/model/field/Field52A.java | 8 + .../swift/model/field/Field52B.java | 6 + .../swift/model/field/Field52D.java | 6 + .../swift/model/field/Field533.java | 7 +- .../swift/model/field/Field53A.java | 8 + .../swift/model/field/Field53B.java | 6 + .../swift/model/field/Field53D.java | 6 + .../swift/model/field/Field54A.java | 8 + .../swift/model/field/Field54B.java | 6 + .../swift/model/field/Field54D.java | 6 + .../swift/model/field/Field55A.java | 8 + .../swift/model/field/Field55B.java | 6 + .../swift/model/field/Field55D.java | 6 + .../swift/model/field/Field56A.java | 8 + .../swift/model/field/Field56B.java | 6 + .../swift/model/field/Field56D.java | 6 + .../swift/model/field/Field57A.java | 8 + .../swift/model/field/Field57B.java | 6 + .../swift/model/field/Field57D.java | 6 + .../swift/model/field/Field58A.java | 8 + .../swift/model/field/Field58B.java | 6 + .../swift/model/field/Field58D.java | 6 + .../swift/model/field/Field59.java | 14 +- .../swift/model/field/Field59A.java | 16 +- .../swift/model/field/Field59F.java | 14 +- .../swift/model/field/Field60F.java | 23 +- .../swift/model/field/Field60M.java | 23 +- .../swift/model/field/Field61.java | 16 +- .../swift/model/field/Field619.java | 7 +- .../swift/model/field/Field62F.java | 17 +- .../swift/model/field/Field62M.java | 17 +- .../swift/model/field/Field64.java | 17 +- .../swift/model/field/Field65.java | 17 +- .../swift/model/field/Field68A.java | 15 +- .../swift/model/field/Field69A.java | 17 +- .../swift/model/field/Field69B.java | 17 +- .../swift/model/field/Field69C.java | 12 +- .../swift/model/field/Field69D.java | 12 +- .../swift/model/field/Field69E.java | 17 +- .../swift/model/field/Field69F.java | 17 +- .../swift/model/field/Field69J.java | 11 +- .../swift/model/field/Field70.java | 6 + .../swift/model/field/Field70C.java | 17 +- .../swift/model/field/Field70D.java | 17 +- .../swift/model/field/Field70E.java | 17 +- .../swift/model/field/Field70F.java | 17 +- .../swift/model/field/Field70G.java | 17 +- .../swift/model/field/Field70H.java | 11 +- .../swift/model/field/Field71A.java | 7 +- .../swift/model/field/Field71B.java | 6 + .../swift/model/field/Field71C.java | 14 +- .../swift/model/field/Field71D.java | 6 + .../swift/model/field/Field71F.java | 22 +- .../swift/model/field/Field71G.java | 22 +- .../swift/model/field/Field71N.java | 14 +- .../swift/model/field/Field72.java | 6 + .../swift/model/field/Field72Z.java | 6 + .../swift/model/field/Field73.java | 6 + .../swift/model/field/Field73A.java | 6 + .../swift/model/field/Field73R.java | 8 +- .../swift/model/field/Field73S.java | 8 +- .../swift/model/field/Field74.java | 6 + .../swift/model/field/Field75.java | 6 + .../swift/model/field/Field76.java | 6 + .../swift/model/field/Field77.java | 6 + .../swift/model/field/Field77A.java | 6 + .../swift/model/field/Field77B.java | 6 + .../swift/model/field/Field77C.java | 13 +- .../swift/model/field/Field77D.java | 6 + .../swift/model/field/Field77E.java | 13 +- .../swift/model/field/Field77F.java | 13 +- .../swift/model/field/Field77H.java | 9 +- .../swift/model/field/Field77J.java | 6 + .../swift/model/field/Field77L.java | 13 +- .../swift/model/field/Field77T.java | 13 +- .../swift/model/field/Field77U.java | 13 +- .../swift/model/field/Field78.java | 14 +- .../swift/model/field/Field78D.java | 14 +- .../swift/model/field/Field79.java | 14 +- .../swift/model/field/Field79Z.java | 14 +- .../swift/model/field/Field80C.java | 14 +- .../swift/model/field/Field81A.java | 8 + .../swift/model/field/Field81D.java | 6 + .../swift/model/field/Field82A.java | 8 + .../swift/model/field/Field82B.java | 6 + .../swift/model/field/Field82D.java | 6 + .../swift/model/field/Field83A.java | 8 + .../swift/model/field/Field83D.java | 6 + .../swift/model/field/Field84A.java | 8 + .../swift/model/field/Field84B.java | 6 + .../swift/model/field/Field84D.java | 6 + .../swift/model/field/Field85A.java | 8 + .../swift/model/field/Field85B.java | 6 + .../swift/model/field/Field85D.java | 6 + .../swift/model/field/Field86.java | 14 +- .../swift/model/field/Field86A.java | 8 + .../swift/model/field/Field86B.java | 6 + .../swift/model/field/Field86D.java | 6 + .../swift/model/field/Field87A.java | 8 + .../swift/model/field/Field87B.java | 6 + .../swift/model/field/Field87D.java | 6 + .../swift/model/field/Field88A.java | 8 + .../swift/model/field/Field88B.java | 6 + .../swift/model/field/Field88D.java | 6 + .../swift/model/field/Field89A.java | 8 + .../swift/model/field/Field89D.java | 6 + .../swift/model/field/Field90A.java | 19 +- .../swift/model/field/Field90B.java | 25 +- .../swift/model/field/Field90C.java | 22 +- .../swift/model/field/Field90D.java | 22 +- .../swift/model/field/Field90E.java | 11 +- .../swift/model/field/Field90F.java | 25 +- .../swift/model/field/Field90J.java | 25 +- .../swift/model/field/Field90K.java | 19 +- .../swift/model/field/Field90L.java | 19 +- .../swift/model/field/Field91A.java | 8 + .../swift/model/field/Field91D.java | 6 + .../swift/model/field/Field92A.java | 19 +- .../swift/model/field/Field92B.java | 25 +- .../swift/model/field/Field92C.java | 11 +- .../swift/model/field/Field92D.java | 19 +- .../swift/model/field/Field92F.java | 25 +- .../swift/model/field/Field92H.java | 18 +- .../swift/model/field/Field92J.java | 18 +- .../swift/model/field/Field92K.java | 11 +- .../swift/model/field/Field92L.java | 25 +- .../swift/model/field/Field92M.java | 25 +- .../swift/model/field/Field92N.java | 25 +- .../swift/model/field/Field92P.java | 19 +- .../swift/model/field/Field92R.java | 19 +- .../swift/model/field/Field93A.java | 11 +- .../swift/model/field/Field93B.java | 19 +- .../swift/model/field/Field93C.java | 19 +- .../swift/model/field/Field93D.java | 19 +- .../swift/model/field/Field93E.java | 19 +- .../swift/model/field/Field93F.java | 19 +- .../swift/model/field/Field94A.java | 7 +- .../swift/model/field/Field94B.java | 11 +- .../swift/model/field/Field94C.java | 11 +- .../swift/model/field/Field94D.java | 11 +- .../swift/model/field/Field94E.java | 17 +- .../swift/model/field/Field94F.java | 13 +- .../swift/model/field/Field94G.java | 17 +- .../swift/model/field/Field94H.java | 13 +- .../swift/model/field/Field94L.java | 11 +- .../swift/model/field/Field95C.java | 11 +- .../swift/model/field/Field95L.java | 11 +- .../swift/model/field/Field95P.java | 5 + .../swift/model/field/Field95Q.java | 9 + .../swift/model/field/Field95R.java | 3 + .../swift/model/field/Field95S.java | 3 + .../swift/model/field/Field95U.java | 9 + .../swift/model/field/Field95V.java | 17 +- .../swift/model/field/Field96A.java | 8 + .../swift/model/field/Field96D.java | 6 + .../swift/model/field/Field97A.java | 11 +- .../swift/model/field/Field97B.java | 11 +- .../swift/model/field/Field97C.java | 11 +- .../swift/model/field/Field97D.java | 11 +- .../swift/model/field/Field97E.java | 11 +- .../swift/model/field/Field98A.java | 17 +- .../swift/model/field/Field98B.java | 11 +- .../swift/model/field/Field98C.java | 17 +- .../swift/model/field/Field98D.java | 14 +- .../swift/model/field/Field98E.java | 17 +- .../swift/model/field/Field98F.java | 16 +- .../swift/model/field/Field98G.java | 14 +- .../swift/model/field/Field98H.java | 13 +- .../swift/model/field/Field98J.java | 14 +- .../swift/model/field/Field98K.java | 12 +- .../swift/model/field/Field999.java | 7 +- .../swift/model/field/Field99A.java | 11 +- .../swift/model/field/Field99B.java | 11 +- .../swift/model/field/Field99C.java | 11 +- .../swift/constraints/IbanValidator.java | 3 +- .../swift/io/parser/SwiftParser.java | 14 +- .../swift/model/BicValidationResult.java | 4 +- .../com/prowidesoftware/swift/model/IBAN.java | 29 +- .../swift/model/IbanValidationResult.java | 4 +- .../swift/model/SwiftMessageUtils.java | 16 +- .../swift/model/SwiftTagListBlock.java | 17 +- .../swift/model/field/Field.java | 8 + .../swift/model/field/Field11T.java | 21 +- .../swift/model/field/Field12H.java | 14 +- .../swift/model/field/Field12K.java | 11 +- .../swift/model/field/Field12L.java | 11 +- .../swift/model/field/Field12R.java | 14 +- .../swift/model/field/Field12S.java | 11 +- .../swift/model/field/Field13E.java | 15 +- .../swift/model/field/Field20E.java | 9 +- .../swift/model/field/Field21S.java | 11 +- .../swift/model/field/Field21T.java | 11 +- .../swift/model/field/Field25F.java | 11 +- .../swift/model/field/Field25G.java | 11 +- .../swift/model/field/Field27A.java | 9 +- .../swift/model/field/Field29D.java | 20 +- .../swift/model/field/Field29F.java | 20 +- .../swift/model/field/Field29P.java | 13 +- .../swift/model/field/Field29S.java | 9 +- .../swift/model/field/Field29U.java | 13 +- .../swift/model/field/Field31J.java | 18 +- .../swift/model/field/Field31K.java | 18 +- .../swift/model/field/Field31M.java | 18 +- .../swift/model/field/Field31T.java | 18 +- .../swift/model/field/Field34D.java | 17 +- .../swift/model/field/Field34K.java | 17 +- .../swift/model/field/Field34L.java | 17 +- .../swift/model/field/Field34M.java | 17 +- .../swift/model/field/Field34S.java | 17 +- .../swift/model/field/Field34T.java | 17 +- .../swift/model/field/Field34U.java | 17 +- .../swift/model/field/Field34V.java | 17 +- .../swift/model/field/Field34W.java | 17 +- .../swift/model/field/Field34X.java | 17 +- .../swift/model/field/Field47E.java | 17 +- .../swift/model/field/Field49D.java | 11 +- .../swift/model/field/Field49F.java | 17 +- .../swift/model/field/Field49J.java | 18 +- .../swift/model/field/Field49K.java | 17 +- .../swift/model/field/Field49L.java | 17 +- .../swift/model/field/Field49Z.java | 17 +- .../swift/model/field/Field71E.java | 8 +- .../swift/model/field/Field78B.java | 17 +- .../swift/model/field/NarrativeFragment.java | 1 + .../swift/model/field/OptionCPartyField.java | 2 +- .../swift/model/field/OptionJPartyField.java | 2 +- .../swift/model/field/OptionLPartyField.java | 2 +- .../swift/utils/ConstraintUtils.java | 485 ++++++++++++++++++ .../com/prowidesoftware/issues/Issue95.java | 2 +- .../issues/JapaneseCharactersTest.java | 47 +- .../swift/constraints/IbanValidatorTest.java | 266 ++++++++++ .../swift/io/RJEReaderTest.java | 65 +-- .../swift/io/parser/BaseMessageTestcase.java | 10 +- .../swift/io/parser/ParserTest.java | 11 +- .../SwiftParserConsumeBlockLenientTest.java | 2 +- .../swift/model/IBANValidateTest.java | 224 ++++++++ .../swift/model/UnparsedTextListTest.java | 12 +- ...FieldComponentLabelsCompatibilityTest.java | 22 +- .../swift/model/mt/AbstractMTTest.java | 6 +- .../swift/utils/ConstraintUtilsTest.java | 18 + .../swift/utils/SwiftFormatUtilsTest.java | 22 +- 697 files changed, 5061 insertions(+), 3544 deletions(-) create mode 100644 src/main/java/com/prowidesoftware/swift/utils/ConstraintUtils.java create mode 100644 src/test/java/com/prowidesoftware/swift/constraints/IbanValidatorTest.java create mode 100644 src/test/java/com/prowidesoftware/swift/model/IBANValidateTest.java create mode 100644 src/test/java/com/prowidesoftware/swift/utils/ConstraintUtilsTest.java diff --git a/build.gradle b/build.gradle index 79dc56ecb..c94374e0b 100644 --- a/build.gradle +++ b/build.gradle @@ -59,6 +59,7 @@ dependencies { compileOnly 'javax.xml.bind:jaxb-api:2.3.1' compileOnly 'javax.validation:validation-api:2.0.1.Final' + testImplementation 'javax.validation:validation-api:2.0.1.Final' testImplementation 'javax.persistence:javax.persistence-api:2.2' testImplementation('org.junit.jupiter:junit-jupiter:5.8.2') testImplementation group: 'org.assertj', name: 'assertj-core', version: '3.22.0' diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field101.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field101.java index d57c46a98..55d5bf051 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field101.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field101.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 101"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field102.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field102.java index 3bbe53977..ff1505582 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field102.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field102.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 102"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field103.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field103.java index 59cc859bc..06d112bdc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field103.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field103.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 103"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field104.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field104.java index 2958e5d3e..2c48d71a9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field104.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field104.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 104"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field105.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field105.java index 4a0933a96..80a4afa4e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field105.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field105.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 105"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field106.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field106.java index b6109fd6e..abba3152d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field106.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field106.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 106"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field107.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field107.java index ce085fc63..711026d9e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field107.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field107.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 107"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field108.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field108.java index 7a8fbda13..65713731a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field108.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field108.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 108"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field109.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field109.java index cd5b2b1e7..b78a771fb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field109.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field109.java @@ -248,11 +248,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -571,6 +569,7 @@ public Field109 setMIR(String component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field110.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field110.java index e84db9d2b..9ac49c0b9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field110.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field110.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 110"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field111.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field111.java index 7da76c56c..04058e379 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field111.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field111.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 111"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field113.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field113.java index a03bcf530..40046345f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field113.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field113.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 113"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field114.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field114.java index f17e8a29f..1e727660a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field114.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field114.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 114"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field115.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field115.java index 07396899d..09f30e0d8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field115.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field115.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 115"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field116.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field116.java index c757e1c6f..932734009 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field116.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field116.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 116"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field117.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field117.java index 20cf9796d..be22ece6c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field117.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field117.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 117"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field118.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field118.java index 527aac845..d4bc0b9d3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field118.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field118.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 118"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field119.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field119.java index 17d471264..2d223ee94 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field119.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field119.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 119"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field11A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field11A.java index 3bdb1348f..67b2f6494 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field11A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field11A.java @@ -232,11 +232,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -510,26 +508,32 @@ public Field11A setCurrency(java.util.Currency component2) { } + @Override public List currencyStrings() { return CurrencyResolver.currencyStrings(this); } + @Override public List currencies() { return CurrencyResolver.currencies(this); } + @Override public Currency currency() { return CurrencyResolver.resolveCurrency(this); } + @Override public String currencyString() { return CurrencyResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { CurrencyResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { CurrencyResolver.resolveSetCurrency(this, cur); } @@ -541,6 +545,7 @@ public void initializeCurrencies(Currency cur) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -551,6 +556,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -565,6 +571,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field11R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field11R.java index 2cc498cf7..81ffa39ff 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field11R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field11R.java @@ -280,11 +280,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -849,6 +847,7 @@ public Field11R setISN(java.lang.Number component4) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -942,6 +941,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -955,6 +955,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field11R cp = newInstance(this); return getLine(cp, line, null, offset); @@ -967,6 +968,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -979,6 +981,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field11R cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -993,6 +996,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1007,6 +1011,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field11R cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field11S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field11S.java index 5877397bd..7720fb765 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field11S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field11S.java @@ -280,11 +280,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -849,6 +847,7 @@ public Field11S setISN(java.lang.Number component4) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -942,6 +941,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -955,6 +955,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field11S cp = newInstance(this); return getLine(cp, line, null, offset); @@ -967,6 +968,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -979,6 +981,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field11S cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -993,6 +996,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1007,6 +1011,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field11S cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12.java index 7cdf9b1dc..202c5121e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field120.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field120.java index 87ea6d68a..93527c132 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field120.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field120.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 120"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field121.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field121.java index 52a5f6355..20ca8e13a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field121.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field121.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 121"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field122.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field122.java index 2debe8c65..ce7620e7f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field122.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field122.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 122"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field123.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field123.java index 0a7c5fc3c..8a5cdf9ae 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field123.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field123.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 123"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field124.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field124.java index 6c3c61278..615b1f4df 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field124.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field124.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 124"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field125.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field125.java index 363093e25..336debe2e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field125.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field125.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 125"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field126.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field126.java index bf7ef458b..53e6b078e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field126.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field126.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 126"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field127.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field127.java index 254361ea1..3a1e4137a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field127.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field127.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 127"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field128.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field128.java index 204220f8e..a541de2f9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field128.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field128.java @@ -223,11 +223,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -461,10 +459,12 @@ public Field128 setBIC(com.prowidesoftware.swift.model.BIC component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field129.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field129.java index c047b861b..223f43069 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field129.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field129.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12A.java index 030748293..f17e1653a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12A.java @@ -242,11 +242,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -512,6 +510,7 @@ public Field12A setInstrumentCode(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -522,6 +521,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -536,6 +536,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12B.java index d4286ba8d..9e4e35fba 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12B.java @@ -241,11 +241,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -507,6 +505,7 @@ public Field12B setType(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -517,6 +516,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -531,6 +531,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12C.java index df7992918..1ab640022 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12C.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field12C setCFICode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12D.java index 343b895d6..75f659675 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12D.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12E.java index 5797b406c..e70e3211d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12E.java @@ -220,11 +220,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12F.java index 4fdcdcb80..27964e0e7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12F.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field12G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field12G.java index 948087f34..ce76faf70 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field12G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field12G.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12G"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field130.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field130.java index 232e4abb4..a30e2c75d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field130.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field130.java @@ -258,11 +258,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -834,6 +832,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -847,6 +846,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field130 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -859,6 +859,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -871,6 +872,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field130 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -885,6 +887,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -899,6 +902,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field130 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field132.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field132.java index c5669dbf1..14ce20a57 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field132.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field132.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field133.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field133.java index 41adf2d0d..e35e3e493 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field133.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field133.java @@ -255,11 +255,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field134.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field134.java index 36f947632..4515ef2b6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field134.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field134.java @@ -240,11 +240,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -518,10 +516,12 @@ public Field134 setBroadcastRequesterCity(String component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -606,6 +606,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -619,6 +620,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field134 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -631,6 +633,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -643,6 +646,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field134 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -657,6 +661,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -671,6 +676,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field134 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field135.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field135.java index 618d9118b..d212e5199 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field135.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field135.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 135"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field136.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field136.java index 0681fa123..318cb5c3d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field136.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field136.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field137.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field137.java index 289cf62ea..4dc4a6ace 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field137.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field137.java @@ -255,11 +255,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field13A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field13A.java index d4b42f975..8c21a29ab 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field13A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field13A.java @@ -228,11 +228,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -451,6 +449,7 @@ public Field13A setNumberIdentification(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -461,6 +460,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -475,6 +475,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field13B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field13B.java index ba91c7b57..623a08279 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field13B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field13B.java @@ -235,11 +235,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -483,6 +481,7 @@ public Field13B setNumber(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -493,6 +492,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -507,6 +507,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field13C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field13C.java index a935203db..b6947c748 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field13C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field13C.java @@ -273,11 +273,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field13D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field13D.java index ac9f4a9ce..e4f86c737 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field13D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field13D.java @@ -261,11 +261,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -664,6 +662,7 @@ public Field13D setOffset(java.util.Calendar component4) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field13J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field13J.java index 74e268389..2cd80980d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field13J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field13J.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -456,6 +454,7 @@ public Field13J setCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -466,6 +465,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -480,6 +480,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field13K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field13K.java index 00262ceec..44f717ac5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field13K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field13K.java @@ -247,14 +247,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -675,6 +674,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -686,6 +686,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -696,6 +697,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -710,6 +712,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field140.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field140.java index de411e41d..3e694e2a9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field140.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field140.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 140"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field141.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field141.java index 4d428b048..4669c1520 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field141.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field141.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 141"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field142.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field142.java index 8353a7f3f..02fd90cdb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field142.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field142.java @@ -210,14 +210,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 142"); } - if (component == 1) { - //datetime: [YY]YYMMDDHHMM - java.text.DateFormat df = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); - } + //datetime: [YY]YYMMDDHHMM + java.text.DateFormat df = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); } return null; } @@ -419,6 +417,7 @@ public Field142 setStartDateTime(java.util.Calendar component1) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field143.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field143.java index 22c1e7e5c..2350c5d3b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field143.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field143.java @@ -210,14 +210,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 143"); } - if (component == 1) { - //datetime: [YY]YYMMDDHHMM - java.text.DateFormat df = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); - } + //datetime: [YY]YYMMDDHHMM + java.text.DateFormat df = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); } return null; } @@ -419,6 +417,7 @@ public Field143 setEndDateTime(java.util.Calendar component1) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field144.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field144.java index 923e02d66..be23dba02 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field144.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field144.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 144"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14A.java index 5824585e2..f433eb6bd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14A.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14B.java index 5b6130ac5..bfe652745 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14B.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14C.java index 638aed8b3..3d25a88c1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14C.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14D.java index d140cd364..bea6329ba 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14D.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14E.java index edd6fda1e..75fc3d2d8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14E.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14F.java index d18b5af7d..9ca71265f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14F.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14G.java index 74b4e290a..86af31c8b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14G.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14H.java index 4389da7a3..562fb2337 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14H.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14H"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14J.java index c1f9898cd..59e786eda 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14J.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14J"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14K.java index 78e81ca64..2928353b7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14K.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14K"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14L.java index e63deb482..859fa0a1c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14L.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14L"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14M.java index 745c3d43c..f493f059b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14M.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14M"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14N.java index 1c05f05d7..907976e13 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14N.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14N"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14O.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14O.java index 2df65e579..68ebfd45b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14O.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14O.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 14O"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field14S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field14S.java index 22d51802e..3fc36f1c5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field14S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field14S.java @@ -267,11 +267,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field151.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field151.java index 5e867942a..440d135d2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field151.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field151.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 151"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field152.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field152.java index 233c4e491..2a08eb54d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field152.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field152.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 152"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field153.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field153.java index 396952f7c..0bae45368 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field153.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field153.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 153"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15A.java index 3cb2254f1..a75eed2c0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15A.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15B.java index 43afdd9ae..3e76a9c85 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15B.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15C.java index 48827bf76..98d27b520 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15C.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15D.java index c58922698..6b05ea81f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15D.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15E.java index 667bceaf6..8350efb64 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15E.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15F.java index 0711f6158..6fc443b72 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15F.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15G.java index 416a21cf3..1daac9063 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15G.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15G"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15H.java index 28b0e7e03..cbb69845f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15H.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15H"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15I.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15I.java index 7b899fc6a..9c156adff 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15I.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15I.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15I"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15J.java index 4b432d205..be120ff69 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15J.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15J"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15K.java index a158eabe0..e5aa04534 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15K.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15K"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15L.java index dfa8f785c..0313e6646 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15L.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15L"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15M.java index 7942e4abd..8de64e749 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15M.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15M"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15N.java index 7c9068912..29eb18415 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15N.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15N"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15O.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15O.java index 3b1247928..33fe4b988 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15O.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15O.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15O"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field15P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field15P.java index 43e72fff7..b6dc0b4ec 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field15P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field15P.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 15P"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field165.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field165.java index 7c7042bad..0f171055a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field165.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field165.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field16A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field16A.java index fe186f556..6ec318ac3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field16A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field16A.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 16A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field16C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field16C.java index ac786a9a8..8f324c741 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field16C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field16C.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 16C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field16R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field16R.java index 111a0e36c..196a4826c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field16R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field16R.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 16R"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field16S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field16S.java index e14f208f6..29f895006 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field16S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field16S.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 16S"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field171.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field171.java index b7bb4c110..8a877fbc8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field171.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field171.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 171"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field171 setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field172.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field172.java index ce1a22779..c934807b6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field172.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field172.java @@ -231,13 +231,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 2) { - //month and day: MMDD - java.text.DateFormat f = new java.text.SimpleDateFormat("MMM dd", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //month and day: MMDD + java.text.DateFormat f = new java.text.SimpleDateFormat("MMM dd", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -519,6 +518,7 @@ public Field172 setEndDate(java.util.Calendar component2) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field173.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field173.java index 8a7305478..b935519c2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field173.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field173.java @@ -210,14 +210,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 173"); } - if (component == 1) { - //day + time: DDHHMM - java.text.DateFormat df = new java.text.SimpleDateFormat("dd", notNull(locale)); - java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); - } + //day + time: DDHHMM + java.text.DateFormat df = new java.text.SimpleDateFormat("dd", notNull(locale)); + java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); } return null; } @@ -419,6 +417,7 @@ public Field173 setDayTime(java.util.Calendar component1) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field174.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field174.java index 36c491888..f54c1d015 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field174.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field174.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 174"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field175.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field175.java index 4a2287910..8828f7ea0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field175.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field175.java @@ -208,13 +208,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 175"); } - if (component == 1) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field177.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field177.java index 729219d29..185dcac83 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field177.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field177.java @@ -210,14 +210,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 177"); } - if (component == 1) { - //datetime: [YY]YYMMDDHHMM - java.text.DateFormat df = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); - } + //datetime: [YY]YYMMDDHHMM + java.text.DateFormat df = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.text.DateFormat tf = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); } return null; } @@ -419,6 +417,7 @@ public Field177 setDateTime(java.util.Calendar component1) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field179.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field179.java index 17a8ca4dc..4a481aab4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field179.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field179.java @@ -203,13 +203,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 179"); } - if (component == 1) { - //time with seconds: HHmmss - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //time with seconds: HHmmss + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17A.java index a63a7687e..f56831408 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17A.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17B.java index 5e70b8c94..220c8125b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17B.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field17B setFlag(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17C.java index cee35dc6c..d17fbe1f0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17C.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17E.java index 5484bdc60..ed2c3bd7b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17E.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17F.java index a3263e18a..880cf4344 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17F.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17G.java index 4d4a3e839..958f0164f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17G.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17G"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17H.java index 726c5a4ca..95bd008a5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17H.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17H"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17I.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17I.java index ff1524fcb..9f44e57c0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17I.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17I.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17I"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17L.java index 0bb11d33a..ea4db73ce 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17L.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17L"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17M.java index 3a96aba8f..fc9618e1d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17M.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17M"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17N.java index 9d9abb33e..29e13289f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17N.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17N"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17O.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17O.java index c412b5092..a090f5e34 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17O.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17O.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17O"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17P.java index 8b1d44096..a209fe6ba 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17P.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17P"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17Q.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17Q.java index f34ea3a17..436424e6f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17Q.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17Q.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17Q"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17R.java index d0264bf29..1989aa511 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17R.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17R"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17S.java index d74579f42..705eeedb4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17S.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17S"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17T.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17T.java index 8c66a1f1f..d8299d141 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17T.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17T.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17T"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17U.java index 6ea0abcab..c1e56356c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17U.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17U"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17V.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17V.java index 03a06e7b1..e04a555d3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17V.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17V.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17V"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17W.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17W.java index 84abe4fd2..7042f497e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17W.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17W.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17W"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17X.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17X.java index 7de5dd9fe..c764c2857 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17X.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17X.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17X"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17Y.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17Y.java index 01b72d439..fa0bcc051 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17Y.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17Y.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17Y"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field17Z.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field17Z.java index 8cc4a7040..5173268d2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field17Z.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field17Z.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 17Z"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field18A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field18A.java index 38ca6fb98..46ebe33ae 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field18A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field18A.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 18A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field18B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field18B.java index d48812fb0..16a9778cd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field18B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field18B.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 18B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field18C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field18C.java index ebd869fa2..f5ab5161b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field18C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field18C.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 18C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field18D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field18D.java index 3acf6689f..da7fc9259 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field18D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field18D.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 18D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field19.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field19.java index ead0f42d3..73b452056 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field19.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field19.java @@ -211,14 +211,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 19"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -500,6 +498,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field199.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field199.java index d688f2f60..f0eccae23 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field199.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field199.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 199"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field19A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field19A.java index d35961f90..97bdc8f09 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field19A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field19A.java @@ -267,14 +267,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -743,26 +742,32 @@ public Field19A setAmount(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -783,6 +788,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -794,6 +800,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -804,6 +811,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -818,6 +826,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field19B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field19B.java index 24db87ad4..06e310121 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field19B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field19B.java @@ -247,14 +247,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -680,26 +679,32 @@ public Field19B setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -720,6 +725,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -731,6 +737,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -741,6 +748,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -755,6 +763,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field19C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field19C.java index 27b35f17a..43acabbe9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field19C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field19C.java @@ -229,14 +229,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -620,6 +619,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field19Y.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field19Y.java index 5c5bb9a1b..5595ea16f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field19Y.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field19Y.java @@ -218,14 +218,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 19Y"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -566,6 +564,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field19Z.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field19Z.java index ec6624b7c..c18cf264d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field19Z.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field19Z.java @@ -218,14 +218,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 19Z"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -566,6 +564,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field20.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field20.java index fc57fd941..c9e5a3c09 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field20.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field20.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 20"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field202.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field202.java index 351ac7bc3..802c12f9f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field202.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field202.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 202"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field203.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field203.java index 28afaf1ab..c6e725dd5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field203.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field203.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 203"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field204.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field204.java index a9e45c628..f692a464e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field204.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field204.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 204"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field206.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field206.java index 36237d297..c6b649280 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field206.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field206.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 206"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field208.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field208.java index d3f2cd81b..3f2a4ef50 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field208.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field208.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 208"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field209.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field209.java index a5680bb22..ebf6d6b22 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field209.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field209.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 209"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field20C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field20C.java index f6eb41ca9..8a835e979 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field20C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field20C.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field20C setReference(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field20D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field20D.java index cb7c9d60d..963bcaa13 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field20D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field20D.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field20D setReference(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field20U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field20U.java index c9c816658..f9d5e7125 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field20U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field20U.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field20U setReference(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21.java index 6312f84ab..3218891c2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21A.java index eaaf6bfd7..fecf98619 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21A.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21B.java index d4a0fc5ad..0f5864ed9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21B.java @@ -219,11 +219,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21C.java index 537f495f7..21bc3e91b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21C.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21D.java index 96f1ecafb..869885496 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21D.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21E.java index b7726ae2d..265ef0277 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21E.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21F.java index f5a098d48..48e2d0abe 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21F.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21G.java index c9d5c1342..c233ae4e8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21G.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21G"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21H.java index 5eb3e53f7..702a1a55a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21H.java @@ -227,11 +227,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21N.java index 9332bf084..741def943 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21N.java @@ -219,11 +219,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21N"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21P.java index b59bb9092..af09371de 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21P.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21P"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field21R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field21R.java index bd2e9c0d7..cd91a0249 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field21R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field21R.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21R"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22.java index fbd5d858c..0d372f315 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22A.java index 7268ec99a..0fc0afea6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22A.java @@ -219,11 +219,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22B.java index feb723af9..5922e5fdb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22B.java @@ -219,11 +219,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22C.java index b7884ff17..619b7868a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22C.java @@ -265,11 +265,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22D.java index cfd3e0717..7376aab01 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22D.java @@ -219,11 +219,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22E.java index 48ddd757a..0ffc7eb7a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22E.java @@ -213,11 +213,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22F.java index bcfa3fe33..f8b5b610b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22F.java @@ -235,11 +235,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -483,6 +481,7 @@ public Field22F setIndicator(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -493,6 +492,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -507,6 +507,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22G.java index eee71a303..452665999 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22G.java @@ -219,11 +219,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22G"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22H.java index 7674c3790..b72d153fc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22H.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -456,6 +454,7 @@ public Field22H setCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -466,6 +465,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -480,6 +480,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22J.java index 6f92e8168..f047305f1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22J.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22J"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22K.java index 342399a26..fdbac9aaf 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22K.java @@ -227,11 +227,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22L.java index 7ac2d901c..c95fab79a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22L.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22L"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22M.java index 5f805cd38..8cdc25157 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22M.java @@ -226,11 +226,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22M"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22N.java index ec2c22c4c..ea68cb195 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22N.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22N"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22P.java index 40f2a20ba..09be66d4e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22P.java @@ -226,11 +226,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22P"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22Q.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22Q.java index 9d0b32c84..9f931a344 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22Q.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22Q.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22Q"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22R.java index 852c8011c..70a3ec211 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22R.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22R"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22S.java index 0dc4052dc..8bd5f35f4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22S.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22T.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22T.java index 7e193ffe2..bfef26b68 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22T.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22T.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22T"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22U.java index 23a0ac510..c5098e881 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22U.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22U"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22V.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22V.java index 4e2e8f8eb..0d0b0fa9d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22V.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22V.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22V"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22W.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22W.java index 09ce255a7..51321d28a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22W.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22W.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22W"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22X.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22X.java index 989dc494b..c0b6a6afc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22X.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22X.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22X"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22Y.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22Y.java index e16b1c7ee..10016f341 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22Y.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22Y.java @@ -220,11 +220,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22Y"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field22Z.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field22Z.java index 5cded64e8..0819e60a9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field22Z.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field22Z.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 22Z"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23.java index d2998a428..bec1f3c5e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23.java @@ -286,11 +286,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -700,26 +698,32 @@ public Field23 setManualAutomaticIndicator(java.util.Currency component4) { } + @Override public List currencyStrings() { return CurrencyResolver.currencyStrings(this); } + @Override public List currencies() { return CurrencyResolver.currencies(this); } + @Override public Currency currency() { return CurrencyResolver.resolveCurrency(this); } + @Override public String currencyString() { return CurrencyResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { CurrencyResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { CurrencyResolver.resolveSetCurrency(this, cur); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23A.java index 9e9593e44..60da6b28e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23A.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23B.java index 916a79d56..37f912682 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23B.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 23B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23C.java index a772d718b..6f606931f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23C.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 23C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23D.java index db07575cb..41dee8d50 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23D.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 23D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23E.java index 7d4b92ddf..bb23a4c1f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23E.java @@ -240,11 +240,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23F.java index 594b1b497..97c41c9e5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23F.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23G.java index d8c273640..46e43ebb8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23G.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23H.java index 4c54b496c..c85315962 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23H.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 23H"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23R.java index efeb71582..32e00ebad 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23R.java @@ -244,11 +244,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(6); } - if (component == 7) { - //default format (as is) - return getComponent(7); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(7); } /** @@ -780,6 +778,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -793,6 +792,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field23R cp = newInstance(this); return getLine(cp, line, null, offset); @@ -805,6 +805,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -817,6 +818,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field23R cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -831,6 +833,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -845,6 +848,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field23R cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23S.java index 77a580d2d..28a27ec1e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23S.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 23S"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field23X.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field23X.java index 9a4cc6830..99a378810 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field23X.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field23X.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field242.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field242.java index b305ad454..a52bd3015 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field242.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field242.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 242"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field243.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field243.java index 85e1e501c..88d32a0f5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field243.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field243.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 243"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field24B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field24B.java index 1585bd2c8..218f35cb9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field24B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field24B.java @@ -235,11 +235,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -483,6 +481,7 @@ public Field24B setReasonCode(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -493,6 +492,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -507,6 +507,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field24D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field24D.java index 6e42505e7..698d6cdf0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field24D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field24D.java @@ -227,11 +227,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field24E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field24E.java index a73a34d32..bfd73c58f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field24E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field24E.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field24G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field24G.java index d1d8c105f..86fb82d61 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field24G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field24G.java @@ -281,11 +281,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(12); } - if (component == 13) { - //default format (as is) - return getComponent(13); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(13); } /** @@ -1366,6 +1364,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1379,6 +1378,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field24G cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1391,6 +1391,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1403,6 +1404,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field24G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1417,6 +1419,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1431,6 +1434,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field24G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field25.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field25.java index 2a09c4694..53bb953b0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field25.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field25.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 25"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field251.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field251.java index 2321b9c86..73e2c5933 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field251.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field251.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 251"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field252.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field252.java index 918b2b248..edf3d5f23 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field252.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field252.java @@ -259,13 +259,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 4) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent4AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent4AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field253.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field253.java index 59d8c849e..8d9c47db5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field253.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field253.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 253"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field254.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field254.java index 1bc86c9cf..30a5a8860 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field254.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field254.java @@ -259,13 +259,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 4) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent4AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent4AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field255.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field255.java index 48d3f4aa0..0697089bd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field255.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field255.java @@ -295,13 +295,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 6) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent6AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent6AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -931,6 +930,7 @@ public Field255 setEndTime(java.util.Calendar component6) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field256.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field256.java index 4d8056bb9..35c50d478 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field256.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field256.java @@ -295,13 +295,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 6) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent6AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent6AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -1040,6 +1039,7 @@ public Field256 setEndTime(java.util.Calendar component6) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field257.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field257.java index 1f5e01a55..46157adda 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field257.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field257.java @@ -285,11 +285,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -877,6 +875,7 @@ public Field257 setSessionNumber(java.lang.Number component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field258.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field258.java index d52f818e9..2d705a2ff 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field258.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field258.java @@ -295,13 +295,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 6) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent6AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent6AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -931,6 +930,7 @@ public Field258 setEndTime(java.util.Calendar component6) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field259.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field259.java index 459f61244..af0c70bf5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field259.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field259.java @@ -290,13 +290,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 6) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent6AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent6AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -1035,6 +1034,7 @@ public Field259 setEndTime(java.util.Calendar component6) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field25A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field25A.java index e89f971e3..8bf9b7db6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field25A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field25A.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 25A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field25D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field25D.java index 9d30f1025..55ade0c30 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field25D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field25D.java @@ -242,11 +242,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -512,6 +510,7 @@ public Field25D setCode(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -522,6 +521,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -536,6 +536,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field25P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field25P.java index 87612f949..c303ac7b6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field25P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field25P.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -524,10 +522,12 @@ public Field25P setBIC(com.prowidesoftware.swift.model.BIC component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -612,6 +612,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -625,6 +626,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field25P cp = newInstance(this); return getLine(cp, line, null, offset); @@ -637,6 +639,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -649,6 +652,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field25P cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -663,6 +667,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -677,6 +682,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field25P cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field260.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field260.java index 718ac8b32..136ae2dea 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field260.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field260.java @@ -285,11 +285,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -877,6 +875,7 @@ public Field260 setSessionNumber(java.lang.Number component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field263.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field263.java index e69c8b6cf..d57df3b44 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field263.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field263.java @@ -285,11 +285,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -877,6 +875,7 @@ public Field263 setSessionNumber(java.lang.Number component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field264.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field264.java index 860d0a3f8..137e4718d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field264.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field264.java @@ -285,11 +285,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -877,6 +875,7 @@ public Field264 setSessionNumber(java.lang.Number component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26A.java index 8a4f61de6..58aa6d77f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26A.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26B.java index 7facd7c15..e1d173b44 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26B.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 26B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26C.java index 56f476bd3..1223701a2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26C.java @@ -291,11 +291,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26D.java index 477e4d369..020641829 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26D.java @@ -354,11 +354,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(29); } - if (component == 30) { - //default format (as is) - return getComponent(30); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(30); } /** @@ -1879,6 +1877,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1892,6 +1891,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field26D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1904,6 +1904,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1916,6 +1917,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field26D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1930,6 +1932,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1944,6 +1947,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field26D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26E.java index 8b6b355c8..485ed9e3f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26E.java @@ -222,11 +222,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 26E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26F.java index c48be97e0..3c01a31ea 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26F.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 26F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26H.java index 8a11e2e97..4958b02e9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26H.java @@ -220,11 +220,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 26H"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26K.java index 3102576a1..1708dea17 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26K.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 26K"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field26T.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field26T.java index ba51687d2..6c3d4fb67 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field26T.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field26T.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 26T"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field27.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field27.java index 575f0f8ac..d4164efdd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field27.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field27.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field270.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field270.java index 6187a8129..321210c67 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field270.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field270.java @@ -232,11 +232,9 @@ public String getValueDisplay(int component, Locale locale) { return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); } } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -476,6 +474,7 @@ public Field270 setLoginBlock(String component2) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field271.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field271.java index b12f7a610..d3f5a0797 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field271.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field271.java @@ -232,11 +232,9 @@ public String getValueDisplay(int component, Locale locale) { return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); } } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -476,6 +474,7 @@ public Field271 setLogoutBlock(String component2) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field272.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field272.java index e4f76c7a4..8708507ab 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field272.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field272.java @@ -232,11 +232,9 @@ public String getValueDisplay(int component, Locale locale) { return df.format(cal.getTime()) + " " + tf.format(cal.getTime()); } } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -476,6 +474,7 @@ public Field272 setAbort(String component2) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field28.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field28.java index 81d1a5bc3..f759965a3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field28.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field28.java @@ -235,11 +235,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field280.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field280.java index a6ba62e65..5ba1b7b29 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field280.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field280.java @@ -256,11 +256,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field281.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field281.java index 3559cc055..0829dda2d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field281.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field281.java @@ -256,11 +256,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field28C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field28C.java index c23b0079e..3d1fedab0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field28C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field28C.java @@ -223,11 +223,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field28D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field28D.java index f96bef0d2..50cb6c9a4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field28D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field28D.java @@ -236,11 +236,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field28E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field28E.java index f55459248..8adb2fe0f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field28E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field28E.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29A.java index 941820954..3aeedc025 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29A.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field29A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field29A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field29A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29B.java index d7d3e3a2b..5f3bc6d6e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29B.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field29B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field29B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field29B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29E.java index c1d458d6c..b019e6477 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29E.java @@ -221,13 +221,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29H.java index 5ab8f8c27..8a27b2fb7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29H.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 29H"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29I.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29I.java index 294eb8c0b..41257dcf6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29I.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29I.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 29I"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29J.java index 5f666a297..a2ce46048 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29J.java @@ -221,13 +221,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29K.java index 6c98d50bb..f24f9259f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29K.java @@ -221,13 +221,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29L.java index ddeeb3dae..5fc1b6ac3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29L.java @@ -241,13 +241,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent3AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent3AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -568,6 +567,7 @@ public Field29L setTime(java.util.Calendar component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29M.java index ca5e1add2..70ffb486e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29M.java @@ -221,13 +221,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29N.java index 5227cbacb..9da063246 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29N.java @@ -241,13 +241,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent3AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent3AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -568,6 +567,7 @@ public Field29N setTime(java.util.Calendar component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field29O.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field29O.java index 2282e6221..333b444f0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field29O.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field29O.java @@ -247,13 +247,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent3AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent3AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30.java index 3a8733798..6d24b96da 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30 setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field301.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field301.java index 4ce5fb508..7158473c4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field301.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field301.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 301"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field302.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field302.java index 7740ab39a..0865132af 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field302.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field302.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 302"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field303.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field303.java index 9e87f7af7..d5bcd0895 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field303.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field303.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 303"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field304.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field304.java index b0eab6aa8..4ba7780aa 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field304.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field304.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field305.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field305.java index 2a1be2cc2..6f4f16d00 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field305.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field305.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 305"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field307.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field307.java index e902e8b74..00e7d5b50 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field307.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field307.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 307"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30F.java index c11c8f67d..126f594f3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30F.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30F"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30F setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30G.java index 6856317c7..bddb77a8b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30G.java @@ -239,13 +239,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 2) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -592,6 +591,7 @@ public Field30G setPeriodEndDate(java.util.Calendar component2) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30H.java index b66f926de..0324bca9e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30H.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30H"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30H setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30I.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30I.java index 38dde6aaf..523b4112a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30I.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30I.java @@ -235,13 +235,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 2) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -562,6 +561,7 @@ public Field30I setEndDate(java.util.Calendar component2) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30J.java index 376f83040..b0eb7c41d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30J.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30M.java index 3ffc3aa75..dda0c31b6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30M.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30M"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30M setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30N.java index 3e226461d..7873c796f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30N.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30N"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30N setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30P.java index 729a97711..3887779d7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30P.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30P"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30P setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30Q.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30Q.java index 8d5c98e93..7daaeaad6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30Q.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30Q.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30Q"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30Q setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30S.java index a1437ce19..6c74e650d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30S.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30S"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30S setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30T.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30T.java index 87df0d0f2..386c0e420 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30T.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30T.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30T"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30T setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30U.java index 814b3d7d2..56856cf74 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30U.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30U"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30U setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30V.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30V.java index 62dbbb99a..9ab4b656a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30V.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30V.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30V"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30V setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30X.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30X.java index d4340b3c1..2d31b29f1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30X.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30X.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30X"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30X setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30Y.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30Y.java index d7e78020c..ed7bb4922 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30Y.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30Y.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30Y"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30Y setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field30Z.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field30Z.java index 7c105f831..9addda9d7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field30Z.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field30Z.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 30Z"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field30Z setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field311.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field311.java index 80e03c2f8..fcb74ab0e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field311.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field311.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 311"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field312.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field312.java index 767b109ae..77d3b2428 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field312.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field312.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 312"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field313.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field313.java index dfebf97d9..40a602ab2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field313.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field313.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 313"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31C.java index f76c5869a..4fb3d476b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31C.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31C"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field31C setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31D.java index 82a8e764f..a6d2d09c4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31D.java @@ -231,11 +231,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -474,6 +472,7 @@ public Field31D setPlace(String component2) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31E.java index a0b9e4c70..d0710e259 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31E.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31E"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field31E setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31F.java index c6f5637fc..355d9bb9b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31F.java @@ -247,11 +247,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -576,6 +574,7 @@ public Field31F setPeriodDetails(String component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31G.java index e932c3dc3..ffe749f57 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31G.java @@ -244,11 +244,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -567,6 +565,7 @@ public Field31G setLocation(String component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31L.java index 8e4401a46..da81d0d84 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31L.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31L"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field31L setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31P.java index 17ef2a6f1..6bdb435e1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31P.java @@ -231,11 +231,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -477,6 +475,7 @@ public Field31P setPlace(String component2) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31R.java index 1de7b0d25..fafa5fe13 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31R.java @@ -228,13 +228,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 2) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -518,6 +517,7 @@ public Field31R setDate2(java.util.Calendar component2) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31S.java index 12781bbc3..67ec26db2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31S.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31S"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field31S setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field31X.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field31X.java index 1681f0a52..a880eb691 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field31X.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field31X.java @@ -254,11 +254,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -586,6 +584,7 @@ public Field31X setCode(String component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field329.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field329.java index a6ebf8b8f..6827d9e0b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field329.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field329.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 329"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32A.java index b112b43f5..a3ca0a159 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32A.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field32A setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32B.java index bb6e42848..52b803293 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32B.java @@ -229,14 +229,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -632,26 +631,32 @@ public Field32B setPrice(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -672,6 +677,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32C.java index 41f9e9c0d..894c50996 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32C.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field32C setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32D.java index 67205053f..2590b3af1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32D.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field32D setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32E.java index 3eb560e46..7f55ee738 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32E.java @@ -210,11 +210,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 32E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -408,26 +405,32 @@ public Field32E setCurrency(java.util.Currency component1) { } + @Override public List currencyStrings() { return CurrencyResolver.currencyStrings(this); } + @Override public List currencies() { return CurrencyResolver.currencies(this); } + @Override public Currency currency() { return CurrencyResolver.resolveCurrency(this); } + @Override public String currencyString() { return CurrencyResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { CurrencyResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { CurrencyResolver.resolveSetCurrency(this, cur); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32F.java index e80d159ac..adfc815b8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32F.java @@ -222,14 +222,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -551,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32G.java index d14965f7a..67459e13b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32G.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field32G setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32H.java index 0108e0495..b9e1d2505 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32H.java @@ -241,14 +241,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -637,26 +636,32 @@ public Field32H setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -677,6 +682,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32K.java index 96184d26a..8424dffb0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32K.java @@ -284,14 +284,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent5AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent5AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -947,26 +946,32 @@ public Field32K setAmount(java.lang.Number component5) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -987,6 +992,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32M.java index f37891dd6..96d32e455 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32M.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field32M setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32Q.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32Q.java index ddec44865..3046768fc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32Q.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32Q.java @@ -223,11 +223,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -501,26 +499,32 @@ public Field32Q setCurrency2(java.util.Currency component2) { } + @Override public List currencyStrings() { return CurrencyResolver.currencyStrings(this); } + @Override public List currencies() { return CurrencyResolver.currencies(this); } + @Override public Currency currency() { return CurrencyResolver.resolveCurrency(this); } + @Override public String currencyString() { return CurrencyResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { CurrencyResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { CurrencyResolver.resolveSetCurrency(this, cur); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32R.java index 3e2fd9bfb..cfd8cc30c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32R.java @@ -244,14 +244,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -616,6 +615,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field32U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field32U.java index 1235ac823..eae166872 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field32U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field32U.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field32U setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field330.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field330.java index 34f8f4979..d517c006b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field330.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field330.java @@ -278,11 +278,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field331.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field331.java index 9360f7aac..017764cb3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field331.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field331.java @@ -359,11 +359,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(11); } - if (component == 12) { - //default format (as is) - return getComponent(12); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(12); } /** @@ -1994,6 +1992,7 @@ public Field331 setLastOutputSequenceNumber(java.lang.Number component12) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field332.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field332.java index 13a3f400c..eb242cbc7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field332.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field332.java @@ -226,11 +226,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field333.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field333.java index ead196766..259da196a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field333.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field333.java @@ -323,11 +323,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(7); } - if (component == 8) { - //default format (as is) - return getComponent(8); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(8); } /** @@ -1362,6 +1360,7 @@ public Field333 setLastOutputSequenceNumberSent(java.lang.Number component8) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field334.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field334.java index 29c5fbc24..d9caecac8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field334.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field334.java @@ -221,13 +221,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field335.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field335.java index fae29b6aa..d690fa00b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field335.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field335.java @@ -274,13 +274,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent5AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent5AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field336.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field336.java index 58542b382..614edd2c6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field336.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field336.java @@ -239,11 +239,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field337.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field337.java index 917b3bc3e..727d8a432 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field337.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field337.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 337"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field338.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field338.java index 2f65cb2cf..bf5b83840 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field338.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field338.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 338"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field339.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field339.java index 4e164290e..bfdb44848 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field339.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field339.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 339"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33A.java index 1640bfe76..3d75217b3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33A.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field33A setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33B.java index 84d003958..af1ac88b8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33B.java @@ -228,14 +228,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -607,6 +606,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33C.java index 052a78c21..ad82b5ff7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33C.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field33C setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33D.java index 11ec7a363..6622220e6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33D.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field33D setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33E.java index 2f50e356b..b5e13f20f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33E.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field33E setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33F.java index e73f602b1..228e602d5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33F.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field33F setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33G.java index 5ccc784e8..bec980641 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33G.java @@ -247,11 +247,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(n); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -697,26 +695,32 @@ public Field33G setCode(String component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -737,6 +741,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33H.java index c2d72cdfe..c8b9e02a9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33H.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field33H setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33J.java index 36a37f099..67ef24c99 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33J.java @@ -229,14 +229,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -580,6 +579,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33K.java index 1739b39c1..0f123e91f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33K.java @@ -284,14 +284,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent5AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent5AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -947,26 +946,32 @@ public Field33K setAmount(java.lang.Number component5) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -987,6 +992,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33S.java index 29297f6d7..bc256f35c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33S.java @@ -229,14 +229,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -580,6 +579,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33T.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33T.java index b7c9cea41..8a62fc438 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33T.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33T.java @@ -229,14 +229,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -617,6 +616,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field33Z.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field33Z.java index 1cb7191e4..47c721a1e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field33Z.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field33Z.java @@ -211,14 +211,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 33Z"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -500,6 +498,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field340.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field340.java index 8d0143bf9..25a53197f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field340.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field340.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field341.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field341.java index fd47577e6..96a7f568f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field341.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field341.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 341"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field342.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field342.java index 38d54a967..51de940c8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field342.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field342.java @@ -225,13 +225,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field343.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field343.java index 27499a2ae..1a9a4545e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field343.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field343.java @@ -252,11 +252,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field344.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field344.java index 83565c6bb..c2e8831fe 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field344.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field344.java @@ -227,11 +227,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field345.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field345.java index d081f42ae..09dd1718e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field345.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field345.java @@ -301,11 +301,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(9); } - if (component == 10) { - //default format (as is) - return getComponent(10); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(10); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field346.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field346.java index 8c102a4e7..82cd57ea6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field346.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field346.java @@ -299,11 +299,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(9); } - if (component == 10) { - //default format (as is) - return getComponent(10); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(10); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field347.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field347.java index efa666cb7..5c78cce8b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field347.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field347.java @@ -299,11 +299,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(9); } - if (component == 10) { - //default format (as is) - return getComponent(10); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(10); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field348.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field348.java index d3a83bfc9..21f6b7f82 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field348.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field348.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 348"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field349.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field349.java index 5761c29f8..a6f5e657f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field349.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field349.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 349"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34A.java index 474a4be31..ff2d38718 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34A.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field34A setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34B.java index db255a591..93b28a34d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34B.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field34B setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34C.java index 8539ccff2..607101e33 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34C.java @@ -271,14 +271,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -806,26 +805,32 @@ public Field34C setAmount(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -846,6 +851,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34E.java index fe0067032..dc3ed94a8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34E.java @@ -241,14 +241,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -637,26 +636,32 @@ public Field34E setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -677,6 +682,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34F.java index 0c5cdfd77..38baf317c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34F.java @@ -241,14 +241,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -637,26 +636,32 @@ public Field34F setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -677,6 +682,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34J.java index bb4455d8a..d47e83662 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34J.java @@ -247,14 +247,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -641,6 +640,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34P.java index 66a1d1134..e93ce74b5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34P.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field34P setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field34R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field34R.java index f57be2cb4..c7a599822 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field34R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field34R.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -679,26 +678,32 @@ public Field34R setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -719,6 +724,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -728,6 +734,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35A.java index 0debaf270..747b36596 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35A.java @@ -236,14 +236,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -646,6 +645,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35B.java index 9d1f0bde8..ac471e7d3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35B.java @@ -281,11 +281,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -999,6 +997,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1012,6 +1011,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field35B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1024,6 +1024,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1036,6 +1037,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field35B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1050,6 +1052,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1064,6 +1067,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field35B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35C.java index f28690b96..6b7d3171f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35C.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35D.java index f80084d34..ee5e7c39c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35D.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 35D"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field35D setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35E.java index 942acdbdc..affb562ce 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35E.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -727,6 +725,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -740,6 +739,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field35E cp = newInstance(this); return getLine(cp, line, null, offset); @@ -752,6 +752,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -764,6 +765,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field35E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -778,6 +780,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -792,6 +795,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field35E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35G.java index 89ae2d038..109f513a1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35G.java @@ -264,11 +264,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(11); } - if (component == 12) { - //default format (as is) - return getComponent(12); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(12); } /** @@ -1015,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1028,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field35G cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1040,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1052,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field35G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1066,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1080,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field35G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35H.java index cfca568a0..c8c14fc19 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35H.java @@ -247,14 +247,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -678,6 +677,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35L.java index 9e27564ab..ebf97277a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35L.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field35L cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field35L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field35L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35N.java index bb85a4a40..982fc9cb1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35N.java @@ -236,14 +236,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -646,6 +645,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35S.java index 03cd966d1..30d10aad7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35S.java @@ -236,14 +236,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -646,6 +645,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field35U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field35U.java index cf7d24e0f..178ccac34 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field35U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field35U.java @@ -248,11 +248,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(n); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -674,6 +672,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field36.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field36.java index 9402cae90..7d6144e62 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field36.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field36.java @@ -211,14 +211,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 36"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -500,6 +498,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field36B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field36B.java index 0ed2661d6..cf57c3235 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field36B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field36B.java @@ -240,14 +240,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -609,6 +608,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -620,6 +620,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -630,6 +631,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -644,6 +646,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field36C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field36C.java index a972386da..5e5dd0909 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field36C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field36C.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -456,6 +454,7 @@ public Field36C setCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -466,6 +465,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -480,6 +480,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field36D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field36D.java index bf67bcc50..d1da5f905 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field36D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field36D.java @@ -238,11 +238,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -592,6 +590,7 @@ public Field36D setQuantityOfDigitalTokens(java.lang.Number component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -602,6 +601,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -616,6 +616,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field36E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field36E.java index 5a88c4c86..7758be746 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field36E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field36E.java @@ -260,14 +260,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -731,6 +730,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -742,6 +742,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -752,6 +753,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -766,6 +768,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37A.java index 0e35ebc55..ecef06e25 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37A.java @@ -307,11 +307,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -1033,6 +1031,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -1042,6 +1041,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37B.java index 1b35137a6..e55566c00 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37B.java @@ -307,11 +307,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -1033,6 +1031,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -1042,6 +1041,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37C.java index eed0ce5c6..b0b1d7b69 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37C.java @@ -307,11 +307,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -1033,6 +1031,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -1042,6 +1041,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37D.java index df6c87535..adc3b7a3f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37D.java @@ -307,11 +307,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -1033,6 +1031,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -1042,6 +1041,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37E.java index 421966208..d853e42cb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37E.java @@ -307,11 +307,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -1033,6 +1031,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -1042,6 +1041,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37F.java index 2296a90a7..aa23c92b2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37F.java @@ -307,11 +307,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -1033,6 +1031,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -1042,6 +1041,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37G.java index 325479aa6..80dd727a6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37G.java @@ -222,14 +222,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -554,6 +553,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37H.java index 163cb786c..9bc97bbc5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37H.java @@ -247,14 +247,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -641,6 +640,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37J.java index 7feb13a77..32650eaa8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37J.java @@ -211,14 +211,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 37J"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -500,6 +498,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37K.java index 2849420d5..cc24e8767 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37K.java @@ -222,14 +222,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -551,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37L.java index ecb77fe00..0bcca293d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37L.java @@ -211,14 +211,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 37L"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -500,6 +498,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37M.java index 0aa230a71..35d78d146 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37M.java @@ -222,14 +222,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -554,6 +553,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37N.java index 6e470068b..772594304 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37N.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field37N cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field37N cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field37N cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37P.java index d919c78dd..621b2d687 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37P.java @@ -211,14 +211,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 37P"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -500,6 +498,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37R.java index 70f343140..6fd985de6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37R.java @@ -222,14 +222,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -554,6 +553,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37U.java index bba256fde..c9b426f1b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37U.java @@ -211,14 +211,12 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 37U"); } - if (component == 1) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent1AsBigDecimal(); - if (n != null) { - return f.format(n); - } + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent1AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -500,6 +498,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field37V.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field37V.java index c2c8720e6..b3923f6b3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field37V.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field37V.java @@ -222,14 +222,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -554,6 +553,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field38A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field38A.java index 4b7f52689..8e759d35f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field38A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field38A.java @@ -216,11 +216,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 38A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field38D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field38D.java index efbc5d01c..52f177cae 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field38D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field38D.java @@ -216,11 +216,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 38D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field38E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field38E.java index c3cb76136..b05fbb10e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field38E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field38E.java @@ -220,11 +220,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field38G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field38G.java index 0f28261ed..326e51cba 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field38G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field38G.java @@ -247,11 +247,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field38H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field38H.java index 09b70356a..2d5c53ef2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field38H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field38H.java @@ -247,11 +247,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field38J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field38J.java index 8890c1e5d..0c6e7625a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field38J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field38J.java @@ -227,11 +227,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field39A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field39A.java index aab4bf5fa..b9205cb04 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field39A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field39A.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field39B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field39B.java index d56a1268b..ab6ed07ee 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field39B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field39B.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 39B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field39C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field39C.java index 554fc66e6..5145aed58 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field39C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field39C.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field39C cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field39C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field39C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field39D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field39D.java index a06f6bbd7..e5668b164 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field39D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field39D.java @@ -264,11 +264,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(11); } - if (component == 12) { - //default format (as is) - return getComponent(12); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(12); } /** @@ -1015,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1028,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field39D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1040,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1052,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field39D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1066,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1080,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field39D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field39E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field39E.java index 6f90596b6..fe5ff74be 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field39E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field39E.java @@ -264,11 +264,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(11); } - if (component == 12) { - //default format (as is) - return getComponent(12); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(12); } /** @@ -1015,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1028,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field39E cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1040,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1052,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field39E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1066,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1080,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field39E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field39F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field39F.java index 8975653a4..8d75d6a84 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field39F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field39F.java @@ -264,11 +264,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(11); } - if (component == 12) { - //default format (as is) - return getComponent(12); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(12); } /** @@ -1015,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1028,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field39F cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1040,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1052,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field39F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1066,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1080,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field39F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field39M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field39M.java index 3a73372bf..f8968db56 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field39M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field39M.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 39M"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field401.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field401.java index 1379fea9f..8f33387d4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field401.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field401.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 401"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field405.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field405.java index a07f1b24c..76cd2919a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field405.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field405.java @@ -226,11 +226,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field40A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field40A.java index b15f65db4..2684615df 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field40A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field40A.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 40A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field40B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field40B.java index 3c222e837..8ef65100e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field40B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field40B.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -502,6 +500,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -515,6 +514,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field40B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -527,6 +527,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -539,6 +540,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field40B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -553,6 +555,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -567,6 +570,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field40B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field40C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field40C.java index 6c0d25bf1..8fa0cc890 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field40C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field40C.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field40D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field40D.java index 7f30c6e00..851228a06 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field40D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field40D.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 40D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field40E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field40E.java index 27392d682..13a7db646 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field40E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field40E.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field40F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field40F.java index 8bd350507..458283634 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field40F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field40F.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 40F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field41A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field41A.java index 5ea37223d..1b75e8e20 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field41A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field41A.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -512,10 +510,12 @@ public Field41A setCode(String component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -600,6 +600,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -613,6 +614,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field41A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -625,6 +627,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -637,6 +640,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field41A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -651,6 +655,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -665,6 +670,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field41A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field41D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field41D.java index 9bb722549..410cf9fc7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field41D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field41D.java @@ -252,11 +252,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -699,6 +697,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -712,6 +711,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field41D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -724,6 +724,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -736,6 +737,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field41D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -750,6 +752,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -764,6 +767,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field41D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field41F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field41F.java index f1ec3a679..f38e20bf4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field41F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field41F.java @@ -217,11 +217,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 41F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -455,10 +452,12 @@ public Field41F setBIC(com.prowidesoftware.swift.model.BIC component1) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field41G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field41G.java index 6294d4005..99589de87 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field41G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field41G.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field41G cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field41G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field41G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field421.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field421.java index c51e79ebe..7a63656e5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field421.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field421.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 421"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field422.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field422.java index a7fe2259e..0e531c68b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field422.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field422.java @@ -345,11 +345,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(23); } - if (component == 24) { - //default format (as is) - return getComponent(24); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(24); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field423.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field423.java index 0986f40f7..8b26fd7cc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field423.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field423.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 423"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field424.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field424.java index 740baa586..c2f248cc1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field424.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field424.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 424"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field425.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field425.java index efeedaf89..c56b727a3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field425.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field425.java @@ -425,11 +425,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(39); } - if (component == 40) { - //default format (as is) - return getComponent(40); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(40); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field42A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field42A.java index 76df94cd5..a4b508324 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field42A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field42A.java @@ -260,10 +260,12 @@ public Field42A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field42A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field42A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field42A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field42C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field42C.java index 29b762f8b..683e768c7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field42C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field42C.java @@ -219,11 +219,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -583,6 +581,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -596,6 +595,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field42C cp = newInstance(this); return getLine(cp, line, null, offset); @@ -608,6 +608,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -620,6 +621,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field42C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -634,6 +636,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -648,6 +651,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field42C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field42D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field42D.java index 2516dc0fc..906643fa2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field42D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field42D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field42D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field42D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field42D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field42M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field42M.java index 8424c9527..70493fb15 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field42M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field42M.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field42M cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field42M cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field42M cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field42P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field42P.java index 9bedbd460..42450ea7f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field42P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field42P.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field42P cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field42P cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field42P cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field431.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field431.java index e88655051..fbdba4187 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field431.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field431.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 431"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field432.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field432.java index c071f5e53..d3bb4528f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field432.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field432.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 432"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field433.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field433.java index af2f21b17..edb24d36e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field433.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field433.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field434.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field434.java index a60bb3871..c8d1dcaa2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field434.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field434.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field43P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field43P.java index 0e079d530..8f9cb0bdc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field43P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field43P.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 43P"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field43T.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field43T.java index 0e8c879f1..078e53acd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field43T.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field43T.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 43T"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field443.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field443.java index 424a54ce7..7b7169667 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field443.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field443.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 443"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44A.java index 38cdf3209..532e3e800 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44A.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 44A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44B.java index 2153afa9d..4752256bb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44B.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 44B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44C.java index 55c985511..4dbbec3a3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44C.java @@ -210,13 +210,11 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 44C"); } - if (component == 1) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -417,6 +415,7 @@ public Field44C setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44D.java index cf8b655d1..cc66dc87a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44D.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -727,6 +725,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -740,6 +739,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field44D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -752,6 +752,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -764,6 +765,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field44D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -778,6 +780,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -792,6 +795,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field44D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44E.java index 956823863..cc3f2308a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44E.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 44E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44F.java index 26de2e6a2..f8ea91bc9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44F.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 44F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44H.java index 7a7eb8269..30826bbb5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44H.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field44J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field44J.java index 124fc584a..3f29a3ce6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field44J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field44J.java @@ -240,11 +240,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -564,6 +562,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -577,6 +576,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field44J cp = newInstance(this); return getLine(cp, line, null, offset); @@ -589,6 +589,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -601,6 +602,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field44J cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -615,6 +617,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -629,6 +632,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field44J cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field451.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field451.java index 01eaad9aa..21806cbde 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field451.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field451.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 451"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field45A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field45A.java index 47b3af0c7..41f2eae60 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field45A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field45A.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 45A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field45A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field45A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field45A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field45B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field45B.java index 1cdde4914..a361c935b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field45B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field45B.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field45B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field45B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field45B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field45C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field45C.java index 228a146e8..315f5e58e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field45C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field45C.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 45C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field45C cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field45C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field45C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field45D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field45D.java index 9d5ea971a..9425899b7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field45D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field45D.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 45D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field45D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field45D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field45D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field45L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field45L.java index 0ef232305..6e0bbb44f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field45L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field45L.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 45L"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field45L cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field45L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field45L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field461.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field461.java index 89740b168..9b36de5fc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field461.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field461.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 461"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field46A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field46A.java index 79792e46c..2cc29d084 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field46A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field46A.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 46A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field46A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field46A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field46A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field46B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field46B.java index bf50f28cd..cae70ef0d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field46B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field46B.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field46B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field46B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field46B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field47A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field47A.java index 88c5ba6d2..9a4fc890c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field47A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field47A.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 47A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field47A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field47A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field47A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field47B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field47B.java index 328d08f14..7d9fd06b5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field47B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field47B.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field47B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field47B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field47B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field48.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field48.java index 865220412..e646424c9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field48.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field48.java @@ -223,11 +223,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field48B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field48B.java index c0ca779ce..a003d0551 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field48B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field48B.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 48B"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field48D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field48D.java index 651430cc9..52b8dd8cb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field48D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field48D.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 48D"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field49.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field49.java index 910a7583f..bea8e701f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field49.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field49.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field49A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field49A.java index 3e952a872..2e76b2250 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field49A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field49A.java @@ -235,11 +235,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -538,6 +536,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -551,6 +550,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -563,6 +563,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -575,6 +576,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -589,6 +591,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -603,6 +606,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field49G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field49G.java index c3d814326..e1a3cf6b8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field49G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field49G.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49G"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49G cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field49H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field49H.java index 4257791ff..7090bf288 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field49H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field49H.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49H"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49H cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49H cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49H cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field49M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field49M.java index a752efa5c..f04f6952a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field49M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field49M.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49M cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49M cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49M cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field49N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field49N.java index 52231fb37..c1eeb35ea 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field49N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field49N.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49N cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49N cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49N cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50.java index 6c2823416..36d404155 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field503.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field503.java index fc0c4da5a..39ce71a22 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field503.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field503.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 503"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50A.java index 65e1aa9ee..c6ee36b0d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50A.java @@ -239,11 +239,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -529,10 +527,12 @@ public Field50A setBIC(com.prowidesoftware.swift.model.BIC component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -617,6 +617,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -630,6 +631,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -642,6 +644,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -654,6 +657,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -668,6 +672,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -682,6 +687,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50B.java index bb3345175..1d816055f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50B.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50C.java index 45b3aa7b5..e356816e6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50C.java @@ -217,11 +217,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 50C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -455,10 +452,12 @@ public Field50C setBIC(com.prowidesoftware.swift.model.BIC component1) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50D.java index cd788f6c8..3f601923f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50F.java index 0e0fb5267..611fc7a37 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50F.java @@ -305,9 +305,8 @@ public String getValueDisplay(int component, Locale locale) { //special case for party identifier in field 50F if (StringUtils.startsWith(getComponent(1), "/")) { return getComponent(1).substring(1); - } else { - return getComponent(1); } + return getComponent(1); } if (component == 2) { //default format (as is) @@ -337,11 +336,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(8); } - if (component == 9) { - //default format (as is) - return getComponent(9); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(9); } /** @@ -1349,6 +1346,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1362,6 +1360,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50F cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1374,6 +1373,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1386,6 +1386,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1400,6 +1401,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1414,6 +1416,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50G.java index 22937f4c4..263e02bf8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50G.java @@ -238,10 +238,12 @@ public Field50G setBIC(com.prowidesoftware.swift.model.BIC component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -326,6 +328,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -339,6 +342,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50G cp = newInstance(this); return getLine(cp, line, null, offset); @@ -351,6 +355,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -363,6 +368,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -377,6 +383,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -391,6 +398,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50H.java index a550a2fdd..d58909ce9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50H.java @@ -352,6 +352,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -365,6 +366,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50H cp = newInstance(this); return getLine(cp, line, null, offset); @@ -377,6 +379,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -389,6 +392,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50H cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -403,6 +407,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -417,6 +422,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50H cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field50K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field50K.java index 6d6f97111..e77072c5a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field50K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field50K.java @@ -352,6 +352,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -365,6 +366,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field50K cp = newInstance(this); return getLine(cp, line, null, offset); @@ -377,6 +379,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -389,6 +392,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field50K cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -403,6 +407,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -417,6 +422,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field50K cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field51.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field51.java index 06d4e5d08..d0a12ef4d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field51.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field51.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -631,6 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +643,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field51 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +656,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +669,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field51 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +684,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +699,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field51 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field51A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field51A.java index d8c8c4a86..6e6981156 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field51A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field51A.java @@ -260,10 +260,12 @@ public Field51A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field51A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field51A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field51A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field51D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field51D.java index 3ceb4e28d..a199e857d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field51D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field51D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field51D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field51D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field51D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field52A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field52A.java index e579c9a00..3f5067e0b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field52A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field52A.java @@ -260,10 +260,12 @@ public Field52A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field52A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field52A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field52A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field52B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field52B.java index 026dcbdc1..24961836b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field52B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field52B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field52B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field52B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field52B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field52D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field52D.java index 78ddd0d8d..482a3b112 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field52D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field52D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field52D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field52D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field52D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field533.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field533.java index 641346683..01c18da4e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field533.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field533.java @@ -209,11 +209,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 533"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field53A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field53A.java index 4eff152c0..420933084 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field53A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field53A.java @@ -260,10 +260,12 @@ public Field53A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field53A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field53A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field53A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field53B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field53B.java index ff280b6d3..86eaa1f56 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field53B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field53B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field53B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field53B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field53B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field53D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field53D.java index 0a935f910..85d97a3c1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field53D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field53D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field53D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field53D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field53D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field54A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field54A.java index 0fc2bbcd5..2752eca5e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field54A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field54A.java @@ -260,10 +260,12 @@ public Field54A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field54A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field54A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field54A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field54B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field54B.java index 5ad813ee5..cf317a2ae 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field54B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field54B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field54B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field54B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field54B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field54D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field54D.java index 81086988f..3ed7689e9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field54D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field54D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field54D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field54D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field54D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field55A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field55A.java index c5a42b275..a821bf3d3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field55A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field55A.java @@ -260,10 +260,12 @@ public Field55A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field55A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field55A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field55A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field55B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field55B.java index 6fcbbf0dd..40779699f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field55B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field55B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field55B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field55B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field55B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field55D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field55D.java index 0b6ba4254..e8dfd5e3f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field55D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field55D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field55D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field55D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field55D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field56A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field56A.java index 236490b71..f89beb987 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field56A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field56A.java @@ -260,10 +260,12 @@ public Field56A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field56A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field56A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field56A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field56B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field56B.java index a313f0190..2ba2a8679 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field56B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field56B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field56B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field56B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field56B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field56D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field56D.java index b00c8239a..10dcf1ecc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field56D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field56D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field56D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field56D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field56D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field57A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field57A.java index ce2769619..acc3d706c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field57A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field57A.java @@ -260,10 +260,12 @@ public Field57A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field57A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field57A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field57A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field57B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field57B.java index a65477f37..df469eda3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field57B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field57B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field57B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field57B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field57B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field57D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field57D.java index eb9e6df7d..f7f55c87f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field57D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field57D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field57D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field57D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field57D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field58A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field58A.java index 409c421b1..4814f58a6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field58A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field58A.java @@ -260,10 +260,12 @@ public Field58A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field58A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field58A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field58A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field58B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field58B.java index d689fbe75..7430a114e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field58B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field58B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field58B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field58B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field58B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field58D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field58D.java index 14951fd50..1a79e539b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field58D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field58D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field58D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field58D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field58D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field59.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field59.java index befe8afd7..87bee7b2b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field59.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field59.java @@ -244,11 +244,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -703,6 +701,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -716,6 +715,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field59 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -728,6 +728,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -740,6 +741,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field59 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -754,6 +756,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -768,6 +771,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field59 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field59A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field59A.java index 507aeb355..905ee816b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field59A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field59A.java @@ -239,11 +239,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -529,10 +527,12 @@ public Field59A setBIC(com.prowidesoftware.swift.model.BIC component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -617,6 +617,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -630,6 +631,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field59A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -642,6 +644,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -654,6 +657,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field59A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -668,6 +672,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -682,6 +687,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field59A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field59F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field59F.java index 432a51960..055c91c1f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field59F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field59F.java @@ -312,11 +312,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(8); } - if (component == 9) { - //default format (as is) - return getComponent(9); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(9); } /** @@ -1336,6 +1334,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1349,6 +1348,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field59F cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1361,6 +1361,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1373,6 +1374,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field59F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1387,6 +1389,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1401,6 +1404,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field59F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field60F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field60F.java index 7e567cc90..6c8e464cb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field60F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field60F.java @@ -260,14 +260,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -766,26 +765,32 @@ public Field60F setAmount(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -806,6 +811,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -815,6 +821,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field60M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field60M.java index dfba3322b..b65c02662 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field60M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field60M.java @@ -260,14 +260,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -766,26 +765,32 @@ public Field60M setAmount(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -806,6 +811,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -815,6 +821,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field61.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field61.java index 36abfe6ad..a6635381a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field61.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field61.java @@ -348,11 +348,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(9); } - if (component == 10) { - //default format (as is) - return getComponent(10); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(10); } /** @@ -1139,6 +1137,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -1149,6 +1148,7 @@ public BigDecimal amount() { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } @@ -1243,6 +1243,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1256,6 +1257,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field61 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1268,6 +1270,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1280,6 +1283,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field61 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1294,6 +1298,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1308,6 +1313,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field61 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field619.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field619.java index 4832286ff..bebaa19d0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field619.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field619.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 619"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field62F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field62F.java index bb39b8db4..20556dea6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field62F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field62F.java @@ -259,14 +259,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -726,6 +725,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -735,6 +735,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field62M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field62M.java index 695e100a2..d3b53489b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field62M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field62M.java @@ -259,14 +259,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -726,6 +725,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -735,6 +735,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field64.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field64.java index 1dbed86fc..bf8772020 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field64.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field64.java @@ -259,14 +259,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -726,6 +725,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -735,6 +735,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field65.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field65.java index 7d547734f..f4b9b0882 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field65.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field65.java @@ -259,14 +259,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -726,6 +725,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -735,6 +735,7 @@ public BigDecimal amount() { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field68A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field68A.java index 04c645864..d4bd6e464 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field68A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field68A.java @@ -285,11 +285,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(n); } } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -1126,26 +1124,32 @@ public Field68A setProductCode(String component6) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -1166,6 +1170,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field69A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field69A.java index 0e34413a5..9647f05d6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field69A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field69A.java @@ -243,13 +243,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent3AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent3AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -570,6 +569,7 @@ public Field69A setDate2(java.util.Calendar component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -590,6 +590,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -600,6 +601,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -614,6 +616,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field69B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field69B.java index bd15b1f32..37724c9bf 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field69B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field69B.java @@ -317,13 +317,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 5) { - //time with seconds: HHmmss - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); - java.util.Calendar cal = getComponent5AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time with seconds: HHmmss + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); + java.util.Calendar cal = getComponent5AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -964,6 +963,7 @@ public Field69B setEndTime(java.util.Calendar component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -984,6 +984,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -994,6 +995,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -1008,6 +1010,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field69C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field69C.java index 001fd38cb..ba13e2917 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field69C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field69C.java @@ -243,11 +243,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -526,6 +524,7 @@ public Field69C setDateCode(String component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -546,6 +545,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -556,6 +556,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -570,6 +571,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field69D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field69D.java index bbd1ca642..c195467d5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field69D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field69D.java @@ -266,11 +266,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -629,6 +627,7 @@ public Field69D setDateCode(String component4) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -649,6 +648,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -659,6 +659,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -673,6 +674,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field69E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field69E.java index 94dbfc9fb..5fa73721b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field69E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field69E.java @@ -246,13 +246,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent3AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent3AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -555,6 +554,7 @@ public Field69E setDate(java.util.Calendar component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -575,6 +575,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -585,6 +586,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -599,6 +601,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field69F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field69F.java index aeb4ce6e9..39212a06c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field69F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field69F.java @@ -269,13 +269,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 4) { - //time with seconds: HHmmss - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); - java.util.Calendar cal = getComponent4AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time with seconds: HHmmss + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); + java.util.Calendar cal = getComponent4AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -658,6 +657,7 @@ public Field69F setTime(java.util.Calendar component4) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -678,6 +678,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -688,6 +689,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -702,6 +704,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field69J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field69J.java index 426cc2283..6b2a6fa85 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field69J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field69J.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -456,6 +454,7 @@ public Field69J setCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -466,6 +465,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -480,6 +480,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field70.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field70.java index b89d25dfd..5b779974d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field70.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field70.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field70 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field70 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field70 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field70C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field70C.java index 65e0b9563..44b71abe7 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field70C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field70C.java @@ -243,11 +243,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -617,6 +615,7 @@ public Field70C setNarrativeLine4(String component5) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -627,6 +626,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -641,6 +641,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -724,6 +725,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -737,6 +739,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field70C cp = newInstance(this); return getLine(cp, line, null, offset); @@ -749,6 +752,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -761,6 +765,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field70C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -775,6 +780,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -789,6 +795,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field70C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field70D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field70D.java index 10b85a72c..5b212374c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field70D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field70D.java @@ -253,11 +253,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(6); } - if (component == 7) { - //default format (as is) - return getComponent(7); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(7); } /** @@ -713,6 +711,7 @@ public Field70D setNarrativeLine6(String component7) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -723,6 +722,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -737,6 +737,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -820,6 +821,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -833,6 +835,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field70D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -845,6 +848,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -857,6 +861,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field70D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -871,6 +876,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -885,6 +891,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field70D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field70E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field70E.java index 5cfe0f7e4..c150baf2b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field70E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field70E.java @@ -273,11 +273,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(10); } - if (component == 11) { - //default format (as is) - return getComponent(11); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(11); } /** @@ -905,6 +903,7 @@ public Field70E setNarrativeLine10(String component11) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -915,6 +914,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -929,6 +929,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -1012,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1025,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field70E cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1037,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1049,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field70E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1063,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1077,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field70E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field70F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field70F.java index 0f5065ec3..02424dba1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field70F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field70F.java @@ -223,11 +223,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -428,6 +426,7 @@ public Field70F setNarrative(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -438,6 +437,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -452,6 +452,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -535,6 +536,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -548,6 +550,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field70F cp = newInstance(this); return getLine(cp, line, null, offset); @@ -560,6 +563,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -572,6 +576,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field70F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -586,6 +591,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -600,6 +606,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field70F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field70G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field70G.java index f2e83c301..37ac72a03 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field70G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field70G.java @@ -273,11 +273,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(10); } - if (component == 11) { - //default format (as is) - return getComponent(11); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(11); } /** @@ -905,6 +903,7 @@ public Field70G setNarrativeLine10(String component11) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -915,6 +914,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -929,6 +929,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -1012,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1025,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field70G cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1037,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1049,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field70G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1063,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1077,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field70G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field70H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field70H.java index ab30145f1..a513ca06c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field70H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field70H.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field70H setNarrative(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field71A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field71A.java index 24ccf8f87..8e1e90add 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field71A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field71A.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 71A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field71B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field71B.java index aa289a6f1..5bd243bc6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field71B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field71B.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field71B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field71B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field71B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field71C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field71C.java index 4e94d90b3..61ee5025f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field71C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field71C.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -727,6 +725,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -740,6 +739,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field71C cp = newInstance(this); return getLine(cp, line, null, offset); @@ -752,6 +752,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -764,6 +765,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field71C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -778,6 +780,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -792,6 +795,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field71C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field71D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field71D.java index 2cee5ddcf..0a924371d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field71D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field71D.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field71D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field71D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field71D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field71F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field71F.java index be91790d3..07c301351 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field71F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field71F.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field71F setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field71G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field71G.java index dd43678a2..a9425d433 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field71G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field71G.java @@ -223,14 +223,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -576,26 +575,32 @@ public Field71G setAmount(java.lang.Number component2) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -616,6 +621,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field71N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field71N.java index a91e4fa09..cd3432574 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field71N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field71N.java @@ -244,11 +244,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(6); } - if (component == 7) { - //default format (as is) - return getComponent(7); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(7); } /** @@ -780,6 +778,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -793,6 +792,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field71N cp = newInstance(this); return getLine(cp, line, null, offset); @@ -805,6 +805,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -817,6 +818,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field71N cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -831,6 +833,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -845,6 +848,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field71N cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field72.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field72.java index 389a667b5..b784d747b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field72.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field72.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field72 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field72 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field72 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field72Z.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field72Z.java index 8d73b5b10..1733d1b30 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field72Z.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field72Z.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field72Z cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field72Z cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field72Z cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field73.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field73.java index 637d2e520..edc31fd34 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field73.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field73.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field73 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field73 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field73 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field73A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field73A.java index 5b228b6ed..ddda8b8b8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field73A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field73A.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field73A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field73A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field73A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field73R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field73R.java index e6d8e956c..fe8417343 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field73R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field73R.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field73S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field73S.java index 3ad921cd8..125e8753d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field73S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field73S.java @@ -221,11 +221,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field74.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field74.java index 7b9b7e224..0400b41b3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field74.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field74.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field74 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field74 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field74 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field75.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field75.java index 15b082fc9..755ae033f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field75.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field75.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field75 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field75 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field75 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field76.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field76.java index 843692483..0eac88954 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field76.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field76.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field76 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field76 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field76 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77.java index fb4ec9171..3f8b8f4dd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77A.java index 5debf4a7c..edacfc210 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77A.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77B.java index 8ecf20e63..8eab07260 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77B.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77C.java index 09b89264a..17f5fe4bc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77C.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 77C"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77C cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77D.java index 1f4f5bba2..c1e94615d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77D.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77E.java index 4d13fe3b6..272f8e1fb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77E.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 77E"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77E cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77F.java index dfb3958bc..8c3cac7e8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77F.java @@ -215,11 +215,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 77F"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -475,6 +472,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -488,6 +486,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77F cp = newInstance(this); return getLine(cp, line, null, offset); @@ -500,6 +499,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -512,6 +512,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -526,6 +527,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -540,6 +542,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77H.java index b4598a097..8bc148f0a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77H.java @@ -249,11 +249,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -597,6 +595,7 @@ public Field77H setVersion(java.util.Calendar component3) { * @return the list of converted components (a Calendar object or null) * @since 9.2.7 */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77J.java index fe97bae31..0712e9b91 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77J.java @@ -262,6 +262,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -275,6 +276,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77J cp = newInstance(this); return getLine(cp, line, null, offset); @@ -287,6 +289,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -299,6 +302,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77J cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -313,6 +317,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -327,6 +332,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77J cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77L.java index f463ae2a8..e5158589c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77L.java @@ -215,11 +215,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 77L"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -475,6 +472,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -488,6 +486,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77L cp = newInstance(this); return getLine(cp, line, null, offset); @@ -500,6 +499,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -512,6 +512,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -526,6 +527,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -540,6 +542,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77T.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77T.java index 784c98739..dbc2f0943 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77T.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77T.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 77T"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77T cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77T cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77T cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field77U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field77U.java index 68271de53..78d32ac0c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field77U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field77U.java @@ -208,11 +208,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 77U"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** @@ -446,6 +443,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -459,6 +457,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field77U cp = newInstance(this); return getLine(cp, line, null, offset); @@ -471,6 +470,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -483,6 +483,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field77U cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -497,6 +498,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -511,6 +513,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field77U cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field78.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field78.java index 78b83bbd6..01823425a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field78.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field78.java @@ -264,11 +264,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(11); } - if (component == 12) { - //default format (as is) - return getComponent(12); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(12); } /** @@ -1015,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1028,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field78 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1040,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1052,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field78 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1066,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1080,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field78 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field78D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field78D.java index deb151607..bb724b2c6 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field78D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field78D.java @@ -264,11 +264,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(11); } - if (component == 12) { - //default format (as is) - return getComponent(12); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(12); } /** @@ -1015,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1028,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field78D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1040,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1052,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field78D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1066,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1080,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field78D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field79.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field79.java index fc45061cd..2ca0e872f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field79.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field79.java @@ -379,11 +379,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(34); } - if (component == 35) { - //default format (as is) - return getComponent(35); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(35); } /** @@ -2119,6 +2117,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -2132,6 +2131,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field79 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -2144,6 +2144,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -2156,6 +2157,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field79 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -2170,6 +2172,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -2184,6 +2187,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field79 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field79Z.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field79Z.java index 17af1e60f..dea6fa523 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field79Z.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field79Z.java @@ -379,11 +379,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(34); } - if (component == 35) { - //default format (as is) - return getComponent(35); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(35); } /** @@ -2119,6 +2117,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -2132,6 +2131,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field79Z cp = newInstance(this); return getLine(cp, line, null, offset); @@ -2144,6 +2144,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -2156,6 +2157,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field79Z cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -2170,6 +2172,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -2184,6 +2187,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field79Z cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field80C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field80C.java index 830443ece..8c1c5b489 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field80C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field80C.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -727,6 +725,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -740,6 +739,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field80C cp = newInstance(this); return getLine(cp, line, null, offset); @@ -752,6 +752,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -764,6 +765,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field80C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -778,6 +780,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -792,6 +795,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field80C cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field81A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field81A.java index c962c1930..a690ad248 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field81A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field81A.java @@ -260,10 +260,12 @@ public Field81A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field81A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field81A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field81A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field81D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field81D.java index fd4fcffd1..08b350bb3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field81D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field81D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field81D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field81D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field81D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field82A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field82A.java index a8b042236..412b36422 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field82A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field82A.java @@ -260,10 +260,12 @@ public Field82A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field82A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field82A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field82A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field82B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field82B.java index 1ff0a046e..3809d9c2d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field82B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field82B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field82B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field82B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field82B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field82D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field82D.java index dc3cd6c41..cbfaaa8bd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field82D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field82D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field82D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field82D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field82D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field83A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field83A.java index c7b953a32..99e1e2128 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field83A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field83A.java @@ -260,10 +260,12 @@ public Field83A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field83A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field83A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field83A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field83D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field83D.java index d593e489c..518d0ead9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field83D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field83D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field83D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field83D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field83D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field84A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field84A.java index 75184cb8e..f20147cc9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field84A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field84A.java @@ -260,10 +260,12 @@ public Field84A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field84A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field84A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field84A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field84B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field84B.java index 342936659..62c441cce 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field84B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field84B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field84B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field84B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field84B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field84D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field84D.java index bcc3436ec..d675b11cc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field84D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field84D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field84D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field84D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field84D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field85A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field85A.java index 5c9ac0a40..fdf032273 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field85A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field85A.java @@ -260,10 +260,12 @@ public Field85A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field85A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field85A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field85A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field85B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field85B.java index 8301f4966..a3027d504 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field85B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field85B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field85B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field85B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field85B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field85D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field85D.java index 886c3b113..da8d50553 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field85D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field85D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field85D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field85D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field85D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field86.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field86.java index fec1b8b4b..321883c50 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field86.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field86.java @@ -234,11 +234,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -727,6 +725,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -740,6 +739,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field86 cp = newInstance(this); return getLine(cp, line, null, offset); @@ -752,6 +752,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -764,6 +765,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field86 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -778,6 +780,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -792,6 +795,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field86 cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field86A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field86A.java index a8c1f5b98..981777e0d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field86A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field86A.java @@ -260,10 +260,12 @@ public Field86A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field86A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field86A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field86A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field86B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field86B.java index 817521b91..0f9846d5f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field86B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field86B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field86B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field86B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field86B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field86D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field86D.java index 5e8964394..54b5ac19c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field86D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field86D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field86D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field86D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field86D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field87A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field87A.java index 4cba226a0..a4408c919 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field87A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field87A.java @@ -260,10 +260,12 @@ public Field87A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field87A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field87A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field87A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field87B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field87B.java index a6acced22..a68b30bb2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field87B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field87B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field87B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field87B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field87B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field87D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field87D.java index b7b31e969..360dd9edd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field87D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field87D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field87D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field87D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field87D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field88A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field88A.java index d52eaa6a5..90a36b4d9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field88A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field88A.java @@ -260,10 +260,12 @@ public Field88A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field88A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field88A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field88A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field88B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field88B.java index 56d12c950..c8dbc95b9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field88B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field88B.java @@ -296,6 +296,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -309,6 +310,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field88B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -321,6 +323,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -333,6 +336,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field88B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -347,6 +351,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -361,6 +366,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field88B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field88D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field88D.java index 4463ea043..aec97c2c9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field88D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field88D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field88D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field88D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field88D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field89A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field89A.java index 8f83f65df..5d4f89d82 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field89A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field89A.java @@ -260,10 +260,12 @@ public Field89A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field89A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field89A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field89A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field89D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field89D.java index acc5e414f..a99b193c0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field89D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field89D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field89D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field89D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field89D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90A.java index e72d48d77..68d0480dc 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90A.java @@ -253,14 +253,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -665,6 +664,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -676,6 +676,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -686,6 +687,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -700,6 +702,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90B.java index 56e778806..9b34108ec 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90B.java @@ -260,14 +260,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -733,26 +732,32 @@ public Field90B setPrice(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -773,6 +778,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -784,6 +790,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -794,6 +801,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -808,6 +816,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90C.java index 862eb1740..95ee974f2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90C.java @@ -235,14 +235,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -737,26 +736,32 @@ public Field90C setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -777,6 +782,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90D.java index ba47c06d4..243c35c4b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90D.java @@ -235,14 +235,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -737,26 +736,32 @@ public Field90D setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -777,6 +782,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90E.java index 170b5df6c..719968f9c 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90E.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -456,6 +454,7 @@ public Field90E setCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -466,6 +465,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -480,6 +480,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90F.java index d6366153d..761ec779a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90F.java @@ -294,14 +294,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent6AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent6AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -957,26 +956,32 @@ public Field90F setQuantity(java.lang.Number component6) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -997,6 +1002,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -1008,6 +1014,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -1018,6 +1025,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -1032,6 +1040,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90J.java index 870b79dbe..ca2adcde5 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90J.java @@ -307,14 +307,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent6AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent6AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -1072,26 +1071,32 @@ public Field90J setAmount2(java.lang.Number component6) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -1112,6 +1117,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -1123,6 +1129,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -1133,6 +1140,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -1147,6 +1155,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90K.java index ef90d5063..a66f49dae 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90K.java @@ -233,14 +233,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -621,6 +620,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -632,6 +632,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -642,6 +643,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -656,6 +658,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field90L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field90L.java index 1bea2df74..b37bc07df 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field90L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field90L.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -677,6 +676,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -688,6 +688,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -698,6 +699,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -712,6 +714,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field91A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field91A.java index df5cfbedd..884d4a4af 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field91A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field91A.java @@ -260,10 +260,12 @@ public Field91A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field91A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field91A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field91A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field91D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field91D.java index cea066115..81788840a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field91D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field91D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field91D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field91D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field91D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92A.java index 664e5a9e3..6117885fd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92A.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -677,6 +676,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -688,6 +688,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -698,6 +699,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -712,6 +714,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92B.java index 8f0b6e8b5..b2d2af044 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92B.java @@ -254,14 +254,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -727,26 +726,32 @@ public Field92B setRate(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -767,6 +772,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -778,6 +784,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -788,6 +795,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -802,6 +810,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92C.java index 36cd1443a..86af3f943 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92C.java @@ -242,11 +242,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -512,6 +510,7 @@ public Field92C setCode(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -522,6 +521,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -536,6 +536,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92D.java index 24036a597..2057f3528 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92D.java @@ -245,14 +245,13 @@ public String getValueDisplay(int component, Locale locale) { return f.format(n); } } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -724,6 +723,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -735,6 +735,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -745,6 +746,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -759,6 +761,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92F.java index b59240bc2..735ba4a9d 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92F.java @@ -247,14 +247,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -680,26 +679,32 @@ public Field92F setAmount(java.lang.Number component3) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -720,6 +725,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -731,6 +737,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -741,6 +748,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -755,6 +763,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92H.java index d0532238a..977bda8fd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92H.java @@ -266,11 +266,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(n); } } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -734,26 +732,32 @@ public Field92H setRateStatus(String component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -774,6 +778,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -785,6 +790,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -795,6 +801,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -809,6 +816,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92J.java index 0c1ce015f..7e976606e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92J.java @@ -300,11 +300,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(n); } } - if (component == 6) { - //default format (as is) - return getComponent(6); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(6); } /** @@ -876,26 +874,32 @@ public Field92J setRateStatus(String component6) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -916,6 +920,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -927,6 +932,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -937,6 +943,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -951,6 +958,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92K.java index a91d51391..ba0d0ef15 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92K.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field92K setRateTypeCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92L.java index dda5dd6dc..f303689f3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92L.java @@ -286,14 +286,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent5AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent5AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -989,26 +988,32 @@ public Field92L setAmount2(java.lang.Number component5) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -1029,6 +1034,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -1040,6 +1046,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -1050,6 +1057,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -1064,6 +1072,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92M.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92M.java index 0396235ff..3f030a929 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92M.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92M.java @@ -266,14 +266,13 @@ public String getValueDisplay(int component, Locale locale) { return f.format(n); } } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -849,26 +848,32 @@ public Field92M setQuantity(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -889,6 +894,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -900,6 +906,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -910,6 +917,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -924,6 +932,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92N.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92N.java index 69a41ae98..bd4ed0383 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92N.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92N.java @@ -265,14 +265,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -848,26 +847,32 @@ public Field92N setAmount(java.lang.Number component4) { } + @Override public List currencyStrings() { return MonetaryAmountResolver.currencyStrings(this); } + @Override public List currencies() { return MonetaryAmountResolver.currencies(this); } + @Override public Currency currency() { return MonetaryAmountResolver.resolveCurrency(this); } + @Override public String currencyString() { return MonetaryAmountResolver.resolveCurrencyString(this); } + @Override public void initializeCurrencies(String cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } + @Override public void initializeCurrencies(Currency cur) { MonetaryAmountResolver.resolveSetCurrency(this, cur); } @@ -888,6 +893,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see MonetaryAmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return MonetaryAmountResolver.amount(this); } @@ -899,6 +905,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -909,6 +916,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -923,6 +931,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92P.java index ae6f6e9f6..60380c5a9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92P.java @@ -233,14 +233,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -621,6 +620,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -632,6 +632,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -642,6 +643,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -656,6 +658,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field92R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field92R.java index fa0e742c2..edec58b04 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field92R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field92R.java @@ -266,14 +266,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent4AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent4AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -759,6 +758,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -770,6 +770,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -780,6 +781,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -794,6 +796,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field93A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field93A.java index 2bd8d40df..22e305bd0 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field93A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field93A.java @@ -242,11 +242,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -512,6 +510,7 @@ public Field93A setCode(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -522,6 +521,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -536,6 +536,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field93B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field93B.java index b625c8678..a2b92f623 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field93B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field93B.java @@ -273,14 +273,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent5AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent5AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -787,6 +786,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -798,6 +798,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -808,6 +809,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -822,6 +824,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field93C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field93C.java index 2a7da1c44..586f3bdf2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field93C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field93C.java @@ -273,14 +273,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent5AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent5AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -784,6 +783,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -795,6 +795,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -805,6 +806,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -819,6 +821,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field93D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field93D.java index 017758731..623a8b7fd 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field93D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field93D.java @@ -246,14 +246,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent3AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent3AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -677,6 +676,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -688,6 +688,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -698,6 +699,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -712,6 +714,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field93E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field93E.java index 2ab8039df..64f1ed03f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field93E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field93E.java @@ -266,14 +266,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent5AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent5AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -718,6 +717,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -729,6 +729,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -739,6 +740,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -753,6 +755,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field93F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field93F.java index 29cb02972..d1a060bb3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field93F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field93F.java @@ -266,14 +266,13 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent5AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // This is the last component, return directly without `if` + //amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent5AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -721,6 +720,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -732,6 +732,7 @@ public BigDecimal amount() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -742,6 +743,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -756,6 +758,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94A.java index eeef975ba..f96ef3e76 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94A.java @@ -207,11 +207,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 94A"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94B.java index 3f09b3682..9f684d6ad 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94B.java @@ -249,11 +249,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -540,6 +538,7 @@ public Field94B setNarrative(String component4) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -550,6 +549,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -564,6 +564,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94C.java index 08af595d2..2fb473c67 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94C.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field94C setCountryCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94D.java index 4c25b64d3..3a2577cd2 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94D.java @@ -236,11 +236,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -484,6 +482,7 @@ public Field94D setPlace(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -494,6 +493,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -508,6 +508,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94E.java index e61a54003..8345e3917 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94E.java @@ -273,11 +273,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(10); } - if (component == 11) { - //default format (as is) - return getComponent(11); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(11); } /** @@ -905,6 +903,7 @@ public Field94E setAddressLine10(String component11) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -915,6 +914,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -929,6 +929,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -1012,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1025,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field94E cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1037,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1049,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field94E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1063,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1077,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field94E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94F.java index beeb1f728..7c2ff6eee 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94F.java @@ -253,11 +253,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -593,10 +591,12 @@ public Field94F setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -608,6 +608,7 @@ public List bicStrings () { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -618,6 +619,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -632,6 +634,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94G.java index b2bee3662..d6af42f9e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94G.java @@ -236,11 +236,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -524,6 +522,7 @@ public Field94G setAddressLine2(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -534,6 +533,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -548,6 +548,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -631,6 +632,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -644,6 +646,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field94G cp = newInstance(this); return getLine(cp, line, null, offset); @@ -656,6 +659,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -668,6 +672,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field94G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -682,6 +687,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -696,6 +702,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field94G cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94H.java index 24a001b47..b2d0012a8 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94H.java @@ -232,11 +232,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -510,10 +508,12 @@ public Field94H setBIC(com.prowidesoftware.swift.model.BIC component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -525,6 +525,7 @@ public List bicStrings () { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -535,6 +536,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -549,6 +551,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field94L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field94L.java index ca729d693..fbcec06fb 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field94L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field94L.java @@ -241,11 +241,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -595,6 +593,7 @@ public Field94L setLegalEntityIdentifierNumber(java.lang.Number component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -605,6 +604,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -619,6 +619,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95C.java index 20f002e6b..790fc99d3 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95C.java @@ -222,11 +222,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -427,6 +425,7 @@ public Field95C setCountryCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -437,6 +436,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -451,6 +451,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95L.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95L.java index b76490d1b..f98d92de9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95L.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95L.java @@ -241,11 +241,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -595,6 +593,7 @@ public Field95L setLegalEntityIdentifierNumber(java.lang.Number component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -605,6 +604,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -619,6 +619,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95P.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95P.java index 8e75f27fb..b23812057 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95P.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95P.java @@ -238,10 +238,12 @@ public Field95P setBIC(com.prowidesoftware.swift.model.BIC component2) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -253,6 +255,7 @@ public List bicStrings () { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -263,6 +266,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -277,6 +281,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95Q.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95Q.java index 41b5114fd..4f3f13bf4 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95Q.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95Q.java @@ -280,6 +280,7 @@ public Field95Q setNameAndAddressLine4(String component5) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -290,6 +291,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -304,6 +306,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -387,6 +390,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -400,6 +404,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field95Q cp = newInstance(this); return getLine(cp, line, null, offset); @@ -412,6 +417,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -424,6 +430,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field95Q cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -438,6 +445,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -452,6 +460,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field95Q cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95R.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95R.java index df7d6828e..de20d009f 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95R.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95R.java @@ -223,6 +223,7 @@ public Field95R setProprietaryCode(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -233,6 +234,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -247,6 +249,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95S.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95S.java index 5015596ba..aab87d674 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95S.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95S.java @@ -267,6 +267,7 @@ public Field95S setAlternateID(String component5) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -277,6 +278,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -291,6 +293,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95U.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95U.java index 94563aa51..de3750e7e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95U.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95U.java @@ -258,6 +258,7 @@ public Field95U setPartyNameLine3(String component4) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -268,6 +269,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -282,6 +284,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -365,6 +368,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -378,6 +382,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field95U cp = newInstance(this); return getLine(cp, line, null, offset); @@ -390,6 +395,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -402,6 +408,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field95U cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -416,6 +423,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -430,6 +438,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field95U cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field95V.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field95V.java index e5d5f4596..17aac2c32 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field95V.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field95V.java @@ -273,11 +273,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(10); } - if (component == 11) { - //default format (as is) - return getComponent(11); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(11); } /** @@ -905,6 +903,7 @@ public Field95V setNameAndAddressLine10(String component11) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -915,6 +914,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -929,6 +929,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } @@ -1012,6 +1013,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -1025,6 +1027,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field95V cp = newInstance(this); return getLine(cp, line, null, offset); @@ -1037,6 +1040,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -1049,6 +1053,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field95V cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -1063,6 +1068,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -1077,6 +1083,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field95V cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field96A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field96A.java index 70778b60d..3681b42ea 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field96A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field96A.java @@ -260,10 +260,12 @@ public Field96A setBIC(com.prowidesoftware.swift.model.BIC component3) { } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -348,6 +350,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -361,6 +364,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field96A cp = newInstance(this); return getLine(cp, line, null, offset); @@ -373,6 +377,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -385,6 +390,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field96A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -399,6 +405,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -413,6 +420,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field96A cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field96D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field96D.java index 01f4e2ade..82378d3fa 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field96D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field96D.java @@ -374,6 +374,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -387,6 +388,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field96D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -399,6 +401,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -411,6 +414,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field96D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -425,6 +429,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -439,6 +444,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field96D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field97A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field97A.java index 2dca990ff..f3c235fc1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field97A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field97A.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -465,6 +463,7 @@ public Field97A setAccount(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -475,6 +474,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -489,6 +489,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field97B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field97B.java index bca6bafd7..29163d331 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field97B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field97B.java @@ -250,11 +250,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -538,6 +536,7 @@ public Field97B setAccountNumber(String component4) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -548,6 +547,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -562,6 +562,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field97C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field97C.java index 7897377a0..81678a657 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field97C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field97C.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -456,6 +454,7 @@ public Field97C setCode(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -466,6 +465,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -480,6 +480,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field97D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field97D.java index 4ab730462..03135db40 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field97D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field97D.java @@ -235,11 +235,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -483,6 +481,7 @@ public Field97D setIdentificationOfBlockchainOrWallet(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -493,6 +492,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -507,6 +507,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field97E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field97E.java index 1c9feb3ba..9e7ad7855 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field97E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field97E.java @@ -229,11 +229,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -465,6 +463,7 @@ public Field97E setAccount(String component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -475,6 +474,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -489,6 +489,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98A.java index aa4470176..f5e8ea507 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98A.java @@ -225,13 +225,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //date: [YY]YYMMDD - java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -472,6 +471,7 @@ public Field98A setDate(java.util.Calendar component2) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -492,6 +492,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -502,6 +503,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -516,6 +518,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98B.java index d4da7ede7..ddcca9e82 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98B.java @@ -242,11 +242,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -512,6 +510,7 @@ public Field98B setCode(String component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -522,6 +521,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -536,6 +536,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98C.java index 743f17b26..e8d90de16 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98C.java @@ -244,13 +244,12 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - //time with seconds: HHmmss - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); - java.util.Calendar cal = getComponent3AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time with seconds: HHmmss + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); + java.util.Calendar cal = getComponent3AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -571,6 +570,7 @@ public Field98C setTime(java.util.Calendar component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -591,6 +591,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -601,6 +602,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -615,6 +617,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98D.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98D.java index 72d6de1be..a77088133 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98D.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98D.java @@ -296,13 +296,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent5AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent5AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -861,6 +860,7 @@ public Field98D setOffset(java.util.Calendar component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98E.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98E.java index f3aa0ae6b..e0a5acb4b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98E.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98E.java @@ -312,13 +312,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(5); } - if (component == 6) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent6AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent6AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -917,6 +916,7 @@ public Field98E setOffset(java.util.Calendar component6) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -937,6 +937,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -947,6 +948,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -961,6 +963,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98F.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98F.java index 7161aca6c..0f6e1a98b 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98F.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98F.java @@ -263,13 +263,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //time with seconds: HHmmss - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); - java.util.Calendar cal = getComponent4AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time with seconds: HHmmss + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm:ss", notNull(locale)); + java.util.Calendar cal = getComponent4AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -617,6 +616,7 @@ public Field98F setTime(java.util.Calendar component4) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return getComponent2(); } @@ -627,6 +627,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return getComponent2() != null; } @@ -641,6 +642,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98G.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98G.java index 42c2117d0..6b4905bf9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98G.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98G.java @@ -303,13 +303,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(4); } - if (component == 5) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent5AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent5AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -927,6 +926,7 @@ public Field98G setOffset(java.util.Calendar component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98H.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98H.java index ae5af3c4e..b9ed53165 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98H.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98H.java @@ -286,13 +286,12 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(3); } - if (component == 4) { - //time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent4AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // This is the last component, return directly without `if` + //time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent4AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98J.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98J.java index f1706e0f8..b48bace6a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98J.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98J.java @@ -276,11 +276,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 4) { - //default format (as is) - return getComponent(4); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(4); } /** @@ -719,6 +717,7 @@ public Field98J setBIC(com.prowidesoftware.swift.model.BIC component4) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -732,10 +731,12 @@ public Calendar date() { return DateResolver.date(this); } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings () { return BICResolver.bicStrings(this); } @@ -747,6 +748,7 @@ public List bicStrings () { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -757,6 +759,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -771,6 +774,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field98K.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field98K.java index 41bd090fb..20dd337f1 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field98K.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field98K.java @@ -279,11 +279,9 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 5) { - //default format (as is) - return getComponent(5); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(5); } /** @@ -682,6 +680,7 @@ public Field98K setProprietaryCode(String component5) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -702,6 +701,7 @@ public Calendar date() { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -712,6 +712,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -726,6 +727,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field999.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field999.java index fa325ec74..32dae527e 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field999.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field999.java @@ -202,11 +202,8 @@ public String getValueDisplay(int component, Locale locale) { if (component < 1 || component > 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 999"); } - if (component == 1) { - //default format (as is) - return getComponent(1); - } - return null; + //default format (as is) + return getComponent(1); } /** diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field99A.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field99A.java index 15fa7ccde..14facf75a 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field99A.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field99A.java @@ -244,11 +244,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(2); } - if (component == 3) { - //default format (as is) - return getComponent(3); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(3); } /** @@ -660,6 +658,7 @@ public Field99A setAmount(java.lang.Number component3) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -670,6 +669,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -684,6 +684,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field99B.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field99B.java index dfa27b2cc..26f962b18 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field99B.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field99B.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -538,6 +536,7 @@ public Field99B setNumber(java.lang.Number component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -548,6 +547,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -562,6 +562,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/generated/java/com/prowidesoftware/swift/model/field/Field99C.java b/src/generated/java/com/prowidesoftware/swift/model/field/Field99C.java index f4f5e8cfc..f692917a9 100644 --- a/src/generated/java/com/prowidesoftware/swift/model/field/Field99C.java +++ b/src/generated/java/com/prowidesoftware/swift/model/field/Field99C.java @@ -224,11 +224,9 @@ public String getValueDisplay(int component, Locale locale) { //default format (as is) return getComponent(1); } - if (component == 2) { - //default format (as is) - return getComponent(2); - } - return null; + // This is the last component, return directly without `if` + //default format (as is) + return getComponent(2); } /** @@ -538,6 +536,7 @@ public Field99C setNumber(java.lang.Number component2) { * * @return DSS component value or null if the DSS is not set or not available for this field. */ + @Override public String getDSS() { return null; } @@ -548,6 +547,7 @@ public String getDSS() { * @see #getDSS() * @return true if DSS is present, false otherwise. */ + @Override public boolean isDSSPresent() { return false; } @@ -562,6 +562,7 @@ public boolean isDSSPresent() { * * @return for generic fields returns the value of the conditional qualifier or null if not set or not applicable for this field. */ + @Override public String getConditionalQualifier() { return getComponent(CONDITIONAL_QUALIFIER); } diff --git a/src/main/java/com/prowidesoftware/swift/constraints/IbanValidator.java b/src/main/java/com/prowidesoftware/swift/constraints/IbanValidator.java index 552e92766..2eaf443aa 100644 --- a/src/main/java/com/prowidesoftware/swift/constraints/IbanValidator.java +++ b/src/main/java/com/prowidesoftware/swift/constraints/IbanValidator.java @@ -37,12 +37,13 @@ public boolean isValid(String iban, ConstraintValidatorContext context) { if (StringUtils.isBlank(iban)) { return true; } - IbanValidationResult result = new IBAN(iban).validate(); + IbanValidationResult result = IBAN.validate(iban); if (result == IbanValidationResult.OK) { return true; } else { context.disableDefaultConstraintViolation(); context.buildConstraintViolationWithTemplate(result.message()).addConstraintViolation(); + return false; } } diff --git a/src/main/java/com/prowidesoftware/swift/io/parser/SwiftParser.java b/src/main/java/com/prowidesoftware/swift/io/parser/SwiftParser.java index 6dc7988c4..f874ec537 100644 --- a/src/main/java/com/prowidesoftware/swift/io/parser/SwiftParser.java +++ b/src/main/java/com/prowidesoftware/swift/io/parser/SwiftParser.java @@ -119,7 +119,7 @@ private static Character extractBlock2Type(final String s) { if (i >= 0 && i + 1 < s.length()) { // check for input mark after ':' ch = s.charAt(i + 1); - } else if (s.length() > 0) { + } else if (!s.isEmpty()) { // check start ch = s.charAt(0); } @@ -326,9 +326,9 @@ protected SwiftBlock consumeBlock(final UnparsedTextList unparsedReceiver) throw // read the block contents final String s = readUntilBlockEnds(); - if ("".equals(s)) { + if (StringUtils.isEmpty(s)) { /* if we have an unparsed text add it to last block */ - if (unparsed.length() > 0) { + if (!unparsed.isEmpty()) { if (unparsedReceiver == null) { log.warning("Unparsed text '" + unparsed + "' can not be reported since unparsedReceiver is null"); } else { @@ -391,7 +391,7 @@ protected SwiftBlock consumeBlock(final UnparsedTextList unparsedReceiver) throw // create the block object b = createBlock(blockId, s); - if (unparsed.length() > 0) { + if (!unparsed.isEmpty()) { if (unparsedReceiver == null) { log.warning("Unparsed text '" + unparsed + "' can not be reported since unparsedReceiver is null"); } else { @@ -562,7 +562,7 @@ protected SwiftTagListBlock consumeTagListBlock(final SwiftTagListBlock b, final int end; for (end = i; end < data.length() && data.charAt(end) != '{'; end++) {} final String unparsedText = data.substring(i, end).trim(); - if (!"".equals(unparsedText)) { + if (!StringUtils.isEmpty(unparsedText)) { b.unparsedTextAddText(unparsedText); } i = end - 1; @@ -629,7 +629,7 @@ protected SwiftBlock4 consumeBlock4(final SwiftBlock4 b, final String s) { // check if we skipped a block unparsed text String unparsedText = s.substring(begin, start - ignore - 1).trim(); - if (!"".equals(unparsedText)) { + if (!StringUtils.isEmpty(unparsedText)) { b.unparsedTextAddText(unparsedText); } @@ -978,7 +978,7 @@ private UnparsedTextList processUnparsedText(final String unparsedText) { // separate a text final String text = unparsedText.substring(start, end).trim(); - if (!"".equals(text)) { + if (!StringUtils.isEmpty(text)) { // add it to the list (create it if needed) if (list == null) { diff --git a/src/main/java/com/prowidesoftware/swift/model/BicValidationResult.java b/src/main/java/com/prowidesoftware/swift/model/BicValidationResult.java index 18c2f7cc4..5823861dd 100644 --- a/src/main/java/com/prowidesoftware/swift/model/BicValidationResult.java +++ b/src/main/java/com/prowidesoftware/swift/model/BicValidationResult.java @@ -15,6 +15,8 @@ */ package com.prowidesoftware.swift.model; +import static com.prowidesoftware.swift.utils.ConstraintUtils.escapeScript; + import java.util.Objects; /** @@ -52,7 +54,7 @@ public enum BicValidationResult { */ public String message() { return this.message - .replace("${found}", Objects.toString(found)) + .replace("${found}", Objects.toString(escapeScript(found))) .replace("${length}", found == null ? "-1" : String.valueOf(found.length())); } diff --git a/src/main/java/com/prowidesoftware/swift/model/IBAN.java b/src/main/java/com/prowidesoftware/swift/model/IBAN.java index ea913b30f..7da17d63c 100644 --- a/src/main/java/com/prowidesoftware/swift/model/IBAN.java +++ b/src/main/java/com/prowidesoftware/swift/model/IBAN.java @@ -139,16 +139,37 @@ public boolean isValid() { * @return IbanFormatStatus with detailed information of the validation problem found */ public IbanValidationResult validate() { - if (iban == null) { + if (this.iban == null) { return IbanValidationResult.IBAN_IS_NULL; } - if (iban.length() == 0) { + final String code = removeNonAlpha(this.iban); + + return validate(code); + } + + /** + * Check an IBAN code throwing an exception with validation details if it is not valid. + * + *

Validates that the length is at least 5 chars: composed by a valid 2 letters ISO country code, + * 2 verifying digits, and 1 BBAN. The verification digits are also computed and verified. + * For the BBAN validation the specific per country structure must be defined either in the + * BbanStructureValidations.json file or by API in the {@link BbanStructureValidations} instance. + * + *

Non alpha-numeric characters are removed from the code prior to validation. Meaning an IBAN + * such as "ES64 0049 6170 68 2810279951" will be considered valid. + * + * @return IbanFormatStatus with detailed information of the validation problem found + */ + public static IbanValidationResult validate(String code) { + if (code == null) { + return IbanValidationResult.IBAN_IS_NULL; + } + if (code.isEmpty()) { return IbanValidationResult.IBAN_IS_EMPTY; } - IbanValidationResult result = null; + IbanValidationResult result; try { - final String code = removeNonAlpha(this.iban); result = IbanValidationUtils.validateCountryCode(code); diff --git a/src/main/java/com/prowidesoftware/swift/model/IbanValidationResult.java b/src/main/java/com/prowidesoftware/swift/model/IbanValidationResult.java index 19bfc0e09..5555d0d8e 100644 --- a/src/main/java/com/prowidesoftware/swift/model/IbanValidationResult.java +++ b/src/main/java/com/prowidesoftware/swift/model/IbanValidationResult.java @@ -15,6 +15,8 @@ */ package com.prowidesoftware.swift.model; +import static com.prowidesoftware.swift.utils.ConstraintUtils.escapeScript; + import java.util.HashMap; import java.util.Map; import java.util.Map.Entry; @@ -68,7 +70,7 @@ public enum IbanValidationResult { public String message() { String msg = this.message; for (Entry e : vars.entrySet()) { - msg = msg.replace("${" + e.getKey() + "}", e.getValue()); + msg = msg.replace("${" + e.getKey() + "}", escapeScript(e.getValue())); } return msg; } diff --git a/src/main/java/com/prowidesoftware/swift/model/SwiftMessageUtils.java b/src/main/java/com/prowidesoftware/swift/model/SwiftMessageUtils.java index e020267f2..9b56dae66 100644 --- a/src/main/java/com/prowidesoftware/swift/model/SwiftMessageUtils.java +++ b/src/main/java/com/prowidesoftware/swift/model/SwiftMessageUtils.java @@ -353,7 +353,7 @@ public static String identifier(final SwiftMessage m) { /** * Proprietary checksum for message integrity verification or duplicates detection. *

Please notice this is not the SWIFT trailer CHK field. - *

The implementation computes an MD5 on the complete message in FIN format. The result hash + *

The implementation computes an SHA-256 on the complete message in FIN format. The result hash * is a 32 character string, you may consider encoding it with base64 on top to have the same * information stored in 22 characters. * @@ -365,7 +365,7 @@ public static String calculateChecksum(final SwiftMessage model) { final StringWriter writer = new StringWriter(); SwiftWriter.writeMessage(model, writer, true); final String fin = writer.getBuffer().toString(); - return md5(fin); + return sha256(fin); } else { return null; } @@ -374,7 +374,7 @@ public static String calculateChecksum(final SwiftMessage model) { /** * Proprietary checksum for message text block (block 4) integrity verification or duplicates detection *

Please notice this is not the SWIFT trailer CHK field. - *

The implementation computes an MD5 on the complete message in FIN format. The result hash + *

The implementation computes an SHA-256 on the complete message in FIN format. The result hash * is a 32 character string, you may consider encoding it with base64 on top to have the same * information stored in 22 characters. * @@ -387,24 +387,22 @@ public static String calculateChecksum(final SwiftBlock4 b4) { final StringWriter writer = new StringWriter(); SwiftWriter.writeBlock4(b4, writer); final String fin = writer.getBuffer().toString(); - return md5(fin); + return sha256(fin); } else { return null; } } /** - * Computes an MD5 hash on the parameter text + * Computes a SHA-256 hash on the parameter text * * @param text the text to hash * @return computed hash or null if exceptions are thrown reading bytes or processing the digest - * @since 7.9.5 */ - // TODO add base 64 encoding on top when upgraded to Java 8 - private static String md5(final String text) { + private static String sha256(final String text) { try { byte[] bytesOfMessage = text.getBytes(StandardCharsets.UTF_8); - MessageDigest md = MessageDigest.getInstance("MD5"); + MessageDigest md = MessageDigest.getInstance("SHA-256"); byte[] thedigest = md.digest(bytesOfMessage); // Converting the bytes to a Hex string diff --git a/src/main/java/com/prowidesoftware/swift/model/SwiftTagListBlock.java b/src/main/java/com/prowidesoftware/swift/model/SwiftTagListBlock.java index a5e739c5c..f33038187 100644 --- a/src/main/java/com/prowidesoftware/swift/model/SwiftTagListBlock.java +++ b/src/main/java/com/prowidesoftware/swift/model/SwiftTagListBlock.java @@ -1828,21 +1828,20 @@ public int countTagsStarsWith(final String name, final String value) { * @return a new block with the trimmed content */ public SwiftTagListBlock removeAfterFirstStartsWith(final String name, final String startsWith) { - if (this.tags == null || !this.tags.isEmpty()) { + if (this.tags == null || this.tags.isEmpty()) { return new SwiftTagListBlock(); } - final List tags = new ArrayList<>(); - boolean done = false; - for (int i = 0; i < this.tags.size() && !done; i++) { - final Tag t = this.tags.get(i); - if (StringUtils.equals(t.getName(), name) && t.startsWith(startsWith)) { - done = true; + final List updatedTags = new ArrayList<>(); + + for (Tag t : this.tags) { + if (StringUtils.equals(t.getName(), name) && StringUtils.startsWith(t.getValue(), startsWith)) { + break; } else { - tags.add(t); + updatedTags.add(t); } } - return new SwiftTagListBlock(tags); + return new SwiftTagListBlock(updatedTags); } /** diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field.java b/src/main/java/com/prowidesoftware/swift/model/field/Field.java index 597939c87..fe70ecd19 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field.java @@ -58,6 +58,14 @@ public abstract class Field implements PatternContainer, JsonSerializable { private static final String fieldNamePattern = "^\\d{2,3}[A-Z]?$"; + /** + * No-argument constructor required for serialization. + * Initializes the components list. + */ + protected Field() { + this.components = new ArrayList<>(); + } + /** * Creates a field with the list of components initialized to the given number of components. * diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field11T.java b/src/main/java/com/prowidesoftware/swift/model/field/Field11T.java index 5155a850e..b7cbf67d0 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field11T.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field11T.java @@ -243,13 +243,11 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 3) { - // time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent3AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent3AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -690,6 +688,7 @@ public Field11T setTime(java.util.Calendar component3) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -766,7 +765,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field11T(f)); } @@ -782,6 +781,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -795,6 +795,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field11T cp = newInstance(this); return getLine(cp, line, null, offset); @@ -807,6 +808,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -819,6 +821,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field11T cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -833,6 +836,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -847,6 +851,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field11T cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field12H.java b/src/main/java/com/prowidesoftware/swift/model/field/Field12H.java index b87026a83..f83f6afca 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field12H.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field12H.java @@ -212,11 +212,8 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // default format (as is) - return getComponent(2); - } - return null; + // default format (as is) + return getComponent(2); } /** @@ -269,10 +266,7 @@ public String validatorPattern() { */ @Override public boolean isOptional(int component) { - if (component == 2) { - return true; - } - return false; + return component == 2; } /** @@ -475,7 +469,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field12H(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field12K.java b/src/main/java/com/prowidesoftware/swift/model/field/Field12K.java index bb40f2ad8..07565a468 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field12K.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field12K.java @@ -206,14 +206,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12K"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -632,7 +629,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field12K(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field12L.java b/src/main/java/com/prowidesoftware/swift/model/field/Field12L.java index 8884829d3..6f9a129fd 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field12L.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field12L.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12L"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field12L(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field12R.java b/src/main/java/com/prowidesoftware/swift/model/field/Field12R.java index 2d0298f06..9fc49f63d 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field12R.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field12R.java @@ -212,11 +212,8 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // default format (as is) - return getComponent(2); - } - return null; + // default format (as is) + return getComponent(2); } /** @@ -269,10 +266,7 @@ public String validatorPattern() { */ @Override public boolean isOptional(int component) { - if (component == 2) { - return true; - } - return false; + return component == 2; } /** @@ -475,7 +469,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field12R(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field12S.java b/src/main/java/com/prowidesoftware/swift/model/field/Field12S.java index f5afd7b08..e7518302f 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field12S.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field12S.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 12S"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field12S(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field13E.java b/src/main/java/com/prowidesoftware/swift/model/field/Field13E.java index 771471512..eb5a95365 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field13E.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field13E.java @@ -222,13 +222,11 @@ public String getValueDisplay(int component, Locale locale) { return f.format(cal.getTime()); } } - if (component == 2) { - // time: HH[mm] - java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); - java.util.Calendar cal = getComponent2AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // time: HH[mm] + java.text.DateFormat f = new java.text.SimpleDateFormat("HH:mm", notNull(locale)); + java.util.Calendar cal = getComponent2AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -508,6 +506,7 @@ public Field13E setTime(java.util.Calendar component2) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -584,7 +583,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field13E(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field20E.java b/src/main/java/com/prowidesoftware/swift/model/field/Field20E.java index 7f6b6cb94..d5a794c3f 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field20E.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field20E.java @@ -211,11 +211,8 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // default format (as is) - return getComponent(2); - } - return null; + // default format (as is) + return getComponent(2); } /** @@ -471,7 +468,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field20E(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field21S.java b/src/main/java/com/prowidesoftware/swift/model/field/Field21S.java index 43ef8c282..4a23b5bc8 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field21S.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field21S.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21S"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field21S(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field21T.java b/src/main/java/com/prowidesoftware/swift/model/field/Field21T.java index 7e641f05b..e3a9eb53e 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field21T.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field21T.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 21T"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field21T(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field25F.java b/src/main/java/com/prowidesoftware/swift/model/field/Field25F.java index 83fcc935e..f16b1499c 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field25F.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field25F.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 25F"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field25F(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field25G.java b/src/main/java/com/prowidesoftware/swift/model/field/Field25G.java index a66b783fb..48cd54c6c 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field25G.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field25G.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 25G"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field25G(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field27A.java b/src/main/java/com/prowidesoftware/swift/model/field/Field27A.java index f744282b9..c5188a8c6 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field27A.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field27A.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // default format (as is) - return getComponent(2); - } - return null; + // default format (as is) + return getComponent(2); } /** @@ -716,7 +713,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field27A(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field29D.java b/src/main/java/com/prowidesoftware/swift/model/field/Field29D.java index 69cb1528c..18c513866 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field29D.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field29D.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(3); } - if (component == 4) { - // default format (as is) - return getComponent(4); - } - return null; + // default format (as is) + return getComponent(4); } /** @@ -277,10 +274,7 @@ public boolean isOptional(int component) { if (component == 3) { return true; } - if (component == 4) { - return true; - } - return false; + return component == 4; } /** @@ -603,7 +597,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field29D(f)); } @@ -619,6 +613,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -632,6 +627,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field29D cp = newInstance(this); return getLine(cp, line, null, offset); @@ -644,6 +640,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -656,6 +653,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field29D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -670,6 +668,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -684,6 +683,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field29D cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field29F.java b/src/main/java/com/prowidesoftware/swift/model/field/Field29F.java index e5e2c5b65..f9bfa5d68 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field29F.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field29F.java @@ -214,11 +214,8 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(3); } - if (component == 4) { - // default format (as is) - return getComponent(4); - } - return null; + // default format (as is) + return getComponent(4); } /** @@ -277,10 +274,7 @@ public boolean isOptional(int component) { if (component == 3) { return true; } - if (component == 4) { - return true; - } - return false; + return component == 4; } /** @@ -603,7 +597,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field29F(f)); } @@ -619,6 +613,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -632,6 +627,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field29F cp = newInstance(this); return getLine(cp, line, null, offset); @@ -644,6 +640,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -656,6 +653,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field29F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -670,6 +668,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -684,6 +683,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field29F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field29P.java b/src/main/java/com/prowidesoftware/swift/model/field/Field29P.java index f5754bc69..2d1a8a2e2 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field29P.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field29P.java @@ -205,14 +205,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 29P"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -456,10 +453,12 @@ public Field29P setBIC(com.prowidesoftware.swift.model.BIC component1) { return setIdentifierCode(component1); } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings() { return BICResolver.bicStrings(this); } @@ -527,7 +526,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field29P(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field29S.java b/src/main/java/com/prowidesoftware/swift/model/field/Field29S.java index 247bf3b06..de80b37c1 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field29S.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field29S.java @@ -211,11 +211,8 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // default format (as is) - return getComponent(2); - } - return null; + // default format (as is) + return getComponent(2); } /** @@ -471,7 +468,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field29S(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field29U.java b/src/main/java/com/prowidesoftware/swift/model/field/Field29U.java index 2fabcbbcc..8ed7941ac 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field29U.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field29U.java @@ -205,14 +205,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 29U"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -456,10 +453,12 @@ public Field29U setBIC(com.prowidesoftware.swift.model.BIC component1) { return setIdentifierCode(component1); } + @Override public List bics() { return BICResolver.bics(this); } + @Override public List bicStrings() { return BICResolver.bicStrings(this); } @@ -527,7 +526,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field29U(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field31J.java b/src/main/java/com/prowidesoftware/swift/model/field/Field31J.java index e952be8e0..079cf4ece 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field31J.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field31J.java @@ -197,17 +197,14 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31J"); } - if (component == 1) { - // date: [YY]YYMMDD - java.text.DateFormat f = - java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -407,6 +404,7 @@ public Field31J setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -483,7 +481,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field31J(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field31K.java b/src/main/java/com/prowidesoftware/swift/model/field/Field31K.java index 11a7367f6..50ef24138 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field31K.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field31K.java @@ -197,17 +197,14 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31K"); } - if (component == 1) { - // date: [YY]YYMMDD - java.text.DateFormat f = - java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -407,6 +404,7 @@ public Field31K setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -483,7 +481,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field31K(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field31M.java b/src/main/java/com/prowidesoftware/swift/model/field/Field31M.java index 477282174..285865ff7 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field31M.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field31M.java @@ -197,17 +197,14 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31M"); } - if (component == 1) { - // date: [YY]YYMMDD - java.text.DateFormat f = - java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -407,6 +404,7 @@ public Field31M setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -483,7 +481,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field31M(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field31T.java b/src/main/java/com/prowidesoftware/swift/model/field/Field31T.java index ae384e386..ca03e89e2 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field31T.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field31T.java @@ -197,17 +197,14 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 31T"); } - if (component == 1) { - // date: [YY]YYMMDD - java.text.DateFormat f = - java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); - java.util.Calendar cal = getComponent1AsCalendar(); - if (cal != null) { - return f.format(cal.getTime()); - } + // date: [YY]YYMMDD + java.text.DateFormat f = java.text.DateFormat.getDateInstance(java.text.DateFormat.DEFAULT, notNull(locale)); + java.util.Calendar cal = getComponent1AsCalendar(); + if (cal != null) { + return f.format(cal.getTime()); } return null; } @@ -407,6 +404,7 @@ public Field31T setDate(java.util.Calendar component1) { * * @return the list of converted components (a Calendar object or null) */ + @Override public List dates() { return DateResolver.dates(this); } @@ -483,7 +481,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field31T(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34D.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34D.java index 5902b87c4..d989f5f0c 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34D.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34D.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34D(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34K.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34K.java index 544eaf581..a523b0fe2 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34K.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34K.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34K(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34L.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34L.java index 061d2935f..f967dde59 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34L.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34L.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34L(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34M.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34M.java index 4b5efe3b9..aec47cc2c 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34M.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34M.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34M(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34S.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34S.java index 6d85ea171..169a6958f 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34S.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34S.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34S(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34T.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34T.java index a1f6fe843..bb7044652 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34T.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34T.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34T(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34U.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34U.java index c19c50bc2..9dc8defd7 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34U.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34U.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34U(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34V.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34V.java index 56978b316..4f6a19d16 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34V.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34V.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34V(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34W.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34W.java index ce34858ab..65fd489ac 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34W.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34W.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34W(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field34X.java b/src/main/java/com/prowidesoftware/swift/model/field/Field34X.java index f26d1fda5..3479ff4ad 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field34X.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field34X.java @@ -212,14 +212,12 @@ public String getValueDisplay(int component, Locale locale) { // default format (as is) return getComponent(1); } - if (component == 2) { - // amount, rate - java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); - f.setMaximumFractionDigits(13); - BigDecimal n = getComponent2AsBigDecimal(); - if (n != null) { - return f.format(n); - } + // amount, rate + java.text.NumberFormat f = java.text.NumberFormat.getNumberInstance(notNull(locale)); + f.setMaximumFractionDigits(13); + BigDecimal n = getComponent2AsBigDecimal(); + if (n != null) { + return f.format(n); } return null; } @@ -552,6 +550,7 @@ public List amounts() { * @return the first amount as BigDecimal value. Can be null * @see AmountResolver#amount(Field) */ + @Override public BigDecimal amount() { return AmountResolver.amount(this); } @@ -619,7 +618,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field34X(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field47E.java b/src/main/java/com/prowidesoftware/swift/model/field/Field47E.java index 20fe2d1dd..bb513aa17 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field47E.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field47E.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 47E"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field47E(f)); } @@ -434,6 +431,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -447,6 +445,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field47E cp = newInstance(this); return getLine(cp, line, null, offset); @@ -459,6 +458,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -471,6 +471,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field47E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -485,6 +486,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -499,6 +501,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field47E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field49D.java b/src/main/java/com/prowidesoftware/swift/model/field/Field49D.java index 295fda0ae..a5b4c2c7f 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field49D.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field49D.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49D"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field49D(f)); } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field49F.java b/src/main/java/com/prowidesoftware/swift/model/field/Field49F.java index de99a0006..af3b62126 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field49F.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field49F.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49F"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field49F(f)); } @@ -434,6 +431,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -447,6 +445,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49F cp = newInstance(this); return getLine(cp, line, null, offset); @@ -459,6 +458,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -471,6 +471,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -485,6 +486,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -499,6 +501,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49F cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field49J.java b/src/main/java/com/prowidesoftware/swift/model/field/Field49J.java index 863cf102e..f715c09b6 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field49J.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field49J.java @@ -195,14 +195,12 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49J"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + + // default format (as is) + return getComponent(1); } /** @@ -418,7 +416,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field49J(f)); } @@ -434,6 +432,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -447,6 +446,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49J cp = newInstance(this); return getLine(cp, line, null, offset); @@ -459,6 +459,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -471,6 +472,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49J cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -485,6 +487,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -499,6 +502,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49J cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field49K.java b/src/main/java/com/prowidesoftware/swift/model/field/Field49K.java index ef5c5ab4a..b96fd0eb1 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field49K.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field49K.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49K"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field49K(f)); } @@ -434,6 +431,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -447,6 +445,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49K cp = newInstance(this); return getLine(cp, line, null, offset); @@ -459,6 +458,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -471,6 +471,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49K cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -485,6 +486,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -499,6 +501,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49K cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field49L.java b/src/main/java/com/prowidesoftware/swift/model/field/Field49L.java index 5aa056ee6..a2f5d303e 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field49L.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field49L.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49L"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field49L(f)); } @@ -434,6 +431,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -447,6 +445,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49L cp = newInstance(this); return getLine(cp, line, null, offset); @@ -459,6 +458,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -471,6 +471,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -485,6 +486,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -499,6 +501,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49L cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field49Z.java b/src/main/java/com/prowidesoftware/swift/model/field/Field49Z.java index a78235458..9115750c2 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field49Z.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field49Z.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 49Z"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field49Z(f)); } @@ -434,6 +431,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -447,6 +445,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field49Z cp = newInstance(this); return getLine(cp, line, null, offset); @@ -459,6 +458,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -471,6 +471,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field49Z cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -485,6 +486,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -499,6 +501,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field49Z cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field71E.java b/src/main/java/com/prowidesoftware/swift/model/field/Field71E.java index 5b14daf27..336726251 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field71E.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field71E.java @@ -232,7 +232,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field71E(f)); } @@ -248,6 +248,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -261,6 +262,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field71E cp = newInstance(this); return getLine(cp, line, null, offset); @@ -273,6 +275,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -285,6 +288,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field71E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -299,6 +303,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -313,6 +318,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field71E cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/Field78B.java b/src/main/java/com/prowidesoftware/swift/model/field/Field78B.java index 6643fa320..0b1845301 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/Field78B.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/Field78B.java @@ -195,14 +195,11 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field 78B"); } - if (component == 1) { - // default format (as is) - return getComponent(1); - } - return null; + // default format (as is) + return getComponent(1); } /** @@ -418,7 +415,7 @@ public static List getAll(final SwiftTagListBlock block) { return result; } final Tag[] arr = block.getTagsByName(NAME); - if (arr != null && arr.length > 0) { + if (arr != null) { for (final Tag f : arr) { result.add(new Field78B(f)); } @@ -434,6 +431,7 @@ public static List getAll(final SwiftTagListBlock block) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line) { return getLine(line, 0); } @@ -447,6 +445,7 @@ public String getLine(int line) { * @return line content or null if not present or if line number is above the expected * @since 7.7 */ + @Override public String getLine(int line, int offset) { Field78B cp = newInstance(this); return getLine(cp, line, null, offset); @@ -459,6 +458,7 @@ public String getLine(int line, int offset) { * @return lines content or empty list if field's value is empty * @since 7.7 */ + @Override public List getLines() { return SwiftParseUtils.getLines(getValue()); } @@ -471,6 +471,7 @@ public List getLines() { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLines(int offset) { Field78B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, null, null, offset)); @@ -485,6 +486,7 @@ public List getLines(int offset) { * @return found lines or empty list if value is empty * @since 7.7 */ + @Override public List getLinesBetween(int start, int end) { return getLinesBetween(start, end, 0); } @@ -499,6 +501,7 @@ public List getLinesBetween(int start, int end) { * @return found lines or empty list if lines are not present or the offset is invalid * @since 7.7 */ + @Override public List getLinesBetween(int start, int end, int offset) { Field78B cp = newInstance(this); return SwiftParseUtils.getLines(getLine(cp, start, end, offset)); diff --git a/src/main/java/com/prowidesoftware/swift/model/field/NarrativeFragment.java b/src/main/java/com/prowidesoftware/swift/model/field/NarrativeFragment.java index 82ea95ffd..e0e1530a1 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/NarrativeFragment.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/NarrativeFragment.java @@ -81,6 +81,7 @@ public int getLineLength() { return lineLength; } + @Override public String toString() { return text; } diff --git a/src/main/java/com/prowidesoftware/swift/model/field/OptionCPartyField.java b/src/main/java/com/prowidesoftware/swift/model/field/OptionCPartyField.java index 488c48a79..efe038de8 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/OptionCPartyField.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/OptionCPartyField.java @@ -111,7 +111,7 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field " + getName()); } // default format (as is) diff --git a/src/main/java/com/prowidesoftware/swift/model/field/OptionJPartyField.java b/src/main/java/com/prowidesoftware/swift/model/field/OptionJPartyField.java index 9717f4f23..3154b3a99 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/OptionJPartyField.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/OptionJPartyField.java @@ -111,7 +111,7 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field " + getName()); } // default format (as is) diff --git a/src/main/java/com/prowidesoftware/swift/model/field/OptionLPartyField.java b/src/main/java/com/prowidesoftware/swift/model/field/OptionLPartyField.java index d44b07783..482cdcfe3 100644 --- a/src/main/java/com/prowidesoftware/swift/model/field/OptionLPartyField.java +++ b/src/main/java/com/prowidesoftware/swift/model/field/OptionLPartyField.java @@ -110,7 +110,7 @@ public String getValue() { */ @Override public String getValueDisplay(int component, Locale locale) { - if (component < 1 || component > 1) { + if (component != 1) { throw new IllegalArgumentException("invalid component number " + component + " for field " + getName()); } // default format (as is) diff --git a/src/main/java/com/prowidesoftware/swift/utils/ConstraintUtils.java b/src/main/java/com/prowidesoftware/swift/utils/ConstraintUtils.java new file mode 100644 index 000000000..eff4f3c97 --- /dev/null +++ b/src/main/java/com/prowidesoftware/swift/utils/ConstraintUtils.java @@ -0,0 +1,485 @@ +package com.prowidesoftware.swift.utils; + +import java.io.IOException; +import java.io.StringWriter; +import java.io.UncheckedIOException; +import java.io.Writer; +import java.security.InvalidParameterException; +import java.util.*; +import java.util.stream.Stream; +import org.apache.commons.lang3.Validate; + +/** + * Utility class for escaping EcmaScript and Java control characters. + * This class provides methods for translating characters into their + * escaped equivalents, specifically for EcmaScript. + */ +public class ConstraintUtils { + + // Map for Java control characters that need to be escaped + private static final Map JAVA_CTRL_CHARS_ESCAPE; + + static { + final Map initialMap = new HashMap<>(); + initialMap.put("\b", "\\b"); + initialMap.put("\n", "\\n"); + initialMap.put("\t", "\\t"); + initialMap.put("\f", "\\f"); + initialMap.put("\r", "\\r"); + JAVA_CTRL_CHARS_ESCAPE = Collections.unmodifiableMap(initialMap); + } + + /** + * Escapes the given input string using EcmaScript rules. + * The method escapes control characters and symbols such as single quotes, double quotes, + * backslashes, and forward slashes, making the string safe for use in EcmaScript contexts. + * + * @param input the string to escape, may be null + * @return the escaped string or null if the input is null + */ + public static String escapeScript(final String input) { + if (input == null) { + return null; + } + + Map escapeEcmaScriptMap = new HashMap<>(); + escapeEcmaScriptMap.put("'", "\\'"); + escapeEcmaScriptMap.put("\"", "\\\""); + escapeEcmaScriptMap.put("\\", "\\\\"); + escapeEcmaScriptMap.put("/", "\\/"); + + CharSequenceTranslator translator = new AggregateTranslator( + new LookupTranslator(Collections.unmodifiableMap(escapeEcmaScriptMap)), + new LookupTranslator(JAVA_CTRL_CHARS_ESCAPE), + JavaUnicodeEscaper.outsideOf(32, 0x7f)); + + return translator.translate(input); + } +} + +abstract class CharSequenceTranslator { + + /** + * Array containing the hexadecimal alphabet. + */ + static final char[] HEX_DIGITS = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F'}; + + /** + * Returns an upper case hexadecimal {@code String} for the given + * character. + * + * @param codePoint The code point to convert. + * @return An upper case hexadecimal {@code String} + */ + public static String hex(final int codePoint) { + return Integer.toHexString(codePoint).toUpperCase(Locale.ENGLISH); + } + + /** + * Helper for non-Writer usage. + * @param input CharSequence to be translated + * @return String output of translation + */ + public final String translate(final CharSequence input) { + if (input == null) { + return null; + } + try { + final StringWriter writer = new StringWriter(input.length() * 2); + translate(input, writer); + return writer.toString(); + } catch (final IOException ioe) { + // this should never ever happen while writing to a StringWriter + throw new UncheckedIOException(ioe); + } + } + + /** + * Translate a set of code points, represented by an int index into a CharSequence, + * into another set of code points. The number of code points consumed must be returned, + * and the only IOExceptions thrown must be from interacting with the Writer so that + * the top level API may reliably ignore StringWriter IOExceptions. + * + * @param input CharSequence that is being translated + * @param index int representing the current point of translation + * @param writer Writer to translate the text to + * @return int count of code points consumed + * @throws IOException if and only if the Writer produces an IOException + */ + public abstract int translate(CharSequence input, int index, Writer writer) throws IOException; + + /** + * Translate an input onto a Writer. This is intentionally final as its algorithm is + * tightly coupled with the abstract method of this class. + * + * @param input CharSequence that is being translated + * @param writer Writer to translate the text to + * @throws IOException if and only if the Writer produces an IOException + */ + public final void translate(final CharSequence input, final Writer writer) throws IOException { + Validate.isTrue(writer != null, "The Writer must not be null"); + if (input == null) { + return; + } + int pos = 0; + final int len = input.length(); + while (pos < len) { + final int consumed = translate(input, pos, writer); + if (consumed == 0) { + // inlined implementation of Character.toChars(Character.codePointAt(input, pos)) + // avoids allocating temp char arrays and duplicate checks + final char c1 = input.charAt(pos); + writer.write(c1); + pos++; + if (Character.isHighSurrogate(c1) && pos < len) { + final char c2 = input.charAt(pos); + if (Character.isLowSurrogate(c2)) { + writer.write(c2); + pos++; + } + } + continue; + } + // contract with translators is that they have to understand code points + // and they just took care of a surrogate pair + for (int pt = 0; pt < consumed; pt++) { + pos += Character.charCount(Character.codePointAt(input, pos)); + } + } + } + + /** + * Helper method to create a merger of this translator with another set of + * translators. Useful in customizing the standard functionality. + * + * @param translators CharSequenceTranslator array of translators to merge with this one + * @return CharSequenceTranslator merging this translator with the others + */ + public final CharSequenceTranslator with(final CharSequenceTranslator... translators) { + final CharSequenceTranslator[] newArray = new CharSequenceTranslator[translators.length + 1]; + newArray[0] = this; + System.arraycopy(translators, 0, newArray, 1, translators.length); + return new AggregateTranslator(newArray); + } +} + +class AggregateTranslator extends CharSequenceTranslator { + + /** + * Translator list. + */ + private final List translators = new ArrayList<>(); + + /** + * Specify the translators to be used at creation time. + * + * @param translators CharSequenceTranslator array to aggregate + */ + public AggregateTranslator(final CharSequenceTranslator... translators) { + if (translators != null) { + Stream.of(translators).filter(Objects::nonNull).forEach(this.translators::add); + } + } + + /** + * The first translator to consume code points from the input is the 'winner'. + * Execution stops with the number of consumed code points being returned. + * {@inheritDoc} + */ + @Override + public int translate(final CharSequence input, final int index, final Writer writer) throws IOException { + for (final CharSequenceTranslator translator : translators) { + final int consumed = translator.translate(input, index, writer); + if (consumed != 0) { + return consumed; + } + } + return 0; + } +} + +class LookupTranslator extends CharSequenceTranslator { + + /** The mapping to be used in translation. */ + private final Map lookupMap; + + /** The first character of each key in the lookupMap. */ + private final BitSet prefixSet; + + /** The length of the shortest key in the lookupMap. */ + private final int shortest; + + /** The length of the longest key in the lookupMap. */ + private final int longest; + + /** + * Constructs the lookup table to be used in translation + * + * Note that, as of Lang 3.1 (the origin of this code), the key to the lookup + * table is converted to a java.lang.String. This is because we need the key + * to support hashCode and equals(Object), allowing it to be the key for a + * HashMap. See LANG-882. + * + * @param lookupMap Map<CharSequence, CharSequence> table of translator + * mappings + */ + public LookupTranslator(final Map lookupMap) { + if (lookupMap == null) { + throw new InvalidParameterException("lookupMap cannot be null"); + } + this.lookupMap = new HashMap<>(); + this.prefixSet = new BitSet(); + int currentShortest = Integer.MAX_VALUE; + int currentLongest = 0; + + for (final Map.Entry pair : lookupMap.entrySet()) { + this.lookupMap.put(pair.getKey().toString(), pair.getValue().toString()); + this.prefixSet.set(pair.getKey().charAt(0)); + final int sz = pair.getKey().length(); + if (sz < currentShortest) { + currentShortest = sz; + } + if (sz > currentLongest) { + currentLongest = sz; + } + } + this.shortest = currentShortest; + this.longest = currentLongest; + } + + /** + * {@inheritDoc} + */ + @Override + public int translate(final CharSequence input, final int index, final Writer writer) throws IOException { + // check if translation exists for the input at position index + if (prefixSet.get(input.charAt(index))) { + int max = longest; + if (index + longest > input.length()) { + max = input.length() - index; + } + // implement greedy algorithm by trying maximum match first + for (int i = max; i >= shortest; i--) { + final CharSequence subSeq = input.subSequence(index, index + i); + final String result = lookupMap.get(subSeq.toString()); + + if (result != null) { + writer.write(result); + return Character.codePointCount(subSeq, 0, subSeq.length()); + } + } + } + return 0; + } +} + +abstract class CodePointTranslator extends CharSequenceTranslator { + + @Override + public final int translate(final CharSequence input, final int index, final Writer writer) throws IOException { + final int codePoint = Character.codePointAt(input, index); + final boolean consumed = translate(codePoint, writer); + return consumed ? 1 : 0; + } + + /** + * Translates the specified code point into another. + * + * @param codePoint int character input to translate + * @param writer Writer to optionally push the translated output to + * @return boolean as to whether translation occurred or not + * @throws IOException if and only if the Writer produces an IOException + */ + public abstract boolean translate(int codePoint, Writer writer) throws IOException; +} + +class UnicodeEscaper extends CodePointTranslator { + + /** + * Constructs a {@code UnicodeEscaper} above the specified value (exclusive). + * + * @param codePoint above which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static UnicodeEscaper above(final int codePoint) { + return outsideOf(0, codePoint); + } + /** + * Constructs a {@code UnicodeEscaper} below the specified value (exclusive). + * + * @param codePoint below which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static UnicodeEscaper below(final int codePoint) { + return outsideOf(codePoint, Integer.MAX_VALUE); + } + /** + * Constructs a {@code UnicodeEscaper} between the specified values (inclusive). + * + * @param codePointLow above which to escape + * @param codePointHigh below which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static UnicodeEscaper between(final int codePointLow, final int codePointHigh) { + return new UnicodeEscaper(codePointLow, codePointHigh, true); + } + + /** + * Constructs a {@code UnicodeEscaper} outside of the specified values (exclusive). + * + * @param codePointLow below which to escape + * @param codePointHigh above which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static UnicodeEscaper outsideOf(final int codePointLow, final int codePointHigh) { + return new UnicodeEscaper(codePointLow, codePointHigh, false); + } + + /** The lowest code point boundary. */ + private final int below; + + /** The highest code point boundary. */ + private final int above; + + /** Whether to escape between the boundaries or outside them. */ + private final boolean between; + + /** + * Constructs a {@code UnicodeEscaper} for all characters. + */ + public UnicodeEscaper() { + this(0, Integer.MAX_VALUE, true); + } + + /** + * Constructs a {@code UnicodeEscaper} for the specified range. This is + * the underlying method for the other constructors/builders. The {@code below} + * and {@code above} boundaries are inclusive when {@code between} is + * {@code true} and exclusive when it is {@code false}. + * + * @param below int value representing the lowest code point boundary + * @param above int value representing the highest code point boundary + * @param between whether to escape between the boundaries or outside them + */ + protected UnicodeEscaper(final int below, final int above, final boolean between) { + this.below = below; + this.above = above; + this.between = between; + } + + /** + * Converts the given code point to a hexadecimal string of the form {@code "\\uXXXX"}. + * + * @param codePoint + * a Unicode code point + * @return The hexadecimal string for the given code point + */ + protected String toUtf16Escape(final int codePoint) { + return "\\u" + hex(codePoint); + } + + /** + * {@inheritDoc} + */ + @Override + public boolean translate(final int codePoint, final Writer writer) throws IOException { + if (between) { + if (codePoint < below || codePoint > above) { + return false; + } + } else if (codePoint >= below && codePoint <= above) { + return false; + } + + if (codePoint > 0xffff) { + writer.write(toUtf16Escape(codePoint)); + } else { + writer.write("\\u"); + writer.write(HEX_DIGITS[codePoint >> 12 & 15]); + writer.write(HEX_DIGITS[codePoint >> 8 & 15]); + writer.write(HEX_DIGITS[codePoint >> 4 & 15]); + writer.write(HEX_DIGITS[codePoint & 15]); + } + return true; + } +} + +class JavaUnicodeEscaper extends UnicodeEscaper { + + /** + * Constructs a {@code JavaUnicodeEscaper} above the specified value (exclusive). + * + * @param codePoint + * above which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static JavaUnicodeEscaper above(final int codePoint) { + return outsideOf(0, codePoint); + } + + /** + * Constructs a {@code JavaUnicodeEscaper} below the specified value (exclusive). + * + * @param codePoint + * below which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static JavaUnicodeEscaper below(final int codePoint) { + return outsideOf(codePoint, Integer.MAX_VALUE); + } + + /** + * Constructs a {@code JavaUnicodeEscaper} between the specified values (inclusive). + * + * @param codePointLow + * above which to escape + * @param codePointHigh + * below which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static JavaUnicodeEscaper between(final int codePointLow, final int codePointHigh) { + return new JavaUnicodeEscaper(codePointLow, codePointHigh, true); + } + + /** + * Constructs a {@code JavaUnicodeEscaper} outside of the specified values (exclusive). + * + * @param codePointLow + * below which to escape + * @param codePointHigh + * above which to escape + * @return The newly created {@code UnicodeEscaper} instance + */ + public static JavaUnicodeEscaper outsideOf(final int codePointLow, final int codePointHigh) { + return new JavaUnicodeEscaper(codePointLow, codePointHigh, false); + } + + /** + * Constructs a {@code JavaUnicodeEscaper} for the specified range. This is the underlying method for the + * other constructors/builders. The {@code below} and {@code above} boundaries are inclusive when + * {@code between} is {@code true} and exclusive when it is {@code false}. + * + * @param below + * int value representing the lowest code point boundary + * @param above + * int value representing the highest code point boundary + * @param between + * whether to escape between the boundaries or outside them + */ + public JavaUnicodeEscaper(final int below, final int above, final boolean between) { + super(below, above, between); + } + + /** + * Converts the given code point to a hexadecimal string of the form {@code "\\uXXXX\\uXXXX"}. + * + * @param codePoint + * a Unicode code point + * @return The hexadecimal string for the given code point + */ + @Override + protected String toUtf16Escape(final int codePoint) { + final char[] surrogatePair = Character.toChars(codePoint); + return "\\u" + hex(surrogatePair[0]) + "\\u" + hex(surrogatePair[1]); + } +} diff --git a/src/test/java/com/prowidesoftware/issues/Issue95.java b/src/test/java/com/prowidesoftware/issues/Issue95.java index e8cf28f69..779b3ce33 100644 --- a/src/test/java/com/prowidesoftware/issues/Issue95.java +++ b/src/test/java/com/prowidesoftware/issues/Issue95.java @@ -13,7 +13,7 @@ public void testInheritance() { assertEquals("121212USD1234,FOO", f.getValue()); } - public class MyField32A extends Field32A { + public static class MyField32A extends Field32A { public MyField32A(String value) { super(value); diff --git a/src/test/java/com/prowidesoftware/issues/JapaneseCharactersTest.java b/src/test/java/com/prowidesoftware/issues/JapaneseCharactersTest.java index 5185b74d2..8f1879fe9 100644 --- a/src/test/java/com/prowidesoftware/issues/JapaneseCharactersTest.java +++ b/src/test/java/com/prowidesoftware/issues/JapaneseCharactersTest.java @@ -21,8 +21,8 @@ import com.prowidesoftware.swift.io.RJEReader; import com.prowidesoftware.swift.model.field.Field86; import com.prowidesoftware.swift.model.mt.mt9xx.MT940; -import com.prowidesoftware.swift.utils.Lib; import java.io.IOException; +import java.io.InputStream; import java.nio.charset.StandardCharsets; import org.junit.jupiter.api.Test; @@ -33,33 +33,40 @@ public class JapaneseCharactersTest { @Test public void testRJEFromFile() throws IOException { - RJEReader reader = - new RJEReader(this.getClass().getResourceAsStream("/sample_JPchar.txt"), StandardCharsets.UTF_8); - MT940 mt = (MT940) reader.nextMT(); - assertNotNull(mt); - Field86 field86 = mt.getField86().get(0); - // System.out.println(mt.message()); - assertEquals("゙アタイヘイヨウセンタ- AFEISEOHFIOSEIOIRT", field86.getComponent2()); + try (InputStream inputStream = JapaneseCharactersTest.class.getResourceAsStream("/sample_JPchar.txt")) { + RJEReader reader = new RJEReader(inputStream, StandardCharsets.UTF_8); + MT940 mt = (MT940) reader.nextMT(); + assertNotNull(mt); + Field86 field86 = mt.getField86().get(0); + // System.out.println(mt.message()); + assertEquals("゙アタイヘイヨウセンタ- AFEISEOHFIOSEIOIRT", field86.getComponent2()); + } } @Test public void testRJEFromFile2() throws IOException { - RJEReader reader = new RJEReader( - Lib.readStream(this.getClass().getResourceAsStream("/sample_JPchar.txt"), StandardCharsets.UTF_8)); - MT940 mt = (MT940) reader.nextMT(); - assertNotNull(mt); - Field86 field86 = mt.getField86().get(0); - // System.out.println(mt.message()); - assertEquals("゙アタイヘイヨウセンタ- AFEISEOHFIOSEIOIRT", field86.getComponent2()); + try (InputStream inputStream = JapaneseCharactersTest.class.getResourceAsStream("/sample_JPchar.txt")) { + RJEReader reader = new RJEReader(inputStream, StandardCharsets.UTF_8); + MT940 mt = (MT940) reader.nextMT(); + assertNotNull(mt); + Field86 field86 = mt.getField86().get(0); + // System.out.println(mt.message()); + assertEquals("゙アタイヘイヨウセンタ- AFEISEOHFIOSEIOIRT", field86.getComponent2()); + } } @Test public void testMTFromFile() throws IOException { - MT940 mt = new MT940(this.getClass().getResourceAsStream("/sample_JPchar.txt")); - assertNotNull(mt); - Field86 field86 = mt.getField86().get(0); - // System.out.println(mt.message()); - assertEquals("゙アタイヘイヨウセンタ- AFEISEOHFIOSEIOIRT", field86.getComponent2()); + try (InputStream resourceStream = JapaneseCharactersTest.class.getResourceAsStream("/sample_JPchar.txt")) { + if (resourceStream == null) { + throw new IOException("Resource not found: MT101.fin"); + } + MT940 mt = new MT940(resourceStream); + assertNotNull(mt); + Field86 field86 = mt.getField86().get(0); + // System.out.println(mt.message()); + assertEquals("゙アタイヘイヨウセンタ- AFEISEOHFIOSEIOIRT", field86.getComponent2()); + } } @Test diff --git a/src/test/java/com/prowidesoftware/swift/constraints/IbanValidatorTest.java b/src/test/java/com/prowidesoftware/swift/constraints/IbanValidatorTest.java new file mode 100644 index 000000000..861e51b31 --- /dev/null +++ b/src/test/java/com/prowidesoftware/swift/constraints/IbanValidatorTest.java @@ -0,0 +1,266 @@ +package com.prowidesoftware.swift.constraints; + +import static org.junit.jupiter.api.Assertions.*; + +import com.prowidesoftware.swift.model.IBAN; +import com.prowidesoftware.swift.model.IbanValidationResult; +import javax.validation.ClockProvider; +import javax.validation.ConstraintValidatorContext; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Disabled; +import org.junit.jupiter.api.Test; + +public class IbanValidatorTest { + + private IbanValidator validator; + private TestConstraintValidatorContext context; + + @BeforeEach + public void setUp() { + validator = new IbanValidator(); + context = new TestConstraintValidatorContext(); + } + + @Test + public void testValidIban() { + String validIban = "ES9121000418450200051332"; // A valid IBAN + assertEquals(IbanValidationResult.OK, new IBAN(validIban).validate()); + assertTrue(validator.isValid(validIban, context)); + assertFalse(context.isViolationOccurred()); + } + + @Test + public void testIbanIsNull() { + String nullIban = null; + assertEquals(IbanValidationResult.IBAN_IS_NULL, new IBAN(nullIban).validate()); + assertTrue(validator.isValid(nullIban, context)); + assertFalse(context.isViolationOccurred()); + assertNull(context.getViolationMessage()); + } + + @Test + public void testIbanIsEmpty() { + String emptyIban = ""; + assertEquals(IbanValidationResult.IBAN_IS_EMPTY, new IBAN(emptyIban).validate()); + assertTrue(validator.isValid(emptyIban, context)); + assertFalse(context.isViolationOccurred()); + assertNull(context.getViolationMessage()); + } + + @Test + public void testMissingCountryCode() { + String missingCountryCodeIban = "1"; + assertEquals(IbanValidationResult.MISSING_COUNTRY_CODE, new IBAN(missingCountryCodeIban).validate()); + assertFalse(validator.isValid(missingCountryCodeIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("The IBAN must start with the two letters ISO country code", context.getViolationMessage()); + } + + @Test + public void testInvalidCountryCodeCharset() { + String invalidCountryCodeIban = "es123456789"; // Lowercase 'es' instead of uppercase + assertEquals(IbanValidationResult.INVALID_COUNTRY_CODE_CHARSET, new IBAN(invalidCountryCodeIban).validate()); + assertFalse(validator.isValid(invalidCountryCodeIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals( + "The country code must contain upper case letters and es was found", context.getViolationMessage()); + } + + @Test + public void testInvalidCountry() { + String invalidCountryCodeIban = "ZZ123456789"; + assertEquals(IbanValidationResult.INVALID_COUNTRY_CODE, new IBAN(invalidCountryCodeIban).validate()); + assertFalse(validator.isValid(invalidCountryCodeIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals( + "The country code ZZ is not a valid ISO country code or the country code is not configured for IBAN validations", + context.getViolationMessage()); + } + + @Test + public void testMissingCheckDigits() { + String missingCheckDigitsIban = "ESX"; + assertEquals(IbanValidationResult.MISSING_CHECK_DIGITS, new IBAN(missingCheckDigitsIban).validate()); + assertFalse(validator.isValid(missingCheckDigitsIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("Missing check digits", context.getViolationMessage()); + } + + @Test + public void testInvalidCheckDigitsFormat() { + String invalidCheckDigitsFormatIban = "ESAB123456789"; // Non-numeric check digits + assertEquals( + IbanValidationResult.INVALID_CHECK_DIGITS_FORMAT, new IBAN(invalidCheckDigitsFormatIban).validate()); + assertFalse(validator.isValid(invalidCheckDigitsFormatIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("Expected 2 check digits and found AB", context.getViolationMessage()); + } + + @Test + public void testMissingBban() { + String missingBbanIban = "ES64"; // Country code + check digits, but no BBAN + assertEquals(IbanValidationResult.MISSING_BBAN, new IBAN(missingBbanIban).validate()); + assertFalse(validator.isValid(missingBbanIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("Missing custom account number (BBAN)", context.getViolationMessage()); + } + + @Test + public void testBbanMaxLengthExceeded() { + String bbanMaxLengthExceededIban = "ES640123456789012345678901234567890"; // Exceeding max BBAN length + assertEquals(IbanValidationResult.BBAN_MAX_LENGTH, new IBAN(bbanMaxLengthExceededIban).validate()); + assertFalse(validator.isValid(bbanMaxLengthExceededIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals( + "The max length for the custom account number (BBAN) is 30 and found 31", + context.getViolationMessage()); + } + + @Test + public void testMissingBbanConfiguration() { + String missingBbanConfigIban = "FK64123456789"; + assertEquals(IbanValidationResult.MISSING_BBAN_CONFIGURATION, new IBAN(missingBbanConfigIban).validate()); + assertFalse(validator.isValid(missingBbanConfigIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals( + "Missing custom account number (BBAN) configuration for country FK", context.getViolationMessage()); + } + + @Test + public void testInvalidBbanLength() { + String invalidBbanLengthIban = "ES6401234"; // Invalid BBAN length + assertEquals(IbanValidationResult.BBAN_INVALID_LENGTH, new IBAN(invalidBbanLengthIban).validate()); + assertFalse(validator.isValid(invalidBbanLengthIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals( + "Expected a 20 characters length for the custom account number (BBAN) and found 5 in 01234", + context.getViolationMessage()); + } + + @Test + public void testBbanInvalidUpperCaseLetters() { + String invalidUpperCaseIban = "GI75nWBK000000007099453"; // BBAN with lowercase letters + assertEquals(IbanValidationResult.BBAN_INVALID_UPPER_CASE_LETTERS, new IBAN(invalidUpperCaseIban).validate()); + assertFalse(validator.isValid(invalidUpperCaseIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("The BANK_CODE nWBK must contain only upper case letters", context.getViolationMessage()); + } + + @Test + public void testBbanInvalidDigitsOrLetters() { + String invalidDigitsOrLettersIban = "GI75NWBK00000000709t453"; // BBAN with invalid characters + assertEquals( + IbanValidationResult.BBAN_INVALID_DIGITS_OR_LETTERS, new IBAN(invalidDigitsOrLettersIban).validate()); + assertFalse(validator.isValid(invalidDigitsOrLettersIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals( + "The ACCOUNT_NUMBER 00000000709t453 must contain only digits or upper case letters", + context.getViolationMessage()); + } + + @Test + public void testBbanInvalidDigits() { + String invalidDigitsIban = "ES640abcd100041845024502"; // BBAN with letters where digits expected + assertEquals(IbanValidationResult.BBAN_INVALID_DIGITS, new IBAN(invalidDigitsIban).validate()); + assertFalse(validator.isValid(invalidDigitsIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("The BANK_CODE 0abc must contain only digits", context.getViolationMessage()); + } + + @Disabled + @Test + public void testInvalidCharacters() { + // TODO: find a input that can produce this result + String invalidCharactersIban = "ES0X1234000000007094532"; + assertEquals(IbanValidationResult.INVALID_CHARACTERS, new IBAN(invalidCharactersIban).validate()); + assertFalse(validator.isValid(invalidCharactersIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("Invalid character '@' found", context.getViolationMessage()); + } + + @Test + public void testInvalidCheckDigits() { + String invalidCheckDigitsIban = "ES0012345678901234567890"; // Invalid computed check digits + assertEquals(IbanValidationResult.IVALID_CHECK_DIGITS, new IBAN(invalidCheckDigitsIban).validate()); + assertFalse(validator.isValid(invalidCheckDigitsIban, context)); + assertTrue(context.isViolationOccurred()); + assertEquals("The expected computed check digit is 98 and 00 was found", context.getViolationMessage()); + } + + /** + * Simulated implementation of ConstraintValidatorContext for testing + */ + static class TestConstraintValidatorContext implements ConstraintValidatorContext { + + private boolean violationOccurred = false; + private String violationMessage = null; + + @Override + public void disableDefaultConstraintViolation() { + violationOccurred = true; + } + + @Override + public String getDefaultConstraintMessageTemplate() { + return null; + } + + @Override + public ClockProvider getClockProvider() { + return null; + } + + @Override + public ConstraintViolationBuilder buildConstraintViolationWithTemplate(String messageTemplate) { + this.violationMessage = messageTemplate; + return new TestConstraintViolationBuilder(); + } + + public boolean isViolationOccurred() { + return violationOccurred; + } + + public String getViolationMessage() { + return violationMessage; + } + + @Override + public T unwrap(Class type) { + return null; + } + + // Simulated ConstraintViolationBuilder implementation + class TestConstraintViolationBuilder implements ConstraintViolationBuilder { + @Override + public NodeBuilderDefinedContext addNode(String name) { + return null; + } + + @Override + public NodeBuilderCustomizableContext addPropertyNode(String name) { + return null; + } + + @Override + public LeafNodeBuilderCustomizableContext addBeanNode() { + return null; + } + + @Override + public ContainerElementNodeBuilderCustomizableContext addContainerElementNode( + String name, Class containerType, Integer index) { + return null; + } + + @Override + public NodeBuilderDefinedContext addParameterNode(int index) { + return null; + } + + @Override + public ConstraintValidatorContext addConstraintViolation() { + return TestConstraintValidatorContext.this; + } + } + } +} diff --git a/src/test/java/com/prowidesoftware/swift/io/RJEReaderTest.java b/src/test/java/com/prowidesoftware/swift/io/RJEReaderTest.java index 85bf77c06..b23518491 100644 --- a/src/test/java/com/prowidesoftware/swift/io/RJEReaderTest.java +++ b/src/test/java/com/prowidesoftware/swift/io/RJEReaderTest.java @@ -20,6 +20,7 @@ import com.prowidesoftware.swift.model.SwiftMessage; import com.prowidesoftware.swift.model.mt.AbstractMT; import java.io.IOException; +import java.io.InputStream; import java.nio.charset.StandardCharsets; import org.junit.jupiter.api.Test; @@ -32,16 +33,17 @@ public class RJEReaderTest { @Test - public void testIterator() { - RJEReader r = - new RJEReader(this.getClass().getResourceAsStream("/MT103-out-ack.rje"), StandardCharsets.US_ASCII); - int count = 0; - for (String m : r) { - assertNotNull(m); - // System.out.println("msg "+(count)); - count++; + public void testIterator() throws IOException { + try (InputStream inputStream = RJEReaderTest.class.getResourceAsStream("/MT103-out-ack.rje")) { + RJEReader r = new RJEReader(inputStream, StandardCharsets.US_ASCII); + int count = 0; + for (String m : r) { + assertNotNull(m); + // System.out.println("msg "+(count)); + count++; + } + assertEquals(13, count); } - assertEquals(13, count); } @Test @@ -69,13 +71,14 @@ public void testIteratorNotReentrant() { @Test public void testIterableWithNextMT() throws IOException { - RJEReader r = - new RJEReader(this.getClass().getResourceAsStream("/MT103-out-ack.rje"), StandardCharsets.US_ASCII); - assertTrue(r.hasNext()); - AbstractMT mt = r.nextMT(); - assertNotNull(mt); - // System.out.println(mt.message()); - assertEquals("103", mt.getMessageType()); + try (InputStream inputStream = RJEReaderTest.class.getResourceAsStream("/MT103-out-ack.rje")) { + RJEReader r = new RJEReader(inputStream, StandardCharsets.US_ASCII); + assertTrue(r.hasNext()); + AbstractMT mt = r.nextMT(); + assertNotNull(mt); + // System.out.println(mt.message()); + assertEquals("103", mt.getMessageType()); + } } @Test @@ -98,19 +101,23 @@ public void testDeliveryNotification() throws IOException { @Test public void testBulkFileWithAcks() throws IOException { - RJEReader r = new RJEReader( - this.getClass().getResourceAsStream("/MT103-bulk-with-ack.rje"), StandardCharsets.US_ASCII); - int count = 0; - while (r.hasNext()) { - SwiftMessage ack = r.nextSwiftMessage(); - assertNotNull(ack); - assertTrue(ack.isServiceMessage21()); - SwiftMessage mt = SwiftMessage.parse(ack.getUnparsedTexts().getAsFINString()); - assertNotNull(mt); - assertTrue(mt.isType(103)); - // System.out.println(mt.getBlock4().getTagValue("20")); - count++; + try (InputStream inputStream = RJEReaderTest.class.getResourceAsStream("/MT103-bulk-with-ack.rje")) { + RJEReader r = new RJEReader(inputStream, StandardCharsets.US_ASCII); + assertNotNull(inputStream, "The input stream could not be found"); + + int count = 0; + while (r.hasNext()) { + SwiftMessage ack = r.nextSwiftMessage(); + assertNotNull(ack); + assertTrue(ack.isServiceMessage21()); + + SwiftMessage mt = SwiftMessage.parse(ack.getUnparsedTexts().getAsFINString()); + assertNotNull(mt); + assertTrue(mt.isType(103)); + // System.out.println(mt.getBlock4().getTagValue("20")); + count++; + } + assertEquals(3, count); } - assertEquals(3, count); } } diff --git a/src/test/java/com/prowidesoftware/swift/io/parser/BaseMessageTestcase.java b/src/test/java/com/prowidesoftware/swift/io/parser/BaseMessageTestcase.java index 9c3cde2c2..593129adb 100644 --- a/src/test/java/com/prowidesoftware/swift/io/parser/BaseMessageTestcase.java +++ b/src/test/java/com/prowidesoftware/swift/io/parser/BaseMessageTestcase.java @@ -46,11 +46,15 @@ protected SwiftParser buildParser(String filename) { } protected InputStream getInputStream(String filename) { - InputStream is = getClass().getResourceAsStream(filename); - if (is == null) { + try (InputStream is = BaseMessageTestcase.class.getResourceAsStream(filename)) { + if (is == null) { + fail(filename + " not found in classpath"); + } + return is; + } catch (IOException e) { fail(filename + " not found in classpath"); + return null; } - return is; } protected String readMessageFromInputStream(InputStream is) { diff --git a/src/test/java/com/prowidesoftware/swift/io/parser/ParserTest.java b/src/test/java/com/prowidesoftware/swift/io/parser/ParserTest.java index b3afd3ba7..00154f4e6 100644 --- a/src/test/java/com/prowidesoftware/swift/io/parser/ParserTest.java +++ b/src/test/java/com/prowidesoftware/swift/io/parser/ParserTest.java @@ -53,9 +53,14 @@ public void testParse101() { */ @Test public void testParse101Stream() throws IOException { - MT101 mt = MT101.parse(getClass().getResourceAsStream("/MT101.fin")); - SwiftMessage msg = mt.getSwiftMessage(); - assertMT101(msg); + try (InputStream resourceStream = ParserTest.class.getResourceAsStream("/MT101.fin")) { + if (resourceStream == null) { + throw new IOException("Resource not found: MT101.fin"); + } + MT101 mt = MT101.parse(resourceStream); + SwiftMessage msg = mt.getSwiftMessage(); + assertMT101(msg); + } } /* diff --git a/src/test/java/com/prowidesoftware/swift/io/parser/SwiftParserConsumeBlockLenientTest.java b/src/test/java/com/prowidesoftware/swift/io/parser/SwiftParserConsumeBlockLenientTest.java index 3c9fe34da..d4d5a27fe 100644 --- a/src/test/java/com/prowidesoftware/swift/io/parser/SwiftParserConsumeBlockLenientTest.java +++ b/src/test/java/com/prowidesoftware/swift/io/parser/SwiftParserConsumeBlockLenientTest.java @@ -304,7 +304,7 @@ public void testSimpleBlockConsumerBlock3_3_KnownToFail() throws IOException { assertEquals("00112233", b.getTagValue("108")); assertTrue(b.containsTag("4")); assertEquals("foobar", b.getTagValue("4")); - assertEquals(b.getUnparsedTextsSize(), new Integer(1)); + assertEquals(b.getUnparsedTextsSize(), Integer.valueOf(1)); assertEquals(b.unparsedTextGetText(0), "blockdata"); } diff --git a/src/test/java/com/prowidesoftware/swift/model/IBANValidateTest.java b/src/test/java/com/prowidesoftware/swift/model/IBANValidateTest.java new file mode 100644 index 000000000..9d85778e9 --- /dev/null +++ b/src/test/java/com/prowidesoftware/swift/model/IBANValidateTest.java @@ -0,0 +1,224 @@ +/* + * Copyright 2006-2023 Prowide + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.prowidesoftware.swift.model; + +import static org.junit.jupiter.api.Assertions.*; + +import org.junit.jupiter.api.Test; + +public class IBANValidateTest { + + @Test + public void testIsValidFoooo() { + assertFalse(IbanValidationResult.OK == IBAN.validate("fooo")); + } + + @Test + public void testIsValidFo00() { + assertFalse(IbanValidationResult.OK == IBAN.validate("fo00")); + } + + @Test + public void testReportedBad() { + assertTrue(IbanValidationResult.OK == IBAN.validate("CH10002300A1023502601")); + } + + @Test + public void testOkAustrian() { + assertEquals(IbanValidationResult.OK, IBAN.validate("AT611904300234573201")); + } + + @Test + public void testInvalidBbanAustrian() { + assertFalse(IbanValidationResult.OK == IBAN.validate("AT32010000000173363")); + } + + @Test + public void testOKSeychelles() { + assertEquals(IbanValidationResult.OK, IBAN.validate("SC52BAHL01031234567890123456USD")); + } + + @Test + public void testOKItaly() { + assertEquals(IbanValidationResult.OK, IBAN.validate("IT40S0542811101000000123456")); + } + + @Test + public void testOKBelgiumOK() { + assertEquals(IbanValidationResult.OK, IBAN.validate("BE62510007547061")); + } + + @Test + public void testOKLuxembourg() { + assertEquals(IbanValidationResult.OK, IBAN.validate("LU280019400644750000")); + } + + @Test + public void testOKDenmark() { + assertEquals(IbanValidationResult.OK, IBAN.validate("DK5000400440116243")); + } + + @Test + public void testOKNetherlands() { + assertEquals(IbanValidationResult.OK, IBAN.validate("NL39RABO0300065264")); + } + + @Test + public void testOKFinland() { + assertEquals(IbanValidationResult.OK, IBAN.validate("FI2112345600000785")); + } + + @Test + public void testOKNorway() { + assertEquals(IbanValidationResult.OK, IBAN.validate("NO9386011117947")); + } + + @Test + public void testOKFrance() { + assertEquals(IbanValidationResult.OK, IBAN.validate("FR1420041010050500013M02606")); + } + + @Test + public void testOKPoland() { + assertEquals(IbanValidationResult.OK, IBAN.validate("PL60102010260000042270201111")); + } + + @Test + public void testOKGermany() { + assertEquals(IbanValidationResult.OK, IBAN.validate("DE89370400440532013000")); + } + + @Test + public void testOKPortugal() { + assertEquals(IbanValidationResult.OK, IBAN.validate("PT50000201231234567890154")); + } + + @Test + public void testOKGibraltar() { + assertEquals(IbanValidationResult.OK, IBAN.validate("GI75NWBK000000007099453")); + } + + @Test + public void testOKSpain() { + assertEquals(IbanValidationResult.OK, IBAN.validate("ES0700120345030000067890")); + } + + @Test + public void testOKGreece() { + assertEquals(IbanValidationResult.OK, IBAN.validate("GR1601101250000000012300695")); + } + + @Test + public void testOKSweden() { + assertEquals(IbanValidationResult.OK, IBAN.validate("SE3550000000054910000003")); + } + + @Test + public void testOKIceland() { + assertEquals(IbanValidationResult.OK, IBAN.validate("IS140159260076545510730339")); + } + + @Test + public void testOKSwitzerland() { + assertEquals(IbanValidationResult.OK, IBAN.validate("CH9300762011623852957")); + } + + @Test + public void testOKIreland() { + assertEquals(IbanValidationResult.OK, IBAN.validate("IE29AIBK93115212345678")); + } + + @Test + public void testSpaceGreatBritain() { + assertTrue(IBAN.validate(" GB51 LOYD 3092 0700 7195 88.") == IbanValidationResult.INVALID_COUNTRY_CODE_CHARSET); + } + + @Test + public void testErrorEmpty() { + assertTrue(IBAN.validate("") == IbanValidationResult.IBAN_IS_EMPTY); + } + + @Test + public void testErrorNull() { + assertTrue(IBAN.validate(null) == IbanValidationResult.IBAN_IS_NULL); + } + + @Test + public void testErrorMissingBban() { + assertTrue(IBAN.validate("IE99") == IbanValidationResult.MISSING_BBAN); + } + + @Test + public void testErrorBbanMaxLength() { + assertTrue(IBAN.validate("IE991234567890123456789012345678901") == IbanValidationResult.BBAN_MAX_LENGTH); + } + + @Test + public void testErrorBbanLength() { + IbanValidationResult result = IBAN.validate("AT32010000000173363"); + assertTrue(result == IbanValidationResult.BBAN_INVALID_LENGTH); + // System.out.println(result.message()); + } + + @Test + public void testErrorCountry() { + IbanValidationResult result = IBAN.validate("aa17002001280000001200527600"); + assertTrue(result == IbanValidationResult.INVALID_COUNTRY_CODE_CHARSET); + // System.out.println(result.message()); + result = IBAN.validate("ZZ17002001280000001200527600"); + assertTrue(result == IbanValidationResult.INVALID_COUNTRY_CODE); + // System.out.println(result.message()); + } + + @Test + public void testValidateCheckDigitPresence() { + IbanValidationResult result = IBAN.validate("AT1"); + assertTrue(result == IbanValidationResult.MISSING_CHECK_DIGITS); + } + + @Test + public void testValidateBbanInvalidDigits() { + IbanValidationResult result = IBAN.validate("DK5000400T40116243"); + assertTrue(result == IbanValidationResult.BBAN_INVALID_DIGITS); + } + + @Test + public void testValidateBbanInvalidDigitsOrLetters() { + IbanValidationResult result = IBAN.validate("GI75NWBK00000000709t453"); + assertTrue(result == IbanValidationResult.BBAN_INVALID_DIGITS_OR_LETTERS); + // System.out.println(result.message()); + } + + @Test + public void testValidateBbanInvalidUpperCaseLetters() { + IbanValidationResult result = IBAN.validate("GI75nWBK000000007099453"); + assertTrue(result == IbanValidationResult.BBAN_INVALID_UPPER_CASE_LETTERS); + // System.out.println(result.message()); + } + + @Test + public void testCodes() { + assertEquals(IbanValidationResult.OK, IBAN.validate("CY17002001280000001200527600")); + assertEquals(IbanValidationResult.OK, IBAN.validate("IE62BOFI90381614262992")); + assertEquals(IbanValidationResult.OK, IBAN.validate("GB61CHAS60924232466601")); + assertEquals(IbanValidationResult.OK, IBAN.validate("EG389004000100300074201200001")); + assertEquals(IbanValidationResult.BBAN_INVALID_LENGTH, IBAN.validate("GB45-LOYD-3092-0711-1072-32")); + assertEquals(IbanValidationResult.BBAN_INVALID_LENGTH, IBAN.validate("SE76 8000.08105903-7676/5343")); + assertEquals(IbanValidationResult.BBAN_INVALID_LENGTH, IBAN.validate("GB97CHAS60924232684106*&^%()!@")); + assertEquals(IbanValidationResult.INVALID_COUNTRY_CODE_CHARSET, IBAN.validate(" NL76 FTSB 084.47.26.494")); + assertEquals(IbanValidationResult.INVALID_COUNTRY_CODE_CHARSET, IBAN.validate(" FI8916603000104953")); + } +} diff --git a/src/test/java/com/prowidesoftware/swift/model/UnparsedTextListTest.java b/src/test/java/com/prowidesoftware/swift/model/UnparsedTextListTest.java index 79d6f052d..a8f0b40c0 100644 --- a/src/test/java/com/prowidesoftware/swift/model/UnparsedTextListTest.java +++ b/src/test/java/com/prowidesoftware/swift/model/UnparsedTextListTest.java @@ -57,7 +57,7 @@ public void test_staticIsMessage() { @Test public void test_addText() { t.addText(someText); - assertEquals(t.size(), new Integer(1)); + assertEquals(t.size(), Integer.valueOf(1)); assertEquals(t.getText(0), someText); } @@ -71,9 +71,9 @@ public void test_isMessage() { @Test public void test_size() { - assertEquals(t.size(), new Integer(0)); + assertEquals(t.size(), Integer.valueOf(0)); t.addText(someText); - assertEquals(t.size(), new Integer(1)); + assertEquals(t.size(), Integer.valueOf(1)); } @Test @@ -111,7 +111,7 @@ public void test_addTextMessage() { t.addText(msg); // check things out - assertEquals(t.size(), new Integer(1)); + assertEquals(t.size(), Integer.valueOf(1)); assertEquals(t.getText(0), msgString); } @@ -121,7 +121,7 @@ public void test_removeIndexOK() { t.addText(someMsg); t.removeText(0); assertEquals(t.getText(0), someMsg); - assertEquals(t.size(), new Integer(1)); + assertEquals(t.size(), Integer.valueOf(1)); } @Test @@ -135,7 +135,7 @@ public void test_removeText() { t.addText(someMsg); t.removeText(someText); assertEquals(t.getText(0), someMsg); - assertEquals(t.size(), new Integer(1)); + assertEquals(t.size(), Integer.valueOf(1)); } @Test diff --git a/src/test/java/com/prowidesoftware/swift/model/field/FieldComponentLabelsCompatibilityTest.java b/src/test/java/com/prowidesoftware/swift/model/field/FieldComponentLabelsCompatibilityTest.java index 7ddbf17cb..46b63c110 100644 --- a/src/test/java/com/prowidesoftware/swift/model/field/FieldComponentLabelsCompatibilityTest.java +++ b/src/test/java/com/prowidesoftware/swift/model/field/FieldComponentLabelsCompatibilityTest.java @@ -16,6 +16,7 @@ package com.prowidesoftware.swift.model.field; import java.io.BufferedReader; +import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; import java.net.URL; @@ -33,14 +34,19 @@ public static List getClasses(ClassLoader cl, String pack) throws Excepti String dottedPackage = pack.replaceAll("[/]", "."); List classes = new ArrayList<>(); URL upackage = cl.getResource(pack); - BufferedReader reader = new BufferedReader(new InputStreamReader((InputStream) upackage.getContent())); - String line = null; - while ((line = reader.readLine()) != null) { - if (line.endsWith(".class") - && line.startsWith("Field") - && !line.contains("Test") - && !line.equals("Field.class")) { - classes.add(Class.forName(dottedPackage + "." + line.substring(0, line.lastIndexOf('.')))); + if (upackage == null) { + throw new IOException("Package not found: " + pack); + } + + try (BufferedReader reader = new BufferedReader(new InputStreamReader((InputStream) upackage.getContent()))) { + String line; + while ((line = reader.readLine()) != null) { + if (line.endsWith(".class") + && line.startsWith("Field") + && !line.contains("Test") + && !line.equals("Field.class")) { + classes.add(Class.forName(dottedPackage + "." + line.substring(0, line.lastIndexOf('.')))); + } } } return classes; diff --git a/src/test/java/com/prowidesoftware/swift/model/mt/AbstractMTTest.java b/src/test/java/com/prowidesoftware/swift/model/mt/AbstractMTTest.java index 88726c765..697091362 100644 --- a/src/test/java/com/prowidesoftware/swift/model/mt/AbstractMTTest.java +++ b/src/test/java/com/prowidesoftware/swift/model/mt/AbstractMTTest.java @@ -303,11 +303,11 @@ public void testMTClassParse() { } @Test - public void testAbstractMt() throws IOException { - Integer type = 9; + public void testAbstractMt() { + int type = 9; try { - AbstractMT aMt = AbstractMT.create(type); + AbstractMT.create(type); } catch (Exception e) { fail("No exception expected"); } diff --git a/src/test/java/com/prowidesoftware/swift/utils/ConstraintUtilsTest.java b/src/test/java/com/prowidesoftware/swift/utils/ConstraintUtilsTest.java new file mode 100644 index 000000000..ed4984132 --- /dev/null +++ b/src/test/java/com/prowidesoftware/swift/utils/ConstraintUtilsTest.java @@ -0,0 +1,18 @@ +package com.prowidesoftware.swift.utils; + +import static org.junit.jupiter.api.Assertions.*; + +import org.junit.jupiter.api.Test; + +class ConstraintUtilsTest { + + @Test + public void testEscapeScript() { + assertNull(ConstraintUtils.escapeScript(null)); + assertEquals("He didn\\'t say, \\\"stop!\\\"", ConstraintUtils.escapeScript("He didn't say, \"stop!\"")); + assertEquals( + "document.getElementById(\\\"test\\\").value = \\'';")); + } +} diff --git a/src/test/java/com/prowidesoftware/swift/utils/SwiftFormatUtilsTest.java b/src/test/java/com/prowidesoftware/swift/utils/SwiftFormatUtilsTest.java index a69a27c82..3b3f1a2cc 100644 --- a/src/test/java/com/prowidesoftware/swift/utils/SwiftFormatUtilsTest.java +++ b/src/test/java/com/prowidesoftware/swift/utils/SwiftFormatUtilsTest.java @@ -44,29 +44,33 @@ public void testGetNumber() { assertNotNull(SwiftFormatUtils.getNumber("1,2")); assertEquals( - new Double(1.2), new Double(SwiftFormatUtils.getNumber("1,2").doubleValue())); + Double.valueOf(1.2), + Double.valueOf(SwiftFormatUtils.getNumber("1,2").doubleValue())); assertNotNull(SwiftFormatUtils.getNumber("12,34")); assertEquals( - new Double(12.34), - new Double(SwiftFormatUtils.getNumber("12,34").doubleValue())); + Double.valueOf(12.34), + Double.valueOf(SwiftFormatUtils.getNumber("12,34").doubleValue())); assertNotNull(SwiftFormatUtils.getNumber("12,3456")); assertEquals( - new Double(12.3456), - new Double(SwiftFormatUtils.getNumber("12,3456").doubleValue())); + Double.valueOf(12.3456), + Double.valueOf(SwiftFormatUtils.getNumber("12,3456").doubleValue())); assertNotNull(SwiftFormatUtils.getNumber("0,")); - assertEquals(new Double(0), new Double(SwiftFormatUtils.getNumber("0,").doubleValue())); + assertEquals( + Double.valueOf(0), + Double.valueOf(SwiftFormatUtils.getNumber("0,").doubleValue())); assertNotNull(SwiftFormatUtils.getNumber("299000,34")); assertEquals( - new Double(299000.34), - new Double(SwiftFormatUtils.getNumber("299000,34").doubleValue())); + Double.valueOf(299000.34), + Double.valueOf(SwiftFormatUtils.getNumber("299000,34").doubleValue())); assertNotNull(SwiftFormatUtils.getNumber(",34")); assertEquals( - new Double(0.34), new Double(SwiftFormatUtils.getNumber(",34").doubleValue())); + Double.valueOf(0.34), + Double.valueOf(SwiftFormatUtils.getNumber(",34").doubleValue())); } @Test