Obtain an instance of EAMAccessManager - HxGN EAM - 12.1 - Feature Briefs - Hexagon

HxGN EAM Custom Framework

Search by Category
Feature Briefs
HxGN EAM Version

Please note, that to obtain an instance to the EAMAccessManager object the HttpRequest object must contain the tenant id and external session id values, otherwise we will not be able to find your users session

EAMAccessManager vEamAccessManager = mEamFactory.getEAMAccessManager(pRequest);

You can also get instance of EAMAccessManager via this method:

EAMAccessManager vEamAccessManager = mEamFactory.getEAMAccessManager(externalSessionId, tenantId);Making System API calls via EAMAccessManager

// Determine if the users session is still active / valid

boolean vIsSessionValid = checkSessionOnServer();

// Obtain database connection object

Connection vConnection = getConnection();

// Obtain multiple install parameter values

String[] vInstallParameters = { "DEFORG", "PMRVCTRL", "DEPTSEC" };

String[] vValues = getInstallParameters(vInstallParameters);

// Obtain a single install parameter value

String vValue = getInstallParameter("DEPTSEC");

// Get organization security for some custom form

EAMSecurity vOrgSecurity = getOrgSecurity("ORG1", "ACCCNT", "UT1");

// Get organization security for DEFORG for some custom form

EAMSecurity vOrgSecurity = getOrgSecurity("ACCCNT", "UT1");

// Access the EAMAccessSession object directly

EAMAccessSession vSession = vEamAccessManager.getSession();

// Do something with the EAMAccessSession Object

vSession.setAttribute("mykey", "myvalue");

String vMyValue = vSession.getAttribute("mykey");