Skip to content

Commit

Permalink
default keep packaging for sink
Browse files Browse the repository at this point in the history
  • Loading branch information
nuclearkatie committed Jul 24, 2024
1 parent 798c8e9 commit c358180
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/sink.cc
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Sink::Sink(cyclus::Context* ctx)
capacity(std::numeric_limits<double>::max()),
latitude(0.0),
longitude(0.0),
keep_packaging(1),
coordinates(latitude, longitude) {
SetMaxInventorySize(std::numeric_limits<double>::max());}

Expand Down Expand Up @@ -43,6 +44,8 @@ void Sink::EnterNotify() {
cyclus::Facility::EnterNotify();
LOG(cyclus::LEV_INFO4, "SnkFac") << " using random behavior " << random_size_type;

inventory.keep_packaging(keep_packaging);

if (in_commod_prefs.size() == 0) {
for (int i = 0; i < in_commods.size(); ++i) {
in_commod_prefs.push_back(cyclus::kDefaultPref);
Expand Down
12 changes: 12 additions & 0 deletions src/sink.h
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,18 @@ class Sink
"frequency of the request, this is the upper bound. Default 1e299"}
int random_frequency_max;

#pragma cyclus var { \
"default": 1, \
"tooltip": "Whether to persist packaging in the sink.", \
"doc": "Boolean value about whether to keep packaging. If true, " \
"packaging will not be stripped upon acceptance into the " \
"sink. If false, package type will be stripped immediately " \
"upon acceptance. Has no effect if the incoming material is not " \
"packaged.", \
"uilabel": "Keep Packaging", \
"uitype": "bool"}
bool keep_packaging;

#pragma cyclus var { \
"default": 0.0, \
"uilabel": "Geographical latitude in degrees as a double", \
Expand Down

0 comments on commit c358180

Please sign in to comment.