Merge "Add support for enums as configuration attributes in config and netconf subsys...
[controller.git] / opendaylight / md-sal / sal-rest-connector / src / main / java / org / opendaylight / controller / sal / rest / impl / SchemaLocation.java
1 package org.opendaylight.controller.sal.rest.impl;
2
3 import java.util.*;
4
5 import org.opendaylight.yangtools.yang.model.api.DataSchemaNode;
6
7 class SchemaLocation {
8     final private List<String> location = new ArrayList<>();
9     final private DataSchemaNode schema;
10
11     public SchemaLocation(DataSchemaNode schema) {
12         this.schema = schema;
13     }
14
15     DataSchemaNode getSchema() {
16         return schema;
17     }
18
19     List<String> getLocation() {
20         return location;
21     }
22
23     SchemaLocation addPathPart(String partOfPath) {
24         location.add(partOfPath);
25         return this;
26     }
27
28 }