unRcpFunctions_class.ctl File Reference

Functions

public void _unRecipeFunctions_getRecipeClassDeviceMapping (dyn_mixed rcpClassObject, mapping &rcpDeviceDpes)
public bool _unRecipeFunctions_isRecipeClassDefinitionValid (string sClassDp, dyn_string &exceptionInfo)
public dyn_string _unRecipeFunctions_getRcpClassDeviceOrder (string sRcpClassDp, dyn_string dsDevices, dyn_string &exceptionInfo)
public void _unRecipeFunctions_getRecipeClassDataFromInstance (string sRcpInstanceDp, string &sRcpClassName, string &sRcpClassDp, string &sPcoLink)
public void _unRecipeFunctions_dpConnectRcpClassElementsCB (string sRcpClassElementsDp, dyn_string dsValues)
public void _unRecipeFunctions_getRecipeInstancesOfClass (string sClassName, dyn_string &dsRcpInstanceNames, dyn_string &dsRcpInstanceDps)
public int _unRecipeFunctions_getInitialRecipeOfClass (string sClassDp, string &sInitialRcpDp, dyn_string &exceptionInfo)
public int _unRecipeFunctions_getLastActivatedRecipeDp (string sClassDp, string &sLastActivatedRcpDp, dyn_string &exceptionInfo)
public void unRecipeFunctions_getLastActivatedPcoRecipes (dyn_string dsPcoDps, dyn_string &recipeList, dyn_string &exceptionInfo)
public void unRecipeFunctions_getInitialPcoRecipes (dyn_string dsPcoDps, dyn_string &recipeList, dyn_string &exceptionInfo)
public void unRecipeFunctions_getLastActivatedRecipesFromPcoHierarchy (string sPcoDp, dyn_string &recipeList, dyn_string &exceptionInfo)
public void unRecipeFunctions_getInitialRecipesFromPcoHierarchy (string sPcoDp, dyn_string &recipeList, dyn_string &exceptionInfo)
public void unRecipeFunctions_addRecipeClassDevices (string sRcpClassDp)
public void unRecipeFunctions_applyRecipeClassModifications (string sRcpClassDp)
private void _unRecipeFunctions_setOnlineValuesForNewDpes (dyn_string dsOldDpes, dyn_string dsNewDpes, dyn_string dsRcpInstNames)
public void unRecipeFunctions_removeSelectedRecipeClassDevices (string sRcpClassDp)
public void _unRecipeFunctions_createRecipeClass (string sClassName, string sDescription, string sPcoLink, string &sRcpClassDp, dyn_string &exceptionInfo, dyn_string dsDeviceList=makeDynString(), string sAcDomain="", string sOperatorPrivileges="", string sExpertPrivileges="", string sAdminPrivileges="")
private bool _unRecipeFunctions_doesRecipeClassExist (string sClassName)
public void unRecipeFunctions_deviceUpdatedRcpClassCB (string sCommandDp, int iCommand, string sSystemNameDp, string sSystemName)
public bool _unRecipeFunctions_hasInitialRecipe (string sRecipeClass)
public void unRecipeFunctions_deleteRecipeClass (string sRcpClassDp, dyn_string &exceptionInfo)
public void unRecipeFunctions_getRecipeClasses (dyn_string &dsRecipeClassNames, dyn_string &dsRecipeClassDps, string sPcoLink="*", bool bLocalOnly=FALSE, bool bAddSystemName=FALSE, string sApplication="*", bool bOnlyConnectedSystems=FALSE)
public int unRecipeFunctions_loadRecipeClasses (string sPcoAlias, dyn_string &exceptionInfo, bool bLoadFirstClass=TRUE, string sApplication="*", bool bOnlyConnectedSystems=FALSE)
private int _unRecipeFunctions_loadRecipeClassesInTable (dyn_string rcpClassNames, dyn_string rcpClassDps, bool bLoadFirstClass=TRUE)
private int _unRecipeFunctions_loadRecipeClassesInComboBox (dyn_string rcpClassNames)
public void unRecipeFunctions_clearRecipeClassData ()
private void unRecipeFunctions_loadRecipeClassData (string sRcpClassDp)
public void unRecipeFunctions_selectRecipeClass (string sRcpClassDp, dyn_string &exceptionInfo, bool bForceReload=FALSE)
public void _unRecipeFunctions_loadRecipeClassList (string sPcoLink="*", string sApplication="*")
public void unRecipeFunctions_filterRecipeClasses (dyn_string dsPcoAlias, dyn_string dsApplication, dyn_string &dsRecipeClassNames, dyn_string &dsRecipeClassDps)

