Struct fidl_fuchsia_io::NodeOptions
source · pub struct NodeOptions {
pub flags: Option<NodeFlags>,
pub protocols: Option<NodeProtocols>,
pub mode: Option<OpenMode>,
pub rights_request: Option<RightsRequest>,
/* private fields */
}
Fields§
§flags: Option<NodeFlags>
§protocols: Option<NodeProtocols>
Callers may assert the type of the object by setting the protocol corresponding to the expected type:
-
If the caller expected a directory but the node cannot be accessed as a directory, the error is
ZX_ERR_NOT_DIR
. -
If the caller expected a file but the node cannot be accessed as a file, the error is
ZX_ERR_NOT_FILE
. -
In other mismatched cases, the error is
ZX_ERR_WRONG_TYPE
.
If more than one protocol is present, the resultant protocol
may become any one of them. Callers should specify
[NodeFlags.GET_REPRESENTATION
] to receive a
[Node.OnRepresentation
] event, in order to ascertain the
protocol.
If absent, indicates that the caller accepts any [Node
]
protocol (including [Node
] itself for connector nodes, for
instance).
mode: Option<OpenMode>
Specifies behavior with respect to existence. If an object
is to be created, its type is specified by protocols
; it
must be present. If a valid object type cannot be
unambiguously inferred e.g. both directory
and file
are
set, the request must fail.
rights_request: Option<RightsRequest>
Requests rights on the new connection according to the specified rules.
If absent, inherits at most the rights from the connection
where the Open
call is made. If the path crosses
intermediate proxies, a proxy may strip elements from the
resulting rights if the intermediate connection does not
have the corresponding rights.
Implementations§
source§impl NodeOptions
impl NodeOptions
Trait Implementations§
source§impl Clone for NodeOptions
impl Clone for NodeOptions
source§fn clone(&self) -> NodeOptions
fn clone(&self) -> NodeOptions
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for NodeOptions
impl Debug for NodeOptions
source§impl Decode<NodeOptions> for NodeOptions
impl Decode<NodeOptions> for NodeOptions
source§impl Encode<NodeOptions> for &NodeOptions
impl Encode<NodeOptions> for &NodeOptions
source§impl Encode<NodeOptions> for NodeOptions
impl Encode<NodeOptions> for NodeOptions
source§impl PartialEq<NodeOptions> for NodeOptions
impl PartialEq<NodeOptions> for NodeOptions
source§fn eq(&self, other: &NodeOptions) -> bool
fn eq(&self, other: &NodeOptions) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl TypeMarker for NodeOptions
impl TypeMarker for NodeOptions
§type Owned = NodeOptions
type Owned = NodeOptions
source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.source§impl ValueTypeMarker for NodeOptions
impl ValueTypeMarker for NodeOptions
§type Borrowed<'a> = &'a <NodeOptions as TypeMarker>::Owned
type Borrowed<'a> = &'a <NodeOptions as TypeMarker>::Owned
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read more