geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r677108 [2/3] - in /geronimo/components/jaspi/trunk/geronimo-jaspi: ./ src/main/java/org/apache/geronimo/components/jaspi/model/ src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ src/main/xsd/
Date Tue, 15 Jul 2008 23:46:51 GMT
Added: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ClientAuthContextTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ClientAuthContextTypeJAXB.java?rev=677108&view=auto
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ClientAuthContextTypeJAXB.java (added)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ClientAuthContextTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -0,0 +1,188 @@
+
+package sxc.org.apache.geronimo.components.jaspi.model;
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import com.envoisolutions.sxc.jaxb.FieldAccessor;
+import com.envoisolutions.sxc.jaxb.JAXBObject;
+import com.envoisolutions.sxc.jaxb.LifecycleCallback;
+import com.envoisolutions.sxc.jaxb.RuntimeContext;
+import com.envoisolutions.sxc.util.Attribute;
+import com.envoisolutions.sxc.util.XoXMLStreamReader;
+import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.AuthModuleType;
+import org.apache.geronimo.components.jaspi.model.ClientAuthContextType;
+
+
+import static sxc.org.apache.geronimo.components.jaspi.model.AuthModuleTypeJAXB.readAuthModuleType;
+import static sxc.org.apache.geronimo.components.jaspi.model.AuthModuleTypeJAXB.writeAuthModuleType;
+
+@SuppressWarnings({
+    "StringEquality"
+})
+public class ClientAuthContextTypeJAXB
+    extends JAXBObject<ClientAuthContextType>
+{
+
+    public final static ClientAuthContextTypeJAXB INSTANCE = new ClientAuthContextTypeJAXB();
+    private final static LifecycleCallback lifecycleCallback = new LifecycleCallback(ClientAuthContextType.class);
+    private final static FieldAccessor<ClientAuthContextType, String> clientAuthContextTypeMessageLayer = new FieldAccessor<ClientAuthContextType, String>(ClientAuthContextType.class, "messageLayer");
+    private final static FieldAccessor<ClientAuthContextType, String> clientAuthContextTypeAppContext = new FieldAccessor<ClientAuthContextType, String>(ClientAuthContextType.class, "appContext");
+    private final static FieldAccessor<ClientAuthContextType, String> clientAuthContextTypeAuthenticationContextID = new FieldAccessor<ClientAuthContextType, String>(ClientAuthContextType.class, "authenticationContextID");
+    private final static FieldAccessor<ClientAuthContextType, List<AuthModuleType>> clientAuthContextTypeClientAuthModule = new FieldAccessor<ClientAuthContextType, List<AuthModuleType>>(ClientAuthContextType.class, "clientAuthModule");
+
+    public ClientAuthContextTypeJAXB() {
+        super(ClientAuthContextType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "clientAuthContextType".intern()), AuthModuleTypeJAXB.class);
+    }
+
+    public static ClientAuthContextType readClientAuthContextType(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+        return INSTANCE.read(reader, context);
+    }
+
+    public static void writeClientAuthContextType(XoXMLStreamWriter writer, ClientAuthContextType clientAuthContextType, RuntimeContext context)
+        throws Exception
+    {
+        INSTANCE.write(writer, clientAuthContextType, context);
+    }
+
+    public final ClientAuthContextType read(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+
+        // Check for xsi:nil
+        if (reader.isXsiNil()) {
+            return null;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        ClientAuthContextType clientAuthContextType = new ClientAuthContextType();
+        context.beforeUnmarshal(clientAuthContextType, lifecycleCallback);
+
+        List<AuthModuleType> clientAuthModule = null;
+
+        // Check xsi:type
+        QName xsiType = reader.getXsiType();
+        if (xsiType!= null) {
+            if (("clientAuthContextType"!= xsiType.getLocalPart())||("http://geronimo.apache.org/xml/ns/geronimo-jaspi"!= xsiType.getNamespaceURI())) {
+                return context.unexpectedXsiType(reader, ClientAuthContextType.class);
+            }
+        }
+
+        // Read attributes
+        for (Attribute attribute: reader.getAttributes()) {
+            if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI!= attribute.getNamespace()) {
+                context.unexpectedAttribute(attribute);
+            }
+        }
+
+        // Read elements
+        for (XoXMLStreamReader elementReader: reader.getChildElements()) {
+            if (("messageLayer" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: messageLayer
+                String messageLayer = elementReader.getElementAsString();
+                clientAuthContextTypeMessageLayer.setObject(reader, context, clientAuthContextType, messageLayer);
+            } else if (("appContext" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: appContext
+                String appContext = elementReader.getElementAsString();
+                clientAuthContextTypeAppContext.setObject(reader, context, clientAuthContextType, appContext);
+            } else if (("authenticationContextID" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: authenticationContextID
+                String authenticationContextID = elementReader.getElementAsString();
+                clientAuthContextTypeAuthenticationContextID.setObject(reader, context, clientAuthContextType, authenticationContextID);
+            } else if (("clientAuthModule" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: clientAuthModule
+                AuthModuleType clientAuthModuleItem = readAuthModuleType(elementReader, context);
+                if (clientAuthModule == null) {
+                    clientAuthModule = clientAuthContextTypeClientAuthModule.getObject(reader, context, clientAuthContextType);
+                    if (clientAuthModule!= null) {
+                        clientAuthModule.clear();
+                    } else {
+                        clientAuthModule = new ArrayList<AuthModuleType>();
+                    }
+                }
+                clientAuthModule.add(clientAuthModuleItem);
+            } else {
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "messageLayer"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "appContext"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "authenticationContextID"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "clientAuthModule"));
+            }
+        }
+        if (clientAuthModule!= null) {
+            clientAuthContextTypeClientAuthModule.setObject(reader, context, clientAuthContextType, clientAuthModule);
+        }
+
+        context.afterUnmarshal(clientAuthContextType, lifecycleCallback);
+
+        return clientAuthContextType;
+    }
+
+    public final void write(XoXMLStreamWriter writer, ClientAuthContextType clientAuthContextType, RuntimeContext context)
+        throws Exception
+    {
+        if (clientAuthContextType == null) {
+            writer.writeXsiNil();
+            return ;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        String prefix = writer.getUniquePrefix("http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+        if (ClientAuthContextType.class!= clientAuthContextType.getClass()) {
+            context.unexpectedSubclass(writer, clientAuthContextType, ClientAuthContextType.class);
+            return ;
+        }
+
+        context.beforeMarshal(clientAuthContextType, lifecycleCallback);
+
+
+        // ELEMENT: messageLayer
+        String messageLayer = clientAuthContextTypeMessageLayer.getObject(clientAuthContextType, context, clientAuthContextType);
+        if (messageLayer!= null) {
+            writer.writeStartElement(prefix, "messageLayer", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(messageLayer);
+            writer.writeEndElement();
+        }
+
+        // ELEMENT: appContext
+        String appContext = clientAuthContextTypeAppContext.getObject(clientAuthContextType, context, clientAuthContextType);
+        if (appContext!= null) {
+            writer.writeStartElement(prefix, "appContext", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(appContext);
+            writer.writeEndElement();
+        }
+
+        // ELEMENT: authenticationContextID
+        String authenticationContextID = clientAuthContextTypeAuthenticationContextID.getObject(clientAuthContextType, context, clientAuthContextType);
+        if (authenticationContextID!= null) {
+            writer.writeStartElement(prefix, "authenticationContextID", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(authenticationContextID);
+            writer.writeEndElement();
+        } else {
+            context.unexpectedNullValue(clientAuthContextType, "authenticationContextID");
+        }
+
+        // ELEMENT: clientAuthModule
+        List<AuthModuleType> clientAuthModule = clientAuthContextTypeClientAuthModule.getObject(clientAuthContextType, context, clientAuthContextType);
+        if (clientAuthModule!= null) {
+            for (AuthModuleType clientAuthModuleItem: clientAuthModule) {
+                writer.writeStartElement(prefix, "clientAuthModule", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+                if (clientAuthModuleItem!= null) {
+                    writeAuthModuleType(writer, clientAuthModuleItem, context);
+                } else {
+                    writer.writeXsiNil();
+                }
+                writer.writeEndElement();
+            }
+        }
+
+        context.afterMarshal(clientAuthContextType, lifecycleCallback);
+    }
+
+}

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ClientAuthContextTypeJAXB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ClientAuthContextTypeJAXB.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ClientAuthContextTypeJAXB.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ConfigProviderTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ConfigProviderTypeJAXB.java?rev=677108&r1=677107&r2=677108&view=diff
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ConfigProviderTypeJAXB.java (original)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ConfigProviderTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -1,6 +1,8 @@
 
 package sxc.org.apache.geronimo.components.jaspi.model;
 
+import java.util.ArrayList;
+import java.util.List;
 import java.util.Map;
 import javax.xml.XMLConstants;
 import javax.xml.namespace.QName;
@@ -11,9 +13,17 @@
 import com.envoisolutions.sxc.util.Attribute;
 import com.envoisolutions.sxc.util.XoXMLStreamReader;
 import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.ClientAuthConfigType;
 import org.apache.geronimo.components.jaspi.model.ConfigProviderType;
+import org.apache.geronimo.components.jaspi.model.ServerAuthConfigType;
 import org.apache.geronimo.components.jaspi.model.StringMapAdapter;
 
+
+import static sxc.org.apache.geronimo.components.jaspi.model.ClientAuthConfigTypeJAXB.readClientAuthConfigType;
+import static sxc.org.apache.geronimo.components.jaspi.model.ClientAuthConfigTypeJAXB.writeClientAuthConfigType;
+import static sxc.org.apache.geronimo.components.jaspi.model.ServerAuthConfigTypeJAXB.readServerAuthConfigType;
+import static sxc.org.apache.geronimo.components.jaspi.model.ServerAuthConfigTypeJAXB.writeServerAuthConfigType;
+
 @SuppressWarnings({
     "StringEquality"
 })
@@ -28,12 +38,14 @@
     private final static FieldAccessor<ConfigProviderType, String> configProviderTypeDescription = new FieldAccessor<ConfigProviderType, String>(ConfigProviderType.class, "description");
     private final static FieldAccessor<ConfigProviderType, String> configProviderTypeClassName = new FieldAccessor<ConfigProviderType, String>(ConfigProviderType.class, "className");
     private final static FieldAccessor<ConfigProviderType, Map<String, String>> configProviderTypeProperties = new FieldAccessor<ConfigProviderType, Map<String, String>>(ConfigProviderType.class, "properties");
+    private final static FieldAccessor<ConfigProviderType, List<ClientAuthConfigType>> configProviderTypeClientAuthConfig = new FieldAccessor<ConfigProviderType, List<ClientAuthConfigType>>(ConfigProviderType.class, "clientAuthConfig");
+    private final static FieldAccessor<ConfigProviderType, List<ServerAuthConfigType>> configProviderTypeServerAuthConfig = new FieldAccessor<ConfigProviderType, List<ServerAuthConfigType>>(ConfigProviderType.class, "serverAuthConfig");
     private final static FieldAccessor<ConfigProviderType, Boolean> configProviderTypePersistent = new FieldAccessor<ConfigProviderType, Boolean>(ConfigProviderType.class, "persistent");
     private final static FieldAccessor<ConfigProviderType, String> configProviderTypeClassLoaderName = new FieldAccessor<ConfigProviderType, String>(ConfigProviderType.class, "classLoaderName");
     private final static StringMapAdapter stringMapAdapterAdapter = new StringMapAdapter();
 
     public ConfigProviderTypeJAXB() {
-        super(ConfigProviderType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "configProviderType".intern()));
+        super(ConfigProviderType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "configProviderType".intern()), ClientAuthConfigTypeJAXB.class, ServerAuthConfigTypeJAXB.class);
     }
 
     public static ConfigProviderType readConfigProviderType(XoXMLStreamReader reader, RuntimeContext context)
@@ -64,6 +76,8 @@
         ConfigProviderType configProviderType = new ConfigProviderType();
         context.beforeUnmarshal(configProviderType, lifecycleCallback);
 
+        List<ClientAuthConfigType> clientAuthConfig = null;
+        List<ServerAuthConfigType> serverAuthConfig = null;
 
         // Check xsi:type
         QName xsiType = reader.getXsiType();
@@ -111,18 +125,48 @@
                 }
 
                 configProviderTypeProperties.setObject(reader, context, configProviderType, properties);
+            } else if (("clientAuthConfig" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: clientAuthConfig
+                ClientAuthConfigType clientAuthConfigItem = readClientAuthConfigType(elementReader, context);
+                if (clientAuthConfig == null) {
+                    clientAuthConfig = configProviderTypeClientAuthConfig.getObject(reader, context, configProviderType);
+                    if (clientAuthConfig!= null) {
+                        clientAuthConfig.clear();
+                    } else {
+                        clientAuthConfig = new ArrayList<ClientAuthConfigType>();
+                    }
+                }
+                clientAuthConfig.add(clientAuthConfigItem);
+            } else if (("serverAuthConfig" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: serverAuthConfig
+                ServerAuthConfigType serverAuthConfigItem = readServerAuthConfigType(elementReader, context);
+                if (serverAuthConfig == null) {
+                    serverAuthConfig = configProviderTypeServerAuthConfig.getObject(reader, context, configProviderType);
+                    if (serverAuthConfig!= null) {
+                        serverAuthConfig.clear();
+                    } else {
+                        serverAuthConfig = new ArrayList<ServerAuthConfigType>();
+                    }
+                }
+                serverAuthConfig.add(serverAuthConfigItem);
             } else if (("persistent" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
                 // ELEMENT: persistent
                 Boolean persistent = ("1".equals(elementReader.getElementAsString())||"true".equals(elementReader.getElementAsString()));
-                configProviderTypePersistent.setBoolean(reader, context, configProviderType, persistent);
+                configProviderTypePersistent.setObject(reader, context, configProviderType, persistent);
             } else if (("classLoaderName" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
                 // ELEMENT: classLoaderName
                 String classLoaderName = elementReader.getElementAsString();
                 configProviderTypeClassLoaderName.setObject(reader, context, configProviderType, classLoaderName);
             } else {
-                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "messageLayer"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "appContext"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "description"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "className"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "properties"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "persistent"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "classLoaderName"));
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "messageLayer"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "appContext"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "description"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "className"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "properties"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "clientAuthConfig"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "serverAuthConfig"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "persistent"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "classLoaderName"));
             }
         }
+        if (clientAuthConfig!= null) {
+            configProviderTypeClientAuthConfig.setObject(reader, context, configProviderType, clientAuthConfig);
+        }
+        if (serverAuthConfig!= null) {
+            configProviderTypeServerAuthConfig.setObject(reader, context, configProviderType, serverAuthConfig);
+        }
 
         context.afterUnmarshal(configProviderType, lifecycleCallback);
 
@@ -180,8 +224,6 @@
             writer.writeStartElement(prefix, "className", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
             writer.writeCharacters(className);
             writer.writeEndElement();
-        } else {
-            context.unexpectedNullValue(configProviderType, "className");
         }
 
         // ELEMENT: properties
@@ -200,11 +242,41 @@
             context.unexpectedNullValue(configProviderType, "properties");
         }
 
