Click or drag to resize

ISite Interface


Represents the manager object that provides the means to query and manage Pages and Page Versions.

It is the most important manager, due to fact it manages the central pieces of CMS, the Pages.

Namespace:  Ingeniux.CMS
Assembly:  Ingeniux.CMS.CSAPI (in Ingeniux.CMS.CSAPI.dll) Version: 10.5.94
Syntax
public interface ISite : ITransactionalEntity, IDisposable, 
	IContentStoreMetaData, ISiteEvents, IAssetManager, IAssetManagerEvents, IAssetStorageManager

The ISite type exposes the following members.

Properties
  NameDescription
Public propertyAssetTreeMenuConfig
Public propertyContentStore
Gets the Content Store.
(Inherited from ITransactionalEntity.)
Public propertyCurrentUser
Gets the Operating User for the Session .
(Inherited from ITransactionalEntity.)
Public propertyDefaultThemeId
Default User Theme Id.
(Inherited from IContentStoreMetaData.)
Public propertyGlobalExportsUpdated
Gets the time of the most recent global exports update.
(Inherited from IContentStoreMetaData.)
Public propertyHttpsOn
Gets and sets whether HTTPS is enabled.
(Inherited from IContentStoreMetaData.)
Public propertyMediaHost
Gets and sets the MediaHost, which is the computer that hosts the images folder.
(Inherited from IContentStoreMetaData.)
Public propertyMediaHostModule
Gets and sets the MediaHostModule, which is the module on the MediaHost to which files are copied.
(Inherited from IContentStoreMetaData.)
Public propertyPublishingTargetsUpdated
Gets the time of the most recent publishing targets update.
(Inherited from IContentStoreMetaData.)
Public propertyRedirectsUpdated
Gets the time of the most recent redirect update.
(Inherited from IContentStoreMetaData.)
Public propertyReferenceMappingUpdated
Gets the time of most recent references mapping update.
(Inherited from IContentStoreMetaData.)
Public propertyServerName
Gets and sets the ServerName, which is the value returned from the ServerVariable SERVER_NAME.
(Inherited from IContentStoreMetaData.)
Public propertyServerPort
Gets and sets the server port.
(Inherited from IContentStoreMetaData.)
Public propertySession
Gets the User Session that this manager instance was initiated from.
(Inherited from ITransactionalEntity.)
Public propertySettings
Public propertySiteUrl
Gets and sets the URL of the Site.
(Inherited from IContentStoreMetaData.)
Public propertySiteVersion
Gets the Version information of the Site Instance. It is the version of the site's assemblies in "bin" folder.
Public propertyTaxonomyAssociationsUpdated
Gets the time of the most recent taxonomy associations update.
(Inherited from IContentStoreMetaData.)
Public propertyVersionsLimit
Gets/sets the limit of Page Versions to be kept on each Page. Older Page Versions are automatically removed from Content Store if this settings is set.
Public propertyXmlDirectoryPath
Gets the full path of "App_Data/xml" folder of the Site Instance
Top
Methods
  NameDescription
Public methodAsset
Retrieves an Asset by its unique ID.
(Inherited from IAssetManager.)
Public methodAssetByPath
Retrieves an asset by its full path
(Inherited from IAssetManager.)
Public methodAssetFolder
Retrieves a asset folder by its unique ID.
(Inherited from IAssetManager.)
Public methodAssetFolderByPath
Retrieves an asset folder by its full path
(Inherited from IAssetManager.)
Public methodAssetFolders
Retrieves a collection of asset folders by their unique IDs.
(Inherited from IAssetManager.)
Public methodAssetItem
Retrieve an Asset or Asset Folder by its unique ID
(Inherited from IAssetManager.)
Public methodAssetItems
Retrieves a collection of assets by their unique IDs.
(Inherited from IAssetManager.)
Public methodAssetRegionRoots
Retrieves the Asset Items that have Locales set and not Inheriting Locale from their ancestors, in a paginated fashion.
(Inherited from IAssetManager.)
Public methodAssetRootFolders
Retrieves a collection of the Asset Folders at the top level of the asset tree.
(Inherited from IAssetManager.)
Public methodAssets(IEnumerableString)
Retrieves a collection of Assets by their unique IDs.
(Inherited from IAssetManager.)
Public methodCode exampleAssets(FuncIAsset, Boolean)

Retrieves a collection of Assets, pre-filtered through a function. e.g. a function to filter assets that have the jpg extension.

