class Exceptionate
Defined at line 33 of file ../../zircon/kernel/object/include/object/exceptionate.h
Kernel-owned exception channel endpoint.
This class is thread-safe, does not require external synchronization.
Note: Not marked `final` because `JobDispatcher::DebugExceptionate` inherits from it.
Public Methods
void Exceptionate (uint32_t type)
|type| must be a valid ZX_EXCEPTION_CHANNEL_TYPE_* constant.
Defined at line 36 of file ../../zircon/kernel/object/include/object/exceptionate.h
void ~Exceptionate ()
Shuts the underlying channel down if it's still connected to be sure the
userspace endpoint gets the PEER_CLOSED signal.
In most cases the task wants to manually shutdown the exceptionate when
transitioning to a dead state, but in some cases tasks can be destroyed
without registering the dead state e.g. childless jobs.
Defined at line 44 of file ../../zircon/kernel/object/include/object/exceptionate.h
void Exceptionate (const Exceptionate & )
Defined at line 46 of file ../../zircon/kernel/object/include/object/exceptionate.h
Exceptionate & operator= (const Exceptionate & )
Defined at line 47 of file ../../zircon/kernel/object/include/object/exceptionate.h
void Exceptionate (Exceptionate && )
Defined at line 48 of file ../../zircon/kernel/object/include/object/exceptionate.h
Exceptionate & operator= (Exceptionate && )
Defined at line 49 of file ../../zircon/kernel/object/include/object/exceptionate.h
zx_status_t SetChannel (KernelHandle<ChannelDispatcher>channel_handle,zx_rights_tthread_rights,zx_rights_tprocess_rights)
Sets the backing ChannelDispatcher endpoint.
The exception channel is first-come-first-served, so if there is
already a valid channel in place (i.e. has a live peer) this will
fail.
The |*_rights| arguments give the rights to assign to task handles
provided through this exception channel. A value of 0 indicates that
the handle should not be made available through this channel.
Returns:
ZX_ERR_INVALID_ARGS if |channel_handle| is null.
ZX_ERR_ALREADY_BOUND if there is already a valid channel.
ZX_ERR_BAD_STATE if Shutdown() has already been called.
Defined at line 65 of file ../../zircon/kernel/object/include/object/exceptionate.h
void Shutdown ()
Removes any exception channel, which will signal PEER_CLOSED for the
userspace endpoint.
Any further attempt to set a new channel will return ZX_ERR_BAD_STATE.
Defined at line 74 of file ../../zircon/kernel/object/include/object/exceptionate.h
bool HasValidChannel ()
Returns true if the channel exists and has a valid userspace peer.
Defined at line 77 of file ../../zircon/kernel/object/include/object/exceptionate.h