Class NSConfigurationAgent
User interface configuration* XML and other elements such as inter-client URLs.
Syntax
Examples
NSConfigurationAgent agent;
agent.callMethod(arg1, arg2);
Constructors
NSConfigurationAgent()
Initializes a new instance of the NSConfigurationAgent class.
Declaration
NSConfigurationAgent
Examples
NSConfigurationAgent agent;
agent.callMethod(arg1, arg2);
Methods
ClearConfigurationCache(String,String,Bool)
Configuration XML may be expensive to build and parse, and are therefore cached to the database.
Caching is per application/instance/associate, and can be turned off through the config file. If caching is on, and the configuration is changed, it is necessary to clear the cached configurations from the database, through this call.Declaration
Void ClearConfigurationCache(String application, String instance, Bool forAllAssociates)
Parameters
Type | Name | Description |
---|---|---|
String | application | |
String | instance | |
Bool | forAllAssociates |
Returns
Type | Description |
---|---|
Void |
Remarks
Changes to the externalapplication table require cache invalidation. SoAdmin will do so automatically.
Examples
NSConfigurationAgent agent;
String application;
String instance;
Bool forAllAssociates;
agent.ClearConfigurationCache(application, instance, forAllAssociates);
CreateDefaultDiaryViewEntity()
Sets default values into a new NSDiaryViewEntity.
Declaration
NSDiaryViewEntity CreateDefaultDiaryViewEntity()
Returns
Type | Description |
---|---|
NSDiaryViewEntity | New entity with default values. |
Remarks
NetServer calculates default values (for example, Country) on the entity, which is required when creating/storing a new instance
Examples
NSConfigurationAgent agent;
NSDiaryViewEntity thing = agent.CreateDefaultDiaryViewEntity();
thing = agent.SaveDiaryViewEntity(thing);
CreateDefaultSystemEventEntity()
Sets default values into a new NSSystemEventEntity.
Declaration
NSSystemEventEntity CreateDefaultSystemEventEntity()
Returns
Type | Description |
---|---|
NSSystemEventEntity | New entity with default values. |
Remarks
NetServer calculates default values (for example, Country) on the entity, which is required when creating/storing a new instance.
Examples
NSConfigurationAgent agent;
NSSystemEventEntity thing = agent.CreateDefaultSystemEventEntity();
thing = agent.SaveSystemEventEntity(thing);
DeleteDiaryViewEntity(Integer)
Deletes the NSDiaryViewEntity
Declaration
Void DeleteDiaryViewEntity(Integer diaryViewEntity)
Parameters
Type | Name | Description |
---|---|---|
Integer | diaryViewEntity |
Returns
Type | Description |
---|---|
Void |
Examples
NSConfigurationAgent agent;
agent.DeleteDiaryViewEntity(123);
DeleteSystemEventEntity(Integer)
Deletes the NSSystemEventEntity
Declaration
Void DeleteSystemEventEntity(Integer systemEventEntity)
Parameters
Type | Name | Description |
---|---|---|
Integer | systemEventEntity | The identity of the DiaryViewEntity. |
Returns
Type | Description |
---|---|
Void |
Examples
NSConfigurationAgent agent;
agent.DeleteSystemEventEntity(123);
DeleteWindowPosSize(Integer)
Deletes a window and dialog position and size setting.
Declaration
Void DeleteWindowPosSize(Integer windowPosSizeId)
Parameters
Type | Name | Description |
---|---|---|
Integer | windowPosSizeId | ID of the window and dialog position and size settings item. |
Returns
Type | Description |
---|---|
Void |
Examples
NSConfigurationAgent agent;
agent.callMethod(arg1, arg2);
ExistsSystemEvent(String)
User interface configuration* XML and other elements such as inter-client URLs.
Declaration
Bool ExistsSystemEvent(String key)
Parameters
Type | Name | Description |
---|---|---|
String | key | The key to match on. |
Returns
Type | Description |
---|---|
Bool | Is there a system event with the given key? |
Examples
NSConfigurationAgent agent;
String key;
Bool res = agent.ExistsSystemEvent(key);
GetAnyConfiguration(String,String,String,String)
Gets one defined configuration fragment, with full reference resolution and parsing applied.
Declaration
String GetAnyConfiguration(String application, String instance, String item, String type)
Parameters
Type | Name | Description |
---|---|---|
String | application | The application name, for instance Six.Web |
String | instance | The instance name, for instance Main |
String | item | The configuration item name (first component of file name) |
String | type | The configuration item type (second component of file name). |
Returns
Type | Description |
---|---|
String | A configuration fragment, with full reference resolution and parsing applied. |
Remarks
This is essentially the same service as the GetPageConfiguration, except that this service is not locked to objects of type Page.
Examples
NSConfigurationAgent agent;
String application;
String instance;
String item;
String type;
String res = agent.GetAnyConfiguration(application, instance, item, type);
GetApplicationConfiguration(String,String)
Returns the application configuration.
Declaration
String GetApplicationConfiguration(String application, String instance)
Parameters
Type | Name | Description |
---|---|---|
String | application | The application name, for instance 'SixWeb' |
String | instance | The instance name for the application, like 'MainInstance' |
Returns
Type | Description |
---|---|
String | XML structure containing the application configuration. A list of pages, with information about the name, main panel and preference mappings of each page. |
Examples
NSConfigurationAgent agent;
String application;
String instance;
String res = agent.GetApplicationConfiguration(application, instance);
GetCRMUrl(String,String,Bool)
Returns a valid URL based in the soprotocol provided
Declaration
String GetCRMUrl(String soProtocol, String currents, Bool frameless)
Parameters
Type | Name | Description |
---|---|---|
String | soProtocol | |
String | currents | |
Bool | frameless |
Returns
Type | Description |
---|---|
String | URl. |
Examples
NSConfigurationAgent agent;
String soProtocol;
String currents;
Bool frameless;
String res = agent.GetCRMUrl(soProtocol, currents, frameless);
GetCSAuthUrl(String,String,String,String)
Generates a URL to the emarketing module
Declaration
String GetCSAuthUrl(String language, String programName, String action, String extraParameters)
Parameters
Type | Name | Description |
---|---|---|
String | language | By setting this parameter, you can change the CS language for the current user. |
String | programName | In this parameter you must specify which CS program you want to create an URL for. Valid examples are ticket, rms, spm etc. |
String | action | Here you can optionally specify the action for the current program. This will enable you to go to a specific screen. |
String | extraParameters | If an action is specified, you can specify extra parameters here. This can be used to set specific behaviour for the chosen screen/action. If an empty action is supplied, this parameter will be ignored. |
Returns
Type | Description |
---|---|
String | A valid Service URL composed of the give parameters. |
Examples
NSConfigurationAgent agent;
String language;
String programName;
String action;
String extraParameters;
String res = agent.GetCSAuthUrl(language, programName, action, extraParameters);
GetCsCgiUrlInternal()
Gets the host name for Service
Declaration
String GetCsCgiUrlInternal()
Returns
Type | Description |
---|---|
String | The host name for where Service is installed. |
Examples
NSConfigurationAgent agent;
String res = agent.GetCsCgiUrlInternal();
GetCsProgramUrl(String,String,String,String)
Converts a module name into a Service URL.
Declaration
String GetCsProgramUrl(String language, String programName, String action, String extraParameters)
Parameters
Type | Name | Description |
---|---|---|
String | language | By setting this parameter, you can change the CS language for the current user. |
String | programName | In this parameter you must specify which CS program you want to create an URL for. Valid examples are ticket, rms, spm etc. |
String | action | Here you can optionally specify the action for the current program. This will enable you to go to a specific screen. |
String | extraParameters | If an action is specified, you can specify extra parameters here. This can be used to set specific behaviour for the chosen screen/action. If an empty action is supplied, this parameter will be ignored. |
Returns
Type | Description |
---|---|
String | A valid Service URL composed of the give parameters. |
Examples
NSConfigurationAgent agent;
String language;
String programName;
String action;
String extraParameters;
String res = agent.GetCsProgramUrl(language, programName, action, extraParameters);
GetCSRegistryValue(Integer)
Gets a value from the Registry table.
Declaration
String GetCSRegistryValue(Integer entry)
Parameters
Type | Name | Description |
---|---|---|
Integer | entry | The Registry entry to get. |
Returns
Type | Description |
---|---|
String | The value of the specified Registry entry. |
Examples
NSConfigurationAgent agent;
Integer entry;
String res = agent.GetCSRegistryValue(entry);
GetCSWwwFolder()
Gets the www folder for Service
Declaration
String GetCSWwwFolder()
Returns
Type | Description |
---|---|
String | The www folder for Service. |
Examples
NSConfigurationAgent agent;
String res = agent.GetCSWwwFolder();
GetCustomerUrl()
Gets the URL for the external access to the customer center
Declaration
String GetCustomerUrl()
Returns
Type | Description |
---|---|
String | The URL to the customer center, without any actions. |
Examples
NSConfigurationAgent agent;
String res = agent.GetCustomerUrl();
GetDiaryViewEntity(Integer)
Gets an NSDiaryViewEntity object.
Declaration
NSDiaryViewEntity GetDiaryViewEntity(Integer diaryViewEntityId)
Parameters
Type | Name | Description |
---|---|---|
Integer | diaryViewEntityId | The identifier of the DiaryViewEntity object. |
Returns
Type | Description |
---|---|
NSDiaryViewEntity |
Examples
NSConfigurationAgent agent;
NSDiaryViewEntity thing = agent.GetDiaryViewEntity(123);
GetEmailNumberOfDays()
User interface configuration* XML and other elements such as inter-client URLs.
Declaration
Integer GetEmailNumberOfDays()
Returns
Type | Description |
---|---|
Integer | Number of days in the past for which we are fetching email. |
Examples
NSConfigurationAgent agent;
Integer res = agent.GetEmailNumberOfDays();
GetEMarketingUrl(String)
User interface configuration* XML and other elements such as inter-client URLs.
Declaration
String GetEMarketingUrl(String language)
Parameters
Type | Name | Description |
---|---|---|
String | language |
Returns
Type | Description |
---|---|
String | URl. |
Examples
NSConfigurationAgent agent;
agent.callMethod(arg1, arg2);
GetFilterList(String,String)
Gets the list of filters to be used for processing the configuration data for this application.
Declaration
String GetFilterList(String application, String instance)
Parameters
Type | Name | Description |
---|---|---|
String | application | The application name, for instance 'SixWeb' |
String | instance | The instance name for the application, like 'MainInstance'. |
Returns
Type | Description |
---|---|
String | XML representing the list of filters and any configuration data they may need. |
Examples
NSConfigurationAgent agent;
String application;
String instance;
String res = agent.GetFilterList(application, instance);
GetHelpDispatcherUrl()
Gets the GetHelpDispatcherUrl used by the help system.
Declaration
String GetHelpDispatcherUrl()
Returns
Type | Description |
---|---|
String | URL to be used by the help system. |
Examples
NSConfigurationAgent agent;
String res = agent.GetHelpDispatcherUrl();
GetMyWindowPosSizes()
Gets the window and dialog position and size settings belonging to the currently logged-on user.
Declaration
NSWindowPosSize[] GetMyWindowPosSizes()
Returns
Type | Description |
---|---|
NSWindowPosSize[] | Array of window and dialog position and size settings. |
Examples
NSConfigurationAgent agent;
NSWindowPosSize[] res = agent.GetMyWindowPosSizes();
GetObjectMapping(String,String)
Gets the object mappings (what code objects should be instantiated to handle the entities of the client configuration?)
Declaration
String GetObjectMapping(String application, String instance)
Parameters
Type | Name | Description |
---|---|---|
String | application | The application name, for instance 'SixWeb' |
String | instance | The instance name for the application, like 'MainInstance'. |
Returns
Type | Description |
---|---|
String | XML containing the object mappings, including assembly and class names. |
Examples
NSConfigurationAgent agent;
String application;
String instance;
String res = agent.GetObjectMapping(application, instance);
GetPageConfiguration(String,String,String)
Gets the configuration for one whole web page, including all its panels etc.
Declaration
String GetPageConfiguration(String application, String instance, String page)
Parameters
Type | Name | Description |
---|---|---|
String | application | The application name, for instance SixWeb |
String | instance | The instance name for the application, like 'MainInstance' |
String | page | Page name, must correspond to one of the pages in the Application Configuration. |
Returns
Type | Description |
---|---|
String | XML containing the configuration for the given page, from the page down to the control level. |
Remarks
Totally asynchronous items like menus are not included, but all references are resolved and all special processing is applied.
Examples
NSConfigurationAgent agent;
String application;
String instance;
String page;
String res = agent.GetPageConfiguration(application, instance, page);
GetRefreshedPageConfiguration(String,String,String)
Gets the configuration for one whole web page, including all its panels etc.
Declaration
String GetRefreshedPageConfiguration(String application, String instance, String page)
Parameters
Type | Name | Description |
---|---|---|
String | application | The application name, for instance SixWeb |
String | instance | The instance name for the application, like 'MainInstance' |
String | page | Page name, must correspond to one of the pages in the Application Configuration. |
Returns
Type | Description |
---|---|
String | XML containing the configuration for the given page, from the page down to the control level. |
Remarks
Totally asynchronous items like menus are not included, but all references are resolved and all special processing is applied. Does not use cache for fetching, but updates the cache with refreshed configuration.
Examples
NSConfigurationAgent agent;
String application;
String instance;
String page;
String res = agent.GetRefreshedPageConfiguration(application, instance, page);
GetSystemEventEntity(Integer)
Gets an NSSystemEventEntity object.
Declaration
NSSystemEventEntity GetSystemEventEntity(Integer systemEventEntityId)
Parameters
Type | Name | Description |
---|---|---|
Integer | systemEventEntityId | The identifier of the SystemEventEntity object. |
Returns
Type | Description |
---|---|
NSSystemEventEntity |
Examples
NSConfigurationAgent agent;
NSSystemEventEntity thing = agent.GetSystemEventEntity(123);
GetWindowPosSize(Integer)
Gets an NSWindowPosSize object.
Declaration
NSWindowPosSize GetWindowPosSize(Integer windowPosSizeId)
Parameters
Type | Name | Description |
---|---|---|
Integer | windowPosSizeId | The identifier of the WindowPosSize object. |
Returns
Type | Description |
---|---|
NSWindowPosSize |
Examples
NSConfigurationAgent agent;
NSWindowPosSize thing = agent.GetWindowPosSize(123);
GetWindowPosSizeList(Integer[])
Retrieves a list of NSWindowPosSize objects.
Declaration
NSWindowPosSize[] GetWindowPosSizeList(Integer[])
Parameters
Type | Name | Description |
---|---|---|
Integer[] | windowPosSizeIds | The IDs of the NSWindowPosSize objects to get. |
Returns
Type | Description |
---|---|
NSWindowPosSize[] | Array of window and dialog position and size settings. |
Examples
Integer[] ids;
NSConfigurationAgent agent;
agent.GetWindowPosSizeList(ids);
GetWindowPosSizesOnAssociateId(Integer)
Gets the window and dialog position and size settings belonging to the specified associate
Declaration
NSWindowPosSize[] GetWindowPosSizesOnAssociateId(Integer associateId)
Parameters
Type | Name | Description |
---|---|---|
Integer | associateId | Associate ID of the Associate/Person owning these window settings. |
Returns
Type | Description |
---|---|
NSWindowPosSize[] | Array of window and dialog position and size settings. |
Examples
NSConfigurationAgent agent;
Integer associateId;
NSWindowPosSize[] res = agent.GetWindowPosSizesOnAssociateId(associateId);
GetWindowPosSizesOnPersonId(Integer)
Gets the window and dialog position and size settings belonging to the specified person
Declaration
NSWindowPosSize[] GetWindowPosSizesOnPersonId(Integer personId)
Parameters
Type | Name | Description |
---|---|---|
Integer | personId | Person ID of the associate owning these window settings. |
Returns
Type | Description |
---|---|
NSWindowPosSize[] | Array of window and dialog position and size settings. |
Examples
NSConfigurationAgent agent;
Integer personId;
NSWindowPosSize[] res = agent.GetWindowPosSizesOnPersonId(personId);
GetWwwUrl(String)
Gets the default URL used for the logo, from the [NetServices] PageUrl preferencec, with tags substituted.
Declaration
String GetWwwUrl(String client)
Parameters
Type | Name | Description |
---|---|---|
String | client | The name for the client application, like 'CS' or 'SM.web', used for the clie variable. |
Returns
Type | Description |
---|---|
String | URL to be used when clicking the logo. |
Examples
NSConfigurationAgent agent;
String client;
String res = agent.GetWwwUrl(client);
GetWwwUrlForSMWeb()
Returns the URL used for the logo by the SM.web client. Uses urldispatch.aspx.
Declaration
String GetWwwUrlForSMWeb()
Returns
Type | Description |
---|---|
String | Link to urldispatch.aspx tagged with [SOSITEURL] |
Examples
NSConfigurationAgent agent;
String res = agent.GetWwwUrlForSMWeb();
SaveDiaryViewEntity(NSDiaryViewEntity)
Updates the existing NSDiaryViewEntity or creates a new NSDiaryViewEntity if the ID parameter is 0.
Declaration
NSDiaryViewEntity SaveDiaryViewEntity(NSDiaryViewEntity diaryViewEntity)
Parameters
Type | Name | Description |
---|---|---|
NSDiaryViewEntity | diaryViewEntity | The DiaryViewEntity to save. |
Returns
Type | Description |
---|---|
NSDiaryViewEntity | New or updated DiaryViewEntity. |
Examples
NSConfiguration agent;
NSDiaryViewEntity thing = agent.CreateDefaultDiaryViewEntity();
thing = agent.SaveDiaryViewEntity(thing);
SaveSystemEventEntity(NSSystemEventEntity)
Updates the existing NSSystemEventEntity or creates a new NSSystemEventEntity if the id parameter is 0
Declaration
NSSystemEventEntity SaveSystemEventEntity(NSSystemEventEntity systemEventEntity)
Parameters
Type | Name | Description |
---|---|---|
NSSystemEventEntity | systemEventEntity | Entity to save. |
Returns
Type | Description |
---|---|
NSSystemEventEntity | New or updated SystemEventEntity. |
Examples
NSConfiguration agent;
NSSystemEventEntity thing = agent.CreateDefaultSystemEventEntity();
thing = agent.SaveSystemEventEntity(thing);
SaveWindowPosSize(NSWindowPosSize)
Saves a window and dialog position and size setting.
Declaration
NSWindowPosSize SaveWindowPosSize(NSWindowPosSize windowPosSize)
Parameters
Type | Name | Description |
---|---|---|
NSWindowPosSize | windowPosSize | The item that is saved. |
Returns
Type | Description |
---|---|
NSWindowPosSize | The saved item. |
Examples
NSConfigurationAgent agent;
NSWindowPosSize windowPosSize;
NSWindowPosSize res = agent.SaveWindowPosSize(windowPosSize);
SaveWindowPosSizes(NSWindowPosSize[])
Saves a set of window and dialog position and size settings.
Declaration
NSWindowPosSize[] SaveWindowPosSizes(NSWindowPosSize[] windowPosSizes)
Parameters
Type | Name | Description |
---|---|---|
NSWindowPosSize[] | windowPosSizes | Items to save. |
Returns
Type | Description |
---|---|
NSWindowPosSize[] | The saved items. |
Examples
NSConfigurationAgent agent;
NSWindowPosSize[] windowPosSizes;
NSWindowPosSize[] res = agent.SaveWindowPosSizes(windowPosSizes);