*/
package org.opendaylight.yangtools.yang.model.api;
+
/**
* The ContainerSchemaNode is used to define an interior data node in the schema
* tree. There are two styles of containers, those that exist only for
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api;
+
+import com.google.common.annotations.Beta;
+import com.google.common.base.Preconditions;
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.common.YangConstants;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+import org.opendaylight.yangtools.yang.model.api.meta.StatementDefinition;
+import org.opendaylight.yangtools.yang.model.api.stmt.AnyxmlStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ArgumentStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.AugmentStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.BaseStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.BelongsToStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.BitStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.CaseStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ChoiceStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ConfigStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ContactStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ContainerStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.DefaultStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.DescriptionStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.DeviateStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.DeviationStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.EnumStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ErrorAppTagStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ErrorMessageStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ExtensionStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.FeatureStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.FractionDigitsStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.GroupingStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.IdentityStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.IfFeatureStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ImportStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.IncludeStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.InputStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.KeyStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.LeafListStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.LeafStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.LengthStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ListStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.MandatoryStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.MaxElementsStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.MinElementsStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ModuleStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.MustStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.NamespaceStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.NotificationStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.OrderedByStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.OrganizationStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.OutputStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.PathStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.PatternStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.PositionStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.PrefixStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.PresenceStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.RangeStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ReferenceStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.RefineStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.RequireInstanceStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.RevisionDateStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.RevisionStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.RpcStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.StatusStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.SubmoduleStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.TypeStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.TypedefStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.UniqueStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.UnitsStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.UsesStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.ValueStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.WhenStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.YangVersionStatement;
+import org.opendaylight.yangtools.yang.model.api.stmt.YinElementStatement;
+
+@Beta
+public enum Rfc6020Mapping implements StatementDefinition {
+ Anyxml(AnyxmlStatement.class, "anyxml", "name"),
+ Argument(ArgumentStatement.class, "argument", "name"),
+ Augment(AugmentStatement.class, "augment", "target-node"),
+ Base(BaseStatement.class, "base", "name"),
+ BelongsTo(BelongsToStatement.class, "belongs-to", "module"),
+ Bit(BitStatement.class, "bit", "name"),
+ Case(CaseStatement.class, "case", "name"),
+ Choice(ChoiceStatement.class, "choice", "name"),
+ Config(ConfigStatement.class, "config", "value"),
+ Contact(ContactStatement.class, "contact", "text", true),
+ Container(ContainerStatement.class, "container", "name"),
+ Default(DefaultStatement.class, "default", "value"),
+ Description(DescriptionStatement.class, "description", "text", true),
+ Deviate(DeviateStatement.class, "deviate", "value"),
+ Deviation(DeviationStatement.class, "deviation", "target-node"),
+ Enum(EnumStatement.class, "enum", "name"),
+ ErrorAppTag(ErrorAppTagStatement.class, "error-app-tag", "value"),
+ ErrorMessage(ErrorMessageStatement.class, "error-message", "value", true),
+ Extension(ExtensionStatement.class, "extension", "name"),
+ Feature(FeatureStatement.class, "feature", "name"),
+ FractionDigits(FractionDigitsStatement.class, "fraction-digits", "value"),
+ Grouping(GroupingStatement.class, "grouping", "name"),
+ Identity(IdentityStatement.class, "identity", "name"),
+ IfFeature(IfFeatureStatement.class, "if-feature", "name"),
+ Import(ImportStatement.class, "import", "module"),
+ Include(IncludeStatement.class, "include", "module"),
+ Input(InputStatement.class, "input"),
+ Key(KeyStatement.class, "key", "value"),
+ Leaf(LeafStatement.class, "leaf", "name"),
+ LeafList(LeafListStatement.class, "leaf-list", "name"),
+ Length(LengthStatement.class, "length", "value"),
+ List(ListStatement.class, "list", "name"),
+ Mandatory(MandatoryStatement.class, "mandatory", "value"),
+ MaxElements(MaxElementsStatement.class, "max-elements", "value"),
+ MinElements(MinElementsStatement.class, "min-elements", "value"),
+ Module(ModuleStatement.class, "module", "name"),
+ Must(MustStatement.class, "must", "condition"),
+ Namespace(NamespaceStatement.class, "namespace", "uri"),
+ Notification(NotificationStatement.class, "notification", "name"),
+ OrderedBy(OrderedByStatement.class, "ordered-by", "value"),
+ Organization(OrganizationStatement.class, "organization", "text", true),
+ Output(OutputStatement.class, "output"),
+ Path(PathStatement.class, "path", "value"),
+ Pattern(PatternStatement.class, "pattern", "value"),
+ Position(PositionStatement.class, "position", "value"),
+ Prefix(PrefixStatement.class, "prefix", "value"),
+ Presence(PresenceStatement.class, "presence", "value"),
+ Range(RangeStatement.class, "range", "value"),
+ Reference(ReferenceStatement.class, "reference", "text", true),
+ Refine(RefineStatement.class, "refine", "target-node"),
+ RequireInstance(RequireInstanceStatement.class, "require-instance", "value"),
+ Revision(RevisionStatement.class, "revision", "date"),
+ RevisionDate(RevisionDateStatement.class, "revision-date", "date"),
+ Rpc(RpcStatement.class, "rpc", "name"),
+ Status(StatusStatement.class, "status", "value"),
+ Submodule(SubmoduleStatement.class, "submodule", "name"),
+ Type(TypeStatement.class, "type", "name"),
+ Typedef(TypedefStatement.class, "typedef", "name"),
+ Unique(UniqueStatement.class, "unique", "tag"),
+ Units(UnitsStatement.class, "units", "name"),
+ Uses(UsesStatement.class, "uses", "name"),
+ Value(ValueStatement.class, "value", "value"),
+ When(WhenStatement.class, "when", "condition"),
+ YangVersion(YangVersionStatement.class, "yang-version", "value"),
+ YinElement(YinElementStatement.class, "yin-element", "value");
+
+ private final @Nonnull Class<? extends DeclaredStatement<?>> type;
+ private final @Nonnull QName name;
+ private final @Nullable QName argument;
+ private final boolean yinElement;
+
+
+ private Rfc6020Mapping(Class<? extends DeclaredStatement<?>> clz, final String nameStr) {
+ type = Preconditions.checkNotNull(clz);
+ name = yinQName(nameStr);
+ argument = null;
+ yinElement = false;
+ }
+
+ private Rfc6020Mapping(Class<? extends DeclaredStatement<?>> clz, final String nameStr, final String argumentStr) {
+ type = Preconditions.checkNotNull(clz);
+ name = yinQName(nameStr);
+ argument = yinQName(argumentStr);
+ this.yinElement = false;
+ }
+
+ private Rfc6020Mapping(Class<? extends DeclaredStatement<?>> clz, final String nameStr, final String argumentStr,
+ final boolean yinElement) {
+ type = Preconditions.checkNotNull(clz);
+ name = yinQName(nameStr);
+ argument = yinQName(argumentStr);
+ this.yinElement = yinElement;
+ }
+
+ private static QName yinQName(String nameStr) {
+ return QName.cachedReference(QName.create(YangConstants.RFC6020_YIN_MODULE, nameStr));
+ }
+
+ @Override
+ public QName getStatementName() {
+ return name;
+ }
+
+ @Override
+ public QName getArgumentName() {
+ return argument;
+ }
+
+ @Override
+ public Class<? extends DeclaredStatement<?>> getDeclaredRepresentationClass() {
+ return type;
+ }
+
+ @Override
+ public Class<? extends DeclaredStatement<?>> getEffectiveRepresentationClass() {
+ // FIXME: Add support once these interfaces are defined.
+ throw new UnsupportedOperationException("Not defined yet.");
+ }
+
+ public boolean isArgumentYinElement() {
+ return yinElement;
+ }
+}
+
*/
/**
- * Definition of structures and DOM Like API of processed YANG schema
+ * Definition of structures and DOM like API of effected YANG schema
*
- * <h3>YANG Statement mapping</h3>
+ * <p>
+ * This package is structured into following logical units:
+ * <dl>
+ * <dt>YANG Meta model</dt>
+ * <dd>Meta model of YANG, which defines basic concepts and building blocks of YANG models
+ * such as {@link org.opendaylight.yangtools.yang.model.api.meta.ModelStatement}.</dd>
+ * <dt>YANG Statement model</dt>
+ * <dd>Concrete java model of YANG statements, which defines basic relationship between statements
+ * and represents these statements.</dd>
+ *
+ * <dt>YANG Effective model</dt>
+ * <dd>Effective model of processed YANG models, which represents semantic interpretation
+ * of YANG models and provides convenience views for interpreting models.
+ * </dd>
+ * </dl>
+ *
+ *
+ * <h2>YANG Effective model</h2>
+ * <h3>Effective model statement mapping</h3>
*
* <dl>
* <dt>anyxml
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nullable;
+
+public interface AnyxmlStatement extends DataDefinitionStatement {
+
+ @Nullable Collection<? extends MustStatement> getMusts();
+
+ @Nullable ConfigStatement getConfig();
+
+ @Nullable MandatoryStatement getMandatory();
+
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+
+@Rfc6020AbnfRule("argument-stmt")
+public interface ArgumentStatement extends DeclaredStatement<QName> {
+
+ @Nonnull String getName();
+
+ @Nullable YinElementStatement getYinElement();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface AugmentStatement extends DeclaredStatement<SchemaNodeIdentifier> , DataDefinitionContainer {
+
+ @Nonnull SchemaNodeIdentifier getTargetNode();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface BaseStatement extends DeclaredStatement<QName> {
+
+ @Nonnull QName getName();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface BelongsToStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getModule();
+
+ @Nonnull PrefixStatement getPrefix();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface BitStatement extends DeclaredStatement<String>, DocumentationGroup.WithStatus {
+
+ @Nonnull String getName();
+
+ @Nullable PositionStatement getPosition();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nonnull;
+
+
+@Rfc6020AbnfRule("body-stmts")
+public interface BodyGroup extends DataDefinitionContainer.WithReusableDefinitions {
+
+ @Nonnull Collection<? extends ExtensionStatement> getExtensions();
+
+ @Nonnull Collection<? extends FeatureStatement> getFeatures();
+
+ @Nonnull Collection<? extends IdentityStatement> getIdentities();
+
+ @Nonnull Collection<? extends AugmentStatement> getAugments();
+
+ @Nonnull Collection<? extends RpcStatement> getRpcs();
+
+ @Nonnull Collection<? extends NotificationStatement> getNotifications();
+
+ @Nonnull Collection<? extends DeviationStatement> getDeviations();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+public interface CaseStatement extends DeclaredStatement<QName>, DataDefinitionContainer, DocumentationGroup.WithStatus, ConditionalDataDefinition {
+
+ @Nonnull QName getName();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+
+
+
+public interface ChoiceStatement extends DataDefinitionStatement {
+
+ @Nullable DefaultStatement getDefault();
+
+ @Nullable ConfigStatement getConfig();
+
+ @Nullable MandatoryStatement getMandatory();
+
+ @Nonnull Collection<? extends CaseStatement> getCases();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+public interface ConditionalDataDefinition extends ConditionalFeature {
+
+ WhenStatement getWhenStatement();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nonnull;
+
+
+@Rfc6020AbnfRule("*(if-feature-stmt)")
+public interface ConditionalFeature {
+
+ @Nonnull Collection<? extends IfFeatureStatement> getIfFeatures();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ConfigStatement extends DeclaredStatement<Boolean> {
+
+ @Nonnull Boolean getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ContactStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getText();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nullable;
+
+
+public interface ContainerStatement extends DataDefinitionStatement, DataDefinitionContainer.WithReusableDefinitions {
+
+ @Nullable Collection<? extends MustStatement> getMusts();
+
+ @Nullable PresenceStatement getPresence();
+
+ @Nullable ConfigStatement getConfig();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+
+
+public interface DataDefinitionContainer {
+
+ Collection<? extends DataDefinitionStatement> getDataDefinitions();
+
+
+ public interface WithReusableDefinitions extends DataDefinitionContainer {
+
+ Collection<? extends TypedefStatement> getTypedefs();
+
+ Collection<? extends GroupingStatement> getGroupings();
+
+ }
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+/**
+ *
+ * Statement that defines new data nodes.
+ *
+ * One of container, leaf, leaf-list, list, choice, case,
+ * augment, uses, and anyxml.
+ *
+ *
+ * Defined in: https://tools.ietf.org/html/rfc6020#section-3
+ *
+ */
+@Rfc6020AbnfRule("data-def-stmt")
+public interface DataDefinitionStatement extends DeclaredStatement<QName>, DocumentationGroup.WithStatus, ConditionalDataDefinition {
+
+ @Nonnull QName getName();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface DefaultStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface DescriptionStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getText();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface DeviateStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface DeviationStatement extends DeclaredStatement<SchemaNodeIdentifier> {
+
+
+ @Nonnull SchemaNodeIdentifier getTargetNode();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nullable;
+
+public interface DocumentationGroup {
+
+ @Nullable DescriptionStatement getDescription();
+
+ @Nullable ReferenceStatement getReference();
+
+
+
+ public interface WithStatus extends DocumentationGroup {
+
+ @Nullable StatusStatement getStatus();
+
+ }
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nullable;
+
+public interface DocumentedConstraintGroup extends DocumentationGroup {
+
+ @Nullable ErrorAppTagStatement getErrorAppTagStatement();
+
+ @Nullable ErrorMessageStatement getErrorMessageStatement();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface EnumStatement extends DeclaredStatement<String>, DocumentationGroup.WithStatus {
+
+ @Nonnull String getName();
+
+ @Nullable ValueStatement getValue();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ErrorAppTagStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ErrorMessageStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ExtensionStatement extends DeclaredStatement<QName>, DocumentationGroup.WithStatus {
+
+ @Nullable ArgumentStatement getArgument();
+
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface FeatureStatement extends DeclaredStatement<QName>, DocumentationGroup.WithStatus, ConditionalFeature {
+
+ @Nonnull QName getName();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+public interface FractionDigitsStatement extends DeclaredStatement<String> {
+
+ String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+public interface GroupingStatement extends DeclaredStatement<QName>, DocumentationGroup.WithStatus,DataDefinitionContainer.WithReusableDefinitions {
+
+ @Nonnull QName getName();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface IdentityStatement extends DeclaredStatement<QName>, DocumentationGroup.WithStatus {
+
+ @Nonnull String getName();
+
+ @Nullable BaseStatement getBase();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface IfFeatureStatement extends DeclaredStatement<QName> {
+
+ @Nonnull QName getName();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ImportStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getModule();
+
+ @Nonnull PrefixStatement getPrefix();
+
+ @Nullable RevisionDateStatement getRevisionDate();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface IncludeStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getModule();
+
+ @Nonnull PrefixStatement getPrefix();
+
+ @Nullable RevisionDateStatement getRevisionDate();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface InputStatement extends DeclaredStatement<Void>, DataDefinitionContainer.WithReusableDefinitions {
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface KeyStatement extends DeclaredStatement<Collection<SchemaNodeIdentifier>> {
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nullable;
+
+
+
+public interface LeafListStatement extends DataDefinitionStatement, MultipleElementsGroup, TypeGroup {
+
+ @Nullable Collection<? extends MustStatement> getMusts();
+
+ @Nullable ConfigStatement getConfig();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nullable;
+
+
+
+public interface LeafStatement extends DataDefinitionStatement, TypeGroup {
+
+ @Nullable Collection<? extends MustStatement> getMusts();
+
+ @Nullable DefaultStatement getDefault();
+
+ @Nullable ConfigStatement getConfig();
+
+ @Nullable MandatoryStatement getMandatory();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface LengthStatement extends DeclaredStatement<String>, DocumentedConstraintGroup {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nonnull;
+
+
+@Rfc6020AbnfRule("linkage-stms")
+public interface LinkageGroup {
+
+ @Nonnull Collection<? extends ImportStatement> getImports();
+
+ @Nonnull Collection<? extends IncludeStatement> getIncludes();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nullable;
+
+public interface ListStatement extends DataDefinitionStatement, MultipleElementsGroup,
+ DataDefinitionContainer.WithReusableDefinitions {
+
+ Collection<? extends MustStatement> getMusts();
+
+ @Nullable KeyStatement getKey();
+
+ Collection<? extends UniqueStatement> getUnique();
+
+ @Nullable ConfigStatement getConfig();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface MandatoryStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface MaxElementsStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nullable;
+
+
+@Rfc6020AbnfRule("meta-stmts")
+public interface MetaGroup extends DocumentationGroup {
+
+ @Nullable OrganizationStatement getOrganization();
+
+ @Nullable ContactStatement getContact();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface MinElementsStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+
+@Rfc6020AbnfRule("module-header-stmts")
+public interface ModuleHeaderGroup {
+
+ @Nullable YangVersionStatement getYangVersion();
+ @Nonnull NamespaceStatement getNamespace();
+ @Nonnull PrefixStatement getPrefix();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ModuleStatement extends DeclaredStatement<String>, ModuleHeaderGroup, LinkageGroup, MetaGroup,
+ RevisionGroup, BodyGroup
+
+ {
+
+ @Nonnull String getName();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nullable;
+
+public interface MultipleElementsGroup {
+
+ @Nullable MinElementsStatement getMinElements();
+
+ @Nullable MaxElementsStatement getMaxElements();
+
+ @Nullable OrderedByStatement getOrderedBy();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.RevisionAwareXPath;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface MustStatement extends DeclaredStatement<RevisionAwareXPath>, DocumentedConstraintGroup {
+
+ @Nonnull RevisionAwareXPath getCondition();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.net.URI;
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface NamespaceStatement extends DeclaredStatement<URI> {
+
+ @Nonnull URI getUri();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface NotificationStatement extends DeclaredStatement<QName> {
+
+ @Nonnull QName getName();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface OrderedByStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface OrganizationStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getText();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface OutputStatement extends DeclaredStatement<Void>, DataDefinitionContainer.WithReusableDefinitions {
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.RevisionAwareXPath;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface PathStatement extends DeclaredStatement<RevisionAwareXPath> {
+
+ // FIXME: Introduce proper type representing parsed leafref
+ @Nonnull String getValue();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface PatternStatement extends DeclaredStatement<String>, DocumentedConstraintGroup {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface PositionStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface PrefixStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface PresenceStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface RangeStatement extends DeclaredStatement<String>, DocumentedConstraintGroup {
+
+ @Nonnull String getRange();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface ReferenceStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getText();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+public interface RefineStatement extends DeclaredStatement<SchemaNodeIdentifier>, DocumentationGroup {
+
+ String getTargetNode();
+
+ public interface RefineContainerStatement extends RefineStatement {
+
+ Collection<? extends MustStatement> getMusts();
+
+ @Nullable ConfigStatement getConfig();
+
+ @Nullable PresenceStatement getPresence();
+
+ }
+
+ public interface RefineLeafStatement extends RefineStatement {
+
+ Collection<? extends MustStatement> getMusts();
+
+ @Nullable DefaultStatement getDefault();
+
+ @Nullable ConfigStatement getConfig();
+
+ @Nullable PresenceStatement getPresence();
+
+ }
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+public interface RequireInstanceStatement extends DeclaredStatement<Boolean> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface RevisionDateStatement extends DeclaredStatement<String> {
+
+ String getDate();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+
+
+@Rfc6020AbnfRule("revision-stmts")
+public interface RevisionGroup {
+
+ Collection<? extends RevisionStatement> getRevisions();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface RevisionStatement extends DeclaredStatement<String>, DocumentationGroup {
+
+ String getDate();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
+/**
+*
+* References ABNF rule defined in RFC6020 - YANG Specification.
+*
+* <p>
+* An interface / class annotated with this annotation
+* is Java representation of data represented by ABNF rule
+* provided as {@link #value()}. Java representation
+* does not need to be direct,
+* but must retain all information in some, publicly
+* accessible form for consumers.
+* </p>
+* <p>
+* Note that this annotation is used currently only for documentation
+* and does not affect any runtime behaviour.
+* </p>
+*
+*/
+@Documented
+@Retention(RetentionPolicy.SOURCE)
+@interface Rfc6020AbnfRule {
+
+ String[] value();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface RpcStatement extends DeclaredStatement<QName> {
+
+ String getName();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import com.google.common.base.Objects;
+import com.google.common.base.Objects.ToStringHelper;
+import com.google.common.base.Preconditions;
+import com.google.common.collect.ImmutableList;
+import com.google.common.collect.Iterables;
+import java.util.Arrays;
+import java.util.Iterator;
+import java.util.List;
+import java.util.NoSuchElementException;
+import java.util.concurrent.atomic.AtomicReferenceFieldUpdater;
+import org.opendaylight.yangtools.concepts.Immutable;
+import org.opendaylight.yangtools.yang.common.QName;
+
+/**
+ * Represents unique path to the every schema node inside the schema node identifier
+ * namespace.
+ *
+ */
+public abstract class SchemaNodeIdentifier implements Immutable {
+ /**
+ * An absolute schema node identifier.
+ */
+ public static final class Absolute extends SchemaNodeIdentifier {
+ private Absolute(final SchemaNodeIdentifier parent, final QName qname) {
+ super(parent, qname);
+ }
+
+ @Override
+ public boolean isAbsolute() {
+ return true;
+ }
+
+ @Override
+ protected SchemaNodeIdentifier createInstance(final SchemaNodeIdentifier parent, final QName qname) {
+ return new Absolute(parent, qname);
+ }
+ }
+
+ /**
+ * A relative schema node identifier.
+ */
+ public static class Relative extends SchemaNodeIdentifier {
+ private Relative(final SchemaNodeIdentifier parent, final QName qname) {
+ super(parent, qname);
+ }
+
+ @Override
+ public boolean isAbsolute() {
+ return false;
+ }
+
+ @Override
+ protected SchemaNodeIdentifier createInstance(final SchemaNodeIdentifier parent, final QName qname) {
+ return new Relative(parent, qname);
+ }
+ }
+
+ @SuppressWarnings("rawtypes")
+ private static final AtomicReferenceFieldUpdater<SchemaNodeIdentifier, ImmutableList> LEGACYPATH_UPDATER =
+ AtomicReferenceFieldUpdater.newUpdater(SchemaNodeIdentifier.class, ImmutableList.class, "legacyPath");
+
+ /**
+ * Shared instance of the conceptual root schema node.
+ */
+ public static final SchemaNodeIdentifier ROOT = new Absolute(null, null);
+
+ /**
+ * Shared instance of the "same" relative schema node.
+ */
+ public static final SchemaNodeIdentifier SAME = new Relative(null, null);
+
+ /**
+ * Parent path.
+ */
+ private final SchemaNodeIdentifier parent;
+
+ /**
+ * This component.
+ */
+ private final QName qname;
+
+ /**
+ * Cached hash code. We can use this since we are immutable.
+ */
+ private final int hash;
+
+ /**
+ * Cached legacy path, filled-in when {@link #getPath()} or {@link #getPathTowardsRoot()}
+ * is invoked.
+ */
+ private volatile ImmutableList<QName> legacyPath;
+
+ private ImmutableList<QName> getLegacyPath() {
+ ImmutableList<QName> ret = legacyPath;
+ if (ret == null) {
+ ret = ImmutableList.copyOf(getPathTowardsRoot()).reverse();
+ LEGACYPATH_UPDATER.lazySet(this, ret);
+ }
+
+ return ret;
+ }
+
+ /**
+ * Returns the complete path to schema node.
+ *
+ * @return list of <code>QName</code> instances which represents complete
+ * path to schema node
+ *
+ * @deprecated Use {@link #getPathFromRoot()} instead.
+ */
+ @Deprecated
+ public List<QName> getPath() {
+ return getLegacyPath();
+ }
+
+ protected SchemaNodeIdentifier(final SchemaNodeIdentifier parent, final QName qname) {
+ this.parent = parent;
+ this.qname = qname;
+
+ int h = parent == null ? 0 : parent.hashCode();
+ if (qname != null) {
+ h = h * 31 + qname.hashCode();
+ }
+
+ hash = h;
+ }
+
+ /**
+ * Constructs new instance of this class with the concrete path.
+ *
+ * @param path
+ * list of QName instances which specifies exact path to the
+ * module node
+ * @param absolute
+ * boolean value which specifies if the path is absolute or
+ * relative
+ *
+ * @return A SchemaPath instance.
+ */
+ public static SchemaNodeIdentifier create(final Iterable<QName> path, final boolean absolute) {
+ final SchemaNodeIdentifier parent = absolute ? ROOT : SAME;
+ return parent.createChild(path);
+ }
+
+ /**
+ * Constructs new instance of this class with the concrete path.
+ *
+ * @param absolute
+ * boolean value which specifies if the path is absolute or
+ * relative
+ * @param path
+ * one or more QName instances which specifies exact path to the
+ * module node
+ *
+ * @return A SchemaPath instance.
+ */
+ public static SchemaNodeIdentifier create(final boolean absolute, final QName... path) {
+ return create(Arrays.asList(path), absolute);
+ }
+
+ /**
+ * Create a new instance.
+ *
+ * @param parent Parent schema node identifier
+ * @param qname next path element
+ * @return A new SchemaPath instance
+ */
+ protected abstract SchemaNodeIdentifier createInstance(SchemaNodeIdentifier parent, QName qname);
+
+ /**
+ * Create a child path based on concatenation of this path and a relative path.
+ *
+ * @param relative Relative path
+ * @return A new child path
+ */
+ public SchemaNodeIdentifier createChild(final Iterable<QName> relative) {
+ if (Iterables.isEmpty(relative)) {
+ return this;
+ }
+
+ SchemaNodeIdentifier parent = this;
+ for (QName qname : relative) {
+ parent = parent.createInstance(parent, qname);
+ }
+
+ return parent;
+ }
+
+ /**
+ * Create a child path based on concatenation of this path and a relative path.
+ *
+ * @param relative Relative SchemaPath
+ * @return A new child path
+ */
+ public SchemaNodeIdentifier createChild(final SchemaNodeIdentifier relative) {
+ Preconditions.checkArgument(!relative.isAbsolute(), "Child creation requires relative path");
+
+ SchemaNodeIdentifier parent = this;
+ for (QName qname : relative.getPathFromRoot()) {
+ parent = parent.createInstance(parent, qname);
+ }
+
+ return parent;
+ }
+
+ /**
+ * Create a child path based on concatenation of this path and additional
+ * path elements.
+ *
+ * @param elements Relative SchemaPath elements
+ * @return A new child path
+ */
+ public SchemaNodeIdentifier createChild(final QName... elements) {
+ return createChild(Arrays.asList(elements));
+ }
+
+ /**
+ * Returns the list of nodes which need to be traversed to get from the
+ * starting point (root for absolute SchemaPaths) to the node represented
+ * by this object.
+ *
+ * @return list of <code>qname</code> instances which represents
+ * path from the root to the schema node.
+ */
+ public Iterable<QName> getPathFromRoot() {
+ return getLegacyPath();
+ }
+
+ /**
+ * Returns the list of nodes which need to be traversed to get from this
+ * node to the starting point (root for absolute SchemaPaths).
+ *
+ * @return list of <code>qname</code> instances which represents
+ * path from the schema node towards the root.
+ */
+ public Iterable<QName> getPathTowardsRoot() {
+ return new Iterable<QName>() {
+ @Override
+ public Iterator<QName> iterator() {
+ return new Iterator<QName>() {
+ private SchemaNodeIdentifier current = SchemaNodeIdentifier.this;
+
+ @Override
+ public boolean hasNext() {
+ return current.parent != null;
+ }
+
+ @Override
+ public QName next() {
+ if (current.parent != null) {
+ final QName ret = current.qname;
+ current = current.parent;
+ return ret;
+ } else {
+ throw new NoSuchElementException("No more elements available");
+ }
+ }
+
+ @Override
+ public void remove() {
+ throw new UnsupportedOperationException("Component removal not supported");
+ }
+ };
+ }
+ };
+ }
+
+ /**
+ * Returns the immediate parent SchemaPath.
+ *
+ * @return Parent path, null if this SchemaPath is already toplevel.
+ */
+ public SchemaNodeIdentifier getParent() {
+ return parent;
+ }
+
+ /**
+ * Get the last component of this path.
+ *
+ * @return The last component of this path.
+ */
+ public final QName getLastComponent() {
+ return qname;
+ }
+
+ /**
+ * Describes whether schema node identifier is|isn't absolute.
+ *
+ * @return boolean value which is <code>true</code> if schema path is
+ * absolute.
+ */
+ public abstract boolean isAbsolute();
+
+ @Override
+ public final int hashCode() {
+ return hash;
+ }
+
+ @Override
+ public boolean equals(final Object obj) {
+ if (this == obj) {
+ return true;
+ }
+ if (obj == null) {
+ return false;
+ }
+ if (getClass() != obj.getClass()) {
+ return false;
+ }
+ final SchemaNodeIdentifier other = (SchemaNodeIdentifier) obj;
+
+ if (qname != null) {
+ if (!qname.equals(other.qname)) {
+ return false;
+ }
+ } else {
+ if (other.qname != null) {
+ return false;
+ }
+ }
+
+ if (parent == null) {
+ return other.parent == null;
+ }
+ return parent.equals(other.parent);
+ }
+
+ @Override
+ public final String toString() {
+ return addToStringAttributes(Objects.toStringHelper(this)).toString();
+ }
+
+ protected ToStringHelper addToStringAttributes(final ToStringHelper toStringHelper) {
+ return toStringHelper.add("path", getPathFromRoot());
+ }
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface StatusStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface SubmoduleStatement extends
+ DeclaredStatement<String>,
+ LinkageGroup,
+ MetaGroup,
+ RevisionGroup,
+ BodyGroup {
+
+ @Nonnull String getName();
+
+ @Nullable YangVersionStatement getYangVersion();
+
+ @Nonnull BelongsToStatement getBelongsTo();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+
+public interface TypeGroup {
+
+ @Nonnull TypeStatement getType();
+
+ @Nullable UnitsStatement getUnits();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nonnull;
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+@Rfc6020AbnfRule("type-stmt")
+public interface TypeStatement extends DeclaredStatement<QName> {
+
+ @Nonnull String getName();
+
+ @Rfc6020AbnfRule("numerical-restrictions")
+ interface NumericalRestrictions extends TypeStatement {
+
+ @Nonnull RangeStatement getRange();
+
+ }
+
+ @Rfc6020AbnfRule("decimal64-specification")
+ interface Decimal64Specification extends TypeStatement {
+
+ @Nonnull FractionDigitsStatement getFractionDigits();
+
+ @Nullable RangeStatement getRange();
+
+ }
+
+ @Rfc6020AbnfRule("string-restrictions")
+ interface StringRestrictions extends TypeStatement {
+
+ @Nullable LengthStatement getLength();
+
+ @Nonnull Collection<? extends PatternStatement> getPatterns();
+ }
+
+ @Rfc6020AbnfRule("enum-specification")
+ interface EnumSpecification extends TypeStatement {
+
+ @Nonnull Collection<? extends EnumStatement> getEnums();
+
+ }
+
+ @Rfc6020AbnfRule("leafref-specification")
+ interface LeafrefSpecification extends TypeStatement {
+
+ @Nullable PathStatement getPath();
+
+ }
+
+ interface InstanceIdentifierSpecification extends TypeStatement {
+
+ @Nullable RequireInstanceStatement getRequireInstance();
+ }
+
+
+ interface IdentityRefSpecification extends TypeStatement {
+
+ }
+ interface BitsSpecification extends TypeStatement {
+
+ @Nonnull Collection<? extends BitStatement> getBits();
+
+ }
+
+ interface UnionSpecification extends TypeStatement {
+
+ @Nonnull Collection<? extends TypeStatement> getTypes();
+
+ }
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface TypedefStatement extends DeclaredStatement<QName>,DocumentationGroup.WithStatus, TypeGroup {
+
+
+ @Nonnull String getName();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface UniqueStatement extends DeclaredStatement<Collection<SchemaNodeIdentifier.Relative>> {
+
+ @Nonnull Collection<SchemaNodeIdentifier.Relative> getTag();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+public interface UnitsStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getName();
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nullable;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface UnknownStatement<S> extends DeclaredStatement<S> {
+
+ @Nullable String getArgument();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import java.util.Collection;
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.common.QName;
+
+
+
+public interface UsesStatement extends DataDefinitionStatement {
+
+ @Override
+ @Nonnull QName getName();
+
+ @Nonnull Collection<? extends RefineStatement> getRefines();
+
+ @Nonnull Collection<? extends AugmentStatement> getAugments();
+
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+
+public interface ValueStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.RevisionAwareXPath;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface WhenStatement extends DeclaredStatement<RevisionAwareXPath>, DocumentationGroup {
+
+ @Nonnull RevisionAwareXPath getCondition();
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface YangVersionStatement extends DeclaredStatement<String> {
+
+}
+
--- /dev/null
+/*
+ * Copyright (c) 2015 Cisco Systems, Inc. and others. All rights reserved.
+ *
+ * This program and the accompanying materials are made available under the
+ * terms of the Eclipse Public License v1.0 which accompanies this distribution,
+ * and is available at http://www.eclipse.org/legal/epl-v10.html
+ */
+package org.opendaylight.yangtools.yang.model.api.stmt;
+
+import javax.annotation.Nonnull;
+import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
+
+public interface YinElementStatement extends DeclaredStatement<String> {
+
+ @Nonnull String getValue();
+}
+