Use QNameModule#intern()
[yangtools.git] / yang / yang-common / src / main / java / org / opendaylight / yangtools / yang / common / YangConstants.java
1 /*
2  * Copyright (c) 2015 Cisco Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8 package org.opendaylight.yangtools.yang.common;
9
10 import java.net.URI;
11
12 /**
13  * Constant definitions present in RFC documents related to the YANG language.
14  */
15 public final class YangConstants {
16     /**
17      * YANG namespace, as defined in RFC 6020.
18      */
19     public static final URI RFC6020_YANG_NAMESPACE = URI.create("urn:ietf:params:xml:ns:yang:1");
20
21     /**
22      * YIN namespace, as defined in RFC 6020.
23      */
24     public static final URI RFC6020_YIN_NAMESPACE = URI.create("urn:ietf:params:xml:ns:yang:yin:1");
25
26     /**
27      * Base QNameModule for all YANG statements.
28      */
29     public static final QNameModule RFC6020_YANG_MODULE = QNameModule.create(RFC6020_YANG_NAMESPACE, null).intern();
30
31     /**
32      * Base QNameModule for all YIN statements.
33      */
34     public static final QNameModule RFC6020_YIN_MODULE = QNameModule.create(RFC6020_YIN_NAMESPACE, null).intern();
35
36     private YangConstants() {
37         throw new UnsupportedOperationException("Utility class");
38     }
39
40 }