Global Presentation Object

A global Presentation Object is named global<Component> and contains database objects (methods and views) that the scanner process cannot identify to which presentation object it should belong. This is typically when the database objects are not located in a window class rather in a library file. The global Presentation Object is created only if such constructions are found. Therefore all components do not have a global Presentation Object.

Ideally the number of global Presentation Objects should be kept to a minimum. If it exists it should contain as few database objects and dependent windows as possible. Transactional methods like New__, Modify__, Remove__ should be avoided. The reason to reduce the grants given by global Presentation Object is that this Presentation Object is by default granted when granting a Presentation Object for that component. This is done since a window might require access to these database objects. Any access right that should be possible to manage should not be added to the global Presentation Object.

There are some techniques to use to avoid getting database objects into the global Presentation Object. The client source files can be annotated with instructions to the scanner. If none of the annotations described below solves the issue it is possible to also manually create Presentation Objects or using include / exclude scripts, see Server Side Behavior.

Contents

 

The class FndPresentationObject defines the possible annotations:

UsedBy

"UsedBy" Used to "re-route" all DB objects and/or Dependency for an certain base type (class) to predefined windows. Otherwise, base classes will all have their items placed in the global<COMPONENT> object, which might often become very large. It refers to the window object(s) where the Presentation Object items for the base class should be scanned and transferred. If object(s) in a utility class is referred completely by a certain Form/Table Window or Dialog, "UsedBy" annotation can be used in the window which has referred to the utility class.

Note:  "UsedBy" can be only used within the same assembly.

 [FndPresentationObject.UsedBy("frmPackageDetails")]
 public partial class dlgAddToAcp : cDialog
 {
    
 }

 

Declaration of UsedBy Class

            

Exclude

"Exclude" captures the Application Forms objects which needs to be excluded from the the Presentation Object Scan. If only few objects  of a utility class is referred by a certain window, then "Exclude" can be used in the utility class and "IncludeMethod","IncludeView","IncludeLovView" or "IncludeWindow" can be used as preferred in order to include relevant objects.

 [FndPresentationObject.Exclude()]   
 public class ApplicationConfigurationPackages:IAPFApplicationConfigurationPackages
 {
 
 }

 

Declaration of Exclude Class


IncludeMethod

"IncludeMethod" addresses the Database methods that should be included as security objects for the Presentation Object. It includes method(s) to the Presentation Object. When "Exclude" is used in a utility class and some objects in that utility class like transactional methods are used in a Form/Table Window or Dialog then "IncludeMethod" can be used to include those referred object(s).

 [FndPresentationObject.IncludeMethod("App_Config_Package_Item_API.Remove_Item", "App_Config_Package_API.Get_Item_Package_Name", "App_Config_Package_API.Get_Package_Id_By_Name")]    
 public partial class dlgAPFAddToPackage : cDialog
 { 
               
 }

 

Declaration of IncludeMethod Class

IncludeView

"IncludeView" acts same like "IncludeMethod" where this includes view as a security object for the Presentation Object.

Declaration of IncludeView Class

IncludeLovView

"IncludeLovView" captures LOV view that should be included as security object for the Presentation Object.

Declaration of IncludeLovView Class

IncludeWindow

"IncludeWindow" addresses a Form/Table Window or Dialog that should be included as a dependency object for the Presentation Object.


Declaration of IncludeWindow Class