RowSetIterator Demo:
****************************************************************
OAViewObjectImpl vo = getStaffDetailsVO1();
StaffDetailsVORowImpl row = null;
int fetchedRowCount = vo.getRowCount();
RowSetIterator saveItr = vo.createRowSetIterator("saveItr");
if(fetchedRowCount > 0)
{
saveItr.setRangeStart(0);
saveItr.setRangeSize(fetchedRowCount);
for(int i=0;i<fetchedRowCount;i++)
{
row = (StaffDetailsVO)saveItr.getRowAtIndex(i);
String empName = row.getempName();
int empId = Integer.parseInt(row.getempId().toString());
System.out.println("Values :" + empName + " and "+ empId);
} //for loop
} //fetchedRowCount
saveItr.closeRowSetIterator();
****************************************************************
****************************************************************
OAViewObjectImpl vo = getStaffDetailsVO1();
StaffDetailsVORowImpl row = null;
int fetchedRowCount = vo.getRowCount();
RowSetIterator saveItr = vo.createRowSetIterator("saveItr");
if(fetchedRowCount > 0)
{
saveItr.setRangeStart(0);
saveItr.setRangeSize(fetchedRowCount);
for(int i=0;i<fetchedRowCount;i++)
{
row = (StaffDetailsVO)saveItr.getRowAtIndex(i);
String empName = row.getempName();
int empId = Integer.parseInt(row.getempId().toString());
System.out.println("Values :" + empName + " and "+ empId);
} //for loop
} //fetchedRowCount
saveItr.closeRowSetIterator();
****************************************************************
No comments:
Post a Comment