}
public static Resource transformWSResourcetoResource(WSRegistryServiceClient client, WSResource wsResource, Object content)throws RegistryException {
ResourceImpl resource = null;
if (wsResource instanceof WSCollection) {
resource = new OnDemandContentCollectionImpl(client);
} else {
resource = new OnDemandContentResourceImpl(client);
}
if (wsResource.getDescription() != null) resource.setDescription(wsResource.getDescription());