MCPcopy Create free account
hub / github.com/apache/trafficserver / eval_pair

Method eval_pair

plugins/experimental/txn_box/plugin/src/query.cc:746–764  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

744}
745
746void
747Mod_query_filter::Case::eval_pair(Context &ctx, const PairExpr &pe, QPair &qp) const
748{
749 if (!pe._name.empty()) {
750 auto name = ctx.extract(pe._name);
751 if (!is_nil(name)) {
752 qp.name = ctx.render_transient([&](BufferWriter &w) { w.print("{}", name); });
753 ctx.commit_transient();
754 }
755 }
756
757 if (!pe._value.empty()) {
758 auto value = ctx.extract(pe._value);
759 if (!is_nil(value)) {
760 qp.value = ctx.render_transient([&](BufferWriter &w) { w.print("{}", value); });
761 ctx.commit_transient();
762 }
763 }
764}
765
766Rv<Feature>
767Mod_query_filter::operator()(Context &ctx, feature_type_for<STRING> qs)

Callers 1

operator()Method · 0.80

Calls 5

is_nilFunction · 0.85
render_transientMethod · 0.80
emptyMethod · 0.45
extractMethod · 0.45
printMethod · 0.45

Tested by

no test coverage detected