Function type R (T1, T2, ..., TN)boost::signals2::optional_last_value<R>intstd::less<Group>boost::function<Signature>boost::function<R (const connection &, T1, T2, ..., TN)>boost::signals2::mutexboost::signals2::signal_baseSafe multicast callback.
See the tutorial
for more information on how to use the signal class.
Signaturetypename Combiner::result_typeCombinerGroupGroupCompareSlotFunctiontypename signals2::slot<Signature, SlotFunction>ExtendedSlotFunctiontypename signals2::slot<R (const connection &, T1, ..., TN), ExtendedSlotFunction>Slots of the extended_slot_type may be connected to the signal using the
connect_extended methods. The extended_slot_type
has an additional signals2::connection argument in its signature,
which gives slot functions access to their connection to the signal
invoking them.
typename SlotFunction::result_type
This is the type returned when dereferencing the input iterators passed to the signal's
combiner.
unspecified
The input iterator type passed to the combiner when the signal is invoked.
T1Exists iff arity == 1T1Exists iff arity == 2T2Exists iff arity == 2unsignedTnThe type of the signal's (n+1)th argumentintNThe number of arguments taken by the signal.const combiner_type&combiner_type()const group_compare_type&group_compare_type()Initializes the signal to contain no slots, copies the given combiner into internal storage, and stores the given group comparison function object to compare groups.this->empty()signal &&Move constructor.The signal other
is in a "moved-from" state where it may only be destroyed, swapped, or move assigned.
Any other operation on a "moved-from" signal is invalid.Will not throw.signal &&Move assignment.The signal rhs
is in a "moved-from" state where it may only be destroyed, swapped, or move assigned.
Any other operation on a "moved-from" signal is invalid.Will not throw.connectionconst slot_type&connect_positionat_backconnectionconst group_type&const slot_type&connect_positionat_backConnects the signal this to the incoming
slot. If the slot is inactive, i.e., any of the slots's tracked
objects have been destroyed, then the
call to connect is a no-op. If the second version of
connect is invoked, the
slot is associated with the given group. The at
parameter specifies where the slot should be connected:
at_front indicates that the slot will be
connected at the front of the list or group of slots and
at_back indicates that the slot will be
connected at the back of the list or group of
slots.A
signals2::connection
object that references the newly-created connection between
the signal and the slot; if the slot is inactive, returns a
disconnected connection.This routine meets the strong exception guarantee,
where any exception thrown will cause the slot to not be
connected to the signal.Constant time when connecting a slot
without a group name or logarithmic in the number of groups
when connecting to a particular
group.It is unspecified whether connecting a slot while the
signal is calling will result in the slot being called
immediately.connectionconst extended_slot_type&connect_positionat_backconnectionconst group_type&const extended_slot_type&connect_positionat_back
The connect_extended methods work the same as the connect
methods, except they take slots of type extended_slot_type.
This is useful if a slot needs to access the connection between it and the
signal invoking it, for example if it wishes to disconnect or block its own connection.
voidconst group_type&voidconst S&If the parameter is (convertible to) a
group name, any slots in the given group are
disconnected. Otherwise, any slots equal to the
given slot function
are disconnected.
Note, the slot_func
argument should not be an actual signals2::slot
object (which does not even support operator==), but rather
the functor you wrapped inside a signals2::slot
when you initially made the connection.
Will not throw unless a user destructor or
equality operator == throws. If either throws,
not all slots may be disconnected.If a group is given, O(lg g) + k where
g is the number of groups in the signal and k is the
number of slots in the group. Otherwise, linear in the
number of slots connected to the
signal.voidDisconnects all slots connected to the signal.this->empty().If disconnecting a slot causes an exception to be
thrown, not all slots may be disconnected.Linear in the number of slots known to the
signal.May be called at any time within the lifetime of the
signal, including during calls to the signal's slots.booltrue if no slots
are connected to the signal, and
false otherwise.Will not throw.Linear in the number of slots known to the
signal.Slots can disconnect at any point in time,
including while those same slots are being invoked. It is
therefore possible that the implementation must search
through a list of disconnected slots to determine if any
slots are still connected.std::size_tThe number of slots connected to the signalWill not throw.Linear in the number of slots known to the
signal.Slots can disconnect at any point in time,
including while those same slots are being invoked. It is
therefore possible that the implementation must search
through a list of disconnected slots to determine how many
slots are still connected.result_typearg<0>::typearg<1>::type...arg<N-1>::typeresult_typearg<0>::typearg<1>::type...arg<N-1>::typeInvokes the combiner with a
slot_call_iterator range
[first, last) corresponding to the sequence of calls to the
slots connected to signal
*this. Dereferencing an
iterator in this range causes a slot call with the given set
of parameters (a1, a2, ...,
aN), the result of which is returned from
the iterator dereference operation.The result returned by the combiner.If an exception is thrown by a slot call, or if the
combiner does not dereference any slot past some given slot,
all slots after that slot in the internal list of connected
slots will not be invoked.Only the slots associated with iterators that are
actually dereferenced will be invoked. Multiple dereferences
of the same iterator will not result in multiple slot
invocations, because the return value of the slot will be
cached.The const version of
the function call operator will invoke the combiner as
const, whereas the
non-const version will
invoke the combiner as
non-const.combiner_typeA copy of the stored combiner.Will not throw.voidconst combiner_type&Copies a new combiner into the signal for use with
future signal invocations.Will not throw.voidsignal&Swaps the signal referenced in
this and
other.Will not throw.voidsignal<Signature, Combiner, Group, GroupCompare, SlotFunction, ExtendedSlotFunction, Mutex>&signal<Signature, Combiner, Group, GroupCompare, SlotFunction, ExtendedSlotFunction, Mutex>&x.swap(y)Will not throw.