|
Mantid
|
This class is for filtering TimeSeriesProperty data. More...
#include <LogFilter.h>
Public Member Functions | |
| void | addFilter (const TimeSeriesProperty< bool > &filter) |
| Adds a filter using boolean AND. | |
| void | clear () |
| Clears filters. | |
| FilteredTimeSeriesProperty< double > * | data () const |
| Returns reference to the filtered property. | |
| const TimeSeriesProperty< bool > * | filter () const |
| Returns a reference to the filter. | |
| LogFilter ()=delete | |
| Disable default constructor. | |
| LogFilter (const LogFilter &)=delete | |
| Disable copy and assignment operator. | |
| LogFilter (const Property *prop) | |
| Constructor taking any property type. | |
| LogFilter (const TimeSeriesProperty< bool > &filter) | |
| Constructor taking a filter. | |
| LogFilter (const TimeSeriesProperty< double > *timeSeries) | |
| Constructor from a TimeSeriesProperty<double> object to avoid overhead of casts. | |
| LogFilter & | operator= (const LogFilter &)=delete |
Private Member Functions | |
| FilteredTimeSeriesProperty< double > * | convertToTimeSeriesOfDouble (const Property *prop) |
| Converts the given property to a TimeSeriesProperty<double>, throws if invalid. | |
| void | setFilter (const TimeROI &roi, const bool filterOpenEnded) |
Private Attributes | |
| std::unique_ptr< TimeSeriesProperty< bool > > | m_filter |
| Owned pointer to the filter mask. | |
| std::unique_ptr< FilteredTimeSeriesProperty< double > > | m_prop |
| Owned pointer to the filtered property. | |
This class is for filtering TimeSeriesProperty data.
Definition at line 32 of file LogFilter.h.
|
delete |
Disable default constructor.
|
delete |
Disable copy and assignment operator.
| Mantid::Kernel::LogFilter::LogFilter | ( | const TimeSeriesProperty< bool > & | filter | ) |
Constructor taking a filter.
Constructor taking a reference to a filter.
Allows filters to be combined without being applied to a property
Note that constructing a LogFilter this way only allows filters to be combined. They will not affect a property
| filter | :: A reference to a TimeSeriesProperty<bool> that will act as a filter |
Definition at line 26 of file LogFilter.cpp.
References addFilter(), and filter().
| Mantid::Kernel::LogFilter::LogFilter | ( | const Property * | prop | ) |
Constructor taking any property type.
Constructor.
| prop | :: Pointer to property to be filtered. Its actual type must be TimeSeriesProperty<double> |
Definition at line 36 of file LogFilter.cpp.
References convertToTimeSeriesOfDouble(), and m_prop.
| Mantid::Kernel::LogFilter::LogFilter | ( | const TimeSeriesProperty< double > * | timeSeries | ) |
Constructor from a TimeSeriesProperty<double> object to avoid overhead of casts.
/ Constructor from a TimeSeriesProperty<double> object to avoid overhead of casts
Definition at line 44 of file LogFilter.cpp.
References convertToTimeSeriesOfDouble(), and m_prop.
| void Mantid::Kernel::LogFilter::addFilter | ( | const TimeSeriesProperty< bool > & | filter | ) |
Adds a filter using boolean AND.
Filter using a TimeSeriesProperty<bool>.
True values mark the allowed time intervals. The object is cloned
| filter | :: Filtering mask |
Definition at line 55 of file LogFilter.cpp.
References Mantid::Kernel::TimeROI::addMask(), Mantid::Kernel::TimeROI::addROI(), Mantid::Kernel::TimeSeriesProperty< TYPE >::clone(), filter(), Mantid::Kernel::TimeSeriesProperty< TYPE >::firstTime(), Mantid::Kernel::TimeSeriesProperty< TYPE >::lastValue(), m_filter, m_prop, setFilter(), Mantid::Kernel::TimeSeriesProperty< TYPE >::size(), Mantid::Kernel::TimeInterval::start(), Mantid::Kernel::TimeROI::update_intersection(), and Mantid::Kernel::TimeSeriesProperty< TYPE >::valuesAsVector().
Referenced by export_LogFilter(), Mantid::Kernel::PropertyManager::filterByProperty(), and LogFilter().
| void Mantid::Kernel::LogFilter::clear | ( | ) |
|
private |
Converts the given property to a TimeSeriesProperty<double>, throws if invalid.
| prop | :: A pointer to a property |
Definition at line 189 of file LogFilter.cpp.
References Mantid::Kernel::Property::name().
Referenced by LogFilter(), and LogFilter().
|
inline |
Returns reference to the filtered property.
Definition at line 53 of file LogFilter.h.
Referenced by export_LogFilter().
|
inline |
Returns a reference to the filter.
Definition at line 55 of file LogFilter.h.
Referenced by addFilter(), Mantid::Kernel::PropertyManager::filterByProperty(), and LogFilter().
|
private |
Definition at line 202 of file LogFilter.cpp.
References m_filter, and Mantid::Kernel::TimeROI::toTimeIntervals().
Referenced by addFilter().
|
private |
Owned pointer to the filter mask.
Definition at line 68 of file LogFilter.h.
Referenced by addFilter(), clear(), and setFilter().
|
private |
Owned pointer to the filtered property.
Definition at line 66 of file LogFilter.h.
Referenced by addFilter(), clear(), LogFilter(), and LogFilter().