Content Studio Web Content Management System
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Xml, a simple one tag document with the attributes in use and their values. The content of the xml is dependent on what type of directive to get and what types of directives that does not have default values.
READ / READ CONTAINER permission on the document / container is required.
This method is new in Content Studio 5.3.
[This is preliminary documentation and is subject to change.]
Returns the all ASP.NET directive types for the site root, a unit, category or document.
Namespace: ContentStudio.Document
Assembly: CSServer5 (in CSServer5.dll) Version: 5.7.5016.0 (5.7.5016.0)
Syntax
public string GetAllDirectives( ConnectionId connectionId, SessionId sessionId, int objectId, CSFileObjectTypes objectType )
Parameters
- connectionId
- Type: ContentStudioConnectionId
A value that identifies the web site - sessionId
- Type: ContentStudio.SecuritySessionId
A value that identifies the user's session. This value usually originates from a call to OpenSession(ConnectionId). - objectId
- Type: SystemInt32
The object to get directives for. - objectType
- Type: ContentStudio.DocumentCSFileObjectTypes
The type of Content Studio object referenced by the objectId parameter
Return Value
Type: StringXml, a simple one tag document with the attributes in use and their values. The content of the xml is dependent on what type of directive to get and what types of directives that does not have default values.
<directives> <Page Language="VB" Strict="true" /> <OutputCache Duration="100" VaryByParam="di" Location="Server" /> </directives>
The element names returned are the directive name and the attributes defines the attributes of the directive. The following directives will be returned.
Directive | Description | Read more |
---|---|---|
Assembly | Links an assembly to the current page or user control declaratively | http://msdn.microsoft.com/en-us/library/d864zc1k.aspx |
Control | Defines control-specific attributes used by the ASP.NET page parser and compiler and can be included only in .ascx files (user controls). | http://msdn.microsoft.com/en-us/library/d19c0t4b.aspx |
Import | Imports a namespace into a page or user control explicitly. | http://msdn.microsoft.com/en-us/library/eb44kack.aspx |
Master | Identifies a page as a master page and defines attributes used by the ASP.NET page parser and compiler and can be included only in .master files | http://msdn.microsoft.com/en-us/library/ms228176.aspx |
OutputCache | Controls the output caching policies of a page or user control declaratively | http://msdn.microsoft.com/en-us/library/hdxfb6cy.aspx |
Page | Defines page-specific attributes used by the ASP.NET page parser and compiler and can be included only in .aspx files | http://msdn.microsoft.com/en-us/library/ydy4x04a.aspx |
Reference | Links a page, user control, or COM control to the current page or user control declaratively | http://msdn.microsoft.com/en-us/library/w70c655a.aspx |
Register | Associates aliases with namespaces and classes, which allow user controls and custom server controls to be rendered when included in a requested page or user control | http://msdn.microsoft.com/en-us/library/c76dd5k1.aspx |
Exceptions
Exception | Condition |
---|---|
CSException | A business rule was violated in the underlying Content Studio database
|
CSInvalidSessionException | The session is invalid (version 5.4 and later) |
CSPermissionDeniedException | Permission denied (version 5.4 and later) |
CSInvalidParameterException | Invalid parameter value (version 5.4 and later) |
CSDocumentNotFoundException | The document is missing (version 5.4 and later) |
SqlException | An error occurred when executing the command against the Content Studio database |
Content Studio permissions
Remarks
Note |
---|
The behavior of this method changed in Content Studio 5.4. Not all containers and documents can have directives. For more information GetDirectivesApplicable |
See Also