masonfactoryservice.java
来自「使用eclipse集成GT4插件环境」· Java 代码 · 共 51 行
JAVA
51 行
package com.buu.grid.hzk.mason.impl;
import java.rmi.RemoteException;
import org.globus.wsrf.*;
import org.apache.axis.message.addressing.EndpointReferenceType;
import org.globus.wsrf.utils.AddressingUtils;
//import com.buu.grid.hzk.mason.stubs.*;
import com.buu.grid.hzk.mason.masonService.stubs.*;
import com.buu.grid.hzk.mason.impl.*;
import com.buu.grid.hzk.mason.Mason;
import org.globus.wsrf.impl.ResourceContextImpl;
public class MasonFactoryService {
/**
*
* @generated
*/
public CreateResourceResponse createResource(CreateResource request) throws RemoteException {
ResourceContext ctx = null;
MasonResourceHome home = null;
ResourceKey key = null;
try {
ctx = ResourceContext.getResourceContext();
ResourceContextImpl ctxi = (ResourceContextImpl)ctx;
ctxi.setService("MasonService");
home = (MasonResourceHome)ctx.getResourceHome();
key = home.create();
} catch (Exception e) {
e.printStackTrace();
throw new RemoteException("", e);
}
EndpointReferenceType epr = null;
try {
epr = AddressingUtils.createEndpointReference(ctx, key);
} catch (Exception e) {
throw new RemoteException("", e);
}
CreateResourceResponse response = new CreateResourceResponse();
response.setEndpointReference(epr);
return response;
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?