Go to the Host object from the endpoint object RRS feed

  • Question

  • I am in 

    public void ExportEndpoint(WsdlExporter exporter, WsdlEndpointConversionContext context)

    trying to get a reference to the service type, so I can examine attributes on the service type and make minor corrections to the exported WSDL. I have access to the Endpoint object that gives me access to the ContractType, but what I really need is the type of the service, not the contract. I know that the type of the service is available from Host.Description.ServiceType, but I don't know how to get from Endpoint to Host.

    Can you help? Thank you.

    Evgueni Tsygankov
    Friday, March 25, 2011 9:52 PM


  • There's no link from the ServiceEndpoint object to the ServiceDescription object (only the other way around). If you control the place where the endpoint or behavior is being added, you may want to pass the service description to your behavior and use that reference from there.
    • Marked as answer by Popsovy Monday, March 28, 2011 1:53 PM
    Friday, March 25, 2011 10:15 PM