zoukankan      html  css  js  c++  java
  • remoting 用app.config文件来配置

    <!--服务端配置-->
    <?xml version="1.0" encoding="utf-8" ?>
    <configuration>
      <system.runtime.remoting>
        <application>
          <service>
            <wellknown
              mode="Singleton"  
              type="DataObjSpace.DataObj,DataObj"
              objecturi="abc.soap"></wellknown>
          </service>
          <channels>
            <channel prot="1234" ref="tcp"></channel>
          </channels>
        </application>
      </system.runtime.remoting>
    </configuration>
    
    
    <!--客户端配置-->
    <?xml version="1.0" encoding="utf-8" ?>
    <configuration>
      <system.runtime.remoting>
        <application>
          <client>
            <wellknown type="DataObj,DataObj " url="tcp://200.1.3.27:1234/abc.soap"></wellknown>
          </client>
          <channels>
            <channel ref="tcp" prot="0"></channel>
          </channels>
        </application>
      </system.runtime.remoting>
    </configuration>
    ////service remoting code 
    RemotingConfiguration.Configure(@"ServiceRemoting.exe.config", false); 
    
    
    //// Client remoting code 
    
    RemotingConfiguration.Configure(@"ClientRemoting.exe.config", false);
    
    
    
    ////一句搞定。
  • 相关阅读:
    第二周c语言PTA作业留
    2018第零次作业
    总结报告
    第14/15周作业
    第七周作业
    第六周作业
    第四次作业
    第三次作业
    大学第二次作业
    大学的第一次作业
  • 原文地址:https://www.cnblogs.com/server126/p/2081659.html
Copyright © 2011-2022 走看看