1

Below is my code that supposedly will output the specified cell in the datapool

java.io.File dpFile = new java.io.File((String) getOption(IOptionName.DATASTORE), "MainScript.rftdp");
IDatapool dp = dpFactory().load(dpFile, true);
IDatapoolEquivalenceClass equivalenceClass = (IDatapoolEquivalenceClass)
dp.getEquivalenceClass(dp.getDefaultEquivalenceClassIndex());
IDatapoolRecord record = equivalenceClass.getRecord(0);
IDatapoolCell cell = (IDatapoolCell) record.getCell(0);
System.out.println(cell.toString());

But I only get this as an output:

com.rational.test.ft.datapool.impl.DatapoolCell@4caf7c7f

How do I get a specific row value of 2 columns?

  • `IDatapoolCell` has `getIntValue(), getFloatValue(), etc`. `toString()` is probably the default implementation from `Object`. – PeterMmm Jan 22 '15 at 06:50

1 Answers1

1

Are you looking for dpString(String) method? It returns value of given column in the current datapool row.

If you want to iterate all rows, you can use

while(!dpDone())
{
    doSomething();
    dpNext();
}
Cagin Uludamar
  • 372
  • 1
  • 3
  • 16