package com.brilliance.isc.convert.mt7xx;

import com.brilliance.isc.swift.objmtconvert.manager.MtCreatorManager;
import com.brilliance.isc.swift.objmtconvert.model.mt7xx.MT799Creator;
import org.junit.Test;
import java.util.LinkedList;
import java.util.List;


public class MT799Test {
    /**
     * @author wuzhe
     * @date 2023/3/3
     */
    @Test
    public void mt799_Test() {

        //构造参数传入MT报文类型
        MT799Creator mt799Creator=new MT799Creator("799");//报文类型
        mt799Creator.setRecvBic("CIPSCNSHXXX");//收报行
        mt799Creator.setSendBic("PSBCCNBJXXX");//发报行
        //20 16x
        mt799Creator.setTransactionReferenceNumber("1PG8761234");
        //79 35*50x 循环
        List<String> list79 = new LinkedList<>();
        list79.add("Narrative");
        list79.add("Narrative");
        mt799Creator.setNarrative(list79);

        //非必选项
        //21 16x
        mt799Creator.setRelatedReference("AG5559823");

        MtCreatorManager.packMT(mt799Creator);
    }

    @Test
    public void mt799_Test2() {

        //构造参数传入MT报文类型
        MT799Creator mt799Creator=new MT799Creator("799");//报文类型
        mt799Creator.setRecvBic("CIPSCNSHXXX");//收报行
        mt799Creator.setSendBic("PSBCCNBJXXX");//发报行
        //20 16x
        mt799Creator.setTransactionReferenceNumber("1PG8761234");
        //79 35*50x 循环
        List<String> list79 = new LinkedList<>();
        list79.add("Narrative");
        list79.add("Narrative");
        list79.add("Narrative");
        mt799Creator.setNarrative(list79);

        //非必选项
        //21 16x
        mt799Creator.setRelatedReference("AG5559823");

        MtCreatorManager.packMT(mt799Creator);
    }
}