1 19 20 package org.netbeans.modules.websvc.core.jaxws.actions; 21 22 import org.netbeans.modules.websvc.core._RetoucheUtil; 23 import org.netbeans.modules.websvc.core.AddWsOperationHelper; 24 import org.netbeans.modules.websvc.core.AddOperationCookie; 25 import org.openide.filesystems.FileObject; 26 import java.io.IOException ; 27 import static org.netbeans.api.java.source.JavaSource.Phase; 28 import org.openide.ErrorManager; 29 import org.openide.filesystems.FileObject; 30 import org.openide.util.NbBundle; 31 32 37 public class JaxWsAddOperation implements AddOperationCookie { 38 39 private FileObject implClassFo; 40 41 42 public JaxWsAddOperation(FileObject implClassFo) { 43 this.implClassFo=implClassFo; 44 } 45 46 public void addOperation(FileObject implementationClass) { 47 AddWsOperationHelper strategy = new AddWsOperationHelper( 48 NbBundle.getMessage(AddWsOperationHelper.class, "LBL_OperationAction")); 49 try { 50 String className = _RetoucheUtil.getMainClassName(implementationClass); 51 if (className != null) { 52 strategy.addMethod(implementationClass, className); 53 } 54 } catch (IOException ex) { 55 ErrorManager.getDefault().notify(ex); 56 } 57 } 58 59 } 60 | Popular Tags |