![]() |
Project
|
#include <DataSpecUtils.h>
Static Public Member Functions | |
| static bool | match (InputSpec const &spec, ConcreteDataMatcher const &target) |
| static bool | match (InputSpec const &spec, ConcreteDataTypeMatcher const &target) |
| static bool | match (OutputSpec const &left, OutputSpec const &right) |
| static bool | match (OutputSpec const &spec, ConcreteDataMatcher const &target) |
| static bool | match (InputSpec const &input, OutputSpec const &output) |
| static bool | match (const InputSpec &spec, const o2::header::DataOrigin &origin, const o2::header::DataDescription &description, const o2::header::DataHeader::SubSpecificationType &subSpec) |
| static bool | match (const OutputSpec &spec, const o2::header::DataOrigin &origin, const o2::header::DataDescription &description, const o2::header::DataHeader::SubSpecificationType &subSpec) |
| static bool | match (const InputSpec &spec, o2::header::DataHeader const &dh) |
| static bool | match (const OutputSpec &spec, o2::header::DataHeader const &dh) |
| template<typename ContainerT > | |
| static std::optional< typename ContainerT::value_type > | find (ContainerT const &container, const o2::header::DataOrigin &origin, const o2::header::DataDescription &description, const o2::header::DataHeader::SubSpecificationType &subSpec) |
| static bool | partialMatch (InputSpec const &spec, o2::header::DataOrigin const &origin) |
| template<size_t N> | |
| static bool | partialMatch (InputSpec const &spec, std::array< header::DataOrigin, N > const &origins) |
| static bool | partialMatch (OutputSpec const &spec, o2::header::DataOrigin const &origin) |
| template<size_t N> | |
| static bool | partialMatch (OutputSpec const &spec, std::array< header::DataOrigin, N > const &origins) |
| static bool | partialMatch (InputSpec const &spec, o2::header::DataDescription const &description) |
| static bool | partialMatch (OutputSpec const &spec, o2::header::DataDescription const &description) |
| template<typename T > | |
| static bool | match (const T &spec, const o2::header::DataHeader &header) |
| static std::string | describe (InputSpec const &spec) |
| static std::string | describe (OutputSpec const &spec) |
| static std::string | describe (ConcreteDataMatcher const &matcher) |
| Describes a ConcreteDataMatcher. | |
| static std::string | label (InputSpec const &spec) |
| static std::string | label (OutputSpec const &spec) |
| static std::string | restEndpoint (InputSpec const &spec) |
| static void | updateMatchingSubspec (InputSpec &in, header::DataHeader::SubSpecificationType subSpec) |
| static void | updateMatchingSubspec (OutputSpec &in, header::DataHeader::SubSpecificationType subSpec) |
| static bool | validate (InputSpec const &input) |
| static bool | validate (OutputSpec const &output) |
| template<HasMatcher T> | |
| static size_t | describe (char *buffer, size_t size, T const &spec) |
| Same as the other describe, but uses a buffer to reduce memory churn. | |
| static ConcreteDataMatcher | asConcreteDataMatcher (InputSpec const &input) |
| static ConcreteDataMatcher | asConcreteDataMatcher (OutputSpec const &spec) |
| static std::optional< ConcreteDataMatcher > | asOptionalConcreteDataMatcher (OutputSpec const &spec) |
| static ConcreteDataTypeMatcher | asConcreteDataTypeMatcher (OutputSpec const &spec) |
| static ConcreteDataTypeMatcher | asConcreteDataTypeMatcher (InputSpec const &spec) |
| static header::DataOrigin | asConcreteOrigin (InputSpec const &spec) |
| static header::DataDescription | asConcreteDataDescription (InputSpec const &spec) |
| static OutputSpec | asOutputSpec (InputSpec const &spec) |
| static InputSpec | matchingInput (OutputSpec const &spec) |
| static InputSpec | fromMetadataString (std::string s) |
| Create an InputSpec from metadata string. | |
| static ConcreteDataMatcher | fromString (std::string s) |
| Create a concrete data matcher from serialized string. | |
| static std::optional< header::DataOrigin > | getOptionalOrigin (InputSpec const &spec) |
| Get the origin, if available. | |
| static std::optional< header::DataDescription > | getOptionalDescription (InputSpec const &spec) |
| Get the description, if available. | |
| static std::optional< header::DataHeader::SubSpecificationType > | getOptionalSubSpec (OutputSpec const &spec) |
| Get the subspec, if available. | |
| static std::optional< header::DataHeader::SubSpecificationType > | getOptionalSubSpec (InputSpec const &spec) |
| Get the subspec, if available. | |
| static data_matcher::DataDescriptorMatcher | dataDescriptorMatcherFrom (ConcreteDataMatcher const &concrete) |
| Build a DataDescriptMatcher which does not care about the subSpec. | |
| static data_matcher::DataDescriptorMatcher | dataDescriptorMatcherFrom (ConcreteDataTypeMatcher const &dataType) |
| Build a DataDescriptMatcher which does not care about the subSpec. | |
| static data_matcher::DataDescriptorMatcher | dataDescriptorMatcherFrom (header::DataOrigin const &origin) |
| Build a DataDescriptMatcher which does not care about the subSpec and description. | |
| static data_matcher::DataDescriptorMatcher | dataDescriptorMatcherFrom (header::DataDescription const &origin) |
| Build a DataDescriptMatcher which does not care about the subSpec and origin. | |
| static std::optional< framework::ConcreteDataMatcher > | optionalConcreteDataMatcherFrom (data_matcher::DataDescriptorMatcher const &matcher) |
| static bool | includes (const InputSpec &left, const InputSpec &right) |
| Checks if left includes right (or is equal to) | |
| static void | updateInputList (std::vector< InputSpec > &list, InputSpec &&input) |
| Updates list of InputSpecs by merging metadata. | |
| static void | updateOutputList (std::vector< OutputSpec > &list, OutputSpec &&input) |
| Updates list of OutputSpecs by merging metadata (or adding output). | |
Definition at line 27 of file DataSpecUtils.h.
|
static |
If possible extract the DataDescription from an InputSpec. This will not always be possible, depending on how complex of a query the InputSpec does, however in most cases it should be ok and we can add corner cases as we go.
Definition at line 469 of file DataSpecUtils.cxx.
|
static |
If possible extract the ConcreteDataMatcher from an InputSpec. This can be done either if the InputSpec is defined in terms for a ConcreteDataMatcher or if the query can be uniquely assigned to a ConcreteDataMatcher.
Definition at line 394 of file DataSpecUtils.cxx.
|
static |
If possible extract the ConcreteDataMatcher from an OutputSpec. For the moment this is trivial as the OutputSpec does not allow for wildcards.
| std::runtime_error | if the OutputSpec contains wildcards. |
Definition at line 411 of file DataSpecUtils.cxx.
|
static |
If possible extract the ConcreteTypeDataMatcher from an InputSpec. This will not always be possible, depending on how complex of a query the InputSpec does, however in most cases it should be ok and we can add corner cases as we go.
Definition at line 437 of file DataSpecUtils.cxx.
|
static |
If possible extract the ConcreteTypeDataMatcher from an OutputSpec. This will always be possible, but implementation will have to take into account the fact that the OutputSpec might have a wildcard on the subSpec.
Definition at line 429 of file DataSpecUtils.cxx.
|
static |
If possible extract the DataOrigin from an InputSpec. This will not always be possible, depending on how complex of a query the InputSpec does, however in most cases it should be ok and we can add corner cases as we go.
Definition at line 453 of file DataSpecUtils.cxx.
|
static |
As the other asConcreteDataMatcher, but returns a std::optional and does its best to handle the case where the OutputSpec contains a wildcard.
Definition at line 416 of file DataSpecUtils.cxx.
|
static |
If possible extract either ConcreteTypeDataMatcher or ConcreteDataMatcher from an InputSpec and assign it to the matcher of the OutputSpec together with binding and lifetime If InputSpec holds a ConcreteDataMatcher, this will be used directly, if it is a DataDescriptorMatcher, depending on its complexity the ConcreteDataMatcher or ConcreteTypeDataMatcher will be created
Definition at line 485 of file DataSpecUtils.cxx.
|
static |
Build a DataDescriptMatcher which does not care about the subSpec.
Definition at line 504 of file DataSpecUtils.cxx.
|
static |
Build a DataDescriptMatcher which does not care about the subSpec.
Definition at line 520 of file DataSpecUtils.cxx.
|
static |
Build a DataDescriptMatcher which does not care about the subSpec and origin.
Definition at line 551 of file DataSpecUtils.cxx.
|
static |
Build a DataDescriptMatcher which does not care about the subSpec and description.
Definition at line 533 of file DataSpecUtils.cxx.
|
static |
Same as the other describe, but uses a buffer to reduce memory churn.
Definition at line 98 of file DataSpecUtils.cxx.
|
static |
Describes a ConcreteDataMatcher.
Definition at line 92 of file DataSpecUtils.cxx.
|
static |
Describes an InputSpec. Use this to get some human readable version of the contents of the InputSpec. Notice this is not part of the InputSpec API, because there is no unique way a description should be done, so we keep this outside.
Definition at line 72 of file DataSpecUtils.cxx.
|
static |
Describes an OutputSpec. Use this to get some human readable version of the contents of the OutputSpec.
Definition at line 84 of file DataSpecUtils.cxx.
|
inlinestatic |
find a matching spec in the container
Definition at line 68 of file DataSpecUtils.h.
|
static |
Create an InputSpec from metadata string.
Definition at line 665 of file DataSpecUtils.cxx.
|
static |
Create a concrete data matcher from serialized string.
Definition at line 686 of file DataSpecUtils.cxx.
|
static |
Get the description, if available.
Definition at line 726 of file DataSpecUtils.cxx.
|
static |
Get the origin, if available.
Definition at line 707 of file DataSpecUtils.cxx.
|
static |
Get the subspec, if available.
Definition at line 757 of file DataSpecUtils.cxx.
|
static |
Get the subspec, if available.
Definition at line 745 of file DataSpecUtils.cxx.
|
static |
Checks if left includes right (or is equal to)
Definition at line 776 of file DataSpecUtils.cxx.
|
static |
Provide a unique label for the input spec. Again this is outside because there is no standard way of doing it, so better not to pollute the API.
Definition at line 121 of file DataSpecUtils.cxx.
|
static |
Provide a unique label for the input spec. Again this is outside because there is no standard way of doing it, so better not to pollute the API.
Definition at line 137 of file DataSpecUtils.cxx.
|
static |
Definition at line 44 of file DataSpecUtils.cxx.
|
inlinestatic |
Definition at line 55 of file DataSpecUtils.h.
|
static |
Definition at line 53 of file DataSpecUtils.cxx.
|
inlinestatic |
Definition at line 60 of file DataSpecUtils.h.
|
inlinestatic |
Definition at line 109 of file DataSpecUtils.h.
|
static |
Definition at line 268 of file DataSpecUtils.cxx.
|
static |
Definition at line 229 of file DataSpecUtils.cxx.
|
static |
Definition at line 207 of file DataSpecUtils.cxx.
|
static |
Definition at line 254 of file DataSpecUtils.cxx.
|
static |
Definition at line 241 of file DataSpecUtils.cxx.
|
static |
Create an InputSpec which is able to match all the outputs of the given OutputSpec
Definition at line 644 of file DataSpecUtils.cxx.
|
static |
return fully qualified ConcreteDataMatcher if DataMatcher is connecting unique properties via 'and' operation
Definition at line 569 of file DataSpecUtils.cxx.
|
static |
Definition at line 287 of file DataSpecUtils.cxx.
|
static |
Definition at line 282 of file DataSpecUtils.cxx.
|
inlinestatic |
Definition at line 86 of file DataSpecUtils.h.
|
static |
Definition at line 296 of file DataSpecUtils.cxx.
|
static |
Definition at line 276 of file DataSpecUtils.cxx.
|
inlinestatic |
Definition at line 96 of file DataSpecUtils.h.
|
static |
Provides the to be used as suffix for any REST endpoint related to the spec.
Definition at line 146 of file DataSpecUtils.cxx.
|
static |
Updates list of InputSpecs by merging metadata.
Definition at line 803 of file DataSpecUtils.cxx.
|
static |
Given an InputSpec, manipulate it so that it will match only the given subSpec.
Definition at line 155 of file DataSpecUtils.cxx.
|
static |
Given an OutputSpec, manipulate it so that it will match only the given subSpec.
Definition at line 166 of file DataSpecUtils.cxx.
|
static |
Updates list of OutputSpecs by merging metadata (or adding output).
Definition at line 819 of file DataSpecUtils.cxx.
|
static |
Definition at line 182 of file DataSpecUtils.cxx.
|
static |
Definition at line 197 of file DataSpecUtils.cxx.