(Inherited from IAssetManager.)
Public methodAssets(Int32, Int32, Int32)
Retrieves the collection of all Assets, in a paginated fashion.
(Inherited from IAssetManager.)
Public methodAssetsAssignedToGroup
Retrieves a collection of Assets assigned to a specific Group, in a paginated fashion.
Public methodAssetsAssignedToUser
Retrieves a collection of Assets assigned to a specific User, in a paginated fashion.
Public methodAssetsBySchemas
Retrieves assets created using a specified list of asset schemas.
(Inherited from IAssetManager.)
Public methodAssetsCount
Gets the count of Asset on this Site Instance.
Public methodCacheAssetFolderPaths
Fetch and generate a dictionary of asset folder names and parent ids. Used during publish to allow asset.path() to pull from this cache.
Public methodCancelContentFreeze
Cancel a pending or ongoing Content Freeze State.
Public methodComponentReferences
Retrieves a collection of Pages that have component references to the specified Component, in a paginated fashion.
Public methodComponents
Retrieves the collection of all Component Pages, in a paginated fashion. Components don't have their own view/template. They are shared among Pages as reusable content.
Public methodComponentsMetaData
Public methodContentFreezeState
Retrieves the Content Freeze State of the Site Instance. This object is used to toggle content freeze on the Site Instance.
Public methodContentItem
Public methodContentItems
Public methodContentItemsByKeywords(String, Int32, Boolean, Boolean, Boolean, Boolean, Int32, Int32)
Retrieves a collection of Pages by keywords in the Pages' Name, and any text/xhtml field values, in a paginated fashion.
Public methodContentItemsByKeywords(String, String, String, Int32, Boolean, Boolean, Boolean, Boolean, Boolean, Int32, Int32)
Retrieves a collection of Pages by keywords in the Pages' Name, or specified text/xhtml field, with additional filtering of Root Name and field to search on, in a paginated fashion.
Public methodCopyAsset
Creates a copy of an Asset into a target Asset Folder.
(Inherited from IAssetManager.)
Public methodCopyAssetFolder
Creates a copy of an Asset Folder in a specified asset folder.
(Inherited from IAssetManager.)
Public methodCopyPage
Copies a Page together with its descendants, to the specified location.
Public methodCopyPageSingle
Copies a Page without its descendants, to the specified location.
Public methodCopyRegionRootAssetItem
Clones an Asset Item that is set as a region root.
(Inherited from IAssetManager.)
Public methodCopyRegionRootPage

Clones a Region Root, together with its descendants, to another location. The cloned Page will also be a Region Root, with the specified language setting applied.

This method will create a collection of Lingual Maps from the source Page and its descendants, to their corresponding clone Pages.

Public methodCreateAsset(IAssetFolder, IAssetSchema, String, Boolean, Stream, Boolean)
Creates a new Asset with specific Asset Schema.
(Inherited from IAssetManager.)
Public methodCreateAsset(IAssetFolder, IAssetSchema, String, Boolean, String, Boolean)
Creates a new Asset with specific Asset Schema with an external URL rather than an uploaded file.
(Inherited from IAssetManager.)
Public methodCreateAssetFolder
Creates a new Asset Folder in a specified parent folder.
(Inherited from IAssetManager.)
Public methodCreateAssetFolderLocaleCache
Public methodCreateAssetLocaleCache
Public methodCreateAssetRootFolder
Creates a new Asset Folder at the top level of the asset tree.
(Inherited from IAssetManager.)
Public methodCreatePage(IPageCreationRule, String, IPage, Boolean, String)
Creates a new Page based on a Page Creation Rule.
Public methodCreatePage(ISchema, String, IPage, Boolean, Boolean)
Creates a new Page with specific Schema.
Public methodCreatePageLocaleCache
Fetch and generate a dictionary of page info and parent ids. Used during publish to fetch inherited locales..
Public methodCrossLocaleCopyAssetItem (Inherited from IAssetManager.)
Public methodCrossLocaleCopyPage

Copies a Page with language settings, together with its descendants, to another location of a Page with language settings, when there is a Lingual Map established between the Region Roots of both Pages .

This method will create a collection of Lingual Maps from the source Page and its descendants, to their corresponding clone Pages.

