#![warn(clippy::all)]
#![allow(unused_parens, unused_mut, unused_imports, nonstandard_style)]
use bitflags::bitflags;
use fidl::client::QueryResponseFut;
use fidl::encoding::{MessageBufFor, ProxyChannelBox, ResourceDialect};
use fidl::endpoints::{ControlHandle as _, Responder as _};
use futures::future::{self, MaybeDone, TryFutureExt};
use zx_status;
pub const CLIENT_SUITE_VERSION: u64 = 1;
#[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
#[repr(u32)]
pub enum FidlErrorKind {
OtherError = 1,
DecodingError = 2,
ChannelPeerClosed = 3,
UnknownMethod = 4,
UnexpectedMessage = 5,
}
impl FidlErrorKind {
#[inline]
pub fn from_primitive(prim: u32) -> Option<Self> {
match prim {
1 => Some(Self::OtherError),
2 => Some(Self::DecodingError),
3 => Some(Self::ChannelPeerClosed),
4 => Some(Self::UnknownMethod),
5 => Some(Self::UnexpectedMessage),
_ => None,
}
}
#[inline]
pub const fn into_primitive(self) -> u32 {
self as u32
}
#[deprecated = "Strict enums should not use `is_unknown`"]
#[inline]
pub fn is_unknown(&self) -> bool {
false
}
}
#[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
#[repr(u32)]
pub enum IoStyle {
Sync = 1,
Async = 2,
}
impl IoStyle {
#[inline]
pub fn from_primitive(prim: u32) -> Option<Self> {
match prim {
1 => Some(Self::Sync),
2 => Some(Self::Async),
_ => None,
}
}
#[inline]
pub const fn into_primitive(self) -> u32 {
self as u32
}
#[deprecated = "Strict enums should not use `is_unknown`"]
#[inline]
pub fn is_unknown(&self) -> bool {
false
}
}
#[derive(Copy, Clone, Debug, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub enum Test {
Setup,
TwoWayNoPayload,
TwoWayStructPayload,
TwoWayTablePayload,
TwoWayUnionPayload,
TwoWayResultWithPayload,
TwoWayResultWithError,
TwoWayStructRequest,
TwoWayTableRequest,
TwoWayUnionRequest,
OneWayNoRequest,
OneWayStructRequest,
OneWayTableRequest,
OneWayUnionRequest,
ReceiveEventNoPayload,
ReceiveEventStructPayload,
ReceiveEventTablePayload,
ReceiveEventUnionPayload,
GracefulFailureDuringCallAfterPeerClose,
ReceiveEventBadMagicNumber,
ReceiveEventUnexpectedTxid,
ReceiveEventUnknownOrdinal,
ReceiveResponseBadMagicNumber,
ReceiveResponseUnexpectedTxid,
ReceiveResponseWrongOrdinalKnown,
ReceiveResponseWrongOrdinalUnknown,
V1TwoWayNoPayload,
V1TwoWayStructPayload,
OneWayCallDoNotReportPeerClosed,
OneWayStrictSend,
OneWayFlexibleSend,
TwoWayStrictSend,
TwoWayStrictSendMismatchedStrictness,
TwoWayStrictSendNonEmptyPayload,
TwoWayStrictErrorSyntaxSendSuccessResponse,
TwoWayStrictErrorSyntaxSendErrorResponse,
TwoWayStrictErrorSyntaxSendUnknownMethodResponse,
TwoWayStrictErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse,
TwoWayStrictErrorSyntaxSendNonEmptyPayload,
TwoWayFlexibleSendSuccessResponse,
TwoWayFlexibleSendErrorResponse,
TwoWayFlexibleSendUnknownMethodResponse,
TwoWayFlexibleSendMismatchedStrictnessUnknownMethodResponse,
TwoWayFlexibleSendOtherFrameworkErrResponse,
TwoWayFlexibleSendNonEmptyPayloadSuccessResponse,
TwoWayFlexibleSendNonEmptyPayloadUnknownMethodResponse,
TwoWayFlexibleErrorSyntaxSendSuccessResponse,
TwoWayFlexibleErrorSyntaxSendErrorResponse,
TwoWayFlexibleErrorSyntaxSendUnknownMethodResponse,
TwoWayFlexibleErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse,
TwoWayFlexibleErrorSyntaxSendOtherFrameworkErrResponse,
TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadSuccessResponse,
TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadUnknownMethodResponse,
ReceiveStrictEvent,
ReceiveStrictEventMismatchedStrictness,
ReceiveFlexibleEvent,
ReceiveFlexibleEventMismatchedStrictness,
UnknownStrictEventOpenProtocol,
UnknownFlexibleEventOpenProtocol,
UnknownStrictEventAjarProtocol,
UnknownFlexibleEventAjarProtocol,
UnknownStrictEventClosedProtocol,
UnknownFlexibleEventClosedProtocol,
UnknownStrictServerInitiatedTwoWay,
UnknownFlexibleServerInitiatedTwoWay,
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u32,
},
}
#[macro_export]
macro_rules! TestUnknown {
() => {
_
};
}
impl Test {
#[inline]
pub fn from_primitive(prim: u32) -> Option<Self> {
match prim {
1 => Some(Self::Setup),
2 => Some(Self::TwoWayNoPayload),
42 => Some(Self::TwoWayStructPayload),
43 => Some(Self::TwoWayTablePayload),
44 => Some(Self::TwoWayUnionPayload),
45 => Some(Self::TwoWayResultWithPayload),
46 => Some(Self::TwoWayResultWithError),
52 => Some(Self::TwoWayStructRequest),
53 => Some(Self::TwoWayTableRequest),
54 => Some(Self::TwoWayUnionRequest),
48 => Some(Self::OneWayNoRequest),
49 => Some(Self::OneWayStructRequest),
50 => Some(Self::OneWayTableRequest),
51 => Some(Self::OneWayUnionRequest),
55 => Some(Self::ReceiveEventNoPayload),
56 => Some(Self::ReceiveEventStructPayload),
57 => Some(Self::ReceiveEventTablePayload),
58 => Some(Self::ReceiveEventUnionPayload),
3 => Some(Self::GracefulFailureDuringCallAfterPeerClose),
60 => Some(Self::ReceiveEventBadMagicNumber),
61 => Some(Self::ReceiveEventUnexpectedTxid),
62 => Some(Self::ReceiveEventUnknownOrdinal),
63 => Some(Self::ReceiveResponseBadMagicNumber),
64 => Some(Self::ReceiveResponseUnexpectedTxid),
65 => Some(Self::ReceiveResponseWrongOrdinalKnown),
67 => Some(Self::ReceiveResponseWrongOrdinalUnknown),
40 => Some(Self::V1TwoWayNoPayload),
41 => Some(Self::V1TwoWayStructPayload),
59 => Some(Self::OneWayCallDoNotReportPeerClosed),
4 => Some(Self::OneWayStrictSend),
5 => Some(Self::OneWayFlexibleSend),
6 => Some(Self::TwoWayStrictSend),
7 => Some(Self::TwoWayStrictSendMismatchedStrictness),
38 => Some(Self::TwoWayStrictSendNonEmptyPayload),
8 => Some(Self::TwoWayStrictErrorSyntaxSendSuccessResponse),
9 => Some(Self::TwoWayStrictErrorSyntaxSendErrorResponse),
10 => Some(Self::TwoWayStrictErrorSyntaxSendUnknownMethodResponse),
11 => Some(Self::TwoWayStrictErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse),
39 => Some(Self::TwoWayStrictErrorSyntaxSendNonEmptyPayload),
12 => Some(Self::TwoWayFlexibleSendSuccessResponse),
13 => Some(Self::TwoWayFlexibleSendErrorResponse),
14 => Some(Self::TwoWayFlexibleSendUnknownMethodResponse),
15 => Some(Self::TwoWayFlexibleSendMismatchedStrictnessUnknownMethodResponse),
16 => Some(Self::TwoWayFlexibleSendOtherFrameworkErrResponse),
17 => Some(Self::TwoWayFlexibleSendNonEmptyPayloadSuccessResponse),
18 => Some(Self::TwoWayFlexibleSendNonEmptyPayloadUnknownMethodResponse),
19 => Some(Self::TwoWayFlexibleErrorSyntaxSendSuccessResponse),
20 => Some(Self::TwoWayFlexibleErrorSyntaxSendErrorResponse),
21 => Some(Self::TwoWayFlexibleErrorSyntaxSendUnknownMethodResponse),
22 => {
Some(Self::TwoWayFlexibleErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse)
}
23 => Some(Self::TwoWayFlexibleErrorSyntaxSendOtherFrameworkErrResponse),
24 => Some(Self::TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadSuccessResponse),
25 => Some(Self::TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadUnknownMethodResponse),
26 => Some(Self::ReceiveStrictEvent),
27 => Some(Self::ReceiveStrictEventMismatchedStrictness),
28 => Some(Self::ReceiveFlexibleEvent),
29 => Some(Self::ReceiveFlexibleEventMismatchedStrictness),
30 => Some(Self::UnknownStrictEventOpenProtocol),
31 => Some(Self::UnknownFlexibleEventOpenProtocol),
32 => Some(Self::UnknownStrictEventAjarProtocol),
33 => Some(Self::UnknownFlexibleEventAjarProtocol),
34 => Some(Self::UnknownStrictEventClosedProtocol),
35 => Some(Self::UnknownFlexibleEventClosedProtocol),
36 => Some(Self::UnknownStrictServerInitiatedTwoWay),
37 => Some(Self::UnknownFlexibleServerInitiatedTwoWay),
_ => None,
}
}
#[inline]
pub fn from_primitive_allow_unknown(prim: u32) -> Self {
match prim {
1 => Self::Setup,
2 => Self::TwoWayNoPayload,
42 => Self::TwoWayStructPayload,
43 => Self::TwoWayTablePayload,
44 => Self::TwoWayUnionPayload,
45 => Self::TwoWayResultWithPayload,
46 => Self::TwoWayResultWithError,
52 => Self::TwoWayStructRequest,
53 => Self::TwoWayTableRequest,
54 => Self::TwoWayUnionRequest,
48 => Self::OneWayNoRequest,
49 => Self::OneWayStructRequest,
50 => Self::OneWayTableRequest,
51 => Self::OneWayUnionRequest,
55 => Self::ReceiveEventNoPayload,
56 => Self::ReceiveEventStructPayload,
57 => Self::ReceiveEventTablePayload,
58 => Self::ReceiveEventUnionPayload,
3 => Self::GracefulFailureDuringCallAfterPeerClose,
60 => Self::ReceiveEventBadMagicNumber,
61 => Self::ReceiveEventUnexpectedTxid,
62 => Self::ReceiveEventUnknownOrdinal,
63 => Self::ReceiveResponseBadMagicNumber,
64 => Self::ReceiveResponseUnexpectedTxid,
65 => Self::ReceiveResponseWrongOrdinalKnown,
67 => Self::ReceiveResponseWrongOrdinalUnknown,
40 => Self::V1TwoWayNoPayload,
41 => Self::V1TwoWayStructPayload,
59 => Self::OneWayCallDoNotReportPeerClosed,
4 => Self::OneWayStrictSend,
5 => Self::OneWayFlexibleSend,
6 => Self::TwoWayStrictSend,
7 => Self::TwoWayStrictSendMismatchedStrictness,
38 => Self::TwoWayStrictSendNonEmptyPayload,
8 => Self::TwoWayStrictErrorSyntaxSendSuccessResponse,
9 => Self::TwoWayStrictErrorSyntaxSendErrorResponse,
10 => Self::TwoWayStrictErrorSyntaxSendUnknownMethodResponse,
11 => Self::TwoWayStrictErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse,
39 => Self::TwoWayStrictErrorSyntaxSendNonEmptyPayload,
12 => Self::TwoWayFlexibleSendSuccessResponse,
13 => Self::TwoWayFlexibleSendErrorResponse,
14 => Self::TwoWayFlexibleSendUnknownMethodResponse,
15 => Self::TwoWayFlexibleSendMismatchedStrictnessUnknownMethodResponse,
16 => Self::TwoWayFlexibleSendOtherFrameworkErrResponse,
17 => Self::TwoWayFlexibleSendNonEmptyPayloadSuccessResponse,
18 => Self::TwoWayFlexibleSendNonEmptyPayloadUnknownMethodResponse,
19 => Self::TwoWayFlexibleErrorSyntaxSendSuccessResponse,
20 => Self::TwoWayFlexibleErrorSyntaxSendErrorResponse,
21 => Self::TwoWayFlexibleErrorSyntaxSendUnknownMethodResponse,
22 => Self::TwoWayFlexibleErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse,
23 => Self::TwoWayFlexibleErrorSyntaxSendOtherFrameworkErrResponse,
24 => Self::TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadSuccessResponse,
25 => Self::TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadUnknownMethodResponse,
26 => Self::ReceiveStrictEvent,
27 => Self::ReceiveStrictEventMismatchedStrictness,
28 => Self::ReceiveFlexibleEvent,
29 => Self::ReceiveFlexibleEventMismatchedStrictness,
30 => Self::UnknownStrictEventOpenProtocol,
31 => Self::UnknownFlexibleEventOpenProtocol,
32 => Self::UnknownStrictEventAjarProtocol,
33 => Self::UnknownFlexibleEventAjarProtocol,
34 => Self::UnknownStrictEventClosedProtocol,
35 => Self::UnknownFlexibleEventClosedProtocol,
36 => Self::UnknownStrictServerInitiatedTwoWay,
37 => Self::UnknownFlexibleServerInitiatedTwoWay,
unknown_ordinal => Self::__SourceBreaking { unknown_ordinal },
}
}
#[inline]
pub fn unknown() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0xffffffff }
}
#[inline]
pub const fn into_primitive(self) -> u32 {
match self {
Self::Setup => 1,
Self::TwoWayNoPayload => 2,
Self::TwoWayStructPayload => 42,
Self::TwoWayTablePayload => 43,
Self::TwoWayUnionPayload => 44,
Self::TwoWayResultWithPayload => 45,
Self::TwoWayResultWithError => 46,
Self::TwoWayStructRequest => 52,
Self::TwoWayTableRequest => 53,
Self::TwoWayUnionRequest => 54,
Self::OneWayNoRequest => 48,
Self::OneWayStructRequest => 49,
Self::OneWayTableRequest => 50,
Self::OneWayUnionRequest => 51,
Self::ReceiveEventNoPayload => 55,
Self::ReceiveEventStructPayload => 56,
Self::ReceiveEventTablePayload => 57,
Self::ReceiveEventUnionPayload => 58,
Self::GracefulFailureDuringCallAfterPeerClose => 3,
Self::ReceiveEventBadMagicNumber => 60,
Self::ReceiveEventUnexpectedTxid => 61,
Self::ReceiveEventUnknownOrdinal => 62,
Self::ReceiveResponseBadMagicNumber => 63,
Self::ReceiveResponseUnexpectedTxid => 64,
Self::ReceiveResponseWrongOrdinalKnown => 65,
Self::ReceiveResponseWrongOrdinalUnknown => 67,
Self::V1TwoWayNoPayload => 40,
Self::V1TwoWayStructPayload => 41,
Self::OneWayCallDoNotReportPeerClosed => 59,
Self::OneWayStrictSend => 4,
Self::OneWayFlexibleSend => 5,
Self::TwoWayStrictSend => 6,
Self::TwoWayStrictSendMismatchedStrictness => 7,
Self::TwoWayStrictSendNonEmptyPayload => 38,
Self::TwoWayStrictErrorSyntaxSendSuccessResponse => 8,
Self::TwoWayStrictErrorSyntaxSendErrorResponse => 9,
Self::TwoWayStrictErrorSyntaxSendUnknownMethodResponse => 10,
Self::TwoWayStrictErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse => 11,
Self::TwoWayStrictErrorSyntaxSendNonEmptyPayload => 39,
Self::TwoWayFlexibleSendSuccessResponse => 12,
Self::TwoWayFlexibleSendErrorResponse => 13,
Self::TwoWayFlexibleSendUnknownMethodResponse => 14,
Self::TwoWayFlexibleSendMismatchedStrictnessUnknownMethodResponse => 15,
Self::TwoWayFlexibleSendOtherFrameworkErrResponse => 16,
Self::TwoWayFlexibleSendNonEmptyPayloadSuccessResponse => 17,
Self::TwoWayFlexibleSendNonEmptyPayloadUnknownMethodResponse => 18,
Self::TwoWayFlexibleErrorSyntaxSendSuccessResponse => 19,
Self::TwoWayFlexibleErrorSyntaxSendErrorResponse => 20,
Self::TwoWayFlexibleErrorSyntaxSendUnknownMethodResponse => 21,
Self::TwoWayFlexibleErrorSyntaxSendMismatchedStrictnessUnknownMethodResponse => 22,
Self::TwoWayFlexibleErrorSyntaxSendOtherFrameworkErrResponse => 23,
Self::TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadSuccessResponse => 24,
Self::TwoWayFlexibleErrorSyntaxSendNonEmptyPayloadUnknownMethodResponse => 25,
Self::ReceiveStrictEvent => 26,
Self::ReceiveStrictEventMismatchedStrictness => 27,
Self::ReceiveFlexibleEvent => 28,
Self::ReceiveFlexibleEventMismatchedStrictness => 29,
Self::UnknownStrictEventOpenProtocol => 30,
Self::UnknownFlexibleEventOpenProtocol => 31,
Self::UnknownStrictEventAjarProtocol => 32,
Self::UnknownFlexibleEventAjarProtocol => 33,
Self::UnknownStrictEventClosedProtocol => 34,
Self::UnknownFlexibleEventClosedProtocol => 35,
Self::UnknownStrictServerInitiatedTwoWay => 36,
Self::UnknownFlexibleServerInitiatedTwoWay => 37,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { unknown_ordinal: _ } => true,
_ => false,
}
}
}
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct Empty;
impl fidl::Persistable for Empty {}
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
#[repr(C)]
pub struct NonEmptyPayload {
pub some_field: i32,
}
impl fidl::Persistable for NonEmptyPayload {}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallFlexibleOneWayRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleOneWayRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallFlexibleTwoWayErrRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayErrRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallFlexibleTwoWayFieldsErrRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayFieldsErrRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallFlexibleTwoWayFieldsRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayFieldsRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallFlexibleTwoWayRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallOneWayNoRequestRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayNoRequestRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallOneWayStructRequestRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
pub request: NonEmptyPayload,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayStructRequestRequest
{
}
#[derive(Debug, PartialEq)]
pub struct RunnerCallOneWayTableRequestRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
pub request: TablePayload,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayTableRequestRequest
{
}
#[derive(Debug, PartialEq)]
pub struct RunnerCallOneWayUnionRequestRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
pub request: UnionPayload,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayUnionRequestRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallStrictOneWayRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictOneWayRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallStrictTwoWayErrRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayErrRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallStrictTwoWayFieldsErrRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayFieldsErrRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallStrictTwoWayFieldsRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayFieldsRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallStrictTwoWayRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallTwoWayNoPayloadRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayNoPayloadRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallTwoWayStructPayloadErrRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayStructPayloadErrRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallTwoWayStructPayloadRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayStructPayloadRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallTwoWayStructRequestRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
pub request: NonEmptyPayload,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayStructRequestRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallTwoWayTablePayloadRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayTablePayloadRequest
{
}
#[derive(Debug, PartialEq)]
pub struct RunnerCallTwoWayTableRequestRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
pub request: TablePayload,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayTableRequestRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerCallTwoWayUnionPayloadRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayUnionPayloadRequest
{
}
#[derive(Debug, PartialEq)]
pub struct RunnerCallTwoWayUnionRequestRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
pub request: UnionPayload,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayUnionRequestRequest
{
}
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
#[repr(C)]
pub struct RunnerGetVersionResponse {
pub version: u64,
}
impl fidl::Persistable for RunnerGetVersionResponse {}
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerIsTestEnabledRequest {
pub test: Test,
}
impl fidl::Persistable for RunnerIsTestEnabledRequest {}
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerIsTestEnabledResponse {
pub is_enabled: bool,
}
impl fidl::Persistable for RunnerIsTestEnabledResponse {}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerReceiveAjarEventsRequest {
pub target: fidl::endpoints::ClientEnd<AjarTargetMarker>,
pub reporter: fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerReceiveAjarEventsRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerReceiveClosedEventsRequest {
pub target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
pub reporter: fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerReceiveClosedEventsRequest
{
}
#[derive(Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
pub struct RunnerReceiveOpenEventsRequest {
pub target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
pub reporter: fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
}
impl fidl::Standalone<fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerReceiveOpenEventsRequest
{
}
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
#[repr(C)]
pub struct UnknownEvent {
pub ordinal: u64,
}
impl fidl::Persistable for UnknownEvent {}
#[derive(Clone, Debug, Default, PartialEq)]
pub struct BindingsProperties {
pub io_style: Option<IoStyle>,
#[doc(hidden)]
pub __source_breaking: fidl::marker::SourceBreaking,
}
impl fidl::Persistable for BindingsProperties {}
#[derive(Clone, Debug, Default, PartialEq)]
pub struct TablePayload {
pub some_field: Option<i32>,
#[doc(hidden)]
pub __source_breaking: fidl::marker::SourceBreaking,
}
impl fidl::Persistable for TablePayload {}
#[derive(Clone, Debug)]
pub enum AjarTargetEventReport {
FidlError(FidlErrorKind),
UnknownEvent(UnknownEvent),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! AjarTargetEventReportUnknown {
() => {
_
};
}
impl PartialEq for AjarTargetEventReport {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
(Self::UnknownEvent(x), Self::UnknownEvent(y)) => *x == *y,
_ => false,
}
}
}
impl AjarTargetEventReport {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::FidlError(_) => 1,
Self::UnknownEvent(_) => 2,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for AjarTargetEventReport {}
#[derive(Clone, Debug)]
pub enum ClosedTargetEventReport {
FidlError(FidlErrorKind),
OnEventNoPayload(Empty),
OnEventStructPayload(NonEmptyPayload),
OnEventTablePayload(TablePayload),
OnEventUnionPayload(UnionPayload),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! ClosedTargetEventReportUnknown {
() => {
_
};
}
impl PartialEq for ClosedTargetEventReport {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
(Self::OnEventNoPayload(x), Self::OnEventNoPayload(y)) => *x == *y,
(Self::OnEventStructPayload(x), Self::OnEventStructPayload(y)) => *x == *y,
(Self::OnEventTablePayload(x), Self::OnEventTablePayload(y)) => *x == *y,
(Self::OnEventUnionPayload(x), Self::OnEventUnionPayload(y)) => *x == *y,
_ => false,
}
}
}
impl ClosedTargetEventReport {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::FidlError(_) => 1,
Self::OnEventNoPayload(_) => 2,
Self::OnEventStructPayload(_) => 3,
Self::OnEventTablePayload(_) => 4,
Self::OnEventUnionPayload(_) => 5,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for ClosedTargetEventReport {}
#[derive(Clone, Debug)]
pub enum EmptyResultClassification {
Success(Empty),
FidlError(FidlErrorKind),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! EmptyResultClassificationUnknown {
() => {
_
};
}
impl PartialEq for EmptyResultClassification {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::Success(x), Self::Success(y)) => *x == *y,
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
_ => false,
}
}
}
impl EmptyResultClassification {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::Success(_) => 1,
Self::FidlError(_) => 3,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for EmptyResultClassification {}
#[derive(Clone, Debug)]
pub enum EmptyResultWithErrorClassification {
Success(Empty),
ApplicationError(i32),
FidlError(FidlErrorKind),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! EmptyResultWithErrorClassificationUnknown {
() => {
_
};
}
impl PartialEq for EmptyResultWithErrorClassification {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::Success(x), Self::Success(y)) => *x == *y,
(Self::ApplicationError(x), Self::ApplicationError(y)) => *x == *y,
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
_ => false,
}
}
}
impl EmptyResultWithErrorClassification {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::Success(_) => 1,
Self::ApplicationError(_) => 2,
Self::FidlError(_) => 3,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for EmptyResultWithErrorClassification {}
#[derive(Clone, Debug)]
pub enum NonEmptyResultClassification {
Success(NonEmptyPayload),
FidlError(FidlErrorKind),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! NonEmptyResultClassificationUnknown {
() => {
_
};
}
impl PartialEq for NonEmptyResultClassification {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::Success(x), Self::Success(y)) => *x == *y,
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
_ => false,
}
}
}
impl NonEmptyResultClassification {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::Success(_) => 1,
Self::FidlError(_) => 3,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for NonEmptyResultClassification {}
#[derive(Clone, Debug)]
pub enum NonEmptyResultWithErrorClassification {
Success(NonEmptyPayload),
ApplicationError(i32),
FidlError(FidlErrorKind),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! NonEmptyResultWithErrorClassificationUnknown {
() => {
_
};
}
impl PartialEq for NonEmptyResultWithErrorClassification {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::Success(x), Self::Success(y)) => *x == *y,
(Self::ApplicationError(x), Self::ApplicationError(y)) => *x == *y,
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
_ => false,
}
}
}
impl NonEmptyResultWithErrorClassification {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::Success(_) => 1,
Self::ApplicationError(_) => 2,
Self::FidlError(_) => 3,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for NonEmptyResultWithErrorClassification {}
#[derive(Clone, Debug)]
pub enum OpenTargetEventReport {
FidlError(FidlErrorKind),
UnknownEvent(UnknownEvent),
StrictEvent(Empty),
FlexibleEvent(Empty),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! OpenTargetEventReportUnknown {
() => {
_
};
}
impl PartialEq for OpenTargetEventReport {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
(Self::UnknownEvent(x), Self::UnknownEvent(y)) => *x == *y,
(Self::StrictEvent(x), Self::StrictEvent(y)) => *x == *y,
(Self::FlexibleEvent(x), Self::FlexibleEvent(y)) => *x == *y,
_ => false,
}
}
}
impl OpenTargetEventReport {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::FidlError(_) => 1,
Self::UnknownEvent(_) => 2,
Self::StrictEvent(_) => 3,
Self::FlexibleEvent(_) => 4,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for OpenTargetEventReport {}
#[derive(Clone, Debug)]
pub enum TableResultClassification {
Success(TablePayload),
FidlError(FidlErrorKind),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! TableResultClassificationUnknown {
() => {
_
};
}
impl PartialEq for TableResultClassification {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::Success(x), Self::Success(y)) => *x == *y,
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
_ => false,
}
}
}
impl TableResultClassification {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::Success(_) => 1,
Self::FidlError(_) => 3,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for TableResultClassification {}
#[derive(Clone, Debug)]
pub enum UnionPayload {
SomeVariant(i32),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! UnionPayloadUnknown {
() => {
_
};
}
impl PartialEq for UnionPayload {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::SomeVariant(x), Self::SomeVariant(y)) => *x == *y,
_ => false,
}
}
}
impl UnionPayload {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::SomeVariant(_) => 1,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for UnionPayload {}
#[derive(Clone, Debug)]
pub enum UnionResultClassification {
Success(UnionPayload),
FidlError(FidlErrorKind),
#[doc(hidden)]
__SourceBreaking {
unknown_ordinal: u64,
},
}
#[macro_export]
macro_rules! UnionResultClassificationUnknown {
() => {
_
};
}
impl PartialEq for UnionResultClassification {
fn eq(&self, other: &Self) -> bool {
match (self, other) {
(Self::Success(x), Self::Success(y)) => *x == *y,
(Self::FidlError(x), Self::FidlError(y)) => *x == *y,
_ => false,
}
}
}
impl UnionResultClassification {
#[inline]
pub fn ordinal(&self) -> u64 {
match *self {
Self::Success(_) => 1,
Self::FidlError(_) => 3,
Self::__SourceBreaking { unknown_ordinal } => unknown_ordinal,
}
}
#[inline]
pub fn unknown_variant_for_testing() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
pub fn is_unknown(&self) -> bool {
match self {
Self::__SourceBreaking { .. } => true,
_ => false,
}
}
}
impl fidl::Persistable for UnionResultClassification {}
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct AjarTargetMarker;
impl fidl::endpoints::ProtocolMarker for AjarTargetMarker {
type Proxy = AjarTargetProxy;
type RequestStream = AjarTargetRequestStream;
#[cfg(target_os = "fuchsia")]
type SynchronousProxy = AjarTargetSynchronousProxy;
const DEBUG_NAME: &'static str = "(anonymous) AjarTarget";
}
pub trait AjarTargetProxyInterface: Send + Sync {}
#[derive(Debug)]
#[cfg(target_os = "fuchsia")]
pub struct AjarTargetSynchronousProxy {
client: fidl::client::sync::Client,
}
#[cfg(target_os = "fuchsia")]
impl fidl::endpoints::SynchronousProxy for AjarTargetSynchronousProxy {
type Proxy = AjarTargetProxy;
type Protocol = AjarTargetMarker;
fn from_channel(inner: fidl::Channel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
fn as_channel(&self) -> &fidl::Channel {
self.client.as_channel()
}
}
#[cfg(target_os = "fuchsia")]
impl AjarTargetSynchronousProxy {
pub fn new(channel: fidl::Channel) -> Self {
let protocol_name = <AjarTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::sync::Client::new(channel, protocol_name) }
}
pub fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
pub fn wait_for_event(
&self,
deadline: zx::MonotonicInstant,
) -> Result<AjarTargetEvent, fidl::Error> {
AjarTargetEvent::decode(self.client.wait_for_event(deadline)?)
}
}
#[derive(Debug, Clone)]
pub struct AjarTargetProxy {
client: fidl::client::Client<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl fidl::endpoints::Proxy for AjarTargetProxy {
type Protocol = AjarTargetMarker;
fn from_channel(inner: ::fidl::AsyncChannel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> Result<::fidl::AsyncChannel, Self> {
self.client.into_channel().map_err(|client| Self { client })
}
fn as_channel(&self) -> &::fidl::AsyncChannel {
self.client.as_channel()
}
}
impl AjarTargetProxy {
pub fn new(channel: ::fidl::AsyncChannel) -> Self {
let protocol_name = <AjarTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::Client::new(channel, protocol_name) }
}
pub fn take_event_stream(&self) -> AjarTargetEventStream {
AjarTargetEventStream { event_receiver: self.client.take_event_receiver() }
}
}
impl AjarTargetProxyInterface for AjarTargetProxy {}
pub struct AjarTargetEventStream {
event_receiver: fidl::client::EventReceiver<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl std::marker::Unpin for AjarTargetEventStream {}
impl futures::stream::FusedStream for AjarTargetEventStream {
fn is_terminated(&self) -> bool {
self.event_receiver.is_terminated()
}
}
impl futures::Stream for AjarTargetEventStream {
type Item = Result<AjarTargetEvent, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
match futures::ready!(futures::stream::StreamExt::poll_next_unpin(
&mut self.event_receiver,
cx
)?) {
Some(buf) => std::task::Poll::Ready(Some(AjarTargetEvent::decode(buf))),
None => std::task::Poll::Ready(None),
}
}
}
#[derive(Debug)]
pub enum AjarTargetEvent {
#[non_exhaustive]
_UnknownEvent {
ordinal: u64,
},
}
impl AjarTargetEvent {
fn decode(
mut buf: <fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc,
) -> Result<AjarTargetEvent, fidl::Error> {
let (bytes, _handles) = buf.split_mut();
let (tx_header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
debug_assert_eq!(tx_header.tx_id, 0);
match tx_header.ordinal {
_ if tx_header.dynamic_flags().contains(fidl::encoding::DynamicFlags::FLEXIBLE) => {
Ok(AjarTargetEvent::_UnknownEvent { ordinal: tx_header.ordinal })
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: tx_header.ordinal,
protocol_name: <AjarTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}
}
}
pub struct AjarTargetRequestStream {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
}
impl std::marker::Unpin for AjarTargetRequestStream {}
impl futures::stream::FusedStream for AjarTargetRequestStream {
fn is_terminated(&self) -> bool {
self.is_terminated
}
}
impl fidl::endpoints::RequestStream for AjarTargetRequestStream {
type Protocol = AjarTargetMarker;
type ControlHandle = AjarTargetControlHandle;
fn from_channel(channel: ::fidl::AsyncChannel) -> Self {
Self { inner: std::sync::Arc::new(fidl::ServeInner::new(channel)), is_terminated: false }
}
fn control_handle(&self) -> Self::ControlHandle {
AjarTargetControlHandle { inner: self.inner.clone() }
}
fn into_inner(
self,
) -> (::std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>, bool)
{
(self.inner, self.is_terminated)
}
fn from_inner(
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
) -> Self {
Self { inner, is_terminated }
}
}
impl futures::Stream for AjarTargetRequestStream {
type Item = Result<AjarTargetRequest, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
let this = &mut *self;
if this.inner.check_shutdown(cx) {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
if this.is_terminated {
panic!("polled AjarTargetRequestStream after completion");
}
fidl::encoding::with_tls_decode_buf::<_, fidl::encoding::DefaultFuchsiaResourceDialect>(
|bytes, handles| {
match this.inner.channel().read_etc(cx, bytes, handles) {
std::task::Poll::Ready(Ok(())) => {}
std::task::Poll::Pending => return std::task::Poll::Pending,
std::task::Poll::Ready(Err(zx_status::Status::PEER_CLOSED)) => {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
std::task::Poll::Ready(Err(e)) => {
return std::task::Poll::Ready(Some(Err(fidl::Error::ServerRequestRead(
e.into(),
))))
}
}
let (header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
std::task::Poll::Ready(Some(match header.ordinal {
_ if header.tx_id == 0
&& header
.dynamic_flags()
.contains(fidl::encoding::DynamicFlags::FLEXIBLE) =>
{
Ok(AjarTargetRequest::_UnknownMethod {
ordinal: header.ordinal,
control_handle: AjarTargetControlHandle { inner: this.inner.clone() },
})
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: header.ordinal,
protocol_name:
<AjarTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}))
},
)
}
}
#[derive(Debug)]
pub enum AjarTargetRequest {
#[non_exhaustive]
_UnknownMethod {
ordinal: u64,
control_handle: AjarTargetControlHandle,
},
}
impl AjarTargetRequest {
pub fn method_name(&self) -> &'static str {
match *self {
AjarTargetRequest::_UnknownMethod { .. } => "unknown one-way method",
}
}
}
#[derive(Debug, Clone)]
pub struct AjarTargetControlHandle {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
}
impl fidl::endpoints::ControlHandle for AjarTargetControlHandle {
fn shutdown(&self) {
self.inner.shutdown()
}
fn shutdown_with_epitaph(&self, status: zx_status::Status) {
self.inner.shutdown_with_epitaph(status)
}
fn is_closed(&self) -> bool {
self.inner.channel().is_closed()
}
fn on_closed(&self) -> fidl::OnSignalsRef<'_> {
self.inner.channel().on_closed()
}
#[cfg(target_os = "fuchsia")]
fn signal_peer(
&self,
clear_mask: zx::Signals,
set_mask: zx::Signals,
) -> Result<(), zx_status::Status> {
use fidl::Peered;
self.inner.channel().signal_peer(clear_mask, set_mask)
}
}
impl AjarTargetControlHandle {}
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct AjarTargetEventReporterMarker;
impl fidl::endpoints::ProtocolMarker for AjarTargetEventReporterMarker {
type Proxy = AjarTargetEventReporterProxy;
type RequestStream = AjarTargetEventReporterRequestStream;
#[cfg(target_os = "fuchsia")]
type SynchronousProxy = AjarTargetEventReporterSynchronousProxy;
const DEBUG_NAME: &'static str = "(anonymous) AjarTargetEventReporter";
}
pub trait AjarTargetEventReporterProxyInterface: Send + Sync {
fn r#report_event(&self, payload: &AjarTargetEventReport) -> Result<(), fidl::Error>;
}
#[derive(Debug)]
#[cfg(target_os = "fuchsia")]
pub struct AjarTargetEventReporterSynchronousProxy {
client: fidl::client::sync::Client,
}
#[cfg(target_os = "fuchsia")]
impl fidl::endpoints::SynchronousProxy for AjarTargetEventReporterSynchronousProxy {
type Proxy = AjarTargetEventReporterProxy;
type Protocol = AjarTargetEventReporterMarker;
fn from_channel(inner: fidl::Channel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
fn as_channel(&self) -> &fidl::Channel {
self.client.as_channel()
}
}
#[cfg(target_os = "fuchsia")]
impl AjarTargetEventReporterSynchronousProxy {
pub fn new(channel: fidl::Channel) -> Self {
let protocol_name =
<AjarTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::sync::Client::new(channel, protocol_name) }
}
pub fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
pub fn wait_for_event(
&self,
deadline: zx::MonotonicInstant,
) -> Result<AjarTargetEventReporterEvent, fidl::Error> {
AjarTargetEventReporterEvent::decode(self.client.wait_for_event(deadline)?)
}
pub fn r#report_event(&self, mut payload: &AjarTargetEventReport) -> Result<(), fidl::Error> {
self.client.send::<AjarTargetEventReport>(
payload,
0x477b93390be99238,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[derive(Debug, Clone)]
pub struct AjarTargetEventReporterProxy {
client: fidl::client::Client<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl fidl::endpoints::Proxy for AjarTargetEventReporterProxy {
type Protocol = AjarTargetEventReporterMarker;
fn from_channel(inner: ::fidl::AsyncChannel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> Result<::fidl::AsyncChannel, Self> {
self.client.into_channel().map_err(|client| Self { client })
}
fn as_channel(&self) -> &::fidl::AsyncChannel {
self.client.as_channel()
}
}
impl AjarTargetEventReporterProxy {
pub fn new(channel: ::fidl::AsyncChannel) -> Self {
let protocol_name =
<AjarTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::Client::new(channel, protocol_name) }
}
pub fn take_event_stream(&self) -> AjarTargetEventReporterEventStream {
AjarTargetEventReporterEventStream { event_receiver: self.client.take_event_receiver() }
}
pub fn r#report_event(&self, mut payload: &AjarTargetEventReport) -> Result<(), fidl::Error> {
AjarTargetEventReporterProxyInterface::r#report_event(self, payload)
}
}
impl AjarTargetEventReporterProxyInterface for AjarTargetEventReporterProxy {
fn r#report_event(&self, mut payload: &AjarTargetEventReport) -> Result<(), fidl::Error> {
self.client.send::<AjarTargetEventReport>(
payload,
0x477b93390be99238,
fidl::encoding::DynamicFlags::empty(),
)
}
}
pub struct AjarTargetEventReporterEventStream {
event_receiver: fidl::client::EventReceiver<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl std::marker::Unpin for AjarTargetEventReporterEventStream {}
impl futures::stream::FusedStream for AjarTargetEventReporterEventStream {
fn is_terminated(&self) -> bool {
self.event_receiver.is_terminated()
}
}
impl futures::Stream for AjarTargetEventReporterEventStream {
type Item = Result<AjarTargetEventReporterEvent, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
match futures::ready!(futures::stream::StreamExt::poll_next_unpin(
&mut self.event_receiver,
cx
)?) {
Some(buf) => std::task::Poll::Ready(Some(AjarTargetEventReporterEvent::decode(buf))),
None => std::task::Poll::Ready(None),
}
}
}
#[derive(Debug)]
pub enum AjarTargetEventReporterEvent {}
impl AjarTargetEventReporterEvent {
fn decode(
mut buf: <fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc,
) -> Result<AjarTargetEventReporterEvent, fidl::Error> {
let (bytes, _handles) = buf.split_mut();
let (tx_header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
debug_assert_eq!(tx_header.tx_id, 0);
match tx_header.ordinal {
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: tx_header.ordinal,
protocol_name:
<AjarTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}
}
}
pub struct AjarTargetEventReporterRequestStream {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
}
impl std::marker::Unpin for AjarTargetEventReporterRequestStream {}
impl futures::stream::FusedStream for AjarTargetEventReporterRequestStream {
fn is_terminated(&self) -> bool {
self.is_terminated
}
}
impl fidl::endpoints::RequestStream for AjarTargetEventReporterRequestStream {
type Protocol = AjarTargetEventReporterMarker;
type ControlHandle = AjarTargetEventReporterControlHandle;
fn from_channel(channel: ::fidl::AsyncChannel) -> Self {
Self { inner: std::sync::Arc::new(fidl::ServeInner::new(channel)), is_terminated: false }
}
fn control_handle(&self) -> Self::ControlHandle {
AjarTargetEventReporterControlHandle { inner: self.inner.clone() }
}
fn into_inner(
self,
) -> (::std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>, bool)
{
(self.inner, self.is_terminated)
}
fn from_inner(
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
) -> Self {
Self { inner, is_terminated }
}
}
impl futures::Stream for AjarTargetEventReporterRequestStream {
type Item = Result<AjarTargetEventReporterRequest, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
let this = &mut *self;
if this.inner.check_shutdown(cx) {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
if this.is_terminated {
panic!("polled AjarTargetEventReporterRequestStream after completion");
}
fidl::encoding::with_tls_decode_buf::<_, fidl::encoding::DefaultFuchsiaResourceDialect>(
|bytes, handles| {
match this.inner.channel().read_etc(cx, bytes, handles) {
std::task::Poll::Ready(Ok(())) => {}
std::task::Poll::Pending => return std::task::Poll::Pending,
std::task::Poll::Ready(Err(zx_status::Status::PEER_CLOSED)) => {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
std::task::Poll::Ready(Err(e)) => {
return std::task::Poll::Ready(Some(Err(fidl::Error::ServerRequestRead(
e.into(),
))))
}
}
let (header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
std::task::Poll::Ready(Some(match header.ordinal {
0x477b93390be99238 => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(AjarTargetEventReport, fidl::encoding::DefaultFuchsiaResourceDialect);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<AjarTargetEventReport>(&header, _body_bytes, handles, &mut req)?;
let control_handle = AjarTargetEventReporterControlHandle {
inner: this.inner.clone(),
};
Ok(AjarTargetEventReporterRequest::ReportEvent {payload: req,
control_handle,
})
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: header.ordinal,
protocol_name: <AjarTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}))
},
)
}
}
#[derive(Debug)]
pub enum AjarTargetEventReporterRequest {
ReportEvent {
payload: AjarTargetEventReport,
control_handle: AjarTargetEventReporterControlHandle,
},
}
impl AjarTargetEventReporterRequest {
#[allow(irrefutable_let_patterns)]
pub fn into_report_event(
self,
) -> Option<(AjarTargetEventReport, AjarTargetEventReporterControlHandle)> {
if let AjarTargetEventReporterRequest::ReportEvent { payload, control_handle } = self {
Some((payload, control_handle))
} else {
None
}
}
pub fn method_name(&self) -> &'static str {
match *self {
AjarTargetEventReporterRequest::ReportEvent { .. } => "report_event",
}
}
}
#[derive(Debug, Clone)]
pub struct AjarTargetEventReporterControlHandle {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
}
impl fidl::endpoints::ControlHandle for AjarTargetEventReporterControlHandle {
fn shutdown(&self) {
self.inner.shutdown()
}
fn shutdown_with_epitaph(&self, status: zx_status::Status) {
self.inner.shutdown_with_epitaph(status)
}
fn is_closed(&self) -> bool {
self.inner.channel().is_closed()
}
fn on_closed(&self) -> fidl::OnSignalsRef<'_> {
self.inner.channel().on_closed()
}
#[cfg(target_os = "fuchsia")]
fn signal_peer(
&self,
clear_mask: zx::Signals,
set_mask: zx::Signals,
) -> Result<(), zx_status::Status> {
use fidl::Peered;
self.inner.channel().signal_peer(clear_mask, set_mask)
}
}
impl AjarTargetEventReporterControlHandle {}
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct ClosedTargetMarker;
impl fidl::endpoints::ProtocolMarker for ClosedTargetMarker {
type Proxy = ClosedTargetProxy;
type RequestStream = ClosedTargetRequestStream;
#[cfg(target_os = "fuchsia")]
type SynchronousProxy = ClosedTargetSynchronousProxy;
const DEBUG_NAME: &'static str = "(anonymous) ClosedTarget";
}
pub type ClosedTargetTwoWayStructPayloadErrResult = Result<i32, i32>;
pub trait ClosedTargetProxyInterface: Send + Sync {
type TwoWayNoPayloadResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#two_way_no_payload(&self) -> Self::TwoWayNoPayloadResponseFut;
type TwoWayStructPayloadResponseFut: std::future::Future<Output = Result<i32, fidl::Error>>
+ Send;
fn r#two_way_struct_payload(&self) -> Self::TwoWayStructPayloadResponseFut;
type TwoWayTablePayloadResponseFut: std::future::Future<Output = Result<TablePayload, fidl::Error>>
+ Send;
fn r#two_way_table_payload(&self) -> Self::TwoWayTablePayloadResponseFut;
type TwoWayUnionPayloadResponseFut: std::future::Future<Output = Result<UnionPayload, fidl::Error>>
+ Send;
fn r#two_way_union_payload(&self) -> Self::TwoWayUnionPayloadResponseFut;
type TwoWayStructPayloadErrResponseFut: std::future::Future<Output = Result<ClosedTargetTwoWayStructPayloadErrResult, fidl::Error>>
+ Send;
fn r#two_way_struct_payload_err(&self) -> Self::TwoWayStructPayloadErrResponseFut;
type TwoWayStructRequestResponseFut: std::future::Future<Output = Result<(), fidl::Error>>
+ Send;
fn r#two_way_struct_request(&self, some_field: i32) -> Self::TwoWayStructRequestResponseFut;
type TwoWayTableRequestResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#two_way_table_request(
&self,
payload: &TablePayload,
) -> Self::TwoWayTableRequestResponseFut;
type TwoWayUnionRequestResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#two_way_union_request(
&self,
payload: &UnionPayload,
) -> Self::TwoWayUnionRequestResponseFut;
fn r#one_way_no_request(&self) -> Result<(), fidl::Error>;
fn r#one_way_struct_request(&self, some_field: i32) -> Result<(), fidl::Error>;
fn r#one_way_table_request(&self, payload: &TablePayload) -> Result<(), fidl::Error>;
fn r#one_way_union_request(&self, payload: &UnionPayload) -> Result<(), fidl::Error>;
}
#[derive(Debug)]
#[cfg(target_os = "fuchsia")]
pub struct ClosedTargetSynchronousProxy {
client: fidl::client::sync::Client,
}
#[cfg(target_os = "fuchsia")]
impl fidl::endpoints::SynchronousProxy for ClosedTargetSynchronousProxy {
type Proxy = ClosedTargetProxy;
type Protocol = ClosedTargetMarker;
fn from_channel(inner: fidl::Channel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
fn as_channel(&self) -> &fidl::Channel {
self.client.as_channel()
}
}
#[cfg(target_os = "fuchsia")]
impl ClosedTargetSynchronousProxy {
pub fn new(channel: fidl::Channel) -> Self {
let protocol_name = <ClosedTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::sync::Client::new(channel, protocol_name) }
}
pub fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
pub fn wait_for_event(
&self,
deadline: zx::MonotonicInstant,
) -> Result<ClosedTargetEvent, fidl::Error> {
ClosedTargetEvent::decode(self.client.wait_for_event(deadline)?)
}
pub fn r#two_way_no_payload(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<(), fidl::Error> {
let _response =
self.client.send_query::<fidl::encoding::EmptyPayload, fidl::encoding::EmptyPayload>(
(),
0x7a722961424c1720,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#two_way_struct_payload(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<i32, fidl::Error> {
let _response = self.client.send_query::<fidl::encoding::EmptyPayload, NonEmptyPayload>(
(),
0x3a402118bad781bd,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response.some_field)
}
pub fn r#two_way_table_payload(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<TablePayload, fidl::Error> {
let _response = self.client.send_query::<fidl::encoding::EmptyPayload, TablePayload>(
(),
0x53be101c241c66bc,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#two_way_union_payload(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<UnionPayload, fidl::Error> {
let _response = self.client.send_query::<fidl::encoding::EmptyPayload, UnionPayload>(
(),
0x1ff7f745ab608f8c,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#two_way_struct_payload_err(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<ClosedTargetTwoWayStructPayloadErrResult, fidl::Error> {
let _response = self.client.send_query::<
fidl::encoding::EmptyPayload,
fidl::encoding::ResultType<NonEmptyPayload, i32>,
>(
(),
0x62b4861c443bbc0b,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response.map(|x| x.some_field))
}
pub fn r#two_way_struct_request(
&self,
mut some_field: i32,
___deadline: zx::MonotonicInstant,
) -> Result<(), fidl::Error> {
let _response = self.client.send_query::<NonEmptyPayload, fidl::encoding::EmptyPayload>(
(some_field,),
0x4ff77b4a913be5b6,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#two_way_table_request(
&self,
mut payload: &TablePayload,
___deadline: zx::MonotonicInstant,
) -> Result<(), fidl::Error> {
let _response = self.client.send_query::<TablePayload, fidl::encoding::EmptyPayload>(
payload,
0x3d38ad5b0f4f49cf,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#two_way_union_request(
&self,
mut payload: &UnionPayload,
___deadline: zx::MonotonicInstant,
) -> Result<(), fidl::Error> {
let _response = self.client.send_query::<UnionPayload, fidl::encoding::EmptyPayload>(
payload,
0x7adb1c265a378e77,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#one_way_no_request(&self) -> Result<(), fidl::Error> {
self.client.send::<fidl::encoding::EmptyPayload>(
(),
0xc376730a2cd8a05,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn r#one_way_struct_request(&self, mut some_field: i32) -> Result<(), fidl::Error> {
self.client.send::<NonEmptyPayload>(
(some_field,),
0x2618da6f51e0dcd2,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn r#one_way_table_request(&self, mut payload: &TablePayload) -> Result<(), fidl::Error> {
self.client.send::<TablePayload>(
payload,
0x1a4b7d32eaed401f,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn r#one_way_union_request(&self, mut payload: &UnionPayload) -> Result<(), fidl::Error> {
self.client.send::<UnionPayload>(
payload,
0x142b3cd9ea530de5,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[derive(Debug, Clone)]
pub struct ClosedTargetProxy {
client: fidl::client::Client<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl fidl::endpoints::Proxy for ClosedTargetProxy {
type Protocol = ClosedTargetMarker;
fn from_channel(inner: ::fidl::AsyncChannel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> Result<::fidl::AsyncChannel, Self> {
self.client.into_channel().map_err(|client| Self { client })
}
fn as_channel(&self) -> &::fidl::AsyncChannel {
self.client.as_channel()
}
}
impl ClosedTargetProxy {
pub fn new(channel: ::fidl::AsyncChannel) -> Self {
let protocol_name = <ClosedTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::Client::new(channel, protocol_name) }
}
pub fn take_event_stream(&self) -> ClosedTargetEventStream {
ClosedTargetEventStream { event_receiver: self.client.take_event_receiver() }
}
pub fn r#two_way_no_payload(
&self,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
ClosedTargetProxyInterface::r#two_way_no_payload(self)
}
pub fn r#two_way_struct_payload(
&self,
) -> fidl::client::QueryResponseFut<i32, fidl::encoding::DefaultFuchsiaResourceDialect> {
ClosedTargetProxyInterface::r#two_way_struct_payload(self)
}
pub fn r#two_way_table_payload(
&self,
) -> fidl::client::QueryResponseFut<TablePayload, fidl::encoding::DefaultFuchsiaResourceDialect>
{
ClosedTargetProxyInterface::r#two_way_table_payload(self)
}
pub fn r#two_way_union_payload(
&self,
) -> fidl::client::QueryResponseFut<UnionPayload, fidl::encoding::DefaultFuchsiaResourceDialect>
{
ClosedTargetProxyInterface::r#two_way_union_payload(self)
}
pub fn r#two_way_struct_payload_err(
&self,
) -> fidl::client::QueryResponseFut<
ClosedTargetTwoWayStructPayloadErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
ClosedTargetProxyInterface::r#two_way_struct_payload_err(self)
}
pub fn r#two_way_struct_request(
&self,
mut some_field: i32,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
ClosedTargetProxyInterface::r#two_way_struct_request(self, some_field)
}
pub fn r#two_way_table_request(
&self,
mut payload: &TablePayload,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
ClosedTargetProxyInterface::r#two_way_table_request(self, payload)
}
pub fn r#two_way_union_request(
&self,
mut payload: &UnionPayload,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
ClosedTargetProxyInterface::r#two_way_union_request(self, payload)
}
pub fn r#one_way_no_request(&self) -> Result<(), fidl::Error> {
ClosedTargetProxyInterface::r#one_way_no_request(self)
}
pub fn r#one_way_struct_request(&self, mut some_field: i32) -> Result<(), fidl::Error> {
ClosedTargetProxyInterface::r#one_way_struct_request(self, some_field)
}
pub fn r#one_way_table_request(&self, mut payload: &TablePayload) -> Result<(), fidl::Error> {
ClosedTargetProxyInterface::r#one_way_table_request(self, payload)
}
pub fn r#one_way_union_request(&self, mut payload: &UnionPayload) -> Result<(), fidl::Error> {
ClosedTargetProxyInterface::r#one_way_union_request(self, payload)
}
}
impl ClosedTargetProxyInterface for ClosedTargetProxy {
type TwoWayNoPayloadResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#two_way_no_payload(&self) -> Self::TwoWayNoPayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x7a722961424c1720,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, ()>(
(),
0x7a722961424c1720,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type TwoWayStructPayloadResponseFut =
fidl::client::QueryResponseFut<i32, fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#two_way_struct_payload(&self) -> Self::TwoWayStructPayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<i32, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x3a402118bad781bd,
>(_buf?)?;
Ok(_response.some_field)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, i32>(
(),
0x3a402118bad781bd,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type TwoWayTablePayloadResponseFut =
fidl::client::QueryResponseFut<TablePayload, fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#two_way_table_payload(&self) -> Self::TwoWayTablePayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<TablePayload, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
TablePayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x53be101c241c66bc,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, TablePayload>(
(),
0x53be101c241c66bc,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type TwoWayUnionPayloadResponseFut =
fidl::client::QueryResponseFut<UnionPayload, fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#two_way_union_payload(&self) -> Self::TwoWayUnionPayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<UnionPayload, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
UnionPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x1ff7f745ab608f8c,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, UnionPayload>(
(),
0x1ff7f745ab608f8c,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type TwoWayStructPayloadErrResponseFut = fidl::client::QueryResponseFut<
ClosedTargetTwoWayStructPayloadErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#two_way_struct_payload_err(&self) -> Self::TwoWayStructPayloadErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<ClosedTargetTwoWayStructPayloadErrResult, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::ResultType<NonEmptyPayload, i32>,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x62b4861c443bbc0b,
>(_buf?)?;
Ok(_response.map(|x| x.some_field))
}
self.client.send_query_and_decode::<
fidl::encoding::EmptyPayload,
ClosedTargetTwoWayStructPayloadErrResult,
>(
(),
0x62b4861c443bbc0b,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type TwoWayStructRequestResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#two_way_struct_request(
&self,
mut some_field: i32,
) -> Self::TwoWayStructRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x4ff77b4a913be5b6,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<NonEmptyPayload, ()>(
(some_field,),
0x4ff77b4a913be5b6,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type TwoWayTableRequestResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#two_way_table_request(
&self,
mut payload: &TablePayload,
) -> Self::TwoWayTableRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x3d38ad5b0f4f49cf,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<TablePayload, ()>(
payload,
0x3d38ad5b0f4f49cf,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type TwoWayUnionRequestResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#two_way_union_request(
&self,
mut payload: &UnionPayload,
) -> Self::TwoWayUnionRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x7adb1c265a378e77,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<UnionPayload, ()>(
payload,
0x7adb1c265a378e77,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
fn r#one_way_no_request(&self) -> Result<(), fidl::Error> {
self.client.send::<fidl::encoding::EmptyPayload>(
(),
0xc376730a2cd8a05,
fidl::encoding::DynamicFlags::empty(),
)
}
fn r#one_way_struct_request(&self, mut some_field: i32) -> Result<(), fidl::Error> {
self.client.send::<NonEmptyPayload>(
(some_field,),
0x2618da6f51e0dcd2,
fidl::encoding::DynamicFlags::empty(),
)
}
fn r#one_way_table_request(&self, mut payload: &TablePayload) -> Result<(), fidl::Error> {
self.client.send::<TablePayload>(
payload,
0x1a4b7d32eaed401f,
fidl::encoding::DynamicFlags::empty(),
)
}
fn r#one_way_union_request(&self, mut payload: &UnionPayload) -> Result<(), fidl::Error> {
self.client.send::<UnionPayload>(
payload,
0x142b3cd9ea530de5,
fidl::encoding::DynamicFlags::empty(),
)
}
}
pub struct ClosedTargetEventStream {
event_receiver: fidl::client::EventReceiver<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl std::marker::Unpin for ClosedTargetEventStream {}
impl futures::stream::FusedStream for ClosedTargetEventStream {
fn is_terminated(&self) -> bool {
self.event_receiver.is_terminated()
}
}
impl futures::Stream for ClosedTargetEventStream {
type Item = Result<ClosedTargetEvent, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
match futures::ready!(futures::stream::StreamExt::poll_next_unpin(
&mut self.event_receiver,
cx
)?) {
Some(buf) => std::task::Poll::Ready(Some(ClosedTargetEvent::decode(buf))),
None => std::task::Poll::Ready(None),
}
}
}
#[derive(Debug)]
pub enum ClosedTargetEvent {
OnEventNoPayload {},
OnEventStructPayload { some_field: i32 },
OnEventTablePayload { payload: TablePayload },
OnEventUnionPayload { payload: UnionPayload },
}
impl ClosedTargetEvent {
#[allow(irrefutable_let_patterns)]
pub fn into_on_event_no_payload(self) -> Option<()> {
if let ClosedTargetEvent::OnEventNoPayload {} = self {
Some(())
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_on_event_struct_payload(self) -> Option<i32> {
if let ClosedTargetEvent::OnEventStructPayload { some_field } = self {
Some((some_field))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_on_event_table_payload(self) -> Option<TablePayload> {
if let ClosedTargetEvent::OnEventTablePayload { payload } = self {
Some((payload))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_on_event_union_payload(self) -> Option<UnionPayload> {
if let ClosedTargetEvent::OnEventUnionPayload { payload } = self {
Some((payload))
} else {
None
}
}
fn decode(
mut buf: <fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc,
) -> Result<ClosedTargetEvent, fidl::Error> {
let (bytes, _handles) = buf.split_mut();
let (tx_header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
debug_assert_eq!(tx_header.tx_id, 0);
match tx_header.ordinal {
0x4ee7b8d3e6bb36a6 => {
let mut out = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&tx_header, _body_bytes, _handles, &mut out)?;
Ok((ClosedTargetEvent::OnEventNoPayload {}))
}
0x48e8c897893ae266 => {
let mut out = fidl::new_empty!(
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<NonEmptyPayload>(&tx_header, _body_bytes, _handles, &mut out)?;
Ok((ClosedTargetEvent::OnEventStructPayload { some_field: out.some_field }))
}
0x72837525f4f3e746 => {
let mut out =
fidl::new_empty!(TablePayload, fidl::encoding::DefaultFuchsiaResourceDialect);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<TablePayload>(&tx_header, _body_bytes, _handles, &mut out)?;
Ok((ClosedTargetEvent::OnEventTablePayload { payload: out }))
}
0x69c6390e1ac48ea0 => {
let mut out =
fidl::new_empty!(UnionPayload, fidl::encoding::DefaultFuchsiaResourceDialect);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<UnionPayload>(&tx_header, _body_bytes, _handles, &mut out)?;
Ok((ClosedTargetEvent::OnEventUnionPayload { payload: out }))
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: tx_header.ordinal,
protocol_name: <ClosedTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}
}
}
pub struct ClosedTargetRequestStream {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
}
impl std::marker::Unpin for ClosedTargetRequestStream {}
impl futures::stream::FusedStream for ClosedTargetRequestStream {
fn is_terminated(&self) -> bool {
self.is_terminated
}
}
impl fidl::endpoints::RequestStream for ClosedTargetRequestStream {
type Protocol = ClosedTargetMarker;
type ControlHandle = ClosedTargetControlHandle;
fn from_channel(channel: ::fidl::AsyncChannel) -> Self {
Self { inner: std::sync::Arc::new(fidl::ServeInner::new(channel)), is_terminated: false }
}
fn control_handle(&self) -> Self::ControlHandle {
ClosedTargetControlHandle { inner: self.inner.clone() }
}
fn into_inner(
self,
) -> (::std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>, bool)
{
(self.inner, self.is_terminated)
}
fn from_inner(
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
) -> Self {
Self { inner, is_terminated }
}
}
impl futures::Stream for ClosedTargetRequestStream {
type Item = Result<ClosedTargetRequest, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
let this = &mut *self;
if this.inner.check_shutdown(cx) {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
if this.is_terminated {
panic!("polled ClosedTargetRequestStream after completion");
}
fidl::encoding::with_tls_decode_buf::<_, fidl::encoding::DefaultFuchsiaResourceDialect>(
|bytes, handles| {
match this.inner.channel().read_etc(cx, bytes, handles) {
std::task::Poll::Ready(Ok(())) => {}
std::task::Poll::Pending => return std::task::Poll::Pending,
std::task::Poll::Ready(Err(zx_status::Status::PEER_CLOSED)) => {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
std::task::Poll::Ready(Err(e)) => {
return std::task::Poll::Ready(Some(Err(fidl::Error::ServerRequestRead(
e.into(),
))))
}
}
let (header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
std::task::Poll::Ready(Some(match header.ordinal {
0x7a722961424c1720 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayNoPayload {
responder: ClosedTargetTwoWayNoPayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x3a402118bad781bd => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayStructPayload {
responder: ClosedTargetTwoWayStructPayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x53be101c241c66bc => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayTablePayload {
responder: ClosedTargetTwoWayTablePayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x1ff7f745ab608f8c => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayUnionPayload {
responder: ClosedTargetTwoWayUnionPayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x62b4861c443bbc0b => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayStructPayloadErr {
responder: ClosedTargetTwoWayStructPayloadErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x4ff77b4a913be5b6 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<NonEmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayStructRequest {
some_field: req.some_field,
responder: ClosedTargetTwoWayStructRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x3d38ad5b0f4f49cf => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
TablePayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<TablePayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayTableRequest {
payload: req,
responder: ClosedTargetTwoWayTableRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x7adb1c265a378e77 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
UnionPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<UnionPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::TwoWayUnionRequest {
payload: req,
responder: ClosedTargetTwoWayUnionRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0xc376730a2cd8a05 => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::OneWayNoRequest { control_handle })
}
0x2618da6f51e0dcd2 => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<NonEmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::OneWayStructRequest {
some_field: req.some_field,
control_handle,
})
}
0x1a4b7d32eaed401f => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(
TablePayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<TablePayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::OneWayTableRequest { payload: req, control_handle })
}
0x142b3cd9ea530de5 => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(
UnionPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<UnionPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle =
ClosedTargetControlHandle { inner: this.inner.clone() };
Ok(ClosedTargetRequest::OneWayUnionRequest { payload: req, control_handle })
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: header.ordinal,
protocol_name:
<ClosedTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}))
},
)
}
}
#[derive(Debug)]
pub enum ClosedTargetRequest {
TwoWayNoPayload { responder: ClosedTargetTwoWayNoPayloadResponder },
TwoWayStructPayload { responder: ClosedTargetTwoWayStructPayloadResponder },
TwoWayTablePayload { responder: ClosedTargetTwoWayTablePayloadResponder },
TwoWayUnionPayload { responder: ClosedTargetTwoWayUnionPayloadResponder },
TwoWayStructPayloadErr { responder: ClosedTargetTwoWayStructPayloadErrResponder },
TwoWayStructRequest { some_field: i32, responder: ClosedTargetTwoWayStructRequestResponder },
TwoWayTableRequest { payload: TablePayload, responder: ClosedTargetTwoWayTableRequestResponder },
TwoWayUnionRequest { payload: UnionPayload, responder: ClosedTargetTwoWayUnionRequestResponder },
OneWayNoRequest { control_handle: ClosedTargetControlHandle },
OneWayStructRequest { some_field: i32, control_handle: ClosedTargetControlHandle },
OneWayTableRequest { payload: TablePayload, control_handle: ClosedTargetControlHandle },
OneWayUnionRequest { payload: UnionPayload, control_handle: ClosedTargetControlHandle },
}
impl ClosedTargetRequest {
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_no_payload(self) -> Option<(ClosedTargetTwoWayNoPayloadResponder)> {
if let ClosedTargetRequest::TwoWayNoPayload { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_struct_payload(self) -> Option<(ClosedTargetTwoWayStructPayloadResponder)> {
if let ClosedTargetRequest::TwoWayStructPayload { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_table_payload(self) -> Option<(ClosedTargetTwoWayTablePayloadResponder)> {
if let ClosedTargetRequest::TwoWayTablePayload { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_union_payload(self) -> Option<(ClosedTargetTwoWayUnionPayloadResponder)> {
if let ClosedTargetRequest::TwoWayUnionPayload { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_struct_payload_err(
self,
) -> Option<(ClosedTargetTwoWayStructPayloadErrResponder)> {
if let ClosedTargetRequest::TwoWayStructPayloadErr { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_struct_request(
self,
) -> Option<(i32, ClosedTargetTwoWayStructRequestResponder)> {
if let ClosedTargetRequest::TwoWayStructRequest { some_field, responder } = self {
Some((some_field, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_table_request(
self,
) -> Option<(TablePayload, ClosedTargetTwoWayTableRequestResponder)> {
if let ClosedTargetRequest::TwoWayTableRequest { payload, responder } = self {
Some((payload, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_two_way_union_request(
self,
) -> Option<(UnionPayload, ClosedTargetTwoWayUnionRequestResponder)> {
if let ClosedTargetRequest::TwoWayUnionRequest { payload, responder } = self {
Some((payload, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_one_way_no_request(self) -> Option<(ClosedTargetControlHandle)> {
if let ClosedTargetRequest::OneWayNoRequest { control_handle } = self {
Some((control_handle))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_one_way_struct_request(self) -> Option<(i32, ClosedTargetControlHandle)> {
if let ClosedTargetRequest::OneWayStructRequest { some_field, control_handle } = self {
Some((some_field, control_handle))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_one_way_table_request(self) -> Option<(TablePayload, ClosedTargetControlHandle)> {
if let ClosedTargetRequest::OneWayTableRequest { payload, control_handle } = self {
Some((payload, control_handle))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_one_way_union_request(self) -> Option<(UnionPayload, ClosedTargetControlHandle)> {
if let ClosedTargetRequest::OneWayUnionRequest { payload, control_handle } = self {
Some((payload, control_handle))
} else {
None
}
}
pub fn method_name(&self) -> &'static str {
match *self {
ClosedTargetRequest::TwoWayNoPayload { .. } => "two_way_no_payload",
ClosedTargetRequest::TwoWayStructPayload { .. } => "two_way_struct_payload",
ClosedTargetRequest::TwoWayTablePayload { .. } => "two_way_table_payload",
ClosedTargetRequest::TwoWayUnionPayload { .. } => "two_way_union_payload",
ClosedTargetRequest::TwoWayStructPayloadErr { .. } => "two_way_struct_payload_err",
ClosedTargetRequest::TwoWayStructRequest { .. } => "two_way_struct_request",
ClosedTargetRequest::TwoWayTableRequest { .. } => "two_way_table_request",
ClosedTargetRequest::TwoWayUnionRequest { .. } => "two_way_union_request",
ClosedTargetRequest::OneWayNoRequest { .. } => "one_way_no_request",
ClosedTargetRequest::OneWayStructRequest { .. } => "one_way_struct_request",
ClosedTargetRequest::OneWayTableRequest { .. } => "one_way_table_request",
ClosedTargetRequest::OneWayUnionRequest { .. } => "one_way_union_request",
}
}
}
#[derive(Debug, Clone)]
pub struct ClosedTargetControlHandle {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
}
impl fidl::endpoints::ControlHandle for ClosedTargetControlHandle {
fn shutdown(&self) {
self.inner.shutdown()
}
fn shutdown_with_epitaph(&self, status: zx_status::Status) {
self.inner.shutdown_with_epitaph(status)
}
fn is_closed(&self) -> bool {
self.inner.channel().is_closed()
}
fn on_closed(&self) -> fidl::OnSignalsRef<'_> {
self.inner.channel().on_closed()
}
#[cfg(target_os = "fuchsia")]
fn signal_peer(
&self,
clear_mask: zx::Signals,
set_mask: zx::Signals,
) -> Result<(), zx_status::Status> {
use fidl::Peered;
self.inner.channel().signal_peer(clear_mask, set_mask)
}
}
impl ClosedTargetControlHandle {
pub fn send_on_event_no_payload(&self) -> Result<(), fidl::Error> {
self.inner.send::<fidl::encoding::EmptyPayload>(
(),
0,
0x4ee7b8d3e6bb36a6,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn send_on_event_struct_payload(&self, mut some_field: i32) -> Result<(), fidl::Error> {
self.inner.send::<NonEmptyPayload>(
(some_field,),
0,
0x48e8c897893ae266,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn send_on_event_table_payload(
&self,
mut payload: &TablePayload,
) -> Result<(), fidl::Error> {
self.inner.send::<TablePayload>(
payload,
0,
0x72837525f4f3e746,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn send_on_event_union_payload(
&self,
mut payload: &UnionPayload,
) -> Result<(), fidl::Error> {
self.inner.send::<UnionPayload>(
payload,
0,
0x69c6390e1ac48ea0,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayNoPayloadResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayNoPayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayNoPayloadResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayNoPayloadResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0x7a722961424c1720,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayStructPayloadResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayStructPayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayStructPayloadResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayStructPayloadResponder {
pub fn send(self, mut some_field: i32) -> Result<(), fidl::Error> {
let _result = self.send_raw(some_field);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut some_field: i32) -> Result<(), fidl::Error> {
let _result = self.send_raw(some_field);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut some_field: i32) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyPayload>(
(some_field,),
self.tx_id,
0x3a402118bad781bd,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayTablePayloadResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayTablePayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayTablePayloadResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayTablePayloadResponder {
pub fn send(self, mut payload: &TablePayload) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut payload: &TablePayload) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &TablePayload) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<TablePayload>(
payload,
self.tx_id,
0x53be101c241c66bc,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayUnionPayloadResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayUnionPayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayUnionPayloadResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayUnionPayloadResponder {
pub fn send(self, mut payload: &UnionPayload) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut payload: &UnionPayload) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &UnionPayload) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<UnionPayload>(
payload,
self.tx_id,
0x1ff7f745ab608f8c,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayStructPayloadErrResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayStructPayloadErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayStructPayloadErrResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayStructPayloadErrResponder {
pub fn send(self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::ResultType<NonEmptyPayload, i32>>(
result.map(|some_field| (some_field,)),
self.tx_id,
0x62b4861c443bbc0b,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayStructRequestResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayStructRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayStructRequestResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayStructRequestResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0x4ff77b4a913be5b6,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayTableRequestResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayTableRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayTableRequestResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayTableRequestResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0x3d38ad5b0f4f49cf,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct ClosedTargetTwoWayUnionRequestResponder {
control_handle: std::mem::ManuallyDrop<ClosedTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for ClosedTargetTwoWayUnionRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for ClosedTargetTwoWayUnionRequestResponder {
type ControlHandle = ClosedTargetControlHandle;
fn control_handle(&self) -> &ClosedTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl ClosedTargetTwoWayUnionRequestResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0x7adb1c265a378e77,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct ClosedTargetEventReporterMarker;
impl fidl::endpoints::ProtocolMarker for ClosedTargetEventReporterMarker {
type Proxy = ClosedTargetEventReporterProxy;
type RequestStream = ClosedTargetEventReporterRequestStream;
#[cfg(target_os = "fuchsia")]
type SynchronousProxy = ClosedTargetEventReporterSynchronousProxy;
const DEBUG_NAME: &'static str = "(anonymous) ClosedTargetEventReporter";
}
pub trait ClosedTargetEventReporterProxyInterface: Send + Sync {
fn r#report_event(&self, payload: &ClosedTargetEventReport) -> Result<(), fidl::Error>;
}
#[derive(Debug)]
#[cfg(target_os = "fuchsia")]
pub struct ClosedTargetEventReporterSynchronousProxy {
client: fidl::client::sync::Client,
}
#[cfg(target_os = "fuchsia")]
impl fidl::endpoints::SynchronousProxy for ClosedTargetEventReporterSynchronousProxy {
type Proxy = ClosedTargetEventReporterProxy;
type Protocol = ClosedTargetEventReporterMarker;
fn from_channel(inner: fidl::Channel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
fn as_channel(&self) -> &fidl::Channel {
self.client.as_channel()
}
}
#[cfg(target_os = "fuchsia")]
impl ClosedTargetEventReporterSynchronousProxy {
pub fn new(channel: fidl::Channel) -> Self {
let protocol_name =
<ClosedTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::sync::Client::new(channel, protocol_name) }
}
pub fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
pub fn wait_for_event(
&self,
deadline: zx::MonotonicInstant,
) -> Result<ClosedTargetEventReporterEvent, fidl::Error> {
ClosedTargetEventReporterEvent::decode(self.client.wait_for_event(deadline)?)
}
pub fn r#report_event(&self, mut payload: &ClosedTargetEventReport) -> Result<(), fidl::Error> {
self.client.send::<ClosedTargetEventReport>(
payload,
0x63890e67649a846e,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[derive(Debug, Clone)]
pub struct ClosedTargetEventReporterProxy {
client: fidl::client::Client<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl fidl::endpoints::Proxy for ClosedTargetEventReporterProxy {
type Protocol = ClosedTargetEventReporterMarker;
fn from_channel(inner: ::fidl::AsyncChannel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> Result<::fidl::AsyncChannel, Self> {
self.client.into_channel().map_err(|client| Self { client })
}
fn as_channel(&self) -> &::fidl::AsyncChannel {
self.client.as_channel()
}
}
impl ClosedTargetEventReporterProxy {
pub fn new(channel: ::fidl::AsyncChannel) -> Self {
let protocol_name =
<ClosedTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::Client::new(channel, protocol_name) }
}
pub fn take_event_stream(&self) -> ClosedTargetEventReporterEventStream {
ClosedTargetEventReporterEventStream { event_receiver: self.client.take_event_receiver() }
}
pub fn r#report_event(&self, mut payload: &ClosedTargetEventReport) -> Result<(), fidl::Error> {
ClosedTargetEventReporterProxyInterface::r#report_event(self, payload)
}
}
impl ClosedTargetEventReporterProxyInterface for ClosedTargetEventReporterProxy {
fn r#report_event(&self, mut payload: &ClosedTargetEventReport) -> Result<(), fidl::Error> {
self.client.send::<ClosedTargetEventReport>(
payload,
0x63890e67649a846e,
fidl::encoding::DynamicFlags::empty(),
)
}
}
pub struct ClosedTargetEventReporterEventStream {
event_receiver: fidl::client::EventReceiver<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl std::marker::Unpin for ClosedTargetEventReporterEventStream {}
impl futures::stream::FusedStream for ClosedTargetEventReporterEventStream {
fn is_terminated(&self) -> bool {
self.event_receiver.is_terminated()
}
}
impl futures::Stream for ClosedTargetEventReporterEventStream {
type Item = Result<ClosedTargetEventReporterEvent, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
match futures::ready!(futures::stream::StreamExt::poll_next_unpin(
&mut self.event_receiver,
cx
)?) {
Some(buf) => std::task::Poll::Ready(Some(ClosedTargetEventReporterEvent::decode(buf))),
None => std::task::Poll::Ready(None),
}
}
}
#[derive(Debug)]
pub enum ClosedTargetEventReporterEvent {}
impl ClosedTargetEventReporterEvent {
fn decode(
mut buf: <fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc,
) -> Result<ClosedTargetEventReporterEvent, fidl::Error> {
let (bytes, _handles) = buf.split_mut();
let (tx_header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
debug_assert_eq!(tx_header.tx_id, 0);
match tx_header.ordinal {
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: tx_header.ordinal,
protocol_name:
<ClosedTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}
}
}
pub struct ClosedTargetEventReporterRequestStream {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
}
impl std::marker::Unpin for ClosedTargetEventReporterRequestStream {}
impl futures::stream::FusedStream for ClosedTargetEventReporterRequestStream {
fn is_terminated(&self) -> bool {
self.is_terminated
}
}
impl fidl::endpoints::RequestStream for ClosedTargetEventReporterRequestStream {
type Protocol = ClosedTargetEventReporterMarker;
type ControlHandle = ClosedTargetEventReporterControlHandle;
fn from_channel(channel: ::fidl::AsyncChannel) -> Self {
Self { inner: std::sync::Arc::new(fidl::ServeInner::new(channel)), is_terminated: false }
}
fn control_handle(&self) -> Self::ControlHandle {
ClosedTargetEventReporterControlHandle { inner: self.inner.clone() }
}
fn into_inner(
self,
) -> (::std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>, bool)
{
(self.inner, self.is_terminated)
}
fn from_inner(
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
) -> Self {
Self { inner, is_terminated }
}
}
impl futures::Stream for ClosedTargetEventReporterRequestStream {
type Item = Result<ClosedTargetEventReporterRequest, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
let this = &mut *self;
if this.inner.check_shutdown(cx) {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
if this.is_terminated {
panic!("polled ClosedTargetEventReporterRequestStream after completion");
}
fidl::encoding::with_tls_decode_buf::<_, fidl::encoding::DefaultFuchsiaResourceDialect>(
|bytes, handles| {
match this.inner.channel().read_etc(cx, bytes, handles) {
std::task::Poll::Ready(Ok(())) => {}
std::task::Poll::Pending => return std::task::Poll::Pending,
std::task::Poll::Ready(Err(zx_status::Status::PEER_CLOSED)) => {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
std::task::Poll::Ready(Err(e)) => {
return std::task::Poll::Ready(Some(Err(fidl::Error::ServerRequestRead(
e.into(),
))))
}
}
let (header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
std::task::Poll::Ready(Some(match header.ordinal {
0x63890e67649a846e => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(ClosedTargetEventReport, fidl::encoding::DefaultFuchsiaResourceDialect);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<ClosedTargetEventReport>(&header, _body_bytes, handles, &mut req)?;
let control_handle = ClosedTargetEventReporterControlHandle {
inner: this.inner.clone(),
};
Ok(ClosedTargetEventReporterRequest::ReportEvent {payload: req,
control_handle,
})
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: header.ordinal,
protocol_name: <ClosedTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}))
},
)
}
}
#[derive(Debug)]
pub enum ClosedTargetEventReporterRequest {
ReportEvent {
payload: ClosedTargetEventReport,
control_handle: ClosedTargetEventReporterControlHandle,
},
}
impl ClosedTargetEventReporterRequest {
#[allow(irrefutable_let_patterns)]
pub fn into_report_event(
self,
) -> Option<(ClosedTargetEventReport, ClosedTargetEventReporterControlHandle)> {
if let ClosedTargetEventReporterRequest::ReportEvent { payload, control_handle } = self {
Some((payload, control_handle))
} else {
None
}
}
pub fn method_name(&self) -> &'static str {
match *self {
ClosedTargetEventReporterRequest::ReportEvent { .. } => "report_event",
}
}
}
#[derive(Debug, Clone)]
pub struct ClosedTargetEventReporterControlHandle {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
}
impl fidl::endpoints::ControlHandle for ClosedTargetEventReporterControlHandle {
fn shutdown(&self) {
self.inner.shutdown()
}
fn shutdown_with_epitaph(&self, status: zx_status::Status) {
self.inner.shutdown_with_epitaph(status)
}
fn is_closed(&self) -> bool {
self.inner.channel().is_closed()
}
fn on_closed(&self) -> fidl::OnSignalsRef<'_> {
self.inner.channel().on_closed()
}
#[cfg(target_os = "fuchsia")]
fn signal_peer(
&self,
clear_mask: zx::Signals,
set_mask: zx::Signals,
) -> Result<(), zx_status::Status> {
use fidl::Peered;
self.inner.channel().signal_peer(clear_mask, set_mask)
}
}
impl ClosedTargetEventReporterControlHandle {}
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct OpenTargetMarker;
impl fidl::endpoints::ProtocolMarker for OpenTargetMarker {
type Proxy = OpenTargetProxy;
type RequestStream = OpenTargetRequestStream;
#[cfg(target_os = "fuchsia")]
type SynchronousProxy = OpenTargetSynchronousProxy;
const DEBUG_NAME: &'static str = "(anonymous) OpenTarget";
}
pub type OpenTargetStrictTwoWayErrResult = Result<(), i32>;
pub type OpenTargetStrictTwoWayFieldsErrResult = Result<i32, i32>;
pub type OpenTargetFlexibleTwoWayErrResult = Result<(), i32>;
pub type OpenTargetFlexibleTwoWayFieldsErrResult = Result<i32, i32>;
pub trait OpenTargetProxyInterface: Send + Sync {
fn r#strict_one_way(&self) -> Result<(), fidl::Error>;
fn r#flexible_one_way(&self) -> Result<(), fidl::Error>;
type StrictTwoWayResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#strict_two_way(&self) -> Self::StrictTwoWayResponseFut;
type StrictTwoWayFieldsResponseFut: std::future::Future<Output = Result<i32, fidl::Error>>
+ Send;
fn r#strict_two_way_fields(&self) -> Self::StrictTwoWayFieldsResponseFut;
type StrictTwoWayErrResponseFut: std::future::Future<Output = Result<OpenTargetStrictTwoWayErrResult, fidl::Error>>
+ Send;
fn r#strict_two_way_err(&self) -> Self::StrictTwoWayErrResponseFut;
type StrictTwoWayFieldsErrResponseFut: std::future::Future<Output = Result<OpenTargetStrictTwoWayFieldsErrResult, fidl::Error>>
+ Send;
fn r#strict_two_way_fields_err(&self) -> Self::StrictTwoWayFieldsErrResponseFut;
type FlexibleTwoWayResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#flexible_two_way(&self) -> Self::FlexibleTwoWayResponseFut;
type FlexibleTwoWayFieldsResponseFut: std::future::Future<Output = Result<i32, fidl::Error>>
+ Send;
fn r#flexible_two_way_fields(&self) -> Self::FlexibleTwoWayFieldsResponseFut;
type FlexibleTwoWayErrResponseFut: std::future::Future<Output = Result<OpenTargetFlexibleTwoWayErrResult, fidl::Error>>
+ Send;
fn r#flexible_two_way_err(&self) -> Self::FlexibleTwoWayErrResponseFut;
type FlexibleTwoWayFieldsErrResponseFut: std::future::Future<Output = Result<OpenTargetFlexibleTwoWayFieldsErrResult, fidl::Error>>
+ Send;
fn r#flexible_two_way_fields_err(&self) -> Self::FlexibleTwoWayFieldsErrResponseFut;
}
#[derive(Debug)]
#[cfg(target_os = "fuchsia")]
pub struct OpenTargetSynchronousProxy {
client: fidl::client::sync::Client,
}
#[cfg(target_os = "fuchsia")]
impl fidl::endpoints::SynchronousProxy for OpenTargetSynchronousProxy {
type Proxy = OpenTargetProxy;
type Protocol = OpenTargetMarker;
fn from_channel(inner: fidl::Channel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
fn as_channel(&self) -> &fidl::Channel {
self.client.as_channel()
}
}
#[cfg(target_os = "fuchsia")]
impl OpenTargetSynchronousProxy {
pub fn new(channel: fidl::Channel) -> Self {
let protocol_name = <OpenTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::sync::Client::new(channel, protocol_name) }
}
pub fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
pub fn wait_for_event(
&self,
deadline: zx::MonotonicInstant,
) -> Result<OpenTargetEvent, fidl::Error> {
OpenTargetEvent::decode(self.client.wait_for_event(deadline)?)
}
pub fn r#strict_one_way(&self) -> Result<(), fidl::Error> {
self.client.send::<fidl::encoding::EmptyPayload>(
(),
0x6db0bc21c4aae764,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn r#flexible_one_way(&self) -> Result<(), fidl::Error> {
self.client.send::<fidl::encoding::EmptyPayload>(
(),
0xf894a7eb9cc29fc,
fidl::encoding::DynamicFlags::FLEXIBLE,
)
}
pub fn r#strict_two_way(&self, ___deadline: zx::MonotonicInstant) -> Result<(), fidl::Error> {
let _response =
self.client.send_query::<fidl::encoding::EmptyPayload, fidl::encoding::EmptyPayload>(
(),
0xdcf4cef19a1c542,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#strict_two_way_fields(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<i32, fidl::Error> {
let _response = self.client.send_query::<fidl::encoding::EmptyPayload, NonEmptyPayload>(
(),
0x79c7a7803c45e2e3,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response.some_field)
}
pub fn r#strict_two_way_err(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<OpenTargetStrictTwoWayErrResult, fidl::Error> {
let _response = self.client.send_query::<
fidl::encoding::EmptyPayload,
fidl::encoding::ResultType<fidl::encoding::EmptyStruct, i32>,
>(
(),
0x54259ed6c262fe88,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response.map(|x| x))
}
pub fn r#strict_two_way_fields_err(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<OpenTargetStrictTwoWayFieldsErrResult, fidl::Error> {
let _response = self.client.send_query::<
fidl::encoding::EmptyPayload,
fidl::encoding::ResultType<NonEmptyPayload, i32>,
>(
(),
0x7dbaa8538b552711,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response.map(|x| x.some_field))
}
pub fn r#flexible_two_way(&self, ___deadline: zx::MonotonicInstant) -> Result<(), fidl::Error> {
let _response = self.client.send_query::<
fidl::encoding::EmptyPayload,
fidl::encoding::FlexibleType<fidl::encoding::EmptyStruct>,
>(
(),
0x66552e68b99a0587,
fidl::encoding::DynamicFlags::FLEXIBLE,
___deadline,
)?
.into_result::<OpenTargetMarker>("flexible_two_way")?;
Ok(_response)
}
pub fn r#flexible_two_way_fields(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<i32, fidl::Error> {
let _response = self.client.send_query::<
fidl::encoding::EmptyPayload,
fidl::encoding::FlexibleType<NonEmptyPayload>,
>(
(),
0x38b95648ac4e2ae4,
fidl::encoding::DynamicFlags::FLEXIBLE,
___deadline,
)?
.into_result::<OpenTargetMarker>("flexible_two_way_fields")?;
Ok(_response.some_field)
}
pub fn r#flexible_two_way_err(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<OpenTargetFlexibleTwoWayErrResult, fidl::Error> {
let _response = self.client.send_query::<
fidl::encoding::EmptyPayload,
fidl::encoding::FlexibleResultType<fidl::encoding::EmptyStruct, i32>,
>(
(),
0x6e144c6e0cf2147a,
fidl::encoding::DynamicFlags::FLEXIBLE,
___deadline,
)?
.into_result::<OpenTargetMarker>("flexible_two_way_err")?;
Ok(_response.map(|x| x))
}
pub fn r#flexible_two_way_fields_err(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<OpenTargetFlexibleTwoWayFieldsErrResult, fidl::Error> {
let _response = self.client.send_query::<
fidl::encoding::EmptyPayload,
fidl::encoding::FlexibleResultType<NonEmptyPayload, i32>,
>(
(),
0xe494147cda8024a,
fidl::encoding::DynamicFlags::FLEXIBLE,
___deadline,
)?
.into_result::<OpenTargetMarker>("flexible_two_way_fields_err")?;
Ok(_response.map(|x| x.some_field))
}
}
#[derive(Debug, Clone)]
pub struct OpenTargetProxy {
client: fidl::client::Client<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl fidl::endpoints::Proxy for OpenTargetProxy {
type Protocol = OpenTargetMarker;
fn from_channel(inner: ::fidl::AsyncChannel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> Result<::fidl::AsyncChannel, Self> {
self.client.into_channel().map_err(|client| Self { client })
}
fn as_channel(&self) -> &::fidl::AsyncChannel {
self.client.as_channel()
}
}
impl OpenTargetProxy {
pub fn new(channel: ::fidl::AsyncChannel) -> Self {
let protocol_name = <OpenTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::Client::new(channel, protocol_name) }
}
pub fn take_event_stream(&self) -> OpenTargetEventStream {
OpenTargetEventStream { event_receiver: self.client.take_event_receiver() }
}
pub fn r#strict_one_way(&self) -> Result<(), fidl::Error> {
OpenTargetProxyInterface::r#strict_one_way(self)
}
pub fn r#flexible_one_way(&self) -> Result<(), fidl::Error> {
OpenTargetProxyInterface::r#flexible_one_way(self)
}
pub fn r#strict_two_way(
&self,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
OpenTargetProxyInterface::r#strict_two_way(self)
}
pub fn r#strict_two_way_fields(
&self,
) -> fidl::client::QueryResponseFut<i32, fidl::encoding::DefaultFuchsiaResourceDialect> {
OpenTargetProxyInterface::r#strict_two_way_fields(self)
}
pub fn r#strict_two_way_err(
&self,
) -> fidl::client::QueryResponseFut<
OpenTargetStrictTwoWayErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
OpenTargetProxyInterface::r#strict_two_way_err(self)
}
pub fn r#strict_two_way_fields_err(
&self,
) -> fidl::client::QueryResponseFut<
OpenTargetStrictTwoWayFieldsErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
OpenTargetProxyInterface::r#strict_two_way_fields_err(self)
}
pub fn r#flexible_two_way(
&self,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
OpenTargetProxyInterface::r#flexible_two_way(self)
}
pub fn r#flexible_two_way_fields(
&self,
) -> fidl::client::QueryResponseFut<i32, fidl::encoding::DefaultFuchsiaResourceDialect> {
OpenTargetProxyInterface::r#flexible_two_way_fields(self)
}
pub fn r#flexible_two_way_err(
&self,
) -> fidl::client::QueryResponseFut<
OpenTargetFlexibleTwoWayErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
OpenTargetProxyInterface::r#flexible_two_way_err(self)
}
pub fn r#flexible_two_way_fields_err(
&self,
) -> fidl::client::QueryResponseFut<
OpenTargetFlexibleTwoWayFieldsErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
OpenTargetProxyInterface::r#flexible_two_way_fields_err(self)
}
}
impl OpenTargetProxyInterface for OpenTargetProxy {
fn r#strict_one_way(&self) -> Result<(), fidl::Error> {
self.client.send::<fidl::encoding::EmptyPayload>(
(),
0x6db0bc21c4aae764,
fidl::encoding::DynamicFlags::empty(),
)
}
fn r#flexible_one_way(&self) -> Result<(), fidl::Error> {
self.client.send::<fidl::encoding::EmptyPayload>(
(),
0xf894a7eb9cc29fc,
fidl::encoding::DynamicFlags::FLEXIBLE,
)
}
type StrictTwoWayResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#strict_two_way(&self) -> Self::StrictTwoWayResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0xdcf4cef19a1c542,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, ()>(
(),
0xdcf4cef19a1c542,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type StrictTwoWayFieldsResponseFut =
fidl::client::QueryResponseFut<i32, fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#strict_two_way_fields(&self) -> Self::StrictTwoWayFieldsResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<i32, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x79c7a7803c45e2e3,
>(_buf?)?;
Ok(_response.some_field)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, i32>(
(),
0x79c7a7803c45e2e3,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type StrictTwoWayErrResponseFut = fidl::client::QueryResponseFut<
OpenTargetStrictTwoWayErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#strict_two_way_err(&self) -> Self::StrictTwoWayErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<OpenTargetStrictTwoWayErrResult, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::ResultType<fidl::encoding::EmptyStruct, i32>,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x54259ed6c262fe88,
>(_buf?)?;
Ok(_response.map(|x| x))
}
self.client
.send_query_and_decode::<fidl::encoding::EmptyPayload, OpenTargetStrictTwoWayErrResult>(
(),
0x54259ed6c262fe88,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type StrictTwoWayFieldsErrResponseFut = fidl::client::QueryResponseFut<
OpenTargetStrictTwoWayFieldsErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#strict_two_way_fields_err(&self) -> Self::StrictTwoWayFieldsErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<OpenTargetStrictTwoWayFieldsErrResult, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::ResultType<NonEmptyPayload, i32>,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x7dbaa8538b552711,
>(_buf?)?;
Ok(_response.map(|x| x.some_field))
}
self.client.send_query_and_decode::<
fidl::encoding::EmptyPayload,
OpenTargetStrictTwoWayFieldsErrResult,
>(
(),
0x7dbaa8538b552711,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type FlexibleTwoWayResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#flexible_two_way(&self) -> Self::FlexibleTwoWayResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::FlexibleType<fidl::encoding::EmptyStruct>,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x66552e68b99a0587,
>(_buf?)?
.into_result::<OpenTargetMarker>("flexible_two_way")?;
Ok(_response)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, ()>(
(),
0x66552e68b99a0587,
fidl::encoding::DynamicFlags::FLEXIBLE,
_decode,
)
}
type FlexibleTwoWayFieldsResponseFut =
fidl::client::QueryResponseFut<i32, fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#flexible_two_way_fields(&self) -> Self::FlexibleTwoWayFieldsResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<i32, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::FlexibleType<NonEmptyPayload>,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x38b95648ac4e2ae4,
>(_buf?)?
.into_result::<OpenTargetMarker>("flexible_two_way_fields")?;
Ok(_response.some_field)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, i32>(
(),
0x38b95648ac4e2ae4,
fidl::encoding::DynamicFlags::FLEXIBLE,
_decode,
)
}
type FlexibleTwoWayErrResponseFut = fidl::client::QueryResponseFut<
OpenTargetFlexibleTwoWayErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#flexible_two_way_err(&self) -> Self::FlexibleTwoWayErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<OpenTargetFlexibleTwoWayErrResult, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::FlexibleResultType<fidl::encoding::EmptyStruct, i32>,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x6e144c6e0cf2147a,
>(_buf?)?
.into_result::<OpenTargetMarker>("flexible_two_way_err")?;
Ok(_response.map(|x| x))
}
self.client.send_query_and_decode::<
fidl::encoding::EmptyPayload,
OpenTargetFlexibleTwoWayErrResult,
>(
(),
0x6e144c6e0cf2147a,
fidl::encoding::DynamicFlags::FLEXIBLE,
_decode,
)
}
type FlexibleTwoWayFieldsErrResponseFut = fidl::client::QueryResponseFut<
OpenTargetFlexibleTwoWayFieldsErrResult,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#flexible_two_way_fields_err(&self) -> Self::FlexibleTwoWayFieldsErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<OpenTargetFlexibleTwoWayFieldsErrResult, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::FlexibleResultType<NonEmptyPayload, i32>,
fidl::encoding::DefaultFuchsiaResourceDialect,
0xe494147cda8024a,
>(_buf?)?
.into_result::<OpenTargetMarker>("flexible_two_way_fields_err")?;
Ok(_response.map(|x| x.some_field))
}
self.client.send_query_and_decode::<
fidl::encoding::EmptyPayload,
OpenTargetFlexibleTwoWayFieldsErrResult,
>(
(),
0xe494147cda8024a,
fidl::encoding::DynamicFlags::FLEXIBLE,
_decode,
)
}
}
pub struct OpenTargetEventStream {
event_receiver: fidl::client::EventReceiver<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl std::marker::Unpin for OpenTargetEventStream {}
impl futures::stream::FusedStream for OpenTargetEventStream {
fn is_terminated(&self) -> bool {
self.event_receiver.is_terminated()
}
}
impl futures::Stream for OpenTargetEventStream {
type Item = Result<OpenTargetEvent, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
match futures::ready!(futures::stream::StreamExt::poll_next_unpin(
&mut self.event_receiver,
cx
)?) {
Some(buf) => std::task::Poll::Ready(Some(OpenTargetEvent::decode(buf))),
None => std::task::Poll::Ready(None),
}
}
}
#[derive(Debug)]
pub enum OpenTargetEvent {
StrictEvent {},
FlexibleEvent {},
#[non_exhaustive]
_UnknownEvent {
ordinal: u64,
},
}
impl OpenTargetEvent {
#[allow(irrefutable_let_patterns)]
pub fn into_strict_event(self) -> Option<()> {
if let OpenTargetEvent::StrictEvent {} = self {
Some(())
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_flexible_event(self) -> Option<()> {
if let OpenTargetEvent::FlexibleEvent {} = self {
Some(())
} else {
None
}
}
fn decode(
mut buf: <fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc,
) -> Result<OpenTargetEvent, fidl::Error> {
let (bytes, _handles) = buf.split_mut();
let (tx_header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
debug_assert_eq!(tx_header.tx_id, 0);
match tx_header.ordinal {
0x2b291d74321e77a0 => {
let mut out = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&tx_header, _body_bytes, _handles, &mut out)?;
Ok((OpenTargetEvent::StrictEvent {}))
}
0x50d4688058898898 => {
let mut out = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&tx_header, _body_bytes, _handles, &mut out)?;
Ok((OpenTargetEvent::FlexibleEvent {}))
}
_ if tx_header.dynamic_flags().contains(fidl::encoding::DynamicFlags::FLEXIBLE) => {
Ok(OpenTargetEvent::_UnknownEvent { ordinal: tx_header.ordinal })
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: tx_header.ordinal,
protocol_name: <OpenTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}
}
}
pub struct OpenTargetRequestStream {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
}
impl std::marker::Unpin for OpenTargetRequestStream {}
impl futures::stream::FusedStream for OpenTargetRequestStream {
fn is_terminated(&self) -> bool {
self.is_terminated
}
}
impl fidl::endpoints::RequestStream for OpenTargetRequestStream {
type Protocol = OpenTargetMarker;
type ControlHandle = OpenTargetControlHandle;
fn from_channel(channel: ::fidl::AsyncChannel) -> Self {
Self { inner: std::sync::Arc::new(fidl::ServeInner::new(channel)), is_terminated: false }
}
fn control_handle(&self) -> Self::ControlHandle {
OpenTargetControlHandle { inner: self.inner.clone() }
}
fn into_inner(
self,
) -> (::std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>, bool)
{
(self.inner, self.is_terminated)
}
fn from_inner(
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
) -> Self {
Self { inner, is_terminated }
}
}
impl futures::Stream for OpenTargetRequestStream {
type Item = Result<OpenTargetRequest, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
let this = &mut *self;
if this.inner.check_shutdown(cx) {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
if this.is_terminated {
panic!("polled OpenTargetRequestStream after completion");
}
fidl::encoding::with_tls_decode_buf::<_, fidl::encoding::DefaultFuchsiaResourceDialect>(
|bytes, handles| {
match this.inner.channel().read_etc(cx, bytes, handles) {
std::task::Poll::Ready(Ok(())) => {}
std::task::Poll::Pending => return std::task::Poll::Pending,
std::task::Poll::Ready(Err(zx_status::Status::PEER_CLOSED)) => {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
std::task::Poll::Ready(Err(e)) => {
return std::task::Poll::Ready(Some(Err(fidl::Error::ServerRequestRead(
e.into(),
))))
}
}
let (header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
std::task::Poll::Ready(Some(match header.ordinal {
0x6db0bc21c4aae764 => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::StrictOneWay { control_handle })
}
0xf894a7eb9cc29fc => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::FlexibleOneWay { control_handle })
}
0xdcf4cef19a1c542 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::StrictTwoWay {
responder: OpenTargetStrictTwoWayResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x79c7a7803c45e2e3 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::StrictTwoWayFields {
responder: OpenTargetStrictTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x54259ed6c262fe88 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::StrictTwoWayErr {
responder: OpenTargetStrictTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x7dbaa8538b552711 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::StrictTwoWayFieldsErr {
responder: OpenTargetStrictTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x66552e68b99a0587 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::FlexibleTwoWay {
responder: OpenTargetFlexibleTwoWayResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x38b95648ac4e2ae4 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::FlexibleTwoWayFields {
responder: OpenTargetFlexibleTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x6e144c6e0cf2147a => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::FlexibleTwoWayErr {
responder: OpenTargetFlexibleTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0xe494147cda8024a => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetControlHandle { inner: this.inner.clone() };
Ok(OpenTargetRequest::FlexibleTwoWayFieldsErr {
responder: OpenTargetFlexibleTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
_ if header.tx_id == 0
&& header
.dynamic_flags()
.contains(fidl::encoding::DynamicFlags::FLEXIBLE) =>
{
Ok(OpenTargetRequest::_UnknownMethod {
ordinal: header.ordinal,
control_handle: OpenTargetControlHandle { inner: this.inner.clone() },
method_type: fidl::MethodType::OneWay,
})
}
_ if header
.dynamic_flags()
.contains(fidl::encoding::DynamicFlags::FLEXIBLE) =>
{
this.inner.send_framework_err(
fidl::encoding::FrameworkErr::UnknownMethod,
header.tx_id,
header.ordinal,
header.dynamic_flags(),
(bytes, handles),
)?;
Ok(OpenTargetRequest::_UnknownMethod {
ordinal: header.ordinal,
control_handle: OpenTargetControlHandle { inner: this.inner.clone() },
method_type: fidl::MethodType::TwoWay,
})
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: header.ordinal,
protocol_name:
<OpenTargetMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}))
},
)
}
}
#[derive(Debug)]
pub enum OpenTargetRequest {
StrictOneWay {
control_handle: OpenTargetControlHandle,
},
FlexibleOneWay {
control_handle: OpenTargetControlHandle,
},
StrictTwoWay {
responder: OpenTargetStrictTwoWayResponder,
},
StrictTwoWayFields {
responder: OpenTargetStrictTwoWayFieldsResponder,
},
StrictTwoWayErr {
responder: OpenTargetStrictTwoWayErrResponder,
},
StrictTwoWayFieldsErr {
responder: OpenTargetStrictTwoWayFieldsErrResponder,
},
FlexibleTwoWay {
responder: OpenTargetFlexibleTwoWayResponder,
},
FlexibleTwoWayFields {
responder: OpenTargetFlexibleTwoWayFieldsResponder,
},
FlexibleTwoWayErr {
responder: OpenTargetFlexibleTwoWayErrResponder,
},
FlexibleTwoWayFieldsErr {
responder: OpenTargetFlexibleTwoWayFieldsErrResponder,
},
#[non_exhaustive]
_UnknownMethod {
ordinal: u64,
control_handle: OpenTargetControlHandle,
method_type: fidl::MethodType,
},
}
impl OpenTargetRequest {
#[allow(irrefutable_let_patterns)]
pub fn into_strict_one_way(self) -> Option<(OpenTargetControlHandle)> {
if let OpenTargetRequest::StrictOneWay { control_handle } = self {
Some((control_handle))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_flexible_one_way(self) -> Option<(OpenTargetControlHandle)> {
if let OpenTargetRequest::FlexibleOneWay { control_handle } = self {
Some((control_handle))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_strict_two_way(self) -> Option<(OpenTargetStrictTwoWayResponder)> {
if let OpenTargetRequest::StrictTwoWay { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_strict_two_way_fields(self) -> Option<(OpenTargetStrictTwoWayFieldsResponder)> {
if let OpenTargetRequest::StrictTwoWayFields { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_strict_two_way_err(self) -> Option<(OpenTargetStrictTwoWayErrResponder)> {
if let OpenTargetRequest::StrictTwoWayErr { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_strict_two_way_fields_err(
self,
) -> Option<(OpenTargetStrictTwoWayFieldsErrResponder)> {
if let OpenTargetRequest::StrictTwoWayFieldsErr { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_flexible_two_way(self) -> Option<(OpenTargetFlexibleTwoWayResponder)> {
if let OpenTargetRequest::FlexibleTwoWay { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_flexible_two_way_fields(self) -> Option<(OpenTargetFlexibleTwoWayFieldsResponder)> {
if let OpenTargetRequest::FlexibleTwoWayFields { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_flexible_two_way_err(self) -> Option<(OpenTargetFlexibleTwoWayErrResponder)> {
if let OpenTargetRequest::FlexibleTwoWayErr { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_flexible_two_way_fields_err(
self,
) -> Option<(OpenTargetFlexibleTwoWayFieldsErrResponder)> {
if let OpenTargetRequest::FlexibleTwoWayFieldsErr { responder } = self {
Some((responder))
} else {
None
}
}
pub fn method_name(&self) -> &'static str {
match *self {
OpenTargetRequest::StrictOneWay { .. } => "strict_one_way",
OpenTargetRequest::FlexibleOneWay { .. } => "flexible_one_way",
OpenTargetRequest::StrictTwoWay { .. } => "strict_two_way",
OpenTargetRequest::StrictTwoWayFields { .. } => "strict_two_way_fields",
OpenTargetRequest::StrictTwoWayErr { .. } => "strict_two_way_err",
OpenTargetRequest::StrictTwoWayFieldsErr { .. } => "strict_two_way_fields_err",
OpenTargetRequest::FlexibleTwoWay { .. } => "flexible_two_way",
OpenTargetRequest::FlexibleTwoWayFields { .. } => "flexible_two_way_fields",
OpenTargetRequest::FlexibleTwoWayErr { .. } => "flexible_two_way_err",
OpenTargetRequest::FlexibleTwoWayFieldsErr { .. } => "flexible_two_way_fields_err",
OpenTargetRequest::_UnknownMethod { method_type: fidl::MethodType::OneWay, .. } => {
"unknown one-way method"
}
OpenTargetRequest::_UnknownMethod { method_type: fidl::MethodType::TwoWay, .. } => {
"unknown two-way method"
}
}
}
}
#[derive(Debug, Clone)]
pub struct OpenTargetControlHandle {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
}
impl fidl::endpoints::ControlHandle for OpenTargetControlHandle {
fn shutdown(&self) {
self.inner.shutdown()
}
fn shutdown_with_epitaph(&self, status: zx_status::Status) {
self.inner.shutdown_with_epitaph(status)
}
fn is_closed(&self) -> bool {
self.inner.channel().is_closed()
}
fn on_closed(&self) -> fidl::OnSignalsRef<'_> {
self.inner.channel().on_closed()
}
#[cfg(target_os = "fuchsia")]
fn signal_peer(
&self,
clear_mask: zx::Signals,
set_mask: zx::Signals,
) -> Result<(), zx_status::Status> {
use fidl::Peered;
self.inner.channel().signal_peer(clear_mask, set_mask)
}
}
impl OpenTargetControlHandle {
pub fn send_strict_event(&self) -> Result<(), fidl::Error> {
self.inner.send::<fidl::encoding::EmptyPayload>(
(),
0,
0x2b291d74321e77a0,
fidl::encoding::DynamicFlags::empty(),
)
}
pub fn send_flexible_event(&self) -> Result<(), fidl::Error> {
self.inner.send::<fidl::encoding::EmptyPayload>(
(),
0,
0x50d4688058898898,
fidl::encoding::DynamicFlags::FLEXIBLE,
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetStrictTwoWayResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetStrictTwoWayResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetStrictTwoWayResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetStrictTwoWayResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0xdcf4cef19a1c542,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetStrictTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetStrictTwoWayFieldsResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetStrictTwoWayFieldsResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetStrictTwoWayFieldsResponder {
pub fn send(self, mut some_field: i32) -> Result<(), fidl::Error> {
let _result = self.send_raw(some_field);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut some_field: i32) -> Result<(), fidl::Error> {
let _result = self.send_raw(some_field);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut some_field: i32) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyPayload>(
(some_field,),
self.tx_id,
0x79c7a7803c45e2e3,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetStrictTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetStrictTwoWayErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetStrictTwoWayErrResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetStrictTwoWayErrResponder {
pub fn send(self, mut result: Result<(), i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut result: Result<(), i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut result: Result<(), i32>) -> Result<(), fidl::Error> {
self.control_handle
.inner
.send::<fidl::encoding::ResultType<fidl::encoding::EmptyStruct, i32>>(
result,
self.tx_id,
0x54259ed6c262fe88,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetStrictTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetStrictTwoWayFieldsErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetStrictTwoWayFieldsErrResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetStrictTwoWayFieldsErrResponder {
pub fn send(self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::ResultType<NonEmptyPayload, i32>>(
result.map(|some_field| (some_field,)),
self.tx_id,
0x7dbaa8538b552711,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetFlexibleTwoWayResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetFlexibleTwoWayResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetFlexibleTwoWayResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetFlexibleTwoWayResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::FlexibleType<fidl::encoding::EmptyStruct>>(
fidl::encoding::Flexible::new(()),
self.tx_id,
0x66552e68b99a0587,
fidl::encoding::DynamicFlags::FLEXIBLE,
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetFlexibleTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetFlexibleTwoWayFieldsResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetFlexibleTwoWayFieldsResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetFlexibleTwoWayFieldsResponder {
pub fn send(self, mut some_field: i32) -> Result<(), fidl::Error> {
let _result = self.send_raw(some_field);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut some_field: i32) -> Result<(), fidl::Error> {
let _result = self.send_raw(some_field);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut some_field: i32) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::FlexibleType<NonEmptyPayload>>(
fidl::encoding::Flexible::new((some_field,)),
self.tx_id,
0x38b95648ac4e2ae4,
fidl::encoding::DynamicFlags::FLEXIBLE,
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetFlexibleTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetFlexibleTwoWayErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetFlexibleTwoWayErrResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetFlexibleTwoWayErrResponder {
pub fn send(self, mut result: Result<(), i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut result: Result<(), i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut result: Result<(), i32>) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::FlexibleResultType<
fidl::encoding::EmptyStruct,
i32,
>>(
fidl::encoding::FlexibleResult::new(result),
self.tx_id,
0x6e144c6e0cf2147a,
fidl::encoding::DynamicFlags::FLEXIBLE,
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct OpenTargetFlexibleTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop<OpenTargetControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for OpenTargetFlexibleTwoWayFieldsErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for OpenTargetFlexibleTwoWayFieldsErrResponder {
type ControlHandle = OpenTargetControlHandle;
fn control_handle(&self) -> &OpenTargetControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl OpenTargetFlexibleTwoWayFieldsErrResponder {
pub fn send(self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
let _result = self.send_raw(result);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut result: Result<i32, i32>) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::FlexibleResultType<NonEmptyPayload, i32>>(
fidl::encoding::FlexibleResult::new(result.map(|some_field| (some_field,))),
self.tx_id,
0xe494147cda8024a,
fidl::encoding::DynamicFlags::FLEXIBLE,
)
}
}
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct OpenTargetEventReporterMarker;
impl fidl::endpoints::ProtocolMarker for OpenTargetEventReporterMarker {
type Proxy = OpenTargetEventReporterProxy;
type RequestStream = OpenTargetEventReporterRequestStream;
#[cfg(target_os = "fuchsia")]
type SynchronousProxy = OpenTargetEventReporterSynchronousProxy;
const DEBUG_NAME: &'static str = "(anonymous) OpenTargetEventReporter";
}
pub trait OpenTargetEventReporterProxyInterface: Send + Sync {
fn r#report_event(&self, payload: &OpenTargetEventReport) -> Result<(), fidl::Error>;
}
#[derive(Debug)]
#[cfg(target_os = "fuchsia")]
pub struct OpenTargetEventReporterSynchronousProxy {
client: fidl::client::sync::Client,
}
#[cfg(target_os = "fuchsia")]
impl fidl::endpoints::SynchronousProxy for OpenTargetEventReporterSynchronousProxy {
type Proxy = OpenTargetEventReporterProxy;
type Protocol = OpenTargetEventReporterMarker;
fn from_channel(inner: fidl::Channel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
fn as_channel(&self) -> &fidl::Channel {
self.client.as_channel()
}
}
#[cfg(target_os = "fuchsia")]
impl OpenTargetEventReporterSynchronousProxy {
pub fn new(channel: fidl::Channel) -> Self {
let protocol_name =
<OpenTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::sync::Client::new(channel, protocol_name) }
}
pub fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
pub fn wait_for_event(
&self,
deadline: zx::MonotonicInstant,
) -> Result<OpenTargetEventReporterEvent, fidl::Error> {
OpenTargetEventReporterEvent::decode(self.client.wait_for_event(deadline)?)
}
pub fn r#report_event(&self, mut payload: &OpenTargetEventReport) -> Result<(), fidl::Error> {
self.client.send::<OpenTargetEventReport>(
payload,
0x70ab38ec0248964a,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[derive(Debug, Clone)]
pub struct OpenTargetEventReporterProxy {
client: fidl::client::Client<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl fidl::endpoints::Proxy for OpenTargetEventReporterProxy {
type Protocol = OpenTargetEventReporterMarker;
fn from_channel(inner: ::fidl::AsyncChannel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> Result<::fidl::AsyncChannel, Self> {
self.client.into_channel().map_err(|client| Self { client })
}
fn as_channel(&self) -> &::fidl::AsyncChannel {
self.client.as_channel()
}
}
impl OpenTargetEventReporterProxy {
pub fn new(channel: ::fidl::AsyncChannel) -> Self {
let protocol_name =
<OpenTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::Client::new(channel, protocol_name) }
}
pub fn take_event_stream(&self) -> OpenTargetEventReporterEventStream {
OpenTargetEventReporterEventStream { event_receiver: self.client.take_event_receiver() }
}
pub fn r#report_event(&self, mut payload: &OpenTargetEventReport) -> Result<(), fidl::Error> {
OpenTargetEventReporterProxyInterface::r#report_event(self, payload)
}
}
impl OpenTargetEventReporterProxyInterface for OpenTargetEventReporterProxy {
fn r#report_event(&self, mut payload: &OpenTargetEventReport) -> Result<(), fidl::Error> {
self.client.send::<OpenTargetEventReport>(
payload,
0x70ab38ec0248964a,
fidl::encoding::DynamicFlags::empty(),
)
}
}
pub struct OpenTargetEventReporterEventStream {
event_receiver: fidl::client::EventReceiver<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl std::marker::Unpin for OpenTargetEventReporterEventStream {}
impl futures::stream::FusedStream for OpenTargetEventReporterEventStream {
fn is_terminated(&self) -> bool {
self.event_receiver.is_terminated()
}
}
impl futures::Stream for OpenTargetEventReporterEventStream {
type Item = Result<OpenTargetEventReporterEvent, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
match futures::ready!(futures::stream::StreamExt::poll_next_unpin(
&mut self.event_receiver,
cx
)?) {
Some(buf) => std::task::Poll::Ready(Some(OpenTargetEventReporterEvent::decode(buf))),
None => std::task::Poll::Ready(None),
}
}
}
#[derive(Debug)]
pub enum OpenTargetEventReporterEvent {}
impl OpenTargetEventReporterEvent {
fn decode(
mut buf: <fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc,
) -> Result<OpenTargetEventReporterEvent, fidl::Error> {
let (bytes, _handles) = buf.split_mut();
let (tx_header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
debug_assert_eq!(tx_header.tx_id, 0);
match tx_header.ordinal {
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: tx_header.ordinal,
protocol_name:
<OpenTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}
}
}
pub struct OpenTargetEventReporterRequestStream {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
}
impl std::marker::Unpin for OpenTargetEventReporterRequestStream {}
impl futures::stream::FusedStream for OpenTargetEventReporterRequestStream {
fn is_terminated(&self) -> bool {
self.is_terminated
}
}
impl fidl::endpoints::RequestStream for OpenTargetEventReporterRequestStream {
type Protocol = OpenTargetEventReporterMarker;
type ControlHandle = OpenTargetEventReporterControlHandle;
fn from_channel(channel: ::fidl::AsyncChannel) -> Self {
Self { inner: std::sync::Arc::new(fidl::ServeInner::new(channel)), is_terminated: false }
}
fn control_handle(&self) -> Self::ControlHandle {
OpenTargetEventReporterControlHandle { inner: self.inner.clone() }
}
fn into_inner(
self,
) -> (::std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>, bool)
{
(self.inner, self.is_terminated)
}
fn from_inner(
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
) -> Self {
Self { inner, is_terminated }
}
}
impl futures::Stream for OpenTargetEventReporterRequestStream {
type Item = Result<OpenTargetEventReporterRequest, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
let this = &mut *self;
if this.inner.check_shutdown(cx) {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
if this.is_terminated {
panic!("polled OpenTargetEventReporterRequestStream after completion");
}
fidl::encoding::with_tls_decode_buf::<_, fidl::encoding::DefaultFuchsiaResourceDialect>(
|bytes, handles| {
match this.inner.channel().read_etc(cx, bytes, handles) {
std::task::Poll::Ready(Ok(())) => {}
std::task::Poll::Pending => return std::task::Poll::Pending,
std::task::Poll::Ready(Err(zx_status::Status::PEER_CLOSED)) => {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
std::task::Poll::Ready(Err(e)) => {
return std::task::Poll::Ready(Some(Err(fidl::Error::ServerRequestRead(
e.into(),
))))
}
}
let (header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
std::task::Poll::Ready(Some(match header.ordinal {
0x70ab38ec0248964a => {
header.validate_request_tx_id(fidl::MethodType::OneWay)?;
let mut req = fidl::new_empty!(OpenTargetEventReport, fidl::encoding::DefaultFuchsiaResourceDialect);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<OpenTargetEventReport>(&header, _body_bytes, handles, &mut req)?;
let control_handle = OpenTargetEventReporterControlHandle {
inner: this.inner.clone(),
};
Ok(OpenTargetEventReporterRequest::ReportEvent {payload: req,
control_handle,
})
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: header.ordinal,
protocol_name: <OpenTargetEventReporterMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}))
},
)
}
}
#[derive(Debug)]
pub enum OpenTargetEventReporterRequest {
ReportEvent {
payload: OpenTargetEventReport,
control_handle: OpenTargetEventReporterControlHandle,
},
}
impl OpenTargetEventReporterRequest {
#[allow(irrefutable_let_patterns)]
pub fn into_report_event(
self,
) -> Option<(OpenTargetEventReport, OpenTargetEventReporterControlHandle)> {
if let OpenTargetEventReporterRequest::ReportEvent { payload, control_handle } = self {
Some((payload, control_handle))
} else {
None
}
}
pub fn method_name(&self) -> &'static str {
match *self {
OpenTargetEventReporterRequest::ReportEvent { .. } => "report_event",
}
}
}
#[derive(Debug, Clone)]
pub struct OpenTargetEventReporterControlHandle {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
}
impl fidl::endpoints::ControlHandle for OpenTargetEventReporterControlHandle {
fn shutdown(&self) {
self.inner.shutdown()
}
fn shutdown_with_epitaph(&self, status: zx_status::Status) {
self.inner.shutdown_with_epitaph(status)
}
fn is_closed(&self) -> bool {
self.inner.channel().is_closed()
}
fn on_closed(&self) -> fidl::OnSignalsRef<'_> {
self.inner.channel().on_closed()
}
#[cfg(target_os = "fuchsia")]
fn signal_peer(
&self,
clear_mask: zx::Signals,
set_mask: zx::Signals,
) -> Result<(), zx_status::Status> {
use fidl::Peered;
self.inner.channel().signal_peer(clear_mask, set_mask)
}
}
impl OpenTargetEventReporterControlHandle {}
#[derive(Debug, Copy, Clone, Eq, PartialEq, Ord, PartialOrd, Hash)]
pub struct RunnerMarker;
impl fidl::endpoints::ProtocolMarker for RunnerMarker {
type Proxy = RunnerProxy;
type RequestStream = RunnerRequestStream;
#[cfg(target_os = "fuchsia")]
type SynchronousProxy = RunnerSynchronousProxy;
const DEBUG_NAME: &'static str = "fidl.clientsuite.Runner";
}
impl fidl::endpoints::DiscoverableProtocolMarker for RunnerMarker {}
pub trait RunnerProxyInterface: Send + Sync {
type GetVersionResponseFut: std::future::Future<Output = Result<u64, fidl::Error>> + Send;
fn r#get_version(&self) -> Self::GetVersionResponseFut;
type IsTestEnabledResponseFut: std::future::Future<Output = Result<bool, fidl::Error>> + Send;
fn r#is_test_enabled(&self, test: Test) -> Self::IsTestEnabledResponseFut;
type CheckAliveResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#check_alive(&self) -> Self::CheckAliveResponseFut;
type GetBindingsPropertiesResponseFut: std::future::Future<Output = Result<BindingsProperties, fidl::Error>>
+ Send;
fn r#get_bindings_properties(&self) -> Self::GetBindingsPropertiesResponseFut;
type CallTwoWayNoPayloadResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_two_way_no_payload(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayNoPayloadResponseFut;
type CallTwoWayStructPayloadResponseFut: std::future::Future<Output = Result<NonEmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_two_way_struct_payload(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayStructPayloadResponseFut;
type CallTwoWayTablePayloadResponseFut: std::future::Future<Output = Result<TableResultClassification, fidl::Error>>
+ Send;
fn r#call_two_way_table_payload(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayTablePayloadResponseFut;
type CallTwoWayUnionPayloadResponseFut: std::future::Future<Output = Result<UnionResultClassification, fidl::Error>>
+ Send;
fn r#call_two_way_union_payload(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayUnionPayloadResponseFut;
type CallTwoWayStructPayloadErrResponseFut: std::future::Future<Output = Result<NonEmptyResultWithErrorClassification, fidl::Error>>
+ Send;
fn r#call_two_way_struct_payload_err(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayStructPayloadErrResponseFut;
type CallTwoWayStructRequestResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_two_way_struct_request(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: &NonEmptyPayload,
) -> Self::CallTwoWayStructRequestResponseFut;
type CallTwoWayTableRequestResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_two_way_table_request(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: &TablePayload,
) -> Self::CallTwoWayTableRequestResponseFut;
type CallTwoWayUnionRequestResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_two_way_union_request(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: &UnionPayload,
) -> Self::CallTwoWayUnionRequestResponseFut;
type CallOneWayNoRequestResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_one_way_no_request(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallOneWayNoRequestResponseFut;
type CallOneWayStructRequestResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_one_way_struct_request(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: &NonEmptyPayload,
) -> Self::CallOneWayStructRequestResponseFut;
type CallOneWayTableRequestResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_one_way_table_request(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: &TablePayload,
) -> Self::CallOneWayTableRequestResponseFut;
type CallOneWayUnionRequestResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_one_way_union_request(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: &UnionPayload,
) -> Self::CallOneWayUnionRequestResponseFut;
type CallStrictOneWayResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_strict_one_way(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictOneWayResponseFut;
type CallFlexibleOneWayResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_flexible_one_way(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleOneWayResponseFut;
type CallStrictTwoWayResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_strict_two_way(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayResponseFut;
type CallStrictTwoWayFieldsResponseFut: std::future::Future<Output = Result<NonEmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_strict_two_way_fields(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayFieldsResponseFut;
type CallStrictTwoWayErrResponseFut: std::future::Future<Output = Result<EmptyResultWithErrorClassification, fidl::Error>>
+ Send;
fn r#call_strict_two_way_err(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayErrResponseFut;
type CallStrictTwoWayFieldsErrResponseFut: std::future::Future<Output = Result<NonEmptyResultWithErrorClassification, fidl::Error>>
+ Send;
fn r#call_strict_two_way_fields_err(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayFieldsErrResponseFut;
type CallFlexibleTwoWayResponseFut: std::future::Future<Output = Result<EmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_flexible_two_way(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayResponseFut;
type CallFlexibleTwoWayFieldsResponseFut: std::future::Future<Output = Result<NonEmptyResultClassification, fidl::Error>>
+ Send;
fn r#call_flexible_two_way_fields(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayFieldsResponseFut;
type CallFlexibleTwoWayErrResponseFut: std::future::Future<Output = Result<EmptyResultWithErrorClassification, fidl::Error>>
+ Send;
fn r#call_flexible_two_way_err(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayErrResponseFut;
type CallFlexibleTwoWayFieldsErrResponseFut: std::future::Future<Output = Result<NonEmptyResultWithErrorClassification, fidl::Error>>
+ Send;
fn r#call_flexible_two_way_fields_err(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayFieldsErrResponseFut;
type ReceiveClosedEventsResponseFut: std::future::Future<Output = Result<(), fidl::Error>>
+ Send;
fn r#receive_closed_events(
&self,
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
reporter: fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
) -> Self::ReceiveClosedEventsResponseFut;
type ReceiveAjarEventsResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#receive_ajar_events(
&self,
target: fidl::endpoints::ClientEnd<AjarTargetMarker>,
reporter: fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
) -> Self::ReceiveAjarEventsResponseFut;
type ReceiveOpenEventsResponseFut: std::future::Future<Output = Result<(), fidl::Error>> + Send;
fn r#receive_open_events(
&self,
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
reporter: fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
) -> Self::ReceiveOpenEventsResponseFut;
}
#[derive(Debug)]
#[cfg(target_os = "fuchsia")]
pub struct RunnerSynchronousProxy {
client: fidl::client::sync::Client,
}
#[cfg(target_os = "fuchsia")]
impl fidl::endpoints::SynchronousProxy for RunnerSynchronousProxy {
type Proxy = RunnerProxy;
type Protocol = RunnerMarker;
fn from_channel(inner: fidl::Channel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
fn as_channel(&self) -> &fidl::Channel {
self.client.as_channel()
}
}
#[cfg(target_os = "fuchsia")]
impl RunnerSynchronousProxy {
pub fn new(channel: fidl::Channel) -> Self {
let protocol_name = <RunnerMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::sync::Client::new(channel, protocol_name) }
}
pub fn into_channel(self) -> fidl::Channel {
self.client.into_channel()
}
pub fn wait_for_event(
&self,
deadline: zx::MonotonicInstant,
) -> Result<RunnerEvent, fidl::Error> {
RunnerEvent::decode(self.client.wait_for_event(deadline)?)
}
pub fn r#get_version(&self, ___deadline: zx::MonotonicInstant) -> Result<u64, fidl::Error> {
let _response =
self.client.send_query::<fidl::encoding::EmptyPayload, RunnerGetVersionResponse>(
(),
0x555d1430b913cdd4,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response.version)
}
pub fn r#is_test_enabled(
&self,
mut test: Test,
___deadline: zx::MonotonicInstant,
) -> Result<bool, fidl::Error> {
let _response =
self.client.send_query::<RunnerIsTestEnabledRequest, RunnerIsTestEnabledResponse>(
(test,),
0x755bc493368d7c50,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response.is_enabled)
}
pub fn r#check_alive(&self, ___deadline: zx::MonotonicInstant) -> Result<(), fidl::Error> {
let _response =
self.client.send_query::<fidl::encoding::EmptyPayload, fidl::encoding::EmptyPayload>(
(),
0x5a77b04abdfde130,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#get_bindings_properties(
&self,
___deadline: zx::MonotonicInstant,
) -> Result<BindingsProperties, fidl::Error> {
let _response =
self.client.send_query::<fidl::encoding::EmptyPayload, BindingsProperties>(
(),
0x76b5610bfd4fa636,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_no_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response =
self.client.send_query::<RunnerCallTwoWayNoPayloadRequest, EmptyResultClassification>(
(target,),
0x53ac710c20b320a1,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_struct_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<NonEmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallTwoWayStructPayloadRequest, NonEmptyResultClassification>(
(target,),
0x24e98c668499b946,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_table_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<TableResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallTwoWayTablePayloadRequest, TableResultClassification>(
(target,),
0x72e428e1605b76a,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_union_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<UnionResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallTwoWayUnionPayloadRequest, UnionResultClassification>(
(target,),
0x7dc9d67218343860,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_struct_payload_err(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<NonEmptyResultWithErrorClassification, fidl::Error> {
let _response = self.client.send_query::<
RunnerCallTwoWayStructPayloadErrRequest,
NonEmptyResultWithErrorClassification,
>(
(target,),
0x2b07a57942c5f6e5,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_struct_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &NonEmptyPayload,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallTwoWayStructRequestRequest, EmptyResultClassification>(
(target, request),
0x7c00a6ba2e6c9b45,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_table_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &TablePayload,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallTwoWayTableRequestRequest, EmptyResultClassification>(
(target, request),
0x641763237d3885be,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_two_way_union_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &UnionPayload,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallTwoWayUnionRequestRequest, EmptyResultClassification>(
(target, request),
0x4be5f061df42619e,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_one_way_no_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response =
self.client.send_query::<RunnerCallOneWayNoRequestRequest, EmptyResultClassification>(
(target,),
0x24b6eea8cbdccc09,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_one_way_struct_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &NonEmptyPayload,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallOneWayStructRequestRequest, EmptyResultClassification>(
(target, request),
0x352a2907a0fcb420,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_one_way_table_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &TablePayload,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallOneWayTableRequestRequest, EmptyResultClassification>(
(target, request),
0x734121bf8bf336ef,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_one_way_union_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &UnionPayload,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallOneWayUnionRequestRequest, EmptyResultClassification>(
(target, request),
0x9be8e5eb7d50eb6,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_strict_one_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response =
self.client.send_query::<RunnerCallStrictOneWayRequest, EmptyResultClassification>(
(target,),
0x4edd0b6f52c0446b,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_flexible_one_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response =
self.client.send_query::<RunnerCallFlexibleOneWayRequest, EmptyResultClassification>(
(target,),
0x7253f10a77dfe817,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_strict_two_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response =
self.client.send_query::<RunnerCallStrictTwoWayRequest, EmptyResultClassification>(
(target,),
0x1fa9fb7414aedd27,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_strict_two_way_fields(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<NonEmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallStrictTwoWayFieldsRequest, NonEmptyResultClassification>(
(target,),
0x6f690e00ebf6f123,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_strict_two_way_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultWithErrorClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallStrictTwoWayErrRequest, EmptyResultWithErrorClassification>(
(target,),
0x51d6bc7cf6cbaf1a,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_strict_two_way_fields_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<NonEmptyResultWithErrorClassification, fidl::Error> {
let _response = self.client.send_query::<
RunnerCallStrictTwoWayFieldsErrRequest,
NonEmptyResultWithErrorClassification,
>(
(target,),
0x6fa31ced05074c05,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_flexible_two_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response =
self.client.send_query::<RunnerCallFlexibleTwoWayRequest, EmptyResultClassification>(
(target,),
0x411f70724876d49,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_flexible_two_way_fields(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<NonEmptyResultClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallFlexibleTwoWayFieldsRequest, NonEmptyResultClassification>(
(target,),
0x330996b623598eed,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_flexible_two_way_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<EmptyResultWithErrorClassification, fidl::Error> {
let _response = self
.client
.send_query::<RunnerCallFlexibleTwoWayErrRequest, EmptyResultWithErrorClassification>(
(target,),
0x5ddbf88a353a2a57,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#call_flexible_two_way_fields_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<NonEmptyResultWithErrorClassification, fidl::Error> {
let _response = self.client.send_query::<
RunnerCallFlexibleTwoWayFieldsErrRequest,
NonEmptyResultWithErrorClassification,
>(
(target,),
0x7ae309383b07048e,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#receive_closed_events(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<(), fidl::Error> {
let _response = self
.client
.send_query::<RunnerReceiveClosedEventsRequest, fidl::encoding::EmptyPayload>(
(target, reporter),
0x48da834910571aeb,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#receive_ajar_events(
&self,
mut target: fidl::endpoints::ClientEnd<AjarTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<(), fidl::Error> {
let _response = self
.client
.send_query::<RunnerReceiveAjarEventsRequest, fidl::encoding::EmptyPayload>(
(target, reporter),
0xc5662b9a9c007a3,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
pub fn r#receive_open_events(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
___deadline: zx::MonotonicInstant,
) -> Result<(), fidl::Error> {
let _response = self
.client
.send_query::<RunnerReceiveOpenEventsRequest, fidl::encoding::EmptyPayload>(
(target, reporter),
0x79a7073fd18edbdf,
fidl::encoding::DynamicFlags::empty(),
___deadline,
)?;
Ok(_response)
}
}
#[derive(Debug, Clone)]
pub struct RunnerProxy {
client: fidl::client::Client<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl fidl::endpoints::Proxy for RunnerProxy {
type Protocol = RunnerMarker;
fn from_channel(inner: ::fidl::AsyncChannel) -> Self {
Self::new(inner)
}
fn into_channel(self) -> Result<::fidl::AsyncChannel, Self> {
self.client.into_channel().map_err(|client| Self { client })
}
fn as_channel(&self) -> &::fidl::AsyncChannel {
self.client.as_channel()
}
}
impl RunnerProxy {
pub fn new(channel: ::fidl::AsyncChannel) -> Self {
let protocol_name = <RunnerMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME;
Self { client: fidl::client::Client::new(channel, protocol_name) }
}
pub fn take_event_stream(&self) -> RunnerEventStream {
RunnerEventStream { event_receiver: self.client.take_event_receiver() }
}
pub fn r#get_version(
&self,
) -> fidl::client::QueryResponseFut<u64, fidl::encoding::DefaultFuchsiaResourceDialect> {
RunnerProxyInterface::r#get_version(self)
}
pub fn r#is_test_enabled(
&self,
mut test: Test,
) -> fidl::client::QueryResponseFut<bool, fidl::encoding::DefaultFuchsiaResourceDialect> {
RunnerProxyInterface::r#is_test_enabled(self, test)
}
pub fn r#check_alive(
&self,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
RunnerProxyInterface::r#check_alive(self)
}
pub fn r#get_bindings_properties(
&self,
) -> fidl::client::QueryResponseFut<
BindingsProperties,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#get_bindings_properties(self)
}
pub fn r#call_two_way_no_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_no_payload(self, target)
}
pub fn r#call_two_way_struct_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> fidl::client::QueryResponseFut<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_struct_payload(self, target)
}
pub fn r#call_two_way_table_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> fidl::client::QueryResponseFut<
TableResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_table_payload(self, target)
}
pub fn r#call_two_way_union_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> fidl::client::QueryResponseFut<
UnionResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_union_payload(self, target)
}
pub fn r#call_two_way_struct_payload_err(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> fidl::client::QueryResponseFut<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_struct_payload_err(self, target)
}
pub fn r#call_two_way_struct_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &NonEmptyPayload,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_struct_request(self, target, request)
}
pub fn r#call_two_way_table_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &TablePayload,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_table_request(self, target, request)
}
pub fn r#call_two_way_union_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &UnionPayload,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_two_way_union_request(self, target, request)
}
pub fn r#call_one_way_no_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_one_way_no_request(self, target)
}
pub fn r#call_one_way_struct_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &NonEmptyPayload,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_one_way_struct_request(self, target, request)
}
pub fn r#call_one_way_table_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &TablePayload,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_one_way_table_request(self, target, request)
}
pub fn r#call_one_way_union_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &UnionPayload,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_one_way_union_request(self, target, request)
}
pub fn r#call_strict_one_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_strict_one_way(self, target)
}
pub fn r#call_flexible_one_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_flexible_one_way(self, target)
}
pub fn r#call_strict_two_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_strict_two_way(self, target)
}
pub fn r#call_strict_two_way_fields(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_strict_two_way_fields(self, target)
}
pub fn r#call_strict_two_way_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_strict_two_way_err(self, target)
}
pub fn r#call_strict_two_way_fields_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_strict_two_way_fields_err(self, target)
}
pub fn r#call_flexible_two_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_flexible_two_way(self, target)
}
pub fn r#call_flexible_two_way_fields(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_flexible_two_way_fields(self, target)
}
pub fn r#call_flexible_two_way_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
EmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_flexible_two_way_err(self, target)
}
pub fn r#call_flexible_two_way_fields_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> fidl::client::QueryResponseFut<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
> {
RunnerProxyInterface::r#call_flexible_two_way_fields_err(self, target)
}
pub fn r#receive_closed_events(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
RunnerProxyInterface::r#receive_closed_events(self, target, reporter)
}
pub fn r#receive_ajar_events(
&self,
mut target: fidl::endpoints::ClientEnd<AjarTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
RunnerProxyInterface::r#receive_ajar_events(self, target, reporter)
}
pub fn r#receive_open_events(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
) -> fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect> {
RunnerProxyInterface::r#receive_open_events(self, target, reporter)
}
}
impl RunnerProxyInterface for RunnerProxy {
type GetVersionResponseFut =
fidl::client::QueryResponseFut<u64, fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#get_version(&self) -> Self::GetVersionResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<u64, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
RunnerGetVersionResponse,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x555d1430b913cdd4,
>(_buf?)?;
Ok(_response.version)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, u64>(
(),
0x555d1430b913cdd4,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type IsTestEnabledResponseFut =
fidl::client::QueryResponseFut<bool, fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#is_test_enabled(&self, mut test: Test) -> Self::IsTestEnabledResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<bool, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
RunnerIsTestEnabledResponse,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x755bc493368d7c50,
>(_buf?)?;
Ok(_response.is_enabled)
}
self.client.send_query_and_decode::<RunnerIsTestEnabledRequest, bool>(
(test,),
0x755bc493368d7c50,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CheckAliveResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#check_alive(&self) -> Self::CheckAliveResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x5a77b04abdfde130,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, ()>(
(),
0x5a77b04abdfde130,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type GetBindingsPropertiesResponseFut = fidl::client::QueryResponseFut<
BindingsProperties,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#get_bindings_properties(&self) -> Self::GetBindingsPropertiesResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<BindingsProperties, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
BindingsProperties,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x76b5610bfd4fa636,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<fidl::encoding::EmptyPayload, BindingsProperties>(
(),
0x76b5610bfd4fa636,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayNoPayloadResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_no_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayNoPayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x53ac710c20b320a1,
>(_buf?)?;
Ok(_response)
}
self.client
.send_query_and_decode::<RunnerCallTwoWayNoPayloadRequest, EmptyResultClassification>(
(target,),
0x53ac710c20b320a1,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayStructPayloadResponseFut = fidl::client::QueryResponseFut<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_struct_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayStructPayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<NonEmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x24e98c668499b946,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallTwoWayStructPayloadRequest,
NonEmptyResultClassification,
>(
(target,),
0x24e98c668499b946,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayTablePayloadResponseFut = fidl::client::QueryResponseFut<
TableResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_table_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayTablePayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<TableResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
TableResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x72e428e1605b76a,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallTwoWayTablePayloadRequest,
TableResultClassification,
>(
(target,),
0x72e428e1605b76a,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayUnionPayloadResponseFut = fidl::client::QueryResponseFut<
UnionResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_union_payload(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayUnionPayloadResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<UnionResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
UnionResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x7dc9d67218343860,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallTwoWayUnionPayloadRequest,
UnionResultClassification,
>(
(target,),
0x7dc9d67218343860,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayStructPayloadErrResponseFut = fidl::client::QueryResponseFut<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_struct_payload_err(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallTwoWayStructPayloadErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<NonEmptyResultWithErrorClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x2b07a57942c5f6e5,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallTwoWayStructPayloadErrRequest,
NonEmptyResultWithErrorClassification,
>(
(target,),
0x2b07a57942c5f6e5,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayStructRequestResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_struct_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &NonEmptyPayload,
) -> Self::CallTwoWayStructRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x7c00a6ba2e6c9b45,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallTwoWayStructRequestRequest,
EmptyResultClassification,
>(
(target, request,),
0x7c00a6ba2e6c9b45,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayTableRequestResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_table_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &TablePayload,
) -> Self::CallTwoWayTableRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x641763237d3885be,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallTwoWayTableRequestRequest,
EmptyResultClassification,
>(
(target, request,),
0x641763237d3885be,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallTwoWayUnionRequestResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_two_way_union_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &UnionPayload,
) -> Self::CallTwoWayUnionRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x4be5f061df42619e,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallTwoWayUnionRequestRequest,
EmptyResultClassification,
>(
(target, request,),
0x4be5f061df42619e,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallOneWayNoRequestResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_one_way_no_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
) -> Self::CallOneWayNoRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x24b6eea8cbdccc09,
>(_buf?)?;
Ok(_response)
}
self.client
.send_query_and_decode::<RunnerCallOneWayNoRequestRequest, EmptyResultClassification>(
(target,),
0x24b6eea8cbdccc09,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallOneWayStructRequestResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_one_way_struct_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &NonEmptyPayload,
) -> Self::CallOneWayStructRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x352a2907a0fcb420,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallOneWayStructRequestRequest,
EmptyResultClassification,
>(
(target, request,),
0x352a2907a0fcb420,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallOneWayTableRequestResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_one_way_table_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &TablePayload,
) -> Self::CallOneWayTableRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x734121bf8bf336ef,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallOneWayTableRequestRequest,
EmptyResultClassification,
>(
(target, request,),
0x734121bf8bf336ef,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallOneWayUnionRequestResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_one_way_union_request(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut request: &UnionPayload,
) -> Self::CallOneWayUnionRequestResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x9be8e5eb7d50eb6,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallOneWayUnionRequestRequest,
EmptyResultClassification,
>(
(target, request,),
0x9be8e5eb7d50eb6,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallStrictOneWayResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_strict_one_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictOneWayResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x4edd0b6f52c0446b,
>(_buf?)?;
Ok(_response)
}
self.client
.send_query_and_decode::<RunnerCallStrictOneWayRequest, EmptyResultClassification>(
(target,),
0x4edd0b6f52c0446b,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallFlexibleOneWayResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_flexible_one_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleOneWayResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x7253f10a77dfe817,
>(_buf?)?;
Ok(_response)
}
self.client
.send_query_and_decode::<RunnerCallFlexibleOneWayRequest, EmptyResultClassification>(
(target,),
0x7253f10a77dfe817,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallStrictTwoWayResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_strict_two_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x1fa9fb7414aedd27,
>(_buf?)?;
Ok(_response)
}
self.client
.send_query_and_decode::<RunnerCallStrictTwoWayRequest, EmptyResultClassification>(
(target,),
0x1fa9fb7414aedd27,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallStrictTwoWayFieldsResponseFut = fidl::client::QueryResponseFut<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_strict_two_way_fields(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayFieldsResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<NonEmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x6f690e00ebf6f123,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallStrictTwoWayFieldsRequest,
NonEmptyResultClassification,
>(
(target,),
0x6f690e00ebf6f123,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallStrictTwoWayErrResponseFut = fidl::client::QueryResponseFut<
EmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_strict_two_way_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultWithErrorClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x51d6bc7cf6cbaf1a,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallStrictTwoWayErrRequest,
EmptyResultWithErrorClassification,
>(
(target,),
0x51d6bc7cf6cbaf1a,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallStrictTwoWayFieldsErrResponseFut = fidl::client::QueryResponseFut<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_strict_two_way_fields_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallStrictTwoWayFieldsErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<NonEmptyResultWithErrorClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x6fa31ced05074c05,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallStrictTwoWayFieldsErrRequest,
NonEmptyResultWithErrorClassification,
>(
(target,),
0x6fa31ced05074c05,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallFlexibleTwoWayResponseFut = fidl::client::QueryResponseFut<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_flexible_two_way(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x411f70724876d49,
>(_buf?)?;
Ok(_response)
}
self.client
.send_query_and_decode::<RunnerCallFlexibleTwoWayRequest, EmptyResultClassification>(
(target,),
0x411f70724876d49,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallFlexibleTwoWayFieldsResponseFut = fidl::client::QueryResponseFut<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_flexible_two_way_fields(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayFieldsResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<NonEmptyResultClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyResultClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x330996b623598eed,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallFlexibleTwoWayFieldsRequest,
NonEmptyResultClassification,
>(
(target,),
0x330996b623598eed,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallFlexibleTwoWayErrResponseFut = fidl::client::QueryResponseFut<
EmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_flexible_two_way_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<EmptyResultWithErrorClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
EmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x5ddbf88a353a2a57,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallFlexibleTwoWayErrRequest,
EmptyResultWithErrorClassification,
>(
(target,),
0x5ddbf88a353a2a57,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type CallFlexibleTwoWayFieldsErrResponseFut = fidl::client::QueryResponseFut<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
>;
fn r#call_flexible_two_way_fields_err(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
) -> Self::CallFlexibleTwoWayFieldsErrResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<NonEmptyResultWithErrorClassification, fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
NonEmptyResultWithErrorClassification,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x7ae309383b07048e,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<
RunnerCallFlexibleTwoWayFieldsErrRequest,
NonEmptyResultWithErrorClassification,
>(
(target,),
0x7ae309383b07048e,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type ReceiveClosedEventsResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#receive_closed_events(
&self,
mut target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
) -> Self::ReceiveClosedEventsResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x48da834910571aeb,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<RunnerReceiveClosedEventsRequest, ()>(
(target, reporter),
0x48da834910571aeb,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type ReceiveAjarEventsResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#receive_ajar_events(
&self,
mut target: fidl::endpoints::ClientEnd<AjarTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
) -> Self::ReceiveAjarEventsResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0xc5662b9a9c007a3,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<RunnerReceiveAjarEventsRequest, ()>(
(target, reporter),
0xc5662b9a9c007a3,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
type ReceiveOpenEventsResponseFut =
fidl::client::QueryResponseFut<(), fidl::encoding::DefaultFuchsiaResourceDialect>;
fn r#receive_open_events(
&self,
mut target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
mut reporter: fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
) -> Self::ReceiveOpenEventsResponseFut {
fn _decode(
mut _buf: Result<<fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc, fidl::Error>,
) -> Result<(), fidl::Error> {
let _response = fidl::client::decode_transaction_body::<
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
0x79a7073fd18edbdf,
>(_buf?)?;
Ok(_response)
}
self.client.send_query_and_decode::<RunnerReceiveOpenEventsRequest, ()>(
(target, reporter),
0x79a7073fd18edbdf,
fidl::encoding::DynamicFlags::empty(),
_decode,
)
}
}
pub struct RunnerEventStream {
event_receiver: fidl::client::EventReceiver<fidl::encoding::DefaultFuchsiaResourceDialect>,
}
impl std::marker::Unpin for RunnerEventStream {}
impl futures::stream::FusedStream for RunnerEventStream {
fn is_terminated(&self) -> bool {
self.event_receiver.is_terminated()
}
}
impl futures::Stream for RunnerEventStream {
type Item = Result<RunnerEvent, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
match futures::ready!(futures::stream::StreamExt::poll_next_unpin(
&mut self.event_receiver,
cx
)?) {
Some(buf) => std::task::Poll::Ready(Some(RunnerEvent::decode(buf))),
None => std::task::Poll::Ready(None),
}
}
}
#[derive(Debug)]
pub enum RunnerEvent {}
impl RunnerEvent {
fn decode(
mut buf: <fidl::encoding::DefaultFuchsiaResourceDialect as fidl::encoding::ResourceDialect>::MessageBufEtc,
) -> Result<RunnerEvent, fidl::Error> {
let (bytes, _handles) = buf.split_mut();
let (tx_header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
debug_assert_eq!(tx_header.tx_id, 0);
match tx_header.ordinal {
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: tx_header.ordinal,
protocol_name: <RunnerMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}
}
}
pub struct RunnerRequestStream {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
}
impl std::marker::Unpin for RunnerRequestStream {}
impl futures::stream::FusedStream for RunnerRequestStream {
fn is_terminated(&self) -> bool {
self.is_terminated
}
}
impl fidl::endpoints::RequestStream for RunnerRequestStream {
type Protocol = RunnerMarker;
type ControlHandle = RunnerControlHandle;
fn from_channel(channel: ::fidl::AsyncChannel) -> Self {
Self { inner: std::sync::Arc::new(fidl::ServeInner::new(channel)), is_terminated: false }
}
fn control_handle(&self) -> Self::ControlHandle {
RunnerControlHandle { inner: self.inner.clone() }
}
fn into_inner(
self,
) -> (::std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>, bool)
{
(self.inner, self.is_terminated)
}
fn from_inner(
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
is_terminated: bool,
) -> Self {
Self { inner, is_terminated }
}
}
impl futures::Stream for RunnerRequestStream {
type Item = Result<RunnerRequest, fidl::Error>;
fn poll_next(
mut self: std::pin::Pin<&mut Self>,
cx: &mut std::task::Context<'_>,
) -> std::task::Poll<Option<Self::Item>> {
let this = &mut *self;
if this.inner.check_shutdown(cx) {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
if this.is_terminated {
panic!("polled RunnerRequestStream after completion");
}
fidl::encoding::with_tls_decode_buf::<_, fidl::encoding::DefaultFuchsiaResourceDialect>(
|bytes, handles| {
match this.inner.channel().read_etc(cx, bytes, handles) {
std::task::Poll::Ready(Ok(())) => {}
std::task::Poll::Pending => return std::task::Poll::Pending,
std::task::Poll::Ready(Err(zx_status::Status::PEER_CLOSED)) => {
this.is_terminated = true;
return std::task::Poll::Ready(None);
}
std::task::Poll::Ready(Err(e)) => {
return std::task::Poll::Ready(Some(Err(fidl::Error::ServerRequestRead(
e.into(),
))))
}
}
let (header, _body_bytes) = fidl::encoding::decode_transaction_header(bytes)?;
std::task::Poll::Ready(Some(match header.ordinal {
0x555d1430b913cdd4 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::GetVersion {
responder: RunnerGetVersionResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x755bc493368d7c50 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerIsTestEnabledRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerIsTestEnabledRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::IsTestEnabled {
test: req.test,
responder: RunnerIsTestEnabledResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x5a77b04abdfde130 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CheckAlive {
responder: RunnerCheckAliveResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x76b5610bfd4fa636 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
fidl::encoding::EmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<fidl::encoding::EmptyPayload>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::GetBindingsProperties {
responder: RunnerGetBindingsPropertiesResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x53ac710c20b320a1 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayNoPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayNoPayloadRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayNoPayload {
target: req.target,
responder: RunnerCallTwoWayNoPayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x24e98c668499b946 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayStructPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayStructPayloadRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayStructPayload {
target: req.target,
responder: RunnerCallTwoWayStructPayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x72e428e1605b76a => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayTablePayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayTablePayloadRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayTablePayload {
target: req.target,
responder: RunnerCallTwoWayTablePayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x7dc9d67218343860 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayUnionPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayUnionPayloadRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayUnionPayload {
target: req.target,
responder: RunnerCallTwoWayUnionPayloadResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x2b07a57942c5f6e5 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayStructPayloadErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayStructPayloadErrRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayStructPayloadErr {
target: req.target,
responder: RunnerCallTwoWayStructPayloadErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x7c00a6ba2e6c9b45 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayStructRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayStructRequestRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayStructRequest {
target: req.target,
request: req.request,
responder: RunnerCallTwoWayStructRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x641763237d3885be => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayTableRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayTableRequestRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayTableRequest {
target: req.target,
request: req.request,
responder: RunnerCallTwoWayTableRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x4be5f061df42619e => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallTwoWayUnionRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallTwoWayUnionRequestRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallTwoWayUnionRequest {
target: req.target,
request: req.request,
responder: RunnerCallTwoWayUnionRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x24b6eea8cbdccc09 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallOneWayNoRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallOneWayNoRequestRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallOneWayNoRequest {
target: req.target,
responder: RunnerCallOneWayNoRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x352a2907a0fcb420 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallOneWayStructRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallOneWayStructRequestRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallOneWayStructRequest {
target: req.target,
request: req.request,
responder: RunnerCallOneWayStructRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x734121bf8bf336ef => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallOneWayTableRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallOneWayTableRequestRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallOneWayTableRequest {
target: req.target,
request: req.request,
responder: RunnerCallOneWayTableRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x9be8e5eb7d50eb6 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallOneWayUnionRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallOneWayUnionRequestRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallOneWayUnionRequest {
target: req.target,
request: req.request,
responder: RunnerCallOneWayUnionRequestResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x4edd0b6f52c0446b => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallStrictOneWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallStrictOneWayRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallStrictOneWay {
target: req.target,
responder: RunnerCallStrictOneWayResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x7253f10a77dfe817 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallFlexibleOneWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallFlexibleOneWayRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallFlexibleOneWay {
target: req.target,
responder: RunnerCallFlexibleOneWayResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x1fa9fb7414aedd27 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallStrictTwoWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallStrictTwoWayRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallStrictTwoWay {
target: req.target,
responder: RunnerCallStrictTwoWayResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x6f690e00ebf6f123 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallStrictTwoWayFieldsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallStrictTwoWayFieldsRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallStrictTwoWayFields {
target: req.target,
responder: RunnerCallStrictTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x51d6bc7cf6cbaf1a => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallStrictTwoWayErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallStrictTwoWayErrRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallStrictTwoWayErr {
target: req.target,
responder: RunnerCallStrictTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x6fa31ced05074c05 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallStrictTwoWayFieldsErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallStrictTwoWayFieldsErrRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallStrictTwoWayFieldsErr {
target: req.target,
responder: RunnerCallStrictTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x411f70724876d49 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallFlexibleTwoWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallFlexibleTwoWayRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallFlexibleTwoWay {
target: req.target,
responder: RunnerCallFlexibleTwoWayResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x330996b623598eed => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallFlexibleTwoWayFieldsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallFlexibleTwoWayFieldsRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallFlexibleTwoWayFields {
target: req.target,
responder: RunnerCallFlexibleTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x5ddbf88a353a2a57 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallFlexibleTwoWayErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallFlexibleTwoWayErrRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallFlexibleTwoWayErr {
target: req.target,
responder: RunnerCallFlexibleTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x7ae309383b07048e => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerCallFlexibleTwoWayFieldsErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerCallFlexibleTwoWayFieldsErrRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::CallFlexibleTwoWayFieldsErr {
target: req.target,
responder: RunnerCallFlexibleTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x48da834910571aeb => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerReceiveClosedEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerReceiveClosedEventsRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::ReceiveClosedEvents {
target: req.target,
reporter: req.reporter,
responder: RunnerReceiveClosedEventsResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0xc5662b9a9c007a3 => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerReceiveAjarEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerReceiveAjarEventsRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::ReceiveAjarEvents {
target: req.target,
reporter: req.reporter,
responder: RunnerReceiveAjarEventsResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
0x79a7073fd18edbdf => {
header.validate_request_tx_id(fidl::MethodType::TwoWay)?;
let mut req = fidl::new_empty!(
RunnerReceiveOpenEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect
);
fidl::encoding::Decoder::<fidl::encoding::DefaultFuchsiaResourceDialect>::decode_into::<RunnerReceiveOpenEventsRequest>(&header, _body_bytes, handles, &mut req)?;
let control_handle = RunnerControlHandle { inner: this.inner.clone() };
Ok(RunnerRequest::ReceiveOpenEvents {
target: req.target,
reporter: req.reporter,
responder: RunnerReceiveOpenEventsResponder {
control_handle: std::mem::ManuallyDrop::new(control_handle),
tx_id: header.tx_id,
},
})
}
_ => Err(fidl::Error::UnknownOrdinal {
ordinal: header.ordinal,
protocol_name:
<RunnerMarker as fidl::endpoints::ProtocolMarker>::DEBUG_NAME,
}),
}))
},
)
}
}
#[derive(Debug)]
pub enum RunnerRequest {
GetVersion {
responder: RunnerGetVersionResponder,
},
IsTestEnabled {
test: Test,
responder: RunnerIsTestEnabledResponder,
},
CheckAlive {
responder: RunnerCheckAliveResponder,
},
GetBindingsProperties {
responder: RunnerGetBindingsPropertiesResponder,
},
CallTwoWayNoPayload {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
responder: RunnerCallTwoWayNoPayloadResponder,
},
CallTwoWayStructPayload {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
responder: RunnerCallTwoWayStructPayloadResponder,
},
CallTwoWayTablePayload {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
responder: RunnerCallTwoWayTablePayloadResponder,
},
CallTwoWayUnionPayload {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
responder: RunnerCallTwoWayUnionPayloadResponder,
},
CallTwoWayStructPayloadErr {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
responder: RunnerCallTwoWayStructPayloadErrResponder,
},
CallTwoWayStructRequest {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: NonEmptyPayload,
responder: RunnerCallTwoWayStructRequestResponder,
},
CallTwoWayTableRequest {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: TablePayload,
responder: RunnerCallTwoWayTableRequestResponder,
},
CallTwoWayUnionRequest {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: UnionPayload,
responder: RunnerCallTwoWayUnionRequestResponder,
},
CallOneWayNoRequest {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
responder: RunnerCallOneWayNoRequestResponder,
},
CallOneWayStructRequest {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: NonEmptyPayload,
responder: RunnerCallOneWayStructRequestResponder,
},
CallOneWayTableRequest {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: TablePayload,
responder: RunnerCallOneWayTableRequestResponder,
},
CallOneWayUnionRequest {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
request: UnionPayload,
responder: RunnerCallOneWayUnionRequestResponder,
},
CallStrictOneWay {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallStrictOneWayResponder,
},
CallFlexibleOneWay {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallFlexibleOneWayResponder,
},
CallStrictTwoWay {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallStrictTwoWayResponder,
},
CallStrictTwoWayFields {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallStrictTwoWayFieldsResponder,
},
CallStrictTwoWayErr {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallStrictTwoWayErrResponder,
},
CallStrictTwoWayFieldsErr {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallStrictTwoWayFieldsErrResponder,
},
CallFlexibleTwoWay {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallFlexibleTwoWayResponder,
},
CallFlexibleTwoWayFields {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallFlexibleTwoWayFieldsResponder,
},
CallFlexibleTwoWayErr {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallFlexibleTwoWayErrResponder,
},
CallFlexibleTwoWayFieldsErr {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
responder: RunnerCallFlexibleTwoWayFieldsErrResponder,
},
ReceiveClosedEvents {
target: fidl::endpoints::ClientEnd<ClosedTargetMarker>,
reporter: fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
responder: RunnerReceiveClosedEventsResponder,
},
ReceiveAjarEvents {
target: fidl::endpoints::ClientEnd<AjarTargetMarker>,
reporter: fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
responder: RunnerReceiveAjarEventsResponder,
},
ReceiveOpenEvents {
target: fidl::endpoints::ClientEnd<OpenTargetMarker>,
reporter: fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
responder: RunnerReceiveOpenEventsResponder,
},
}
impl RunnerRequest {
#[allow(irrefutable_let_patterns)]
pub fn into_get_version(self) -> Option<(RunnerGetVersionResponder)> {
if let RunnerRequest::GetVersion { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_is_test_enabled(self) -> Option<(Test, RunnerIsTestEnabledResponder)> {
if let RunnerRequest::IsTestEnabled { test, responder } = self {
Some((test, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_check_alive(self) -> Option<(RunnerCheckAliveResponder)> {
if let RunnerRequest::CheckAlive { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_get_bindings_properties(self) -> Option<(RunnerGetBindingsPropertiesResponder)> {
if let RunnerRequest::GetBindingsProperties { responder } = self {
Some((responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_no_payload(
self,
) -> Option<(fidl::endpoints::ClientEnd<ClosedTargetMarker>, RunnerCallTwoWayNoPayloadResponder)>
{
if let RunnerRequest::CallTwoWayNoPayload { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_struct_payload(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
RunnerCallTwoWayStructPayloadResponder,
)> {
if let RunnerRequest::CallTwoWayStructPayload { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_table_payload(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
RunnerCallTwoWayTablePayloadResponder,
)> {
if let RunnerRequest::CallTwoWayTablePayload { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_union_payload(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
RunnerCallTwoWayUnionPayloadResponder,
)> {
if let RunnerRequest::CallTwoWayUnionPayload { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_struct_payload_err(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
RunnerCallTwoWayStructPayloadErrResponder,
)> {
if let RunnerRequest::CallTwoWayStructPayloadErr { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_struct_request(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
NonEmptyPayload,
RunnerCallTwoWayStructRequestResponder,
)> {
if let RunnerRequest::CallTwoWayStructRequest { target, request, responder } = self {
Some((target, request, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_table_request(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
TablePayload,
RunnerCallTwoWayTableRequestResponder,
)> {
if let RunnerRequest::CallTwoWayTableRequest { target, request, responder } = self {
Some((target, request, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_two_way_union_request(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
UnionPayload,
RunnerCallTwoWayUnionRequestResponder,
)> {
if let RunnerRequest::CallTwoWayUnionRequest { target, request, responder } = self {
Some((target, request, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_one_way_no_request(
self,
) -> Option<(fidl::endpoints::ClientEnd<ClosedTargetMarker>, RunnerCallOneWayNoRequestResponder)>
{
if let RunnerRequest::CallOneWayNoRequest { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_one_way_struct_request(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
NonEmptyPayload,
RunnerCallOneWayStructRequestResponder,
)> {
if let RunnerRequest::CallOneWayStructRequest { target, request, responder } = self {
Some((target, request, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_one_way_table_request(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
TablePayload,
RunnerCallOneWayTableRequestResponder,
)> {
if let RunnerRequest::CallOneWayTableRequest { target, request, responder } = self {
Some((target, request, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_one_way_union_request(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
UnionPayload,
RunnerCallOneWayUnionRequestResponder,
)> {
if let RunnerRequest::CallOneWayUnionRequest { target, request, responder } = self {
Some((target, request, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_strict_one_way(
self,
) -> Option<(fidl::endpoints::ClientEnd<OpenTargetMarker>, RunnerCallStrictOneWayResponder)>
{
if let RunnerRequest::CallStrictOneWay { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_flexible_one_way(
self,
) -> Option<(fidl::endpoints::ClientEnd<OpenTargetMarker>, RunnerCallFlexibleOneWayResponder)>
{
if let RunnerRequest::CallFlexibleOneWay { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_strict_two_way(
self,
) -> Option<(fidl::endpoints::ClientEnd<OpenTargetMarker>, RunnerCallStrictTwoWayResponder)>
{
if let RunnerRequest::CallStrictTwoWay { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_strict_two_way_fields(
self,
) -> Option<(fidl::endpoints::ClientEnd<OpenTargetMarker>, RunnerCallStrictTwoWayFieldsResponder)>
{
if let RunnerRequest::CallStrictTwoWayFields { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_strict_two_way_err(
self,
) -> Option<(fidl::endpoints::ClientEnd<OpenTargetMarker>, RunnerCallStrictTwoWayErrResponder)>
{
if let RunnerRequest::CallStrictTwoWayErr { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_strict_two_way_fields_err(
self,
) -> Option<(
fidl::endpoints::ClientEnd<OpenTargetMarker>,
RunnerCallStrictTwoWayFieldsErrResponder,
)> {
if let RunnerRequest::CallStrictTwoWayFieldsErr { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_flexible_two_way(
self,
) -> Option<(fidl::endpoints::ClientEnd<OpenTargetMarker>, RunnerCallFlexibleTwoWayResponder)>
{
if let RunnerRequest::CallFlexibleTwoWay { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_flexible_two_way_fields(
self,
) -> Option<(
fidl::endpoints::ClientEnd<OpenTargetMarker>,
RunnerCallFlexibleTwoWayFieldsResponder,
)> {
if let RunnerRequest::CallFlexibleTwoWayFields { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_flexible_two_way_err(
self,
) -> Option<(fidl::endpoints::ClientEnd<OpenTargetMarker>, RunnerCallFlexibleTwoWayErrResponder)>
{
if let RunnerRequest::CallFlexibleTwoWayErr { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_call_flexible_two_way_fields_err(
self,
) -> Option<(
fidl::endpoints::ClientEnd<OpenTargetMarker>,
RunnerCallFlexibleTwoWayFieldsErrResponder,
)> {
if let RunnerRequest::CallFlexibleTwoWayFieldsErr { target, responder } = self {
Some((target, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_receive_closed_events(
self,
) -> Option<(
fidl::endpoints::ClientEnd<ClosedTargetMarker>,
fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
RunnerReceiveClosedEventsResponder,
)> {
if let RunnerRequest::ReceiveClosedEvents { target, reporter, responder } = self {
Some((target, reporter, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_receive_ajar_events(
self,
) -> Option<(
fidl::endpoints::ClientEnd<AjarTargetMarker>,
fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
RunnerReceiveAjarEventsResponder,
)> {
if let RunnerRequest::ReceiveAjarEvents { target, reporter, responder } = self {
Some((target, reporter, responder))
} else {
None
}
}
#[allow(irrefutable_let_patterns)]
pub fn into_receive_open_events(
self,
) -> Option<(
fidl::endpoints::ClientEnd<OpenTargetMarker>,
fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
RunnerReceiveOpenEventsResponder,
)> {
if let RunnerRequest::ReceiveOpenEvents { target, reporter, responder } = self {
Some((target, reporter, responder))
} else {
None
}
}
pub fn method_name(&self) -> &'static str {
match *self {
RunnerRequest::GetVersion { .. } => "get_version",
RunnerRequest::IsTestEnabled { .. } => "is_test_enabled",
RunnerRequest::CheckAlive { .. } => "check_alive",
RunnerRequest::GetBindingsProperties { .. } => "get_bindings_properties",
RunnerRequest::CallTwoWayNoPayload { .. } => "call_two_way_no_payload",
RunnerRequest::CallTwoWayStructPayload { .. } => "call_two_way_struct_payload",
RunnerRequest::CallTwoWayTablePayload { .. } => "call_two_way_table_payload",
RunnerRequest::CallTwoWayUnionPayload { .. } => "call_two_way_union_payload",
RunnerRequest::CallTwoWayStructPayloadErr { .. } => "call_two_way_struct_payload_err",
RunnerRequest::CallTwoWayStructRequest { .. } => "call_two_way_struct_request",
RunnerRequest::CallTwoWayTableRequest { .. } => "call_two_way_table_request",
RunnerRequest::CallTwoWayUnionRequest { .. } => "call_two_way_union_request",
RunnerRequest::CallOneWayNoRequest { .. } => "call_one_way_no_request",
RunnerRequest::CallOneWayStructRequest { .. } => "call_one_way_struct_request",
RunnerRequest::CallOneWayTableRequest { .. } => "call_one_way_table_request",
RunnerRequest::CallOneWayUnionRequest { .. } => "call_one_way_union_request",
RunnerRequest::CallStrictOneWay { .. } => "call_strict_one_way",
RunnerRequest::CallFlexibleOneWay { .. } => "call_flexible_one_way",
RunnerRequest::CallStrictTwoWay { .. } => "call_strict_two_way",
RunnerRequest::CallStrictTwoWayFields { .. } => "call_strict_two_way_fields",
RunnerRequest::CallStrictTwoWayErr { .. } => "call_strict_two_way_err",
RunnerRequest::CallStrictTwoWayFieldsErr { .. } => "call_strict_two_way_fields_err",
RunnerRequest::CallFlexibleTwoWay { .. } => "call_flexible_two_way",
RunnerRequest::CallFlexibleTwoWayFields { .. } => "call_flexible_two_way_fields",
RunnerRequest::CallFlexibleTwoWayErr { .. } => "call_flexible_two_way_err",
RunnerRequest::CallFlexibleTwoWayFieldsErr { .. } => "call_flexible_two_way_fields_err",
RunnerRequest::ReceiveClosedEvents { .. } => "receive_closed_events",
RunnerRequest::ReceiveAjarEvents { .. } => "receive_ajar_events",
RunnerRequest::ReceiveOpenEvents { .. } => "receive_open_events",
}
}
}
#[derive(Debug, Clone)]
pub struct RunnerControlHandle {
inner: std::sync::Arc<fidl::ServeInner<fidl::encoding::DefaultFuchsiaResourceDialect>>,
}
impl fidl::endpoints::ControlHandle for RunnerControlHandle {
fn shutdown(&self) {
self.inner.shutdown()
}
fn shutdown_with_epitaph(&self, status: zx_status::Status) {
self.inner.shutdown_with_epitaph(status)
}
fn is_closed(&self) -> bool {
self.inner.channel().is_closed()
}
fn on_closed(&self) -> fidl::OnSignalsRef<'_> {
self.inner.channel().on_closed()
}
#[cfg(target_os = "fuchsia")]
fn signal_peer(
&self,
clear_mask: zx::Signals,
set_mask: zx::Signals,
) -> Result<(), zx_status::Status> {
use fidl::Peered;
self.inner.channel().signal_peer(clear_mask, set_mask)
}
}
impl RunnerControlHandle {}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerGetVersionResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerGetVersionResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerGetVersionResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerGetVersionResponder {
pub fn send(self, mut version: u64) -> Result<(), fidl::Error> {
let _result = self.send_raw(version);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut version: u64) -> Result<(), fidl::Error> {
let _result = self.send_raw(version);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut version: u64) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<RunnerGetVersionResponse>(
(version,),
self.tx_id,
0x555d1430b913cdd4,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerIsTestEnabledResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerIsTestEnabledResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerIsTestEnabledResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerIsTestEnabledResponder {
pub fn send(self, mut is_enabled: bool) -> Result<(), fidl::Error> {
let _result = self.send_raw(is_enabled);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self, mut is_enabled: bool) -> Result<(), fidl::Error> {
let _result = self.send_raw(is_enabled);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut is_enabled: bool) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<RunnerIsTestEnabledResponse>(
(is_enabled,),
self.tx_id,
0x755bc493368d7c50,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCheckAliveResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCheckAliveResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCheckAliveResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCheckAliveResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0x5a77b04abdfde130,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerGetBindingsPropertiesResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerGetBindingsPropertiesResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerGetBindingsPropertiesResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerGetBindingsPropertiesResponder {
pub fn send(self, mut payload: &BindingsProperties) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &BindingsProperties,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &BindingsProperties) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<BindingsProperties>(
payload,
self.tx_id,
0x76b5610bfd4fa636,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayNoPayloadResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayNoPayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayNoPayloadResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayNoPayloadResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x53ac710c20b320a1,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayStructPayloadResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayStructPayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayStructPayloadResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayStructPayloadResponder {
pub fn send(self, mut payload: &NonEmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &NonEmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &NonEmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyResultClassification>(
payload,
self.tx_id,
0x24e98c668499b946,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayTablePayloadResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayTablePayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayTablePayloadResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayTablePayloadResponder {
pub fn send(self, mut payload: &TableResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &TableResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &TableResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<TableResultClassification>(
payload,
self.tx_id,
0x72e428e1605b76a,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayUnionPayloadResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayUnionPayloadResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayUnionPayloadResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayUnionPayloadResponder {
pub fn send(self, mut payload: &UnionResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &UnionResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &UnionResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<UnionResultClassification>(
payload,
self.tx_id,
0x7dc9d67218343860,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayStructPayloadErrResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayStructPayloadErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayStructPayloadErrResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayStructPayloadErrResponder {
pub fn send(
self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(
&self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyResultWithErrorClassification>(
payload,
self.tx_id,
0x2b07a57942c5f6e5,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayStructRequestResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayStructRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayStructRequestResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayStructRequestResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x7c00a6ba2e6c9b45,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayTableRequestResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayTableRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayTableRequestResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayTableRequestResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x641763237d3885be,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallTwoWayUnionRequestResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallTwoWayUnionRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallTwoWayUnionRequestResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallTwoWayUnionRequestResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x4be5f061df42619e,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallOneWayNoRequestResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallOneWayNoRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallOneWayNoRequestResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallOneWayNoRequestResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x24b6eea8cbdccc09,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallOneWayStructRequestResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallOneWayStructRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallOneWayStructRequestResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallOneWayStructRequestResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x352a2907a0fcb420,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallOneWayTableRequestResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallOneWayTableRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallOneWayTableRequestResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallOneWayTableRequestResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x734121bf8bf336ef,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallOneWayUnionRequestResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallOneWayUnionRequestResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallOneWayUnionRequestResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallOneWayUnionRequestResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x9be8e5eb7d50eb6,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallStrictOneWayResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallStrictOneWayResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallStrictOneWayResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallStrictOneWayResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x4edd0b6f52c0446b,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallFlexibleOneWayResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallFlexibleOneWayResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallFlexibleOneWayResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallFlexibleOneWayResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x7253f10a77dfe817,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallStrictTwoWayResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallStrictTwoWayResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallStrictTwoWayResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallStrictTwoWayResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x1fa9fb7414aedd27,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallStrictTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallStrictTwoWayFieldsResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallStrictTwoWayFieldsResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallStrictTwoWayFieldsResponder {
pub fn send(self, mut payload: &NonEmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &NonEmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &NonEmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyResultClassification>(
payload,
self.tx_id,
0x6f690e00ebf6f123,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallStrictTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallStrictTwoWayErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallStrictTwoWayErrResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallStrictTwoWayErrResponder {
pub fn send(self, mut payload: &EmptyResultWithErrorClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(
&self,
mut payload: &EmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultWithErrorClassification>(
payload,
self.tx_id,
0x51d6bc7cf6cbaf1a,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallStrictTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallStrictTwoWayFieldsErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallStrictTwoWayFieldsErrResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallStrictTwoWayFieldsErrResponder {
pub fn send(
self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(
&self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyResultWithErrorClassification>(
payload,
self.tx_id,
0x6fa31ced05074c05,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallFlexibleTwoWayResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallFlexibleTwoWayResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallFlexibleTwoWayResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallFlexibleTwoWayResponder {
pub fn send(self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &EmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultClassification>(
payload,
self.tx_id,
0x411f70724876d49,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallFlexibleTwoWayFieldsResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallFlexibleTwoWayFieldsResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallFlexibleTwoWayFieldsResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallFlexibleTwoWayFieldsResponder {
pub fn send(self, mut payload: &NonEmptyResultClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &NonEmptyResultClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(&self, mut payload: &NonEmptyResultClassification) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyResultClassification>(
payload,
self.tx_id,
0x330996b623598eed,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallFlexibleTwoWayErrResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallFlexibleTwoWayErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallFlexibleTwoWayErrResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallFlexibleTwoWayErrResponder {
pub fn send(self, mut payload: &EmptyResultWithErrorClassification) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &EmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(
&self,
mut payload: &EmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<EmptyResultWithErrorClassification>(
payload,
self.tx_id,
0x5ddbf88a353a2a57,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerCallFlexibleTwoWayFieldsErrResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerCallFlexibleTwoWayFieldsErrResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerCallFlexibleTwoWayFieldsErrResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerCallFlexibleTwoWayFieldsErrResponder {
pub fn send(
self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(
self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
let _result = self.send_raw(payload);
self.drop_without_shutdown();
_result
}
fn send_raw(
&self,
mut payload: &NonEmptyResultWithErrorClassification,
) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<NonEmptyResultWithErrorClassification>(
payload,
self.tx_id,
0x7ae309383b07048e,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerReceiveClosedEventsResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerReceiveClosedEventsResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerReceiveClosedEventsResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerReceiveClosedEventsResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0x48da834910571aeb,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerReceiveAjarEventsResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerReceiveAjarEventsResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerReceiveAjarEventsResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerReceiveAjarEventsResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0xc5662b9a9c007a3,
fidl::encoding::DynamicFlags::empty(),
)
}
}
#[must_use = "FIDL methods require a response to be sent"]
#[derive(Debug)]
pub struct RunnerReceiveOpenEventsResponder {
control_handle: std::mem::ManuallyDrop<RunnerControlHandle>,
tx_id: u32,
}
impl std::ops::Drop for RunnerReceiveOpenEventsResponder {
fn drop(&mut self) {
self.control_handle.shutdown();
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
}
}
impl fidl::endpoints::Responder for RunnerReceiveOpenEventsResponder {
type ControlHandle = RunnerControlHandle;
fn control_handle(&self) -> &RunnerControlHandle {
&self.control_handle
}
fn drop_without_shutdown(mut self) {
unsafe { std::mem::ManuallyDrop::drop(&mut self.control_handle) };
std::mem::forget(self);
}
}
impl RunnerReceiveOpenEventsResponder {
pub fn send(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
if _result.is_err() {
self.control_handle.shutdown();
}
self.drop_without_shutdown();
_result
}
pub fn send_no_shutdown_on_err(self) -> Result<(), fidl::Error> {
let _result = self.send_raw();
self.drop_without_shutdown();
_result
}
fn send_raw(&self) -> Result<(), fidl::Error> {
self.control_handle.inner.send::<fidl::encoding::EmptyPayload>(
(),
self.tx_id,
0x79a7073fd18edbdf,
fidl::encoding::DynamicFlags::empty(),
)
}
}
mod internal {
use super::*;
unsafe impl fidl::encoding::TypeMarker for FidlErrorKind {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
std::mem::align_of::<u32>()
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
std::mem::size_of::<u32>()
}
#[inline(always)]
fn encode_is_copy() -> bool {
true
}
#[inline(always)]
fn decode_is_copy() -> bool {
false
}
}
impl fidl::encoding::ValueTypeMarker for FidlErrorKind {
type Borrowed<'a> = Self;
#[inline(always)]
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
*value
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<Self, D> for FidlErrorKind {
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<Self>(offset);
encoder.write_num(self.into_primitive(), offset);
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for FidlErrorKind {
#[inline(always)]
fn new_empty() -> Self {
Self::OtherError
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let prim = decoder.read_num::<u32>(offset);
*self = Self::from_primitive(prim).ok_or(fidl::Error::InvalidEnumValue)?;
Ok(())
}
}
unsafe impl fidl::encoding::TypeMarker for IoStyle {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
std::mem::align_of::<u32>()
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
std::mem::size_of::<u32>()
}
#[inline(always)]
fn encode_is_copy() -> bool {
true
}
#[inline(always)]
fn decode_is_copy() -> bool {
false
}
}
impl fidl::encoding::ValueTypeMarker for IoStyle {
type Borrowed<'a> = Self;
#[inline(always)]
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
*value
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<Self, D> for IoStyle {
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<Self>(offset);
encoder.write_num(self.into_primitive(), offset);
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for IoStyle {
#[inline(always)]
fn new_empty() -> Self {
Self::Sync
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let prim = decoder.read_num::<u32>(offset);
*self = Self::from_primitive(prim).ok_or(fidl::Error::InvalidEnumValue)?;
Ok(())
}
}
unsafe impl fidl::encoding::TypeMarker for Test {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
std::mem::align_of::<u32>()
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
std::mem::size_of::<u32>()
}
#[inline(always)]
fn encode_is_copy() -> bool {
false
}
#[inline(always)]
fn decode_is_copy() -> bool {
false
}
}
impl fidl::encoding::ValueTypeMarker for Test {
type Borrowed<'a> = Self;
#[inline(always)]
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
*value
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<Self, D> for Test {
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<Self>(offset);
encoder.write_num(self.into_primitive(), offset);
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for Test {
#[inline(always)]
fn new_empty() -> Self {
Self::unknown()
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let prim = decoder.read_num::<u32>(offset);
*self = Self::from_primitive_allow_unknown(prim);
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for Empty {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for Empty {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
1
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
1
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<Empty, D> for &Empty {
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<Empty>(offset);
encoder.write_num(0u8, offset);
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for Empty {
#[inline(always)]
fn new_empty() -> Self {
Self
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
match decoder.read_num::<u8>(offset) {
0 => Ok(()),
_ => Err(fidl::Error::Invalid),
}
}
}
impl fidl::encoding::ValueTypeMarker for NonEmptyPayload {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for NonEmptyPayload {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn encode_is_copy() -> bool {
true
}
#[inline(always)]
fn decode_is_copy() -> bool {
true
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<NonEmptyPayload, D>
for &NonEmptyPayload
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<NonEmptyPayload>(offset);
unsafe {
let buf_ptr = encoder.buf.as_mut_ptr().add(offset);
(buf_ptr as *mut NonEmptyPayload)
.write_unaligned((self as *const NonEmptyPayload).read());
}
Ok(())
}
}
unsafe impl<D: fidl::encoding::ResourceDialect, T0: fidl::encoding::Encode<i32, D>>
fidl::encoding::Encode<NonEmptyPayload, D> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<NonEmptyPayload>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for NonEmptyPayload {
#[inline(always)]
fn new_empty() -> Self {
Self { some_field: fidl::new_empty!(i32, D) }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let buf_ptr = unsafe { decoder.buf.as_ptr().add(offset) };
unsafe {
std::ptr::copy_nonoverlapping(buf_ptr, self as *mut Self as *mut u8, 4);
}
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallFlexibleOneWayRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallFlexibleOneWayRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallFlexibleOneWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallFlexibleOneWayRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleOneWayRequest>(offset);
fidl::encoding::Encode::<RunnerCallFlexibleOneWayRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallFlexibleOneWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleOneWayRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleOneWayRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallFlexibleTwoWayErrRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallFlexibleTwoWayErrRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallFlexibleTwoWayErrRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayErrRequest>(offset);
fidl::encoding::Encode::<RunnerCallFlexibleTwoWayErrRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayErrRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayErrRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallFlexibleTwoWayFieldsErrRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallFlexibleTwoWayFieldsErrRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayFieldsErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallFlexibleTwoWayFieldsErrRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayFieldsErrRequest>(offset);
fidl::encoding::Encode::<RunnerCallFlexibleTwoWayFieldsErrRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayFieldsErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayFieldsErrRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayFieldsErrRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallFlexibleTwoWayFieldsRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallFlexibleTwoWayFieldsRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayFieldsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallFlexibleTwoWayFieldsRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayFieldsRequest>(offset);
fidl::encoding::Encode::<RunnerCallFlexibleTwoWayFieldsRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayFieldsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayFieldsRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayFieldsRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallFlexibleTwoWayRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallFlexibleTwoWayRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallFlexibleTwoWayRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayRequest>(offset);
fidl::encoding::Encode::<RunnerCallFlexibleTwoWayRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallFlexibleTwoWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallFlexibleTwoWayRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallFlexibleTwoWayRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallOneWayNoRequestRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallOneWayNoRequestRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallOneWayNoRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallOneWayNoRequestRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayNoRequestRequest>(offset);
fidl::encoding::Encode::<RunnerCallOneWayNoRequestRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallOneWayNoRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayNoRequestRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayNoRequestRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallOneWayStructRequestRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallOneWayStructRequestRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
8
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallOneWayStructRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallOneWayStructRequestRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayStructRequestRequest>(offset);
fidl::encoding::Encode::<RunnerCallOneWayStructRequestRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<NonEmptyPayload as fidl::encoding::ValueTypeMarker>::borrow(&self.request),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<NonEmptyPayload, fidl::encoding::DefaultFuchsiaResourceDialect>,
>
fidl::encoding::Encode<
RunnerCallOneWayStructRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayStructRequestRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 4, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayStructRequestRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
request: fidl::new_empty!(
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.request,
decoder,
offset + 4,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallOneWayTableRequestRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallOneWayTableRequestRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
24
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallOneWayTableRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallOneWayTableRequestRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayTableRequestRequest>(offset);
fidl::encoding::Encode::<RunnerCallOneWayTableRequestRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<TablePayload as fidl::encoding::ValueTypeMarker>::borrow(&self.request),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<TablePayload, fidl::encoding::DefaultFuchsiaResourceDialect>,
>
fidl::encoding::Encode<
RunnerCallOneWayTableRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayTableRequestRequest>(offset);
unsafe {
let ptr = encoder.buf.as_mut_ptr().add(offset).offset(0);
(ptr as *mut u64).write_unaligned(0);
}
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 8, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayTableRequestRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
request: fidl::new_empty!(
TablePayload,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let ptr = unsafe { decoder.buf.as_ptr().add(offset).offset(0) };
let padval = unsafe { (ptr as *const u64).read_unaligned() };
let mask = 0xffffffff00000000u64;
let maskedval = padval & mask;
if maskedval != 0 {
return Err(fidl::Error::NonZeroPadding {
padding_start: offset + 0 + ((mask as u64).trailing_zeros() / 8) as usize,
});
}
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
TablePayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.request,
decoder,
offset + 8,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallOneWayUnionRequestRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallOneWayUnionRequestRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
24
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallOneWayUnionRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallOneWayUnionRequestRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayUnionRequestRequest>(offset);
fidl::encoding::Encode::<RunnerCallOneWayUnionRequestRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<UnionPayload as fidl::encoding::ValueTypeMarker>::borrow(&self.request),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<UnionPayload, fidl::encoding::DefaultFuchsiaResourceDialect>,
>
fidl::encoding::Encode<
RunnerCallOneWayUnionRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallOneWayUnionRequestRequest>(offset);
unsafe {
let ptr = encoder.buf.as_mut_ptr().add(offset).offset(0);
(ptr as *mut u64).write_unaligned(0);
}
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 8, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallOneWayUnionRequestRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
request: fidl::new_empty!(
UnionPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let ptr = unsafe { decoder.buf.as_ptr().add(offset).offset(0) };
let padval = unsafe { (ptr as *const u64).read_unaligned() };
let mask = 0xffffffff00000000u64;
let maskedval = padval & mask;
if maskedval != 0 {
return Err(fidl::Error::NonZeroPadding {
padding_start: offset + 0 + ((mask as u64).trailing_zeros() / 8) as usize,
});
}
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
UnionPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.request,
decoder,
offset + 8,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallStrictOneWayRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallStrictOneWayRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallStrictOneWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallStrictOneWayRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictOneWayRequest>(offset);
fidl::encoding::Encode::<RunnerCallStrictOneWayRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallStrictOneWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictOneWayRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictOneWayRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallStrictTwoWayErrRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallStrictTwoWayErrRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallStrictTwoWayErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallStrictTwoWayErrRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayErrRequest>(offset);
fidl::encoding::Encode::<RunnerCallStrictTwoWayErrRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallStrictTwoWayErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayErrRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayErrRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallStrictTwoWayFieldsErrRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallStrictTwoWayFieldsErrRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallStrictTwoWayFieldsErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallStrictTwoWayFieldsErrRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayFieldsErrRequest>(offset);
fidl::encoding::Encode::<RunnerCallStrictTwoWayFieldsErrRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallStrictTwoWayFieldsErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayFieldsErrRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayFieldsErrRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallStrictTwoWayFieldsRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallStrictTwoWayFieldsRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallStrictTwoWayFieldsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallStrictTwoWayFieldsRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayFieldsRequest>(offset);
fidl::encoding::Encode::<RunnerCallStrictTwoWayFieldsRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallStrictTwoWayFieldsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayFieldsRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayFieldsRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallStrictTwoWayRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallStrictTwoWayRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallStrictTwoWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallStrictTwoWayRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayRequest>(offset);
fidl::encoding::Encode::<RunnerCallStrictTwoWayRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallStrictTwoWayRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallStrictTwoWayRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallStrictTwoWayRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayNoPayloadRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayNoPayloadRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayNoPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayNoPayloadRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayNoPayloadRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayNoPayloadRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallTwoWayNoPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayNoPayloadRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayNoPayloadRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayStructPayloadErrRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayStructPayloadErrRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayStructPayloadErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayStructPayloadErrRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayStructPayloadErrRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayStructPayloadErrRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallTwoWayStructPayloadErrRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayStructPayloadErrRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayStructPayloadErrRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayStructPayloadRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayStructPayloadRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayStructPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayStructPayloadRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayStructPayloadRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayStructPayloadRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallTwoWayStructPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayStructPayloadRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayStructPayloadRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayStructRequestRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayStructRequestRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
8
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayStructRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayStructRequestRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayStructRequestRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayStructRequestRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<NonEmptyPayload as fidl::encoding::ValueTypeMarker>::borrow(&self.request),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<NonEmptyPayload, fidl::encoding::DefaultFuchsiaResourceDialect>,
>
fidl::encoding::Encode<
RunnerCallTwoWayStructRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayStructRequestRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 4, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayStructRequestRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
request: fidl::new_empty!(
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
NonEmptyPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.request,
decoder,
offset + 4,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayTablePayloadRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayTablePayloadRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayTablePayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayTablePayloadRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayTablePayloadRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayTablePayloadRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallTwoWayTablePayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayTablePayloadRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayTablePayloadRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayTableRequestRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayTableRequestRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
24
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayTableRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayTableRequestRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayTableRequestRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayTableRequestRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<TablePayload as fidl::encoding::ValueTypeMarker>::borrow(&self.request),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<TablePayload, fidl::encoding::DefaultFuchsiaResourceDialect>,
>
fidl::encoding::Encode<
RunnerCallTwoWayTableRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayTableRequestRequest>(offset);
unsafe {
let ptr = encoder.buf.as_mut_ptr().add(offset).offset(0);
(ptr as *mut u64).write_unaligned(0);
}
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 8, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayTableRequestRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
request: fidl::new_empty!(
TablePayload,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let ptr = unsafe { decoder.buf.as_ptr().add(offset).offset(0) };
let padval = unsafe { (ptr as *const u64).read_unaligned() };
let mask = 0xffffffff00000000u64;
let maskedval = padval & mask;
if maskedval != 0 {
return Err(fidl::Error::NonZeroPadding {
padding_start: offset + 0 + ((mask as u64).trailing_zeros() / 8) as usize,
});
}
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
TablePayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.request,
decoder,
offset + 8,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayUnionPayloadRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayUnionPayloadRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayUnionPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayUnionPayloadRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayUnionPayloadRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayUnionPayloadRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerCallTwoWayUnionPayloadRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayUnionPayloadRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayUnionPayloadRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerCallTwoWayUnionRequestRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerCallTwoWayUnionRequestRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
24
}
}
unsafe impl
fidl::encoding::Encode<
RunnerCallTwoWayUnionRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerCallTwoWayUnionRequestRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayUnionRequestRequest>(offset);
fidl::encoding::Encode::<RunnerCallTwoWayUnionRequestRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<UnionPayload as fidl::encoding::ValueTypeMarker>::borrow(&self.request),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<UnionPayload, fidl::encoding::DefaultFuchsiaResourceDialect>,
>
fidl::encoding::Encode<
RunnerCallTwoWayUnionRequestRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerCallTwoWayUnionRequestRequest>(offset);
unsafe {
let ptr = encoder.buf.as_mut_ptr().add(offset).offset(0);
(ptr as *mut u64).write_unaligned(0);
}
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 8, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerCallTwoWayUnionRequestRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
request: fidl::new_empty!(
UnionPayload,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let ptr = unsafe { decoder.buf.as_ptr().add(offset).offset(0) };
let padval = unsafe { (ptr as *const u64).read_unaligned() };
let mask = 0xffffffff00000000u64;
let maskedval = padval & mask;
if maskedval != 0 {
return Err(fidl::Error::NonZeroPadding {
padding_start: offset + 0 + ((mask as u64).trailing_zeros() / 8) as usize,
});
}
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
UnionPayload,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.request,
decoder,
offset + 8,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for RunnerGetVersionResponse {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerGetVersionResponse {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn encode_is_copy() -> bool {
true
}
#[inline(always)]
fn decode_is_copy() -> bool {
true
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<RunnerGetVersionResponse, D> for &RunnerGetVersionResponse
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerGetVersionResponse>(offset);
unsafe {
let buf_ptr = encoder.buf.as_mut_ptr().add(offset);
(buf_ptr as *mut RunnerGetVersionResponse)
.write_unaligned((self as *const RunnerGetVersionResponse).read());
}
Ok(())
}
}
unsafe impl<D: fidl::encoding::ResourceDialect, T0: fidl::encoding::Encode<u64, D>>
fidl::encoding::Encode<RunnerGetVersionResponse, D> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerGetVersionResponse>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for RunnerGetVersionResponse
{
#[inline(always)]
fn new_empty() -> Self {
Self { version: fidl::new_empty!(u64, D) }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let buf_ptr = unsafe { decoder.buf.as_ptr().add(offset) };
unsafe {
std::ptr::copy_nonoverlapping(buf_ptr, self as *mut Self as *mut u8, 8);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for RunnerIsTestEnabledRequest {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerIsTestEnabledRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
4
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<RunnerIsTestEnabledRequest, D> for &RunnerIsTestEnabledRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerIsTestEnabledRequest>(offset);
fidl::encoding::Encode::<RunnerIsTestEnabledRequest, D>::encode(
(<Test as fidl::encoding::ValueTypeMarker>::borrow(&self.test),),
encoder,
offset,
_depth,
)
}
}
unsafe impl<D: fidl::encoding::ResourceDialect, T0: fidl::encoding::Encode<Test, D>>
fidl::encoding::Encode<RunnerIsTestEnabledRequest, D> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerIsTestEnabledRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for RunnerIsTestEnabledRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self { test: fidl::new_empty!(Test, D) }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(Test, D, &mut self.test, decoder, offset + 0, _depth)?;
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for RunnerIsTestEnabledResponse {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerIsTestEnabledResponse {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
1
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
1
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<RunnerIsTestEnabledResponse, D> for &RunnerIsTestEnabledResponse
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerIsTestEnabledResponse>(offset);
fidl::encoding::Encode::<RunnerIsTestEnabledResponse, D>::encode(
(<bool as fidl::encoding::ValueTypeMarker>::borrow(&self.is_enabled),),
encoder,
offset,
_depth,
)
}
}
unsafe impl<D: fidl::encoding::ResourceDialect, T0: fidl::encoding::Encode<bool, D>>
fidl::encoding::Encode<RunnerIsTestEnabledResponse, D> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerIsTestEnabledResponse>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for RunnerIsTestEnabledResponse
{
#[inline(always)]
fn new_empty() -> Self {
Self { is_enabled: fidl::new_empty!(bool, D) }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(bool, D, &mut self.is_enabled, decoder, offset + 0, _depth)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerReceiveAjarEventsRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerReceiveAjarEventsRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
8
}
}
unsafe impl
fidl::encoding::Encode<
RunnerReceiveAjarEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerReceiveAjarEventsRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerReceiveAjarEventsRequest>(offset);
fidl::encoding::Encode::<RunnerReceiveAjarEventsRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<AjarTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.reporter),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<AjarTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerReceiveAjarEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerReceiveAjarEventsRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 4, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerReceiveAjarEventsRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<AjarTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
reporter: fidl::new_empty!(
fidl::encoding::Endpoint<
fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>,
>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<AjarTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<AjarTargetEventReporterMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.reporter,
decoder,
offset + 4,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerReceiveClosedEventsRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerReceiveClosedEventsRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
8
}
}
unsafe impl
fidl::encoding::Encode<
RunnerReceiveClosedEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerReceiveClosedEventsRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerReceiveClosedEventsRequest>(offset);
fidl::encoding::Encode::<RunnerReceiveClosedEventsRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.reporter),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<
fidl::encoding::Endpoint<
fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerReceiveClosedEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerReceiveClosedEventsRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 4, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerReceiveClosedEventsRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
reporter: fidl::new_empty!(
fidl::encoding::Endpoint<
fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<ClosedTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
fidl::encoding::Endpoint<
fidl::endpoints::ClientEnd<ClosedTargetEventReporterMarker>,
>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.reporter,
decoder,
offset + 4,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ResourceTypeMarker for RunnerReceiveOpenEventsRequest {
type Borrowed<'a> = &'a mut Self;
fn take_or_borrow<'a>(
value: &'a mut <Self as fidl::encoding::TypeMarker>::Owned,
) -> Self::Borrowed<'a> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for RunnerReceiveOpenEventsRequest {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
4
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
8
}
}
unsafe impl
fidl::encoding::Encode<
RunnerReceiveOpenEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for &mut RunnerReceiveOpenEventsRequest
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerReceiveOpenEventsRequest>(offset);
fidl::encoding::Encode::<RunnerReceiveOpenEventsRequest, fidl::encoding::DefaultFuchsiaResourceDialect>::encode(
(
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.target),
<fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>> as fidl::encoding::ResourceTypeMarker>::take_or_borrow(&mut self.reporter),
),
encoder, offset, _depth
)
}
}
unsafe impl<
T0: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
T1: fidl::encoding::Encode<
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
>
fidl::encoding::Encode<
RunnerReceiveOpenEventsRequest,
fidl::encoding::DefaultFuchsiaResourceDialect,
> for (T0, T1)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<RunnerReceiveOpenEventsRequest>(offset);
self.0.encode(encoder, offset + 0, depth)?;
self.1.encode(encoder, offset + 4, depth)?;
Ok(())
}
}
impl fidl::encoding::Decode<Self, fidl::encoding::DefaultFuchsiaResourceDialect>
for RunnerReceiveOpenEventsRequest
{
#[inline(always)]
fn new_empty() -> Self {
Self {
target: fidl::new_empty!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
reporter: fidl::new_empty!(
fidl::encoding::Endpoint<
fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>,
>,
fidl::encoding::DefaultFuchsiaResourceDialect
),
}
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<
'_,
fidl::encoding::DefaultFuchsiaResourceDialect,
>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.target,
decoder,
offset + 0,
_depth
)?;
fidl::decode!(
fidl::encoding::Endpoint<fidl::endpoints::ClientEnd<OpenTargetEventReporterMarker>>,
fidl::encoding::DefaultFuchsiaResourceDialect,
&mut self.reporter,
decoder,
offset + 4,
_depth
)?;
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for UnknownEvent {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for UnknownEvent {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn encode_is_copy() -> bool {
true
}
#[inline(always)]
fn decode_is_copy() -> bool {
true
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<UnknownEvent, D>
for &UnknownEvent
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<UnknownEvent>(offset);
unsafe {
let buf_ptr = encoder.buf.as_mut_ptr().add(offset);
(buf_ptr as *mut UnknownEvent)
.write_unaligned((self as *const UnknownEvent).read());
}
Ok(())
}
}
unsafe impl<D: fidl::encoding::ResourceDialect, T0: fidl::encoding::Encode<u64, D>>
fidl::encoding::Encode<UnknownEvent, D> for (T0,)
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<UnknownEvent>(offset);
self.0.encode(encoder, offset + 0, depth)?;
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for UnknownEvent {
#[inline(always)]
fn new_empty() -> Self {
Self { ordinal: fidl::new_empty!(u64, D) }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let buf_ptr = unsafe { decoder.buf.as_ptr().add(offset) };
unsafe {
std::ptr::copy_nonoverlapping(buf_ptr, self as *mut Self as *mut u8, 8);
}
Ok(())
}
}
impl BindingsProperties {
#[inline(always)]
fn max_ordinal_present(&self) -> u64 {
if let Some(_) = self.io_style {
return 1;
}
0
}
}
impl fidl::encoding::ValueTypeMarker for BindingsProperties {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for BindingsProperties {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<BindingsProperties, D>
for &BindingsProperties
{
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<BindingsProperties>(offset);
let max_ordinal: u64 = self.max_ordinal_present();
encoder.write_num(max_ordinal, offset);
encoder.write_num(fidl::encoding::ALLOC_PRESENT_U64, offset + 8);
if max_ordinal == 0 {
return Ok(());
}
depth.increment()?;
let envelope_size = 8;
let bytes_len = max_ordinal as usize * envelope_size;
#[allow(unused_variables)]
let offset = encoder.out_of_line_offset(bytes_len);
let mut _prev_end_offset: usize = 0;
if 1 > max_ordinal {
return Ok(());
}
let cur_offset: usize = (1 - 1) * envelope_size;
encoder.padding(offset + _prev_end_offset, cur_offset - _prev_end_offset);
fidl::encoding::encode_in_envelope_optional::<IoStyle, D>(
self.io_style.as_ref().map(<IoStyle as fidl::encoding::ValueTypeMarker>::borrow),
encoder,
offset + cur_offset,
depth,
)?;
_prev_end_offset = cur_offset + envelope_size;
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for BindingsProperties {
#[inline(always)]
fn new_empty() -> Self {
Self::default()
}
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let len = match fidl::encoding::decode_vector_header(decoder, offset)? {
None => return Err(fidl::Error::NotNullable),
Some(len) => len,
};
if len == 0 {
return Ok(());
};
depth.increment()?;
let envelope_size = 8;
let bytes_len = len * envelope_size;
let offset = decoder.out_of_line_offset(bytes_len)?;
let mut _next_ordinal_to_read = 0;
let mut next_offset = offset;
let end_offset = offset + bytes_len;
_next_ordinal_to_read += 1;
if next_offset >= end_offset {
return Ok(());
}
while _next_ordinal_to_read < 1 {
fidl::encoding::decode_unknown_envelope(decoder, next_offset, depth)?;
_next_ordinal_to_read += 1;
next_offset += envelope_size;
}
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
if let Some((inlined, num_bytes, num_handles)) =
fidl::encoding::decode_envelope_header(decoder, next_offset)?
{
let member_inline_size =
<IoStyle as fidl::encoding::TypeMarker>::inline_size(decoder.context);
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let inner_offset;
let mut inner_depth = depth.clone();
if inlined {
decoder.check_inline_envelope_padding(next_offset, member_inline_size)?;
inner_offset = next_offset;
} else {
inner_offset = decoder.out_of_line_offset(member_inline_size)?;
inner_depth.increment()?;
}
let val_ref = self.io_style.get_or_insert_with(|| fidl::new_empty!(IoStyle, D));
fidl::decode!(IoStyle, D, val_ref, decoder, inner_offset, inner_depth)?;
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize)
{
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
}
next_offset += envelope_size;
while next_offset < end_offset {
_next_ordinal_to_read += 1;
fidl::encoding::decode_unknown_envelope(decoder, next_offset, depth)?;
next_offset += envelope_size;
}
Ok(())
}
}
impl TablePayload {
#[inline(always)]
fn max_ordinal_present(&self) -> u64 {
if let Some(_) = self.some_field {
return 1;
}
0
}
}
impl fidl::encoding::ValueTypeMarker for TablePayload {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for TablePayload {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<TablePayload, D>
for &TablePayload
{
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<TablePayload>(offset);
let max_ordinal: u64 = self.max_ordinal_present();
encoder.write_num(max_ordinal, offset);
encoder.write_num(fidl::encoding::ALLOC_PRESENT_U64, offset + 8);
if max_ordinal == 0 {
return Ok(());
}
depth.increment()?;
let envelope_size = 8;
let bytes_len = max_ordinal as usize * envelope_size;
#[allow(unused_variables)]
let offset = encoder.out_of_line_offset(bytes_len);
let mut _prev_end_offset: usize = 0;
if 1 > max_ordinal {
return Ok(());
}
let cur_offset: usize = (1 - 1) * envelope_size;
encoder.padding(offset + _prev_end_offset, cur_offset - _prev_end_offset);
fidl::encoding::encode_in_envelope_optional::<i32, D>(
self.some_field.as_ref().map(<i32 as fidl::encoding::ValueTypeMarker>::borrow),
encoder,
offset + cur_offset,
depth,
)?;
_prev_end_offset = cur_offset + envelope_size;
Ok(())
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for TablePayload {
#[inline(always)]
fn new_empty() -> Self {
Self::default()
}
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
let len = match fidl::encoding::decode_vector_header(decoder, offset)? {
None => return Err(fidl::Error::NotNullable),
Some(len) => len,
};
if len == 0 {
return Ok(());
};
depth.increment()?;
let envelope_size = 8;
let bytes_len = len * envelope_size;
let offset = decoder.out_of_line_offset(bytes_len)?;
let mut _next_ordinal_to_read = 0;
let mut next_offset = offset;
let end_offset = offset + bytes_len;
_next_ordinal_to_read += 1;
if next_offset >= end_offset {
return Ok(());
}
while _next_ordinal_to_read < 1 {
fidl::encoding::decode_unknown_envelope(decoder, next_offset, depth)?;
_next_ordinal_to_read += 1;
next_offset += envelope_size;
}
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
if let Some((inlined, num_bytes, num_handles)) =
fidl::encoding::decode_envelope_header(decoder, next_offset)?
{
let member_inline_size =
<i32 as fidl::encoding::TypeMarker>::inline_size(decoder.context);
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let inner_offset;
let mut inner_depth = depth.clone();
if inlined {
decoder.check_inline_envelope_padding(next_offset, member_inline_size)?;
inner_offset = next_offset;
} else {
inner_offset = decoder.out_of_line_offset(member_inline_size)?;
inner_depth.increment()?;
}
let val_ref = self.some_field.get_or_insert_with(|| fidl::new_empty!(i32, D));
fidl::decode!(i32, D, val_ref, decoder, inner_offset, inner_depth)?;
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize)
{
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
}
next_offset += envelope_size;
while next_offset < end_offset {
_next_ordinal_to_read += 1;
fidl::encoding::decode_unknown_envelope(decoder, next_offset, depth)?;
next_offset += envelope_size;
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for AjarTargetEventReport {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for AjarTargetEventReport {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<AjarTargetEventReport, D>
for &AjarTargetEventReport
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<AjarTargetEventReport>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
AjarTargetEventReport::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
AjarTargetEventReport::UnknownEvent(ref val) => {
fidl::encoding::encode_in_envelope::<UnknownEvent, D>(
<UnknownEvent as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
AjarTargetEventReport::__SourceBreaking { .. } => Err(fidl::Error::UnknownUnionTag),
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for AjarTargetEventReport {
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
2 => <UnknownEvent as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let AjarTargetEventReport::FidlError(_) = self {
} else {
*self =
AjarTargetEventReport::FidlError(fidl::new_empty!(FidlErrorKind, D));
}
#[allow(irrefutable_let_patterns)]
if let AjarTargetEventReport::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
2 => {
#[allow(irrefutable_let_patterns)]
if let AjarTargetEventReport::UnknownEvent(_) = self {
} else {
*self =
AjarTargetEventReport::UnknownEvent(fidl::new_empty!(UnknownEvent, D));
}
#[allow(irrefutable_let_patterns)]
if let AjarTargetEventReport::UnknownEvent(ref mut val) = self {
fidl::decode!(UnknownEvent, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self = AjarTargetEventReport::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for ClosedTargetEventReport {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for ClosedTargetEventReport {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<ClosedTargetEventReport, D> for &ClosedTargetEventReport
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<ClosedTargetEventReport>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
ClosedTargetEventReport::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
ClosedTargetEventReport::OnEventNoPayload(ref val) => {
fidl::encoding::encode_in_envelope::<Empty, D>(
<Empty as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
ClosedTargetEventReport::OnEventStructPayload(ref val) => {
fidl::encoding::encode_in_envelope::<NonEmptyPayload, D>(
<NonEmptyPayload as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
ClosedTargetEventReport::OnEventTablePayload(ref val) => {
fidl::encoding::encode_in_envelope::<TablePayload, D>(
<TablePayload as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
ClosedTargetEventReport::OnEventUnionPayload(ref val) => {
fidl::encoding::encode_in_envelope::<UnionPayload, D>(
<UnionPayload as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
ClosedTargetEventReport::__SourceBreaking { .. } => {
Err(fidl::Error::UnknownUnionTag)
}
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for ClosedTargetEventReport
{
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
2 => <Empty as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <NonEmptyPayload as fidl::encoding::TypeMarker>::inline_size(decoder.context),
4 => <TablePayload as fidl::encoding::TypeMarker>::inline_size(decoder.context),
5 => <UnionPayload as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::FidlError(_) = self {
} else {
*self =
ClosedTargetEventReport::FidlError(fidl::new_empty!(FidlErrorKind, D));
}
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
2 => {
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventNoPayload(_) = self {
} else {
*self =
ClosedTargetEventReport::OnEventNoPayload(fidl::new_empty!(Empty, D));
}
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventNoPayload(ref mut val) = self {
fidl::decode!(Empty, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventStructPayload(_) = self {
} else {
*self = ClosedTargetEventReport::OnEventStructPayload(fidl::new_empty!(
NonEmptyPayload,
D
));
}
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventStructPayload(ref mut val) = self {
fidl::decode!(NonEmptyPayload, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
4 => {
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventTablePayload(_) = self {
} else {
*self = ClosedTargetEventReport::OnEventTablePayload(fidl::new_empty!(
TablePayload,
D
));
}
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventTablePayload(ref mut val) = self {
fidl::decode!(TablePayload, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
5 => {
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventUnionPayload(_) = self {
} else {
*self = ClosedTargetEventReport::OnEventUnionPayload(fidl::new_empty!(
UnionPayload,
D
));
}
#[allow(irrefutable_let_patterns)]
if let ClosedTargetEventReport::OnEventUnionPayload(ref mut val) = self {
fidl::decode!(UnionPayload, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self = ClosedTargetEventReport::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for EmptyResultClassification {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for EmptyResultClassification {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<EmptyResultClassification, D> for &EmptyResultClassification
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<EmptyResultClassification>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
EmptyResultClassification::Success(ref val) => {
fidl::encoding::encode_in_envelope::<Empty, D>(
<Empty as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
EmptyResultClassification::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
EmptyResultClassification::__SourceBreaking { .. } => {
Err(fidl::Error::UnknownUnionTag)
}
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for EmptyResultClassification
{
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <Empty as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let EmptyResultClassification::Success(_) = self {
} else {
*self = EmptyResultClassification::Success(fidl::new_empty!(Empty, D));
}
#[allow(irrefutable_let_patterns)]
if let EmptyResultClassification::Success(ref mut val) = self {
fidl::decode!(Empty, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let EmptyResultClassification::FidlError(_) = self {
} else {
*self = EmptyResultClassification::FidlError(fidl::new_empty!(
FidlErrorKind,
D
));
}
#[allow(irrefutable_let_patterns)]
if let EmptyResultClassification::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self =
EmptyResultClassification::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for EmptyResultWithErrorClassification {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for EmptyResultWithErrorClassification {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<EmptyResultWithErrorClassification, D>
for &EmptyResultWithErrorClassification
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<EmptyResultWithErrorClassification>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
EmptyResultWithErrorClassification::Success(ref val) => {
fidl::encoding::encode_in_envelope::<Empty, D>(
<Empty as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
EmptyResultWithErrorClassification::ApplicationError(ref val) => {
fidl::encoding::encode_in_envelope::<i32, D>(
<i32 as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
EmptyResultWithErrorClassification::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
EmptyResultWithErrorClassification::__SourceBreaking { .. } => {
Err(fidl::Error::UnknownUnionTag)
}
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for EmptyResultWithErrorClassification
{
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <Empty as fidl::encoding::TypeMarker>::inline_size(decoder.context),
2 => <i32 as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let EmptyResultWithErrorClassification::Success(_) = self {
} else {
*self =
EmptyResultWithErrorClassification::Success(fidl::new_empty!(Empty, D));
}
#[allow(irrefutable_let_patterns)]
if let EmptyResultWithErrorClassification::Success(ref mut val) = self {
fidl::decode!(Empty, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
2 => {
#[allow(irrefutable_let_patterns)]
if let EmptyResultWithErrorClassification::ApplicationError(_) = self {
} else {
*self = EmptyResultWithErrorClassification::ApplicationError(
fidl::new_empty!(i32, D),
);
}
#[allow(irrefutable_let_patterns)]
if let EmptyResultWithErrorClassification::ApplicationError(ref mut val) = self
{
fidl::decode!(i32, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let EmptyResultWithErrorClassification::FidlError(_) = self {
} else {
*self = EmptyResultWithErrorClassification::FidlError(fidl::new_empty!(
FidlErrorKind,
D
));
}
#[allow(irrefutable_let_patterns)]
if let EmptyResultWithErrorClassification::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self = EmptyResultWithErrorClassification::__SourceBreaking {
unknown_ordinal: ordinal,
};
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for NonEmptyResultClassification {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for NonEmptyResultClassification {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<NonEmptyResultClassification, D> for &NonEmptyResultClassification
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<NonEmptyResultClassification>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
NonEmptyResultClassification::Success(ref val) => {
fidl::encoding::encode_in_envelope::<NonEmptyPayload, D>(
<NonEmptyPayload as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
NonEmptyResultClassification::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
NonEmptyResultClassification::__SourceBreaking { .. } => {
Err(fidl::Error::UnknownUnionTag)
}
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for NonEmptyResultClassification
{
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <NonEmptyPayload as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultClassification::Success(_) = self {
} else {
*self = NonEmptyResultClassification::Success(fidl::new_empty!(
NonEmptyPayload,
D
));
}
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultClassification::Success(ref mut val) = self {
fidl::decode!(NonEmptyPayload, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultClassification::FidlError(_) = self {
} else {
*self = NonEmptyResultClassification::FidlError(fidl::new_empty!(
FidlErrorKind,
D
));
}
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultClassification::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self =
NonEmptyResultClassification::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for NonEmptyResultWithErrorClassification {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for NonEmptyResultWithErrorClassification {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<NonEmptyResultWithErrorClassification, D>
for &NonEmptyResultWithErrorClassification
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<NonEmptyResultWithErrorClassification>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
NonEmptyResultWithErrorClassification::Success(ref val) => {
fidl::encoding::encode_in_envelope::<NonEmptyPayload, D>(
<NonEmptyPayload as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
NonEmptyResultWithErrorClassification::ApplicationError(ref val) => {
fidl::encoding::encode_in_envelope::<i32, D>(
<i32 as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
NonEmptyResultWithErrorClassification::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
NonEmptyResultWithErrorClassification::__SourceBreaking { .. } => {
Err(fidl::Error::UnknownUnionTag)
}
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for NonEmptyResultWithErrorClassification
{
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <NonEmptyPayload as fidl::encoding::TypeMarker>::inline_size(decoder.context),
2 => <i32 as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultWithErrorClassification::Success(_) = self {
} else {
*self = NonEmptyResultWithErrorClassification::Success(fidl::new_empty!(
NonEmptyPayload,
D
));
}
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultWithErrorClassification::Success(ref mut val) = self {
fidl::decode!(NonEmptyPayload, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
2 => {
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultWithErrorClassification::ApplicationError(_) = self {
} else {
*self = NonEmptyResultWithErrorClassification::ApplicationError(
fidl::new_empty!(i32, D),
);
}
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultWithErrorClassification::ApplicationError(ref mut val) =
self
{
fidl::decode!(i32, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultWithErrorClassification::FidlError(_) = self {
} else {
*self = NonEmptyResultWithErrorClassification::FidlError(fidl::new_empty!(
FidlErrorKind,
D
));
}
#[allow(irrefutable_let_patterns)]
if let NonEmptyResultWithErrorClassification::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self = NonEmptyResultWithErrorClassification::__SourceBreaking {
unknown_ordinal: ordinal,
};
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for OpenTargetEventReport {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for OpenTargetEventReport {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<OpenTargetEventReport, D>
for &OpenTargetEventReport
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<OpenTargetEventReport>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
OpenTargetEventReport::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
OpenTargetEventReport::UnknownEvent(ref val) => {
fidl::encoding::encode_in_envelope::<UnknownEvent, D>(
<UnknownEvent as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
OpenTargetEventReport::StrictEvent(ref val) => {
fidl::encoding::encode_in_envelope::<Empty, D>(
<Empty as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
OpenTargetEventReport::FlexibleEvent(ref val) => {
fidl::encoding::encode_in_envelope::<Empty, D>(
<Empty as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
OpenTargetEventReport::__SourceBreaking { .. } => Err(fidl::Error::UnknownUnionTag),
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for OpenTargetEventReport {
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
2 => <UnknownEvent as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <Empty as fidl::encoding::TypeMarker>::inline_size(decoder.context),
4 => <Empty as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::FidlError(_) = self {
} else {
*self =
OpenTargetEventReport::FidlError(fidl::new_empty!(FidlErrorKind, D));
}
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
2 => {
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::UnknownEvent(_) = self {
} else {
*self =
OpenTargetEventReport::UnknownEvent(fidl::new_empty!(UnknownEvent, D));
}
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::UnknownEvent(ref mut val) = self {
fidl::decode!(UnknownEvent, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::StrictEvent(_) = self {
} else {
*self = OpenTargetEventReport::StrictEvent(fidl::new_empty!(Empty, D));
}
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::StrictEvent(ref mut val) = self {
fidl::decode!(Empty, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
4 => {
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::FlexibleEvent(_) = self {
} else {
*self = OpenTargetEventReport::FlexibleEvent(fidl::new_empty!(Empty, D));
}
#[allow(irrefutable_let_patterns)]
if let OpenTargetEventReport::FlexibleEvent(ref mut val) = self {
fidl::decode!(Empty, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self = OpenTargetEventReport::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for TableResultClassification {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for TableResultClassification {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<TableResultClassification, D> for &TableResultClassification
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<TableResultClassification>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
TableResultClassification::Success(ref val) => {
fidl::encoding::encode_in_envelope::<TablePayload, D>(
<TablePayload as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
TableResultClassification::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
TableResultClassification::__SourceBreaking { .. } => {
Err(fidl::Error::UnknownUnionTag)
}
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for TableResultClassification
{
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <TablePayload as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let TableResultClassification::Success(_) = self {
} else {
*self =
TableResultClassification::Success(fidl::new_empty!(TablePayload, D));
}
#[allow(irrefutable_let_patterns)]
if let TableResultClassification::Success(ref mut val) = self {
fidl::decode!(TablePayload, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let TableResultClassification::FidlError(_) = self {
} else {
*self = TableResultClassification::FidlError(fidl::new_empty!(
FidlErrorKind,
D
));
}
#[allow(irrefutable_let_patterns)]
if let TableResultClassification::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self =
TableResultClassification::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for UnionPayload {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for UnionPayload {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Encode<UnionPayload, D>
for &UnionPayload
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<UnionPayload>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
UnionPayload::SomeVariant(ref val) => fidl::encoding::encode_in_envelope::<i32, D>(
<i32 as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
),
UnionPayload::__SourceBreaking { .. } => Err(fidl::Error::UnknownUnionTag),
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D> for UnionPayload {
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <i32 as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let UnionPayload::SomeVariant(_) = self {
} else {
*self = UnionPayload::SomeVariant(fidl::new_empty!(i32, D));
}
#[allow(irrefutable_let_patterns)]
if let UnionPayload::SomeVariant(ref mut val) = self {
fidl::decode!(i32, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self = UnionPayload::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
impl fidl::encoding::ValueTypeMarker for UnionResultClassification {
type Borrowed<'a> = &'a Self;
fn borrow(value: &<Self as fidl::encoding::TypeMarker>::Owned) -> Self::Borrowed<'_> {
value
}
}
unsafe impl fidl::encoding::TypeMarker for UnionResultClassification {
type Owned = Self;
#[inline(always)]
fn inline_align(_context: fidl::encoding::Context) -> usize {
8
}
#[inline(always)]
fn inline_size(_context: fidl::encoding::Context) -> usize {
16
}
}
unsafe impl<D: fidl::encoding::ResourceDialect>
fidl::encoding::Encode<UnionResultClassification, D> for &UnionResultClassification
{
#[inline]
unsafe fn encode(
self,
encoder: &mut fidl::encoding::Encoder<'_, D>,
offset: usize,
_depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
encoder.debug_check_bounds::<UnionResultClassification>(offset);
encoder.write_num::<u64>(self.ordinal(), offset);
match self {
UnionResultClassification::Success(ref val) => {
fidl::encoding::encode_in_envelope::<UnionPayload, D>(
<UnionPayload as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
UnionResultClassification::FidlError(ref val) => {
fidl::encoding::encode_in_envelope::<FidlErrorKind, D>(
<FidlErrorKind as fidl::encoding::ValueTypeMarker>::borrow(val),
encoder,
offset + 8,
_depth,
)
}
UnionResultClassification::__SourceBreaking { .. } => {
Err(fidl::Error::UnknownUnionTag)
}
}
}
}
impl<D: fidl::encoding::ResourceDialect> fidl::encoding::Decode<Self, D>
for UnionResultClassification
{
#[inline(always)]
fn new_empty() -> Self {
Self::__SourceBreaking { unknown_ordinal: 0 }
}
#[inline]
unsafe fn decode(
&mut self,
decoder: &mut fidl::encoding::Decoder<'_, D>,
offset: usize,
mut depth: fidl::encoding::Depth,
) -> fidl::Result<()> {
decoder.debug_check_bounds::<Self>(offset);
#[allow(unused_variables)]
let next_out_of_line = decoder.next_out_of_line();
let handles_before = decoder.remaining_handles();
let (ordinal, inlined, num_bytes, num_handles) =
fidl::encoding::decode_union_inline_portion(decoder, offset)?;
let member_inline_size = match ordinal {
1 => <UnionPayload as fidl::encoding::TypeMarker>::inline_size(decoder.context),
3 => <FidlErrorKind as fidl::encoding::TypeMarker>::inline_size(decoder.context),
0 => return Err(fidl::Error::UnknownUnionTag),
_ => num_bytes as usize,
};
if inlined != (member_inline_size <= 4) {
return Err(fidl::Error::InvalidInlineBitInEnvelope);
}
let _inner_offset;
if inlined {
decoder.check_inline_envelope_padding(offset + 8, member_inline_size)?;
_inner_offset = offset + 8;
} else {
depth.increment()?;
_inner_offset = decoder.out_of_line_offset(member_inline_size)?;
}
match ordinal {
1 => {
#[allow(irrefutable_let_patterns)]
if let UnionResultClassification::Success(_) = self {
} else {
*self =
UnionResultClassification::Success(fidl::new_empty!(UnionPayload, D));
}
#[allow(irrefutable_let_patterns)]
if let UnionResultClassification::Success(ref mut val) = self {
fidl::decode!(UnionPayload, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
3 => {
#[allow(irrefutable_let_patterns)]
if let UnionResultClassification::FidlError(_) = self {
} else {
*self = UnionResultClassification::FidlError(fidl::new_empty!(
FidlErrorKind,
D
));
}
#[allow(irrefutable_let_patterns)]
if let UnionResultClassification::FidlError(ref mut val) = self {
fidl::decode!(FidlErrorKind, D, val, decoder, _inner_offset, depth)?;
} else {
unreachable!()
}
}
#[allow(deprecated)]
ordinal => {
for _ in 0..num_handles {
decoder.drop_next_handle()?;
}
*self =
UnionResultClassification::__SourceBreaking { unknown_ordinal: ordinal };
}
}
if !inlined && decoder.next_out_of_line() != next_out_of_line + (num_bytes as usize) {
return Err(fidl::Error::InvalidNumBytesInEnvelope);
}
if handles_before != decoder.remaining_handles() + (num_handles as usize) {
return Err(fidl::Error::InvalidNumHandlesInEnvelope);
}
Ok(())
}
}
}