blob: 16f69a843956de4f3367b72d6c4014bdb5ee9bcb [file] [log] [blame]
Yuta HIGUCHIdb1b8302014-06-26 10:50:39 -07001package net.onrc.onos.core.topology;
2
3import java.util.Map;
4
Yuta HIGUCHIbf0a8712014-06-30 18:59:46 -07005// TODO We may want to separate configuration attributes and
6// running state attributes.
Yuta HIGUCHIdb1b8302014-06-26 10:50:39 -07007/**
8 * Interface for Elements with StringAttributes.
9 */
10public interface StringAttributes {
11 /**
12 * Gets the string attribute.
13 *
14 * @param attr attribute name
15 * @return attribute value or null
16 */
17 public String getStringAttribute(final String attr);
18
19 /**
20 * Gets the string attribute.
21 *
22 * @param attr attribute name
23 * @param def default value if {@code attr} did not exist
24 * @return attribute value or null
25 */
26 public String getStringAttribute(final String attr, final String def);
27
28 /**
29 * Gets all the string attributes.
30 *
31 * @return Immutable Map containing all the String attributes.
32 */
33 public Map<String, String> getAllStringAttributes();
34}