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

Method add

src/proxy/logging/LogFilter.cc:999–1019  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

997 -------------------------------------------------------------------------*/
998
999void
1000LogFilterList::add(LogFilter *filter, bool copy)
1001{
1002 ink_assert(filter != nullptr);
1003 if (copy) {
1004 if (filter->type() == LogFilter::INT_FILTER) {
1005 LogFilterInt *f = new LogFilterInt(*((LogFilterInt *)filter));
1006 m_filter_list.enqueue(f);
1007 } else if (filter->type() == LogFilter::IP_FILTER) {
1008 LogFilterIP *f = new LogFilterIP(*((LogFilterIP *)filter));
1009 m_filter_list.enqueue(f);
1010 } else {
1011 LogFilterString *f = new LogFilterString(*((LogFilterString *)filter));
1012 m_filter_list.enqueue(f);
1013 }
1014 } else {
1015 m_filter_list.enqueue(filter);
1016 }
1017
1018 m_has_wipe |= filter->is_wipe();
1019}
1020
1021/*-------------------------------------------------------------------------
1022 -------------------------------------------------------------------------*/

Callers

nothing calls this directly

Calls 3

is_wipeMethod · 0.80
typeMethod · 0.45
enqueueMethod · 0.45

Tested by

no test coverage detected