RepositoryTrafficReferrers() public static method

Returns the Uri for repository traffice referrers.
public static RepositoryTrafficReferrers ( long repositoryId ) : Uri
repositoryId long The id of the repository
return Uri
示例#1
0
        /// <summary>
        /// List the top 10 referrers over the last 14 days
        /// </summary>
        /// <remarks>https://developer.github.com/v3/repos/traffic/#list-referrers</remarks>
        /// <param name="owner">The owner of the repository</param>
        /// <param name="name">The name of the repository</param>
        public Task <IReadOnlyList <RepositoryTrafficReferrer> > GetAllReferrers(string owner, string name)
        {
            Ensure.ArgumentNotNullOrEmptyString(owner, "owner");
            Ensure.ArgumentNotNullOrEmptyString(name, "name");

            return(ApiConnection.GetAll <RepositoryTrafficReferrer>(ApiUrls.RepositoryTrafficReferrers(owner, name), AcceptHeaders.RepositoryTrafficApiPreview));
        }
示例#2
0
        public Task <IReadOnlyList <RepositoryTrafficReferrer> > GetAllReferrers(string owner, string name)
        {
            Ensure.ArgumentNotNullOrEmptyString(owner, nameof(owner));
            Ensure.ArgumentNotNullOrEmptyString(name, nameof(name));

            return(ApiConnection.GetAll <RepositoryTrafficReferrer>(ApiUrls.RepositoryTrafficReferrers(owner, name)));
        }
示例#3
0
 /// <summary>
 /// List the top 10 referrers over the last 14 days
 /// </summary>
 /// <remarks>https://developer.github.com/v3/repos/traffic/#list-referrers</remarks>
 /// <param name="repositoryId">The owner of the repository</param>
 public Task <IReadOnlyList <RepositoryTrafficReferrer> > GetAllReferrers(long repositoryId)
 {
     return(ApiConnection.GetAll <RepositoryTrafficReferrer>(ApiUrls.RepositoryTrafficReferrers(repositoryId), AcceptHeaders.RepositoryTrafficApiPreview));
 }