com.ebmwebsourcing.wsstar.wsnb.services.impl.util
Class Wsnb4ServUtils

java.lang.Object
  extended by com.ebmwebsourcing.wsstar.wsnb.services.impl.util.Wsnb4ServUtils

public abstract class Wsnb4ServUtils
extends java.lang.Object


Constructor Summary
Wsnb4ServUtils()
           
 
Method Summary
static org.w3c.dom.Document convertFromFiletoDocument(java.io.File file)
          convert xml File loaded as File Java object to Document Java object
static org.w3c.dom.Element createPropertyAsElement(javax.xml.namespace.QName propertyQName, java.lang.String propertyValue)
          Create a Element representation of a given resource property (See "WS-ResourceProperties" specification and related implementation)
static org.w3c.dom.Element createSimpleReasonElement(java.lang.String reasonAsString)
           
static org.w3c.dom.Element createSubscriptionIdAsReferenceParamElt(java.lang.String uuid)
          Format the subscription's Id as a WS-Addressing ReferenceParameters element
static java.lang.String getSubscriptionIdFromReferenceParams(com.ebmwebsourcing.wsstar.addressing.datatypes.api.abstraction.ReferenceParametersType refParams)
          Format the subscription's Id as a WS-Addressing ReferenceParameters element
static com.ebmwebsourcing.wsstar.basenotification.datatypes.api.abstraction.WsnbReader getWsnbReader()
           
static com.ebmwebsourcing.wsstar.basenotification.datatypes.api.abstraction.WsnbWriter getWsnbWriter()
           
static com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.abstraction.WsrfrlReader getWsrfrlReader()
           
static com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.abstraction.WsrfrlWriter getWsrfrlWriter()
           
static com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.abstraction.WsrfrpReader getWsrfrpReader()
           
static com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.abstraction.WsrfrpWriter getWsrfrpWriter()
           
static com.ebmwebsourcing.wsstar.topics.datatypes.api.abstraction.WstopReader getWstopReader()
           
static com.ebmwebsourcing.wsstar.topics.datatypes.api.abstraction.WstopWriter getWstopWriter()
           
static void initModelFactories(com.ebmwebsourcing.wsstar.addressing.datatypes.api.implementor.WsaModelFactory wsaModFact, com.ebmwebsourcing.wsstar.basefaults.datatypes.api.implementor.WsrfbfModelFactory wsrfbfModFact, com.ebmwebsourcing.wsstar.resource.datatypes.api.implementor.WsrfrModelFactory wsrfrModFact, com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.implementor.WsrfrlModelFactory wsrfrlModFact, com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.implementor.WsrfrpModelFactory wsrfrpModFact, com.ebmwebsourcing.wsstar.topics.datatypes.api.implementor.WstopModelFactory wstopModFact, com.ebmwebsourcing.wsstar.basenotification.datatypes.api.implementor.WsnbModelFactory wsnbModFact)
          /!
static java.lang.String prettyPrint(org.w3c.dom.Document xmlDocument)
          parse the xml Document and return it pretty-printed (with correct indentations, etc..).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Wsnb4ServUtils

public Wsnb4ServUtils()
Method Detail

getWsnbReader

public static com.ebmwebsourcing.wsstar.basenotification.datatypes.api.abstraction.WsnbReader getWsnbReader()
                                                                                                     throws com.ebmwebsourcing.wsstar.basenotification.datatypes.api.utils.WsnbException
Throws:
com.ebmwebsourcing.wsstar.basenotification.datatypes.api.utils.WsnbException

getWstopReader

public static com.ebmwebsourcing.wsstar.topics.datatypes.api.abstraction.WstopReader getWstopReader()
                                                                                             throws com.ebmwebsourcing.wsstar.topics.datatypes.api.utils.WstopException
Throws:
com.ebmwebsourcing.wsstar.topics.datatypes.api.utils.WstopException

getWsrfrlReader

public static com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.abstraction.WsrfrlReader getWsrfrlReader()
                                                                                                         throws com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.utils.WsrfrlException
Throws:
com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.utils.WsrfrlException

getWsrfrpReader

public static com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.abstraction.WsrfrpReader getWsrfrpReader()
                                                                                                           throws com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.utils.WsrfrpException
Throws:
com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.utils.WsrfrpException

getWsnbWriter

public static com.ebmwebsourcing.wsstar.basenotification.datatypes.api.abstraction.WsnbWriter getWsnbWriter()
                                                                                                     throws com.ebmwebsourcing.wsstar.basenotification.datatypes.api.utils.WsnbException
