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.data.impl.leafref;
10 import com.google.common.collect.ImmutableList;
11 import java.util.List;
12 import org.opendaylight.yangtools.yang.common.QName;
13 import org.opendaylight.yangtools.yang.common.QNameModule;
15 final class QNameWithPredicateImpl extends AbstractQNameWithPredicate {
16 private final ImmutableList<QNamePredicate> qnamePredicates;
17 private final QNameModule moduleQname;
18 private final String localName;
20 QNameWithPredicateImpl(final QNameModule moduleQname, final String localName,
21 final List<QNamePredicate> qnamePredicates) {
22 this.moduleQname = moduleQname;
23 this.localName = localName;
24 this.qnamePredicates = ImmutableList.copyOf(qnamePredicates);
28 public List<QNamePredicate> getQNamePredicates() {
29 return qnamePredicates;
33 public QNameModule getModuleQname() {
38 public String getLocalName() {
43 public QName getQName() {
44 return QName.create(moduleQname, localName);