Search Results for

    Show / Hide Table of Contents
    View Source

    Interface IRedirectUrlRepository

    Defines the IRedirectUrl repository.

    Namespace: Umbraco.Cms.Core.Persistence.Repositories
    Assembly: Umbraco.Core.dll
    Syntax
    public interface IRedirectUrlRepository : IReadWriteQueryRepository<Guid, IRedirectUrl>, IReadRepository<Guid, IRedirectUrl>, IWriteRepository<IRedirectUrl>, IQueryRepository<IRedirectUrl>, IRepository

    Methods

    View Source

    Delete(Guid)

    Deletes a redirect URL.

    Declaration
    void Delete(Guid id)
    Parameters
    Type Name Description
    Guid id

    The redirect URL identifier.

    View Source

    DeleteAll()

    Deletes all redirect URLs.

    Declaration
    void DeleteAll()
    View Source

    DeleteContentUrls(Guid)

    Deletes all redirect URLs for a given content.

    Declaration
    void DeleteContentUrls(Guid contentKey)
    Parameters
    Type Name Description
    Guid contentKey

    The content unique key.

    View Source

    Get(String, Guid, String)

    Gets a redirect URL.

    Declaration
    IRedirectUrl Get(string url, Guid contentKey, string culture)
    Parameters
    Type Name Description
    System.String url

    The Umbraco redirect URL route.

    Guid contentKey

    The content unique key.

    System.String culture

    The culture.

    Returns
    Type Description
    IRedirectUrl
    View Source

    GetAllUrls(Int32, Int64, Int32, out Int64)

    Gets all redirect URLs below a given content item.

    Declaration
    IEnumerable<IRedirectUrl> GetAllUrls(int rootContentId, long pageIndex, int pageSize, out long total)
    Parameters
    Type Name Description
    System.Int32 rootContentId

    The content unique identifier.

    System.Int64 pageIndex

    The page index.

    System.Int32 pageSize

    The page size.

    System.Int64 total

    The total count of redirect URLs.

    Returns
    Type Description
    IEnumerable<IRedirectUrl>

    The redirect URLs.

    View Source

    GetAllUrls(Int64, Int32, out Int64)

    Gets all redirect URLs.

    Declaration
    IEnumerable<IRedirectUrl> GetAllUrls(long pageIndex, int pageSize, out long total)
    Parameters
    Type Name Description
    System.Int64 pageIndex

    The page index.

    System.Int32 pageSize

    The page size.

    System.Int64 total

    The total count of redirect URLs.

    Returns
    Type Description
    IEnumerable<IRedirectUrl>

    The redirect URLs.

    View Source

    GetContentUrls(Guid)

    Gets all redirect URLs for a content item.

    Declaration
    IEnumerable<IRedirectUrl> GetContentUrls(Guid contentKey)
    Parameters
    Type Name Description
    Guid contentKey

    The content unique key.

    Returns
    Type Description
    IEnumerable<IRedirectUrl>

    All redirect URLs for the content item.

    View Source

    GetMostRecentUrl(String)

    Gets the most recent redirect URL corresponding to an Umbraco redirect URL route.

    Declaration
    IRedirectUrl GetMostRecentUrl(string url)
    Parameters
    Type Name Description
    System.String url

    The Umbraco redirect URL route.

    Returns
    Type Description
    IRedirectUrl

    The most recent redirect URL corresponding to the route.

    View Source

    GetMostRecentUrl(String, String)

    Gets the most recent redirect URL corresponding to an Umbraco redirect URL route.

    Declaration
    IRedirectUrl GetMostRecentUrl(string url, string culture)
    Parameters
    Type Name Description
    System.String url

    The Umbraco redirect URL route.

    System.String culture

    The culture the domain is associated with

    Returns
    Type Description
    IRedirectUrl

    The most recent redirect URL corresponding to the route.

    View Source

    GetMostRecentUrlAsync(String)

    Gets the most recent redirect URL corresponding to an Umbraco redirect URL route.

    Declaration
    virtual Task<IRedirectUrl> GetMostRecentUrlAsync(string url)
    Parameters
    Type Name Description
    System.String url

    The Umbraco redirect URL route.

    Returns
    Type Description
    System.Threading.Tasks.Task<IRedirectUrl>

    The most recent redirect URL corresponding to the route.

    View Source

    GetMostRecentUrlAsync(String, String)

    Gets the most recent redirect URL corresponding to an Umbraco redirect URL route.

    Declaration
    virtual Task<IRedirectUrl> GetMostRecentUrlAsync(string url, string culture)
    Parameters
    Type Name Description
    System.String url

    The Umbraco redirect URL route.

    System.String culture

    The culture the domain is associated with

    Returns
    Type Description
    System.Threading.Tasks.Task<IRedirectUrl>

    The most recent redirect URL corresponding to the route.

    View Source

    SearchUrls(String, Int64, Int32, out Int64)

    Searches for all redirect URLs that contain a given search term in their URL property.

    Declaration
    IEnumerable<IRedirectUrl> SearchUrls(string searchTerm, long pageIndex, int pageSize, out long total)
    Parameters
    Type Name Description
    System.String searchTerm

    The term to search for.

    System.Int64 pageIndex

    The page index.

    System.Int32 pageSize

    The page size.

    System.Int64 total

    The total count of redirect URLs.

    Returns
    Type Description
    IEnumerable<IRedirectUrl>

    The redirect URLs.

    • Improve this Doc
    • View Source
    In This Article
    • Methods
      • Delete(Guid)
      • DeleteAll()
      • DeleteContentUrls(Guid)
      • Get(String, Guid, String)
      • GetAllUrls(Int32, Int64, Int32, out Int64)
      • GetAllUrls(Int64, Int32, out Int64)
      • GetContentUrls(Guid)
      • GetMostRecentUrl(String)
      • GetMostRecentUrl(String, String)
      • GetMostRecentUrlAsync(String)
      • GetMostRecentUrlAsync(String, String)
      • SearchUrls(String, Int64, Int32, out Int64)
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX