11 #ifndef ASIO_DETAIL_WINRT_RESOLVER_SERVICE_HPP 12 #define ASIO_DETAIL_WINRT_RESOLVER_SERVICE_HPP 14 #if defined(_MSC_VER) && (_MSC_VER >= 1200) 16 #endif // defined(_MSC_VER) && (_MSC_VER >= 1200) 20 #if defined(ASIO_WINDOWS_RUNTIME) 36 template <
typename Protocol>
37 class winrt_resolver_service
46 typedef typename Protocol::endpoint endpoint_type;
57 async_manager_(
use_service<winrt_async_manager>(io_service))
62 ~winrt_resolver_service()
67 void shutdown_service()
77 void construct(implementation_type&)
82 void destroy(implementation_type&)
87 void cancel(implementation_type&)
92 iterator_type resolve(implementation_type&,
97 using namespace Windows::Networking::Sockets;
98 auto endpoint_pairs = async_manager_.sync(
99 DatagramSocket::GetEndpointPairsAsync(
101 winrt_utils::string(query.service_name())), ec);
104 return iterator_type();
106 return iterator_type::create(
107 endpoint_pairs, query.hints(),
108 query.host_name(), query.service_name());
110 catch (Platform::Exception^
e)
114 return iterator_type();
119 template <
typename Handler>
120 void async_resolve(implementation_type&,
121 const query_type& query, Handler& handler)
127 typedef winrt_resolve_op<Protocol, Handler> op;
128 typename op::ptr p = { asio::detail::addressof(handler),
130 sizeof(op), handler), 0 };
131 p.p =
new (p.v) op(query, handler);
137 using namespace Windows::Networking::Sockets;
138 async_manager_.async(DatagramSocket::GetEndpointPairsAsync(
140 winrt_utils::string(query.service_name())), p.p);
143 catch (Platform::Exception^
e)
147 io_service_.post_immediate_completion(p.p, is_continuation);
153 iterator_type resolve(implementation_type&,
157 return iterator_type();
161 template <
typename Handler>
162 void async_resolve(implementation_type&,
163 const endpoint_type&, Handler& handler)
166 const iterator_type iterator;
167 io_service_.get_io_service().post(
173 winrt_async_manager& async_manager_;
181 #endif // defined(ASIO_WINDOWS_RUNTIME) 183 #endif // ASIO_DETAIL_WINRT_RESOLVER_SERVICE_HPP
shared_ptr< void > shared_cancel_token_type
Provides core I/O functionality.
pylon Camera Software Suite for Linux for Use with Basler Gigabit the pylon Viewer and the IP Configurator applications might not be available System I340 and I350 series Although the pylon software will work with any GigE network we would recommend to use one of these adapters USB For U3V devices a USB3 capable USB controller is necessary For best performance and stability we highly recommend a kernel the following settings should be i e
Service & use_service(io_service &ios)
class task_io_service io_service_impl
fork_event
Fork-related event notifications.
bool is_continuation(Context &context)
Class to represent an error code value.
ASIO_DECL std::string host_name()
Get the current host name.
void * allocate(std::size_t s, Handler &h)
binder1< Handler, Arg1 > bind_handler(Handler handler, const Arg1 &arg1)
#define ASIO_HANDLER_CREATION(args)
ASIO_DECL const error_category & system_category()
Returns the error category used for the system errors produced by asio.