@@ -492,12 +492,6 @@ class TableConsumer;
492492// / Helper class actually implementing the cursor which can write to
493493// / a table. The provided template arguments are if type Column and
494494// / therefore refer only to the persisted columns.
495- template <typename T>
496- concept is_producable = soa::has_metadata<aod::MetadataTrait<o2::aod::Hash<T::ref.desc_hash>>> || soa::has_metadata<aod::MetadataTrait<o2::aod::Hash<T::parent_t ::ref.desc_hash>>>;
497-
498- template <typename T>
499- concept is_enumerated_iterator = requires (T t) { t.globalIndex (); };
500-
501495template <is_producable T>
502496struct WritingCursor {
503497 public:
@@ -579,13 +573,13 @@ struct WritingCursor {
579573 decltype (FFL (std::declval<cursor_t >())) cursor;
580574
581575 private:
582- static decltype (auto ) extract(is_enumerated_iterator auto const & arg)
576+ static decltype (auto ) extract(soa:: is_enumerated_iterator auto const & arg)
583577 {
584578 return arg.globalIndex ();
585579 }
586580
587581 template <typename A>
588- requires (!is_enumerated_iterator<A>)
582+ requires (!soa:: is_enumerated_iterator<A>)
589583 static decltype (auto ) extract(A&& arg)
590584 {
591585 return arg;
@@ -642,9 +636,6 @@ template <is_producable T>
642636struct Produces : WritingCursor<T> {
643637};
644638
645- template <typename T>
646- concept is_produces = requires (T t) { typename T::cursor_t ; typename T::persistent_table_t ; &T::cursor; };
647-
648639// / Use this to group together produces. Useful to separate them logically
649640// / or simply to stay within the 100 elements per Task limit.
650641// / Use as:
@@ -654,11 +645,10 @@ concept is_produces = requires(T t) { typename T::cursor_t; typename T::persiste
654645// /
655646// / Notice the label MySetOfProduces is just a mnemonic and can be omitted.
656647struct ProducesGroup {
648+ static constexpr void isProducesGroup ()
649+ {};
657650};
658651
659- template <typename T>
660- concept is_produces_group = std::derived_from<T, ProducesGroup>;
661-
662652// / Helper template for table transformations
663653template <soa::is_metadata M, soa::TableRef Ref>
664654struct TableTransform {
@@ -682,12 +672,6 @@ struct TableTransform {
682672
683673// / This helper struct allows you to declare extended tables which should be
684674// / created by the task (as opposed to those pre-defined by data model)
685- template <typename T>
686- concept is_spawnable = soa::has_metadata<aod::MetadataTrait<o2::aod::Hash<T::originals[T::originals.size() - 1 ].desc_hash>>> && soa::has_extension<typename aod::MetadataTrait<o2::aod::Hash<T::originals[T::originals.size() - 1 ].desc_hash>>::metadata>;
687-
688- template <typename T>
689- concept is_dynamically_spawnable = soa::has_metadata<aod::MetadataTrait<o2::aod::Hash<T::originals[T::originals.size() - 1 ].desc_hash>>> && soa::has_configurable_extension<typename aod::MetadataTrait<o2::aod::Hash<T::originals[T::originals.size() - 1 ].desc_hash>>::metadata>;
690-
691675template <is_spawnable T>
692676consteval auto transformBase ()
693677{
@@ -736,13 +720,6 @@ struct Spawns : decltype(transformBase<T>()) {
736720 }();
737721};
738722
739- template <typename T>
740- concept is_spawns = requires (T t) {
741- typename T::metadata;
742- typename T::expression_pack_t ;
743- requires std::same_as<decltype (t.projector ), std::shared_ptr<gandiva::Projector>>;
744- };
745-
746723// / This helper struct allows you to declare extended tables with dynamically-supplied
747724// / expressions to be created by the task
748725// / The actual expressions have to be set in init() for the configurable expression
@@ -792,15 +769,6 @@ struct Defines : decltype(transformBase<T>()) {
792769template <is_dynamically_spawnable T>
793770using DefinesDelayed = Defines<T, true >;
794771
795- template <typename T>
796- concept is_defines = requires (T t) {
797- typename T::metadata;
798- typename T::placeholders_pack_t ;
799- requires std::same_as<decltype (t.projector ), std::shared_ptr<gandiva::Projector>>;
800- requires std::same_as<decltype (t.needRecompilation ), bool >;
801- &T::recompile;
802- };
803-
804772// / Policy to control index building
805773// / Exclusive index: each entry in a row has a valid index
806774// / Sparse index: values in a row can be (-1), index table is isomorphic (joinable) to T1
@@ -859,13 +827,6 @@ struct Builds : decltype(transformBase<T>()) {
859827 }
860828};
861829
862- template <typename T>
863- concept is_builds = requires (T t) {
864- typename T::metadata;
865- typename T::Key;
866- requires std::same_as<decltype (t.map ), std::vector<soa::IndexRecord>>;
867- };
868-
869830// / a task with rewritten origin, if running together with a task with the default, will
870831// / have a different name and thus its output would be routed separately
871832
@@ -877,6 +838,7 @@ concept is_builds = requires(T t) {
877838// / to determine the target file, e.g. analysis result, QA or control histogram,
878839// / etc.
879840template <typename T>
841+ requires (std::derived_from<T, TNamed>)
880842struct OutputObj {
881843 using obj_t = T;
882844
@@ -964,15 +926,6 @@ struct OutputObj {
964926 uint32_t mTaskHash ;
965927};
966928
967- template <typename T>
968- concept is_outputobj = requires (T t) {
969- &T::setHash;
970- &T::spec;
971- &T::ref;
972- requires std::same_as<decltype (t.operator ->()), typename T::obj_t *>;
973- requires std::same_as<decltype (t.object ), std::shared_ptr<typename T::obj_t >>;
974- };
975-
976929// / This helper allows you to fetch a Sevice from the context or
977930// / by using some singleton. This hopefully will hide the Singleton and
978931// / We will be able to retrieve it in a more thread safe manner later on.
@@ -991,12 +944,6 @@ struct Service {
991944 }
992945};
993946
994- template <typename T>
995- concept is_service = requires (T t) {
996- requires std::same_as<decltype (t.service ), typename T::service_t *>;
997- &T::operator ->;
998- };
999-
1000947auto getTableFromFilter (soa::is_filtered_table auto const & table, soa::SelectionVector&& selection)
1001948{
1002949 return std::make_unique<o2::soa::Filtered<std::decay_t <decltype (table)>>>(std::vector{table}, std::forward<soa::SelectionVector>(selection));
@@ -1016,7 +963,7 @@ void initializePartitionCaches(std::set<uint32_t> const& hashes, std::shared_ptr
1016963// / the real reason is to provide grouped parts for the process functions that request it
1017964// / better solution would be to "slice" the selection, as is already done in GroupSlicer
1018965// / for the same purpose, instead of reapplying the filtering
1019- template <typename T>
966+ template <soa::is_table T>
1020967struct Partition {
1021968 using content_t = T;
1022969 Partition (expressions::Node&& filter_) : filter{std::forward<expressions::Node>(filter_)}
@@ -1128,13 +1075,6 @@ struct Partition {
11281075 return mFiltered ->size ();
11291076 }
11301077};
1131-
1132- template <typename T>
1133- concept is_partition = requires (T t) {
1134- &T::updatePlaceholders;
1135- requires std::same_as<decltype (t.filter ), expressions::Filter>;
1136- requires std::same_as<decltype (t.mFiltered ), std::unique_ptr<o2::soa::Filtered<typename T::content_t >>>;
1137- };
11381078} // namespace o2::framework
11391079
11401080namespace o2 ::soa
0 commit comments