SmartAPI
Open Source .NET RQL library for RedDot CMS / OpenText WSM Management Server
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties Pages
erminas.SmartAPI.CMS.ISession Interface Reference
+ Inheritance diagram for erminas.SmartAPI.CMS.ISession:
+ Collaboration diagram for erminas.SmartAPI.CMS.ISession:

Public Member Functions

XmlDocument ExecuteRQL (string query, RQL.IODataFormat format)
 
XmlDocument ExecuteRQL (string query)
 Execute an RQL query on the server and get its results.
 
XmlDocument ExecuteRQLInProjectContext (string query, Guid projectGuid)
 Select a project and execute an RQL query in its context.
 
XmlDocument ExecuteRQLInProjectContextAndEmbeddedInProjectElement (string query, Guid projectGuid)
 
string ExecuteRQLRaw (string query, RQL.IODataFormat ioDataFormat)
 Execute an RQL statement. The format of the query (usage of session key/logon guid can be chosen).
 
string GetTextContent (Guid projectGuid, ILanguageVariant lang, Guid elementGuid, string typeString)
 Get the text content of a text element. This method exists, because it needs a different RQL element layout than all other queries.
 
void SelectProject (Guid projectGuid)
 Select a project. Subsequent queries will be executed in the context of this project.
 
void SelectProject (IProject project)
 Select a project as active project (RQL queries will be evaluated in the context of this project).
 
void SendMailFromCurrentUserAccount (EMail mail)
 
void SendMailFromSystemAccount (EMail mail)
 
Guid SetTextContent (Guid projectGuid, ILanguageVariant languageVariant, Guid textElementGuid, string typeString, string content)
 This is only meant for internal use! It probably won't work as you expect it, so just ignore it ;) Set the text content of a (content class) text element. This method exists, because it needs a different RQL element layout than all other queries.
 
void WaitForAsyncProcess (TimeSpan maxWait, Predicate< IAsynchronousProcess > processPredicate)
 Waits for an asynchronous process to finish. This is done by waiting for the process to spawn (or have it available on start) and then waiting for the process to disappear from the process list. The async processes get checked every second, for other retry periods, use WaitForAsyncProcess(System.TimeSpan,System.TimeSpan,System.Predicate{ServerManagement.ServerManager.AsynchronousProcess}) instead.
 
void WaitForAsyncProcess (TimeSpan maxWait, TimeSpan retry, Predicate< IAsynchronousProcess > processPredicate)
 Waits for an asynchronous process to finish. This is done by waiting for the process to spawn (or have it available on start) and then waiting for the process to disappear from the process list.
 

Properties

IUser CurrentUser [get]
 
IndexedCachedList< string,
IDialogLocale
DialogLocales [get]
 
IIndexedCachedList< int,
ISystemLocale
Locales [get]
 All locales, indexed by LCID. The list is cached by default.
 
Guid LogonGuid [get]
 
IProject SelectedProject [get, set]
 Get/Set the currently selected project.
 
ServerLogin ServerLogin [get]
 Login information of the session
 
IServerManager ServerManager [get]
 
Version ServerVersion [get]
 
string SessionKey [get]
 
ISystemLocale StandardLocale [get]
 

Detailed Description

Definition at line 93 of file ISession.cs.

Member Function Documentation

XmlDocument erminas.SmartAPI.CMS.ISession.ExecuteRQL ( string  query,
RQL.IODataFormat  format 
)
XmlDocument erminas.SmartAPI.CMS.ISession.ExecuteRQL ( string  query)

Execute an RQL query on the server and get its results.

Parameters
queryThe RQL query string without the IODATA element
Returns
A XmlDocument containing the answer of the RedDot server
XmlDocument erminas.SmartAPI.CMS.ISession.ExecuteRQLInProjectContext ( string  query,
Guid  projectGuid 
)

Select a project and execute an RQL query in its context.

Parameters
queryThe query string without the IODATA element
projectGuidGuid of the project
Returns
An XmlDocument containing the answer of the RedDot server
XmlDocument erminas.SmartAPI.CMS.ISession.ExecuteRQLInProjectContextAndEmbeddedInProjectElement ( string  query,
Guid  projectGuid 
)
string erminas.SmartAPI.CMS.ISession.ExecuteRQLRaw ( string  query,
RQL.IODataFormat  ioDataFormat 
)

Execute an RQL statement. The format of the query (usage of session key/logon guid can be chosen).

