com.primix.vlib
Class Visit

java.lang.Object
  |
  +--com.primix.vlib.Visit
All Implemented Interfaces:
java.io.Serializable

public class Visit
extends java.lang.Object
implements java.io.Serializable

The visit object for the VirtualLibraryEngine. Primarily, this is used to access the home interfaces and EJB instances, and to identify who the logged in user is.

Version:
$Id: Visit.java,v 1.9 2001/08/27 22:19:12 hship Exp $
Author:
Howard Ship
See Also:
Serialized Form

Constructor Summary
Visit(VirtualLibraryEngine engine)
           
 
Method Summary
 void clearCache()
          Invoked by pages after they perform an operation that changes the backend database in such a way that cached data is no longer valid.
 VirtualLibraryEngine getEngine()
           
 java.sql.Timestamp getLastAccess()
          Returns the time the user last accessed the database, which may be null if the user hasn't logged in yet.
 Person getUser()
          Gets the logged-in user, or null if the user is not logged in.
 java.lang.Integer getUserPK()
          Returns the primary key of the logged in user, or null if the user is not logged in.
 boolean isLoggedInUser(java.lang.Integer primaryKey)
           
 boolean isUserLoggedIn()
          Returns true if the user is logged in.
 boolean isUserLoggedOut()
          Returns true if the user has not been identified (has not logged in).
 void setUser(Person value)
          Changes the logged in user ...
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Visit

public Visit(VirtualLibraryEngine engine)
Method Detail

getEngine

public VirtualLibraryEngine getEngine()

getLastAccess

public java.sql.Timestamp getLastAccess()
Returns the time the user last accessed the database, which may be null if the user hasn't logged in yet.

getUser

public Person getUser()
Gets the logged-in user, or null if the user is not logged in.

getUserPK

public java.lang.Integer getUserPK()
Returns the primary key of the logged in user, or null if the user is not logged in.

setUser

public void setUser(Person value)
Changes the logged in user ... this is only invoked from the Login page.

isUserLoggedIn

public boolean isUserLoggedIn()
Returns true if the user is logged in.

isUserLoggedOut

public boolean isUserLoggedOut()
Returns true if the user has not been identified (has not logged in).

isLoggedInUser

public boolean isLoggedInUser(java.lang.Integer primaryKey)

clearCache

public void clearCache()
Invoked by pages after they perform an operation that changes the backend database in such a way that cached data is no longer valid. Currently, this should be invoked after changing the user's profile, or adding a new IPublisher entity.