private HashMap<String, String> readLookupEntries(String lookupName){
HashMap<String, String> lookupEntryMap = new HashMap<String, String>();
tcLookupOperationsIntf lookupOperationsIntf = Platform.getService(tcLookupOperationsIntf.class);
try {
tcResultSet resultSet = lookupOperationsIntf.getLookupValues(lookupName);
for(int i = 0; resultSet.getRowCount(); i++){
resultSet.goToRow(i);
lookupEntryMap.put(resultSet.getStringValue("Lookup Definition.Lookup Code Information.Code Key"), resultSet.getStringValue("Lookup Definition.Lookup Code Information.Decode") );
}
catch(Exception e){
e.printStackTrace();
}
finally{
lookupOperationsIntf.close();
}
return lookupEntryMap;
No comments:
Post a Comment