Repository

Struct Repository 

Source
pub struct Repository { /* private fields */ }
Expand description

Repository on GitHub

Repositories are a core resource on GitHub, and most other resources belong to them. They are uniquely identified by the combination of their owner and name.

Implementations§

Source§

impl Repository

Source

pub fn id(&self) -> RepositoryId

Returns the repository’s unique id.

Source

pub fn node_id(&self) -> &NodeId

Returns the repository’s node id.

Source

pub fn name(&self) -> &RepositoryName

Returns the repository’s name.

Source

pub fn owner(&self) -> &Account

Returns the account which ows the repository.

Source

pub fn full_name(&self) -> &RepositoryFullName

Returns the repository’s full name.

Source

pub fn description(&self) -> &String

Returns the repository’s description.

Source

pub fn homepage(&self) -> &String

Returns the URL to the repository’s homepage.

Source

pub fn language(&self) -> &String

Returns the repository’s primary programming language.

Source

pub fn license(&self) -> &License

Returns the repository’s license.

Source

pub fn visibility(&self) -> Visibility

Returns the repository’s visibility.

Source

pub fn default_branch(&self) -> &String

Returns the repository’s default branch.

Source

pub fn topics(&self) -> &Vec<String>

Returns the repository’s topics.

Source

pub fn size(&self) -> u64

Returns the repository’s size.

Source

pub fn stargazers_count(&self) -> u64

Returns the repository’s stargazers count.

Source

pub fn watchers_count(&self) -> u64

Returns the repository’s watchers count.

Source

pub fn forks_count(&self) -> u64

Returns the repository’s forks count.

Source

pub fn open_issues_count(&self) -> u64

Returns the repository’s open issues count.

Source

pub fn private(&self) -> bool

Indicates whether the repository is private.

Source

pub fn fork(&self) -> bool

Indicates whether the repository is a fork.

Source

pub fn has_issues(&self) -> bool

Indicates whether the issues feature is enabled for the repository.

Source

pub fn has_projects(&self) -> bool

Indicates whether the projects feature is enabled for the repository.

Source

pub fn has_wiki(&self) -> bool

Indicates whether the wiki feature is enabled for the repository.

Source

pub fn has_pages(&self) -> bool

Indicates whether the repository has a static website.

Source

pub fn archived(&self) -> bool

Indicates whether the repository has been archived.

Source

pub fn disabled(&self) -> bool

Indicates whether the repository has been disabled.

Source

pub fn allow_forking(&self) -> bool

Indicates whether the repository can be forked.

Source

pub fn is_template(&self) -> bool

Indicates whether the repository can be used as a template.

Source

pub fn web_commit_signoff_required(&self) -> bool

Indicates whether the signoff is required for commits through GitHub’s web interface.

Source

pub fn html_url(&self) -> &Url

Returns the URL to the repository.

Source

pub fn url(&self) -> &Url

Returns the API endpoint to query the repository.

Source

pub fn keys_url(&self) -> &Url

Returns the API endpoint to query the repository’s keys.

Source

pub fn collaborators_url(&self) -> &Url

Returns the API endpoint to query the repository’s collaborators.

Source

pub fn teams_url(&self) -> &Url

Returns the API endpoint to query the repository’s teams.

Source

pub fn hooks_url(&self) -> &Url

Returns the API endpoint to query the repository’s hooks.

Source

pub fn issue_events_url(&self) -> &Url

Returns the API endpoint to query the repository’s issue events.

Source

pub fn events_url(&self) -> &Url

Returns the API endpoint to query the repository’s events.

Source

pub fn assignees_url(&self) -> &Url

Returns the API endpoint to query the repository’s assignees.

Source

pub fn branches_url(&self) -> &Url

Returns the API endpoint to query the repository’s branches.

Source

pub fn tags_url(&self) -> &Url

Returns the API endpoint to query the repository’s tags.

Source

pub fn blobs_url(&self) -> &Url

Returns the API endpoint to query the repository’s blobs.

Source

pub fn git_tags_url(&self) -> &Url

Returns the API endpoint to query the repository’s git tags.

Source

pub fn git_refs_url(&self) -> &Url

