C# Class UmbracoFlare.Manager.UmbracoFlareDomainManager

ファイルを表示 Open project: scyllagroup/UmbracoFlare

Public Methods

Method Description
FilterToAllowedDomains ( IEnumerable domains ) : IEnumerable

This will take a list of domains and make sure that they are either equal to or a subdomain of the allowed domains in cloudflare.

GetDomainsFromCloudflareZones ( ) : IEnumerable

Gets the domains from each cloudflare zone.

GetUrlsForNode ( IContent content, bool includeDescendants = false ) : List

We want to get the domains associated with the content node. This includes getting the allowed domains on the node as well as searching up the tree to get the parents nodes since they are inherited.

GetUrlsForNode ( int contentId, bool includeDescendants = false ) : List

Private Methods

Method Description
GetAllowedZonesAndDomains ( ) : IEnumerable>.KeyValuePair

This method will grab the list of zones from cloudflare. It will then check to make sure that the zone has some corresponding hostnames in umbraco. If it does, we will save the domain names & the zones.

GetDescendantsDomains ( List domains, IEnumerable descendants ) : List
RecursivelyGetParentsDomains ( List domains, IContent content ) : List
UmbracoFlareDomainManager ( ) : System

Method Details

FilterToAllowedDomains() public method

This will take a list of domains and make sure that they are either equal to or a subdomain of the allowed domains in cloudflare.
public FilterToAllowedDomains ( IEnumerable domains ) : IEnumerable
domains IEnumerable The domains to filter.
return IEnumerable

GetDomainsFromCloudflareZones() public method

Gets the domains from each cloudflare zone.
public GetDomainsFromCloudflareZones ( ) : IEnumerable
return IEnumerable

GetUrlsForNode() public method

We want to get the domains associated with the content node. This includes getting the allowed domains on the node as well as searching up the tree to get the parents nodes since they are inherited.
public GetUrlsForNode ( IContent content, bool includeDescendants = false ) : List
content IContent
includeDescendants bool
return List

GetUrlsForNode() public method

public GetUrlsForNode ( int contentId, bool includeDescendants = false ) : List
contentId int
includeDescendants bool
return List