2 * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved.
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
8 package org.opendaylight.controller.yang.parser.builder.api;
10 import java.util.List;
12 import org.opendaylight.controller.yang.parser.builder.impl.UnknownSchemaNodeBuilder;
15 * Parent interface for all builder interfaces.
17 public interface Builder {
20 * Get current line in yang file.
22 * @return current line in yang file
27 * Get parent node of this node.
29 * @return parent node builder or null if this is top level node
34 * Set parent of this node.
39 void setParent(Builder parent);
42 * Add unknown node to this builder.
46 void addUnknownNodeBuilder(UnknownSchemaNodeBuilder unknownNode);
49 * Get builders of unknown nodes defined in this node.
51 * @return collection of UnknownSchemaNodeBuilder objects
53 List<UnknownSchemaNodeBuilder> getUnknownNodeBuilders();
56 * Build YANG data model node.
58 * This method should create an instance of YANG data model node. After
59 * creating an instance, this instance should be returned for each call
60 * without repeating build process.
62 * @return YANG data model node