scone.accesstracking
Class FrameSet

java.lang.Object
  extended by scone.accesstracking.FrameSet

public class FrameSet
extends java.lang.Object

FrameSet stores two or more Access objects to allow FrameHistory to work with frame sets

Version:
1.0b, 11/02/2001
Author:
Torsten Hass

Constructor Summary
FrameSet()
           
 
Method Summary
 void addToFrameSet(java.lang.String megTime, Access a)
          Adds a new Access object and a megTime to the FrameSet.
 void addToFrameSet(java.lang.String megTime, FrameSet fs)
          Adds a new FrameSet object and a megTime to the FrameSet.
 boolean contains(java.lang.String megTime)
          Checks if the megTime is in the FrameSet
 boolean containsPageLike(Access a)
          Checks if the Access object matches one in the FrameSet in following fields:
userId, nodeId, frameName, fragment, query
If one of the entries is a FrameSet itself, it is searched recursively with it's containsPageLike method.
 void copyUnstoppedEvents(FrameSet source)
          Copy unstopped events: all Access objects that have not been stopped (have an stay time > 0) are Frames that have not changed in FrameSet and have to be copied to the next FrameSet
 Access getFirstEvent()
          Get first access object of this FrameSet
 java.lang.Object getFrame(int index)
          Get frame of a position
 int getFrameListSize()
          Get number of entries in FrameSet.
 Access getLastEvent(java.lang.String frameName)
          Get last access event
 java.lang.String getMegTime(int index)
          Get megTime of a position
 boolean noStoppedEvents()
          Test if all access events have stayTime = 0, so no event was stopped by the applet.
 void replaceEvent(java.lang.String frameName, java.lang.String megTime, Access a)
          Replace last megTime and access object
 void setParentAccessIds(java.lang.String parentAccessId)
          Sets the parentAccessIds of every Access object in this FrameSet.
 void showFrameSetContents()
          Show FrameSet contents to std out.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FrameSet

public FrameSet()
Method Detail

addToFrameSet

public void addToFrameSet(java.lang.String megTime,
                          Access a)
Adds a new Access object and a megTime to the FrameSet.

Parameters:
megTime - The time when the JavaScriptCode was generated
a - The Access object to add to list

addToFrameSet

public void addToFrameSet(java.lang.String megTime,
                          FrameSet fs)
Adds a new FrameSet object and a megTime to the FrameSet.

Parameters:
megTime - The time when the JavaScriptCode was generated
a - The Access object to add to list

contains

public boolean contains(java.lang.String megTime)
Checks if the megTime is in the FrameSet

Parameters:
megTime - The megTime as a sting
Returns:
true if the FrameSet contains megTime

containsPageLike

public boolean containsPageLike(Access a)
Checks if the Access object matches one in the FrameSet in following fields:
userId, nodeId, frameName, fragment, query
If one of the entries is a FrameSet itself, it is searched recursively with it's containsPageLike method.

Parameters:
a - The Access object.
Returns:
true if the Access object matches one in the FrameSet.

getLastEvent

public Access getLastEvent(java.lang.String frameName)
Get last access event

Parameters:
frameName - To identify the Access object
Returns:
Access object

getFirstEvent

public Access getFirstEvent()
Get first access object of this FrameSet

Returns:
Access object

setParentAccessIds

public void setParentAccessIds(java.lang.String parentAccessId)
Sets the parentAccessIds of every Access object in this FrameSet.

Parameters:
parentAccessId - AccessId of the parent Access object

showFrameSetContents

public void showFrameSetContents()
Show FrameSet contents to std out.


noStoppedEvents

public boolean noStoppedEvents()
Test if all access events have stayTime = 0, so no event was stopped by the applet.

Returns:
true if this FrameSet contains no stopped access objects.

copyUnstoppedEvents

public void copyUnstoppedEvents(FrameSet source)
Copy unstopped events: all Access objects that have not been stopped (have an stay time > 0) are Frames that have not changed in FrameSet and have to be copied to the next FrameSet

Parameters:
source - The FrameSet to get the unstopped Access object from.

getFrameListSize

public int getFrameListSize()
Get number of entries in FrameSet. FrameSets, that are entries of this FrameSet are counted as one entry.

Returns:
Number of entries

getFrame

public java.lang.Object getFrame(int index)
Get frame of a position

Parameters:
number - of FrameSet entry
Returns:
FrameSet entry

getMegTime

public java.lang.String getMegTime(int index)
Get megTime of a position

Parameters:
number - of FrameSet entry
Returns:
megTime

replaceEvent

public void replaceEvent(java.lang.String frameName,
                         java.lang.String megTime,
                         Access a)
Replace last megTime and access object

Parameters:
frameName - To identify the frame to be replaced
megTime - The megTime that replaces the previous one
a - The Access object that replaces the previous one