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.parser.spi.source;
11 import org.eclipse.jdt.annotation.NonNull;
12 import org.eclipse.jdt.annotation.Nullable;
13 import org.opendaylight.yangtools.yang.common.QName;
14 import org.opendaylight.yangtools.yang.model.api.meta.IdentifierNamespace;
15 import org.opendaylight.yangtools.yang.model.api.meta.StatementDefinition;
16 import org.opendaylight.yangtools.yang.parser.spi.meta.NamespaceBehaviour;
19 * Map of fully qualified statement name to statement definition.
21 public interface QNameToStatementDefinition extends IdentifierNamespace<QName, StatementDefinition> {
22 NamespaceBehaviour<QName, StatementDefinition, @NonNull QNameToStatementDefinition> BEHAVIOUR =
23 NamespaceBehaviour.sourceLocal(QNameToStatementDefinition.class);
26 * Returns StatementDefinition with specified QName.
29 * QName of requested statement
30 * @return StatementDefinition
33 StatementDefinition get(QName identifier);
36 * Returns StatementDefinition with specified namespace and localName.
39 * namespace of requested statement
41 * localName of requested statement
42 * @return StatementDefinition
44 @Nullable StatementDefinition getByNamespaceAndLocalName(@NonNull URI namespace, @NonNull String localName);