FileDocCategorySizeDatePackage
SOAPElementFactory.javaAPI DocApache Axis 1.44722Sat Apr 22 18:57:28 BST 2006javax.xml.soap

SOAPElementFactory

public class SOAPElementFactory extends Object

SOAPElementFactory is a factory for XML fragments that will eventually end up in the SOAP part. These fragments can be inserted as children of the SOAPHeader or SOAPBody or SOAPEnvelope.

Elements created using this factory do not have the properties of an element that lives inside a SOAP header document. These elements are copied into the XML document tree when they are inserted.

deprecated
- Use javax.xml.soap.SOAPFactory for creating SOAPElements.
see
SOAPFactory SOAPFactory

Fields Summary
private SOAPFactory
sf
Constructors Summary
private SOAPElementFactory(SOAPFactory soapfactory)
Create a new SOAPElementFactory from a SOAPFactory.

param
soapfactory the SOAPFactory to use

        sf = soapfactory;
    
Methods Summary
public javax.xml.soap.SOAPElementcreate(javax.xml.soap.Name name)
Create a SOAPElement object initialized with the given Name object.

param
name a Name object with the XML name for the new element
return
the new SOAPElement object that was created
throws
SOAPException if there is an error in creating the SOAPElement object
deprecated
Use javax.xml.soap.SOAPFactory.createElement(javax.xml.soap.Name) instead
see
SOAPFactory#createElement(javax.xml.soap.Name) SOAPFactory.createElement(javax.xml.soap.Name)

        return sf.createElement(name);
    
public javax.xml.soap.SOAPElementcreate(java.lang.String localName)
Create a SOAPElement object initialized with the given local name.

param
localName a String giving the local name for the new element
return
the new SOAPElement object that was created
throws
SOAPException if there is an error in creating the SOAPElement object
deprecated
Use javax.xml.soap.SOAPFactory.createElement(String localName) instead
see
SOAPFactory#createElement(java.lang.String) SOAPFactory.createElement(java.lang.String)

        return sf.createElement(localName);
    
public javax.xml.soap.SOAPElementcreate(java.lang.String localName, java.lang.String prefix, java.lang.String uri)
Create a new SOAPElement object with the given local name, prefix and uri.

param
localName a String giving the local name for the new element
param
prefix the prefix for this SOAPElement
param
uri a String giving the URI of the namespace to which the new element belongs
return
the new SOAPElement object that was created
throws
SOAPException if there is an error in creating the SOAPElement object
deprecated
Use javax.xml.soap.SOAPFactory.createElement(String localName, String prefix, String uri) instead
see
SOAPFactory#createElement(java.lang.String, java.lang.String, java.lang.String) SOAPFactory.createElement(java.lang.String, java.lang.String, java.lang.String)

        return sf.createElement(localName, prefix, uri);
    
public static javax.xml.soap.SOAPElementFactorynewInstance()
Creates a new instance of SOAPElementFactory.

return
a new instance of a SOAPElementFactory
throws
SOAPException if there was an error creating the default SOAPElementFactory


        try {
            return new SOAPElementFactory(SOAPFactory.newInstance());
        } catch (Exception exception) {
            throw new SOAPException("Unable to create SOAP Element Factory: "
                                    + exception.getMessage());
        }