package org.apache.ws.resource.properties.v2004_11.porttype.impl;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.ws.resource.ResourceContext;
import org.apache.ws.resource.i18n.MessagesImpl;
import org.apache.ws.resource.properties.NamespaceVersionHolder;
import org.apache.ws.resource.properties.impl.AbstractResourcePropertiesPortType;
import org.apache.ws.resource.properties.impl.XmlBeansResourcePropertySet;
import org.apache.ws.resource.properties.v2004_11.porttype.GetResourcePropertyDocumentPortType;
import org.apache.ws.resource.properties.v2004_11.impl.NamespaceVersionHolderImpl;
import org.apache.ws.util.XmlBeanUtils;
import org.apache.ws.util.i18n.Messages;
import org.oasisOpen.docs.wsrf.x2004.x11.wsrfWSResourceProperties12Draft05.GetResourcePropertyDocumentDocument1;
import org.oasisOpen.docs.wsrf.x2004.x11.wsrfWSResourceProperties12Draft05.GetResourcePropertyDocumentResponseDocument;
/**
* @author Sal Campana
*/
public class GetResourcePropertyDocumentPortTypeImpl extends AbstractResourcePropertiesPortType implements GetResourcePropertyDocumentPortType
{
private static final Log LOG = LogFactory.getLog( GetMultipleResourcePropertiesPortTypeImpl.class );
private static final Messages MSG = MessagesImpl.getInstance();
private static final NamespaceVersionHolder NAMESPACE_SET = new NamespaceVersionHolderImpl();
/**
* Creates a new {@link AbstractResourcePropertiesPortType} object.
*
* @param resourceContext DOCUMENT_ME
*/
public GetResourcePropertyDocumentPortTypeImpl(ResourceContext resourceContext)
{
super(resourceContext);
}
/**
* DOCUMENT_ME
*
* @param requestDoc DOCUMENT_ME
* @return DOCUMENT_ME
*/
public GetResourcePropertyDocumentResponseDocument getResourcePropertyDocument(GetResourcePropertyDocumentDocument1 requestDoc)
{
GetResourcePropertyDocumentResponseDocument responseDocument = createResponseDocument();
GetResourcePropertyDocumentResponseDocument.GetResourcePropertyDocumentResponse responseDoc = responseDocument.getGetResourcePropertyDocumentResponse();
XmlBeansResourcePropertySet properties = (XmlBeansResourcePropertySet) getProperties();
XmlBeanUtils.addChildElement(responseDoc, properties.toXmlObject());
return responseDocument;
}
private GetResourcePropertyDocumentResponseDocument createResponseDocument()
{
GetResourcePropertyDocumentResponseDocument responseDoc =
GetResourcePropertyDocumentResponseDocument.Factory.newInstance();
responseDoc.addNewGetResourcePropertyDocumentResponse();
return responseDoc;
}
protected NamespaceVersionHolder getNamespaceSet()
{
return NAMESPACE_SET;
}
}