Public methodCurrentVersionFilesCount
Calculates the current version files count across all Storage Tracks.
(Inherited from IAssetStorageManager.)
Public methodDeepCloneT, TManager
Duplicates an object instance, not including its unique ID.
(Inherited from ITransactionalEntity.)
Public methodEmptyAssetRecyleFolder
Permanently removes all Asset Items in the asset recycle folder.
(Inherited from IAssetManager.)
Public methodEmptyRecycleFolder
Permenantly delete all Pages under Recycle Folder.
Public methodFreezeContent
Plans a Content Freeze on the Site Instance.
Public methodGetEmailTemplate
Retrieves the email template for a specific User.
Public methodImagesAssignedToUser
Retrieves all image asset that are assigned to user
Public methodLinkReferences
Retrieves a collection of Pages that have link or link-set references to the specified Target Page , in a paginated fashion.
Public methodManageAssetItemT
Public methodCode exampleMetaDataReadT
Retrieves a meta data value via callback
Public methodMoveAsset
Moves an asset from its current location to a new target Asset Folder.
(Inherited from IAssetManager.)
Public methodMoveAssetFolder
Moves an Asset Folder together with its descendants to the specified target location.
(Inherited from IAssetManager.)
Public methodMovePage
Moves a Page together with its descendants, to the specified location.
Public methodPage
Retrieves a Page by its unique Id.
Public methodPages(IEnumerableString)
Retrieves a collection of Pages by their unique Ids.
Public methodPages(FuncIPage, Boolean)
Retrieves a collection of Pages, filtered by a callback method.
Public methodPages(Int32, Int32, Int32)
Retrieves the collection of all Pages, in a paginated fashion.
Public methodPagesAssignedToGroup
Retrieves a collection of Pages assigned to a specific Group, in a paginated fashion.
Public methodPagesAssignedToUser
Retrieves a collection of Pages assigned to a specific User, in a paginated fashion.
Public methodPagesAssignedToUserCount
Gets the count of Pages assigned to the specified User.
Public methodPagesByRootNames
Retrieves a collection of Pages by their Root Names.
Public methodPagesBySchemas
Retrieves a collection of Pages by Schemas.
Public methodPagesCount
Gets the count of Pages on this Site Instance.
Public methodPagesHistoryByKeywords(String, Int32, Boolean, Int32, Int32)
Retrieves a collection of Page Versions by keywords in the Pages' Name, and any text/xhtml field values, in a paginated fashion. This search covers the entire existing history of the Pages.
Public methodPagesHistoryByKeywords(String, String, String, Int32, Boolean, Boolean, Int32, Int32)
Retrieves a collection of Page Versions by keywords in the Pages' Name, or specified text/xhtml field, with additional filtering of Root Name and field to search on, in a paginated fashion.
Public methodPagesMetaDataByRootNames
Public methodPreviousVersionsFilesCount
Calculated the previous version files count across all Storage Tracks.
(Inherited from IAssetStorageManager.)
Public methodPreviousVersionsStorageSpace
Calculates the total storage space of previous versions across all Storage Tracks.
(Inherited from IAssetStorageManager.)
Public methodQuickWrite
Creates a temporary Write Session to quickly write something outside the current Session and transaction. This is a way to bypass the transaction and quickly put something into the content store.
(Inherited from ITransactionalEntity.)
Public methodRecycleAssetFolder
Retrieves the Recycle Folder of the AssetManager Instance.
(Inherited from IAssetManager.)
Public methodRecycleFolder
Retrieves the Recycle Folder of the Site Instance
Public methodRegionRoots
Retrieves the Pages that have Locales set and not Inheriting Locale from their ancestors, in a paginated fashion.
Public methodRelatedAssets
Retrieves assets that are related to a specified asset.
(Inherited from IAssetManager.)
Public methodRemoveAsset
Removes a single Asset by ID.
(Inherited from IAssetManager.)
Public methodRemoveAssetFolder
Removes a single Asset Folder by ID.
(Inherited from IAssetManager.)
Public methodRemovePage
Removes a single Page.
Public methodSerializeAssetTree
Public methodSerializeAssetTreeForIncrementalPublishing
Public methodSerializeForIncrementalPublishing(IPublishingTarget, IEnumerableString)
Public methodSerializeForIncrementalPublishing(IPublishingTarget, IEnumerableString, DictionaryString, IPage)
Incrementally produces XML serialization for a specific Publishing Target. This method generates the content of published reference.xml for Dynamic Site Server.
Public methodSerializeForPublishing(IPublishingTarget)
Public methodSerializeForPublishing(IPublishingTarget, DictionaryString, IPage)
Produces XML serialization for a specific Publishing Target. This method generates the content of published reference.xml for Dynamic Site Server.
Public methodSiteRoot
Retrieves the Root Page of the Site Instance.
Public methodStorageTrack
Retrieves the storage tracking information of an Asset type/schema
(Inherited from IAssetStorageManager.)
Public methodStorageTracks
Retrieves all storage tracks
(Inherited from IAssetStorageManager.)
Public methodStyleSheets
Retrieves the XSLT stylesheets collection in the "App_Data\xml\Stylesheets" Folder.
Public methodTotalStorageSpace
Calculates the total storage space across all Storage Tracks.
(Inherited from IAssetStorageManager.)
Public methodUnmanageAssetItemT
Public methodValidateStylesheets
Perform XML validation on the XSLT stylesheets.
Top
Events
  NameDescription