Throws:
com.ebmwebsourcing.wsstar.basenotification.datatypes.api.utils.WsnbException

getWstopWriter

public static com.ebmwebsourcing.wsstar.topics.datatypes.api.abstraction.WstopWriter getWstopWriter()
                                                                                             throws com.ebmwebsourcing.wsstar.topics.datatypes.api.utils.WstopException
Throws:
com.ebmwebsourcing.wsstar.topics.datatypes.api.utils.WstopException

getWsrfrlWriter

public static com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.abstraction.WsrfrlWriter getWsrfrlWriter()
                                                                                                         throws com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.utils.WsrfrlException
Throws:
com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.utils.WsrfrlException

getWsrfrpWriter

public static com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.abstraction.WsrfrpWriter getWsrfrpWriter()
                                                                                                           throws com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.utils.WsrfrpException
Throws:
com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.utils.WsrfrpException

initModelFactories

public static void initModelFactories(com.ebmwebsourcing.wsstar.addressing.datatypes.api.implementor.WsaModelFactory wsaModFact,
                                      com.ebmwebsourcing.wsstar.basefaults.datatypes.api.implementor.WsrfbfModelFactory wsrfbfModFact,
                                      com.ebmwebsourcing.wsstar.resource.datatypes.api.implementor.WsrfrModelFactory wsrfrModFact,
                                      com.ebmwebsourcing.wsstar.resourcelifetime.datatypes.api.implementor.WsrfrlModelFactory wsrfrlModFact,
                                      com.ebmwebsourcing.wsstar.resourceproperties.datatypes.api.implementor.WsrfrpModelFactory wsrfrpModFact,
                                      com.ebmwebsourcing.wsstar.topics.datatypes.api.implementor.WstopModelFactory wstopModFact,
                                      com.ebmwebsourcing.wsstar.basenotification.datatypes.api.implementor.WsnbModelFactory wsnbModFact)
/!\ Mandatory Call : -------------------- must be called to set the "modal" layer, as soon as possible

Parameters:
wsaModFact -
wsrfbfModFact -
wsrfrModFact -
wsrfrlModFact -
wsrfrpModFact - TODO
wstopModFact -
wsnbModFact -
wsnbrModFact -

convertFromFiletoDocument

public static org.w3c.dom.Document convertFromFiletoDocument(java.io.File file)
                                                      throws com.ebmwebsourcing.wsstar.basenotification.datatypes.api.utils.WsnbException
convert xml File loaded as File Java object to Document Java object

Parameters:
file - Java object to convert
Returns:
Document Representation
Throws:
com.ebmwebsourcing.wsstar.basenotification.datatypes.api.utils.WsnbException

createSubscriptionIdAsReferenceParamElt

public static org.w3c.dom.Element createSubscriptionIdAsReferenceParamElt(java.lang.String uuid)
                                                                   throws com.ebmwebsourcing.wsstar.addressing.datatypes.api.utils.WsaException
Format the subscription's Id as a WS-Addressing ReferenceParameters element

Parameters:
uuid -
Returns:
Throws:
com.ebmwebsourcing.wsstar.addressing.datatypes.api.utils.WsaException

getSubscriptionIdFromReferenceParams

public static java.lang.String getSubscriptionIdFromReferenceParams(com.ebmwebsourcing.wsstar.addressing.datatypes.api.abstraction.ReferenceParametersType refParams)
                                                             throws com.ebmwebsourcing.wsstar.addressing.datatypes.api.utils.WsaException
Format the subscription's Id as a WS-Addressing ReferenceParameters element

Parameters:
uuid -
Returns:
Throws:
com.ebmwebsourcing.wsstar.addressing.datatypes.api.utils.WsaException

createPropertyAsElement

public static org.w3c.dom.Element createPropertyAsElement(javax.xml.namespace.QName propertyQName,
                                                          java.lang.String propertyValue)
Create a Element representation of a given resource property (See "WS-ResourceProperties" specification and related implementation)

Parameters:
propertyQName -
propertyValue -
Returns:

createSimpleReasonElement

public static org.w3c.dom.Element createSimpleReasonElement(java.lang.String reasonAsString)

prettyPrint

public static java.lang.String prettyPrint(org.w3c.dom.Document xmlDocument)
parse the xml Document and return it pretty-printed (with correct indentations, etc..). Use the encoding defined at the parsing or in the document (utf8 is used if no encoding is defined)

Parameters:
xmlDocument - the xml document to pretty print. Must be non null


Copyright © 2011 eBM Websourcing. All Rights Reserved.