JavaIdentifierNormalizer ThreadSafe/Memory leak fix
[mdsal.git] / binding2 / mdsal-binding2-generator-util / src / main / java / org / opendaylight / mdsal / binding / javav2 / generator / util / ReferencedTypeImpl.java
1 /*
2  * Copyright (c) 2017 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
9 package org.opendaylight.mdsal.binding.javav2.generator.util;
10
11 import org.opendaylight.mdsal.binding.javav2.generator.context.ModuleContext;
12
13 /**
14  *
15  * Wraps combination of <code>packageName</code> and <code>name</code> to the
16  * object representation
17  *
18  */
19 public final class ReferencedTypeImpl extends AbstractBaseType {
20
21     /**
22      * Creates instance of this class with concrete package name and type name
23      *
24      * @param packageName
25      *            string with the package name
26      * @param name
27      *            string with the name for referenced type
28      */
29     public ReferencedTypeImpl(String packageName, String name, ModuleContext context) {
30         super(packageName, name, context);
31     }
32
33     /**
34      * Creates instance of this class with concrete package name and type name
35      * for already normalized identifier
36      *
37      * @param packageName
38      *            string with the package name
39      * @param name
40      *            string with the name for referenced type
41      * @param isNormalized
42      *            indicates if identifier name is normalized
43      */
44     public ReferencedTypeImpl(String packageName, String name, boolean isNormalized, ModuleContext context) {
45         super(packageName, name, isNormalized, context);
46     }
47
48     @Override
49     public String toString() {
50         StringBuilder builder = new StringBuilder();
51         builder.append("ReferencedTypeImpl [packageName=");
52         builder.append(getPackageName());
53         builder.append(", name=");
54         builder.append(getName());
55         builder.append(']');
56         return builder.toString();
57     }
58 }