zoukankan      html  css  js  c++  java
  • WCF configuration file

    WCF configuration file

     

    The configuration file in the host application follows the same format as the configuration file in the client application. There is a <bindings> section where the bindings are defined and a <service> section in which the endpoints (addresses and bindings) are defined.

     

    When defining endpoints in a configuration file the service name should be in the format of NAMESPACE.CLASSNAME, and the endpoint contract name should be in the format of NAMESPACE.INTERFACECLASS.

     

    In the preceding example, the service namespace is WCFService with a class name of ServiceClass, and the interface is named IServiceClass. Therefore the service and endpoints are defined in the configuration file as the following:

     

    <service name =”WCFService.ServiceClass”>

    <endpoint contract =”WCFService.IServiceClass”

    name=”NetTcpBinding_IServiceClass”

    binding =”netTcpBinding”

    address =”net.tcp://localhost:8000/TcpBinding”/>

    <endpoint contract =”WCFService.IServiceClass”

    name=”netNamedPipeBinding_IServiceClass”

    binding =”netNamedPipeBinding”

    address =”net.pipe://localhost/NetNamedPipeBinding”/>

    </service>

     

     

     

  • 相关阅读:
    C
    B
    D
    I
    B
    E
    B
    L
    H
    bzoj3276磁力 两种要求下的最大值:分块or线段树+拓扑
  • 原文地址:https://www.cnblogs.com/rickie/p/1050449.html
Copyright © 2011-2022 走看看