ws-scout-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ge...@apache.org
Subject svn commit: r153319 - webservices/scout/trunk/modules/scout/src/java/org/apache/ws/scout/util/ScoutUddiJaxrHelper.java
Date Fri, 11 Feb 2005 02:21:03 GMT
Author: geirm
Date: Thu Feb 10 18:21:00 2005
New Revision: 153319

URL: http://svn.apache.org/viewcvs?view=rev&rev=153319
Log:
Helper method to turn a jUDDI ServiceInfo into a JAXR Service

Modified:
    webservices/scout/trunk/modules/scout/src/java/org/apache/ws/scout/util/ScoutUddiJaxrHelper.java

Modified: webservices/scout/trunk/modules/scout/src/java/org/apache/ws/scout/util/ScoutUddiJaxrHelper.java
URL: http://svn.apache.org/viewcvs/webservices/scout/trunk/modules/scout/src/java/org/apache/ws/scout/util/ScoutUddiJaxrHelper.java?view=diff&r1=153318&r2=153319
==============================================================================
--- webservices/scout/trunk/modules/scout/src/java/org/apache/ws/scout/util/ScoutUddiJaxrHelper.java
(original)
+++ webservices/scout/trunk/modules/scout/src/java/org/apache/ws/scout/util/ScoutUddiJaxrHelper.java
Thu Feb 10 18:21:00 2005
@@ -24,6 +24,7 @@
 import org.apache.juddi.datatype.response.BusinessDetail;
 import org.apache.juddi.datatype.response.TModelDetail;
 import org.apache.juddi.datatype.response.TModelInfo;
+import org.apache.juddi.datatype.response.ServiceInfo;
 import org.apache.juddi.datatype.service.BusinessService;
 import org.apache.juddi.datatype.service.BusinessServices;
 import org.apache.juddi.datatype.tmodel.TModel;
@@ -183,6 +184,25 @@
         Description desc = (Description)descvect.elementAt(0);
         serve.setDescription(lcm.createInternationalString(desc.getValue()));
         return serve;
+    }
+
+    public static Service getService(ServiceInfo si, LifeCycleManager lcm)
+        throws JAXRException
+    {
+        Service service = new ServiceImpl(lcm);
+
+        String keystr = si.getServiceKey();
+
+        if (keystr != null) {
+            service.setKey(lcm.createKey(keystr));
+        }
+
+        Vector namevect = si.getNameVector();
+        Name n = (Name)namevect.elementAt(0);
+        String name = n.getValue() ;
+        service.setName(lcm.createInternationalString(name));
+
+        return service;
     }
 
     public static Concept getConcept(TModelDetail tm, LifeCycleManager lcm)



---------------------------------------------------------------------
To unsubscribe, e-mail: scout-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: scout-dev-help@ws.apache.org


Mime
View raw message