gov.nih.nci.cagrid.introduce.codegen.serializers
Class SyncSerialization

java.lang.Object
  extended by gov.nih.nci.cagrid.introduce.codegen.common.SyncTool
      extended by gov.nih.nci.cagrid.introduce.codegen.serializers.SyncSerialization

public class SyncSerialization
extends SyncTool

Reads client-config.wsdd and server-config.wsdd, and adds any typemappings that are required. <typeMapping qname="(from Namespace namespace, and SchemaElement type)" languageSpecificType="java:(from Namespace packageName+.+SchemaElement className)" serializer="(from SchemaElement serializer)" deserializer="(from SchemaElement deserializer)" encodingStyle=""/> editors will look for: <!-- START INTRODUCE TYPEMAPPINGS --> if it exists, it dump the type mappings from its start, replacing evertying in the file until finding: <!-- END INTRODUCE TYPEMAPPINGS --> if the tag isn't found, the tags (and type mappings) will be added to the end of the file (in appropriate location for server and client)

Author:
oster

Field Summary
static java.lang.String MAPPING_FOOTER
           
static java.lang.String MAPPING_HEADER
           
static java.lang.String WSDD_END_TAG
           
 
Constructor Summary
SyncSerialization(java.io.File baseDirectory, ServiceInformation info)
           
 
Method Summary
static java.util.List buildTypeMappings(NamespaceType[] namespaces)
           
static void editFile(java.io.File wsddFile, java.lang.String replacement)
           
static java.lang.String mappingToString(org.apache.axis.deployment.wsdd.WSDDTypeMapping mapping)
           
 void sync()
           
static boolean typeContainsAllAttributes(SchemaElementType type)
           
 
Methods inherited from class gov.nih.nci.cagrid.introduce.codegen.common.SyncTool
getBaseDirectory, getServiceInformation, setBaseDirectory, setServiceInformation
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

WSDD_END_TAG

public static final java.lang.String WSDD_END_TAG
See Also:
Constant Field Values

MAPPING_HEADER

public static final java.lang.String MAPPING_HEADER
See Also:
Constant Field Values

MAPPING_FOOTER

public static final java.lang.String MAPPING_FOOTER
See Also:
Constant Field Values
Constructor Detail

SyncSerialization

public SyncSerialization(java.io.File baseDirectory,
                         ServiceInformation info)
Method Detail

sync

public void sync()
          throws SynchronizationException
Specified by:
sync in class SyncTool
Throws:
SynchronizationException - if unable to locate and write to client-config.wsdd and server-config.wsdd

editFile

public static void editFile(java.io.File wsddFile,
                            java.lang.String replacement)
                     throws SynchronizationException
Throws:
SynchronizationException

buildTypeMappings

public static java.util.List buildTypeMappings(NamespaceType[] namespaces)
                                        throws SynchronizationException
Throws:
SynchronizationException

mappingToString

public static java.lang.String mappingToString(org.apache.axis.deployment.wsdd.WSDDTypeMapping mapping)
                                        throws SynchronizationException
Throws:
SynchronizationException

typeContainsAllAttributes

public static boolean typeContainsAllAttributes(SchemaElementType type)
                                         throws SynchronizationException
Throws:
SynchronizationException