Bug 8126 - Some augments are not being processed
[yangtools.git] / yang / yang-data-jaxen / src / main / java / org / opendaylight / yangtools / yang / data / jaxen / JaxenDocumentContext.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.data.jaxen;
9
10 import com.google.common.base.Preconditions;
11 import javax.annotation.Nonnull;
12 import org.opendaylight.yangtools.yang.data.api.schema.NormalizedNode;
13 import org.opendaylight.yangtools.yang.data.api.schema.xpath.XPathDocument;
14
15 final class JaxenDocument implements XPathDocument {
16     private final NormalizedNode<?, ?> root;
17
18     JaxenDocument(final JaxenSchemaContext context, final NormalizedNode<?, ?> root) {
19         this.root = Preconditions.checkNotNull(root);
20     }
21
22     @Nonnull
23     @Override
24     public NormalizedNode<?, ?> getRootNode() {
25         return root;
26     }
27 }