Detailed Description

UNICOS Copyright (C) CERN 2017 All rights reserved

unRcpFunctions_class.ctl This file contains functions related to the recipes classes.

Creation Date
15/03/2017
Modification History
Constraints
None
Usage
Public
PVSS managers
Ui, CTRL
Author:
Ivan Prieto Barreiro (BE-ICS)

Function Documentation

public void _unRecipeFunctions_getRecipeClassDeviceMapping ( dyn_mixed  rcpClassObject,
mapping &  rcpDeviceDpes 
)

Get the device mapping from a recipe class.

Parameters:
rcpClassObject - [IN] The recipe class object from the JCOP recipe class definition.
rcpDeviceDpes - [OUT] Mapping where: Key=device name, Value=list of device DPEs included in the recipe.

Referenced by unRecipeFunctions_loadRecipeClassData().

public bool _unRecipeFunctions_isRecipeClassDefinitionValid ( string  sClassDp,
dyn_string &  exceptionInfo 
)

Check if a recipe class definition is valid.

Parameters:
sClassDp - [IN] Datapoint name of the recipe class.
exceptionInfo - [OUT] Standard exception handling variable.

References unRecipeFunctions_getRecipeClassObject(), and unRecipeFunctions_normalizeDp().

Referenced by _unRecipeFunctions_createRecipeInstance(), _unRecipeFunctions_getRecipeClassList(), and unRecipeFunctions_saveRecipeToDb().

public void _unRecipeFunctions_getRecipeClassDataFromInstance ( string  sRcpInstanceDp,
string &  sRcpClassName,
string &  sRcpClassDp,
string &  sPcoLink 
)

Get the recipe class data from a recipe instance datapoint.

Parameters:
sRcpInstanceDp - [IN] Datapoint name of the recipe instance.
sRcpClassName - [OUT] Name of the recipe class related to the recipe instance.
sRcpClassDp - [OUT] Datapoint name of the recipe class related to the recipe instance.
sPcoLink - [OUT] Device link of the recipe class.

References unRecipeFunctions_normalizeDp(), and unRecipeFunctions_writeInRecipeLog().

Referenced by _unRecipeFunctions_getRecipeClassData(), and unRecipeFunctions_selectRecipeInstance().

public void _unRecipeFunctions_dpConnectRcpClassElementsCB ( string  sRcpClassElementsDp,
dyn_string  dsValues 
)

Callback function executed when the recipe class elements have been modified. The function will enable a warning message to indicate that the recipe must be reloaded.

Reviewed:
2018-09-12 Callback

References _unRecipeFunctions_enableRecipeInstanceWarning().

public void _unRecipeFunctions_getRecipeInstancesOfClass ( string  sClassName,
dyn_string &  dsRcpInstanceNames,
dyn_string &  dsRcpInstanceDps 
)

Get all the recipe instances of a class.

Parameters:
sClassName - [IN] Recipe class name.
dsRcpInstanceNames - [OUT] Recipe instance names.
dsRcpInstanceDps - [OUT] Recipe instance datapoint elements.

References _unRecipeFunctions_getFilteredDevices().

Referenced by _unRecipeFunctions_getSaveOperationIds(), _unRecipeFunctions_loadRecipeInstances(), _unRecipeFunctions_saveRecipeClassAndInstancesToDb(), unRecipeFunctions_deviceUpdatedRcpInstanceCB(), unRecipeFunctions_editRecipeClassPrivileges(), and unRecipeFunctions_loadRecipeClassInstancesFromDb().

public int _unRecipeFunctions_getInitialRecipeOfClass ( string  sClassDp,
string &  sInitialRcpDp,
dyn_string &  exceptionInfo 
)

