Class GrantCore

  • All Implemented Interfaces:
    com.simplicite.util.engine.CacheInterface, java.io.Serializable
    Direct Known Subclasses:
    Grant

    public abstract class GrantCore
    extends java.lang.Object
    implements java.io.Serializable, com.simplicite.util.engine.CacheInterface
    Core user rights
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      GrantCore()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      boolean accessAction​(java.lang.String obj, java.lang.String action)
      Check if the action is granted to the user for a given object
      boolean accessCreate​(java.lang.String obj)
      Check if the creation is granted to the user
      boolean accessDelete​(java.lang.String obj)
      Check if deletion is granted to the user
      boolean accessDomain​(java.lang.String domain)
      Check if the domain is granted to the user
      boolean accessIndexedObject​(java.lang.String obj)
      Check if the object is granted to the user and indexable
      java.util.List<java.lang.String> accessIndexedObjects()
      List of accessible objects with fulltext index
      boolean accessObject​(java.lang.String obj)
      Check if the object is granted to the user
      boolean accessProcess​(java.lang.String process)
      Check if the process is granted to the user
      boolean accessShortcut​(java.lang.String name)
      Check if the shortcut is granted to the user
      boolean accessUpdate​(java.lang.String obj)
      Check if update is granted to the user
      boolean accessWebZone​(java.lang.String zone, int order, java.lang.String lang)
      Deprecated, for removal: This API element is subject to removal in a future version. 
      void addAccessCreate​(java.lang.String obj)
      Grant the object creation to the user
      void addAccessDelete​(java.lang.String obj)
      Grant the object deletion to the user
      void addAccessObject​(java.lang.String obj)
      Grant the right to read/open the object
      void addAccessProcess​(java.lang.String process)
      Grant the right to read/open the process
      void addAccessRead​(java.lang.String obj)
      Alias to addAccessObject
      void addAccessUpdate​(java.lang.String obj)
      Grant the object update to the user
      void addHomePage​(java.lang.String viewName)
      Add home page view
      void addObjectCalculated​(java.lang.String object, java.lang.String field, java.lang.String target, java.lang.String refId)
      Not null when the field is linked to calculated field in DB.
      void addPredefinedSearch​(java.lang.String object, PredefinedSearch ps)
      Add a predefined search to object
      void addResource​(Resource res, java.lang.String objectClass, java.lang.String objId)
      Deprecated. 
      void addResource​(Resource res, java.lang.String objectClass, java.lang.String objId, java.lang.String objName)
      Add a resource
      void addSharedScript​(SharedScript scr)
      Add a shared code
      void addText​(java.lang.String code, java.lang.String value)
      Add a translated text
      boolean canUpdateSystem()
      Can update system modules' objects (ADMIN_SYSTEM = yes/no)
      boolean[] changeAccess​(java.lang.String obj, boolean[] crud)
      Change the Create/Read/Update/Delete access to object
      boolean[] changeAccess​(java.lang.String obj, boolean create, boolean read, boolean update, boolean delete)
      Change the Create/Read/Update/Delete access to object
      boolean checkPwd​(java.lang.String password)
      Check current user password
      void clearTreeViews()
      Clear tree views
      void delAccessCreate​(java.lang.String obj)
      Revoke the object creation to the user
      void delAccessDelete​(java.lang.String obj)
      Revoke the object deletion to the user
      void delAccessObject​(java.lang.String obj)
      Revoke the right to read/open the object
      void delAccessProcess​(java.lang.String process)
      Revoke the right to read/open the process
      void delAccessRead​(java.lang.String obj)
      Alias to delAccessObject
      void delAccessUpdate​(java.lang.String obj)
      Revoke the object update to the user
      void disableAction​(java.lang.String obj, java.lang.String action)
      Disable one action on a given object
      void enableAction​(java.lang.String obj, java.lang.String action)
      Enable one action on a given object
      void enableGC​(boolean enabled)
      Not used : System full GC is managed after the expiration of user session
      java.lang.Object evalExpression​(java.lang.String expr)
      Prepare and evaluate an expression (see prepareExpression for details on tokens)
      java.lang.Object evalExpression​(java.lang.String expr, java.util.Map<java.lang.String,​java.lang.Object> in, java.util.Map<java.lang.String,​java.lang.Object> out)
      Prepare and evaluate an expression (see prepareExpression for details on tokens)
      java.lang.String evalExpressionAsString​(java.lang.String expr)
      Prepare and evaluate an expression token (enclosed in [EXPR:]) as a string (see prepareExpression for details on tokens).
      java.lang.String evalURLExpression​(java.lang.String url)
      Prepare and evaluate an URL expression (see prepareExpression for details on tokens)
      boolean garbageCollection()
      Not used : System full GC is managed after the expiration of user session
      Action getAction​(java.lang.String obj, java.lang.String name)
      Get a specific action of one object
      java.util.List<Action> getActions​(java.lang.String obj)
      Get all specific actions of one object
      java.util.List<Action> getActions​(java.lang.String obj, java.lang.String startsWith)
      Get all actions of one object
      java.lang.String getAjaxKey()
      Set the user Ajax key
      int getAuthMethod()
      Get the authentication method
      java.lang.String getAuthProvider()
      Get the authentication provider name
      java.lang.String getAuthToken()
      Get the user authentication token
      long getAuthTokenExpiry()
      Get the user authentication token expiry time
      java.lang.String getBeanDir()
      Deprecated.
      Use Platform.getSrcDir
      java.lang.String getBinDir()
      Deprecated.
      Use Platform.getBinDir
      boolean getBooleanParameter​(java.lang.String name)
      Gets an boolean session system parameter as boolean (false if absent)
      boolean getBooleanParameter​(java.lang.String name, boolean def)
      Gets an boolean session system parameter as boolean
      java.lang.String getCacheDir()
      Deprecated.
      Use Platform.getCacheDir
      java.lang.String getCacheKey​(Grant g)
      Get grant unique cache key
      java.lang.String getCellPhoneNumber()
      Get the user's cell phone number (alias to getMobilePhoneNumber)
      java.lang.String getClassesDir()
      Deprecated.
      Use Platform.getClassesDir
      java.lang.String getClientTabId()
      Client/browser tab Id
      java.lang.String getContentDir()
      Deprecated.
      Use Platform.getContentDir
      java.util.Map<java.lang.String,​java.lang.String> getCreatable()
      Get granted objects for creation
      com.simplicite.util.engine.GrantData getData()
      Get the GrantData infos
      java.lang.String getDateFormat()
      User date format (ex MM/DD/YYYY)
      java.lang.String getDBPatchLevel()
      Get database patch level
      java.util.Map<java.lang.String,​java.lang.String> getDel()
      Deprecated.
      Use getDeletable
      java.util.Map<java.lang.String,​java.lang.String> getDeletable()
      Get granted objects for deletion
      Disposition getDisposition()
      Get disposition
      java.lang.String getDispositionName()
      Get the disposition name (from current disposition definition or, if not yet loaded from the configured system parameter).
      java.lang.String getDocDir()
      Deprecated.
      Use Platform.getDocDir
      long getDocDirMax()
      Deprecated.
      Use Platform.getDocDirMax
      java.lang.String getDocLocalDir()
      Deprecated.
      Use Platform.getDocLocalDir
      java.util.List<java.lang.String> getDomains()
      Get all granted domains
      java.lang.String getEmail()
      Get the user's email address
      java.lang.String getExportDir()
      Deprecated.
      Use Platform.getExportDir
      java.lang.String getExternalDocsDir()
      Deprecated.
      Use Platform.getExternalDocsDir
      java.lang.String getFirstName()
      Get the user's first name
      boolean getFlagParameter​(java.lang.String name)
      Gets a flag session system parameter as boolean (false if absent)
      boolean getFlagParameter​(java.lang.String name, boolean def)
      Gets a flag session system parameter as boolean
      java.lang.String getFullName()
      Get the user's full name (or the login if unknown)
      com.simplicite.util.engine.GrantInterface getGrantInterface()
      Get the invocation interface for grants (Local EJB, Remote EJB, WebService, Direct)
      java.lang.String getHashAlgorithm()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use SystemParameters.getHashEncoding
      java.lang.String getHashEncoding()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use SystemParameters.getHashEncoding
      View getHome()
      Get the current home page
      java.lang.String getHomeName()
      Get the current home page name if exists
      java.util.List<java.lang.String> getHomePages()
      Get all granted home pages
      java.lang.String getHomePhoneNumber()
      Get the user's home phone number
      java.lang.String getImportDir()
      Deprecated.
      Use Platform.getImportDir
      java.lang.String getIndexDir()
      Deprecated.
      Use Platform.getIndexDir
      int getIntParameter​(java.lang.String name)
      Gets an integer session system parameter as boolean (0 if absent)
      int getIntParameter​(java.lang.String name, int def)
      Gets an integer session system parameter as boolean
      java.lang.String getJavadocDir()
      Deprecated.
      Use Platform.getJavadocDir
      org.json.JSONArray getJSONArrayParameter​(java.lang.String name)
      Gets an JSON array string session system parameter as JSON array
      org.json.JSONArray getJSONArrayParameter​(java.lang.String name, java.lang.String def)
      Gets an JSON array string session system parameter as JSON array
      org.json.JSONArray getJSONArrayParameter​(java.lang.String name, org.json.JSONArray def)
      Gets an JSON array string session system parameter as JSON array
      org.json.JSONObject getJSONObjectParameter​(java.lang.String name)
      Gets an JSON object string session system parameter as JSON object
      org.json.JSONObject getJSONObjectParameter​(java.lang.String name, java.lang.String def)
      Gets an JSON object string session system parameter as JSON object
      org.json.JSONObject getJSONObjectParameter​(java.lang.String name, org.json.JSONObject def)
      Gets an JSON object string session system parameter as JSON object
      java.lang.String getLang()
      Get the user's language
      java.lang.String getLangPreference()
      Get the user's preferred language
      java.util.List<java.lang.String> getLanguages()
      Get available languages for the user (default all known languages)
      java.lang.String getLastName()
      Get the user's last name
      java.lang.String getLibsDir()
      Deprecated.
      Use Platform.getLibsDir
      java.util.Locale getLocale()
      Get locale for grant
      java.lang.Object getLock()
      Get the lock to be used in synchronized blocks
      java.lang.String getLogDir()
      Deprecated.
      Use Platform.getLogDir
      AppLogEvent getLogEvent​(java.lang.String code)
      Get the log event for a given code
      java.util.Map<java.lang.String,​AppLogEvent> getLogEvents()
      Get all log events
      java.lang.String getLogin()
      Get the user login
      long getLongParameter​(java.lang.String name)
      Gets an long integre session system parameter as boolean (0 if absent)
      long getLongParameter​(java.lang.String name, long def)
      Gets an long integer session system parameter as boolean
      java.lang.String getMavenDir()
      Deprecated.
      Use Platform.getMavenDir
      int getMaxRows()
      Get the list maximum size (for paginated search)
      long getMaxUploadSize()
      Get the upload limit size (in Mb)
      MenuItem getMenu()
      Get the main menu
      java.util.List<MenuItem> getMenuItems​(java.lang.String domain)
      Get items in a domain
      java.lang.String getMenuStyle()
      Get menu style
      java.lang.String getMFAMethod()
      Get the user's MFA method (or null if the authentication provider is not the internal provider)
      java.lang.String getMFASettings()
      Get the user's MFA settings
      org.json.JSONObject getMFASettingsJSONObject()
      Get the user's MFA settings as JSON object
      int getMinRows()
      Get the list page minimum size (for paginated searches)
      java.lang.String getMobilePhoneNumber()
      Get the user's mobile phone number
      java.lang.String getName()
      Get name
      java.util.Map<java.lang.String,​java.lang.String> getNew()
      Deprecated.
      Use getCreatable
      java.lang.String getNumberFormat()
      User number format
      java.util.Map<java.lang.String,​java.util.List<Action>> getObjectActions()
      Get granted objects for external actions
      java.util.Map<java.lang.String,​java.util.Map<java.lang.String,​java.util.List<java.lang.String>>> getObjectCalculated()
      Get ref object calculated fields
      com.simplicite.util.engine.ObjectInterface getObjectInterface()
      Get the invocation interface for objects (Local EJB, Remote EJB, WebService, Direct)
      java.lang.Object getObjectParameter​(ObjectCore obj, java.lang.String name)
      Gets one object parameter
      java.lang.Object getObjectParameter​(java.lang.String name)
      Gets one object session parameter
      java.lang.Object getObjectParameter​(java.lang.String name, java.lang.Object def)
      Gets one object session parameter
      java.util.Map<java.lang.String,​java.io.Serializable> getObjectParameters​(ObjectCore obj)
      Gets all object parameters
      java.util.List<Resource> getObjectResources​(java.lang.String objectClass, java.lang.String objId)
      Get object resources
      java.util.List<java.lang.String> getObjects()
      Get all granted objects
      java.util.Map<java.lang.String,​java.util.List<View>> getObjectViews()
      Get the views associated to objects
      int getPanelCharMax()
      Get panels (tabs) max width in char
      java.lang.String getParameter​(java.lang.String name)
      Gets a text session parameter
      java.lang.String getParameter​(java.lang.String name, java.lang.String def)
      Gets a text session parameter
      java.lang.String getParameterId​(java.lang.String code)  
      java.util.Map<java.lang.String,​java.io.Serializable> getParameters()
      Get all parameters
      java.lang.String getPassword()
      Get the user password
      DocumentDB getPicture()
      Get the user picture document
      java.lang.String getPoweredBy()
      Get the powered by text
      java.util.Map<java.lang.String,​java.util.List<PredefinedSearch>> getPredefinedSearch()
      Get all predefined searches
      java.util.List<PredefinedSearch> getPredefinedSearch​(java.lang.String object)
      Get predefined searches of object
      PredefinedSearch getPredefinedSearch​(java.lang.String object, java.lang.String id)
      Get predefined searches of object
      java.util.Map<java.lang.String,​java.lang.String> getProcess()
      Get the granted processes
      ProcessusInterface getProcessInterface()
      Get the invocation interface for processes (Local EJB, Remote EJB, WebService, Direct)
      java.lang.String getProjectDir()
      Deprecated.
      Use Platform.getProjectDir
      int getRailway()
      Get the railway size to display in the navigation bar
      static java.lang.String getRandomPassword​(int length)
      Get random password
      java.lang.String getRecycleBinDir()
      Deprecated.
      Use Platform.getRecycleBinDir
      java.util.List<GroupDB> getRegistrationGroups()
      Get the registration groups
      Resource getResource​(java.lang.String code)
      Get a resource for a specified code
      Resource getResource​(java.lang.String type, java.lang.String code)
      Get a disposition resource for specified code and type
      Resource getResource​(java.lang.String code, java.lang.String type, java.lang.String objectName)
      Get a resource for specified code, type or objectName
      Resource getResource​(java.lang.String type, java.lang.String code, java.lang.String objectClass, java.lang.String objId)
      Get a resource for specified code and type
      Resource getResourceById​(java.lang.String resId)
      Get a resource for specified resource ID
      java.util.List<java.lang.String> getResourceCodes​(java.lang.String type, java.lang.String objectClass, java.lang.String objId)
      Get resource codes for specified type
      java.util.Map<java.lang.String,​Resource> getResources()
      Get all resources
      java.util.Map<java.lang.String,​GroupDB> getResp()
      Get all groups granted in the user session
      java.lang.String getRespList()
      Get all groups granted in the user session in a text format (separated with comma)
      java.lang.String getScope()
      Get the current scope if exists
      SharedScript getScriptById​(java.lang.String scrId)
      Get a shared code for specified ID
      com.simplicite.util.engine.ScriptInterpreter getScriptInterpreter()
      Get script interpreter for the user session
      java.lang.String getScriptInterpreterEngineName()
      Get script interpreter engine name
      java.lang.String getSessionId()
      Get the user SessionId (web or technical)
      SharedScript getSharedScript​(java.lang.String name)
      Get a shared code for specified code
      Shortcut getShortcut​(java.lang.String name)
      Get shortcut
      java.util.List<Shortcut> getShortcuts()
      Get all shortcuts
      View getSimpleView​(java.lang.String name)
      Get a standalone view
      java.util.Map<java.lang.String,​View> getSimpleViews()
      Get all standalone views
      java.lang.String getSourcesDir()
      Deprecated.
      Use Platform.getSourcesDir
      java.lang.String getSrcDir()
      Deprecated.
      Use Platform.getSrcDir
      int getStatus()
      Get the user's status
      java.lang.String getSubPackage()
      Get subpackage of specific classes
      java.util.Map<java.lang.String,​java.lang.String> getText()
      Get all the translated text values (in current user's language)
      java.lang.String getText​(java.lang.String code)
      Same as T
      java.lang.String getTheme()
      Get the theme name
      java.util.TimeZone getTimeZone()
      Get the user time zone
      java.lang.String getTimeZoneID()
      User time zone ID
      java.lang.String getTmpDir()
      Deprecated.
      Use Platform.getTmpDir
      TreeView getTreeView​(java.lang.String name)
      Get a tree view
      java.util.Map<java.lang.String,​TreeView> getTreeViews()
      Get all tree views
      java.util.List<TreeView> getTreeViewsOfObject​(java.lang.String name, boolean root)
      Get treeviews with a given object in hierarchy
      java.util.Map<java.lang.String,​java.lang.String> getUpdatable()
      Get granted objects for update
      int getUserId()
      Get the user unique ID as integer
      java.lang.String getUserModuleId()
      Get the user Module ID
      java.lang.String getUserUniqueId()
      Get the user unique ID as string
      java.lang.String getVersion()
      Get the application version
      java.util.Map<java.lang.String,​java.util.List<ObjectVisibility>> getVisibilities()
      Get object all visibilities
      java.util.List<ObjectVisibility> getVisibility​(java.lang.String object, char type)
      Get the object's standard access visibilities
      java.util.List<ObjectVisibility> getVisibility​(java.lang.String object, java.lang.String action)
      Get object ACTION visibilities
      WebZone getWebZone​(java.lang.String zone, int order, java.lang.String lang)
      Deprecated, for removal: This API element is subject to removal in a future version. 
      WebZone getWebZone​(java.lang.String zone, java.lang.String name, java.lang.String lang)
      Deprecated, for removal: This API element is subject to removal in a future version. 
      java.util.List<WebZone> getWebZones()
      Deprecated, for removal: This API element is subject to removal in a future version. 
      java.util.List<WebZone> getWebZones​(java.lang.String zone)
      Deprecated, for removal: This API element is subject to removal in a future version. 
      java.lang.String getWindowTitle()
      Get the window title
      java.lang.String getWorkPhoneNumber()
      Get the user's work phone number
      boolean hasParameter​(java.lang.String name)
      Check if a text session parameter is set
      boolean hasRegistration()
      Has registration?
      boolean hasResponsibility​(java.lang.String group)
      Check if the user has one responsibility
      boolean isAboutEnable()
      Is about info enabled ? Forced for admin profiles
      boolean isAPIInterfaceEnable()
      Deprecated. 
      boolean isCompletionEnable()
      Is the completion feature enabled?
      boolean isConvertWildcards()
      Are wildcard converted (from * and ? to SQL's % and _)?
      boolean isCROWDAuthMethod()
      Is the authentication method CROWD?
      boolean isCustomAuthMethod()
      Is the authentication method custom?
      boolean isDefaultAuthMethod()
      Is the authentication method default?
      boolean isDesigner()
      Is "designer" user?
      boolean isEasyModeClearCache()
      Deprecated, for removal: This API element is subject to removal in a future version. 
      boolean isForcedChangePassword()
      Is forced change password ?
      boolean isGITInterfaceEnable()
      Deprecated. 
      boolean isHtmlEditorEnable()
      Is the HTML editor enabled ?
      boolean isHybridApp()
      Hybrid application on mobile device (cordova)
      boolean isInternalOAuth2AuthMethod()
      Is the authentication method OAuth2?
      boolean isIOInterfaceEnable()
      Deprecated. 
      boolean isJavaImplemented()
      Is implemented in Java
      boolean isLDAPAuthMethod()
      Is the authentication method LDAP?
      boolean isLoaded()
      Checks if grants are loaded
      boolean isMFAChecked()
      Is the MFA checked for user?
      boolean isOAuth2AuthMethod()
      Is the authentication method OAuth2?
      boolean isPanelFilterEnable()
      Is display panel filter?
      boolean isPublic()
      Is "public" user?
      boolean isRightToLeft()
      Get the user language direction (not yet implemented)
      boolean isSAMLAuthMethod()
      Is the authentication method SAML?
      boolean isSystem()
      Is "system" user?
      boolean isSystemAdmin()
      Is "system" user (alias to isSystem)?
      long lastUsage​(boolean update)
      Not used : System full GC is managed after the expiration of user session
      void limitLicenseRights()
      Allow access but with restricted rights to update the LicenseKey only
      boolean logActivity()
      Are the user's activities (redo log) logged?
      boolean logDebug()
      Are the debug events logged ?
      boolean logDocument()
      Are the document events logged?
      boolean logError()
      Are the error events logged?
      boolean logFatal()
      Are the fatal events logged?
      boolean logInfo()
      Are the info events logged?
      boolean logObject()
      Are the object events logged?
      boolean logSession()
      Are the session login/logout logged?
      boolean logWarning()
      Are the warning events logged?
      void newData()
      New empty GrantData
      static java.lang.String notGranted​(Grant g)
      Translated not granted message
      java.lang.String prepareExpression​(java.lang.String content)
      Prepare an expression by processing token substitutions: (see prepareExpression for details on tokens)
      java.lang.String prepareExpression​(java.lang.String content, java.lang.String sep, boolean inlineValues, boolean front)
      Prepare an expression by processing token substitutions:
      - [APPLICATION] or [APPNAME] : application name
      - [ENCODING] : application encoding
      - [GRANT] : user grant
      - [LOGIN] : user login
      - [USERID] : user row ID
      - [LANG] : user language
      - [HASRESP:<group>] or [HASRESPONSIBILITY:<group>] : check if user has specified responsibility
      - [TEXT:<code>] : value of a text
      - [SYSPARAM:<name>] : value of a system parameter (without surrounding quotes because a system parameter can be numeric)
      java.lang.String prepareSQL​(java.lang.String sql)
      Prepares a SQL statement applying following token substitutions:
      - [login] : user login (surrounded by SQL quotes)
      - [userid] : user row ID (surrounded by SQL quotes)
      - [lang] : user language (surrounded by SQL quotes)
      - [sysparam:<name>] : system parameter value (surrounded by SQL quotes)
      - [text:<code>] : text value (surrounded by SQL quotes)
      void recordUsage()
      Record usage (usage count and last usage date)
      void removeAccessCreate​(java.lang.String obj)
      Alias to delAccessCreate
      void removeAccessDelete​(java.lang.String obj)
      Alias to delAccessDelete
      void removeAccessObject​(java.lang.String obj)
      Alias to delAccessObject
      void removeAccessRead​(java.lang.String obj)
      Alias to delAccessObject
      void removeAccessUpdate​(java.lang.String obj)
      Alias to delAccessUpdate
      java.io.Serializable removeObjectParameter​(ObjectCore obj, java.lang.String name)
      Unsets an object parameter
      void removeObjectParameters​(ObjectCore obj, java.lang.String prefix)
      Unsets object parameters starting with prefix
      java.io.Serializable removeParameter​(java.lang.String name)
      Remove a session system parameter
      void removeResources()
      Remove all resources
      void removeResources​(java.lang.String objectClass, java.lang.String objId, boolean clearCache)
      Remove resources
      void removeSharedScript​(java.lang.String name)
      Remove a shared code
      void removeSharedScripts()
      Remove all shared codes
      void setAbout​(boolean b)
      Set whether about info is enabled
      void setAjaxKey​(java.lang.String ajaxkey)
      Set the user Ajax key
      void setAPIInterface​(boolean b)
      Deprecated. 
      void setAuthToken​(java.lang.String token)
      Set the user authentication token
      void setAuthTokenExpiry​(long time)
      Set the user authentication token expiry time
      void setBeanDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setSrcDir
      void setBinDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setBinDir
      void setCacheDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setCacheDir
      void setCellPhoneNumber​(java.lang.String num)
      Set the user's cell phone number (alias to setMobilePhoneNumber)
      void setClassesDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setClassesDir
      void setClientTabId​(java.lang.String tabId)
      Set Grant in a client UI tab
      void setCompletion​(boolean b)
      Set whether the completion feature is enabled
      void setContentDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setContentDir
      void setConvertWildcards​(boolean convert)
      Set wildcard as converted (from * and ? to SQL's % and _)
      void setData​(com.simplicite.util.engine.GrantData d)
      Set the GrantData infos
      void setDateFormat​(java.lang.String df)
      Set the user date format
      void setDateFormat​(java.lang.String code, java.lang.String lang)
      Set date format
      void setDisposition​(Disposition d)
      Set disposition
      void setDocDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setDocDir
      void setDocDirMax​(long n)
      Deprecated.
      Use Platform.setDocDirMax
      void setDocLocalDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setDocLocalDir
      void setEasyModeClearCache​(boolean c)
      Deprecated, for removal: This API element is subject to removal in a future version. 
      void setEmail​(java.lang.String email)
      Set the user's e-mail address
      void setExportDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setExportDir
      void setExternalDocsDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setExternalDocsDir
      void setFirstName​(java.lang.String firstname)
      Set the user's first name
      void setFlagParameter​(java.lang.String name, boolean value)
      Sets a yes/no flag session system parameter
      void setForcedChangePassword​(boolean f)
      Set forced change password
      void setGITInterface​(boolean b)
      Deprecated. 
      void setHashAlgorithm​(java.lang.String p)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use SystemParameters.setHashEncoding
      void setHashEncoding​(java.lang.String p)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Use SystemParameters.setHashEncoding
      void setHome​(View home)
      Set the current home page
      void setHomePhoneNumber​(java.lang.String num)
      Set the user's home phone number
      void setHtmlEditor​(boolean b)
      Set whether the HTML editor is enabled
      void setHybridApp​(boolean inapp)
      Hybrid application on mobile device (cordova)
      void setImportDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setImportDir
      void setIndexDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setIndexDir
      void setInterfaces​(com.simplicite.util.engine.GrantInterface g, com.simplicite.util.engine.ObjectInterface o, ProcessusInterface p)
      Set the invocation interfaces (Local EJB, Remote EJB, WebService, Direct)
      void setInterfaces​(Globals.InterfaceType interfaceType)
      Set the invocation interfaces (Local EJB, Remote EJB, WebService, Direct)
      void setIOInterface​(boolean b)
      Deprecated. 
      void setJavadocDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setJavadocDir
      void setLang​(java.lang.String lang)
      Set the user's language to display the UI
      void setLangPreference​(java.lang.String lang)
      Set the user's preferred language
      void setLanguages​(java.util.List<java.lang.String> langs)
      Set available languages for the user (null means all known languages)
      void setLastName​(java.lang.String lastname)
      Set the user's last name
      void setLibsDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setLibsDir
      void setLogDebug​(boolean b)
      Enable/disable the debug events logging
      void setLogDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setLogDir
      void setLogDocument​(boolean b)
      Enable/disable the document events logging
      void setLogError​(boolean b)
      Enable/disable the error events logging
      void setLogFatal​(boolean b)
      Enable/disable the fatal events logging
      void setLogin​(java.lang.String login)
      Set the user login
      void setLogInfo​(boolean b)
      Enable/disable the info events logging
      void setLogObject​(boolean b)
      Enable/disable the object events logging
      void setLogWarning​(boolean b)
      Enable/disable the warning events logging
      void setMavenDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setMavenDir
      void setMaxRows​(int n)
      Set the list page maximum size (for paginated searches)
      void setMaxUploadSize​(long s)
      Set upload size limit (in Mb)
      void setMenu​(MenuItem menu)
      Set the main menu
      void setMFAChecked​(boolean checked)
      Set the MFA check status for user
      void setMFAMethod​(java.lang.String method)
      Set the user's MFA method
      void setMFASettings​(java.lang.String settings)
      Set the user's MFA settings
      void setMinRows​(int n)
      Set the list page minimum size (for paginated searches)
      void setMobilePhoneNumber​(java.lang.String num)
      Set the user's mobile phone number
      void setNumberFormat​(java.lang.String nf)
      Set the user number format
      void setNumberFormat​(java.lang.String code, java.lang.String lang)
      Set number format
      void setObjectParameter​(ObjectCore obj, java.lang.String name, java.io.Serializable value)
      Sets one object session parameter (useful, for instance, to store data thru different pages and contexts)
      void setPanelCharMax​(int n)
      Set panels (tabs) max width in char
      void setPanelFilter​(boolean b)
      Set display the panel filter
      void setParameter​(java.lang.String name, java.io.Serializable obj)
      Sets one object session parameter (useful, for instance, to store data thru different pages and contexts)
      void setParameter​(java.lang.String name, java.lang.String value)
      Sets a text session system parameter (useful, for instance, to store data thru different pages and contexts)
      void setPassword​(java.lang.String password)
      Set the user password
      void setPicture​(DocumentDB doc)
      Set the user's picture document
      void setProjectDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setProjectDir
      void setRailway​(int p)
      Set the railway size to display in the navigation bar
      void setRecycleBinDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setRecycleBinDir
      void setRespList​(java.lang.String s)
      Set all groups granted in the user session in a text format (separated with comma)
      void setSessionId​(java.lang.String id)
      Store the user SessionId (web or technical)
      void setShortcuts​(java.util.List<Shortcut> shortcuts)
      Set all shortcuts
      void setShowNavigator​(boolean p)
      Set whether the user needs the navigation bar
      void setSourcesDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setSourcesDir
      void setSrcDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setSrcDir
      void setStatus​(int status)
      Set the user status
      void setSubPackage​(java.lang.String sp)
      Set subpackage of specific classes
      void setTimeZone​(java.util.TimeZone tz)
      Set the user time zone
      void setTimeZoneID​(java.lang.String zoneID)
      Set the user time zone
      void setTmpDir​(java.lang.String dir)
      Deprecated.
      Use Platform.setTmpDir
      void setTreeView​(java.lang.String name, TreeView treeview)
      Set tree view
      void setUserId​(int id)
      Set the user unique ID (row_id from m_user) from integer
      void setUserModuleId​(java.lang.String id)
      Set the user Module ID
      void setUserUniqueId​(java.lang.String id)
      Set the user unique ID (row_id from m_user) from string
      void setWindowTitle​(java.lang.String title)
      Set the window title
      void setWorkPhoneNumber​(java.lang.String num)
      Set the user's work phone number
      boolean showNavigator()
      The user needs the navigation bar ?
      java.lang.String T​(java.lang.String code)
      Get translated text value for specified code (in current user's language)
      java.lang.String T​(java.lang.String code, boolean plural)
      Get translated text value for specified code.
      java.lang.String T​(java.lang.String code, java.lang.String def)
      Get translated text value for specified code (in current user's language) or default
      java.lang.String toFormattedBoolean​(java.lang.String serviceBoolean)
      Convert a service boolean to a formatted boolean
      java.lang.String toFormattedDate​(java.lang.String serviceDate)
      Convert a service date to a formatted date
      java.lang.String toFormattedDatetime​(java.lang.String serviceDatetime)
      Convert a service date time to a formatted date time
      java.lang.String toFormattedFloat​(java.lang.String serviceFloat, int size, int precision)
      Convert a service float to a formatted float
      java.lang.String toFormattedFloat​(java.math.BigDecimal serviceFloat, int size, int precision)
      Convert a service float to a formatted float
      java.lang.String toFormattedTime​(java.lang.String serviceTime)
      Convert a service time to a formatted time
      org.json.JSONObject toJSONObject()
      Generates a JSON object representation of grant
      org.json.JSONObject toJSONObject​(boolean resps, boolean sysparams)
      Generates a JSON object representation of grant
      java.lang.String toServiceDate​(java.lang.String formattedDate)
      Convert a formatted date to a service date
      java.lang.String toServiceDatetime​(java.lang.String formattedDatetime)
      Convert a formatted date time to a service date time
      java.lang.String toServiceFloat​(java.lang.String formattedFloat)
      Convert a formatted float to a service float
      java.lang.String toServiceTime​(java.lang.String formattedTime)
      Convert a formatted time to a service time
      java.lang.String toString()
      Generates a string representation of the grant
      java.lang.String toString​(boolean resps, boolean sysparams)
      Generates a string representation of the grant
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • FUNCTION_CREATE

        public static final char FUNCTION_CREATE
        Create function
        See Also:
        Constant Field Values
      • FUNCTION_UPDATE

        public static final char FUNCTION_UPDATE
        Update function
        See Also:
        Constant Field Values
      • FUNCTION_DELETE

        public static final char FUNCTION_DELETE
        Delete function
        See Also:
        Constant Field Values
      • FUNCTION_ALL

        public static final java.lang.String FUNCTION_ALL
        Delete function
      • FUNCTION_ACTION

        public static final char FUNCTION_ACTION
        Action function
        See Also:
        Constant Field Values
      • STATUS_INACTIVE

        public static final int STATUS_INACTIVE
        Inactive status
        See Also:
        Constant Field Values
      • STATUS_WEBSERVICES

        public static final int STATUS_WEBSERVICES
        Webservices only status
        See Also:
        Constant Field Values
      • USER_INACTIVE

        public static final java.lang.String USER_INACTIVE
        Inactive user status
      • USER_ACTIVE

        public static final java.lang.String USER_ACTIVE
        Active user status
      • USER_PENDING

        public static final java.lang.String USER_PENDING
        Pending user status
      • USER_WEBSERVICES

        public static final java.lang.String USER_WEBSERVICES
        Webservices only user statsus
      • SYSTEM_ADMIN_SESSION

        public static final java.lang.String SYSTEM_ADMIN_SESSION
        System admin pseudo-session ID
        See Also:
        Constant Field Values
      • SYSTEM_PUBLIC_SESSION

        public static final java.lang.String SYSTEM_PUBLIC_SESSION
        Public pseudo-session ID
        See Also:
        Constant Field Values
      • API_SESSION_PREFIX

        public static final java.lang.String API_SESSION_PREFIX
        API pseudo-session IDs prefix
        See Also:
        Constant Field Values
      • IO_SESSION_PREFIX

        public static final java.lang.String IO_SESSION_PREFIX
        I/O pseudo-session IDs prefix
        See Also:
        Constant Field Values
    • Constructor Detail

      • GrantCore

        public GrantCore()
    • Method Detail

      • getData

        public com.simplicite.util.engine.GrantData getData()
        Get the GrantData infos
      • setData

        public void setData​(com.simplicite.util.engine.GrantData d)
        Set the GrantData infos
      • newData

        public void newData()
        New empty GrantData
      • getLock

        public java.lang.Object getLock()
        Get the lock to be used in synchronized blocks
      • setInterfaces

        public void setInterfaces​(com.simplicite.util.engine.GrantInterface g,
                                  com.simplicite.util.engine.ObjectInterface o,
                                  ProcessusInterface p)
        Set the invocation interfaces (Local EJB, Remote EJB, WebService, Direct)
      • setInterfaces

        public void setInterfaces​(Globals.InterfaceType interfaceType)
        Set the invocation interfaces (Local EJB, Remote EJB, WebService, Direct)
        Parameters:
        interfaceType - Interface type
      • getObjectInterface

        public com.simplicite.util.engine.ObjectInterface getObjectInterface()
        Get the invocation interface for objects (Local EJB, Remote EJB, WebService, Direct)
      • getGrantInterface

        public com.simplicite.util.engine.GrantInterface getGrantInterface()
        Get the invocation interface for grants (Local EJB, Remote EJB, WebService, Direct)
      • getProcessInterface

        public ProcessusInterface getProcessInterface()
        Get the invocation interface for processes (Local EJB, Remote EJB, WebService, Direct)
      • setSessionId

        public void setSessionId​(java.lang.String id)
        Store the user SessionId (web or technical)
      • getSessionId

        public java.lang.String getSessionId()
        Get the user SessionId (web or technical)
      • setClientTabId

        public void setClientTabId​(java.lang.String tabId)
        Set Grant in a client UI tab
        Parameters:
        tabId - Browser tab Id
      • getClientTabId

        public java.lang.String getClientTabId()
        Client/browser tab Id
        Returns:
        Optional client tab Id in case of UI usage
      • setHybridApp

        public void setHybridApp​(boolean inapp)
        Hybrid application on mobile device (cordova)
        Parameters:
        inapp - true when the application is started thru hybrid engine
      • isHybridApp

        public boolean isHybridApp()
        Hybrid application on mobile device (cordova)
        Returns:
        true when the application is started thru hybrid engine
      • getScriptInterpreterEngineName

        public java.lang.String getScriptInterpreterEngineName()
        Get script interpreter engine name
      • getScriptInterpreter

        public com.simplicite.util.engine.ScriptInterpreter getScriptInterpreter()
        Get script interpreter for the user session
      • prepareExpression

        public java.lang.String prepareExpression​(java.lang.String content)
                                           throws ScriptException
        Prepare an expression by processing token substitutions: (see prepareExpression for details on tokens)
        Parameters:
        content - Script, template or expression including tokens to substitute
        Throws:
        ScriptException
      • prepareExpression

        public java.lang.String prepareExpression​(java.lang.String content,
                                                  java.lang.String sep,
                                                  boolean inlineValues,
                                                  boolean front)
                                           throws ScriptException
        Prepare an expression by processing token substitutions:
        - [APPLICATION] or [APPNAME] : application name
        - [ENCODING] : application encoding
        - [GRANT] : user grant
        - [LOGIN] : user login
        - [USERID] : user row ID
        - [LANG] : user language
        - [HASRESP:<group>] or [HASRESPONSIBILITY:<group>] : check if user has specified responsibility
        - [TEXT:<code>] : value of a text
        - [SYSPARAM:<name>] : value of a system parameter (without surrounding quotes because a system parameter can be numeric)
        Parameters:
        content - Script, template or expression including tokens to substitute
        sep - separator for String
        inlineValues - Replace with explicit value or with API. Ex: [VALUE:input] will be replaced with explicit value of field, or replaced by obj.getInput(input).getValue()
        Returns:
        Prepared expression
        Throws:
        ScriptException
      • evalExpression

        public java.lang.Object evalExpression​(java.lang.String expr)
                                        throws ScriptException
        Prepare and evaluate an expression (see prepareExpression for details on tokens)
        Parameters:
        expr - Expression
        Returns:
        Evaluation result
        Throws:
        ScriptException
      • evalExpression

        public java.lang.Object evalExpression​(java.lang.String expr,
                                               java.util.Map<java.lang.String,​java.lang.Object> in,
                                               java.util.Map<java.lang.String,​java.lang.Object> out)
                                        throws ScriptException
        Prepare and evaluate an expression (see prepareExpression for details on tokens)
        Parameters:
        expr - Expression
        in - Input variables to set before script evaluation
        out - Output variables to retrieve after script evaluation
        Returns:
        Script evaluation result
        Throws:
        ScriptException
      • evalURLExpression

        public java.lang.String evalURLExpression​(java.lang.String url)
                                           throws ScriptException
        Prepare and evaluate an URL expression (see prepareExpression for details on tokens)
        Parameters:
        url - URL
        Returns:
        Evaluated URL
        Throws:
        ScriptException
      • evalExpressionAsString

        public java.lang.String evalExpressionAsString​(java.lang.String expr)
                                                throws ScriptException
        Prepare and evaluate an expression token (enclosed in [EXPR:]) as a string (see prepareExpression for details on tokens).
        Parameters:
        expr - Expression token
        Returns:
        Evaluated expression token
        Throws:
        ScriptException
      • prepareSQL

        public java.lang.String prepareSQL​(java.lang.String sql)
        Prepares a SQL statement applying following token substitutions:
        - [login] : user login (surrounded by SQL quotes)
        - [userid] : user row ID (surrounded by SQL quotes)
        - [lang] : user language (surrounded by SQL quotes)
        - [sysparam:<name>] : system parameter value (surrounded by SQL quotes)
        - [text:<code>] : text value (surrounded by SQL quotes)
        Parameters:
        sql - SQL including tokens to substitute
        Returns:
        Prepared SQL statement
      • getCacheKey

        public java.lang.String getCacheKey​(Grant g)
        Get grant unique cache key
        Specified by:
        getCacheKey in interface com.simplicite.util.engine.CacheInterface
        Parameters:
        g - Grant
        Returns:
        Unique cache key
      • isJavaImplemented

        public boolean isJavaImplemented()
        Is implemented in Java
        Specified by:
        isJavaImplemented in interface com.simplicite.util.engine.CacheInterface
        Returns:
        True if implemented in Java
      • getName

        public java.lang.String getName()
        Get name
        Specified by:
        getName in interface com.simplicite.util.engine.CacheInterface
        Returns:
        Name forced to Grant
      • enableGC

        public void enableGC​(boolean enabled)
        Not used : System full GC is managed after the expiration of user session
        Specified by:
        enableGC in interface com.simplicite.util.engine.CacheInterface
        Parameters:
        enabled - false to disable internal GC
      • lastUsage

        public long lastUsage​(boolean update)
        Not used : System full GC is managed after the expiration of user session
        Specified by:
        lastUsage in interface com.simplicite.util.engine.CacheInterface
        Parameters:
        update - true to update the last usage date of object
        Returns:
        last usage date in milliseconds
      • garbageCollection

        public boolean garbageCollection()
        Not used : System full GC is managed after the expiration of user session
        Specified by:
        garbageCollection in interface com.simplicite.util.engine.CacheInterface
        Returns:
        True if something has been cleared
      • getMenu

        public MenuItem getMenu()
        Get the main menu
        Returns:
        Root item
      • setMenu

        public void setMenu​(MenuItem menu)
        Set the main menu
        Parameters:
        menu - Root item
      • getMenuItems

        public java.util.List<MenuItem> getMenuItems​(java.lang.String domain)
        Get items in a domain
        Parameters:
        domain - Domain name
        Returns:
        List of items or null
      • getHome

        public View getHome()
        Get the current home page
        Returns:
        Current home page
      • setHome

        public void setHome​(View home)
        Set the current home page
        Parameters:
        home - Current home page
      • getScope

        public java.lang.String getScope()
        Get the current scope if exists
        Returns:
        Current scope or null
      • getHomeName

        public java.lang.String getHomeName()
        Get the current home page name if exists
        Returns:
        Current home page name or null
      • getHomePages

        public java.util.List<java.lang.String> getHomePages()
        Get all granted home pages
        Returns:
        List of granted home pages
      • addHomePage

        public void addHomePage​(java.lang.String viewName)
        Add home page view
        Parameters:
        viewName - View name
      • getObjectViews

        public java.util.Map<java.lang.String,​java.util.List<View>> getObjectViews()
        Get the views associated to objects
        Returns:
        Map of views associated to objects
      • getSimpleView

        public View getSimpleView​(java.lang.String name)
        Get a standalone view
        Parameters:
        name - View name
        Returns:
        View
      • getSimpleViews

        public java.util.Map<java.lang.String,​View> getSimpleViews()
        Get all standalone views
        Returns:
        Map of standalone views
      • getDomains

        public java.util.List<java.lang.String> getDomains()
        Get all granted domains
        Returns:
        List of granted domains
      • getObjects

        public java.util.List<java.lang.String> getObjects()
        Get all granted objects
        Returns:
        List of granted objects
      • getNew

        @Deprecated(forRemoval=false,
                    since="4.0")
        public final java.util.Map<java.lang.String,​java.lang.String> getNew()
        Deprecated.
        Use getCreatable
      • getCreatable

        public java.util.Map<java.lang.String,​java.lang.String> getCreatable()
        Get granted objects for creation
        Returns:
        Map of granted objects for creation
      • getUpdatable

        public java.util.Map<java.lang.String,​java.lang.String> getUpdatable()
        Get granted objects for update
        Returns:
        Map of granted objects for updates
      • getDel

        @Deprecated(forRemoval=false,
                    since="4.0")
        public final java.util.Map<java.lang.String,​java.lang.String> getDel()
        Deprecated.
        Use getDeletable
      • getDeletable

        public java.util.Map<java.lang.String,​java.lang.String> getDeletable()
        Get granted objects for deletion
        Returns:
        Map of granted objects for deletion
      • getObjectActions

        public java.util.Map<java.lang.String,​java.util.List<Action>> getObjectActions()
        Get granted objects for external actions
        Returns:
        List of granted objects
      • getLogin

        public java.lang.String getLogin()
        Get the user login
        Returns:
        Login
      • setLogin

        public void setLogin​(java.lang.String login)
        Set the user login
        Parameters:
        login - Login
      • getPassword

        public java.lang.String getPassword()
        Get the user password
        Returns:
        Password
      • setPassword

        public void setPassword​(java.lang.String password)
        Set the user password
        Parameters:
        password - Password
      • getAuthToken

        public java.lang.String getAuthToken()
        Get the user authentication token
        Returns:
        Token
      • setAuthToken

        public void setAuthToken​(java.lang.String token)
        Set the user authentication token
        Parameters:
        token - Token
      • getAjaxKey

        public java.lang.String getAjaxKey()
        Set the user Ajax key
        Returns:
        Ajax key
      • setAjaxKey

        public void setAjaxKey​(java.lang.String ajaxkey)
        Set the user Ajax key
        Parameters:
        ajaxkey - Ajax key
      • getAuthTokenExpiry

        public long getAuthTokenExpiry()
        Get the user authentication token expiry time
        Returns:
        Token expiry time
      • setAuthTokenExpiry

        public void setAuthTokenExpiry​(long time)
        Set the user authentication token expiry time
        Parameters:
        time - Token expiry time
      • getRandomPassword

        public static java.lang.String getRandomPassword​(int length)
        Get random password
        Parameters:
        length - Length (cannot be less than Globals.DEFAULT_PASSWORD_LENGTH)
        Returns:
        A random password of specified length with at least a number, an uppercase and a lowercase letter
      • setUserUniqueId

        public void setUserUniqueId​(java.lang.String id)
        Set the user unique ID (row_id from m_user) from string
      • setUserId

        public void setUserId​(int id)
        Set the user unique ID (row_id from m_user) from integer
      • getUserUniqueId

        public java.lang.String getUserUniqueId()
        Get the user unique ID as string
      • getUserId

        public int getUserId()
        Get the user unique ID as integer
      • setLang

        public void setLang​(java.lang.String lang)
        Set the user's language to display the UI
      • getLang

        public java.lang.String getLang()
        Get the user's language
      • setLangPreference

        public void setLangPreference​(java.lang.String lang)
        Set the user's preferred language
      • getLangPreference

        public java.lang.String getLangPreference()
        Get the user's preferred language
      • setLanguages

        public void setLanguages​(java.util.List<java.lang.String> langs)
        Set available languages for the user (null means all known languages)
      • getLanguages

        public java.util.List<java.lang.String> getLanguages()
        Get available languages for the user (default all known languages)
      • isRightToLeft

        public boolean isRightToLeft()
        Get the user language direction (not yet implemented)
      • setUserModuleId

        public void setUserModuleId​(java.lang.String id)
        Set the user Module ID
      • getUserModuleId

        public java.lang.String getUserModuleId()
        Get the user Module ID
      • setMinRows

        public void setMinRows​(int n)
        Set the list page minimum size (for paginated searches)
        Parameters:
        n - List page minimum size
      • getMinRows

        public int getMinRows()
        Get the list page minimum size (for paginated searches)
        Returns:
        List page minimum size
      • setMaxRows

        public void setMaxRows​(int n)
        Set the list page maximum size (for paginated searches)
        Parameters:
        n - List page maximum size
      • getMaxRows

        public int getMaxRows()
        Get the list maximum size (for paginated search)
        Returns:
        List page maximum size
      • getResp

        public java.util.Map<java.lang.String,​GroupDB> getResp()
        Get all groups granted in the user session
      • getRespList

        public java.lang.String getRespList()
        Get all groups granted in the user session in a text format (separated with comma)
      • setRespList

        public void setRespList​(java.lang.String s)
        Set all groups granted in the user session in a text format (separated with comma)
      • setFirstName

        public void setFirstName​(java.lang.String firstname)
        Set the user's first name
        Parameters:
        firstname - User's first name
      • getFirstName

        public java.lang.String getFirstName()
        Get the user's first name
        Returns:
        User's first name
      • setLastName

        public void setLastName​(java.lang.String lastname)
        Set the user's last name
        Parameters:
        lastname - User's last name
      • getLastName

        public java.lang.String getLastName()
        Get the user's last name
        Returns:
        User's last name
      • getFullName

        public java.lang.String getFullName()
        Get the user's full name (or the login if unknown)
        Returns:
        User's full name
      • setEmail

        public void setEmail​(java.lang.String email)
        Set the user's e-mail address
        Parameters:
        email - User's e-mail address
      • getEmail

        public java.lang.String getEmail()
        Get the user's email address
        Returns:
        User's email address
      • setWorkPhoneNumber

        public void setWorkPhoneNumber​(java.lang.String num)
        Set the user's work phone number
        Parameters:
        num - User's work phone number
      • getWorkPhoneNumber

        public java.lang.String getWorkPhoneNumber()
        Get the user's work phone number
        Returns:
        User's work phone number
      • setHomePhoneNumber

        public void setHomePhoneNumber​(java.lang.String num)
        Set the user's home phone number
        Parameters:
        num - User's home phone number
      • getHomePhoneNumber

        public java.lang.String getHomePhoneNumber()
        Get the user's home phone number
        Returns:
        User's home phone number
      • setMobilePhoneNumber

        public void setMobilePhoneNumber​(java.lang.String num)
        Set the user's mobile phone number
        Parameters:
        num - User's mobile phone number
      • getMobilePhoneNumber

        public java.lang.String getMobilePhoneNumber()
        Get the user's mobile phone number
        Returns:
        User's mobile phone number
      • getCellPhoneNumber

        public java.lang.String getCellPhoneNumber()
        Get the user's cell phone number (alias to getMobilePhoneNumber)
        Returns:
        User's cell phone number
      • setCellPhoneNumber

        public void setCellPhoneNumber​(java.lang.String num)
        Set the user's cell phone number (alias to setMobilePhoneNumber)
        Parameters:
        num - User's cell phone number
      • setPicture

        public void setPicture​(DocumentDB doc)
        Set the user's picture document
        Parameters:
        doc - User's picture document
      • getPicture

        public DocumentDB getPicture()
        Get the user picture document
        Returns:
        User's picture document
      • setStatus

        public void setStatus​(int status)
        Set the user status
        Parameters:
        status - User's status
      • getStatus

        public int getStatus()
        Get the user's status
        Returns:
        User's status
      • getText

        public java.util.Map<java.lang.String,​java.lang.String> getText()
        Get all the translated text values (in current user's language)
      • T

        public java.lang.String T​(java.lang.String code)
        Get translated text value for specified code (in current user's language)
      • T

        public java.lang.String T​(java.lang.String code,
                                  java.lang.String def)
        Get translated text value for specified code (in current user's language) or default
      • T

        public java.lang.String T​(java.lang.String code,
                                  boolean plural)
        Get translated text value for specified code. Value must match single|plural
      • getText

        public final java.lang.String getText​(java.lang.String code)
        Same as T
      • addText

        public void addText​(java.lang.String code,
                            java.lang.String value)
        Add a translated text
        Parameters:
        code - Code
        value - text value
      • notGranted

        public static java.lang.String notGranted​(Grant g)
        Translated not granted message
        Parameters:
        g - Optional grant (defaults to system admin grant)
        Returns:
        Translated message
      • setNumberFormat

        public void setNumberFormat​(java.lang.String nf)
        Set the user number format
        Parameters:
        nf - Number format (DC, SC, CD with D=dot C=comma S=space)
      • setNumberFormat

        public void setNumberFormat​(java.lang.String code,
                                    java.lang.String lang)
        Set number format
        Parameters:
        code - NUM_FORMAT code (DC, SC, CD with D=dot C=comma S=space)
        lang - user language
      • getNumberFormat

        public java.lang.String getNumberFormat()
        User number format
        Returns:
        DC (1.234.567,89), SC (1 234 567,89) or CD (1,234,567.89)
      • setDateFormat

        public void setDateFormat​(java.lang.String df)
        Set the user date format
        Parameters:
        df - Date format (ex DD/MM/YYYY)
      • setDateFormat

        public void setDateFormat​(java.lang.String code,
                                  java.lang.String lang)
        Set date format
        Parameters:
        code - DATE_FORMAT code (YMD, DMY, MDY, CHF)
        lang - user language
      • getDateFormat

        public java.lang.String getDateFormat()
        User date format (ex MM/DD/YYYY)
      • setTimeZoneID

        public void setTimeZoneID​(java.lang.String zoneID)
        Set the user time zone
        Parameters:
        zoneID - zone ID short or long name (ex: GMT or Europe/Paris)
      • getTimeZoneID

        public java.lang.String getTimeZoneID()
        User time zone ID
      • setTimeZone

        public void setTimeZone​(java.util.TimeZone tz)
        Set the user time zone
      • getTimeZone

        public java.util.TimeZone getTimeZone()
        Get the user time zone
      • toServiceDate

        public java.lang.String toServiceDate​(java.lang.String formattedDate)
        Convert a formatted date to a service date
      • toFormattedDate

        public java.lang.String toFormattedDate​(java.lang.String serviceDate)
        Convert a service date to a formatted date
      • toServiceTime

        public java.lang.String toServiceTime​(java.lang.String formattedTime)
        Convert a formatted time to a service time
      • toFormattedTime

        public java.lang.String toFormattedTime​(java.lang.String serviceTime)
        Convert a service time to a formatted time
      • toServiceDatetime

        public java.lang.String toServiceDatetime​(java.lang.String formattedDatetime)
        Convert a formatted date time to a service date time
      • toFormattedDatetime

        public java.lang.String toFormattedDatetime​(java.lang.String serviceDatetime)
        Convert a service date time to a formatted date time
      • toServiceFloat

        public java.lang.String toServiceFloat​(java.lang.String formattedFloat)
        Convert a formatted float to a service float
      • toFormattedFloat

        public java.lang.String toFormattedFloat​(java.lang.String serviceFloat,
                                                 int size,
                                                 int precision)
        Convert a service float to a formatted float
      • toFormattedFloat

        public java.lang.String toFormattedFloat​(java.math.BigDecimal serviceFloat,
                                                 int size,
                                                 int precision)
        Convert a service float to a formatted float
      • toFormattedBoolean

        public java.lang.String toFormattedBoolean​(java.lang.String serviceBoolean)
        Convert a service boolean to a formatted boolean
      • getParameters

        public java.util.Map<java.lang.String,​java.io.Serializable> getParameters()
        Get all parameters
        Returns:
        Parameters map
      • hasParameter

        public boolean hasParameter​(java.lang.String name)
        Check if a text session parameter is set
        Parameters:
        name - Parameter name
        Returns:
        True is parameter is set
      • getParameter

        public java.lang.String getParameter​(java.lang.String name)
        Gets a text session parameter
        Parameters:
        name - Parameter name
        Returns:
        Session parameter value
      • getParameter

        public java.lang.String getParameter​(java.lang.String name,
                                             java.lang.String def)
        Gets a text session parameter
        Parameters:
        name - Parameter name
        def - Default value
        Returns:
        Session parameter value
      • getObjectParameter

        public java.lang.Object getObjectParameter​(java.lang.String name)
        Gets one object session parameter
        Parameters:
        name - Parameter name
        Returns:
        Session parameter object
      • getObjectParameter

        public java.lang.Object getObjectParameter​(java.lang.String name,
                                                   java.lang.Object def)
        Gets one object session parameter
        Parameters:
        name - Parameter name
        def - Default value
        Returns:
        Session parameter object
      • getFlagParameter

        public boolean getFlagParameter​(java.lang.String name)
        Gets a flag session system parameter as boolean (false if absent)
        Parameters:
        name - Parameter name
        Returns:
        boolean value
      • getFlagParameter

        public boolean getFlagParameter​(java.lang.String name,
                                        boolean def)
        Gets a flag session system parameter as boolean
        Parameters:
        name - Parameter name
        def - Default value
        Returns:
        boolean value
      • getBooleanParameter

        public boolean getBooleanParameter​(java.lang.String name)
        Gets an boolean session system parameter as boolean (false if absent)
        Parameters:
        name - Parameter name
        Returns:
        boolean value
      • getBooleanParameter

        public boolean getBooleanParameter​(java.lang.String name,
                                           boolean def)
        Gets an boolean session system parameter as boolean
        Parameters:
        name - Parameter name
        Returns:
        boolean value
      • getIntParameter

        public int getIntParameter​(java.lang.String name)
        Gets an integer session system parameter as boolean (0 if absent)
        Parameters:
        name - Parameter name
        Returns:
        integer value
      • getIntParameter

        public int getIntParameter​(java.lang.String name,
                                   int def)
        Gets an integer session system parameter as boolean
        Parameters:
        name - Parameter name
        def - Default value
        Returns:
        integer value
      • getLongParameter

        public long getLongParameter​(java.lang.String name,
                                     long def)
        Gets an long integer session system parameter as boolean
        Parameters:
        name - Parameter name
        def - Default value
        Returns:
        integer value
      • getLongParameter

        public long getLongParameter​(java.lang.String name)
        Gets an long integre session system parameter as boolean (0 if absent)
        Parameters:
        name - Parameter name
        Returns:
        integer value
      • getJSONObjectParameter

        public org.json.JSONObject getJSONObjectParameter​(java.lang.String name)
        Gets an JSON object string session system parameter as JSON object
        Parameters:
        name - Parameter name
        Returns:
        JSON object or null
      • getJSONObjectParameter

        public org.json.JSONObject getJSONObjectParameter​(java.lang.String name,
                                                          java.lang.String def)
        Gets an JSON object string session system parameter as JSON object
        Parameters:
        name - Parameter name
        def - Default JSON string value
        Returns:
        JSON object
      • getJSONObjectParameter

        public org.json.JSONObject getJSONObjectParameter​(java.lang.String name,
                                                          org.json.JSONObject def)
        Gets an JSON object string session system parameter as JSON object
        Parameters:
        name - Parameter name
        def - Default JSONobject value
        Returns:
        JSON object
      • getJSONArrayParameter

        public org.json.JSONArray getJSONArrayParameter​(java.lang.String name)
        Gets an JSON array string session system parameter as JSON array
        Parameters:
        name - Parameter name
        Returns:
        JSON array or null
      • getJSONArrayParameter

        public org.json.JSONArray getJSONArrayParameter​(java.lang.String name,
                                                        java.lang.String def)
        Gets an JSON array string session system parameter as JSON array
        Parameters:
        name - Parameter name
        def - Default JSON string value
        Returns:
        JSON array
      • getJSONArrayParameter

        public org.json.JSONArray getJSONArrayParameter​(java.lang.String name,
                                                        org.json.JSONArray def)
        Gets an JSON array string session system parameter as JSON array
        Parameters:
        name - Parameter name
        def - Default JSONArray value
        Returns:
        JSON array
      • setParameter

        public void setParameter​(java.lang.String name,
                                 java.lang.String value)
        Sets a text session system parameter (useful, for instance, to store data thru different pages and contexts)
        Parameters:
        name - Parameter name
        value - Value
      • setParameter

        public void setParameter​(java.lang.String name,
                                 java.io.Serializable obj)
        Sets one object session parameter (useful, for instance, to store data thru different pages and contexts)
        Parameters:
        name - Parameter name
        obj - Any object, if null the parameter name is removed
      • removeParameter

        public java.io.Serializable removeParameter​(java.lang.String name)
        Remove a session system parameter
        Parameters:
        name - Parameter name
      • setFlagParameter

        public void setFlagParameter​(java.lang.String name,
                                     boolean value)
        Sets a yes/no flag session system parameter
        Parameters:
        name - Parameter name
        value - Value (boolean value translated into "yes" or "no")
      • getParameterId

        public java.lang.String getParameterId​(java.lang.String code)
      • setObjectParameter

        public void setObjectParameter​(ObjectCore obj,
                                       java.lang.String name,
                                       java.io.Serializable value)
        Sets one object session parameter (useful, for instance, to store data thru different pages and contexts)
        Parameters:
        obj - Object
        name - Parameter name
        value - Any object, if null the parameter name is removed
      • removeObjectParameter

        public java.io.Serializable removeObjectParameter​(ObjectCore obj,
                                                          java.lang.String name)
        Unsets an object parameter
        Parameters:
        obj - Object
        name - Parameter name
        Returns:
        Serializable object if parameter exists
      • removeObjectParameters

        public void removeObjectParameters​(ObjectCore obj,
                                           java.lang.String prefix)
        Unsets object parameters starting with prefix
        Parameters:
        obj - Object
        prefix - Parameter prefix
      • getObjectParameter

        public java.lang.Object getObjectParameter​(ObjectCore obj,
                                                   java.lang.String name)
        Gets one object parameter
        Parameters:
        obj - Object
        name - Parameter name
        Returns:
        Object parameter
      • getObjectParameters

        public java.util.Map<java.lang.String,​java.io.Serializable> getObjectParameters​(ObjectCore obj)
        Gets all object parameters
        Parameters:
        obj - Object
        Returns:
        Map of parameters value
      • isLoaded

        public boolean isLoaded()
        Checks if grants are loaded
        Returns:
        true if grants have been already loaded, false otherwise
      • checkPwd

        public boolean checkPwd​(java.lang.String password)
        Check current user password
        Parameters:
        password - Password
        Returns:
        True if the given password is correct
      • isDesigner

        public boolean isDesigner()
        Is "designer" user?
        Returns:
        True if user is the "e;designer" user
      • isPublic

        public boolean isPublic()
        Is "public" user?
        Returns:
        True if user is the "public" user
      • isSystem

        public boolean isSystem()
        Is "system" user?
        Returns:
        True if user is the "system" user
      • isSystemAdmin

        public boolean isSystemAdmin()
        Is "system" user (alias to isSystem)?
        Returns:
        True if user is the "system" user
      • canUpdateSystem

        public boolean canUpdateSystem()
        Can update system modules' objects (ADMIN_SYSTEM = yes/no)
        Returns:
        True if ADMIN_SYSTEM system parameter value is yes
      • hasResponsibility

        public boolean hasResponsibility​(java.lang.String group)
        Check if the user has one responsibility
        Parameters:
        group - Group name
        Returns:
        True if the group is granted to the user
      • getActions

        public java.util.List<Action> getActions​(java.lang.String obj)
        Get all specific actions of one object
        Parameters:
        obj - Object name
        Returns:
        List of Actions
      • getActions

        public java.util.List<Action> getActions​(java.lang.String obj,
                                                 java.lang.String startsWith)
        Get all actions of one object
        Parameters:
        obj - Object name
        startsWith - Name starts with
        Returns:
        List of Actions
      • getAction

        public Action getAction​(java.lang.String obj,
                                java.lang.String name)
        Get a specific action of one object
        Parameters:
        obj - Object name
        name - Action name
        Returns:
        Action or null if not found
      • getPredefinedSearch

        public java.util.Map<java.lang.String,​java.util.List<PredefinedSearch>> getPredefinedSearch()
        Get all predefined searches
      • getPredefinedSearch

        public java.util.List<PredefinedSearch> getPredefinedSearch​(java.lang.String object)
        Get predefined searches of object
        Parameters:
        object - Object name
      • getPredefinedSearch

        public PredefinedSearch getPredefinedSearch​(java.lang.String object,
                                                    java.lang.String id)
        Get predefined searches of object
        Parameters:
        object - Object name
        id - Search row id
      • addPredefinedSearch

        public void addPredefinedSearch​(java.lang.String object,
                                        PredefinedSearch ps)
        Add a predefined search to object
        Parameters:
        object - Object name
        ps - Predefined search
      • getScriptById

        public SharedScript getScriptById​(java.lang.String scrId)
        Get a shared code for specified ID
        Parameters:
        scrId - Shared code ID
        Returns:
        Shared code
      • getSharedScript

        public SharedScript getSharedScript​(java.lang.String name)
        Get a shared code for specified code
        Parameters:
        name - Shared code name
        Returns:
        Shared code
      • addSharedScript

        public void addSharedScript​(SharedScript scr)
        Add a shared code
        Parameters:
        scr - Shared code
      • removeSharedScript

        public void removeSharedScript​(java.lang.String name)
        Remove a shared code
        Parameters:
        name - Shared code name
      • removeSharedScripts

        public void removeSharedScripts()
        Remove all shared codes
      • getResourceById

        public Resource getResourceById​(java.lang.String resId)
        Get a resource for specified resource ID
        Parameters:
        resId - Resource ID
        Returns:
        Resource or null if not exists
      • getResource

        public Resource getResource​(java.lang.String type,
                                    java.lang.String code)
        Get a disposition resource for specified code and type
        Parameters:
        type - Resource type
        code - Resource code
        Returns:
        Resource or null if not exists
      • getResource

        public Resource getResource​(java.lang.String type,
                                    java.lang.String code,
                                    java.lang.String objectClass,
                                    java.lang.String objId)
        Get a resource for specified code and type
        Parameters:
        type - Resource type (default TYPE_IMAGE)
        code - Resource code
        objectClass - Optional target object class name (ObjectInternal, ObjectExternal, ... or null for Disposition)
        objId - Optional object Id (null for Disposition)
        Returns:
        Resource or null if not exists
      • getResource

        public Resource getResource​(java.lang.String code,
                                    java.lang.String type,
                                    java.lang.String objectName)
        Get a resource for specified code, type or objectName
        Parameters:
        code - Resource code
        type - Resource type
        objectName - Object name (of disposition, internal or external object, or process)
        Returns:
        Resource or null if not exists
      • getResource

        public Resource getResource​(java.lang.String code)
        Get a resource for a specified code
        Parameters:
        code - Resource code
        Returns:
        Resource or null if not exists
      • getResources

        public java.util.Map<java.lang.String,​Resource> getResources()
        Get all resources
        Returns:
        Map of resources
      • getObjectResources

        public java.util.List<Resource> getObjectResources​(java.lang.String objectClass,
                                                           java.lang.String objId)
        Get object resources
        Parameters:
        objectClass - Target object type name (ObjectInternal, ObjectExternal, ... or null for Disposition)
        objId - Object Id (null for Disposition)
        Returns:
        List of resources
      • getResourceCodes

        public java.util.List<java.lang.String> getResourceCodes​(java.lang.String type,
                                                                 java.lang.String objectClass,
                                                                 java.lang.String objId)
        Get resource codes for specified type
        Parameters:
        type - Resource type
        objectClass - Target object type name (ObjectInternal, ObjectExternal, ... or null for Disposition)
        objId - Object Id (null for Disposition)
        Returns:
        List of resources
      • addResource

        @Deprecated(forRemoval=false,
                    since="5")
        public void addResource​(Resource res,
                                java.lang.String objectClass,
                                java.lang.String objId)
        Deprecated.
        Add a resource
        Parameters:
        res - Resource
        objectClass - Target object type name (ObjectInternal, ObjectExternal, ... or null for Disposition)
        objId - Object Id (null for Disposition)
      • addResource

        public void addResource​(Resource res,
                                java.lang.String objectClass,
                                java.lang.String objId,
                                java.lang.String objName)
        Add a resource
        Parameters:
        res - Resource
        objectClass - Target object type name (ObjectInternal, ObjectExternal, ... or null for Disposition)
        objId - Object Id (null for Disposition)
        objName - Target object name
      • removeResources

        public void removeResources​(java.lang.String objectClass,
                                    java.lang.String objId,
                                    boolean clearCache)
        Remove resources
        Parameters:
        objectClass - Target object type name (ObjectInternal, ObjectExternal, ... or null for Disposition)
        objId - Object Id (null for Disposition)
      • removeResources

        public void removeResources()
        Remove all resources
      • getTreeView

        public TreeView getTreeView​(java.lang.String name)
        Get a tree view
        Parameters:
        name - tree view name
        Returns:
        Tree view or null if not found
      • getTreeViewsOfObject

        public java.util.List<TreeView> getTreeViewsOfObject​(java.lang.String name,
                                                             boolean root)
        Get treeviews with a given object in hierarchy
        Parameters:
        name - Object name
        root - true to get only the tree where object is the root
        Returns:
        List of treeviews or null if not found
      • setTreeView

        public void setTreeView​(java.lang.String name,
                                TreeView treeview)
        Set tree view
        Parameters:
        name - Object name
        treeview - Treeview
      • getTreeViews

        public java.util.Map<java.lang.String,​TreeView> getTreeViews()
        Get all tree views
        Returns:
        Map of tree views
      • clearTreeViews

        public void clearTreeViews()
        Clear tree views
      • getShortcuts

        public java.util.List<Shortcut> getShortcuts()
        Get all shortcuts
        Returns:
        List of shortcuts
      • setShortcuts

        public void setShortcuts​(java.util.List<Shortcut> shortcuts)
        Set all shortcuts
        Parameters:
        shortcuts - List of shortcuts
      • getShortcut

        public Shortcut getShortcut​(java.lang.String name)
        Get shortcut
        Parameters:
        name - Shortcut name
        Returns:
        Shortcut
      • accessShortcut

        public boolean accessShortcut​(java.lang.String name)
        Check if the shortcut is granted to the user
        Parameters:
        name - Shortcut name
        Returns:
        True if the shortcut is granted to the user
      • getWebZones

        @Deprecated(forRemoval=true,
                    since="5")
        public java.util.List<WebZone> getWebZones()
        Deprecated, for removal: This API element is subject to removal in a future version.
        Get all web zones
        Returns:
        List of web zones
      • getWebZones

        @Deprecated(forRemoval=true,
                    since="5")
        public java.util.List<WebZone> getWebZones​(java.lang.String zone)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Get web zones for zone
        Parameters:
        zone - Zone
        Returns:
        List of web zones
      • getWebZone

        @Deprecated(forRemoval=true,
                    since="5")
        public WebZone getWebZone​(java.lang.String zone,
                                  java.lang.String name,
                                  java.lang.String lang)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Get web zone for zone, name and language
        Parameters:
        zone - Zone
        name - Name
        lang - Language
        Returns:
        Web zone
      • getWebZone

        @Deprecated(forRemoval=true,
                    since="5")
        public WebZone getWebZone​(java.lang.String zone,
                                  int order,
                                  java.lang.String lang)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Get web zone for zone, order and language
        Parameters:
        zone - Zone
        order - Order
        lang - Language
        Returns:
        Web zone
      • accessWebZone

        @Deprecated(forRemoval=true,
                    since="5")
        public boolean accessWebZone​(java.lang.String zone,
                                     int order,
                                     java.lang.String lang)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Check if the web zone is granted to the user
        Parameters:
        zone - Zone
        order - Order
        lang - Language
        Returns:
        True if the web zone is granted to the user
      • accessDomain

        public boolean accessDomain​(java.lang.String domain)
        Check if the domain is granted to the user
        Parameters:
        domain - Domain name
        Returns:
        True if the domain is granted to the user
      • accessObject

        public boolean accessObject​(java.lang.String obj)
        Check if the object is granted to the user
        Parameters:
        obj - Object name
        Returns:
        True if the object is granted to the user
      • accessIndexedObjects

        public java.util.List<java.lang.String> accessIndexedObjects()
        List of accessible objects with fulltext index
      • accessIndexedObject

        public boolean accessIndexedObject​(java.lang.String obj)
        Check if the object is granted to the user and indexable
        Parameters:
        obj - Object name
        Returns:
        True if the object is granted to the user
      • addAccessObject

        public void addAccessObject​(java.lang.String obj)
        Grant the right to read/open the object
        Parameters:
        obj - Object name
      • addAccessRead

        public void addAccessRead​(java.lang.String obj)
        Alias to addAccessObject
      • delAccessObject

        public void delAccessObject​(java.lang.String obj)
        Revoke the right to read/open the object
        Parameters:
        obj - Object name
      • removeAccessObject

        public void removeAccessObject​(java.lang.String obj)
        Alias to delAccessObject
      • delAccessRead

        public void delAccessRead​(java.lang.String obj)
        Alias to delAccessObject
      • removeAccessRead

        public void removeAccessRead​(java.lang.String obj)
        Alias to delAccessObject
      • getProcess

        public java.util.Map<java.lang.String,​java.lang.String> getProcess()
        Get the granted processes
      • accessProcess

        public boolean accessProcess​(java.lang.String process)
        Check if the process is granted to the user
        Parameters:
        process - Process name
      • addAccessProcess

        public void addAccessProcess​(java.lang.String process)
        Grant the right to read/open the process
        Parameters:
        process - Process name
      • delAccessProcess

        public void delAccessProcess​(java.lang.String process)
        Revoke the right to read/open the process
        Parameters:
        process - Process name
      • accessAction

        public boolean accessAction​(java.lang.String obj,
                                    java.lang.String action)
        Check if the action is granted to the user for a given object
        Parameters:
        obj - Object name
        action - Action name
      • enableAction

        public void enableAction​(java.lang.String obj,
                                 java.lang.String action)
        Enable one action on a given object
        Parameters:
        obj - Object name
        action - Action name
      • disableAction

        public void disableAction​(java.lang.String obj,
                                  java.lang.String action)
        Disable one action on a given object
        Parameters:
        obj - Object name
        action - Action name
      • accessCreate

        public boolean accessCreate​(java.lang.String obj)
        Check if the creation is granted to the user
        Parameters:
        obj - Object name
      • addAccessCreate

        public void addAccessCreate​(java.lang.String obj)
        Grant the object creation to the user
        Parameters:
        obj - Object name
      • delAccessCreate

        public void delAccessCreate​(java.lang.String obj)
        Revoke the object creation to the user
        Parameters:
        obj - Object name
      • removeAccessCreate

        public void removeAccessCreate​(java.lang.String obj)
        Alias to delAccessCreate
      • accessUpdate

        public boolean accessUpdate​(java.lang.String obj)
        Check if update is granted to the user
        Parameters:
        obj - Object name
      • addAccessUpdate

        public void addAccessUpdate​(java.lang.String obj)
        Grant the object update to the user
        Parameters:
        obj - Object name
      • delAccessUpdate

        public void delAccessUpdate​(java.lang.String obj)
        Revoke the object update to the user
        Parameters:
        obj - Object name
      • removeAccessUpdate

        public void removeAccessUpdate​(java.lang.String obj)
        Alias to delAccessUpdate
      • accessDelete

        public boolean accessDelete​(java.lang.String obj)
        Check if deletion is granted to the user
        Parameters:
        obj - Object name
      • delAccessDelete

        public void delAccessDelete​(java.lang.String obj)
        Revoke the object deletion to the user
        Parameters:
        obj - Object name
      • removeAccessDelete

        public void removeAccessDelete​(java.lang.String obj)
        Alias to delAccessDelete
      • addAccessDelete

        public void addAccessDelete​(java.lang.String obj)
        Grant the object deletion to the user
        Parameters:
        obj - Object name
      • changeAccess

        public boolean[] changeAccess​(java.lang.String obj,
                                      boolean create,
                                      boolean read,
                                      boolean update,
                                      boolean delete)
        Change the Create/Read/Update/Delete access to object
        Parameters:
        obj - Object name
        create - Allows creation ?
        read - Allows search/select ?
        update - Allows update ?
        delete - Allows deletion ?
        Returns:
        previous CRUD
      • changeAccess

        public boolean[] changeAccess​(java.lang.String obj,
                                      boolean[] crud)
        Change the Create/Read/Update/Delete access to object
        Parameters:
        obj - Object name
        crud - Allows Create/Read/Update/Delete ?
        Returns:
        previous CRUD
      • getVisibilities

        public java.util.Map<java.lang.String,​java.util.List<ObjectVisibility>> getVisibilities()
        Get object all visibilities
        Returns:
        Hash of all indexed visibilities per objects and types
      • getVisibility

        public java.util.List<ObjectVisibility> getVisibility​(java.lang.String object,
                                                              char type)
        Get the object's standard access visibilities
        Parameters:
        object - Object name
        type - Visibility type TYPE_READ, TYPE_UPDATE, TYPE_DELETE
        Returns:
        List of visibilities or null
      • getVisibility

        public java.util.List<ObjectVisibility> getVisibility​(java.lang.String object,
                                                              java.lang.String action)
        Get object ACTION visibilities
        Parameters:
        object - Object name
        action - External action name
        Returns:
        List of visibilities or null
      • logSession

        public boolean logSession()
        Are the session login/logout logged?
      • logActivity

        public boolean logActivity()
        Are the user's activities (redo log) logged?
      • logDebug

        public boolean logDebug()
        Are the debug events logged ?
      • setLogDebug

        public void setLogDebug​(boolean b)
        Enable/disable the debug events logging
        Parameters:
        b - Enable?
      • logInfo

        public boolean logInfo()
        Are the info events logged?
      • setLogInfo

        public void setLogInfo​(boolean b)
        Enable/disable the info events logging
        Parameters:
        b - Enable?
      • logWarning

        public boolean logWarning()
        Are the warning events logged?
      • setLogWarning

        public void setLogWarning​(boolean b)
        Enable/disable the warning events logging
        Parameters:
        b - Enable?
      • logError

        public boolean logError()
        Are the error events logged?
      • setLogError

        public void setLogError​(boolean b)
        Enable/disable the error events logging
        Parameters:
        b - Enable?
      • logFatal

        public boolean logFatal()
        Are the fatal events logged?
      • setLogFatal

        public void setLogFatal​(boolean b)
        Enable/disable the fatal events logging
        Parameters:
        b - Enable?
      • logObject

        public boolean logObject()
        Are the object events logged?
      • setLogObject

        public void setLogObject​(boolean b)
        Enable/disable the object events logging
        Parameters:
        b - Enable?
      • logDocument

        public boolean logDocument()
        Are the document events logged?
      • setLogDocument

        public void setLogDocument​(boolean b)
        Enable/disable the document events logging
        Parameters:
        b - Enable?
      • getRailway

        public int getRailway()
        Get the railway size to display in the navigation bar
      • setRailway

        public void setRailway​(int p)
        Set the railway size to display in the navigation bar
      • showNavigator

        public boolean showNavigator()
        The user needs the navigation bar ?
      • setShowNavigator

        public void setShowNavigator​(boolean p)
        Set whether the user needs the navigation bar
      • getProjectDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getProjectDir()
        Deprecated.
        Use Platform.getProjectDir
      • setProjectDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setProjectDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setProjectDir
      • getDocDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getDocDir()
        Deprecated.
        Use Platform.getDocDir
      • setDocDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setDocDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setDocDir
      • getDocLocalDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getDocLocalDir()
        Deprecated.
        Use Platform.getDocLocalDir
      • setDocLocalDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setDocLocalDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setDocLocalDir
      • getDocDirMax

        @Deprecated(forRemoval=false,
                    since="5")
        public long getDocDirMax()
        Deprecated.
        Use Platform.getDocDirMax
      • setDocDirMax

        @Deprecated(forRemoval=false,
                    since="5")
        public void setDocDirMax​(long n)
        Deprecated.
        Use Platform.setDocDirMax
      • getTmpDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getTmpDir()
        Deprecated.
        Use Platform.getTmpDir
      • setTmpDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setTmpDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setTmpDir
      • getContentDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getContentDir()
        Deprecated.
        Use Platform.getContentDir
      • setContentDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setContentDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setContentDir
      • getExternalDocsDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getExternalDocsDir()
        Deprecated.
        Use Platform.getExternalDocsDir
      • setExternalDocsDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setExternalDocsDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setExternalDocsDir
      • getLogDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getLogDir()
        Deprecated.
        Use Platform.getLogDir
      • setLogDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setLogDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setLogDir
      • getRecycleBinDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getRecycleBinDir()
        Deprecated.
        Use Platform.getRecycleBinDir
      • setRecycleBinDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setRecycleBinDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setRecycleBinDir
      • getCacheDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getCacheDir()
        Deprecated.
        Use Platform.getCacheDir
      • setCacheDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setCacheDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setCacheDir
      • getImportDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getImportDir()
        Deprecated.
        Use Platform.getImportDir
      • setImportDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setImportDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setImportDir
      • getExportDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getExportDir()
        Deprecated.
        Use Platform.getExportDir
      • setExportDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setExportDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setExportDir
      • getIndexDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getIndexDir()
        Deprecated.
        Use Platform.getIndexDir
      • setIndexDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setIndexDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setIndexDir
      • getBeanDir

        @Deprecated(forRemoval=false,
                    since="4.0")
        public final java.lang.String getBeanDir()
        Deprecated.
        Use Platform.getSrcDir
      • setBeanDir

        @Deprecated(forRemoval=false,
                    since="4.0")
        public final void setBeanDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setSrcDir
      • getSrcDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getSrcDir()
        Deprecated.
        Use Platform.getSrcDir
      • setSrcDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setSrcDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setSrcDir
      • getBinDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getBinDir()
        Deprecated.
        Use Platform.getBinDir
      • setBinDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setBinDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setBinDir
      • getMavenDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getMavenDir()
        Deprecated.
        Use Platform.getMavenDir
      • setMavenDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setMavenDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setMavenDir
      • getClassesDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getClassesDir()
        Deprecated.
        Use Platform.getClassesDir
      • setClassesDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setClassesDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setClassesDir
      • getJavadocDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getJavadocDir()
        Deprecated.
        Use Platform.getJavadocDir
      • setJavadocDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setJavadocDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setJavadocDir
      • getSourcesDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getSourcesDir()
        Deprecated.
        Use Platform.getSourcesDir
      • setSourcesDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setSourcesDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setSourcesDir
      • getLibsDir

        @Deprecated(forRemoval=false,
                    since="5")
        public java.lang.String getLibsDir()
        Deprecated.
        Use Platform.getLibsDir
      • setLibsDir

        @Deprecated(forRemoval=false,
                    since="5")
        public void setLibsDir​(java.lang.String dir)
        Deprecated.
        Use Platform.setLibsDir
      • getSubPackage

        public java.lang.String getSubPackage()
        Get subpackage of specific classes
      • setSubPackage

        public void setSubPackage​(java.lang.String sp)
        Set subpackage of specific classes
      • isAboutEnable

        public boolean isAboutEnable()
        Is about info enabled ? Forced for admin profiles
        Returns:
        True if about info is enabled
      • setAbout

        public void setAbout​(boolean b)
        Set whether about info is enabled
        Parameters:
        b - Enabled?
      • getWindowTitle

        public java.lang.String getWindowTitle()
        Get the window title
        Returns:
        Window title
      • setWindowTitle

        public void setWindowTitle​(java.lang.String title)
        Set the window title
        Parameters:
        title - Window title
      • isPanelFilterEnable

        public boolean isPanelFilterEnable()
        Is display panel filter?
      • setPanelFilter

        public void setPanelFilter​(boolean b)
        Set display the panel filter
      • getPanelCharMax

        public int getPanelCharMax()
        Get panels (tabs) max width in char
      • setPanelCharMax

        public void setPanelCharMax​(int n)
        Set panels (tabs) max width in char
      • isHtmlEditorEnable

        public boolean isHtmlEditorEnable()
        Is the HTML editor enabled ?
      • setHtmlEditor

        public void setHtmlEditor​(boolean b)
        Set whether the HTML editor is enabled
      • getMenuStyle

        public java.lang.String getMenuStyle()
        Get menu style
      • getDBPatchLevel

        public java.lang.String getDBPatchLevel()
        Get database patch level
      • getHashAlgorithm

        @Deprecated(forRemoval=true,
                    since="4.0")
        public java.lang.String getHashAlgorithm()
        Deprecated, for removal: This API element is subject to removal in a future version.
        Use SystemParameters.getHashEncoding
      • setHashAlgorithm

        @Deprecated(forRemoval=true,
                    since="4.0")
        public void setHashAlgorithm​(java.lang.String p)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Use SystemParameters.setHashEncoding
      • getHashEncoding

        @Deprecated(forRemoval=true,
                    since="4.0")
        public java.lang.String getHashEncoding()
        Deprecated, for removal: This API element is subject to removal in a future version.
        Use SystemParameters.getHashEncoding
      • setHashEncoding

        @Deprecated(forRemoval=true,
                    since="4.0")
        public void setHashEncoding​(java.lang.String p)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Use SystemParameters.setHashEncoding
      • getLogEvent

        public AppLogEvent getLogEvent​(java.lang.String code)
        Get the log event for a given code
      • getLogEvents

        public java.util.Map<java.lang.String,​AppLogEvent> getLogEvents()
        Get all log events
      • isConvertWildcards

        public boolean isConvertWildcards()
        Are wildcard converted (from * and ? to SQL's % and _)?
        Returns:
        True if the wildcards are converted
      • setConvertWildcards

        public void setConvertWildcards​(boolean convert)
        Set wildcard as converted (from * and ? to SQL's % and _)
        Parameters:
        convert - Convert wildcards?
      • addObjectCalculated

        public void addObjectCalculated​(java.lang.String object,
                                        java.lang.String field,
                                        java.lang.String target,
                                        java.lang.String refId)
        Not null when the field is linked to calculated field in DB. key = the object used in external expression value = Hash of fields used in external expression containing a List of (linked objects to refresh + the ref field to make the join)
        Parameters:
        object - Object name
        field - Object field link to external expression
        target - Object to refresh
        refId - Reference field
      • getObjectCalculated

        public java.util.Map<java.lang.String,​java.util.Map<java.lang.String,​java.util.List<java.lang.String>>> getObjectCalculated()
        Get ref object calculated fields
        Returns:
        Ref object calculated fields map
      • getMaxUploadSize

        public long getMaxUploadSize()
        Get the upload limit size (in Mb)
      • setMaxUploadSize

        public void setMaxUploadSize​(long s)
        Set upload size limit (in Mb)
      • isCompletionEnable

        public boolean isCompletionEnable()
        Is the completion feature enabled?
      • setCompletion

        public void setCompletion​(boolean b)
        Set whether the completion feature is enabled
      • isIOInterfaceEnable

        @Deprecated(forRemoval=false,
                    since="5")
        public boolean isIOInterfaceEnable()
        Deprecated.
      • setIOInterface

        @Deprecated(forRemoval=false,
                    since="5")
        public void setIOInterface​(boolean b)
        Deprecated.
      • isGITInterfaceEnable

        @Deprecated(forRemoval=false,
                    since="5")
        public boolean isGITInterfaceEnable()
        Deprecated.
      • setGITInterface

        @Deprecated(forRemoval=false,
                    since="5")
        public void setGITInterface​(boolean b)
        Deprecated.
      • isAPIInterfaceEnable

        @Deprecated(forRemoval=false,
                    since="5")
        public boolean isAPIInterfaceEnable()
        Deprecated.
      • setAPIInterface

        @Deprecated(forRemoval=false,
                    since="5")
        public void setAPIInterface​(boolean b)
        Deprecated.
      • getVersion

        public java.lang.String getVersion()
        Get the application version
        Returns:
        Application version
      • getPoweredBy

        public java.lang.String getPoweredBy()
        Get the powered by text
        Returns:
        Powered by text
      • getAuthMethod

        public int getAuthMethod()
        Get the authentication method
        Returns:
        One of AuthTool.AUTH_METHOD_* constant
      • isDefaultAuthMethod

        public boolean isDefaultAuthMethod()
        Is the authentication method default?
      • isInternalOAuth2AuthMethod

        public boolean isInternalOAuth2AuthMethod()
        Is the authentication method OAuth2?
      • isOAuth2AuthMethod

        public boolean isOAuth2AuthMethod()
        Is the authentication method OAuth2?
      • isSAMLAuthMethod

        public boolean isSAMLAuthMethod()
        Is the authentication method SAML?
      • isCROWDAuthMethod

        public boolean isCROWDAuthMethod()
        Is the authentication method CROWD?
      • isLDAPAuthMethod

        public boolean isLDAPAuthMethod()
        Is the authentication method LDAP?
      • isCustomAuthMethod

        public boolean isCustomAuthMethod()
        Is the authentication method custom?
      • getAuthProvider

        public java.lang.String getAuthProvider()
        Get the authentication provider name
        Returns:
        Auth provider name (e.g. one of AuthTool.AUTH_PROVIDER_*) or null if default authentication method
      • setMFAMethod

        public void setMFAMethod​(java.lang.String method)
        Set the user's MFA method
        Parameters:
        method - User's MFA method
      • getMFAMethod

        public java.lang.String getMFAMethod()
        Get the user's MFA method (or null if the authentication provider is not the internal provider)
        Returns:
        User's MFA method or null
      • setMFASettings

        public void setMFASettings​(java.lang.String settings)
        Set the user's MFA settings
        Parameters:
        settings - User's MFA settings
      • getMFASettings

        public java.lang.String getMFASettings()
        Get the user's MFA settings
        Returns:
        User's MFA settings
      • getMFASettingsJSONObject

        public org.json.JSONObject getMFASettingsJSONObject()
        Get the user's MFA settings as JSON object
        Returns:
        User's MFA settings as JSON object (empty JSON object if empty or unparseable settings)
      • isMFAChecked

        public boolean isMFAChecked()
        Is the MFA checked for user?
        Returns:
        True if MAF is checked
      • setMFAChecked

        public void setMFAChecked​(boolean checked)
        Set the MFA check status for user
        Parameters:
        checked - Is the MFA checked for user?
      • isForcedChangePassword

        public boolean isForcedChangePassword()
        Is forced change password ?
        Returns:
        true if change password is forced
      • setForcedChangePassword

        public void setForcedChangePassword​(boolean f)
        Set forced change password
        Parameters:
        f - Force change password?
      • limitLicenseRights

        public void limitLicenseRights()
        Allow access but with restricted rights to update the LicenseKey only
      • getDispositionName

        public java.lang.String getDispositionName()
        Get the disposition name (from current disposition definition or, if not yet loaded from the configured system parameter).
        Returns:
        Disposition name
      • getDisposition

        public Disposition getDisposition()
        Get disposition
        Returns:
        Disposition
      • setDisposition

        public void setDisposition​(Disposition d)
        Set disposition
        Parameters:
        d - Disposition
      • getTheme

        public java.lang.String getTheme()
        Get the theme name
        Returns:
        Theme name
      • hasRegistration

        public boolean hasRegistration()
        Has registration?
        Returns:
        true if a register group exists
      • getRegistrationGroups

        public java.util.List<GroupDB> getRegistrationGroups()
        Get the registration groups
        Returns:
        List of registration groups
      • isEasyModeClearCache

        @Deprecated(forRemoval=true,
                    since="5")
        public boolean isEasyModeClearCache()
        Deprecated, for removal: This API element is subject to removal in a future version.
        Check the partial clear cache flag (formerly known as "easy mode")
        Returns:
        true to use partial clear cache
      • setEasyModeClearCache

        @Deprecated(forRemoval=true,
                    since="5")
        public void setEasyModeClearCache​(boolean c)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Set the partial clear cache flag (formerly known as "easy mode")
        Parameters:
        c - Partial clear cache?
      • getLocale

        public java.util.Locale getLocale()
        Get locale for grant
        Returns:
        Locale
      • recordUsage

        public void recordUsage()
        Record usage (usage count and last usage date)
      • toJSONObject

        public org.json.JSONObject toJSONObject()
        Generates a JSON object representation of grant
        Returns:
        grant as JSON object
      • toJSONObject

        public org.json.JSONObject toJSONObject​(boolean resps,
                                                boolean sysparams)
        Generates a JSON object representation of grant
        Parameters:
        resps - Add responsibilities
        sysparams - Add system parameters
        Returns:
        grant as JSON object
      • toString

        public java.lang.String toString()
        Generates a string representation of the grant
        Overrides:
        toString in class java.lang.Object
        Returns:
        grant as string
      • toString

        public java.lang.String toString​(boolean resps,
                                         boolean sysparams)
        Generates a string representation of the grant
        Parameters:
        resps - Add responsibilities
        sysparams - Add system parameters
        Returns:
        grant as string