@Override public void run() { //暴露服务 export(new ComputeServiceImpl(), PORT); } }
protected void send ( ConnectionOrientedPdu request ) throws IOException { bind (); context.getConnection ().transmit ( request, getTransport () ); }
public void detach() throws IOException { bound = false; context = null; getTransport().close(); }
protected void attach () throws IOException { Endpoint endpoint = getEndpoint (); if ( endpoint != null ) return; String address = getAddress (); if ( address == null ) throw new RpcException ( "No address specified." ); setEndpoint ( getTransportFactory ().createTransport ( address, getProperties () ).attach ( new PresentationSyntax ( getSyntax () ) ) ); }
protected void detach() throws IOException { Endpoint endpoint = getEndpoint(); if (endpoint == null) return; try { endpoint.detach(); } finally { setEndpoint(null); } }
protected ConnectionOrientedPdu receive () throws IOException { return context.getConnection ().receive ( getTransport () ); }
public void send_gettimestamp(long mytimestamp) throws org.apache.thrift.TException { gettimestamp_args args = new gettimestamp_args(); args.setMytimestamp(mytimestamp); sendBase("gettimestamp", args); }
public void send_getID(String para) throws org.apache.thrift.TException { getID_args args = new getID_args(); args.setPara(para); sendBase("getID", args); }
public gettimestamp_result getResult(I iface, gettimestamp_args args) throws org.apache.thrift.TException { gettimestamp_result result = new gettimestamp_result(); result.success = iface.gettimestamp(args.mytimestamp); result.setSuccessIsSet(true); return result; } }
public getID_result getResult(I iface, getID_args args) throws org.apache.thrift.TException { getID_result result = new getID_result(); result.success = iface.getID(args.para); return result; } }
protected void attach() throws IOException { Endpoint endpoint = getEndpoint(); if (endpoint != null) return; String address = getAddress(); if (address == null) throw new RpcException("No address specified."); setEndpoint(getTransportFactory().createTransport(address, getProperties()).attach(new PresentationSyntax(getSyntax()))); }
protected void send(ConnectionOrientedPdu request) throws IOException { bind(); context.getConnection().transmit(request, getTransport()); }
protected void detach() throws IOException { Endpoint endpoint = getEndpoint(); if (endpoint == null) return; try { endpoint.detach(); } finally { setEndpoint(null); } }
protected ConnectionOrientedPdu receive() throws IOException { return context.getConnection().receive(getTransport()); }
public void detach () throws IOException { bound = false; context = null; getTransport ().close (); }
protected void attach() throws IOException { Endpoint endpoint = getEndpoint(); if (endpoint != null) return; String address = getAddress(); if (address == null) throw new RpcException("No address specified."); setEndpoint(getTransportFactory().createTransport(address, getProperties()).attach(new PresentationSyntax(getSyntax()))); }
protected void send(ConnectionOrientedPdu request) throws IOException { bind(); context.getConnection().transmit(request, getTransport()); }
protected void detach () throws IOException { Endpoint endpoint = getEndpoint (); if ( endpoint == null ) return; try { endpoint.detach (); } finally { setEndpoint ( null ); } }
protected ConnectionOrientedPdu receive() throws IOException { return context.getConnection().receive(getTransport()); }
public void detach() throws IOException { bound = false; context = null; getTransport().close(); }