Get the DP name of the initial recipe of the class 'sClassName'.

Parameters:
sClassDp - [IN] Datapoint name of the recipe class which initial recipe is required.
sInitialRcpDp - [OUT] DP Name of the initial recipe of the specified class.
exceptionInfo - [OUT] Standard exception handling variable.
Returns:
0 if the initial recipe was found, otherwise returns a negative value

References unRecipeFunctions_normalizeDp().

Referenced by unRecipeFunctions_deleteRecipeClass(), unRecipeFunctions_getInitialPcoRecipes(), and unRecipeFunctions_saveAsInitialRecipe().

public int _unRecipeFunctions_getLastActivatedRecipeDp ( string  sClassDp,
string &  sLastActivatedRcpDp,
dyn_string &  exceptionInfo 
)

Get the DP name of the last activated recipe of the class 'sClassName'.

Parameters:
sClassDp - [IN] Datapoint name of the recipe class which last activated recipe is required.
sLastActivatedRcpDp - [OUT] DP Name of the last activated recipe of the specified class.
exceptionInfo - [OUT] Standard exception handling variable.
Returns:
0 if the last activated recipe was found, otherwise returns a negative value

References unRecipeFunctions_normalizeDp().

Referenced by unRecipeFunctions_getLastActivatedPcoRecipes().

public void unRecipeFunctions_getLastActivatedPcoRecipes ( dyn_string  dsPcoDps,
dyn_string &  recipeList,
dyn_string &  exceptionInfo 
)

Get the last activated recipe of each recipe class for the current PCO.

Parameters:
dsPcoDps - [IN] List of PCO datapoint elements which last activated recipes are required.
recipeList - [OUT] Datapoint elements of the last activated recipes of the PCO.
exceptionInfo - [OUT] Standard exception handling variable.

References _unRecipeFunctions_getLastActivatedRecipeDp(), unRecipeFunctions_filterRecipeClasses(), unRecipeFunctions_getDeviceAliases(), and unRecipeFunctions_getRecipeClasses().

Referenced by unRecipeFunctions_getLastActivatedRecipesFromPcoHierarchy().

public void unRecipeFunctions_getInitialPcoRecipes ( dyn_string  dsPcoDps,
dyn_string &  recipeList,
dyn_string &  exceptionInfo 
)

Get the initial recipe of each recipe class for the current PCO.

Parameters:
dsPcoDps - [IN] List of PCO datapoint elements which initial recipes are required.
recipeList - [OUT] Datapoint elements of the initial recipes of the PCO.
exceptionInfo - [OUT] Standard exception handling variable.

References _unRecipeFunctions_getInitialRecipeOfClass(), unRecipeFunctions_filterRecipeClasses(), unRecipeFunctions_getDeviceAliases(), and unRecipeFunctions_getRecipeClasses().

Referenced by unRecipeFunctions_getInitialRecipesFromPcoHierarchy().

public void unRecipeFunctions_getLastActivatedRecipesFromPcoHierarchy ( string  sPcoDp,
dyn_string &  recipeList,
dyn_string &  exceptionInfo 
)

Get the last activated recipe of each recipe class for the PCO hierarchy.

Parameters:
sPcoDp - [IN] The PCO datapoint element which last activated recipes are required.
recipeList - [OUT] Datapoint elements of the last activated recipes of the PCO hierarchy.
exceptionInfo - [OUT] Standard exception handling variable.

References _unRecipeFunctions_getPcoChildren(), and unRecipeFunctions_getLastActivatedPcoRecipes().

public void unRecipeFunctions_getInitialRecipesFromPcoHierarchy ( string  sPcoDp,
dyn_string &  recipeList,
dyn_string &  exceptionInfo 
)

Get the initial recipe of each recipe class for the PCO hierarchy.

Parameters:
sPcoDp - [IN] The PCO datapoint element which initial recipes are required.
recipeList - [OUT] Datapoint elements of the initial recipes of the PCO hierarchy.
exceptionInfo - [OUT] Standard exception handling variable.

References _unRecipeFunctions_getPcoChildren(), and unRecipeFunctions_getInitialPcoRecipes().

