Class PBELoginObject

Object
  |
  +--PBEUnit
        |
        +--PBEObject
              |
              +--PBELoginObject
Direct Known Subclasses:
ModuleLoginObject, PBETableLoginObject

public class PBELoginObject
extends PBEObject


Description:
PBELoginObject provides customizable login functionality to a PrimeBase Enterprise Objects application.


PBE Attributes/Fields:

password

user


PBE Methods:

debug, guest, login


Fields inherited from class PBEObject
attributes, iClearInput, methods, name
 
Constructor Summary
PBELoginObject(varchar name)
           
 
Method Summary
 void disable(varchar page)
          Login objects cannot be disabled.
 void login(boolean guest, varchar user)
          Perform your login action here.
 void loginFailed(boolean guest, varchar user)
          Perform your login failed action here.
 boolean mayLogin(boolean guest, varchar user, varchar password)
          Check if the given user with the give password may login.
 boolean validUser(boolean guest, varchar user)
          Check if the user is valid (i.e. if the user is known and may login).
 
Methods inherited from class PBEObject
attributeName, clear, clearInput, disableAttributes, display, enable, enableAttributes, getAttributeStatus, getAttributeStatus, getError, globalReference, hide, init, inputMethod, inputMethod, inputValue, outputValue, outputValue, outputValue, performActivation, prepareAction, redirect, setActive, setAttributeStatus, setError, show
 
Methods inherited from class PBEUnit
compileActions, compileConditions, prepareEvent
 

Constructor Detail

PBELoginObject

public PBELoginObject(varchar name)
Parameters:
name - the name used to access this object.
Method Detail

disable

public void disable(varchar page)
Login objects cannot be disabled. This function overrides and disables the disable functionality of the object.
Overrides:
disable in class PBEObject

validUser

public boolean validUser(boolean guest,
                         varchar user)
Check if the user is valid (i.e. if the user is known and may login). The guest parameter is set to $true if this is a guest login. In this case the user name is ignored. This function returns $true if the user is valid, $false if the user is not value, and $null if access is not checked by login.

mayLogin

public boolean mayLogin(boolean guest,
                        varchar user,
                        varchar password)
Check if the given user with the give password may login.

login

public void login(boolean guest,
                  varchar user)
Perform your login action here. By default, all objects in the application are enabled. On debug login name == $null and on guest login, name == "".

loginFailed

public void loginFailed(boolean guest,
                        varchar user)
Perform your login failed action here. By default all objects are disabled and redirected to a page called '/noaccess.htd'. However, when guest login fails, this function does nothing.