배치 jobItem 파일 수정

This commit is contained in:
임장현
2026-06-05 17:00:26 +09:00
parent b63086c134
commit 2cf94a3de8
108 changed files with 161 additions and 162 deletions
@@ -105,7 +105,7 @@ public class RECV_BI0400 extends DefaultTelegram implements TelegramService
}
for (int i=0; i<seq_no; i++){
miss_data.put(new Integer(i), "1");
miss_data.put(i, "1");
}
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
} else {//수신된 데이터가 seq크기만큼 안되면 처음부터 다시..
@@ -73,7 +73,7 @@ public class RECV_BI0410 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(i) , fileData);
block_data.put(i, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
}
@@ -78,15 +78,15 @@ public class RECV_BI0420 extends DefaultTelegram implements TelegramService
if (first_miss_field == null){
first_miss_field = new HashMap<String, Integer>();
first_miss_field.put(JobProcessData.PROCDATA_FIRST_MISS, new Integer(seq_no+1));
first_miss_field.put(JobProcessData.PROCDATA_FIRST_MISS, seq_no + 1);
hm.put(JobProcessData.PROCDATA_FIRST_MISS, first_miss_field);
for (int i=seq_no; i<recv_seq_no; i++){//중간에 결번이 생긴 부분은 결번으로 셋팅
miss_data.put(new Integer(i), "0");
miss_data.put(i, "0");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
last_miss_field = new HashMap<String, Integer>();
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, new Integer(i));
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, i);
hm.put(JobProcessData.PROCDATA_LAST_MISS, last_miss_field);
missCount = missCount+1;
@@ -96,11 +96,11 @@ public class RECV_BI0420 extends DefaultTelegram implements TelegramService
} else { //이전에 miss_field가 있으면
for (int i=seq_no; i<recv_seq_no; i++){//중간에 결번이 생긴 부분은 결번으로 셋팅
miss_data.put(new Integer(i), "0");
miss_data.put(i, "0");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
last_miss_field = new HashMap<String, Integer>();
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, new Integer(i));
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, i);
hm.put(JobProcessData.PROCDATA_LAST_MISS, last_miss_field);
missCount = missCount+1;
@@ -119,20 +119,20 @@ public class RECV_BI0700 extends DefaultTelegram implements TelegramService
}
fout.write(bout.toByteArray());
miss_data.put(new Integer(recv_seq_no-1), "1");
miss_data.put(recv_seq_no - 1, "1");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
}else { //결번이 발생한 경우이면 메모리에 저장.
first_miss_field = new HashMap<String, Integer>();
first_miss_field.put(JobProcessData.PROCDATA_FIRST_MISS, new Integer(seq_no+1));
first_miss_field.put(JobProcessData.PROCDATA_FIRST_MISS, seq_no + 1);
hm.put(JobProcessData.PROCDATA_FIRST_MISS, first_miss_field);
last_miss_field = new HashMap<String, Integer>();
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, new Integer(seq_no+1));
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, seq_no + 1);
hm.put(JobProcessData.PROCDATA_LAST_MISS, last_miss_field);
for (int i=seq_no+1; i<recv_seq_no; i++){//중간에 결번이 생긴 부분은 결번으로 셋팅
miss_data.put(new Integer(i-1), "0");
miss_data.put(i - 1, "0");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
missCount = missCount+1;
@@ -140,15 +140,15 @@ public class RECV_BI0700 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setMissingNmCount(missCount);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
miss_data.put(new Integer(recv_seq_no-1), "1");
miss_data.put(recv_seq_no - 1, "1");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
}
} else { //이전에 miss_field가 있으면 현재 수신한 seq에 data set
for (int i=seq_no+1; i<recv_seq_no; i++){//중간에 결번이 생긴 부분은 결번으로 셋팅
miss_data.put(new Integer(i-1), "0");
miss_data.put(i - 1, "0");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
missCount = missCount+1;
@@ -156,10 +156,10 @@ public class RECV_BI0700 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setMissingNmCount(missCount);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
miss_data.put(new Integer(recv_seq_no-1), "1");
miss_data.put(recv_seq_no - 1, "1");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
}
@@ -90,14 +90,14 @@ public class RECV_BI0710 extends DefaultTelegram implements TelegramService
logger.info("{"+logHeader+"} doPostExecute> RECV recv_seq_no [" + recv_seq_no + "] ");
byte[] _missing_field = new byte[miss_data.size()];
for (int j = 0; j<miss_data.size(); j++) { //받은 seq_no만큼만 데이터 확인
String field = (String) miss_data.get( new Integer(j) );
String field = (String) miss_data.get(j);
_missing_field[j] = field.getBytes()[0]; //결번이 발생한 seq만 '0' 설정
if ((recv_seq_no-1) == j && _missing_field[j] == '0' ){
_missing_field[recv_seq_no-1] = '1';
missingCount -= 1;
miss_data.put(new Integer(j), "1");
miss_data.put(j, "1");
hm.put(JobProcessData.PROCDATA_MISSDATA, miss_data);
}
@@ -119,17 +119,17 @@ public class RECV_BI0710 extends DefaultTelegram implements TelegramService
for (int i =0; i < _missing_field.length; i++){
if (_missing_field[i]=='0'){
first_miss_field.put(JobProcessData.PROCDATA_FIRST_MISS, new Integer(i+1)); // 첫번째 결번
first_miss_field.put(JobProcessData.PROCDATA_FIRST_MISS, i + 1); // 첫번째 결번
hm.put(JobProcessData.PROCDATA_FIRST_MISS, first_miss_field );
last_miss_field = new HashMap<String, Integer>();
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, new Integer(i+1));
last_miss_field.put(JobProcessData.PROCDATA_LAST_MISS, i + 1);
hm.put(JobProcessData.PROCDATA_LAST_MISS, last_miss_field);
for (int n = recv_seq_no; n<i; n++){//현재 받은 결번 데이터와 다음 결번 사이에 seq data를 write한다.
byte[] data = (byte[]) block_data.get(new Integer(n));
byte[] data = (byte[]) block_data.get(n);
fout.write(data);
block_data.remove(new Integer(n));
block_data.remove(n);
}
break;
}
@@ -137,8 +137,8 @@ public class RECV_BI0710 extends DefaultTelegram implements TelegramService
}else {//같지 않으면 메모리에 저장..
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
if (block_data.get(recv_seq_no - 1) == null) {
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
}
@@ -213,7 +213,7 @@ public class SEND_BI0430 extends DefaultTelegram implements TelegramService
}
} else {
for (int j = 0; j<seq_no; j++) { //받은 seq_no만큼만 데이터 확인
String field = miss_data.get( new Integer(j) );
String field = miss_data.get(j);
_missingNm[j] = field.getBytes()[0]; //결번이 발생한 seq만 '0' 설정
}
if (MISSING_COUNT == 0) {
@@ -224,7 +224,7 @@ public class SEND_BI0430 extends DefaultTelegram implements TelegramService
Integer lastMiss = last_miss_field.get(JobProcessData.PROCDATA_LAST_MISS);
for (int i = lastMiss.intValue(); i<seq_no; i++) { //결번이후 메모리에 저장한 데이터 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
fout.write(data);
}
hm.put(JobProcessData.PROCDATA_BLOCKDATA, null); //데이터 기록후 Vector 초기화
@@ -394,7 +394,7 @@ public class SEND_BI0700 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1) , fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
this.batchDoc.getBatchMsg().getBody().setSeqNum(SEQUENCE_NO);
@@ -272,7 +272,7 @@ public class SEND_BI0710 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = block_data.get( new Integer(i) );
byte[] data = block_data.get(i);
fileData = new byte[data.length];
System.arraycopy( data, 0, fileData, 0, data.length);
this.REAL_BYTE = data.length;
@@ -64,7 +64,7 @@ public class RECV_BOKEX_03000030 extends DefaultTelegram implements TelegramServ
int recv_seq_no = Integer.parseInt(_seq_no);
batchDoc.getBatchMsg().getBody().setSeqNum(recv_seq_no);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -44,7 +44,7 @@ public class RECV_BOKEX_03100040 extends DefaultTelegram implements TelegramServ
// 이전에 송신한 최초 시퀀스 찾아 내어 시퀀스 번호 다시 세팅
int seq_no = batchDoc.getBatchMsg().getBody().getSeqNum();
for ( int inx=0;inx<seq_no;inx++){
Object obj = hm.get(new Integer(inx));
Object obj = hm.get(inx);
if ( obj!= null ){
batchDoc.getBatchMsg().getBody().setSeqNum(inx+1);
break;
@@ -323,7 +323,7 @@ public class SEND_BOKEX_03000030 extends DefaultTelegram implements TelegramServ
block_data = new HashMap<Integer, byte[]>();
}
fileData = block_data.get(new Integer(SEQUENCE_NO-1));
fileData = block_data.get(SEQUENCE_NO - 1);
if ( fileData == null ){
fileData = new byte[sequence_size];
@@ -350,7 +350,7 @@ public class SEND_BOKEX_03000030 extends DefaultTelegram implements TelegramServ
}
}
REAL_BYTE = offset;
block_data.put( new Integer(SEQUENCE_NO-1) , fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 전송 상태 처리
@@ -225,7 +225,7 @@ public class SEND_BOKEX_03100040 extends DefaultTelegram implements TelegramServ
return false;
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
if (data != null ) fout.write(data);
}
}
@@ -96,7 +96,7 @@ public class RECV_BOKGG_0310 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -175,7 +175,7 @@ public class RECV_BOKGG_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -295,7 +295,7 @@ public class SEND_BOKGG_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -310,7 +310,7 @@ public class SEND_BOKGG_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -268,7 +268,7 @@ public class SEND_BOKGG_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = block_data.get( new Integer(SEQUENCE_NO -1) );
byte[] data = block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = data.length;
fileData = new byte[REAL_BYTE];
System.arraycopy( data, 0, fileData, 0, data.length);
@@ -396,7 +396,7 @@ public class SEND_BOKGG_0320 extends DefaultTelegram implements TelegramService
System.arraycopy( fileLine, 0, fileData, inx * batchDoc.getBatchMsg().getHeader().getRecLen(), batchDoc.getBatchMsg().getHeader().getRecLen());
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -96,7 +96,7 @@ public class RECV_BOKJJ_0310 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -173,7 +173,7 @@ public class RECV_BOKJJ_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -298,7 +298,7 @@ public class SEND_BOKJJ_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -313,7 +313,7 @@ public class SEND_BOKJJ_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -271,7 +271,7 @@ public class SEND_BOKJJ_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = block_data.get( new Integer(SEQUENCE_NO -1) );
byte[] data = block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = data.length;
fileData = new byte[REAL_BYTE];
System.arraycopy( data, 0, fileData, 0, data.length);
@@ -418,7 +418,7 @@ public class SEND_BOKJJ_0320 extends DefaultTelegram implements TelegramService
System.arraycopy( fileLine, 0, fileData, inx * batchDoc.getBatchMsg().getHeader().getRecLen(), batchDoc.getBatchMsg().getHeader().getRecLen());
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 이후 0600 전문 송신시에는 최종 block, seq를 보내 줘야 하기 때문에 헤더트레일러인 경우는 다음을 셋하지 않는다.
@@ -102,7 +102,7 @@ public class RECV_BOKNG_0310 extends DefaultTelegram implements TelegramService
System.arraycopy(bout.toByteArray(), 3, enc, 0, enc.length);
System.arraycopy(IniSafeManager.getInstance().dec(batchDoc,enc), 0, dec, 3, enc.length);
block_data.put( new Integer(recv_seq_no-1) , dec);
block_data.put(recv_seq_no - 1, dec);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -182,7 +182,7 @@ public class RECV_BOKNG_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , dec);
block_data.put(recv_seq_no - 1, dec);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -300,7 +300,7 @@ public class SEND_BOKNG_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -314,7 +314,7 @@ public class SEND_BOKNG_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -283,7 +283,7 @@ public class SEND_BOKNG_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
byte[] data = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = data.length;
fileData = new byte[REAL_BYTE];
System.arraycopy( data, 0, fileData, 0, data.length);
@@ -420,7 +420,7 @@ public class SEND_BOKNG_0320 extends DefaultTelegram implements TelegramService
System.arraycopy( fileLine, 0, fileData, inx * batchDoc.getBatchMsg().getHeader().getRecLen(), batchDoc.getBatchMsg().getHeader().getRecLen());
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -81,7 +81,7 @@ public class RECV_CCRSF_0310 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -156,7 +156,7 @@ public class RECV_CCRSF_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -302,7 +302,7 @@ public class SEND_CCRSF_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -317,7 +317,7 @@ public class SEND_CCRSF_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -275,7 +275,7 @@ public class SEND_CCRSF_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = block_data.get( new Integer(SEQUENCE_NO -1) );
byte[] data = block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = data.length;
fileData = new byte[REAL_BYTE];
System.arraycopy( data, 0, fileData, 0, data.length);
@@ -401,7 +401,7 @@ public class SEND_CCRSF_0320 extends DefaultTelegram implements TelegramService
System.arraycopy( fileLine, 0, fileData, inx * batchDoc.getBatchMsg().getHeader().getRecLen(), batchDoc.getBatchMsg().getHeader().getRecLen());
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -95,8 +95,8 @@ public class RECV_CMS25_0310 extends DefaultTelegram implements TelegramService
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if ( recv_block_no == block_no ){
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
if (block_data.get(recv_seq_no - 1) == null) {
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
}
@@ -85,7 +85,7 @@ public class RECV_CMS25_0320 extends DefaultTelegram implements TelegramService
int recv_seq_no = Integer.parseInt(_seq_no);
int block_no = batchDoc.getBatchMsg().getBody().getBlockNum();
if ( recv_block_no == block_no ){
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
//DB로그에 남길 전문 헤더 설정
@@ -139,7 +139,7 @@ public class RECV_CMS25_0640 extends DefaultTelegram implements TelegramService
}
block_data.put( new Integer(inx), fileData);
block_data.put(inx, fileData);
}
batchDoc.getBatchMsg().getBody().setSeqNum(seqNo);
@@ -386,7 +386,7 @@ public class SEND_CMS25_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -406,7 +406,7 @@ public class SEND_CMS25_0300 extends DefaultTelegram implements TelegramService
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
if ( writeNoLf != null && writeNoLf.equals("Y")){
fout.write(data);
long lnCurSize = batchDoc.getBatchMsg().getBody().getCurFileSize()+data.length;
@@ -349,7 +349,7 @@ public class SEND_CMS25_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO -1);
this.REAL_BYTE = fileData.length;
return true;
} catch (Exception e ) {
@@ -462,7 +462,7 @@ public class SEND_CMS25_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO-1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -99,7 +99,7 @@ public class RECV_DEBIT_0310 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -183,7 +183,7 @@ public class RECV_DEBIT_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -305,7 +305,7 @@ public class SEND_DEBIT_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -320,7 +320,7 @@ public class SEND_DEBIT_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -273,7 +273,7 @@ public class SEND_DEBIT_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = block_data.get( new Integer(SEQUENCE_NO -1) );
byte[] data = block_data.get(SEQUENCE_NO -1);
this.REAL_BYTE = data.length;
fileData = new byte[REAL_BYTE];
System.arraycopy( data, 0, fileData, 0, data.length);
@@ -409,7 +409,7 @@ public class SEND_DEBIT_0320 extends DefaultTelegram implements TelegramService
System.arraycopy( fileLine, 0, fileData, inx * batchDoc.getBatchMsg().getHeader().getRecLen(), batchDoc.getBatchMsg().getHeader().getRecLen());
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO-1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -70,7 +70,7 @@ public class RECV_FIUSC_0303 extends DefaultTelegram implements TelegramService
int recv_seq_no = Integer.parseInt(_seq_no.trim());
batchDoc.getBatchMsg().getBody().setSeqNum(recv_seq_no);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -340,7 +340,7 @@ public class SEND_FIUSC_0303 extends DefaultTelegram implements TelegramService
block_data = new HashMap<Integer, byte[]>();
}
fileData = block_data.get(new Integer(SEQUENCE_NO-1));
fileData = block_data.get(SEQUENCE_NO - 1);
if ( fileData == null ){
fileData = new byte[sequence_size];
@@ -351,10 +351,10 @@ public class SEND_FIUSC_0303 extends DefaultTelegram implements TelegramService
byte[] retryFileData = new byte[REAL_BYTE];
int bytesRead = bin.read(retryFileData);
if (bytesRead == REAL_BYTE) {
block_data.put(new Integer(SEQUENCE_NO-1), retryFileData);
block_data.put(SEQUENCE_NO - 1, retryFileData);
}
} else {
block_data.put(new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
}
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -3,6 +3,7 @@ package com.eactive.eai.batch.job.jobItem.fiusc;
import java.io.ByteArrayOutputStream;
import java.io.File;
import java.io.FileOutputStream;
import java.util.Arrays;
import java.util.HashMap;
import java.util.Properties;
@@ -57,9 +58,7 @@ public class SEND_FIUSC_0314 extends DefaultTelegram implements TelegramService
//사용자ID
byte[] userId = new byte[20];
for ( int inx = 0; inx < userId.length; inx++ ){
userId[inx] = ' ';
}
Arrays.fill(userId, (byte) ' ');
System.arraycopy(batchDoc.getBatchMsg().getHeader().getUserID().getBytes(), 0, userId, 0,
Math.min(batchDoc.getBatchMsg().getHeader().getUserID().getBytes().length, 20));
@@ -115,14 +114,14 @@ public class SEND_FIUSC_0314 extends DefaultTelegram implements TelegramService
for (int i=0; i<10; i++) {
baout.write((byte[])this.al_Field.get(i));
}
batchDoc.getBatchMsg().setTelegramHeader(new String(baout.toByteArray()));
batchDoc.getBatchMsg().setTelegramHeader(baout.toString());
//DB로그에 남길 전문 바디 설정
baout = new ByteArrayOutputStream();
for (int i=10; i< al_Field.size(); i++) {
baout.write((byte[])this.al_Field.get(i));
}
batchDoc.getBatchMsg().setTelegramBody(new String(baout.toByteArray()));
batchDoc.getBatchMsg().setTelegramBody(baout.toString());
//확인결과 정상(RTN_CD='00')이 아닌 경우 재처리를 위해 기수신파일크기 리셋
if (RTN_CD != "00") {
@@ -262,7 +261,7 @@ public class SEND_FIUSC_0314 extends DefaultTelegram implements TelegramService
//받은 seq_no만큼만 데이터 확인하여 정상이면 파일에 기록하고, 비정상이면 받은 데이터 길이만 저장
for (int i=0; i < seq_no; i++) {
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
if (data != null ) {
if (RTN_CD.equals("00")) {
fout.write(data);
@@ -82,7 +82,7 @@ public class RECV_HOUSE_0310 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -148,7 +148,7 @@ public class RECV_HOUSE_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -319,7 +319,7 @@ public class SEND_HOUSE_0300 extends DefaultTelegram implements TelegramService
//20060413 khs >> byte[] data = (byte[]) block_data.get( i );
byte[] data = null;
if ( block_data != null ){
data = (byte[]) block_data.get( new Integer(i) );
data = (byte[]) block_data.get(i);
}
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
@@ -336,7 +336,7 @@ public class SEND_HOUSE_0300 extends DefaultTelegram implements TelegramService
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = null;
if ( block_data != null ){
data = (byte[]) block_data.get( new Integer(i) );
data = (byte[]) block_data.get(i);
}
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
@@ -300,7 +300,7 @@ public class SEND_HOUSE_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
byte[] data = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = data.length;
fileData = new byte[REAL_BYTE];
System.arraycopy( data, 0, fileData, 0, data.length);
@@ -465,7 +465,7 @@ public class SEND_HOUSE_0320 extends DefaultTelegram implements TelegramService
System.arraycopy( fileLine, 0, fileData, inx * batchDoc.getBatchMsg().getHeader().getRecLen(), batchDoc.getBatchMsg().getHeader().getRecLen());
}
block_data.put( new Integer(SEQUENCE_NO-1) , fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -67,11 +67,11 @@ public class RECV_KEDBT_0310 extends DefaultTelegram implements TelegramService
}
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
if (block_data.get(recv_seq_no-1) == null) {
//결번 테스트용
// if ( Math.random() > 0.6 ){
// }
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -68,7 +68,7 @@ public class RECV_KEDBT_0320 extends DefaultTelegram implements TelegramService
//결번 테스트용
// if ( Math.random() > 0.6 ){
// }
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
return true;
} catch ( Exception e) {
@@ -283,7 +283,7 @@ public class SEND_KEDBT_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0'; //받은 DATA없을
}else{
for (int i = 0; i < SEQUENCE_NO; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data != null ) {
_missingNm[i] = '1'; //정상이면 '1' 설정
}else{
@@ -307,7 +307,7 @@ public class SEND_KEDBT_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i < SEQUENCE_NO; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -264,7 +264,7 @@ public class SEND_KEDBT_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO -1);
this.REAL_BYTE = fileData.length;
return true;
@@ -345,7 +345,7 @@ public class SEND_KEDBT_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO-1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -99,7 +99,7 @@ public class RECV_KFB0310 extends DefaultTelegram implements TelegramService {
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -161,7 +161,7 @@ public class RECV_KFB0320 extends DefaultTelegram implements TelegramService {
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no-1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -309,7 +309,7 @@ public class SEND_KFB0300 extends DefaultTelegram implements TelegramService {
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -324,7 +324,7 @@ public class SEND_KFB0300 extends DefaultTelegram implements TelegramService {
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -281,7 +281,7 @@ public class SEND_KFB0310 extends DefaultTelegram implements TelegramService {
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
byte[] data = block_data.get( new Integer(SEQUENCE_NO -1) );
byte[] data = block_data.get(SEQUENCE_NO -1);
this.REAL_BYTE = data.length;
fileData = new byte[REAL_BYTE];
System.arraycopy( data, 0, fileData, 0, data.length);
@@ -432,7 +432,7 @@ public class SEND_KFB0320 extends DefaultTelegram implements TelegramService {
System.arraycopy( fileLine, 0, fileData, inx * batchDoc.getBatchMsg().getHeader().getRecLen(), batchDoc.getBatchMsg().getHeader().getRecLen());
}
block_data.put( new Integer(SEQUENCE_NO-1) , fileData);
block_data.put(SEQUENCE_NO-1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -89,8 +89,8 @@ public class RECV_KFTCB_0310 extends DefaultTelegram implements TelegramService
int recv_seq_no = Integer.parseInt(_seq_no);
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
if (block_data.get(recv_seq_no - 1) == null) {
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -80,7 +80,7 @@ public class RECV_KFTCB_0320 extends DefaultTelegram implements TelegramService
String _seq_no = new String ((byte[]) al_Field.get(10));
int recv_seq_no = Integer.parseInt(_seq_no);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -133,7 +133,7 @@ public class RECV_KFTCB_0640 extends DefaultTelegram implements TelegramService
}
block_data.put( new Integer(inx), fileData);
block_data.put(inx, fileData);
}
batchDoc.getBatchMsg().getBody().setSeqNum(seqNo);
@@ -357,7 +357,7 @@ public class SEND_KFTCB_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -377,7 +377,7 @@ public class SEND_KFTCB_0300 extends DefaultTelegram implements TelegramService
} catch (Exception e) {}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
if ( writeNoLf != null && writeNoLf.equals("Y")){
fout.write(data);
@@ -333,7 +333,7 @@ public class SEND_KFTCB_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = fileData.length;
return true;
} catch (Exception e ) {
@@ -454,7 +454,7 @@ public class SEND_KFTCB_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -89,8 +89,8 @@ public class RECV_KOFCB_0310 extends DefaultTelegram implements TelegramService
int recv_seq_no = Integer.parseInt(_seq_no);
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
if (block_data.get(recv_seq_no - 1) == null) {
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -80,7 +80,7 @@ public class RECV_KOFCB_0320 extends DefaultTelegram implements TelegramService
String _seq_no = new String ((byte[]) al_Field.get(10));
int recv_seq_no = Integer.parseInt(_seq_no);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -339,7 +339,7 @@ public class SEND_KOFCB_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -354,7 +354,7 @@ public class SEND_KOFCB_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -320,7 +320,7 @@ public class SEND_KOFCB_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = fileData.length;
return true;
} catch (Exception e ) {
@@ -399,7 +399,7 @@ public class SEND_KOFCB_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -89,8 +89,8 @@ public class RECV_LGCNS_0310 extends DefaultTelegram implements TelegramService
int recv_seq_no = Integer.parseInt(_seq_no);
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
if (block_data.get(recv_seq_no - 1) == null) {
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -80,7 +80,7 @@ public class RECV_LGCNS_0320 extends DefaultTelegram implements TelegramService
String _seq_no = new String ((byte[]) al_Field.get(10));
int recv_seq_no = Integer.parseInt(_seq_no);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -132,7 +132,7 @@ public class RECV_LGCNS_0640 extends DefaultTelegram implements TelegramService
}
block_data.put( new Integer(inx), fileData);
block_data.put(inx, fileData);
}
batchDoc.getBatchMsg().getBody().setSeqNum(seqNo);
@@ -291,7 +291,7 @@ public class SEND_LGCNS_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -306,7 +306,7 @@ public class SEND_LGCNS_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
fout.write(data);
long lnCurSize = batchDoc.getBatchMsg().getBody().getCurFileSize()+data.length;
batchDoc.getBatchMsg().getBody().setCurFileSize(lnCurSize);
@@ -269,7 +269,7 @@ public class SEND_LGCNS_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = fileData.length;
return true;
} catch (Exception e ) {
@@ -372,7 +372,7 @@ public class SEND_LGCNS_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -89,8 +89,8 @@ public class RECV_SHCDB_0310 extends DefaultTelegram implements TelegramService
int recv_seq_no = Integer.parseInt(_seq_no);
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
if (block_data.get(recv_seq_no - 1) == null) {
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -80,7 +80,7 @@ public class RECV_SHCDB_0320 extends DefaultTelegram implements TelegramService
String _seq_no = new String ((byte[]) al_Field.get(10));
int recv_seq_no = Integer.parseInt(_seq_no);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -344,7 +344,7 @@ public class SEND_SHCDB_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -359,7 +359,7 @@ public class SEND_SHCDB_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -318,7 +318,7 @@ public class SEND_SHCDB_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = fileData.length;
return true;
} catch (Exception e ) {
@@ -398,7 +398,7 @@ public class SEND_SHCDB_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -82,7 +82,7 @@ public class RECV_SKT01_2100 extends DefaultTelegram implements TelegramService
// if ( Math.random() > 0.3 ){
// block_data.put( new Integer(recv_seq_no-1) , (byte[]) al_Field.get(13));
// }
block_data.put( new Integer(recv_seq_no-1) , (byte[]) al_Field.get(13));
block_data.put(recv_seq_no - 1, (byte[]) al_Field.get(13));
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -165,7 +165,7 @@ public class SEND_SKT01_0810 extends DefaultTelegram implements TelegramService
//FileOutputStream fout = new FileOutputStream(rcvRealFile, true);
try (FileOutputStream fout = new FileOutputStream(rcvRealFile, true)) {// 20250910 obl
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
if ( data != null ){
int recLen = Integer.parseInt(substring(data, 8, 4));
byte[]layout = new byte[recLen];
@@ -378,7 +378,7 @@ public class SEND_SKT01_2100 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -441,7 +441,7 @@ public class SEND_SKT01_2100 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = fileData.length;
return true;
@@ -281,7 +281,7 @@ public class SEND_SKT01_2210 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -297,7 +297,7 @@ public class SEND_SKT01_2210 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
if ( data != null ){
int recLen = Integer.parseInt(substring(data, 8, 4));
byte[]layout = new byte[recLen];
@@ -57,7 +57,7 @@ public class RECV_SSNBT_0310 extends DefaultTelegram implements TelegramService
byte[] recvData = new byte[dataSize];
System.arraycopy(bout.toByteArray(), 0, recvData, 0, dataSize);
block_data.put( new Integer(recv_seq_no - 1), recvData);
block_data.put(recv_seq_no - 1, recvData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
if ( recv_seq_no == 1 ){ // 레코드이면
@@ -56,7 +56,7 @@ public class RECV_SSNBT_0320 extends DefaultTelegram implements TelegramService
byte[] recvData = new byte[dataSize];
System.arraycopy(bout.toByteArray(), 0, recvData, 0, dataSize);
block_data.put( new Integer(recv_seq_no - 1), recvData);
block_data.put(recv_seq_no - 1, recvData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
if ( recv_seq_no == 1 ){ // 레코드이면
@@ -242,7 +242,7 @@ public class SEND_SSNBT_0310 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
fileData = block_data.get( new Integer(SEQUENCE_NO - 1));
fileData = block_data.get(SEQUENCE_NO - 1);
REAL_BYTE = fileData.length;
return true;
@@ -334,7 +334,7 @@ public class SEND_SSNBT_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO - 1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -383,7 +383,7 @@ public class SEND_SSNBT_0320_JB extends DefaultTelegram implements TelegramServi
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO - 1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -202,7 +202,7 @@ public class SEND_SSNBT_0620 extends DefaultTelegram implements TelegramService
} catch (Exception e) {}
for (int i = lastSeq + 1; i <= seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i-1));
byte[] data = (byte[]) block_data.get(i - 1);
if ( recLen < 1 ){
recLen = data.length;
@@ -89,8 +89,8 @@ public class RECV_WELCD_0310 extends DefaultTelegram implements TelegramService
int recv_seq_no = Integer.parseInt(_seq_no);
logger.info("{} doInformalField >> missing telegram receive : [" + (recv_seq_no-1) + "]", logHeader);
if (block_data.get(new Integer(recv_seq_no-1)) == null) {
block_data.put(new Integer(recv_seq_no-1), bout.toByteArray());
if (block_data.get(recv_seq_no - 1) == null) {
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}
@@ -80,7 +80,7 @@ public class RECV_WELCD_0320 extends DefaultTelegram implements TelegramService
String _seq_no = new String ((byte[]) al_Field.get(10));
int recv_seq_no = Integer.parseInt(_seq_no);
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
//DB로그에 남길 전문 헤더 설정
@@ -295,7 +295,7 @@ public class SEND_WELCD_0300 extends DefaultTelegram implements TelegramService
_missingNm[i] = '0';
}else{
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인
byte[] data = (byte[]) block_data.get( new Integer(i) );
byte[] data = (byte[]) block_data.get(i);
if (data == null ) {
_missingNm[i] = '0'; //결번이 발생한 seq만 '0' 설정
MISSING_COUNT++;
@@ -310,7 +310,7 @@ public class SEND_WELCD_0300 extends DefaultTelegram implements TelegramService
}
for (int i = 0; i<seq_no; i++) { //받은 seq_no만큼만 데이터 확인하여 기록
byte[] data = (byte[]) block_data.get(new Integer(i));
byte[] data = (byte[]) block_data.get(i);
int recLen = batchDoc.getBatchMsg().getHeader().getRecLen();
if ( recLen < 1 ){
recLen = data.length;
@@ -204,7 +204,7 @@ public class SEND_WELCD_0310 extends DefaultTelegram implements TelegramService
this.batchDoc.getBatchMsg().getBody().setErrorMsg(errMsg);
return false;
}
fileData = (byte[]) block_data.get( new Integer(SEQUENCE_NO -1) );
fileData = (byte[]) block_data.get(SEQUENCE_NO - 1);
this.REAL_BYTE = fileData.length;
return true;
} catch (Exception e ) {
@@ -354,7 +354,7 @@ public class SEND_WELCD_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(SEQUENCE_NO-1), fileData);
block_data.put(SEQUENCE_NO - 1, fileData);
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
// 2008.06.19 - 정동한
@@ -101,7 +101,7 @@ public class RECV_LDB01_0310 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
@@ -160,7 +160,7 @@ public class RECV_LDB01_0320 extends DefaultTelegram implements TelegramService
if (block_data == null) {
block_data = new HashMap<Integer, byte[]>();
}
block_data.put( new Integer(recv_seq_no-1) , bout.toByteArray());
block_data.put(recv_seq_no - 1, bout.toByteArray());
hm.put(JobProcessData.PROCDATA_BLOCKDATA, block_data);
}

Some files were not shown because too many files have changed in this diff Show More