2 * Copyright (c) 2015 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.yangtools.yang.model.api.stmt;
10 import java.util.Collection;
11 import javax.annotation.Nonnull;
12 import javax.annotation.Nullable;
13 import org.opendaylight.yangtools.yang.model.api.meta.DeclaredStatement;
15 @Rfc6020AbnfRule("type-stmt")
16 public interface TypeStatement extends DeclaredStatement<String> {
18 @Nonnull String getName();
20 @Rfc6020AbnfRule("numerical-restrictions")
21 interface NumericalRestrictions extends TypeStatement {
23 @Nonnull RangeStatement getRange();
27 @Rfc6020AbnfRule("decimal64-specification")
28 interface Decimal64Specification extends TypeStatement {
30 @Nonnull FractionDigitsStatement getFractionDigits();
32 @Nullable RangeStatement getRange();
36 @Rfc6020AbnfRule("string-restrictions")
37 interface StringRestrictions extends TypeStatement {
39 @Nullable LengthStatement getLength();
41 @Nonnull Collection<? extends PatternStatement> getPatterns();
44 @Rfc6020AbnfRule("enum-specification")
45 interface EnumSpecification extends TypeStatement {
47 @Nonnull Collection<? extends EnumStatement> getEnums();
51 @Rfc6020AbnfRule("leafref-specification")
52 interface LeafrefSpecification extends TypeStatement {
54 @Nonnull PathStatement getPath();
58 @Rfc6020AbnfRule("instanceidentifier-specification")
59 interface InstanceIdentifierSpecification extends TypeStatement {
61 @Nullable RequireInstanceStatement getRequireInstance();
64 @Rfc6020AbnfRule("identityref-specification")
65 interface IdentityRefSpecification extends TypeStatement {
67 @Nonnull BaseStatement getBase();
71 @Rfc6020AbnfRule("bits-specification")
72 interface BitsSpecification extends TypeStatement {
74 @Nonnull Collection<? extends BitStatement> getBits();
78 @Rfc6020AbnfRule("union-specification")
79 interface UnionSpecification extends TypeStatement {
81 @Nonnull Collection<? extends TypeStatement> getTypes();
85 @Rfc6020AbnfRule("binary-specification")
86 interface BinarySpecification extends TypeStatement {
88 @Nullable LengthStatement getLength();