use of com.netsuite.webservices.v2016_2.platform.core.RecordRefList in project components by Talend.
the class NetSuiteOutputWriterIT method makeAccountRecords.
private static List<Account> makeAccountRecords(int count, RecordRef subsidiary) {
List<Account> recordList = new ArrayList<>(count);
for (int i = 1; i <= count; i++) {
Account record = new Account();
String id = Long.toString(System.currentTimeMillis());
record.setAcctNumber(id);
record.setAcctName("Test account " + id);
record.setAcctType(AccountType.OTHER_ASSET);
record.setDescription("Test description " + i);
RecordRefList subsidiaries = new RecordRefList();
subsidiaries.getRecordRef().add(subsidiary);
record.setSubsidiaryList(subsidiaries);
try {
Thread.sleep(10);
} catch (InterruptedException e) {
}
recordList.add(record);
}
return recordList;
}
Aggregations