isUserValid
isUserValid(usercode: String; password: String): Boolean [serverExecution];
The isUserValid method of the Global class is the secondary validation method that is invoked on the subschema global instance as a result of a jomSignOn API call to open a process.
For details, see "
When no user code is supplied in the jomSignOn Application Programming Interface (API) call to open a process, the user code and password returned by the getAndValidateUser method are used.
If the user code and password are specified in the jomSignOn call, these are used, as follows.
-
If the method indicates success, the jomSignOn API returns a valid process handle to the caller, which allows the application to proceed as usual.
-
If the method signals failure (that is, the user is not authorized), the Jade Object Manager discontinues the tentative application process and a null process handle is returned to the caller. No exception is raised.
When this method is reimplemented, your user method is responsible for validating (or revalidating) the user code and password and for returning the appropriate result.
Reimplement this method to:
-
Validate user codes and passwords passed from non‑Jade clients or the Jade ODBC interface.
-
Ensure that secondary validation always occurs on the server.
To guarantee that secondary validation occurs on the server, the isUserValid method must be marked for server execution.
The values returned by this method are listed in the following table.
Value | Result |
---|---|
true | The user is authorized |
false | The user is not authorized |
The default isUserValid method that returns true is defined and implemented in the RootSchemaGlobal global class of the RootSchema. The default implementation also defines the method name and signature, so that you are aware that you are correctly reimplementing the server user validation method.