贴一个RFT HELP里链接数据池的例子
public void testMain(Object[] args) {java.io.File dpFile = new java.io.File((String)getOption(IOptionName.DATASTORE),"datapool/ClassicsDP.rftdp");
IDatapool dp = dpFactory().load(dpFile, true);
//Use default iterator class
IDatapoolIterator dpIter = dpFactory().open(dp, null);
//Use default equivalence class
dpIter.dpInitialize(dp);
while ( !dpIter.dpDone() )
{
// Insert actions using dpIter based references to the datapool
//Get the current datapool record
dpIter.dpCurrent();
//Get the String value at column index 0 in current record
dpIter.dpString("0");
//Get the int value at column index 1 in current record
dpIter.dpInt(1);
//Move the pointer to next record
dpIter.dpNext();
}
} 嗯。不错。帮助文档里还有取表内容,下拉列表内容的例子,都是超实用的例子。
页:
[1]