From 1b1113ce93b37e8371fcc893be4d56118e88c63c Mon Sep 17 00:00:00 2001 From: jprocter Date: Thu, 8 Jan 2009 16:00:17 +0000 Subject: [PATCH] structure ids are not IDs, but simply references --- .../version2/descriptors/StructureStateDescriptor.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/jalview/schemabinding/version2/descriptors/StructureStateDescriptor.java b/src/jalview/schemabinding/version2/descriptors/StructureStateDescriptor.java index a52e81d..a904165 100644 --- a/src/jalview/schemabinding/version2/descriptors/StructureStateDescriptor.java +++ b/src/jalview/schemabinding/version2/descriptors/StructureStateDescriptor.java @@ -311,7 +311,7 @@ public class StructureStateDescriptor extends org.exolab.castor.xml.util.XMLClas desc.setValidator(fieldValidator); //-- _viewId desc = new org.exolab.castor.xml.util.XMLFieldDescriptorImpl(java.lang.String.class, "_viewId", "viewId", org.exolab.castor.xml.NodeType.Attribute); - super.setIdentity(desc); + desc.setImmutable(true); handler = new org.exolab.castor.xml.XMLFieldHandler() { public java.lang.Object getValue( java.lang.Object object ) throws IllegalStateException @@ -330,7 +330,7 @@ public class StructureStateDescriptor extends org.exolab.castor.xml.util.XMLClas } } public java.lang.Object newInstance(java.lang.Object parent) { - return new java.lang.String(); + return null; } }; desc.setHandler(handler); @@ -340,9 +340,10 @@ public class StructureStateDescriptor extends org.exolab.castor.xml.util.XMLClas //-- validation code for: _viewId fieldValidator = new org.exolab.castor.xml.FieldValidator(); { //-- local scope - org.exolab.castor.xml.validators.IdValidator typeValidator; - typeValidator = new org.exolab.castor.xml.validators.IdValidator(); + 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 element descriptors -- 1.7.10.2