Package org.uengine.kernel

Examples of org.uengine.kernel.ServiceDefinition


      fd = getFieldDescriptor("Role");   
      fd.setInputter(new RoleInput(pd, RoleInput.WEBSERVICE_ONLY){
        public void onValueChanged(){
          Role role = (Role)getValue();
          ServiceDefinition svcdef = (ServiceDefinition)role.getServiceType();
          serviceDefinitionInputter.setValue(svcdef);
          portTypeInputter.setServiceDefinition(svcdef);         
        }
      });
View Full Code Here


  public static void generateStubCommand(ProcessDefinition definition) throws Exception{   
    Properties command = new Properties();
    command.setProperty("wsdlLocations.length", ""+definition.getServiceDefinitions().length);
   
    for(int i=0; i<definition.getServiceDefinitions().length; i++){
      ServiceDefinition sd = definition.getServiceDefinitions()[i];
      command.setProperty("wsdlLocation" + i, sd.getWsdlLocation());
      command.setProperty("name" + i, ""+sd.getName());
    }
   
    command.store(new FileOutputStream(COMMAND_FILE), "");
  }
View Full Code Here

      JPanel panel = new JPanel(new BorderLayout());
      JButton btn = new JButton("Generate");
      btn.addActionListener(new ActionListener(){
        public void actionPerformed(ActionEvent ae){
          try{                       
            ServiceDefinition tempSvcDef = (ServiceDefinition)((ObjectInstance)((DefaultApplication)getApplication()).getSelectedRecord()).getObject();
            tempSvcDef.generateStub();
            setValue(tempSvcDef.getStubPackage());         
          }catch(Exception e){
            e.printStackTrace();
          }
        }
      });     
View Full Code Here

    if(portTypeInputter!=null)
    cb.addItemListener(new ItemListener(){
      public void itemStateChanged(ItemEvent e){
        if(e.getStateChange()!=ItemEvent.SELECTED) return;
        ServiceDefinition svcdef = (ServiceDefinition)getValue();
       
        portTypeInputter.setServiceDefinition(svcdef);       
      }
    });      
   
View Full Code Here

  public Object convert(Object src, java.util.Hashtable keyedContext) throws Exception{
    ReceiveActivity srcAct = (ReceiveActivity)src;
    WebServiceActivity destAct = new WebServiceActivity();
    Role role = (Role)keyedContext.get("role");   
    Role myRole = (Role)keyedContext.get(ProcessDefinitionAdapter.MY_ROLE);   
    ServiceDefinition serviceDefinition = (ServiceDefinition)keyedContext.get(ProcessDefinitionAdapter.MY_SVC_DEF);   
    if(srcAct.getFromRole()==null || !srcAct.getFromRole().equals(role)) return null;

    try{
      String msgName = srcAct.getMessageDefinition().getName();
      destAct.setPortType(myRole.getName());
View Full Code Here

  public Object convert(Object src, java.util.Hashtable keyedContext) throws Exception{
    ProcessDefinition srcProc = (ProcessDefinition)src;
    ProcessDefinition dstProc = new ProcessDefinition();
    Role role = (Role)keyedContext.get("role");   
   
    ServiceDefinition mySvcDef = new ServiceDefinition();
   
    //review: ProcessDefinition need WSDL location field if once exposed as a Web service
    String srcProcName = srcProc.getName().getText().replace(' ', '_');
    mySvcDef.setName(srcProcName);
    mySvcDef.setWsdlLocation("http://localhost:8082/axis/services/" + srcProcName );
    mySvcDef.setStubPackage("org.uengine");   
    dstProc.setServiceDefinitions(new ServiceDefinition[]{mySvcDef});
 
    Role myRole = new Role();
    //review: seems occur namespace collision
    myRole.setName(srcProcName);
    myRole.setServiceType(mySvcDef);
    dstProc.setRoles(new Role[]{myRole});
    dstProc.setName(role.getName());
   
    MessageDefinition message = new MessageDefinition();
    ServiceDefinition svcDef = role.getServiceType();   
//    Definition wsdlDef = svcDef.getDefinition();
   
//    keyedContext.put(WSDL_DEF, wsdlDef); 
    keyedContext.put(DEST_PROC, dstProc)
    keyedContext.put(MSG_DEFS, new ExclusiveList());
View Full Code Here

TOP

Related Classes of org.uengine.kernel.ServiceDefinition

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.