CYCLUS
res_manip.h
Go to the documentation of this file.
1 #ifndef CYCLUS_SRC_TOOLKIT_RES_MANIP_H_
2 #define CYCLUS_SRC_TOOLKIT_RES_MANIP_H_
3 
4 #include "material.h"
5 #include "resource.h"
6 #include "product.h"
7 
8 namespace cyclus {
9 namespace toolkit {
10 
11 /// Squash combines all products in ps and returns the resulting single
12 /// product.
13 Product::Ptr Squash(std::vector<Product::Ptr> ps);
14 
15 /// Squash combines all materials in ms and returns the resulting single
16 /// material.
17 Material::Ptr Squash(std::vector<Material::Ptr> ms);
18 
19 /// Squash combines all resources in rs and returns the resulting single
20 /// resource.
21 Resource::Ptr Squash(std::vector<Resource::Ptr> rs);
22 
23 /// Casts a vector of Materials into a vector of Resources.
24 std::vector<Resource::Ptr> ResCast(std::vector<Material::Ptr> rs);
25 
26 /// Casts a vector of Products into a vector of Resources.
27 std::vector<Resource::Ptr> ResCast(std::vector<Product::Ptr> rs);
28 
29 /// Casts a vector of Resources into a vector of Resources. This is actually
30 /// basically a no-op that enables ResBuf to work for plain Resource types.
31 std::vector<Resource::Ptr> ResCast(std::vector<Resource::Ptr> rs);
32 
33 } // namespace toolkit
34 } // namespace cyclus
35 
36 #endif // CYCLUS_SRC_TOOLKIT_RES_MANIP_H_
boost::shared_ptr< Material > Ptr
Definition: material.h:75
Product::Ptr Squash(std::vector< Product::Ptr > ps)
Squash combines all products in ps and returns the resulting single product.
Definition: res_manip.cc:7
boost::shared_ptr< Product > Ptr
Definition: product.h:24
boost::shared_ptr< Resource > Ptr
Definition: resource.h:24
taken directly from OsiSolverInterface.cpp on 2/17/14 from https://projects.coin-or.org/Osi/browser/trunk.
Definition: agent.cc:14
std::vector< Resource::Ptr > ResCast(std::vector< Material::Ptr > rs)
Casts a vector of Materials into a vector of Resources.
Definition: res_manip.cc:48