+        // ELEMENT: clientAuthConfig
+        List<ClientAuthConfigType> clientAuthConfig = configProviderTypeClientAuthConfig.getObject(configProviderType, context, configProviderType);
+        if (clientAuthConfig!= null) {
+            for (ClientAuthConfigType clientAuthConfigItem: clientAuthConfig) {
+                writer.writeStartElement(prefix, "clientAuthConfig", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+                if (clientAuthConfigItem!= null) {
+                    writeClientAuthConfigType(writer, clientAuthConfigItem, context);
+                } else {
+                    writer.writeXsiNil();
+                }
+                writer.writeEndElement();
+            }
+        }
+
+        // ELEMENT: serverAuthConfig
+        List<ServerAuthConfigType> serverAuthConfig = configProviderTypeServerAuthConfig.getObject(configProviderType, context, configProviderType);
+        if (serverAuthConfig!= null) {
+            for (ServerAuthConfigType serverAuthConfigItem: serverAuthConfig) {
+                writer.writeStartElement(prefix, "serverAuthConfig", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+                if (serverAuthConfigItem!= null) {
+                    writeServerAuthConfigType(writer, serverAuthConfigItem, context);
+                } else {
+                    writer.writeXsiNil();
+                }
+                writer.writeEndElement();
+            }
+        }
+
         // ELEMENT: persistent
-        Boolean persistent = configProviderTypePersistent.getBoolean(configProviderType, context, configProviderType);
-        writer.writeStartElement(prefix, "persistent", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
-        writer.writeCharacters(Boolean.toString(persistent));
-        writer.writeEndElement();
+        Boolean persistent = configProviderTypePersistent.getObject(configProviderType, context, configProviderType);
+        if (persistent!= null) {
+            writer.writeStartElement(prefix, "persistent", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(Boolean.toString(persistent));
+            writer.writeEndElement();
+        }
 
         // ELEMENT: classLoaderName
         String classLoaderName = configProviderTypeClassLoaderName.getObject(configProviderType, context, configProviderType);

Added: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/MessagePolicyTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/MessagePolicyTypeJAXB.java?rev=677108&view=auto
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/MessagePolicyTypeJAXB.java (added)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/MessagePolicyTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -0,0 +1,157 @@
+
+package sxc.org.apache.geronimo.components.jaspi.model;
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import com.envoisolutions.sxc.jaxb.FieldAccessor;
+import com.envoisolutions.sxc.jaxb.JAXBObject;
+import com.envoisolutions.sxc.jaxb.LifecycleCallback;
+import com.envoisolutions.sxc.jaxb.RuntimeContext;
+import com.envoisolutions.sxc.util.Attribute;
+import com.envoisolutions.sxc.util.XoXMLStreamReader;
+import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.MessagePolicyType;
+import org.apache.geronimo.components.jaspi.model.TargetPolicyType;
+
+
+import static sxc.org.apache.geronimo.components.jaspi.model.TargetPolicyTypeJAXB.readTargetPolicyType;
+import static sxc.org.apache.geronimo.components.jaspi.model.TargetPolicyTypeJAXB.writeTargetPolicyType;
+
+@SuppressWarnings({
+    "StringEquality"
+})
+public class MessagePolicyTypeJAXB
+    extends JAXBObject<MessagePolicyType>
+{
+
+    public final static MessagePolicyTypeJAXB INSTANCE = new MessagePolicyTypeJAXB();
+    private final static LifecycleCallback lifecycleCallback = new LifecycleCallback(MessagePolicyType.class);
+    private final static FieldAccessor<MessagePolicyType, List<TargetPolicyType>> messagePolicyTypeTargetPolicy = new FieldAccessor<MessagePolicyType, List<TargetPolicyType>>(MessagePolicyType.class, "targetPolicy");
+    private final static FieldAccessor<MessagePolicyType, Boolean> messagePolicyTypeMandatory = new FieldAccessor<MessagePolicyType, Boolean>(MessagePolicyType.class, "mandatory");
+
+    public MessagePolicyTypeJAXB() {
+        super(MessagePolicyType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "messagePolicyType".intern()), TargetPolicyTypeJAXB.class);
+    }
+
+    public static MessagePolicyType readMessagePolicyType(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+        return INSTANCE.read(reader, context);
+    }
+
+    public static void writeMessagePolicyType(XoXMLStreamWriter writer, MessagePolicyType messagePolicyType, RuntimeContext context)
+        throws Exception
+    {
+        INSTANCE.write(writer, messagePolicyType, context);
+    }
+
+    public final MessagePolicyType read(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+
+        // Check for xsi:nil
+        if (reader.isXsiNil()) {
+            return null;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        MessagePolicyType messagePolicyType = new MessagePolicyType();
+        context.beforeUnmarshal(messagePolicyType, lifecycleCallback);
+
+        List<TargetPolicyType> targetPolicy = null;
+
+        // Check xsi:type
+        QName xsiType = reader.getXsiType();
+        if (xsiType!= null) {
+            if (("messagePolicyType"!= xsiType.getLocalPart())||("http://geronimo.apache.org/xml/ns/geronimo-jaspi"!= xsiType.getNamespaceURI())) {
+                return context.unexpectedXsiType(reader, MessagePolicyType.class);
+            }
+        }
+
+        // Read attributes
+        for (Attribute attribute: reader.getAttributes()) {
+            if (("mandatory" == attribute.getLocalName())&&(("" == attribute.getNamespace())||(attribute.getNamespace() == null))) {
+                // ATTRIBUTE: mandatory
+                Boolean mandatory = ("1".equals(attribute.getValue())||"true".equals(attribute.getValue()));
+                messagePolicyTypeMandatory.setObject(reader, context, messagePolicyType, mandatory);
+            } else if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI!= attribute.getNamespace()) {
+                context.unexpectedAttribute(attribute, new QName("", "mandatory"));
+            }
+        }
+
+        // Read elements
+        for (XoXMLStreamReader elementReader: reader.getChildElements()) {
+            if (("targetPolicy" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: targetPolicy
+                TargetPolicyType targetPolicyItem = readTargetPolicyType(elementReader, context);
+                if (targetPolicy == null) {
+                    targetPolicy = messagePolicyTypeTargetPolicy.getObject(reader, context, messagePolicyType);
+                    if (targetPolicy!= null) {
+                        targetPolicy.clear();
+                    } else {
+                        targetPolicy = new ArrayList<TargetPolicyType>();
+                    }
+                }
+                targetPolicy.add(targetPolicyItem);
+            } else {
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "targetPolicy"));
+            }
+        }
+        if (targetPolicy!= null) {
+            messagePolicyTypeTargetPolicy.setObject(reader, context, messagePolicyType, targetPolicy);
+        }
+
+        context.afterUnmarshal(messagePolicyType, lifecycleCallback);
+
+        return messagePolicyType;
+    }
+
+    public final void write(XoXMLStreamWriter writer, MessagePolicyType messagePolicyType, RuntimeContext context)
+        throws Exception
+    {
+        if (messagePolicyType == null) {
+            writer.writeXsiNil();
+            return ;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        if (MessagePolicyType.class!= messagePolicyType.getClass()) {
+            context.unexpectedSubclass(writer, messagePolicyType, MessagePolicyType.class);
+            return ;
+        }
+
+        context.beforeMarshal(messagePolicyType, lifecycleCallback);
+
+
+        // ATTRIBUTE: mandatory
+        Boolean mandatory = messagePolicyTypeMandatory.getObject(messagePolicyType, context, messagePolicyType);
+        if (mandatory!= null) {
+            writer.writeAttribute("", "", "mandatory", Boolean.toString(mandatory));
+        }
+
+        // ELEMENT: targetPolicy
+        List<TargetPolicyType> targetPolicy = messagePolicyTypeTargetPolicy.getObject(messagePolicyType, context, messagePolicyType);
+        if (targetPolicy!= null) {
+            for (TargetPolicyType targetPolicyItem: targetPolicy) {
+                writer.writeStartElementWithAutoPrefix("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "targetPolicy");
+                if (targetPolicyItem!= null) {
+                    writeTargetPolicyType(writer, targetPolicyItem, context);
+                } else {
+                    writer.writeXsiNil();
+                }
+                writer.writeEndElement();
+            }
+        }
+
+        context.afterMarshal(messagePolicyType, lifecycleCallback);
+    }
+
+}

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/MessagePolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/MessagePolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/MessagePolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Modified: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ObjectFactoryJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ObjectFactoryJAXB.java?rev=677108&r1=677107&r2=677108&view=diff
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ObjectFactoryJAXB.java (original)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ObjectFactoryJAXB.java Tue Jul 15 16:46:50 2008
@@ -16,7 +16,7 @@
     private final Map<QName, Class<? extends JAXBObject>> rootElements = new HashMap<QName, Class<? extends JAXBObject>>();
 
     public ObjectFactoryJAXB() {
-        super(ObjectFactory.class, ConfigProviderTypeJAXB.class, JaspiTypeJAXB.class);
+        super(ObjectFactory.class, JaspiTypeJAXB.class, ServerAuthContextTypeJAXB.class, AuthModuleTypeJAXB.class, ServerAuthConfigTypeJAXB.class, TargetTypeJAXB.class, MessagePolicyTypeJAXB.class, ClientAuthContextTypeJAXB.class, ConfigProviderTypeJAXB.class, TargetPolicyTypeJAXB.class, ClientAuthConfigTypeJAXB.class, ProtectionPolicyTypeJAXB.class);
         rootElements.put(new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "jaspi".intern()), JaspiTypeJAXB.class);
     }
 

Added: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ProtectionPolicyTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ProtectionPolicyTypeJAXB.java?rev=677108&view=auto
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ProtectionPolicyTypeJAXB.java (added)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ProtectionPolicyTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -0,0 +1,123 @@
+
+package sxc.org.apache.geronimo.components.jaspi.model;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import com.envoisolutions.sxc.jaxb.FieldAccessor;
+import com.envoisolutions.sxc.jaxb.JAXBObject;
+import com.envoisolutions.sxc.jaxb.LifecycleCallback;
+import com.envoisolutions.sxc.jaxb.RuntimeContext;
+import com.envoisolutions.sxc.util.Attribute;
+import com.envoisolutions.sxc.util.XoXMLStreamReader;
+import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.ProtectionPolicyType;
+
+@SuppressWarnings({
+    "StringEquality"
+})
+public class ProtectionPolicyTypeJAXB
+    extends JAXBObject<ProtectionPolicyType>
+{
+
+    public final static ProtectionPolicyTypeJAXB INSTANCE = new ProtectionPolicyTypeJAXB();
+    private final static LifecycleCallback lifecycleCallback = new LifecycleCallback(ProtectionPolicyType.class);
+    private final static FieldAccessor<ProtectionPolicyType, String> protectionPolicyTypeClassName = new FieldAccessor<ProtectionPolicyType, String>(ProtectionPolicyType.class, "className");
+
+    public ProtectionPolicyTypeJAXB() {
+        super(ProtectionPolicyType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "protectionPolicyType".intern()));
+    }
+
+    public static ProtectionPolicyType readProtectionPolicyType(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+        return INSTANCE.read(reader, context);
+    }
+
+    public static void writeProtectionPolicyType(XoXMLStreamWriter writer, ProtectionPolicyType protectionPolicyType, RuntimeContext context)
+        throws Exception
+    {
+        INSTANCE.write(writer, protectionPolicyType, context);
+    }
+
+    public final ProtectionPolicyType read(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+
+        // Check for xsi:nil
+        if (reader.isXsiNil()) {
+            return null;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        ProtectionPolicyType protectionPolicyType = new ProtectionPolicyType();
+        context.beforeUnmarshal(protectionPolicyType, lifecycleCallback);
+
+
+        // Check xsi:type
+        QName xsiType = reader.getXsiType();
+        if (xsiType!= null) {
+            if (("protectionPolicyType"!= xsiType.getLocalPart())||("http://geronimo.apache.org/xml/ns/geronimo-jaspi"!= xsiType.getNamespaceURI())) {
+                return context.unexpectedXsiType(reader, ProtectionPolicyType.class);
+            }
+        }
+
+        // Read attributes
+        for (Attribute attribute: reader.getAttributes()) {
+            if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI!= attribute.getNamespace()) {
+                context.unexpectedAttribute(attribute);
+            }
+        }
+
+        // Read elements
+        for (XoXMLStreamReader elementReader: reader.getChildElements()) {
+            if (("className" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: className
+                String className = elementReader.getElementAsString();
+                protectionPolicyTypeClassName.setObject(reader, context, protectionPolicyType, className);
+            } else {
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "className"));
+            }
+        }
+
+        context.afterUnmarshal(protectionPolicyType, lifecycleCallback);
+
+        return protectionPolicyType;
+    }
+
+    public final void write(XoXMLStreamWriter writer, ProtectionPolicyType protectionPolicyType, RuntimeContext context)
+        throws Exception
+    {
+        if (protectionPolicyType == null) {
+            writer.writeXsiNil();
+            return ;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        if (ProtectionPolicyType.class!= protectionPolicyType.getClass()) {
+            context.unexpectedSubclass(writer, protectionPolicyType, ProtectionPolicyType.class);
+            return ;
+        }
+
+        context.beforeMarshal(protectionPolicyType, lifecycleCallback);
+
+
+        // ELEMENT: className
+        String className = protectionPolicyTypeClassName.getObject(protectionPolicyType, context, protectionPolicyType);
+        if (className!= null) {
+            writer.writeStartElementWithAutoPrefix("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "className");
+            writer.writeCharacters(className);
+            writer.writeEndElement();
+        } else {
+            context.unexpectedNullValue(protectionPolicyType, "className");
+        }
+
+        context.afterMarshal(protectionPolicyType, lifecycleCallback);
+    }
+
+}

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ProtectionPolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ProtectionPolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ProtectionPolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthConfigTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthConfigTypeJAXB.java?rev=677108&view=auto
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthConfigTypeJAXB.java (added)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthConfigTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -0,0 +1,199 @@
+
+package sxc.org.apache.geronimo.components.jaspi.model;
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import com.envoisolutions.sxc.jaxb.FieldAccessor;
+import com.envoisolutions.sxc.jaxb.JAXBObject;
+import com.envoisolutions.sxc.jaxb.LifecycleCallback;
+import com.envoisolutions.sxc.jaxb.RuntimeContext;
+import com.envoisolutions.sxc.util.Attribute;
+import com.envoisolutions.sxc.util.XoXMLStreamReader;
+import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.ServerAuthConfigType;
+import org.apache.geronimo.components.jaspi.model.ServerAuthContextType;
+
+
+import static sxc.org.apache.geronimo.components.jaspi.model.ServerAuthContextTypeJAXB.readServerAuthContextType;
+import static sxc.org.apache.geronimo.components.jaspi.model.ServerAuthContextTypeJAXB.writeServerAuthContextType;
+
+@SuppressWarnings({
+    "StringEquality"
+})
+public class ServerAuthConfigTypeJAXB
+    extends JAXBObject<ServerAuthConfigType>
+{
+
+    public final static ServerAuthConfigTypeJAXB INSTANCE = new ServerAuthConfigTypeJAXB();
+    private final static LifecycleCallback lifecycleCallback = new LifecycleCallback(ServerAuthConfigType.class);
+    private final static FieldAccessor<ServerAuthConfigType, String> serverAuthConfigTypeMessageLayer = new FieldAccessor<ServerAuthConfigType, String>(ServerAuthConfigType.class, "messageLayer");
+    private final static FieldAccessor<ServerAuthConfigType, String> serverAuthConfigTypeAppContext = new FieldAccessor<ServerAuthConfigType, String>(ServerAuthConfigType.class, "appContext");
+    private final static FieldAccessor<ServerAuthConfigType, String> serverAuthConfigTypeAuthenticationContextID = new FieldAccessor<ServerAuthConfigType, String>(ServerAuthConfigType.class, "authenticationContextID");
+    private final static FieldAccessor<ServerAuthConfigType, Boolean> serverAuthConfigType_protected = new FieldAccessor<ServerAuthConfigType, Boolean>(ServerAuthConfigType.class, "_protected");
+    private final static FieldAccessor<ServerAuthConfigType, List<ServerAuthContextType>> serverAuthConfigTypeServerAuthContext = new FieldAccessor<ServerAuthConfigType, List<ServerAuthContextType>>(ServerAuthConfigType.class, "serverAuthContext");
+
+    public ServerAuthConfigTypeJAXB() {
+        super(ServerAuthConfigType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "serverAuthConfigType".intern()), ServerAuthContextTypeJAXB.class);
+    }
+
+    public static ServerAuthConfigType readServerAuthConfigType(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+        return INSTANCE.read(reader, context);
+    }
+
+    public static void writeServerAuthConfigType(XoXMLStreamWriter writer, ServerAuthConfigType serverAuthConfigType, RuntimeContext context)
+        throws Exception
+    {
+        INSTANCE.write(writer, serverAuthConfigType, context);
+    }
+
+    public final ServerAuthConfigType read(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+
+        // Check for xsi:nil
+        if (reader.isXsiNil()) {
+            return null;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        ServerAuthConfigType serverAuthConfigType = new ServerAuthConfigType();
+        context.beforeUnmarshal(serverAuthConfigType, lifecycleCallback);
+
+        List<ServerAuthContextType> serverAuthContext = null;
+
+        // Check xsi:type
+        QName xsiType = reader.getXsiType();
+        if (xsiType!= null) {
+            if (("serverAuthConfigType"!= xsiType.getLocalPart())||("http://geronimo.apache.org/xml/ns/geronimo-jaspi"!= xsiType.getNamespaceURI())) {
+                return context.unexpectedXsiType(reader, ServerAuthConfigType.class);
+            }
+        }
+
+        // Read attributes
+        for (Attribute attribute: reader.getAttributes()) {
+            if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI!= attribute.getNamespace()) {
+                context.unexpectedAttribute(attribute);
+            }
+        }
+
+        // Read elements
+        for (XoXMLStreamReader elementReader: reader.getChildElements()) {
+            if (("messageLayer" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: messageLayer
+                String messageLayer = elementReader.getElementAsString();
+                serverAuthConfigTypeMessageLayer.setObject(reader, context, serverAuthConfigType, messageLayer);
+            } else if (("appContext" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: appContext
+                String appContext = elementReader.getElementAsString();
+                serverAuthConfigTypeAppContext.setObject(reader, context, serverAuthConfigType, appContext);
+            } else if (("authenticationContextID" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: authenticationContextID
+                String authenticationContextID = elementReader.getElementAsString();
+                serverAuthConfigTypeAuthenticationContextID.setObject(reader, context, serverAuthConfigType, authenticationContextID);
+            } else if (("protected" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: _protected
+                Boolean _protected = ("1".equals(elementReader.getElementAsString())||"true".equals(elementReader.getElementAsString()));
+                serverAuthConfigType_protected.setBoolean(reader, context, serverAuthConfigType, _protected);
+            } else if (("serverAuthContext" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: serverAuthContext
+                ServerAuthContextType serverAuthContextItem = readServerAuthContextType(elementReader, context);
+                if (serverAuthContext == null) {
+                    serverAuthContext = serverAuthConfigTypeServerAuthContext.getObject(reader, context, serverAuthConfigType);
+                    if (serverAuthContext!= null) {
+                        serverAuthContext.clear();
+                    } else {
+                        serverAuthContext = new ArrayList<ServerAuthContextType>();
+                    }
+                }
+                serverAuthContext.add(serverAuthContextItem);
+            } else {
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "messageLayer"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "appContext"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "authenticationContextID"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "protected"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "serverAuthContext"));
+            }
+        }
+        if (serverAuthContext!= null) {
+            serverAuthConfigTypeServerAuthContext.setObject(reader, context, serverAuthConfigType, serverAuthContext);
+        }
+
+        context.afterUnmarshal(serverAuthConfigType, lifecycleCallback);
+
+        return serverAuthConfigType;
+    }
+
+    public final void write(XoXMLStreamWriter writer, ServerAuthConfigType serverAuthConfigType, RuntimeContext context)
+        throws Exception
+    {
+        if (serverAuthConfigType == null) {
+            writer.writeXsiNil();
+            return ;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        String prefix = writer.getUniquePrefix("http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+        if (ServerAuthConfigType.class!= serverAuthConfigType.getClass()) {
+            context.unexpectedSubclass(writer, serverAuthConfigType, ServerAuthConfigType.class);
+            return ;
+        }
+
+        context.beforeMarshal(serverAuthConfigType, lifecycleCallback);
+
+
+        // ELEMENT: messageLayer
+        String messageLayer = serverAuthConfigTypeMessageLayer.getObject(serverAuthConfigType, context, serverAuthConfigType);
+        if (messageLayer!= null) {
+            writer.writeStartElement(prefix, "messageLayer", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(messageLayer);
+            writer.writeEndElement();
+        }
+
+        // ELEMENT: appContext
+        String appContext = serverAuthConfigTypeAppContext.getObject(serverAuthConfigType, context, serverAuthConfigType);
+        if (appContext!= null) {
+            writer.writeStartElement(prefix, "appContext", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(appContext);
+            writer.writeEndElement();
+        }
+
+        // ELEMENT: authenticationContextID
+        String authenticationContextID = serverAuthConfigTypeAuthenticationContextID.getObject(serverAuthConfigType, context, serverAuthConfigType);
+        if (authenticationContextID!= null) {
+            writer.writeStartElement(prefix, "authenticationContextID", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(authenticationContextID);
+            writer.writeEndElement();
+        } else {
+            context.unexpectedNullValue(serverAuthConfigType, "authenticationContextID");
+        }
+
+        // ELEMENT: _protected
+        Boolean _protected = serverAuthConfigType_protected.getBoolean(serverAuthConfigType, context, serverAuthConfigType);
+        writer.writeStartElement(prefix, "protected", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+        writer.writeCharacters(Boolean.toString(_protected));
+        writer.writeEndElement();
+
+        // ELEMENT: serverAuthContext
+        List<ServerAuthContextType> serverAuthContext = serverAuthConfigTypeServerAuthContext.getObject(serverAuthConfigType, context, serverAuthConfigType);
+        if (serverAuthContext!= null) {
+            for (ServerAuthContextType serverAuthContextItem: serverAuthContext) {
+                writer.writeStartElement(prefix, "serverAuthContext", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+                if (serverAuthContextItem!= null) {
+                    writeServerAuthContextType(writer, serverAuthContextItem, context);
+                } else {
+                    writer.writeXsiNil();
+                }
+                writer.writeEndElement();
+            }
+        }
+
+        context.afterMarshal(serverAuthConfigType, lifecycleCallback);
+    }
+
+}

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthConfigTypeJAXB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthConfigTypeJAXB.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthConfigTypeJAXB.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthContextTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthContextTypeJAXB.java?rev=677108&view=auto
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthContextTypeJAXB.java (added)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthContextTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -0,0 +1,188 @@
+
+package sxc.org.apache.geronimo.components.jaspi.model;
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import com.envoisolutions.sxc.jaxb.FieldAccessor;
+import com.envoisolutions.sxc.jaxb.JAXBObject;
+import com.envoisolutions.sxc.jaxb.LifecycleCallback;
+import com.envoisolutions.sxc.jaxb.RuntimeContext;
+import com.envoisolutions.sxc.util.Attribute;
+import com.envoisolutions.sxc.util.XoXMLStreamReader;
+import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.AuthModuleType;
+import org.apache.geronimo.components.jaspi.model.ServerAuthContextType;
+
+
+import static sxc.org.apache.geronimo.components.jaspi.model.AuthModuleTypeJAXB.readAuthModuleType;
+import static sxc.org.apache.geronimo.components.jaspi.model.AuthModuleTypeJAXB.writeAuthModuleType;
+
+@SuppressWarnings({
+    "StringEquality"
+})
+public class ServerAuthContextTypeJAXB
+    extends JAXBObject<ServerAuthContextType>
+{
+
+    public final static ServerAuthContextTypeJAXB INSTANCE = new ServerAuthContextTypeJAXB();
+    private final static LifecycleCallback lifecycleCallback = new LifecycleCallback(ServerAuthContextType.class);
+    private final static FieldAccessor<ServerAuthContextType, String> serverAuthContextTypeMessageLayer = new FieldAccessor<ServerAuthContextType, String>(ServerAuthContextType.class, "messageLayer");
+    private final static FieldAccessor<ServerAuthContextType, String> serverAuthContextTypeAppContext = new FieldAccessor<ServerAuthContextType, String>(ServerAuthContextType.class, "appContext");
+    private final static FieldAccessor<ServerAuthContextType, String> serverAuthContextTypeAuthenticationContextID = new FieldAccessor<ServerAuthContextType, String>(ServerAuthContextType.class, "authenticationContextID");
+    private final static FieldAccessor<ServerAuthContextType, List<AuthModuleType>> serverAuthContextTypeServerAuthModule = new FieldAccessor<ServerAuthContextType, List<AuthModuleType>>(ServerAuthContextType.class, "serverAuthModule");
+
+    public ServerAuthContextTypeJAXB() {
+        super(ServerAuthContextType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "serverAuthContextType".intern()), AuthModuleTypeJAXB.class);
+    }
+
+    public static ServerAuthContextType readServerAuthContextType(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+        return INSTANCE.read(reader, context);
+    }
+
+    public static void writeServerAuthContextType(XoXMLStreamWriter writer, ServerAuthContextType serverAuthContextType, RuntimeContext context)
+        throws Exception
+    {
+        INSTANCE.write(writer, serverAuthContextType, context);
+    }
+
+    public final ServerAuthContextType read(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+
+        // Check for xsi:nil
+        if (reader.isXsiNil()) {
+            return null;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        ServerAuthContextType serverAuthContextType = new ServerAuthContextType();
+        context.beforeUnmarshal(serverAuthContextType, lifecycleCallback);
+
+        List<AuthModuleType> serverAuthModule = null;
+
+        // Check xsi:type
+        QName xsiType = reader.getXsiType();
+        if (xsiType!= null) {
+            if (("serverAuthContextType"!= xsiType.getLocalPart())||("http://geronimo.apache.org/xml/ns/geronimo-jaspi"!= xsiType.getNamespaceURI())) {
+                return context.unexpectedXsiType(reader, ServerAuthContextType.class);
+            }
+        }
+
+        // Read attributes
+        for (Attribute attribute: reader.getAttributes()) {
+            if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI!= attribute.getNamespace()) {
+                context.unexpectedAttribute(attribute);
+            }
+        }
+
+        // Read elements
+        for (XoXMLStreamReader elementReader: reader.getChildElements()) {
+            if (("messageLayer" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: messageLayer
+                String messageLayer = elementReader.getElementAsString();
+                serverAuthContextTypeMessageLayer.setObject(reader, context, serverAuthContextType, messageLayer);
+            } else if (("appContext" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: appContext
+                String appContext = elementReader.getElementAsString();
+                serverAuthContextTypeAppContext.setObject(reader, context, serverAuthContextType, appContext);
+            } else if (("authenticationContextID" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: authenticationContextID
+                String authenticationContextID = elementReader.getElementAsString();
+                serverAuthContextTypeAuthenticationContextID.setObject(reader, context, serverAuthContextType, authenticationContextID);
+            } else if (("serverAuthModule" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: serverAuthModule
+                AuthModuleType serverAuthModuleItem = readAuthModuleType(elementReader, context);
+                if (serverAuthModule == null) {
+                    serverAuthModule = serverAuthContextTypeServerAuthModule.getObject(reader, context, serverAuthContextType);
+                    if (serverAuthModule!= null) {
+                        serverAuthModule.clear();
+                    } else {
+                        serverAuthModule = new ArrayList<AuthModuleType>();
+                    }
+                }
+                serverAuthModule.add(serverAuthModuleItem);
+            } else {
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "messageLayer"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "appContext"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "authenticationContextID"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "serverAuthModule"));
+            }
+        }
+        if (serverAuthModule!= null) {
+            serverAuthContextTypeServerAuthModule.setObject(reader, context, serverAuthContextType, serverAuthModule);
+        }
+
+        context.afterUnmarshal(serverAuthContextType, lifecycleCallback);
+
+        return serverAuthContextType;
+    }
+
+    public final void write(XoXMLStreamWriter writer, ServerAuthContextType serverAuthContextType, RuntimeContext context)
+        throws Exception
+    {
+        if (serverAuthContextType == null) {
+            writer.writeXsiNil();
+            return ;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        String prefix = writer.getUniquePrefix("http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+        if (ServerAuthContextType.class!= serverAuthContextType.getClass()) {
+            context.unexpectedSubclass(writer, serverAuthContextType, ServerAuthContextType.class);
+            return ;
+        }
+
+        context.beforeMarshal(serverAuthContextType, lifecycleCallback);
+
+
+        // ELEMENT: messageLayer
+        String messageLayer = serverAuthContextTypeMessageLayer.getObject(serverAuthContextType, context, serverAuthContextType);
+        if (messageLayer!= null) {
+            writer.writeStartElement(prefix, "messageLayer", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(messageLayer);
+            writer.writeEndElement();
+        }
+
+        // ELEMENT: appContext
+        String appContext = serverAuthContextTypeAppContext.getObject(serverAuthContextType, context, serverAuthContextType);
+        if (appContext!= null) {
+            writer.writeStartElement(prefix, "appContext", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(appContext);
+            writer.writeEndElement();
+        }
+
+        // ELEMENT: authenticationContextID
+        String authenticationContextID = serverAuthContextTypeAuthenticationContextID.getObject(serverAuthContextType, context, serverAuthContextType);
+        if (authenticationContextID!= null) {
+            writer.writeStartElement(prefix, "authenticationContextID", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writer.writeCharacters(authenticationContextID);
+            writer.writeEndElement();
+        } else {
+            context.unexpectedNullValue(serverAuthContextType, "authenticationContextID");
+        }
+
+        // ELEMENT: serverAuthModule
+        List<AuthModuleType> serverAuthModule = serverAuthContextTypeServerAuthModule.getObject(serverAuthContextType, context, serverAuthContextType);
+        if (serverAuthModule!= null) {
+            for (AuthModuleType serverAuthModuleItem: serverAuthModule) {
+                writer.writeStartElement(prefix, "serverAuthModule", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+                if (serverAuthModuleItem!= null) {
+                    writeAuthModuleType(writer, serverAuthModuleItem, context);
+                } else {
+                    writer.writeXsiNil();
+                }
+                writer.writeEndElement();
+            }
+        }
+
+        context.afterMarshal(serverAuthContextType, lifecycleCallback);
+    }
+
+}

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthContextTypeJAXB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthContextTypeJAXB.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/ServerAuthContextTypeJAXB.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetPolicyTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetPolicyTypeJAXB.java?rev=677108&view=auto
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetPolicyTypeJAXB.java (added)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetPolicyTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -0,0 +1,165 @@
+
+package sxc.org.apache.geronimo.components.jaspi.model;
+
+import java.util.ArrayList;
+import java.util.List;
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import com.envoisolutions.sxc.jaxb.FieldAccessor;
+import com.envoisolutions.sxc.jaxb.JAXBObject;
+import com.envoisolutions.sxc.jaxb.LifecycleCallback;
+import com.envoisolutions.sxc.jaxb.RuntimeContext;
+import com.envoisolutions.sxc.util.Attribute;
+import com.envoisolutions.sxc.util.XoXMLStreamReader;
+import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.ProtectionPolicyType;
+import org.apache.geronimo.components.jaspi.model.TargetPolicyType;
+import org.apache.geronimo.components.jaspi.model.TargetType;
+
+
+import static sxc.org.apache.geronimo.components.jaspi.model.ProtectionPolicyTypeJAXB.readProtectionPolicyType;
+import static sxc.org.apache.geronimo.components.jaspi.model.ProtectionPolicyTypeJAXB.writeProtectionPolicyType;
+import static sxc.org.apache.geronimo.components.jaspi.model.TargetTypeJAXB.readTargetType;
+import static sxc.org.apache.geronimo.components.jaspi.model.TargetTypeJAXB.writeTargetType;
+
+@SuppressWarnings({
+    "StringEquality"
+})
+public class TargetPolicyTypeJAXB
+    extends JAXBObject<TargetPolicyType>
+{
+
+    public final static TargetPolicyTypeJAXB INSTANCE = new TargetPolicyTypeJAXB();
+    private final static LifecycleCallback lifecycleCallback = new LifecycleCallback(TargetPolicyType.class);
+    private final static FieldAccessor<TargetPolicyType, ProtectionPolicyType> targetPolicyTypeProtectionPolicy = new FieldAccessor<TargetPolicyType, ProtectionPolicyType>(TargetPolicyType.class, "protectionPolicy");
+    private final static FieldAccessor<TargetPolicyType, List<TargetType>> targetPolicyTypeTarget = new FieldAccessor<TargetPolicyType, List<TargetType>>(TargetPolicyType.class, "target");
+
+    public TargetPolicyTypeJAXB() {
+        super(TargetPolicyType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "targetPolicyType".intern()), ProtectionPolicyTypeJAXB.class, TargetTypeJAXB.class);
+    }
+
+    public static TargetPolicyType readTargetPolicyType(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+        return INSTANCE.read(reader, context);
+    }
+
+    public static void writeTargetPolicyType(XoXMLStreamWriter writer, TargetPolicyType targetPolicyType, RuntimeContext context)
+        throws Exception
+    {
+        INSTANCE.write(writer, targetPolicyType, context);
+    }
+
+    public final TargetPolicyType read(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+
+        // Check for xsi:nil
+        if (reader.isXsiNil()) {
+            return null;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        TargetPolicyType targetPolicyType = new TargetPolicyType();
+        context.beforeUnmarshal(targetPolicyType, lifecycleCallback);
+
+        List<TargetType> target = null;
+
+        // Check xsi:type
+        QName xsiType = reader.getXsiType();
+        if (xsiType!= null) {
+            if (("targetPolicyType"!= xsiType.getLocalPart())||("http://geronimo.apache.org/xml/ns/geronimo-jaspi"!= xsiType.getNamespaceURI())) {
+                return context.unexpectedXsiType(reader, TargetPolicyType.class);
+            }
+        }
+
+        // Read attributes
+        for (Attribute attribute: reader.getAttributes()) {
+            if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI!= attribute.getNamespace()) {
+                context.unexpectedAttribute(attribute);
+            }
+        }
+
+        // Read elements
+        for (XoXMLStreamReader elementReader: reader.getChildElements()) {
+            if (("protectionPolicy" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: protectionPolicy
+                ProtectionPolicyType protectionPolicy = readProtectionPolicyType(elementReader, context);
+                targetPolicyTypeProtectionPolicy.setObject(reader, context, targetPolicyType, protectionPolicy);
+            } else if (("target" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: target
+                TargetType targetItem = readTargetType(elementReader, context);
+                if (target == null) {
+                    target = targetPolicyTypeTarget.getObject(reader, context, targetPolicyType);
+                    if (target!= null) {
+                        target.clear();
+                    } else {
+                        target = new ArrayList<TargetType>();
+                    }
+                }
+                target.add(targetItem);
+            } else {
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "protectionPolicy"), new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "target"));
+            }
+        }
+        if (target!= null) {
+            targetPolicyTypeTarget.setObject(reader, context, targetPolicyType, target);
+        }
+
+        context.afterUnmarshal(targetPolicyType, lifecycleCallback);
+
+        return targetPolicyType;
+    }
+
+    public final void write(XoXMLStreamWriter writer, TargetPolicyType targetPolicyType, RuntimeContext context)
+        throws Exception
+    {
+        if (targetPolicyType == null) {
+            writer.writeXsiNil();
+            return ;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        String prefix = writer.getUniquePrefix("http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+        if (TargetPolicyType.class!= targetPolicyType.getClass()) {
+            context.unexpectedSubclass(writer, targetPolicyType, TargetPolicyType.class);
+            return ;
+        }
+
+        context.beforeMarshal(targetPolicyType, lifecycleCallback);
+
+
+        // ELEMENT: protectionPolicy
+        ProtectionPolicyType protectionPolicy = targetPolicyTypeProtectionPolicy.getObject(targetPolicyType, context, targetPolicyType);
+        if (protectionPolicy!= null) {
+            writer.writeStartElement(prefix, "protectionPolicy", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+            writeProtectionPolicyType(writer, protectionPolicy, context);
+            writer.writeEndElement();
+        } else {
+            context.unexpectedNullValue(targetPolicyType, "protectionPolicy");
+        }
+
+        // ELEMENT: target
+        List<TargetType> target = targetPolicyTypeTarget.getObject(targetPolicyType, context, targetPolicyType);
+        if (target!= null) {
+            for (TargetType targetItem: target) {
+                writer.writeStartElement(prefix, "target", "http://geronimo.apache.org/xml/ns/geronimo-jaspi");
+                if (targetItem!= null) {
+                    writeTargetType(writer, targetItem, context);
+                } else {
+                    writer.writeXsiNil();
+                }
+                writer.writeEndElement();
+            }
+        }
+
+        context.afterMarshal(targetPolicyType, lifecycleCallback);
+    }
+
+}

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetPolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetPolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetPolicyTypeJAXB.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain

Added: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetTypeJAXB.java
URL: http://svn.apache.org/viewvc/geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetTypeJAXB.java?rev=677108&view=auto
==============================================================================
--- geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetTypeJAXB.java (added)
+++ geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetTypeJAXB.java Tue Jul 15 16:46:50 2008
@@ -0,0 +1,123 @@
+
+package sxc.org.apache.geronimo.components.jaspi.model;
+
+import javax.xml.XMLConstants;
+import javax.xml.namespace.QName;
+import com.envoisolutions.sxc.jaxb.FieldAccessor;
+import com.envoisolutions.sxc.jaxb.JAXBObject;
+import com.envoisolutions.sxc.jaxb.LifecycleCallback;
+import com.envoisolutions.sxc.jaxb.RuntimeContext;
+import com.envoisolutions.sxc.util.Attribute;
+import com.envoisolutions.sxc.util.XoXMLStreamReader;
+import com.envoisolutions.sxc.util.XoXMLStreamWriter;
+import org.apache.geronimo.components.jaspi.model.TargetType;
+
+@SuppressWarnings({
+    "StringEquality"
+})
+public class TargetTypeJAXB
+    extends JAXBObject<TargetType>
+{
+
+    public final static TargetTypeJAXB INSTANCE = new TargetTypeJAXB();
+    private final static LifecycleCallback lifecycleCallback = new LifecycleCallback(TargetType.class);
+    private final static FieldAccessor<TargetType, String> targetTypeClassName = new FieldAccessor<TargetType, String>(TargetType.class, "className");
+
+    public TargetTypeJAXB() {
+        super(TargetType.class, null, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi".intern(), "targetType".intern()));
+    }
+
+    public static TargetType readTargetType(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+        return INSTANCE.read(reader, context);
+    }
+
+    public static void writeTargetType(XoXMLStreamWriter writer, TargetType targetType, RuntimeContext context)
+        throws Exception
+    {
+        INSTANCE.write(writer, targetType, context);
+    }
+
+    public final TargetType read(XoXMLStreamReader reader, RuntimeContext context)
+        throws Exception
+    {
+
+        // Check for xsi:nil
+        if (reader.isXsiNil()) {
+            return null;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        TargetType targetType = new TargetType();
+        context.beforeUnmarshal(targetType, lifecycleCallback);
+
+
+        // Check xsi:type
+        QName xsiType = reader.getXsiType();
+        if (xsiType!= null) {
+            if (("targetType"!= xsiType.getLocalPart())||("http://geronimo.apache.org/xml/ns/geronimo-jaspi"!= xsiType.getNamespaceURI())) {
+                return context.unexpectedXsiType(reader, TargetType.class);
+            }
+        }
+
+        // Read attributes
+        for (Attribute attribute: reader.getAttributes()) {
+            if (XMLConstants.W3C_XML_SCHEMA_INSTANCE_NS_URI!= attribute.getNamespace()) {
+                context.unexpectedAttribute(attribute);
+            }
+        }
+
+        // Read elements
+        for (XoXMLStreamReader elementReader: reader.getChildElements()) {
+            if (("className" == elementReader.getLocalName())&&("http://geronimo.apache.org/xml/ns/geronimo-jaspi" == elementReader.getNamespaceURI())) {
+                // ELEMENT: className
+                String className = elementReader.getElementAsString();
+                targetTypeClassName.setObject(reader, context, targetType, className);
+            } else {
+                context.unexpectedElement(elementReader, new QName("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "className"));
+            }
+        }
+
+        context.afterUnmarshal(targetType, lifecycleCallback);
+
+        return targetType;
+    }
+
+    public final void write(XoXMLStreamWriter writer, TargetType targetType, RuntimeContext context)
+        throws Exception
+    {
+        if (targetType == null) {
+            writer.writeXsiNil();
+            return ;
+        }
+
+        if (context == null) {
+            context = new RuntimeContext();
+        }
+
+        if (TargetType.class!= targetType.getClass()) {
+            context.unexpectedSubclass(writer, targetType, TargetType.class);
+            return ;
+        }
+
+        context.beforeMarshal(targetType, lifecycleCallback);
+
+
+        // ELEMENT: className
+        String className = targetTypeClassName.getObject(targetType, context, targetType);
+        if (className!= null) {
+            writer.writeStartElementWithAutoPrefix("http://geronimo.apache.org/xml/ns/geronimo-jaspi", "className");
+            writer.writeCharacters(className);
+            writer.writeEndElement();
+        } else {
+            context.unexpectedNullValue(targetType, "className");
+        }
+
+        context.afterMarshal(targetType, lifecycleCallback);
+    }
+
+}

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetTypeJAXB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetTypeJAXB.java
------------------------------------------------------------------------------
    svn:keywords = Date Revision

Propchange: geronimo/components/jaspi/trunk/geronimo-jaspi/src/main/java/sxc/org/apache/geronimo/components/jaspi/model/TargetTypeJAXB.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain



Mime
View raw message