fieldValidator.setValidator(typeValidator);\r
}\r
desc.setValidator(fieldValidator);\r
+ //-- _sequenceRef\r
+ desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(java.lang.String.class, "_sequenceRef", "sequenceRef", org.exolab.castor.xml.NodeType.Attribute);\r
+ desc.setImmutable(true);\r
+ handler = (new org.exolab.castor.xml.XMLFieldHandler() {\r
+ public java.lang.Object getValue( java.lang.Object object ) \r
+ throws IllegalStateException\r
+ {\r
+ Annotation target = (Annotation) object;\r
+ return target.getSequenceRef();\r
+ }\r
+ public void setValue( java.lang.Object object, java.lang.Object value) \r
+ throws IllegalStateException, IllegalArgumentException\r
+ {\r
+ try {\r
+ Annotation target = (Annotation) object;\r
+ target.setSequenceRef( (java.lang.String) value);\r
+ }\r
+ catch (java.lang.Exception ex) {\r
+ throw new IllegalStateException(ex.toString());\r
+ }\r
+ }\r
+ public java.lang.Object newInstance( java.lang.Object parent ) {\r
+ return null;\r
+ }\r
+ } );\r
+ desc.setHandler(handler);\r
+ addFieldDescriptor(desc);\r
+ \r
+ //-- validation code for: _sequenceRef\r
+ fieldValidator = new org.exolab.castor.xml.FieldValidator();\r
+ { //-- local scope\r
+ StringValidator typeValidator = new StringValidator();\r
+ typeValidator.setWhiteSpace("preserve");\r
+ fieldValidator.setValidator(typeValidator);\r
+ }\r
+ desc.setValidator(fieldValidator);\r
+ //-- _graphColour\r
+ desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(java.lang.Integer.TYPE, "_graphColour", "graphColour", org.exolab.castor.xml.NodeType.Attribute);\r
+ handler = (new org.exolab.castor.xml.XMLFieldHandler() {\r
+ public java.lang.Object getValue( java.lang.Object object ) \r
+ throws IllegalStateException\r
+ {\r
+ Annotation target = (Annotation) object;\r
+ if(!target.hasGraphColour())\r
+ return null;\r
+ return new java.lang.Integer(target.getGraphColour());\r
+ }\r
+ public void setValue( java.lang.Object object, java.lang.Object value) \r
+ throws IllegalStateException, IllegalArgumentException\r
+ {\r
+ try {\r
+ Annotation target = (Annotation) object;\r
+ // if null, use delete method for optional primitives \r
+ if (value == null) {\r
+ target.deleteGraphColour();\r
+ return;\r
+ }\r
+ target.setGraphColour( ((java.lang.Integer)value).intValue());\r
+ }\r
+ catch (java.lang.Exception ex) {\r
+ throw new IllegalStateException(ex.toString());\r
+ }\r
+ }\r
+ public java.lang.Object newInstance( java.lang.Object parent ) {\r
+ return null;\r
+ }\r
+ } );\r
+ desc.setHandler(handler);\r
+ addFieldDescriptor(desc);\r
+ \r
+ //-- validation code for: _graphColour\r
+ fieldValidator = new org.exolab.castor.xml.FieldValidator();\r
+ { //-- local scope\r
+ IntegerValidator typeValidator= new IntegerValidator();\r
+ fieldValidator.setValidator(typeValidator);\r
+ }\r
+ desc.setValidator(fieldValidator);\r
+ //-- _graphGroup\r
+ desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(java.lang.Integer.TYPE, "_graphGroup", "graphGroup", org.exolab.castor.xml.NodeType.Attribute);\r
+ handler = (new org.exolab.castor.xml.XMLFieldHandler() {\r
+ public java.lang.Object getValue( java.lang.Object object ) \r
+ throws IllegalStateException\r
+ {\r
+ Annotation target = (Annotation) object;\r
+ if(!target.hasGraphGroup())\r
+ return null;\r
+ return new java.lang.Integer(target.getGraphGroup());\r
+ }\r
+ public void setValue( java.lang.Object object, java.lang.Object value) \r
+ throws IllegalStateException, IllegalArgumentException\r
+ {\r
+ try {\r
+ Annotation target = (Annotation) object;\r
+ // if null, use delete method for optional primitives \r
+ if (value == null) {\r
+ target.deleteGraphGroup();\r
+ return;\r
+ }\r
+ target.setGraphGroup( ((java.lang.Integer)value).intValue());\r
+ }\r
+ catch (java.lang.Exception ex) {\r
+ throw new IllegalStateException(ex.toString());\r
+ }\r
+ }\r
+ public java.lang.Object newInstance( java.lang.Object parent ) {\r
+ return null;\r
+ }\r
+ } );\r
+ desc.setHandler(handler);\r
+ addFieldDescriptor(desc);\r
+ \r
+ //-- validation code for: _graphGroup\r
+ fieldValidator = new org.exolab.castor.xml.FieldValidator();\r
+ { //-- local scope\r
+ IntegerValidator typeValidator= new IntegerValidator();\r
+ fieldValidator.setValidator(typeValidator);\r
+ }\r
+ desc.setValidator(fieldValidator);\r
//-- initialize element descriptors\r
\r
//-- _annotationElementList\r
} );\r
desc.setHandler(handler);\r
desc.setNameSpaceURI("www.vamsas.ac.uk/jalview/version2");\r
- desc.setRequired(true);\r
desc.setMultivalued(true);\r
addFieldDescriptor(desc);\r
\r
//-- validation code for: _annotationElementList\r
fieldValidator = new org.exolab.castor.xml.FieldValidator();\r
- fieldValidator.setMinOccurs(1);\r
+ fieldValidator.setMinOccurs(0);\r
{ //-- local scope\r
}\r
desc.setValidator(fieldValidator);\r
} );\r
desc.setHandler(handler);\r
desc.setNameSpaceURI("www.vamsas.ac.uk/jalview/version2");\r
- desc.setRequired(true);\r
desc.setMultivalued(false);\r
addFieldDescriptor(desc);\r
\r
//-- validation code for: _description\r
fieldValidator = new org.exolab.castor.xml.FieldValidator();\r
- fieldValidator.setMinOccurs(1);\r
{ //-- local scope\r
StringValidator typeValidator = new StringValidator();\r
typeValidator.setWhiteSpace("preserve");\r