[][src]Struct git2::Signature

pub struct Signature<'a> { /* fields omitted */ }

A Signature is used to indicate authorship of various actions throughout the library.

Signatures contain a name, email, and timestamp. All fields can be specified with new while the now constructor omits the timestamp. The Repository::signature method can be used to create a default signature with name and email values read from the configuration.

Methods

impl<'a> Signature<'a>
[src]

Create a new action signature with a timestamp of 'now'.

See new for more information

Create a new action signature.

The time specified is in seconds since the epoch, and the offset is the time zone offset in minutes.

Returns error if either name or email contain angle brackets.

Gets the name on the signature.

Returns None if the name is not valid utf-8

Gets the name on the signature as a byte slice.

Gets the email on the signature.

Returns None if the email is not valid utf-8

Gets the email on the signature as a byte slice.

Get the when of this signature.

Convert a signature of any lifetime into an owned signature with a static lifetime.

Trait Implementations

impl Clone for Signature<'static>
[src]

Performs copy-assignment from source. Read more

impl<'a> Drop for Signature<'a>
[src]

impl<'a> Display for Signature<'a>
[src]

Auto Trait Implementations

impl<'a> !Send for Signature<'a>

impl<'a> !Sync for Signature<'a>

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]