EnterpriseSearchIndexing() public static method

public static EnterpriseSearchIndexing ( ) : Uri
return System.Uri
        /// <summary>
        /// Queue an indexing job for all of a user or organization's repositories (must be Site Admin user).
        /// </summary>
        /// <remarks>
        /// https://developer.github.com/v3/enterprise/search_indexing/#queue-an-indexing-job
        /// </remarks>
        /// <param name="owner">A user or organization account</param>
        /// <returns>The <see cref="SearchIndexingResponse"/> message.</returns>
        public Task <SearchIndexingResponse> QueueAll(string owner)
        {
            Ensure.ArgumentNotNull(owner, "owner");

            var endpoint = ApiUrls.EnterpriseSearchIndexing();
            var target   = new SearchIndexTarget(string.Format(CultureInfo.InvariantCulture, "{0}/*", owner));

            return(ApiConnection.Post <SearchIndexingResponse>(endpoint, target));
        }
Esempio n. 2
0
        /// <summary>
        /// Queue an indexing job for all the issues in all of a user or organization's repositories (must be Site Admin user).
        /// </summary>
        /// <remarks>
        /// https://developer.github.com/v3/enterprise/search_indexing/#queue-an-indexing-job
        /// </remarks>
        /// <param name="owner">A user or organization account</param>
        /// <returns>The <see cref="SearchIndexingResponse"/> message.</returns>
        public async Task <SearchIndexingResponse> QueueAllIssues(string owner)
        {
            Ensure.ArgumentNotNull(owner, "owner");

            var endpoint = ApiUrls.EnterpriseSearchIndexing();
            var target   = new SearchIndexTarget(string.Format(CultureInfo.InvariantCulture, "{0}/*/issues", owner));

            return(await ApiConnection.Post <SearchIndexingResponse>(endpoint, target)
                   .ConfigureAwait(false));
        }
        /// <summary>
        /// Queue an indexing job for all the issues in a repository (must be Site Admin user).
        /// </summary>
        /// <remarks>
        /// https://developer.github.com/v3/enterprise/search_indexing/#queue-an-indexing-job
        /// </remarks>
        /// <param name="owner">A user or organization account</param>
        /// <param name="repository">A repository</param>
        /// <returns>The <see cref="SearchIndexingResponse"/> message.</returns>
        public Task <SearchIndexingResponse> QueueAllIssues(string owner, string repository)
        {
            Ensure.ArgumentNotNull(owner, nameof(owner));
            Ensure.ArgumentNotNull(repository, nameof(repository));

            var endpoint = ApiUrls.EnterpriseSearchIndexing();
            var target   = new SearchIndexTarget(string.Format(CultureInfo.InvariantCulture, "{0}/{1}/issues", owner, repository));

            return(ApiConnection.Post <SearchIndexingResponse>(endpoint, target));
        }
Esempio n. 4
0
        /// <summary>
        /// Queue an indexing job for all the source code in a repository (must be Site Admin user).
        /// </summary>
        /// <remarks>
        /// https://developer.github.com/v3/enterprise/search_indexing/#queue-an-indexing-job
        /// </remarks>
        /// <param name="owner">A user or organization account</param>
        /// <param name="repository">A repository</param>
        /// <returns>The <see cref="SearchIndexingResponse"/> message.</returns>
        public async Task <SearchIndexingResponse> QueueAllCode(string owner, string repository)
        {
            Ensure.ArgumentNotNull(owner, "owner");
            Ensure.ArgumentNotNull(repository, "repository");

            var endpoint = ApiUrls.EnterpriseSearchIndexing();
            var target   = new SearchIndexTarget(string.Format(CultureInfo.InvariantCulture, "{0}/{1}/code", owner, repository));

            return(await ApiConnection.Post <SearchIndexingResponse>(endpoint, target)
                   .ConfigureAwait(false));
        }