Public eventAfterAssetCopy
This event is fired after an Asset is copied.
(Inherited from IAssetManagerEvents.)
Public eventAfterAssetCrossLocaleCopy
This event is fired after an Asset is copied from one Region Root to another.
(Inherited from IAssetManagerEvents.)
Public eventAfterAssetDelete
This event is fired after an Asset is removed.
(Inherited from IAssetManagerEvents.)
Public eventAfterAssetMove
This event is fired after an Asset is moved.
(Inherited from IAssetManagerEvents.)
Public eventAfterAssetRegionRootCopy
This event is fired after a Region Root is copied.
(Inherited from IAssetManagerEvents.)
Public eventAfterCrossLocaleCopy
This event is fired after a Page is copied across Region Roots.
(Inherited from ISiteEvents.)
Public eventAfterEmptyAssetRecycleFolder
This event is fired before the asset recycle folder is emptied.
(Inherited from IAssetManagerEvents.)
Public eventAfterEmptyRecycleFolder
This event is fired after Recycle Folder is emptied.
(Inherited from ISiteEvents.)
Public eventAfterPageCopy
This event is fired after a Page is copied.
(Inherited from ISiteEvents.)
Public eventAfterPageDelete
This event is fired after a Page is removed.
(Inherited from ISiteEvents.)
Public eventAfterPageMove
This event is fired after a Page is moved.
(Inherited from ISiteEvents.)
Public eventAfterRegionRootCopy
This event is fired after a Region Root is copied.
(Inherited from ISiteEvents.)
Public eventAssetCreated
This event is fired when a new Asset is created.
(Inherited from IAssetManagerEvents.)
Public eventAssetFileUpdated
This method is invoked after an edit to an Asset File is saved.
(Inherited from IAssetManagerEvents.)
Public eventBeforeAssetCopy
This event is fired before an Asset to be copied.
(Inherited from IAssetManagerEvents.)
Public eventBeforeAssetCrossLocaleCopy
This event is fired before an Asset is copied from one Region Root to another.
(Inherited from IAssetManagerEvents.)
Public eventBeforeAssetDelete
This event is fired before an Asset is moved to Recycle Folder.
(Inherited from IAssetManagerEvents.)
Public eventBeforeAssetMove
This event is fired before an Asset is moved.
(Inherited from IAssetManagerEvents.)
Public eventBeforeAssetRegionRootCopy
This event is fired before a Region Root is copied.
(Inherited from IAssetManagerEvents.)
Public eventBeforeCrossLocaleCopy
This event is fired before a Page is copied across Region Roots.
(Inherited from ISiteEvents.)
Public eventBeforeEmptyAssetRecycleFolder
This event is fired before the asset recycle folder is emptied.
(Inherited from IAssetManagerEvents.)
Public eventBeforeEmptyRecycleFolder
This event is fired before emptying the Recycle Folder.
(Inherited from ISiteEvents.)
Public eventBeforePageCopy
This event is fired before a Page to be copied.
(Inherited from ISiteEvents.)
Public eventBeforePageDelete
This event is fired before a Page is moved to Recycle Folder.
(Inherited from ISiteEvents.)
Public eventBeforePageMove
This event is fired before a Page is moved.
(Inherited from ISiteEvents.)
Public eventBeforeRegionRootCopy
This event is fired before a Region Root is copied.
(Inherited from ISiteEvents.)
Public eventPageCreated
This event is fired when a new Page is created.
(Inherited from ISiteEvents.)
Top
Remarks

Like all manager objects, instances of this manager are retrieved from an IUserSession object and only work within that session.

C#
using (IUserSession session = store.OpenReadSession(currentUser))
{
       ISite site = session.Site;
       ...
}

Unlike the Site object before version 9.0, DO NOT store instance of this object in ASP.NET session.

Examples

Serialization of Site matches the serialization of reference.xml in previous-generation CMS content:

