2 * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved.
\r
4 * This program and the accompanying materials are made available under the
\r
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
\r
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
\r
8 package org.opendaylight.controller.yang.parser.builder.api;
\r
10 import java.util.List;
\r
12 import org.opendaylight.controller.yang.common.QName;
\r
13 import org.opendaylight.controller.yang.model.api.SchemaPath;
\r
14 import org.opendaylight.controller.yang.model.api.Status;
\r
15 import org.opendaylight.controller.yang.model.api.UnknownSchemaNode;
\r
18 * Basic implementation of SchemaNodeBuilder.
\r
20 public abstract class AbstractSchemaNodeBuilder extends AbstractBuilder implements SchemaNodeBuilder {
\r
21 protected final QName qname;
\r
22 protected SchemaPath schemaPath;
\r
23 protected String description;
\r
24 protected String reference;
\r
25 protected Status status = Status.CURRENT;
\r
26 protected List<UnknownSchemaNode> unknownNodes;
\r
28 protected AbstractSchemaNodeBuilder(final String moduleName, final int line, final QName qname) {
\r
29 super(moduleName, line);
\r
33 public QName getQName() {
\r
38 public SchemaPath getPath() {
\r
43 public void setPath(SchemaPath schemaPath) {
\r
44 this.schemaPath = schemaPath;
\r
48 public String getDescription() {
\r
53 public void setDescription(String description) {
\r
54 this.description = description;
\r
58 public String getReference() {
\r
63 public void setReference(String reference) {
\r
64 this.reference = reference;
\r
68 public Status getStatus() {
\r
73 public void setStatus(Status status) {
\r
74 if (status != null) {
\r
75 this.status = status;
\r
79 public void setUnknownNodes(List<UnknownSchemaNode> unknownNodes) {
\r
80 this.unknownNodes = unknownNodes;
\r