001 /*
002 * JBoss DNA (http://www.jboss.org/dna)
003 * See the COPYRIGHT.txt file distributed with this work for information
004 * regarding copyright ownership. Some portions may be licensed
005 * to Red Hat, Inc. under one or more contributor license agreements.
006 * See the AUTHORS.txt file in the distribution for a full listing of
007 * individual contributors.
008 *
009 * JBoss DNA is free software. Unless otherwise indicated, all code in JBoss DNA
010 * is licensed to you under the terms of the GNU Lesser General Public License as
011 * published by the Free Software Foundation; either version 2.1 of
012 * the License, or (at your option) any later version.
013 *
014 * JBoss DNA is distributed in the hope that it will be useful,
015 * but WITHOUT ANY WARRANTY; without even the implied warranty of
016 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
017 * Lesser General Public License for more details.
018 *
019 * You should have received a copy of the GNU Lesser General Public
020 * License along with this software; if not, write to the Free
021 * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
022 * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
023 */
024 package org.jboss.dna.sequencer.java.metadata;
025
026 import java.util.ArrayList;
027 import java.util.List;
028
029 /**
030 * FieldMetadata is the base class of all fields.
031 *
032 * @author Serge Pagop
033 */
034 public class FieldMetadata {
035
036 /** The type of the field */
037 private String type;
038
039 /** The variables */
040 private List<Variable> variables = new ArrayList<Variable>();
041
042 private List<ModifierMetadata> modifierMetadatas = new ArrayList<ModifierMetadata>();
043
044 /**
045 * @return variables
046 */
047 public List<Variable> getVariables() {
048 return variables;
049 }
050
051 /**
052 * @param variables Sets variables to the specified value.
053 */
054 public void setVariables( List<Variable> variables ) {
055 this.variables = variables;
056 }
057
058 /**
059 * @return type
060 */
061 public String getType() {
062 return type;
063 }
064
065 /**
066 * @param type Sets type to the specified value.
067 */
068 public void setType( String type ) {
069 this.type = type;
070 }
071
072 /**
073 * @return modifierMetadatas
074 */
075 public List<ModifierMetadata> getModifiers() {
076 return modifierMetadatas;
077 }
078
079 /**
080 * @param modifierMetadatas Sets modifierMetadatas to the specified value.
081 */
082 public void setModifiers( List<ModifierMetadata> modifierMetadatas ) {
083 this.modifierMetadatas = modifierMetadatas;
084 }
085
086 /**
087 * Find out if a field is primitive type or not.
088 *
089 * @return true if field is a primitive type.
090 */
091 public boolean isPrimitiveType() {
092 return false;
093 }
094
095 /**
096 * Find out if a field is a simple type or not.
097 *
098 * @return true if field is a simple type.
099 */
100 public boolean isSimpleType() {
101 return false;
102 }
103
104 /**
105 * Find out if a field is a array type or not.
106 *
107 * @return true if field is a array type.
108 */
109 public boolean isArrayType() {
110 return false;
111 }
112
113 /**
114 * Find out if a field is a qualified type or not.
115 *
116 * @return true if field is a qualified type.
117 */
118 public boolean isQualifiedType() {
119 return false;
120 }
121
122 /**
123 * Find out if a field is a parameterized type or not.
124 *
125 * @return true if field is a parameterized type.
126 */
127 public boolean isParameterizedType() {
128 return false;
129 }
130
131 /**
132 * Find out if a field is a wild card type or not.
133 *
134 * @return true if field is a wild card type.
135 */
136 public boolean isWildcardType() {
137 return false;
138 }
139 }