public void unRecipeFunctions_addRecipeClassDevices ( string  sRcpClassDp  ) 

Add new devices to the recipe class that is being displayed in the recipe class panel.

Parameters:
sRcpClassDp - [IN] Datapoint element of the recipe class that will be modified.

References _unRecipeFunctions_getFilteredDevices(), _unRecipeFunctions_getTypeMapping(), and unRecipeFunctions_writeInRecipeLog().

public void unRecipeFunctions_applyRecipeClassModifications ( string  sRcpClassDp  ) 

Apply the modifications done in the recipe class elements.

Parameters:
sRcpClassDp - [IN] DataPoint name of the recipe class where the changes must be applied.

References _unRecipeFunctions_setOnlineValuesForNewDpes(), unRecipeFunctions_getRecipeClassObject(), unRecipeFunctions_loadRecipeClassData(), and unRecipeFunctions_writeInRecipeLog().

Referenced by unRecipeFunctions_deviceUpdatedRcpClassCB().

private void _unRecipeFunctions_setOnlineValuesForNewDpes ( dyn_string  dsOldDpes,
dyn_string  dsNewDpes,
dyn_string  dsRcpInstNames 
)

When a recipe class is modified to include new DPEs the method sets the online values in all the recipe instances for the new DPEs.

Parameters:
dsOldDpes - [IN] Old DPEs of the recipe class.
dsNewDpes - [IN] New DPEs of the recipe class.
dsRcpInstNames - [IN] Recipe instance names.

References unRecipeFunctions_dynDiff(), unRecipeFunctions_getDynPos(), and unRecipeFunctions_getOnlineValues().

Referenced by unRecipeFunctions_applyRecipeClassModifications().

public void unRecipeFunctions_removeSelectedRecipeClassDevices ( string  sRcpClassDp  ) 

Remove the selected recipe class devices from the table.

Parameters:
sRcpClassDp - [IN] Datapoint element of the recipe class to be modified.

References unRecipeFunctions_writeInRecipeLog().

public void _unRecipeFunctions_createRecipeClass ( string  sClassName,
string  sDescription,
string  sPcoLink,
string &  sRcpClassDp,
dyn_string &  exceptionInfo,
dyn_string  dsDeviceList = makeDynString(),
string  sAcDomain = "",
string  sOperatorPrivileges = "",
string  sExpertPrivileges = "",
string  sAdminPrivileges = "" 
)

Create the recipe class device.

Parameters:
sClassName - [IN] Recipe class name.
sDescription - [IN] Recipe class description.
sPcoLink - [IN] Alias of the PCO where the recipe class will be linked.
sRcpClassDp - [OUT] Datapoint of the new recipe class.
exceptionInfo - [OUT] Standard exception handling variable.
dsDeviceList - [IN] List of recipe elements (optional).
sAcDomain - [IN] Access control domain (optional).
sOperatorPrivileges - [IN] Operator privileges (optional).
sExpertPrivileges - [IN] Expert privileges (optional).
sAdminPrivileges - [IN] Admin privileges (optional).

References _unRecipeFunctions_doesRecipeClassExist(), unRecipeFunctions_createNewRecipeDp(), unRecipeFunctions_createRecipeFrontEnd(), unRecipeFunctions_getDeviceDefaultPrivileges(), unRecipeFunctions_updateRecipeClassPrivileges(), and unRecipeFunctions_writeInRecipeLog().

Referenced by _unRecipeFunctions_createRecipeClassFromDbInternal().

private bool _unRecipeFunctions_doesRecipeClassExist ( string  sClassName  ) 

Function used to know if a recipe class already exists in any system.

Parameters:
sClassName - [IN] Recipe class name.
Returns:
TRUE if the recipe class already exists, otherwise FALSE.

References unRecipeFunctions_isRemoteSystemConnected(), and unRecipeFunctions_writeInRecipeLog().

Referenced by _unRecipeFunctions_createRecipeClass().

public void unRecipeFunctions_deviceUpdatedRcpClassCB ( string  sCommandDp,
int  iCommand,
string  sSystemNameDp,
string  sSystemName 
)

