(svn r26166) -Fix: Scale flows only after mapping to avoid rounding errors.

This commit is contained in:
fonsinchen
2013-12-20 14:57:44 +00:00
parent 2852dbae2c
commit fea3a433b2
5 changed files with 42 additions and 8 deletions

View File

@@ -23,12 +23,25 @@
*/
class FlowMapper : public ComponentHandler {
public:
/**
* Create a flow mapper.
* @param scale Whether the flow mapper should scale all flows to monthly
* values. Only do that on the very last flow mapping.
*/
FlowMapper(bool scale) : scale(scale) {}
virtual void Run(LinkGraphJob &job) const;
/**
* Virtual destructor has to be defined because of virtual Run().
*/
virtual ~FlowMapper() {}
private:
/**
* Whether the flow mapper should scale all flows to monthly values.
*/
const bool scale;
};
#endif /* FLOWMAPPER_H_ */