A collection of scalar bounds to be used as a unary predicate. More...
Public Member Functions | |
constexpr | scalarRanges () noexcept=default |
Default construct. More... | |
scalarRanges (const std::string &str, bool report=true) | |
Construct by parsing string using the parse() static method. More... | |
bool | match (const scalar &value) const |
Match any condition in the list. More... | |
bool | operator() (const scalar &value) const |
Use match() as a predicate. More... | |
Public Member Functions inherited from List< scalarRange > | |
constexpr | List () noexcept |
Default construct. More... | |
List (const label len) | |
Construct with given size. More... | |
List (const label len, const scalarRange &val) | |
Construct with given size and value for all elements. More... | |
List (const label len, const Foam::zero) | |
Construct with given size initializing all elements to zero. More... | |
List (const Foam::one, const scalarRange &val) | |
Construct with length=1, copying the value as the only content. More... | |
List (const Foam::one, scalarRange &&val) | |
Construct with length=1, moving the value as the only content. More... | |
List (const Foam::one, const Foam::zero) | |
Construct with length=1, initializing content to zero. More... | |
List (const List< scalarRange > &a) | |
Copy construct from list. More... | |
List (const UList< scalarRange > &a) | |
Copy construct contents from list. More... | |
List (List< scalarRange > &a, bool reuse) | |
Construct as copy or re-use as specified. More... | |
List (const UList< scalarRange > &list, const labelUList &indices) | |
Copy construct subset of list. More... | |
List (const UList< scalarRange > &list, const FixedList< label, N > &indices) | |
Copy construct subset of list. More... | |
List (const FixedList< scalarRange, N > &list) | |
Construct as copy of FixedList<T, N> More... | |
List (const PtrList< scalarRange > &list) | |
Construct as copy of PtrList<T> More... | |
List (const SLList< scalarRange > &list) | |
Construct as copy of SLList<T> More... | |
List (const IndirectListBase< scalarRange, Addr > &list) | |
Construct as copy of IndirectList contents. More... | |
List (std::initializer_list< scalarRange > list) | |
Construct from an initializer list. More... | |
List (List< scalarRange > &&list) | |
Move construct from List. More... | |
List (DynamicList< scalarRange, SizeMin > &&list) | |
Move construct from DynamicList. More... | |
List (SortableList< scalarRange > &&list) | |
Move construct from SortableList. More... | |
List (SLList< scalarRange > &&list) | |
Move construct from SLList. More... | |
List (Istream &is) | |
Construct from Istream. More... | |
autoPtr< List< scalarRange > > | clone () const |
Clone. More... | |
~List () | |
Destructor. More... | |
void | clear () |
Clear the list, i.e. set size to zero. More... | |
void | resize (const label len) |
Adjust allocated size of list. More... | |
void | resize (const label len, const scalarRange &val) |
Adjust allocated size of list and set val for new elements. More... | |
void | resize (const label newLen) |
void | resize_nocopy (const label len) |
Adjust allocated size of list without necessarily. More... | |
void | setSize (const label n) |
Alias for resize() More... | |
void | setSize (const label n, const scalarRange &val) |
Alias for resize() More... | |
void | append (const scalarRange &val) |
Append an element at the end of the list. More... | |
void | append (scalarRange &&val) |
Move append an element at the end of the list. More... | |
void | append (const UList< scalarRange > &list) |
Append a List to the end of this list. More... | |
void | append (const IndirectListBase< scalarRange, Addr > &list) |
Append IndirectList contents at the end of this list. More... | |
label | appendUniq (const scalarRange &val) |
Append an element if not already in the list. More... | |
void | transfer (List< scalarRange > &list) |
void | transfer (DynamicList< scalarRange, SizeMin > &list) |
void | transfer (SortableList< scalarRange > &list) |
scalarRange & | newElmt (const label i) |
void | operator= (const UList< scalarRange > &a) |
Assignment to UList operator. Takes linear time. More... | |
void | operator= (const List< scalarRange > &list) |
Assignment operator. Takes linear time. More... | |
void | operator= (const SLList< scalarRange > &list) |
Assignment to SLList operator. Takes linear time. More... | |
void | operator= (const IndirectListBase< scalarRange, Addr > &list) |
Assignment from IndirectList. Takes linear time. More... | |
void | operator= (const FixedList< scalarRange, N > &list) |
Copy assignment from FixedList. More... | |
void | operator= (std::initializer_list< scalarRange > list) |
Assignment to an initializer list. More... | |
void | operator= (const scalarRange &val) |
Assignment of all entries to the given value. More... | |
void | operator= (const Foam::zero) |
Assignment of all entries to zero. More... | |
void | operator= (List< scalarRange > &&list) |
Move assignment. Takes constant time. More... | |
void | operator= (DynamicList< scalarRange, SizeMin > &&list) |
Move assignment. Takes constant time. More... | |
void | operator= (SortableList< scalarRange > &&list) |
Move assignment. Takes constant time. More... | |
void | operator= (SLList< scalarRange > &&list) |
Move assignment. Takes constant time. More... | |
Istream & | readList (Istream &is) |
Read List from Istream, discarding contents of existing List. More... | |
Istream & | readList (Istream &is) |
Istream & | readList (Istream &is) |
void | shallowCopy (const UList< scalarRange > &)=delete |
No shallowCopy permitted. More... | |
std::enable_if< std::is_same< bool, TypeT >::value, bool >::type | set (const label i, bool val=true) |
A bitSet::set() method for a list of bool. More... | |
Static Public Member Functions | |
static scalarRanges | parse (const std::string &str, bool report=true) |
Construct by parsing string for scalar ranges. More... | |
Static Public Member Functions inherited from List< scalarRange > | |
static const List< scalarRange > & | null () |
Return a null List. More... | |
Additional Inherited Members | |
Public Types inherited from List< scalarRange > | |
typedef SubList< scalarRange > | subList |
Declare type of subList. More... | |
A collection of scalar bounds to be used as a unary predicate.
Definition at line 55 of file scalarRanges.H.
|
constexprdefaultnoexcept |
Default construct.
|
inlineexplicit |
Construct by parsing string using the parse() static method.
report | Report when any range fails to parse |
Definition at line 30 of file scalarRangesI.H.
|
static |
Construct by parsing string for scalar ranges.
The individual items are space, comma or semicolon delimited.
report | Report when any range fails to parse |
Definition at line 34 of file scalarRanges.C.
References Foam::endl(), Foam::Info, n, range, s, and Foam::stringOps::splitAny().
|
inline |
Match any condition in the list.
Definition at line 38 of file scalarRangesI.H.
References range.
Referenced by timeSelector::selected().
|
inline |
Use match() as a predicate.
Definition at line 54 of file scalarRangesI.H.
References Foam::stringOps::match().