本文整理汇总了Java中com.belladati.sdk.util.CachedList.load方法的典型用法代码示例。如果您正苦于以下问题:Java CachedList.load方法的具体用法?Java CachedList.load怎么用?Java CachedList.load使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.belladati.sdk.util.CachedList
的用法示例。
在下文中一共展示了CachedList.load方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: loadDataSource
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Import is loaded correctly from getService(). */
public void loadDataSource() {
registerSingleImport(
builder.buildSourceImportNode(id, caller, lastImport, overwritePolicy, interval, customIntervalLength));
CachedList<DataSourceImport> imports = getService().getDataSourceImports(dsId);
imports.load();
server.assertRequestUris(importUri);
assertEquals(imports.toList().size(), 1);
DataSourceImport exec = imports.toList().get(0);
assertEquals(exec.getId(), id);
assertEquals(exec.getCallerName(), caller);
Calendar expectedImport = Calendar.getInstance(TimeZone.getTimeZone("GMT"));
expectedImport.set(2012, 3, 16, 10, 17, 26);
expectedImport.set(Calendar.MILLISECOND, 0);
assertEquals(exec.getNextExecutionDate(), expectedImport.getTime());
assertEquals(exec.getRepeatInterval().getMinutes(), customIntervalLength);
assertTrue(exec.isOverwriting());
}
示例2: loadFromDataSet
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Import is loaded correctly from data source. */
public void loadFromDataSet() {
registerSingleImport(
builder.buildSourceImportNode(id, caller, lastImport, overwritePolicy, interval, customIntervalLength));
DataSource source = new DataSourceImpl(getService(), builder.buildDataSourceNode(dsId, "", ""));
CachedList<DataSourceImport> imports = source.getImports();
imports.load();
server.assertRequestUris(importUri);
assertEquals(imports.toList().size(), 1);
DataSourceImport exec = imports.toList().get(0);
assertEquals(exec.getId(), id);
assertEquals(exec.getCallerName(), caller);
Calendar expectedImport = Calendar.getInstance(TimeZone.getTimeZone("GMT"));
expectedImport.set(2012, 3, 16, 10, 17, 26);
expectedImport.set(Calendar.MILLISECOND, 0);
assertEquals(exec.getNextExecutionDate(), expectedImport.getTime());
assertEquals(exec.getRepeatInterval().getMinutes(), customIntervalLength);
assertTrue(exec.isOverwriting());
}
示例3: loadDataSource
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Data source is loaded correctly from service. */
public void loadDataSource() {
registerSingleDataSource(builder.buildDataSourceNode(id, name, type));
CachedList<DataSource> dataSources = getService().getDataSources(dsId);
dataSources.load();
server.assertRequestUris(dataSourcesUri);
assertEquals(dataSources.toList().size(), 1);
DataSource source = dataSources.toList().get(0);
assertEquals(source.getId(), id);
assertEquals(source.getName(), name);
assertEquals(source.getType(), type);
assertEquals(source.toString(), name);
}
示例4: loadFromDataSet
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Data source is loaded correctly from data set. */
public void loadFromDataSet() {
registerSingleDataSource(builder.buildDataSourceNode(id, name, type));
DataSet dataSet = new DataSetImpl(getService(), builder.buildDataSetNode(dsId, "", null, null, null));
CachedList<DataSource> dataSources = dataSet.getDataSources();
dataSources.load();
server.assertRequestUris(dataSourcesUri);
assertEquals(dataSources.toList().size(), 1);
DataSource source = dataSources.toList().get(0);
assertEquals(source.getId(), id);
assertEquals(source.getName(), name);
assertEquals(source.getType(), type);
assertEquals(source.toString(), name);
}
示例5: loadForms_withElements
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
public void loadForms_withElements() {
server.registerPaginatedItem(baseUri, "importForms", builder.buildFormNode(id, name, recordTimestamp, testElements()));
CachedList<Form> list = getService().getImportForms();
list.load();
server.assertRequestUris(baseUri);
assertEquals(list.get().size(), 1);
Form form = list.get().get(0);
assertEquals(form.getId(), id);
assertEquals(form.getName(), name);
assertEquals(form.getRecordTimestamp() + "", recordTimestamp);
assertEquals(form.toString(), name);
assertEquals(form.getElements().size(), 6);
assertElements(form.getElements());
}
示例6: loadDomainInfo
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Regular domain info data is loaded correctly. */
public void loadDomainInfo() {
server.registerPaginatedItem(baseUri, "domains", builder.buildDomainInfoNode(id, name, description, active));
CachedList<DomainInfo> infos = getService().getDomainInfo();
infos.load();
server.assertRequestUris(baseUri);
assertEquals(infos.get().size(), 1);
DomainInfo info = infos.get().get(0);
assertEquals(info.getId(), id);
assertEquals(info.getName(), name);
assertEquals(info.getDescription(), description);
assertEquals(info.getActive() + "", active);
assertEquals(info.toString(), name);
}
示例7: loadUsers_withoutGroupFilter
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Users (without group filter) are loaded correctly from getService(). */
public void loadUsers_withoutGroupFilter() {
registerSingleUser(builder.buildUserNode(user_id, user_name, "", "", "", "", "", "", null, null, id, null, null));
ObjectNode node = builder.buildDomainNode(id, name, description, dateFormat, timeFormat, timeZone, locale, active);
Domain domain = new DomainImpl(getService(), node);
CachedList<User> list = domain.loadUsers(null);
list.load();
server.assertRequestUris(usersUri);
assertEquals(list.toList().size(), 1);
User item = list.toList().get(0);
assertEquals(item.getId(), user_id);
assertEquals(item.getUsername(), user_name);
assertEquals(item.getDomainId(), id);
assertEquals(item.getUserGroups().size(), 0);
assertEquals(item.toString(), user_name);
}
示例8: loadUsers_withGroupFilter
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Users (with group filter) are loaded correctly from getService(). */
public void loadUsers_withGroupFilter() {
registerSingleUser(
builder.buildUserNode(user_id, user_name, "", "", "", "", "", "", null, null, id, null, userGroupsJson));
ObjectNode infoJson = builder.buildDomainInfoNode(id, name, description, active);
DomainInfo domainInfo = new DomainInfoImpl(getService(), infoJson);
CachedList<User> list = domainInfo.loadUsers(userGroup_id);
list.load();
server.assertRequestUris(usersUri);
assertEquals(list.toList().size(), 1);
User item = list.toList().get(0);
assertEquals(item.getId(), user_id);
assertEquals(item.getUsername(), user_name);
assertEquals(item.getDomainId(), id);
assertEquals(item.getUserGroups().size(), 1);
UserGroup[] groups = item.getUserGroups().toArray(new UserGroup[1]);
assertEquals(groups[0].getId(), userGroup_id);
assertEquals(groups[0].getName(), userGroup_name);
assertEquals(groups[0].getDescription(), "");
assertEquals(item.toString(), user_name);
}
示例9: loadUserGroups_fromDomain
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Loads UserGroups from Domain. */
public void loadUserGroups_fromDomain() {
ObjectNode infoJson = builder.buildDomainInfoNode(id, name, description, active);
server.register(apiUri + id, infoJson.toString());
registerSingleUserGroup(builder.buildUserGroupNode(userGroup_id, userGroup_name, description));
DomainInfo domainInfo = new DomainInfoImpl(getService(), infoJson);
assertEquals(domainInfo.getId(), id);
Domain domain = domainInfo.loadDetails();
CachedList<UserGroup> list = domain.loadUserGroups();
list.load();
assertEquals(list.toList().size(), 1);
UserGroup item = list.toList().get(0);
assertEquals(item.getId(), userGroup_id);
assertEquals(item.getName(), userGroup_name);
assertEquals(item.getDescription(), description);
assertEquals(item.toString(), userGroup_name);
}
示例10: loadUserGroups_fromDomainInfo
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Loads UserGroups from DomainInfo. */
public void loadUserGroups_fromDomainInfo() {
registerSingleUserGroup(builder.buildUserGroupNode(userGroup_id, userGroup_name, description));
ObjectNode infoJson = builder.buildDomainInfoNode(id, name, description, active);
DomainInfo domainInfo = new DomainInfoImpl(getService(), infoJson);
assertEquals(domainInfo.getId(), id);
CachedList<UserGroup> list = domainInfo.loadUserGroups();
list.load();
assertEquals(list.toList().size(), 1);
UserGroup item = list.toList().get(0);
assertEquals(item.getId(), userGroup_id);
assertEquals(item.getName(), userGroup_name);
assertEquals(item.getDescription(), description);
assertEquals(item.toString(), userGroup_name);
}
示例11: loadDataSource
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Import is loaded correctly from service. */
public void loadDataSource() {
CachedList<DataSourceImport> imports = service.getDataSourceImports(dsId);
registerSingleImport(builder.buildSourceImportNode(id, caller, lastImport, overwritePolicy, interval,
customIntervalLength));
imports.load();
server.assertRequestUris(importUri);
assertEquals(imports.toList().size(), 1);
DataSourceImport exec = imports.toList().get(0);
assertEquals(exec.getId(), id);
assertEquals(exec.getCallerName(), caller);
Calendar expectedImport = Calendar.getInstance(TimeZone.getTimeZone("GMT"));
expectedImport.set(2012, 3, 16, 10, 17, 26);
expectedImport.set(Calendar.MILLISECOND, 0);
assertEquals(exec.getNextExecutionDate(), expectedImport.getTime());
assertEquals(exec.getRepeatInterval().getMinutes(), customIntervalLength);
assertTrue(exec.isOverwriting());
}
示例12: loadFromDataSet
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Import is loaded correctly from data source. */
public void loadFromDataSet() {
DataSource source = new DataSourceImpl(service, builder.buildDataSourceNode(dsId, "", ""));
CachedList<DataSourceImport> imports = source.getImports();
registerSingleImport(builder.buildSourceImportNode(id, caller, lastImport, overwritePolicy, interval,
customIntervalLength));
imports.load();
server.assertRequestUris(importUri);
assertEquals(imports.toList().size(), 1);
DataSourceImport exec = imports.toList().get(0);
assertEquals(exec.getId(), id);
assertEquals(exec.getCallerName(), caller);
Calendar expectedImport = Calendar.getInstance(TimeZone.getTimeZone("GMT"));
expectedImport.set(2012, 3, 16, 10, 17, 26);
expectedImport.set(Calendar.MILLISECOND, 0);
assertEquals(exec.getNextExecutionDate(), expectedImport.getTime());
assertEquals(exec.getRepeatInterval().getMinutes(), customIntervalLength);
assertTrue(exec.isOverwriting());
}
示例13: loadDataSource
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Data source is loaded correctly from service. */
public void loadDataSource() {
CachedList<DataSource> dataSources = service.getDataSources(dsId);
registerSingleDataSource(builder.buildDataSourceNode(id, name, type));
dataSources.load();
server.assertRequestUris(dataSourcesUri);
assertEquals(dataSources.toList().size(), 1);
DataSource source = dataSources.toList().get(0);
assertEquals(source.getId(), id);
assertEquals(source.getName(), name);
assertEquals(source.getType(), type);
assertEquals(source.toString(), name);
}
示例14: loadFromDataSet
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
/** Data source is loaded correctly from data set. */
public void loadFromDataSet() {
DataSet dataSet = new DataSetImpl(service, builder.buildDataSetNode(dsId, "", null, null, null));
CachedList<DataSource> dataSources = dataSet.getDataSources();
registerSingleDataSource(builder.buildDataSourceNode(id, name, type));
dataSources.load();
server.assertRequestUris(dataSourcesUri);
assertEquals(dataSources.toList().size(), 1);
DataSource source = dataSources.toList().get(0);
assertEquals(source.getId(), id);
assertEquals(source.getName(), name);
assertEquals(source.getType(), type);
assertEquals(source.toString(), name);
}
示例15: loadForms_withoutElements
import com.belladati.sdk.util.CachedList; //导入方法依赖的package包/类
public void loadForms_withoutElements() {
server.registerPaginatedItem(baseUri, "importForms", builder.buildFormNode(id, name, recordTimestamp));
CachedList<Form> list = getService().getImportForms();
list.load();
server.assertRequestUris(baseUri);
assertEquals(list.get().size(), 1);
Form form = list.get().get(0);
assertEquals(form.getId(), id);
assertEquals(form.getName(), name);
assertEquals(form.getRecordTimestamp() + "", recordTimestamp);
assertEquals(form.getElements().size(), 0);
assertEquals(form.toString(), name);
}