blob: 9fc591d8b3602e40c9327cf5ea6a21c577e56be7 [file] [log] [blame]
Deepak Kodihalli16e87542017-02-27 07:07:33 -06001#pragma once
2
3#include <vector>
4#include <string>
5#include <phosphor-logging/elog-errors.hpp>
6#include "elog_entry.hpp"
7
8namespace phosphor
9{
10namespace logging
11{
12namespace metadata
13{
14
15using Metadata = std::string;
16
17namespace associations
18{
19
20using Type = void(const std::string&,
21 const std::vector<std::string>&,
22 AssociationList& list);
23
24/** @brief Build error associations specific to metadata. Specialize this
25 * template for handling a specific type of metadata.
26 * @tparam M - type of metadata
27 * @param [in] data - metadata to be handled
28 * @param [in] data - metadata key=value entries
29 * @param [out] list - list of error association objects
30 */
31template <typename M>
32void build(const std::string& match,
33 const std::vector<std::string>& data,
34 AssociationList& list) = delete;
35
36} // namespace associations
37} // namespace metadata
38} // namespace logging
39} // namespace phosphor