Trait RemoteCommit

Source
pub trait RemoteCommit: DynClone {
    // Required methods
    fn id(&self) -> String;
    fn username(&self) -> Option<String>;
    fn timestamp(&self) -> Option<i64>;

    // Provided method
    fn convert_to_unix_timestamp(&self, date: &str) -> i64 { ... }
}
Available on crate feature remote only.
Expand description

Trait for handling remote commits.

Required Methods§

Source

fn id(&self) -> String

Commit SHA.

Source

fn username(&self) -> Option<String>

Commit author.

Source

fn timestamp(&self) -> Option<i64>

Timestamp.

Provided Methods§

Source

fn convert_to_unix_timestamp(&self, date: &str) -> i64

Convert date in RFC3339 format to unix timestamp

Implementors§

Source§

impl RemoteCommit for BitbucketCommit

Available on crate feature bitbucket only.
Source§

impl RemoteCommit for GiteaCommit

Available on crate feature gitea only.
Source§

impl RemoteCommit for GitHubCommit

Available on crate feature github only.
Source§

impl RemoteCommit for GitLabCommit

Available on crate feature gitlab only.