{
@Override
public java.lang.Object getValue(java.lang.Object object)
throws IllegalStateException
{
Class target = (Class) object;
return target.getContent();
}
@Override
public void setValue(java.lang.Object object, java.lang.Object value)
throws IllegalStateException, IllegalArgumentException
{
try
{
Class target = (Class) object;
target.setContent((java.lang.String) value);
}
catch (java.lang.Exception ex)
{
throw new IllegalStateException(ex.toString());
}
}
@Override
public java.lang.Object newInstance(java.lang.Object parent)
{
return null;
}
};
desc.setSchemaType("string");
desc.setHandler(handler);
addFieldDescriptor(desc);
//-- validation code for: _content
fieldValidator = new org.exolab.castor.xml.FieldValidator();
{ //-- local scope
org.exolab.castor.xml.validators.StringValidator typeValidator;
typeValidator = new org.exolab.castor.xml.validators.StringValidator();
fieldValidator.setValidator(typeValidator);
typeValidator.setWhiteSpace("preserve");
}
desc.setValidator(fieldValidator);
//-- initialize attribute descriptors
//-- _name
desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
java.lang.String.class, "_name", "name",
org.exolab.castor.xml.NodeType.Attribute);
desc.setImmutable(true);
handler = new org.exolab.castor.xml.XMLFieldHandler()
{
@Override
public java.lang.Object getValue(java.lang.Object object)
throws IllegalStateException
{
Class target = (Class) object;
return target.getName();
}
@Override
public void setValue(java.lang.Object object, java.lang.Object value)
throws IllegalStateException, IllegalArgumentException
{
try
{
Class target = (Class) object;
target.setName((java.lang.String) value);
}
catch (java.lang.Exception ex)
{
throw new IllegalStateException(ex.toString());
}
}
@Override
public java.lang.Object newInstance(java.lang.Object parent)
{
return null;
}
};
desc.setSchemaType("string");
desc.setHandler(handler);
desc.setRequired(true);
desc.setMultivalued(false);
addFieldDescriptor(desc);
//-- validation code for: _name
fieldValidator = new org.exolab.castor.xml.FieldValidator();
fieldValidator.setMinOccurs(1);
{ //-- local scope
org.exolab.castor.xml.validators.StringValidator typeValidator;
typeValidator = new org.exolab.castor.xml.validators.StringValidator();
fieldValidator.setValidator(typeValidator);
typeValidator.setWhiteSpace("preserve");
}
desc.setValidator(fieldValidator);
//-- _action
desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
org.xrace.desjardins.trx.types.ClassActionType.class,
"_action", "action", org.exolab.castor.xml.NodeType.Attribute);
handler = new org.exolab.castor.xml.XMLFieldHandler()
{
@Override
public java.lang.Object getValue(java.lang.Object object)
throws IllegalStateException
{
Class target = (Class) object;
return target.getAction();
}
@Override
public void setValue(java.lang.Object object, java.lang.Object value)
throws IllegalStateException, IllegalArgumentException
{
try
{
Class target = (Class) object;
target
.setAction((org.xrace.desjardins.trx.types.ClassActionType) value);
}
catch (java.lang.Exception ex)
{
throw new IllegalStateException(ex.toString());
}
}
@Override
public java.lang.Object newInstance(java.lang.Object parent)
{
return null;
}
};
handler = new org.exolab.castor.xml.handlers.EnumFieldHandler(
org.xrace.desjardins.trx.types.ClassActionType.class, handler);
desc.setImmutable(true);
desc.setSchemaType("ClassActionType");
desc.setHandler(handler);
desc.setMultivalued(false);
addFieldDescriptor(desc);
//-- validation code for: _action
fieldValidator = new org.exolab.castor.xml.FieldValidator();
{ //-- local scope
}
desc.setValidator(fieldValidator);
//-- _key
desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(
java.lang.String.class, "_key", "key",
org.exolab.castor.xml.NodeType.Attribute);
desc.setImmutable(true);
handler = new org.exolab.castor.xml.XMLFieldHandler()
{
@Override
public java.lang.Object getValue(java.lang.Object object)
throws IllegalStateException
{
Class target = (Class) object;
return target.getKey();
}
@Override
public void setValue(java.lang.Object object, java.lang.Object value)
throws IllegalStateException, IllegalArgumentException
{
try
{
Class target = (Class) object;
target.setKey((java.lang.String) value);
}
catch (java.lang.Exception ex)
{
throw new IllegalStateException(ex.toString());
}