Search Results for

    Show / Hide Table of Contents
    View Source

    Interface IPublicAccessService

    Namespace: Umbraco.Cms.Core.Services
    Assembly: Umbraco.Core.dll
    Syntax
    public interface IPublicAccessService : IService

    Methods

    View Source

    AddRule(IContent, String, String)

    Adds a rule if the entry doesn't already exist

    Declaration
    Attempt<OperationResult<OperationResultType, PublicAccessEntry>> AddRule(IContent content, string ruleType, string ruleValue)
    Parameters
    Type Name Description
    IContent content
    System.String ruleType
    System.String ruleValue
    Returns
    Type Description
    Attempt<OperationResult<OperationResultType, PublicAccessEntry>>
    View Source

    Delete(PublicAccessEntry)

    Deletes the entry and all associated rules

    Declaration
    Attempt<OperationResult> Delete(PublicAccessEntry entry)
    Parameters
    Type Name Description
    PublicAccessEntry entry
    Returns
    Type Description
    Attempt<OperationResult>
    View Source

    GetAll()

    Gets all defined entries and associated rules

    Declaration
    IEnumerable<PublicAccessEntry> GetAll()
    Returns
    Type Description
    IEnumerable<PublicAccessEntry>
    View Source

    GetEntryForContent(String)

    Gets the entry defined for the content item based on a content path

    Declaration
    PublicAccessEntry GetEntryForContent(string contentPath)
    Parameters
    Type Name Description
    System.String contentPath
    Returns
    Type Description
    PublicAccessEntry

    Returns null if no entry is found

    View Source

    GetEntryForContent(IContent)

    Gets the entry defined for the content item's path

    Declaration
    PublicAccessEntry GetEntryForContent(IContent content)
    Parameters
    Type Name Description
    IContent content
    Returns
    Type Description
    PublicAccessEntry

    Returns null if no entry is found

    View Source

    IsProtected(String)

    Returns true if the content has an entry based on a content path

    Declaration
    Attempt<PublicAccessEntry> IsProtected(string contentPath)
    Parameters
    Type Name Description
    System.String contentPath
    Returns
    Type Description
    Attempt<PublicAccessEntry>
    View Source

    IsProtected(IContent)

    Returns true if the content has an entry for it's path

    Declaration
    Attempt<PublicAccessEntry> IsProtected(IContent content)
    Parameters
    Type Name Description
    IContent content
    Returns
    Type Description
    Attempt<PublicAccessEntry>
    View Source

    RemoveRule(IContent, String, String)

    Removes a rule

    Declaration
    Attempt<OperationResult> RemoveRule(IContent content, string ruleType, string ruleValue)
    Parameters
    Type Name Description
    IContent content
    System.String ruleType
    System.String ruleValue
    Returns
    Type Description
    Attempt<OperationResult>
    View Source

    Save(PublicAccessEntry)

    Saves the entry

    Declaration
    Attempt<OperationResult> Save(PublicAccessEntry entry)
    Parameters
    Type Name Description
    PublicAccessEntry entry
    Returns
    Type Description
    Attempt<OperationResult>
    • Improve this Doc
    • View Source
    In This Article
    • Methods
      • AddRule(IContent, String, String)
      • Delete(PublicAccessEntry)
      • GetAll()
      • GetEntryForContent(String)
      • GetEntryForContent(IContent)
      • IsProtected(String)
      • IsProtected(IContent)
      • RemoveRule(IContent, String, String)
      • Save(PublicAccessEntry)
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX