KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > jboss > xb > binding > sunday > unmarshalling > TermBinding


1 /*
2   * JBoss, Home of Professional Open Source
3   * Copyright 2005, JBoss Inc., and individual contributors as indicated
4   * by the @authors tag. See the copyright.txt in the distribution for a
5   * full listing of individual contributors.
6   *
7   * This is free software; you can redistribute it and/or modify it
8   * under the terms of the GNU Lesser General Public License as
9   * published by the Free Software Foundation; either version 2.1 of
10   * the License, or (at your option) any later version.
11   *
12   * This software is distributed in the hope that it will be useful,
13   * but WITHOUT ANY WARRANTY; without even the implied warranty of
14   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15   * Lesser General Public License for more details.
16   *
17   * You should have received a copy of the GNU Lesser General Public
18   * License along with this software; if not, write to the Free
19   * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
20   * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
21   */

22 package org.jboss.xb.binding.sunday.unmarshalling;
23
24 import org.jboss.xb.binding.metadata.ClassMetaData;
25 import org.jboss.xb.binding.metadata.PropertyMetaData;
26 import org.jboss.xb.binding.metadata.MapEntryMetaData;
27 import org.jboss.xb.binding.metadata.PutMethodMetaData;
28 import org.jboss.xb.binding.metadata.AddMethodMetaData;
29 import org.jboss.xb.binding.metadata.ValueMetaData;
30 import org.jboss.xb.binding.sunday.marshalling.TermBeforeMarshallingCallback;
31
32 /**
33  * @author <a HREF="mailto:alex@jboss.org">Alexey Loubyansky</a>
34  * @version <tt>$Revision: 2139 $</tt>
35  */

36 public abstract class TermBinding
37 {
38    protected SchemaBinding schema;
39
40    protected ClassMetaData classMetaData;
41    protected PropertyMetaData propertyMetaData;
42    protected MapEntryMetaData mapEntryMetaData;
43    protected PutMethodMetaData putMethodMetaData;
44    protected AddMethodMetaData addMethodMetaData;
45    protected ValueMetaData valueMetaData;
46    protected boolean mapEntryKey;
47    protected boolean mapEntryValue;
48    protected Boolean JavaDoc skip;
49    protected ValueAdapter valueAdapter;
50    protected TermBeforeMarshallingCallback beforeMarshallingCallback;
51    protected TermBeforeSetParentCallback beforeSetParentCallback;
52
53    protected TermBinding(SchemaBinding schema)
54    {
55       this.schema = schema;
56    }
57
58    protected TermBinding()
59    {
60    }
61    
62    public ClassMetaData getClassMetaData()
63    {
64       return classMetaData;
65    }
66
67    public void setClassMetaData(ClassMetaData classMetaData)
68    {
69       this.classMetaData = classMetaData;
70    }
71
72    public PropertyMetaData getPropertyMetaData()
73    {
74       return propertyMetaData;
75    }
76
77    public void setPropertyMetaData(PropertyMetaData propertyMetaData)
78    {
79       this.propertyMetaData = propertyMetaData;
80    }
81
82    public MapEntryMetaData getMapEntryMetaData()
83    {
84       return mapEntryMetaData;
85    }
86
87    public void setMapEntryMetaData(MapEntryMetaData mapEntryMetaData)
88    {
89       this.mapEntryMetaData = mapEntryMetaData;
90    }
91
92    public PutMethodMetaData getPutMethodMetaData()
93    {
94       return putMethodMetaData;
95    }
96
97    public void setPutMethodMetaData(PutMethodMetaData putMethodMetaData)
98    {
99       this.putMethodMetaData = putMethodMetaData;
100    }
101
102    public AddMethodMetaData getAddMethodMetaData()
103    {
104       return addMethodMetaData;
105    }
106
107    public void setAddMethodMetaData(AddMethodMetaData addMethodMetaData)
108    {
109       this.addMethodMetaData = addMethodMetaData;
110    }
111
112    public ValueMetaData getValueMetaData()
113    {
114       return valueMetaData;
115    }
116
117    public void setValueMetaData(ValueMetaData valueMetaData)
118    {
119       this.valueMetaData = valueMetaData;
120    }
121
122    public boolean isMapEntryKey()
123    {
124       return mapEntryKey;
125    }
126
127    public void setMapEntryKey(boolean mapEntryKey)
128    {
129       this.mapEntryKey = mapEntryKey;
130    }
131
132    public boolean isMapEntryValue()
133    {
134       return mapEntryValue;
135    }
136
137    public void setMapEntryValue(boolean mapEntryValue)
138    {
139       this.mapEntryValue = mapEntryValue;
140    }
141
142    public abstract boolean isSkip();
143
144    public void setSkip(Boolean JavaDoc skip)
145    {
146       this.skip = skip;
147    }
148
149    public ValueAdapter getValueAdapter()
150    {
151       return valueAdapter;
152    }
153
154    public void setValueAdapter(ValueAdapter valueAdapter)
155    {
156       this.valueAdapter = valueAdapter;
157    }
158
159    public SchemaBinding getSchema()
160    {
161       return schema;
162    }
163
164    public abstract boolean isModelGroup();
165
166    public abstract boolean isWildcard();
167
168    public abstract boolean isElement();
169
170    public void setBeforeMarshallingCallback(TermBeforeMarshallingCallback marshallingHandler)
171    {
172       this.beforeMarshallingCallback = marshallingHandler;
173    }
174
175    public TermBeforeMarshallingCallback getBeforeMarshallingCallback()
176    {
177       return beforeMarshallingCallback;
178    }
179
180    public void setBeforeSetParentCallback(TermBeforeSetParentCallback beforeSetParent)
181    {
182       this.beforeSetParentCallback = beforeSetParent;
183    }
184
185    public TermBeforeSetParentCallback getBeforeSetParentCallback()
186    {
187       return beforeSetParentCallback;
188    }
189 }
190
Popular Tags