1b9c70867d37e7d330d0541785917565ee3d3096
[controller.git] / opendaylight / md-sal / sal-protocolbuffer-encoding / src / main / java / org / opendaylight / controller / cluster / datastore / node / utils / NodeIdentifierGenerator.java
1 /*
2  *
3  *  Copyright (c) 2014 Cisco Systems, Inc. and others.  All rights reserved.
4  *
5  *  This program and the accompanying materials are made available under the
6  *  terms of the Eclipse Public License v1.0 which accompanies this distribution,
7  *  and is available at http://www.eclipse.org/legal/epl-v10.html
8  *
9  */
10
11 package org.opendaylight.controller.cluster.datastore.node.utils;
12
13 import org.opendaylight.yangtools.yang.common.QName;
14 import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier;
15
16 public class NodeIdentifierGenerator {
17     private final String id;
18     private final QName qName;
19
20     public NodeIdentifierGenerator(String id){
21         this.id = id;
22         this.qName = QNameFactory.create(id);
23     }
24
25     public YangInstanceIdentifier.PathArgument getArgument(){
26         return new YangInstanceIdentifier.NodeIdentifier(qName);
27     }
28 }