Parameters
queryStatement to execute
RQL.IODataFormatDefines the format of the iodata element / placement of sessionkey of the RQL query
Returns
String returned from the server
string erminas.SmartAPI.CMS.ISession.GetTextContent ( Guid  projectGuid,
ILanguageVariant  lang,
Guid  elementGuid,
string  typeString 
)

Get the text content of a text element. This method exists, because it needs a different RQL element layout than all other queries.

Parameters
projectGuidGuid of the project containing the element
langLanguage variant to get the text from
elementGuidGuid of the text element
typeStringtexttype value
Returns
text content of the element
void erminas.SmartAPI.CMS.ISession.SelectProject ( Guid  projectGuid)

Select a project. Subsequent queries will be executed in the context of this project.

Parameters
projectGuidGuid of the project to select
void erminas.SmartAPI.CMS.ISession.SelectProject ( IProject  project)

Select a project as active project (RQL queries will be evaluated in the context of this project).

Parameters
projectProject to select
Exceptions
ExceptionThrown, if the project could not get selected.
void erminas.SmartAPI.CMS.ISession.SendMailFromCurrentUserAccount ( EMail  mail)
void erminas.SmartAPI.CMS.ISession.SendMailFromSystemAccount ( EMail  mail)
Guid erminas.SmartAPI.CMS.ISession.SetTextContent ( Guid  projectGuid,
ILanguageVariant  languageVariant,
Guid  textElementGuid,
string  typeString,
string  content 
)

This is only meant for internal use! It probably won't work as you expect it, so just ignore it ;) Set the text content of a (content class) text element. This method exists, because it needs a different RQL element layout than all other queries.

Parameters
projectGuidGuid of the project containing the element
languageVariantLanguage variant for setting the text in
textElementGuidGuid of the text element
typeStringtexttype value
contentnew value
Returns
Guid of the text element
void erminas.SmartAPI.CMS.ISession.WaitForAsyncProcess ( TimeSpan  maxWait,
Predicate< IAsynchronousProcess processPredicate 
)

Waits for an asynchronous process to finish. This is done by waiting for the process to spawn (or have it available on start) and then waiting for the process to disappear from the process list. The async processes get checked every second, for other retry periods, use WaitForAsyncProcess(System.TimeSpan,System.TimeSpan,System.Predicate{ServerManagement.ServerManager.AsynchronousProcess}) instead.

Parameters
maxWaitMaximum time span to wait for the process to complete
processPredicateGets checked for every process in the list to determine the process to wait for (must return true for it and only for it)
void erminas.SmartAPI.CMS.ISession.WaitForAsyncProcess ( TimeSpan  maxWait,
TimeSpan  retry,
Predicate< IAsynchronousProcess processPredicate 
)

Waits for an asynchronous process to finish. This is done by waiting for the process to spawn (or have it available on start) and then waiting for the process to disappear from the process list.

Parameters
maxWaitMaximum time span to wait for the process to complete
retryDetermines how often the async processes should be checked
processPredicateGets checked for every process in the list to determine the process to wait for (must return true for it and only for it)

Property Documentation

IUser erminas.SmartAPI.CMS.ISession.CurrentUser
get

Definition at line 95 of file ISession.cs.

IndexedCachedList<string, IDialogLocale> erminas.SmartAPI.CMS.ISession.DialogLocales
get

Definition at line 96 of file ISession.cs.

IIndexedCachedList<int, ISystemLocale> erminas.SmartAPI.CMS.ISession.Locales
get

All locales, indexed by LCID. The list is cached by default.

Definition at line 138 of file ISession.cs.

Guid erminas.SmartAPI.CMS.ISession.LogonGuid
get

Definition at line 140 of file ISession.cs.

IProject erminas.SmartAPI.CMS.ISession.SelectedProject
getset

Get/Set the currently selected project.

Definition at line 158 of file ISession.cs.

ServerLogin erminas.SmartAPI.CMS.ISession.ServerLogin
get

Login information of the session

Definition at line 166 of file ISession.cs.

IServerManager erminas.SmartAPI.CMS.ISession.ServerManager
get

Definition at line 168 of file ISession.cs.

Version erminas.SmartAPI.CMS.ISession.ServerVersion
get

Definition at line 170 of file ISession.cs.

string erminas.SmartAPI.CMS.ISession.SessionKey
get

Definition at line 172 of file ISession.cs.

ISystemLocale erminas.SmartAPI.CMS.ISession.StandardLocale
get

Definition at line 188 of file ISession.cs.


The documentation for this interface was generated from the following file: