当前位置: 首页 > news >正文

用word怎么做首页网站通城网站建设

用word怎么做首页网站,通城网站建设,毕设网站代做一般预算多少钱,展览搭建设计网站当我们使用Thrift 通信的时候#xff0c;服务端有时候需要注册多个类#xff0c;去实现通信#xff0c;这时候我们就不能再使用单一Processor的方式#xff0c;就要使用多个Processor#xff0c;那么如何去实现呢#xff1f; 多个Process 服务端 public static void m…当我们使用Thrift 通信的时候服务端有时候需要注册多个类去实现通信这时候我们就不能再使用单一Processor的方式就要使用多个Processor那么如何去实现呢 多个Process 服务端 public static void main(String[] args) {try {AImpl aService new AImpl();BImpl bServicenew BImpl();TMultiplexedProcessor multiplexedProcessor new TMultiplexedProcessor();AService.ProcessorAImpl aProcessor new AService.Processor(aService);multiplexedProcessor.registerProcessor(aService, aProcessor);BService.ProcessorBImpl bProcessor new BService.Processor(bService);multiplexedProcessor.registerProcessor(bService, bProcessor);TServerSocket serverTransport new TServerSocket(80000);TThreadPoolServer.Args serverArgs new TThreadPoolServer.Args(serverTransport);serverArgs.processor(multiplexedProcessor);TServer server new TThreadPoolServer(serverArgs);System.out.println(Starting the multi-processor server...);server.serve();} catch (Exception e) {e.printStackTrace();System.out.println(e.getMessage());}}客户端 public static void main(String[] args) throws TException {TTransport transport new TSocket(localhost, 80000);transport.open();// AServiceTMultiplexedProtocol multiplexedProtocol new TMultiplexedProtocol(new TBinaryProtocol(transport), aService);AService.Client aClient new AService.Client(multiplexedProtocol);aClient.method();System.out.println(Calling AService method...);// BServicemultiplexedProtocol new TMultiplexedProtocol(new TBinaryProtocol(transport), bService);BService.Client bClient new BService.Client(multiplexedProtocol);BClient.method();System.out.println(Calling SystemLogService method...);transport.close();}这个Demo中我们要用到两个接口类那么A和B使用TMultiplexedProcessor 去注册两个Service启动服务。 单个Process 服务端 AImpl aService new AImpl();TServerSocket serverSocket new TServerSocket(90000);AService.ProcessorAImpl aProcessor new AService.Processor(aService);TThreadPoolServer.Args serverArg new TThreadPoolServer.Args(serverSocket);serverArg.processor(aProcessor);TThreadPoolServer server new TThreadPoolServer(serverArg);server.serve();客户端 TTransport transport new TSocket(localhost, 90000);transport.open();TBinaryProtocol protocol new TBinaryProtocol(transport);AService.Client aClient new AService.Client(protocol);aclient.method();附单个process的方式。
http://www.dnsts.com.cn/news/32154.html

相关文章:

  • 做网站的叫什么职位网站建设好学么
  • 网站常见错误代码天津高端网站设计公司
  • 足球哪个网站做的比较好怎么做网站优化 site
  • 建设局查询网站首页wordpress获取广告js
  • 班级网站建设需求分析网站建设视频技术论坛
  • 我要自学网做网站软件开发文档编制
  • 电子商城网站开发购物车竞价网站制作
  • 凡科网建站系统源码中国空间网站
  • 长沙租车网站排名宁波高端网站建设
  • 北京网站优化企业推荐股票的好网站
  • seo网站推广教程新公司如何做网站
  • kuler 网站跳转网站正在建设中
  • 合肥做网站哪家好网站外部链接怎么做
  • 谷歌推广费用多少优化大师下载安装免费
  • 沧州做网站优化哪家公司便宜上海紫博蓝网站
  • 网站转移码php旅游网站cms
  • 电子商务网站建设实训报告心得网站跳出率多少正常
  • 杭州专业的网站制作公司开公司需要多少钱
  • 怎么样自己制作网站google在线网页代理
  • 个人网站的首页wordpress 管理系统
  • 外贸建站深圳抖音seo搜索优化
  • 企业网站源码 vue手机端网站seo
  • 一起做业官方网站wordpress邮箱注册功能
  • 网站名称和备案公司名称不一样前端毕业设计题目可以做哪些
  • 交易平台网站开发教程百度云做文案的网站有些什么软件
  • 石龙镇住房规划建设局网站网站开发的过程步骤
  • 做胃镜多少钱那好天津津门网站a网站的流程图
  • 新网站建设脑图甘肃网站开发
  • 瑞安做网站的公司班级网站 模板
  • 对亚马逊网站做简要分析与评价贵阳网站开发制作公司