Trait gdnative_doc::Callbacks[][src]

pub trait Callbacks {
    fn extension(&self) -> &'static str;
fn encode(&mut self, s: &mut String, events: Vec<Event<'_>>); fn start_class(
        &mut self,
        _s: &mut String,
        _resolver: &Resolver,
        _class: &GdnativeClass
    ) { ... }
fn start_method(
        &mut self,
        _s: &mut String,
        _resolver: &Resolver,
        _method: &Method
    ) { ... }
fn start_property(
        &mut self,
        _s: &mut String,
        _resolver: &Resolver,
        _property: &Property
    ) { ... }
fn finish_encoding(&mut self, _s: &mut String) { ... } }

Callbacks to encode markdown input in a given format.

Required methods

fn extension(&self) -> &'static str[src]

File extension for the files generated by this callback.

fn encode(&mut self, s: &mut String, events: Vec<Event<'_>>)[src]

Encode the stream of events in s.

Loading content...

Provided methods

fn start_class(
    &mut self,
    _s: &mut String,
    _resolver: &Resolver,
    _class: &GdnativeClass
)
[src]

Called before encoding each class.

Default: does nothing

fn start_method(
    &mut self,
    _s: &mut String,
    _resolver: &Resolver,
    _method: &Method
)
[src]

Called before encoding each method.

Default: does nothing

fn start_property(
    &mut self,
    _s: &mut String,
    _resolver: &Resolver,
    _property: &Property
)
[src]

Called before encoding each property.

Default: does nothing

fn finish_encoding(&mut self, _s: &mut String)[src]

Called at the end of the processing for a given file.

Default: does nothing

Loading content...

Implementations

impl dyn Callbacks[src]

pub fn start_method_default(
    &mut self,
    s: &mut String,
    property: &Resolver,
    method: &Method
)
[src]

Default start_method implementation, implemented on dyn Callbacks to avoid code duplication.

This will create a level 3 header that looks like (in markdown):

### <a id="func-name"></a>func name(arg1: type, ...) -> type
________

With appropriate linking.

pub fn start_property_default(
    &mut self,
    s: &mut String,
    resolver: &Resolver,
    property: &Property
)
[src]

Default start_property implementation, implemented on dyn Callbacks to avoid code duplication.

This will create a level 3 header that looks like (in markdown):

### <a id="property-name"></a> name: type
________

With appropriate linking.

Trait Implementations

impl Debug for dyn Callbacks[src]

Implementors

Loading content...