Merge "Bug 1505 - Provide test coverage for binding-data-codec using sal-test-model"
[yangtools.git] / yang / yang-data-api / src / main / java / org / opendaylight / yangtools / yang / data / api / AttributesContainer.java
1 /*
2  * Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8 package org.opendaylight.yangtools.yang.data.api;
9
10 import java.util.Map;
11
12 import org.opendaylight.yangtools.yang.common.QName;
13
14 /**
15  * 
16  * Container of attributes, which may be attached to {@link Node}
17  * 
18  */
19 public interface AttributesContainer {
20
21     /**
22      * Returns immutable map of QName and value of the attribute.
23      * 
24      * @return immutable map of attribute names and values.
25      */
26     Map<QName, String> getAttributes();
27
28     /**
29      * Returns attribute value by supplied QName
30      * 
31      * 
32      * @param name Attribute name
33      * @return Value of attribute if present, null otherwise.
34      */
35     Object getAttributeValue(QName name);
36
37 }