TTTT Analysis  0.1
Classes | Namespaces | Typedefs
value.hpp File Reference
#include <iostream>
#include <utility>
#include <algorithm>
#include <map>
#include <vector>
#include <tuple>
#include <initializer_list>
#include <functional>
Include dependency graph for value.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  filval::GenValue
 A type-agnostic value. More...
 
class  filval::Value< T >
 A generic value. More...
 
class  filval::ObservedValue< T >
 A generic, observed, value. More...
 
class  filval::DerivedValue< T >
 A generic, derived, value. More...
 
class  filval::WrapperVector< T >
 A std::vector wrapper around a C-style array. More...
 
class  filval::Pair< T1, T2 >
 Creates a std::pair type from a two other Value objects. More...
 
class  filval::ZipMapFour< R, T >
 Takes a set of four Value<std::vector<T> > objects and a function of four Ts and returns a std::vector<R>. More...
 
class  filval::Reduce< T >
 Reduce a Value of type vector<T> to just a T. More...
 
class  filval::Max< T >
 Find and return the maximum value of a vector. More...
 
class  filval::Min< T >
 Find and return the minimum value of a vector. More...
 
class  filval::Mean< T >
 Calculate the mean value of a vector. More...
 
class  filval::ElementOf< T >
 Extract the element at a specific index from a vector. More...
 
class  filval::ReduceIndex< T >
 Similar to Reduce, but returns a pair of a T and an int. More...
 
class  filval::MaxIndex< T >
 Find and return the maximum value of a vector and its index. More...
 
class  filval::MinIndex< T >
 Find and return the minimum value of a vector and its index. More...
 
class  filval::MultiFunc< R, T >
 A variadic. More...
 
class  filval::BoundValue< T >
 A generic value owning only a function object. More...
 
class  filval::ConstantValue< T >
 A Value which always returns the same value, supplied in the constructor. More...
 

Namespaces

 filval
 The namespace containing all filval classes and functions.
 

Typedefs

typedef std::map< std::string, GenValue * > filval::ValueSet
 

Detailed Description

Author
Caleb Fangmeier caleb.nosp@m.@fan.nosp@m.gmeie.nosp@m.r.te.nosp@m.ch
Version
0.1

LICENSE

MIT License

Copyright (c) 2017 Caleb Fangmeier

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

DESCRIPTION

This header defines a set of generic classes that wrap up "values". In essence, a Value<T> object is just something that contains a value of type T and can provide it when requested. The usefulness stems from composing values together with calculations. This enables very clear dependency mapping and a way to know clearly how every value was arrived at. This could be used to, for example, automatically generate commentary for plots that explain the exect calculation used to create it. Or easily making a series of plots contrasting different values that have been composed slightly differently.