Struct nu_plugin_s3::handler::Handler
source · [−]pub struct Handler {
pub resource: Option<Value>,
pub tag: Tag,
pub has_raw: bool,
pub config: CredentialConfig,
}
Fields
resource: Option<Value>
tag: Tag
has_raw: bool
config: CredentialConfig
Implementations
Trait Implementations
sourceimpl Plugin for Handler
impl Plugin for Handler
sourcefn config(&mut self) -> Result<Signature, ShellError>
fn config(&mut self) -> Result<Signature, ShellError>
The config
method is used to configure a plugin’s user interface / signature. Read more
sourcefn begin_filter(
&mut self,
callinfo: CallInfo
) -> Result<Vec<ReturnValue>, ShellError>
fn begin_filter(
&mut self,
callinfo: CallInfo
) -> Result<Vec<ReturnValue>, ShellError>
begin_filter
is the first method to be called if the Signature
of the plugin is configured to be filterable.
Any setup required for the plugin such as parsing arguments from CallInfo
or initializing data structures
can be done here. The CallInfo
parameter will contain data configured in the config
method of the Plugin trait. Read more
sourcefn filter(
&mut self,
_input: Value
) -> Result<Vec<Result<ReturnSuccess, ShellError>, Global>, ShellError>
fn filter(
&mut self,
_input: Value
) -> Result<Vec<Result<ReturnSuccess, ShellError>, Global>, ShellError>
filter
is called for every Value
that is processed by the plugin.
This method requires the plugin Signature
to be configured as filterable. Read more
sourcefn end_filter(
&mut self
) -> Result<Vec<Result<ReturnSuccess, ShellError>, Global>, ShellError>
fn end_filter(
&mut self
) -> Result<Vec<Result<ReturnSuccess, ShellError>, Global>, ShellError>
end_filter
is the last method to be called by the plugin after all Value
s are processed by the plugin.
This method requires the plugin Signature
to be configured as filterable. Read more
sourcefn sink(&mut self, _call_info: CallInfo, _input: Vec<Value, Global>)
fn sink(&mut self, _call_info: CallInfo, _input: Vec<Value, Global>)
sink
consumes the Value
s that are passed in, preventing further processing.
This method requires the plugin Signature
to be configured without filtering. Read more
fn quit(&mut self)
Auto Trait Implementations
impl RefUnwindSafe for Handler
impl Send for Handler
impl Sync for Handler
impl Unpin for Handler
impl UnwindSafe for Handler
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> SpannedItem for T
impl<T> SpannedItem for T
sourceimpl<T> TaggedItem for T
impl<T> TaggedItem for T
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more