2 * Copyright (c) 2013 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.controller.config.yangjmxgenerator.plugin.ftl.model;
10 import com.google.common.collect.Lists;
12 import java.util.List;
15 private final String type;
16 private final String name;
17 private final String definition;
18 private final List<String> modifiers;
20 public Field(String type, String name) {
21 this(Lists.<String> newArrayList(), type, name, null);
24 public Field(String type, String name, String definition) {
25 this(Lists.<String> newArrayList(), type, name, definition);
28 public Field(List<String> modifiers, String type, String name) {
29 this(modifiers, type, name, null);
32 public Field(List<String> modifiers, String type, String name,
34 this.modifiers = modifiers;
37 this.definition = definition;
40 public String getType() {
44 public List<String> getModifiers() {
48 public String getName() {
52 public String getDefinition() {
56 public boolean isArray() {
57 return type.endsWith("[]");