org.wso2.carbon.registry.ws.api.utils
Class CommonUtil

java.lang.Object
  extended by org.wso2.carbon.registry.ws.api.utils.CommonUtil

public class CommonUtil
extends Object


Constructor Summary
CommonUtil()
           
 
Method Summary
static Map createMap(String[] key, String[] value)
           
static WSTaggedResourcePath[] exchangeTaggedResourcepath(org.wso2.carbon.registry.core.TaggedResourcePath[] registry)
           
static org.wso2.carbon.registry.core.TaggedResourcePath[] exchangeWSResourcePath(WSTaggedResourcePath[] wsrpath)
           
static org.wso2.carbon.registry.core.service.RegistryService getRegistryService()
           
static byte[] makeBytesFromDataHandler(WSResource wsResource)
           
static DataHandler makeDataHandler(org.wso2.carbon.registry.core.Resource resource, File tempFile)
           
static WSCollection newCollectiontoWSCollection(org.wso2.carbon.registry.core.Collection collection)
           
static WSResource newResourcetoWSResource(org.wso2.carbon.registry.core.Resource resource)
           
static WSComment RegistryCommenttoWSComment(org.wso2.carbon.registry.core.Comment comment)
           
static void setRegistryService(org.wso2.carbon.registry.core.service.RegistryService service)
           
static WSAssociation transformAssociationToWSAssociation(org.wso2.carbon.registry.core.Association asso)
           
static WSCollection transformCollectiontoWSCollection(org.wso2.carbon.registry.core.Collection collection, DataHandler dataHandler)
           
static WSLogEntry transformLogEntryToWSLogEntry(org.wso2.carbon.registry.core.LogEntry logEntry)
           
static WSResource transformResourceToWSResource(org.wso2.carbon.registry.core.Resource resource, DataHandler dataHandler)
           
static WSTag transformTagToWSTag(org.wso2.carbon.registry.core.Tag tag)
           
static org.wso2.carbon.registry.core.Collection transformWSCollectiontoCollection(WSResource wsCollection, Object content)
           
static org.wso2.carbon.registry.core.Resource transformWSResourcetoResource(WSResource wsResource, Object content)
           
static org.wso2.carbon.registry.core.Comment WSCommenttoRegistryComment(WSComment wsComment)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CommonUtil

public CommonUtil()
Method Detail

setRegistryService

public static void setRegistryService(org.wso2.carbon.registry.core.service.RegistryService service)

getRegistryService

public static org.wso2.carbon.registry.core.service.RegistryService getRegistryService()

createMap

public static Map createMap(String[] key,
                            String[] value)
                     throws org.wso2.carbon.registry.core.exceptions.RegistryException
Throws:
org.wso2.carbon.registry.core.exceptions.RegistryException

transformWSResourcetoResource

public static org.wso2.carbon.registry.core.Resource transformWSResourcetoResource(WSResource wsResource,
                                                                                   Object content)
                                                                            throws org.wso2.carbon.registry.core.exceptions.RegistryException
Throws:
org.wso2.carbon.registry.core.exceptions.RegistryException

transformWSCollectiontoCollection

public static org.wso2.carbon.registry.core.Collection transformWSCollectiontoCollection(WSResource wsCollection,
                                                                                         Object content)
                                                                                  throws org.wso2.carbon.registry.core.exceptions.RegistryException
Throws:
org.wso2.carbon.registry.core.exceptions.RegistryException

transformCollectiontoWSCollection

public static WSCollection transformCollectiontoWSCollection(org.wso2.carbon.registry.core.Collection collection,
                                                             DataHandler dataHandler)

transformResourceToWSResource

public static WSResource transformResourceToWSResource(org.wso2.carbon.registry.core.Resource resource,
                                                       DataHandler dataHandler)

makeBytesFromDataHandler

public static byte[] makeBytesFromDataHandler(WSResource wsResource)
                                       throws IOException
Throws:
IOException

makeDataHandler

public static DataHandler makeDataHandler(org.wso2.carbon.registry.core.Resource resource,
                                          File tempFile)
                                   throws IOException,
                                          org.wso2.carbon.registry.core.exceptions.RegistryException
Throws:
IOException
org.wso2.carbon.registry.core.exceptions.RegistryException

newResourcetoWSResource

public static WSResource newResourcetoWSResource(org.wso2.carbon.registry.core.Resource resource)

newCollectiontoWSCollection

public static WSCollection newCollectiontoWSCollection(org.wso2.carbon.registry.core.Collection collection)

exchangeTaggedResourcepath

public static WSTaggedResourcePath[] exchangeTaggedResourcepath(org.wso2.carbon.registry.core.TaggedResourcePath[] registry)

exchangeWSResourcePath

public static org.wso2.carbon.registry.core.TaggedResourcePath[] exchangeWSResourcePath(WSTaggedResourcePath[] wsrpath)

RegistryCommenttoWSComment

public static WSComment RegistryCommenttoWSComment(org.wso2.carbon.registry.core.Comment comment)

WSCommenttoRegistryComment

public static org.wso2.carbon.registry.core.Comment WSCommenttoRegistryComment(WSComment wsComment)

transformAssociationToWSAssociation

public static WSAssociation transformAssociationToWSAssociation(org.wso2.carbon.registry.core.Association asso)

transformLogEntryToWSLogEntry

public static WSLogEntry transformLogEntryToWSLogEntry(org.wso2.carbon.registry.core.LogEntry logEntry)

transformTagToWSTag

public static WSTag transformTagToWSTag(org.wso2.carbon.registry.core.Tag tag)


Copyright © 2012 WSO2 Inc. All Rights Reserved.