XML
<?xml version="1.0" encoding="utf-8"?>
<Site ID="x1" Name="Content Store" CheckedOut="false" SCID="Schema_Folder" SCV="1" AssignedUser="" AssignedGroup="" Schema="Folder" PageType="0" Locale="" LocaleInherited="true" Created="20140529T15:16:00" CreatedBy="ingeniux\ashley" Changed="20140625T09:53:15" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" SiteBaseUrl="" xmlns="x-schema:siteSchema.xml">
  <Page ID="x3" Name="Site" CheckedOut="false" SCID="Schema_Folder" SCV="1" AssignedUser="" AssignedGroup="" Schema="Folder" PageType="1" Locale="" LocaleInherited="true" Created="20140529T16:11:45" CreatedBy="ingeniux\ashley" Changed="20140625T09:53:15" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59">
    <Page ID="x2" Name="Home" CheckedOut="true" SCID="schemas/23" SCV="5" AssignedUser="ingeniux\awang" AssignedGroup="" Schema="Home" PageType="7" Locale="" LocaleInherited="true" Created="20140529T16:03:08" CreatedBy="ingeniux\ashley" Changed="20140710T09:42:16" LastChangedBy="ingeniux\awang" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59">
      <Page ID="x34" Name="Products" CheckedOut="false" SCID="schemas/28" SCV="6" AssignedUser="" AssignedGroup="" Schema="ProductFront" PageType="8" Locale="" LocaleInherited="true" Created="20140602T15:50:27" CreatedBy="ingeniux\ashley" Changed="20140619T16:52:37" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59">
        <Page ID="x43" Name="Cartella" CheckedOut="false" SCID="schemas/27" SCV="6" AssignedUser="" AssignedGroup="" Schema="ProductDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T14:46:10" CreatedBy="ingeniux\ashley" Changed="20140612T11:22:29" LastChangedBy="ingeniux\admin1" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
        <Page ID="x44" Name="CMS" CheckedOut="false" SCID="schemas/27" SCV="6" AssignedUser="" AssignedGroup="" Schema="ProductDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T15:02:29" CreatedBy="ingeniux\ashley" Changed="20140612T11:22:29" LastChangedBy="ingeniux\admin1" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
      </Page>
      <Page ID="x41" Name="Solutions" CheckedOut="false" SCID="schemas/31" SCV="3" AssignedUser="" AssignedGroup="" Schema="SolutionsFront" PageType="8" Locale="" LocaleInherited="true" Created="20140603T14:21:21" CreatedBy="ingeniux\ashley" Changed="20140603T16:14:55" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59">
        <Page ID="x47" Name="Mainstream" CheckedOut="false" SCID="schemas/30" SCV="3" AssignedUser="" AssignedGroup="" Schema="SolutionsDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T15:42:05" CreatedBy="ingeniux\ashley" Changed="20140603T16:14:55" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
        <Page ID="x48" Name="Information Technology" CheckedOut="false" SCID="schemas/30" SCV="3" AssignedUser="ingeniux\ashley" AssignedGroup="" Schema="SolutionsDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T15:44:43" CreatedBy="ingeniux\ashley" Changed="20140616T16:55:16" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
        <Page ID="x49" Name="Higher Education" CheckedOut="false" SCID="schemas/30" SCV="3" AssignedUser="" AssignedGroup="" Schema="SolutionsDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T15:44:44" CreatedBy="ingeniux\ashley" Changed="20140603T16:14:55" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
        <Page ID="x50" Name="E-commerce" CheckedOut="false" SCID="schemas/30" SCV="3" AssignedUser="" AssignedGroup="" Schema="SolutionsDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T15:44:46" CreatedBy="ingeniux\ashley" Changed="20140603T16:14:55" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
        <Page ID="x51" Name="Intranets and Extranets" CheckedOut="false" SCID="schemas/30" SCV="3" AssignedUser="" AssignedGroup="" Schema="SolutionsDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T15:44:48" CreatedBy="ingeniux\ashley" Changed="20140603T16:14:55" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
        <Page ID="x52" Name="Structured Pyramids" CheckedOut="false" SCID="schemas/30" SCV="3" AssignedUser="" AssignedGroup="" Schema="SolutionsDetail" PageType="8" Locale="" LocaleInherited="true" Created="20140603T15:44:53" CreatedBy="ingeniux\ashley" Changed="20140603T16:14:55" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
      </Page>
    </Page>
  </Page>
  <Page ID="RecycleBin" Name="Recycle Folder" CheckedOut="false" SCID="Schema_Folder" SCV="1" AssignedUser="" AssignedGroup="" Schema="Folder" PageType="1" Locale="" LocaleInherited="true" Created="20140529T15:16:01" CreatedBy="ingeniux\ashley" Changed="20140701T21:16:14" LastChangedBy="ingeniux\ashley" StartDate="00010101T00:00:00" EndDate="99991231T23:59:59" />
</Site>
See Also