Callback function from the recipe class panel. The function is called when the devices list has been updated.

Parameters:
sCommandDp - [IN] DP Name of the command over the list of devices.
iCommand - [IN] Command value over the list of devices.
sSystemNameDp - [IN] DP Name of the system.
sSystemName - [IN] System name.
Reviewed:
2018-09-12 Callback

References unRecipeFunctions_applyRecipeClassModifications(), unRecipeFunctions_areListsEqual(), unRecipeFunctions_getRecipeClasses(), unRecipeFunctions_loadRecipeClasses(), and unRecipeFunctions_selectRecipeClass().

public bool _unRecipeFunctions_hasInitialRecipe ( string  sRecipeClass  ) 

Check if an initial recipe instance exists for the specified class.

Parameters:
sRecipeClass - [IN] Recipe class name.
Returns:
TRUE if the specified recipe class has an initial recipe, otherwise FALSE.

Referenced by _unRecipeFunctions_createRecipeInstance(), _unRecipeFunctions_createRecipeInstanceFromDbInternal(), and unRecipeFunctions_createRecipeInstance().

public void unRecipeFunctions_deleteRecipeClass ( string  sRcpClassDp,
dyn_string &  exceptionInfo 
)

Delete a recipe class and all its recipe instances. Note: The recipe class and its instances will be deleted ONLY if there are no initial recipes of the class.

Parameters:
sRcpClassDp - [IN] Data point name of the recipe instance to delete.
exceptionInfo - [OUT] Standard exception handling variable.

References _unRecipeFunctions_getInitialRecipeOfClass(), unRecipeFunctions_loadRecipeClasses(), and unRecipeFunctions_writeInRecipeLog().

public void unRecipeFunctions_getRecipeClasses ( dyn_string &  dsRecipeClassNames,
dyn_string &  dsRecipeClassDps,
string  sPcoLink = "*",
bool  bLocalOnly = FALSE,
bool  bAddSystemName = FALSE,
string  sApplication = "*",
bool  bOnlyConnectedSystems = FALSE 
)

Get the list of recipe class names and recipe class DPs linked to a PCO.

Parameters:
dsRecipeClassNames - [OUT] List of recipe class names.
dsRecipeClassDps - [OUT] List of recipe class DPs.
sPcoLink - [IN] PCO alias which recipe classes are requested.
bLocalOnly - [IN] TRUE if only the recipe classes of the local system must be loaded, otherwise FALSE.
bAddSystemName - [IN] TRUE if the system name must be added to the recipe class name
bOnlyConnectedSystems - [IN] TRUE if only the devices of the connected systems must be obtained.
sApplication - [IN] Name of the application for which the recipe classes are required.

References _unRecipeFunctions_getFilteredDevices(), unRecipeFunctions_filterRecipeClasses(), unRecipeFunctions_isRemoteSystemConnected(), and unRecipeFunctions_sortAscDynLists().

Referenced by _unRecipeFunctions_getExistingClassOrCreateNewClassFromDb(), _unRecipeFunctions_loadRecipeClassList(), unRecipeFunctions_deviceUpdatedRcpClassCB(), unRecipeFunctions_getInitialPcoRecipes(), unRecipeFunctions_getLastActivatedPcoRecipes(), and unRecipeFunctions_loadRecipeClasses().

public int unRecipeFunctions_loadRecipeClasses ( string  sPcoAlias,
dyn_string &  exceptionInfo,
bool  bLoadFirstClass = TRUE,
string  sApplication = "*",
bool  bOnlyConnectedSystems = FALSE 
)

Load the recipe classes linked to the PCO sPcoAlias.

Parameters:
sPcoAlias - [IN] The PCO alias which recipe classes muat be loaded.
exceptionInfo - [OUT] Standard exception handling routine.
bLoadFirstClass - [IN] TRUE if the data of the first recipe class must be loaded in the panel.
sApplication - [IN] Application name for the recipe classes to load.
bOnlyConnectedSystems - [IN] TRUE if only the devices of the connected systems must be obtained.
Returns:
The number of recipe classes added.