Returns the API endpoint to query the repository’s git refs.

Source

pub fn trees_url(&self) -> &Url

Returns the API endpoint to query the repository’s git trees.

Source

pub fn statuses_url(&self) -> &Url

Returns the API endpoint to query the repository’s statuses.

Source

pub fn languages_url(&self) -> &Url

Returns the API endpoint to query the repository’s programming languages.

Source

pub fn stargazers_url(&self) -> &Url

Returns the API endpoint to query the repository’s stargazers.

Source

pub fn contributors_url(&self) -> &Url

Returns the API endpoint to query the repository’s contributors.

Source

pub fn subscribers_url(&self) -> &Url

Returns the API endpoint to query the repository’s subscribers.

Source

pub fn subscription_url(&self) -> &Url

Returns the API endpoint to query the repository’s subscriptions.

Source

pub fn commits_url(&self) -> &Url

Returns the API endpoint to query the repository’s commits.

Source

pub fn git_commits_url(&self) -> &Url

Returns the API endpoint to query the repository’s git commits.

Source

pub fn comments_url(&self) -> &Url

Returns the API endpoint to query the repository’s comments.

Source

pub fn issue_comment_url(&self) -> &Url

Returns the API endpoint to query the repository’s issue comments.

Source

pub fn contents_url(&self) -> &Url

Returns the API endpoint to query the repository’s contents.

Source

pub fn compare_url(&self) -> &Url

Returns the API endpoint to compare refs in the repository.

Source

pub fn merges_url(&self) -> &Url

Returns the API endpoint to query the repository’s merges.

Source

pub fn archive_url(&self) -> &Url

Returns the API endpoint to retrieve the repository’s archive.

Source

pub fn downloads_url(&self) -> &Url

Returns the API endpoint to query the repository’s downloads.

Source

pub fn issues_url(&self) -> &Url

Returns the API endpoint to query the repository’s issues.

Source

pub fn pulls_url(&self) -> &Url

Returns the API endpoint to query the repository’s pull requests.

Source

pub fn milestones_url(&self) -> &Url

Returns the API endpoint to query the repository’s milestones.

Source

pub fn notifications_url(&self) -> &Url

Returns the API endpoint to query the repository’s notifications.

Source

pub fn labels_url(&self) -> &Url

Returns the API endpoint to query the repository’s labels.

Source

pub fn releases_url(&self) -> &Url

Returns the API endpoint to query the repository’s releases.

Source

pub fn deployments_url(&self) -> &Url

Returns the API endpoint to query the repository’s deployments.

Source

pub fn git_url(&self) -> &Url

Returns the Git URL to clone the repository.

Source

pub fn ssh_url(&self) -> &str

Returns the SSH URL to clone the repository.

Source

pub fn clone_url(&self) -> &Url

Returns the HTTP URL to clone the repository.

Source

pub fn svn_url(&self) -> &Url

Returns the SVN URL to clone the repository.

Source

pub fn mirror_url(&self) -> &Option<Url>

Returns the URL to the repository’s mirror.

Source

pub fn created_at(&self) -> &DateTime<Utc>

Returns the date when the repository was created.

Source

pub fn updated_at(&self) -> &DateTime<Utc>

Returns the date when the repository was last updated.

Source

pub fn pushed_at(&self) -> &DateTime<Utc>

Returns the date when the repository was last pushed.

Trait Implementations§

Source§

impl Clone for Repository

Source§

fn clone(&self) -> Repository

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Repository

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for Repository

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Display for Repository

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Hash for Repository

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl Ord for Repository

Source§

fn cmp(&self, other: &Repository) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · Source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized,

Restrict a value to a certain interval. Read more
Source§

impl PartialEq for Repository

Source§

fn eq(&self, other: &Repository) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl PartialOrd for Repository

Source§

fn partial_cmp(&self, other: &Repository) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · Source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · Source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · Source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · Source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
Source§

impl Serialize for Repository

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl Eq for Repository

Source§

impl StructuralPartialEq for Repository

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<Q, K> Comparable<K> for Q
where Q: Ord + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn compare(&self, key: &K) -> Ordering

Compare self to key and return their ordering.
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

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
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,