axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@apache.org
Subject cvs commit: xml-axis/java/src/org/apache/axis/encoding DeserializationContext.java SerializationContext.java
Date Fri, 04 May 2001 21:30:00 GMT
rubys       01/05/04 14:30:00

  Modified:    java/src/org/apache/axis/encoding
                        DeserializationContext.java
                        SerializationContext.java
  Log:
  More lazy initialization
  
  Revision  Changes    Path
  1.6       +4 -2      xml-axis/java/src/org/apache/axis/encoding/DeserializationContext.java
  
  Index: DeserializationContext.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/encoding/DeserializationContext.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- DeserializationContext.java	2001/05/04 21:22:48	1.5
  +++ DeserializationContext.java	2001/05/04 21:29:56	1.6
  @@ -72,7 +72,7 @@
   {
       public SOAPSAXHandler baseHandler;
       public Hashtable idMappings = new Hashtable();
  -    public TypeMappingRegistry mappingRegistry = new SOAPTypeMappingRegistry();
  +    public TypeMappingRegistry mappingRegistry = null;
       public Hashtable fixups = new Hashtable();
       public boolean hasUnresolvedHrefs = false;
       
  @@ -147,6 +147,8 @@
   
       public TypeMappingRegistry getTypeMappingRegistry()
       {
  +        if (mappingRegistry == null) 
  +            mappingRegistry = new SOAPTypeMappingRegistry();
           return mappingRegistry;
       }
       
  @@ -163,7 +165,7 @@
       
       public DeserializerBase getDeserializer(QName qName)
       {
  -        DeserializerBase dSer = mappingRegistry.getDeserializer(qName);
  +        DeserializerBase dSer = getTypeMappingRegistry().getDeserializer(qName);
           dSer.setDeserializationContext(this);
           return dSer;
       }
  
  
  
  1.6       +2 -2      xml-axis/java/src/org/apache/axis/encoding/SerializationContext.java
  
  Index: SerializationContext.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/encoding/SerializationContext.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- SerializationContext.java	2001/05/04 21:04:11	1.5
  +++ SerializationContext.java	2001/05/04 21:29:57	1.6
  @@ -142,13 +142,13 @@
       
       public QName getQNameForClass(Class cls)
       {
  -        return getMappingRegistry().getTypeQName(cls);
  +        return getTypeMappingRegistry().getTypeQName(cls);
       }
       
       public void serialize(QName qName, Attributes attributes, Object value)
           throws IOException
       {
  -        getMappingRegistry().serialize(qName, attributes, value, this);
  +        getTypeMappingRegistry().serialize(qName, attributes, value, this);
       }
       
       public void startElement(QName qName, Attributes attributes)
  
  
  

Mime
View raw message