public class WandoraPiccoloWebapiService extends java.lang.Object implements WandoraService_PortType
The org.wandora.webapi package contains all classes needed by the Wandora web api. The definition subpackage contains the defining classes. From these classes a wsdl document is created using the java2wsdl tool in Apache Axis. After that, stubs for server implementation can be created using the wsdl2java tool. These classes are in the implementation subpackage. The classes in definition subpackage aren't actually used for anything else than creating the server stubs, they aren't referenced anywhere in java code outside the definition subpackage.
All classes in implementation subpackage except this class are automatically created by the wsdl2java tool and will be overwritten if web api is changed and the stubs are created again. The deplay.wsdd is also automatically created and contains webservice definition for the Axis servlet. Contents of this file should be copied in the server-config.wsdd in WEB-INF directory of the web application.
This class contains the actual functionality for the Wandora web api. The Apache Axis servlet uses the automatically generated WandoraServiceSoapBindingImpl class which directly calls this class. Having all functionality in this class avoids the possibility of accidentally overwriting all the functionality with an automatically created stub class when web api is updated and the stubs are recreated.
If the web api needs to be updated, changes should be made to the classes in the definition subpackage. After that create the wsdl document and then the server stubs and place them in the implementation subpackage. Then WandoraServiceSoapBindingImpl class needs to be modified to call implementations in this class. Best way to do this is to have a private variable containing an instance of this class and which is initialized in the constructor. Then call the methods in that variable in each web api method.
To use Wandora Service, an Axis servlet must be started and configured to use the wandora web service. Also, this class needs the topic map that is used to retrieve all the information. This topic map is passed in a servlet context attribute with identifier "org.wandora.PiccoloWandoraTopicMap". This can be done in the piccoloconfig.xml file with following lines.
<servletcontext xp:id="servletcontext" xp:idref="servlet" xp:method="getServletContext"/>
<servletcontext xp:idref="servletcontext" xp:method="setAttribute">
<param>org.wandora.PiccoloWandoraTopicMap</param>
<param xp:idref="wandora" xp:method="getTopicMap"/>
</servletcontext>
Constructor and Description |
---|
WandoraPiccoloWebapiService()
Creates a new instance of WandoraPiccoloWebapiService
|
Modifier and Type | Method and Description |
---|---|
private java.lang.String |
getLanguageSI(Topic t) |
private java.lang.String |
getMinSI(Topic t) |
WSTopic |
getTopic(java.lang.String si,
boolean full) |
protected TopicMap |
getTopicMap() |
WSTopic[] |
getTopics(java.lang.String[] sis,
boolean full) |
WSTopic[] |
getTopicsOfType(java.lang.String in0,
boolean full) |
WSTopic |
getTopicWithBaseName(java.lang.String si,
boolean full) |
private WSTopic |
makeWSTopic(Topic t,
boolean full) |
private WSTopic[] |
makeWSTopics(java.util.Collection<Topic> ts,
boolean full) |
public WandoraPiccoloWebapiService()
protected TopicMap getTopicMap()
private WSTopic[] makeWSTopics(java.util.Collection<Topic> ts, boolean full) throws TopicMapException
TopicMapException
private java.lang.String getLanguageSI(Topic t) throws TopicMapException
TopicMapException
private java.lang.String getMinSI(Topic t) throws TopicMapException
TopicMapException
private WSTopic makeWSTopic(Topic t, boolean full) throws TopicMapException
TopicMapException
public WSTopic getTopic(java.lang.String si, boolean full) throws java.rmi.RemoteException
getTopic
in interface WandoraService_PortType
java.rmi.RemoteException
public WSTopic[] getTopics(java.lang.String[] sis, boolean full) throws java.rmi.RemoteException
getTopics
in interface WandoraService_PortType
java.rmi.RemoteException
public WSTopic getTopicWithBaseName(java.lang.String si, boolean full) throws java.rmi.RemoteException
getTopicWithBaseName
in interface WandoraService_PortType
java.rmi.RemoteException
public WSTopic[] getTopicsOfType(java.lang.String in0, boolean full) throws java.rmi.RemoteException
getTopicsOfType
in interface WandoraService_PortType
java.rmi.RemoteException
Copyright 2004-2015 Wandora Team