## Class soap_controller

zeep::http::soap_controller — class that helps with handling SOAP requests

## Synopsis

    // In header: <zeep/http/soap-controller.hpp>

    class soap_controller : public  {
    public:
      // member classes/structs/unions
      template<typename Callback,  >
      struct mount_point {
      };
      template<typename ControllerType, typename Result,  Args>
      struct mount_point<> : public  {
        // types
        typedef                                                         ;
        typedef  ;
        typedef                                                            ;

        // construct/copy/destruct
        (, soap_controller *, );
        template< Names>
          (, soap_controller *, , );

        // public member functions

        (xml::element > &,
                      );
        template< I>
           (xml::element > &,
                             , );
        template< I>
          xml::element
          (xml::element > &,
                       );
         (xml::element &, reply &, );
        template<typename ResultType, typename ArgsTuple,
                   = >
           (, reply &, );
        template<typename ResultType, typename ArgsTuple,
                   = >
           (, reply &, );
        template< I>
           (xml::element &,
                                      );
        template<typename T>  (xml::deserializer &, );

        (, , xml::element &, xml::element *);

        // public data members
        static  N;
         m_callback;
         m_names;
        xml::element m_responseType;
        xml::element,  m_parameterTypes;
      };

      struct mount_point_base {
        // construct/copy/destruct
        ();
        ~();

        // public member functions
         (xml::element &, reply &, ) = ;

        (xml::element > &,
                      ) = ;

        // public data members
         m_action;
      };
      // construct/copy/destruct
      (, );
      ~();

      // public member functions
       ();
       ();
      template<typename Callback,  ArgNames>
         (, , );
      xml::element ();
       (request &, reply &);
    };

## Description

This controller will handle SOAP requests automatically handing the packing and unpacking of XML envelopes.

To use this, create a subclass and add some methods that should be exposed. Then map these methods on a path that optionally contains parameter values.

See the chapter on SOAP controllers in the documention for more information.

### `soap_controller` public construct/copy/destruct

1.     ( prefix_path,  ns);

   constructor

   Parameters:

   `ns` | This is the XML Namespace for our SOAP calls
   `prefix_path` | This is the leading part of the request URI for each mount point

2.     ~();

### `soap_controller` public member functions

1.      ( location);

   Set the external address at which this service is visible.

2.      ( service);

   Set the service name.

3.     template<typename Callback,  ArgNames>
          ( actionName,  callback,
                          names);

   map a SOAP action to callback using names for mapping the arguments

   The method in callback should be a method of the derived class having as many arguments as the number of specified names.

4.     xml::element ();

   Create a WSDL based on the registered actions.

5.      (request & req, reply & reply);

   Handle the SOAP request.