Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(userspace/libsinsp): make get_field_names a property of generic formatters #1120

Merged
merged 1 commit into from
May 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
chore(userspace/libsinsp): make get_field_names a property of generic…
… formatters

Signed-off-by: Jason Dellaluce <jasondellaluce@gmail.com>
  • Loading branch information
jasondellaluce committed May 25, 2023
commit 88579b01dbee00b6da6f38be124447de070a7dbc
2 changes: 1 addition & 1 deletion userspace/libsinsp/eventformatter.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ class SINSP_PUBLIC sinsp_evt_formatter : public gen_event_formatter
// interface. It just calls resolve_tokens().
bool get_field_values(gen_event *evt, std::map<std::string, std::string> &fields) override;

void get_field_names(std::vector<std::string> &fields);
void get_field_names(std::vector<std::string> &fields) override;

gen_event_formatter::output_format get_output_format() override;

Expand Down
2 changes: 2 additions & 0 deletions userspace/libsinsp/gen_filter.h
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,8 @@ class gen_event_formatter
// (e.g. "proc.name"), to field value (e.g. "nginx")
virtual bool get_field_values(gen_event *evt, std::map<std::string, std::string> &fields) = 0;

virtual void get_field_names(std::vector<std::string> &fields) = 0;

virtual output_format get_output_format() = 0;
};

Expand Down