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 @Nullable PathStatement getPath();
58 interface InstanceIdentifierSpecification extends TypeStatement {
60 @Nullable RequireInstanceStatement getRequireInstance();
64 interface IdentityRefSpecification extends TypeStatement {
67 interface BitsSpecification extends TypeStatement {
69 @Nonnull Collection<? extends BitStatement> getBits();
73 interface UnionSpecification extends TypeStatement {
75 @Nonnull Collection<? extends TypeStatement> getTypes();