// The Construct // // Copyright (C) The Construct Developers, Authors & Contributors // Copyright (C) 2016-2020 Jason Volk // // Permission to use, copy, modify, and/or distribute this software for any // purpose with or without fee is hereby granted, provided that the above // copyright notice and this permission notice is present in all copies. The // full license for this software is available in the LICENSE file. #pragma once #define HAVE_IRCD_IOS_DISPATCH_H namespace ircd::ios { IRCD_OVERLOAD(synchronous) struct dispatch; struct defer; struct post; } namespace ircd { using ios::dispatch; using ios::defer; using ios::post; } struct ircd::ios::dispatch { dispatch(descriptor &, std::function); dispatch(descriptor &, synchronous_t, const std::function &); dispatch(descriptor &, synchronous_t); dispatch(std::function); dispatch(synchronous_t, const std::function &); }; struct ircd::ios::defer { defer(descriptor &, std::function); defer(descriptor &, synchronous_t, const std::function &); defer(descriptor &, synchronous_t); defer(std::function); defer(synchronous_t, const std::function &); }; struct ircd::ios::post { post(descriptor &, std::function); post(descriptor &, synchronous_t, const std::function &); post(descriptor &, synchronous_t); post(std::function); post(synchronous_t, const std::function &); };