本文整理汇总了C++中Tools::append方法的典型用法代码示例。如果您正苦于以下问题:C++ Tools::append方法的具体用法?C++ Tools::append怎么用?C++ Tools::append使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Tools
的用法示例。
在下文中一共展示了Tools::append方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: ti
TEST_F(RunManagerTestFixture, Workflow_ToWorkItems)
{
ToolInfo ti("tool", openstudio::toPath("somepath"));
Tools tis;
tis.append(ti);
JobParam param("param1");
JobParams params;
params.append(param);
FileInfo fi(openstudio::toPath("somefile.txt"), "txt");
Files fis;
fis.append(fi);
Workflow wf("null->energyplus");
wf.add(params);
wf.add(tis);
wf.add(fis);
std::vector<WorkItem> wis = wf.toWorkItems();
ASSERT_EQ(2u, wis.size());
EXPECT_EQ(JobType(JobType::Null), wis[0].type);
EXPECT_EQ(JobType(JobType::EnergyPlus), wis[1].type);
EXPECT_EQ(params, wis[0].params);
EXPECT_EQ(fis, wis[0].files);
EXPECT_EQ(tis, wis[0].tools);
EXPECT_TRUE(wis[1].params.params().empty());
EXPECT_TRUE(wis[1].files.files().empty());
EXPECT_TRUE(wis[1].tools.tools().empty());
}
示例2: createEnergyPlusJob
Job JobFactory::createEnergyPlusJob(
ToolInfo t_energyPlusTool,
const openstudio::path &t_idd,
const openstudio::path &t_idf,
const openstudio::path &t_epw,
const openstudio::path &t_outdir,
const boost::optional<openstudio::UUID> &t_uuid)
{
JobParams params;
params.append("outdir", toString(t_outdir));
Tools tools;
t_energyPlusTool.name = "energyplus";
tools.append(t_energyPlusTool);
Files files;
FileInfo idf(t_idf, "idf");
if (!t_idd.empty())
{
idf.addRequiredFile(t_idd,toPath("Energy+.idd"));
}
idf.addRequiredFile(t_epw, toPath("in.epw"));
files.append(idf);
return createEnergyPlusJob(tools, params, files, std::vector<openstudio::URLSearchPath>(), t_uuid);
}