References _unRecipeFunctions_loadRecipeClassesInComboBox(), _unRecipeFunctions_loadRecipeClassesInTable(), unRecipeFunctions_getRecipeClasses(), and unRecipeFunctions_writeInRecipeLog().

Referenced by unRecipeFunctions_deleteRecipeClass(), unRecipeFunctions_deviceUpdatedRcpClassCB(), and unRecipeFunctions_selectPcoRecipes().

private int _unRecipeFunctions_loadRecipeClassesInTable ( dyn_string  rcpClassNames,
dyn_string  rcpClassDps,
bool  bLoadFirstClass = TRUE 
)

Load the recipe class list in a table.

Parameters:
rcpClassNames - [IN] List containing the recipe class names.
rcpClassDps - [IN] List containing the recipe class datapoints.
bLoadFirstClass - [IN] TRUE if the data of the first recipe class must be loaded in the panel.
Returns:
The number of recipe classes added.

References unRecipeFunctions_clearRecipeClassData(), and unRecipeFunctions_selectRecipeClass().

Referenced by unRecipeFunctions_loadRecipeClasses().

private int _unRecipeFunctions_loadRecipeClassesInComboBox ( dyn_string  rcpClassNames  ) 

Load the recipe class list in a combo box.

Parameters:
rcpClassNames - [IN] List containing the recipe class names.
Returns:
The number of recipe classes added.

Referenced by unRecipeFunctions_loadRecipeClasses().

public void unRecipeFunctions_clearRecipeClassData (  ) 

Clear all the data from the recipe class panel.

Referenced by _unRecipeFunctions_loadRecipeClassesInTable().

private void unRecipeFunctions_loadRecipeClassData ( string  sRcpClassDp  ) 

Load the recipe class data in the recipe class panel.

Parameters:
sRcpClassDp - [IN] Datapoint name of the recipe class which data will be loaded in the panel.

References _unRecipeFunctions_getRecipeClassDeviceMapping(), _unRecipeFunctions_setInvalidRows(), unRecipeFunctions_getRecipeClassObject(), unRecipeFunctions_normalizeDp(), and unRecipeFunctions_writeInRecipeLog().

Referenced by unRecipeFunctions_applyRecipeClassModifications(), and unRecipeFunctions_selectRecipeClass().

public void unRecipeFunctions_selectRecipeClass ( string  sRcpClassDp,
dyn_string &  exceptionInfo,
bool  bForceReload = FALSE 
)

Select the specified recipe class in the recipe class panel.

Parameters:
sRcpClassDp - [IN] Datapoint name of the recipe class.
exceptionInfo - [OUT] Standard exception handling variable.
bForceReload - [IN] Boolean value to force the reload of the recipe class data.

References unRecipeFunctions_loadRecipeClassData(), and unRecipeFunctions_normalizeDp().

Referenced by _unRecipeFunctions_loadRecipeClassesInTable(), and unRecipeFunctions_deviceUpdatedRcpClassCB().

public void _unRecipeFunctions_loadRecipeClassList ( string  sPcoLink = "*",
string  sApplication = "*" 
)

Method used to load the recipe class list associated to a PCO

Parameters:
sPcoLink Alias of the PCO which recipe classes will be loaded or "*" for all the available classes.

References unRecipeFunctions_getRecipeClasses().

public void unRecipeFunctions_filterRecipeClasses ( dyn_string  dsPcoAlias,
dyn_string  dsApplication,
dyn_string &  dsRecipeClassNames,
dyn_string &  dsRecipeClassDps 
)

Filters a list of recipe class names & recipe class dps. Removes from the lists the recipes that don't belong to the specified applications or are not linked to the specified PCOs.

Parameters:
dsPcoAlias - [IN] List of PCO aliases for the filter.
dsApplication - [IN] List of applications for the filter.
dsRecipeClassNames - [IN/OUT] List of recipe class names.
dsRecipeClassDps - [IN/OUT] List of recipe class dps.

Referenced by unRecipeFunctions_getInitialPcoRecipes(), unRecipeFunctions_getLastActivatedPcoRecipes(), and unRecipeFunctions_getRecipeClasses().


Generated on 11 Mar 2019 for unCPC6 by  doxygen 1.6.1