Skip to main content

Config.CPF

abstract class Config.CPF extends Config.CommonMethods

Method Inventory

Parameters

parameter DOMAIN = %Utility;

Methods

classmethod Activate(Obj As %Library.ObjectHandle = "", Flags As %Library.Integer = 0) as %Status
Read and activate the current CPF file.
This method will read the currently active CPF file if it has been updated on disk but not yet read in. After the current settings have been read in, they are activated.
classmethod CPFFileNeedsActivation(ByRef Msg As %String) as %Boolean
Returns 0/1 if the CPF file has been modified but not activated.
If it has been modified by an editor, an activation must occur before any of the Config methods can be called to activate any additional changes.
classmethod Convert(ByRef CPFFile As %String = "", Flags As %Integer = 0) as %Status
Convert a CPF file to the current version.
This method will take a CPF file and convert it to the current version. Note that it will not do any validation on the file, it will simply convert it.
Parameters:
CPFFile - CPF file to convert.
Flags - Internal use only, do not pass.
classmethod PendingRestart(ByRef Reasons As %String) as %Boolean
Determines if a restart of the system is required in order to activate modified CPF parameters.
Return Values:
0 - Restart is not required
1 - Restart is required
Reasons - If a restart is required, an array of reasons why in the following format.
Reasons=1
Reasons(1,"New")=New value
Reasons(1,"Old")=Old Value
Reasons(1,"Property")=Property name
Reasons(1,"Section")=Section name
Reasons(1)="Restart required because section [xxx], property yyy modified, new value:zzz, old value:zzz"
Note that if the CPF file has been modified, but not yet activated, this method will return 1, and the following array:
Reasons=1
Reasons(1)="Restart or reactivation required because the CPF file xxxx has been modified, but not activated"
Reasons(1,"New")=""
Reasons(1,"Old")=""
Reasons(1,"Property")=""
Reasons(1,"Section")=""
classmethod Validate(ByRef CPFFile As %String = "", Flags As %Integer = $$$ErrorTextToScreen, ByRef ErrorText As %String) as %Status
Validate a CPFFile.
CPFFile - CPF file to validate.
Flags - Options for error text. Macros defined in %syConfig.inc.
Bit $$$ErrorTextToScreen - Write error text to terminal
Bit $$$ErrorTextToConsole - Write error text to cconsole.log
Bit $$$ErrorTextToArray - Return error text in ErrorText array
classmethod Write(ByRef CPFFile As %String = "")
Write to the CPF file from the config object.
Parameters:
CPFFile - CPF file to write, default is currently active one.

Inherited Members

Inherited Methods

FeedbackOpens in a new tab