Commit 3dbed902 by wangguangchao

cacheRead String类型方法修改

parent d2b03bd5
......@@ -2,14 +2,18 @@ String getDecNum(String argact)
{
// 取账户开户机构的金融机构标识码
String decnum = "";
Platform.cacheRead( decnum, "ACTINFO", argact, "OPNBCHDECNUM" );
Argument<String> decnumBox= new Argument<>("","");
Platform.cacheRead( decnumBox, "ACTINFO", argact, "OPNBCHDECNUM" );
decnum = decnumBox.value;
String bchinr = NULLSTR;
int err = 0;
if( Platform.errorCode() > 0 )
{
//账户的开户机构
bchinr = "";
Platform.cacheRead( bchinr, "ACTINFO", argact, "OPNBCHINR" );
Argument<String> bchinrBox= new Argument<>("","");
Platform.cacheRead( bchinrBox, "ACTINFO", argact, "OPNBCHINR" );
bchinr = bchinrBox.value;
if( Platform.errorCode() > 0 )
{
Platform.dbExecuteSQL( "SELECT BCHKEYINR FROM ACT WHERE EXTKEY=?", argact );
......
String getTextbyInrTable(String tableid,String tableinr,String fieldid)
{
String fld = "";
Platform.cacheRead( fld, "TRNMOD", tableid, tableinr, fieldid );
Argument<String> fldBox= new Argument<>("","");
Platform.cacheRead( fldBox, "TRNMOD", tableid, tableinr, fieldid );
fld = fldBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
if( ! Platform.isEmpty( tableinr ) )
......
......@@ -5,7 +5,9 @@ void createCbbEntries(#cbe rec)
// retrieve the list of columns to be processed
String cbcBlk = "";
String cbsConfKey = $$rec\objtyp.getValue() + "-" + $$rec\cbt.getValue();
Platform.cacheRead( cbcBlk, "cbsmod", cbsConfKey, "OPR" );
Argument<String> cbcBlkBox= new Argument<>("","");
Platform.cacheRead( cbcBlkBox, "cbsmod", cbsConfKey, "OPR" );
cbcBlk = cbcBlkBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
cbcBlk = Platform.getIniBlock( "CBSCONF.INI", cbsConfKey, "OPR" );
......
......@@ -26,13 +26,15 @@ void deleteCbbEntries(#cbe cbearg)
max = Platform.streamCount( cbbStm );
cbsConfKey = $$cbearg\objtyp.getValue() + "-" + $$cbearg\cbt.getValue() + "-OPR";
opr = "";
Argument<String> oprBox= new Argument<>("","");
for(int idx = 1;idx <= max;idx++)
{
lin = Platform.getLine( cbbStm, idx );
pos = Platform.pos( lin, "\t" );
cbc = Platform.mid( lin, pos + 1 );
// Check for every element, whether CBT includes column
Platform.cacheRead( opr, "cbsmod", cbsConfKey, cbc );
Platform.cacheRead( oprBox, "cbsmod", cbsConfKey, cbc );
opr = oprBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
opr = Platform.getIniStr( "CBSCONF.INI", cbsConfKey, cbc );
......
......@@ -26,13 +26,15 @@ void commitCbbEntries(#cbe cbearg)
max = Platform.streamCount( cbbStm );
cbsConfKey = $$cbearg\objtyp.getValue() + "-" + $$cbearg\cbt.getValue() + "-OPR";
opr = "";
Argument<String> oprBox= new Argument<>("","");
for(int idx = 1;idx <= max;idx++)
{
lin = Platform.getLine( cbbStm, idx );
pos = Platform.pos( lin, "\t" );
cbc = Platform.mid( lin, pos + 1 );
// Check for every element, whether CBT includes column
Platform.cacheRead( opr, "cbsmod", cbsConfKey, cbc );
Platform.cacheRead( oprBox, "cbsmod", cbsConfKey, cbc );
opr = oprBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
opr = Platform.getIniStr( "CBSCONF.INI", cbsConfKey, cbc );
......
......@@ -9,7 +9,9 @@ String getPtmField(String arginr,String argcortyp,String argseafld)
Platform.sysDump( "DOCEOT.GetPtmField called with an empty parameter" );
}
String res = "";
Platform.cacheRead( res, "DOCEOT", arginr, argcortyp );
Argument<String> resBox= new Argument<>("","");
Platform.cacheRead( resBox, "DOCEOT", arginr, argcortyp );
res = resBox.value;
String sql = NULLSTR;
if( Platform.errorCode() == tdCacheNotFound )
{
......
......@@ -108,7 +108,9 @@ void printDoc()
if( Platform.compareTo($cltprtflg, "S" )== 0 )
{
pPDFile = "";
Platform.cacheRead( pPDFile, "PRTMOD_PPDFILE", $prt\prt.getValue() );
Argument<String> pPDFileBox= new Argument<>("","");
Platform.cacheRead( pPDFileBox, "PRTMOD_PPDFILE", $prt\prt.getValue() );
pPDFile = pPDFileBox.value;
if( Platform.errorCode() > 0 )
{
Platform.setErrorCode( Platform.errorCode(), Platform.formatText( "Cannot determine name of PPD file for printer queue \'$1\' from printers.xml", $prt\prt.getValue() ) );
......@@ -116,7 +118,9 @@ void printDoc()
}
Platform.setContext( "PPDFILE", pPDFile );
pdl = "PS";
Platform.cacheRead( pdl, "PRTMOD_PDL", $prt\prt.getValue() );
Argument<String> pdlBox= new Argument<>("","");
Platform.cacheRead( pdlBox, "PRTMOD_PDL", $prt\prt.getValue() );
pdl = pdlBox.value;
if( Platform.errorCode() > 0 )
{
if( Platform.errorCode() != tdCacheNotFound )
......@@ -199,7 +203,9 @@ void printDoc()
if( Platform.compareTo($cltprtflg, "S" )== 0 )
{
pPDFile = "";
Platform.cacheRead( pPDFile, "PRTMOD_PPDFILE", $prt\prt.getValue() );
Argument<String> pPDFileBox= new Argument<>("","");
Platform.cacheRead( pPDFileBox, "PRTMOD_PPDFILE", $prt\prt.getValue() );
pPDFile = pPDFileBox.value;
if( Platform.errorCode() > 0 )
{
Platform.setErrorCode( Platform.errorCode(), Platform.formatText( "Cannot determine name of PPD file for printer queue \'$1\' from printers.xml", $prt\prt.getValue() ) );
......@@ -207,7 +213,9 @@ void printDoc()
}
Platform.setContext( "PPDFILE", pPDFile );
pPDFile = "";
Platform.cacheRead( pPDFile, "PRTMOD_PPDFILE", $prt\prt.getValue() );
//Argument<String> pPDFileBox= new Argument<>("","");
Platform.cacheRead( pPDFileBox, "PRTMOD_PPDFILE", $prt\prt.getValue() );
pPDFile = pPDFileBox.value;
if( Platform.errorCode() > 0 )
{
Platform.setErrorCode( Platform.errorCode(), Platform.formatText( "Cannot determine name of PPD file for printer queue \'$1\' from printers.xml", $prt\prt.getValue() ) );
......@@ -215,7 +223,9 @@ void printDoc()
}
Platform.setContext( "PPDFILE", pPDFile );
pdl = "PS";
Platform.cacheRead( pdl, "PRTMOD_PDL", $prt\prt.getValue() );
Argument<String> pdlBox= new Argument<>("","");
Platform.cacheRead( pdlBox, "PRTMOD_PDL", $prt\prt.getValue() );
pdl = pdlBox.value;
if( Platform.errorCode() > 0 )
{
if( Platform.errorCode() != tdCacheNotFound )
......
......@@ -4,7 +4,9 @@ String getViewerFromSMH(#smh argsmh)
//! By setting appropriate entries with CacheWrite in DOCIMM.init different viewers can be configured
// e.g. CacheWrite("LET","DOCIMMViewer",">","FAX","XML")
String viewer = "";
Argument<String> viewerBox= new Argument<>("","");
Platform.cacheRead( viewer, "DOCIMMViewer", $$argsmh\dir.getValue(), $$argsmh\cortyp.getValue(), Platform.toUpper( $$argsmh\docfxt.getValue() ) );
viewer = viewerBox.value;
String ignore = NULLSTR;
if( Platform.errorCode() <= 0 )
{
......
......@@ -47,7 +47,9 @@ void getold()
if( ! Platform.isEmpty( $liaallg[l]\oldflg ) )
{
used = "";
Platform.cacheRead( used, "LIAALL", "OLDUSE", l );
Argument<String> usedBox= new Argument<>("","");
Platform.cacheRead( usedBox, "LIAALL", "OLDUSE", l );
used = usedBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
Platform.clear( $liaallg[l]\objmodpath );
......
......@@ -5,7 +5,9 @@ void liaallSetPtsptaForRol(String argrol,IModule arggrp,#ptspta argptspta)
//! In case of changes in Call with same ArgRol, LiaAllCompleteRedefaultWithWarn is executed to reinitialze engagement
String ptsptaPath = Platform.getModuleInfo( argptspta, tdModuleInfoFullName );
String oldPath = "";
Platform.cacheRead( oldPath, "LiaallSetPtsptaForRol", "OldPtsPta", argrol );
Argument<String> oldPathBox= new Argument<>("","");
Platform.cacheRead( oldPathBox, "LiaallSetPtsptaForRol", "OldPtsPta", argrol );
oldPath = oldPathBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
Platform.cacheWrite( ptsptaPath, "LiaallSetPtsptaForRol", "OldPtsPta", argrol );
......
......@@ -22,7 +22,9 @@ void movePteToLiaallg(IModule argmod)
{
// if there is an empty line for that role and contract, reuse it
liause = "";
Platform.cacheRead( liause, "LIAALL", "OLDUSE", i );
Argument<String> liauseBox= new Argument<>("","");
Platform.cacheRead( liauseBox, "LIAALL", "OLDUSE", i );
liause = liauseBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
Platform.clear( liause );
......
......@@ -6,7 +6,9 @@ String liaallParGet(String argfuckey,String argdtakey)
//! ArgDtaKey : Data key (3rd key of cache entry)
//! Corresponding function: LiaallParSet to set the information, LiaallParFound
String res = "";
Platform.cacheRead( res, "LIAALL", argfuckey, argdtakey );
Argument<String> resBox= new Argument<>("","");
Platform.cacheRead( resBox, "LIAALL", argfuckey, argdtakey );
res = resBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
return "";
......
......@@ -6,7 +6,9 @@ boolean liaallParFound(String argfuckey,String argdtakey)
//! ArgDtaKey : Data key (3rd key of cache entry)
//! Corresponding function: LiaallParSet to set the information, LiaallParGet
String res = "";
Platform.cacheRead( res, "LIAALL", argfuckey, argdtakey );
Argument<String> resBox= new Argument<>("","");
Platform.cacheRead( resBox, "LIAALL", argfuckey, argdtakey );
res = resBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
return false;
......
......@@ -20,7 +20,9 @@ void getOldCovers(IModule mod)
IStream ids = new StreamImpl();
Platform.streamSet( ids, $\cbsmod\cbsget.cbsGetUnbalancedExtIds( mod, "CCVSUM" ) );
String add = "";
Argument<String> addBox= new Argument<>("","");
Platform.cacheRead( add, "LIAALL", "ADDMODULE", "ALL" );
add = addBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
add = "";
......
......@@ -9,7 +9,9 @@ String getOitOfCty(String argcodcty,String argwrnpfx,String argstplev)
return "";
}
String ctyInr = "";
Platform.cacheRead( ctyInr, "OITCTYINR", $\sysmod\ety\extkey.getValue(), "CTY", argcodcty );
Argument<String> ctyInrBox= new Argument<>("","");
Platform.cacheRead( ctyInrBox, "OITCTYINR", $\sysmod\ety\extkey.getValue(), "CTY", argcodcty );
ctyInr = ctyInrBox.value;
String etySql = NULLSTR;
if( Platform.errorCode() == tdCacheNotFound )
{
......
......@@ -13,7 +13,9 @@ init $\ order 1000
{
// do not start the notify if it deactivated in EnterTransaction(1550)
res = "";
Platform.cacheRead( res, "NTFMOD", "NTFSTOP", $\sysmod\usr\extkey.getValue() );
Argument<String> resBox= new Argument<>("","");
Platform.cacheRead( resBox, "NTFMOD", "NTFSTOP", $\sysmod\usr\extkey.getValue() );
res = resBox.value;
if( Platform.errorCode() == 0 && ! Platform.isEmpty( res ) )
{
ntfStart = false;
......
......@@ -3,7 +3,9 @@ void getBinStream(IStream bincache,String printer)
//! read the Paperbins from File "Printers.xml" if unix, else getting the Paperbins from the Context
// try to read global CLTPRTFLG from cache, otherwise default here
String cltprtflg = "";
Platform.cacheRead( cltprtflg, "CLTPRTFLG" );
Argument<String> cltprtflgBox= new Argument<>("","");
Platform.cacheRead( cltprtflgBox, "CLTPRTFLG" );
cltprtflg = cltprtflgBox.value;
if( Platform.errorCode() > 0 )
{
if( Platform.errorCode() != tdCacheNotFound )
......
......@@ -33,7 +33,9 @@ String getPrinterList()
quenam = Platform.mid( line, 1, posend - 1 );
Platform.printTemp( quenam);
pPDFile = "";
Platform.cacheRead( pPDFile, "PRTMOD_PPDFILE", quenam );
Argument<String> pPDFileBox= new Argument<>("","");
Platform.cacheRead( pPDFileBox, "PRTMOD_PPDFILE", quenam );
pPDFile = pPDFileBox.value;
if( Platform.errorCode() > 0 )
{
posstart = Platform.pos( line, "printer-ppd=\"" );
......@@ -46,7 +48,9 @@ String getPrinterList()
}
}
pdl = "";
Platform.cacheRead( pPDFile, "PRTMOD_PDL", quenam );
Argument<String> pdlBox= new Argument<>("","");
Platform.cacheRead( pdlBox, "PRTMOD_PDL", quenam );
pdl = pdlBox.value;
if( Platform.errorCode() > 0 )
{
posstart = Platform.pos( line, "printer-pdl=\"" );
......
......@@ -50,7 +50,9 @@ void getFepEntries(Argument<Boolean> argfirstcall)
for(int i = 1;i <= cnt;i++)
{
id = "";
Platform.cacheRead( id, "SETFEG", "FEPIDS", i );
Argument<String> idBox= new Argument<>("","");
Platform.cacheRead( idBox, "SETFEG", "FEPIDS", i );
id = idBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.cacheDelete( "SETFEG", "FEEVAL", id );
......
......@@ -12,7 +12,9 @@ void getfepinrs(IStream res,boolean feponly)
for(int i = 1;i <= cnt;i++)
{
id = "";
Platform.cacheRead( id, "SETFEG", "FEPIDS", i );
Argument<String> idBox= new Argument<>("","");
Platform.cacheRead( idBox, "SETFEG", "FEPIDS", i );
id = idBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.reraise();
......@@ -33,7 +35,9 @@ void getfepinrs(IStream res,boolean feponly)
for(int i = 1;i <= cnt;i++)
{
id = "";
Platform.cacheRead( id, "SETFEG", "FEEIDS", i );
Argument<String> idBox= new Argument<>("","");
Platform.cacheRead( idBox, "SETFEG", "FEEIDS", i );
id = idBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.reraise();
......
......@@ -14,7 +14,9 @@ void remTrnFeeGroup(String argid)
for(int i = 1;i <= cnt;i++)
{
id = "";
Platform.cacheRead( id, "SETFEG", "FEEIDS", i );
Argument<String> idBox= new Argument<>("","");
Platform.cacheRead( idBox, "SETFEG", "FEEIDS", i );
id = idBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.reraise();
......
......@@ -3,7 +3,9 @@ String getfepval(String inr,String nam)
//! get value stored with function add2fepinp for INR and name
//! Corresponding function:add2fepinp
String value = "";
Platform.cacheRead( value, "SETFEG", "FEEVAL", inr, nam );
Argument<String> valueBox= new Argument<>("","");
Platform.cacheRead( valueBox, "SETFEG", "FEEVAL", inr, nam );
value = valueBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
Platform.clear( value );
......
......@@ -15,7 +15,9 @@ default $macbog order 1000
for(int i = 1;i <= cnt;i++)
{
mac = "";
Platform.cacheRead( mac, "SETFEG", "MAC", i );
Argument<String> macBox= new Argument<>("","");
Platform.cacheRead( macBox, "SETFEG", "MAC", i );
mac = macBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.reraise();
......
......@@ -16,7 +16,9 @@ void fillPtyInrStmForFep(IStream argstm)
for(int i = 1;i <= cnt;i++)
{
id = "";
Platform.cacheRead( id, "SETFEG", "FEPIDS", i );
Argument<String> idBox= new Argument<>("","");
Platform.cacheRead( idBox, "SETFEG", "FEPIDS", i );
id = idBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.reraise();
......
......@@ -14,12 +14,16 @@ void getfepfeecods(IStream res,boolean feponly)
for(int i = 1;i <= cnt;i++)
{
id = "";
Platform.cacheRead( id, "SETFEG", "FEPIDS", i );
Argument<String> idBox= new Argument<>("","");
Platform.cacheRead( idBox, "SETFEG", "FEPIDS", i );
id = idBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.reraise();
feecod = "";
Platform.cacheRead( feecod, "SETFEG", "FEEVAL", id, "FEECOD" );
Argument<String> feecodBox= new Argument<>("","");
Platform.cacheRead( feecodBox, "SETFEG", "FEEVAL", id, "FEECOD" );
feecod = feecodBox.value;
Platform.streamInsert( res, 0, feecod + #CT000307 + id );
}
}
......@@ -37,12 +41,16 @@ void getfepfeecods(IStream res,boolean feponly)
for(int i = 1;i <= cnt;i++)
{
id = "";
Platform.cacheRead( id, "SETFEG", "FEEIDS", i );
Argument<String> idBox= new Argument<>("","");
Platform.cacheRead( idBox, "SETFEG", "FEEIDS", i );
id = idBox.value;
if( Platform.errorCode() != tdCacheNotFound )
{
Platform.reraise();
feecod = "";
Platform.cacheRead( feecod, "SETFEG", "FEEVAL", id, "FEECOD" );
Argument<String> feecodBox= new Argument<>("","");
Platform.cacheRead( feecodBox, "SETFEG", "FEEVAL", id, "FEECOD" );
feecod = feecodBox.value;
Platform.streamInsert( res, 0, feecod + #CT000308 + id );
}
}
......
......@@ -3,11 +3,13 @@ String getCurCal(String incur)
// Gets calender for currency
// Clear Calendar register
String calChk = "";
Argument<String> calChkBox= new Argument<>("","");
String iniValue = NULLSTR;
if( ! Platform.isEmpty( incur ) )
{
// search calender in cache
Platform.cacheRead( calChk, "CURCAL", incur );
Platform.cacheRead( calChkBox, "CURCAL", incur );
calChk = calChkBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
// check where calendar is defined
......
......@@ -2,7 +2,9 @@ String getAlternateFeeCodetable(String argtag,String argmt)
{
// DO5CS.703597
String altCT = "";
Platform.cacheRead( altCT, "ALTFEESFT", argtag, argmt );
Argument<String> altCTBox= new Argument<>("","");
Platform.cacheRead( altCTBox, "ALTFEESFT", argtag, argmt );
altCT = altCTBox.value;
String tag = NULLSTR;
IStream keylst = new StreamImpl();
if( Platform.errorCode() > 0 )
......
String getTextOfInrTable(String tableid,String tableinr,String fieldid)
{
String fld = "";
Platform.cacheRead( fld, "TRNMOD", tableid, tableinr, fieldid );
Argument<String> fldBox= new Argument<>("","");
Platform.cacheRead( fldBox, "TRNMOD", tableid, tableinr, fieldid );
fld = fldBox.value;
if( Platform.errorCode() == tdCacheNotFound )
{
if( ! Platform.isEmpty( tableinr ) )
......
......@@ -21,7 +21,9 @@ boolean ifSameContract(IStream argstm)
obj = "";
objtyp = "";
objinr = "";
Platform.cacheRead( obj, "OBJofTRN", trninr );
Argument<String> objBox= new Argument<>("","");
Platform.cacheRead( objBox, "OBJofTRN", trninr );
obj = objBox.value;
if( Platform.errorCode() > 0 )
{
if( Platform.errorCode() == tdCacheNotFound )
......
......@@ -5,7 +5,9 @@ String validCurrencies(Date value)
IStream valstm = new StreamImpl();
Platform.streamClear( valstm );
String valDat = Platform.toString( valstm );
Platform.cacheRead( valDat, "VALCUR", $\sysmod\ety\extkey.getValue(), value );
Argument<String> valDatBox= new Argument<>("","");
Platform.cacheRead( valDatBox, "VALCUR", $\sysmod\ety\extkey.getValue(), value );
valDat = valDatBox.value;
if( Platform.errorCode() <= 0 )
{
return valDat;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment