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.yangtools.yang.model.api;
10 import java.util.Optional;
11 import org.opendaylight.yangtools.concepts.SemVer;
12 import org.opendaylight.yangtools.yang.common.Revision;
15 * Interface describing YANG 'import' statement.
18 * The import statement makes definitions from one module available inside another module or submodule.
20 public interface ModuleImport extends DocumentedNode {
22 * Returns the name of the module to import.
24 * @return Name of the module to import
26 String getModuleName();
29 * Returns the module revision to import. May be null.
31 * @return Revision of module to import
33 Optional<Revision> getRevision();
36 * Returns the semantic version to import.
38 * @return Semantic version of module to import
40 Optional<SemVer> getSemanticVersion();
43 * Returns the prefix associated with the imported module.
45 * @return Prefix used to point to imported module