HomeManualTopicsTypesSymbols

std::is_not_empty

checks whether a collection contains at least one item

Parameter

collection
the collection to be checked

Result

not_empty
true if collection is not empty, false otherwise

Description

The following invariant should always hold:

std::is_empty(collection) == (std::length_of(collection) > 0)

Topics

Collections

Strings

Lists

See also

std::is_empty checks whether a collection contains any items
std::length_of returns the number of items within a collection

Implemented by

std_types::io checks if the input-output object contains any event registrations
std_types::list returns whether the list is empty or not
std_types::octet_string returns whether the octet string is empty or not
std_types::quad_octet_string returns whether the quad-octet string is empty or not