root / trunk / frameworks / _fwAndami / src / com / iver / andami / plugins / config / generate / ResourceBundleDescriptor.java @ 598
History | View | Annotate | Download (4.78 KB)
1 |
/*
|
---|---|
2 |
* This class was automatically generated with
|
3 |
* <a href="http://www.castor.org">Castor 0.9.5.3</a>, using an XML
|
4 |
* Schema.
|
5 |
* $Id: ResourceBundleDescriptor.java 598 2004-12-22 10:11:38Z fernando $
|
6 |
*/
|
7 |
|
8 |
package com.iver.andami.plugins.config.generate; |
9 |
|
10 |
//---------------------------------/
|
11 |
//- Imported classes and packages -/
|
12 |
//---------------------------------/
|
13 |
|
14 |
import org.exolab.castor.mapping.AccessMode; |
15 |
import org.exolab.castor.xml.TypeValidator; |
16 |
import org.exolab.castor.xml.XMLFieldDescriptor; |
17 |
import org.exolab.castor.xml.validators.*; |
18 |
|
19 |
/**
|
20 |
* Class ResourceBundleDescriptor.
|
21 |
*
|
22 |
* @version $Revision: 598 $ $Date: 2004-12-22 11:11:38 +0100 (Wed, 22 Dec 2004) $
|
23 |
*/
|
24 |
public class ResourceBundleDescriptor extends org.exolab.castor.xml.util.XMLClassDescriptorImpl { |
25 |
|
26 |
|
27 |
//--------------------------/
|
28 |
//- Class/Member Variables -/
|
29 |
//--------------------------/
|
30 |
|
31 |
/**
|
32 |
* Field nsPrefix
|
33 |
*/
|
34 |
private java.lang.String nsPrefix;
|
35 |
|
36 |
/**
|
37 |
* Field nsURI
|
38 |
*/
|
39 |
private java.lang.String nsURI;
|
40 |
|
41 |
/**
|
42 |
* Field xmlName
|
43 |
*/
|
44 |
private java.lang.String xmlName;
|
45 |
|
46 |
/**
|
47 |
* Field identity
|
48 |
*/
|
49 |
private org.exolab.castor.xml.XMLFieldDescriptor identity;
|
50 |
|
51 |
|
52 |
//----------------/
|
53 |
//- Constructors -/
|
54 |
//----------------/
|
55 |
|
56 |
public ResourceBundleDescriptor() {
|
57 |
super();
|
58 |
xmlName = "resourceBundle";
|
59 |
org.exolab.castor.xml.util.XMLFieldDescriptorImpl desc = null;
|
60 |
org.exolab.castor.xml.XMLFieldHandler handler = null;
|
61 |
org.exolab.castor.xml.FieldValidator fieldValidator = null;
|
62 |
//-- initialize attribute descriptors
|
63 |
|
64 |
//-- _name
|
65 |
desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(java.lang.String.class, "_name", "name", org.exolab.castor.xml.NodeType.Attribute); |
66 |
handler = (new org.exolab.castor.xml.XMLFieldHandler() {
|
67 |
public java.lang.Object getValue( java.lang.Object object )
|
68 |
throws IllegalStateException |
69 |
{ |
70 |
ResourceBundle target = (ResourceBundle) object; |
71 |
return target.getName();
|
72 |
} |
73 |
public void setValue( java.lang.Object object, java.lang.Object value) |
74 |
throws IllegalStateException, IllegalArgumentException |
75 |
{ |
76 |
try {
|
77 |
ResourceBundle target = (ResourceBundle) object; |
78 |
target.setName( (java.lang.String) value); |
79 |
} |
80 |
catch (java.lang.Exception ex) {
|
81 |
throw new IllegalStateException(ex.toString()); |
82 |
} |
83 |
} |
84 |
public java.lang.Object newInstance( java.lang.Object parent ) {
|
85 |
return new java.lang.String(); |
86 |
} |
87 |
} ); |
88 |
desc.setHandler(handler); |
89 |
desc.setRequired(true);
|
90 |
addFieldDescriptor(desc); |
91 |
|
92 |
//-- validation code for: _name
|
93 |
fieldValidator = new org.exolab.castor.xml.FieldValidator();
|
94 |
fieldValidator.setMinOccurs(1);
|
95 |
{ //-- local scope
|
96 |
NameValidator typeValidator = new NameValidator(NameValidator.NMTOKEN);
|
97 |
fieldValidator.setValidator(typeValidator); |
98 |
} |
99 |
desc.setValidator(fieldValidator); |
100 |
//-- initialize element descriptors
|
101 |
|
102 |
} //-- com.iver.andami.plugins.config.generate.ResourceBundleDescriptor()
|
103 |
|
104 |
|
105 |
//-----------/
|
106 |
//- Methods -/
|
107 |
//-----------/
|
108 |
|
109 |
/**
|
110 |
* Method getAccessMode
|
111 |
*/
|
112 |
public org.exolab.castor.mapping.AccessMode getAccessMode()
|
113 |
{ |
114 |
return null; |
115 |
} //-- org.exolab.castor.mapping.AccessMode getAccessMode()
|
116 |
|
117 |
/**
|
118 |
* Method getExtends
|
119 |
*/
|
120 |
public org.exolab.castor.mapping.ClassDescriptor getExtends()
|
121 |
{ |
122 |
return null; |
123 |
} //-- org.exolab.castor.mapping.ClassDescriptor getExtends()
|
124 |
|
125 |
/**
|
126 |
* Method getIdentity
|
127 |
*/
|
128 |
public org.exolab.castor.mapping.FieldDescriptor getIdentity()
|
129 |
{ |
130 |
return identity;
|
131 |
} //-- org.exolab.castor.mapping.FieldDescriptor getIdentity()
|
132 |
|
133 |
/**
|
134 |
* Method getJavaClass
|
135 |
*/
|
136 |
public java.lang.Class getJavaClass()
|
137 |
{ |
138 |
return com.iver.andami.plugins.config.generate.ResourceBundle.class;
|
139 |
} //-- java.lang.Class getJavaClass()
|
140 |
|
141 |
/**
|
142 |
* Method getNameSpacePrefix
|
143 |
*/
|
144 |
public java.lang.String getNameSpacePrefix()
|
145 |
{ |
146 |
return nsPrefix;
|
147 |
} //-- java.lang.String getNameSpacePrefix()
|
148 |
|
149 |
/**
|
150 |
* Method getNameSpaceURI
|
151 |
*/
|
152 |
public java.lang.String getNameSpaceURI()
|
153 |
{ |
154 |
return nsURI;
|
155 |
} //-- java.lang.String getNameSpaceURI()
|
156 |
|
157 |
/**
|
158 |
* Method getValidator
|
159 |
*/
|
160 |
public org.exolab.castor.xml.TypeValidator getValidator()
|
161 |
{ |
162 |
return this; |
163 |
} //-- org.exolab.castor.xml.TypeValidator getValidator()
|
164 |
|
165 |
/**
|
166 |
* Method getXMLName
|
167 |
*/
|
168 |
public java.lang.String getXMLName()
|
169 |
{ |
170 |
return xmlName;
|
171 |
} //-- java.lang.String getXMLName()
|
172 |
|
173 |
} |