infosapient.server
Class InfoSapientKnowledgeWorker

java.lang.Object
  |
  +--infosapient.server.InfoSapientKnowledgeWorker

public class InfoSapientKnowledgeWorker
extends java.lang.Object
implements java.lang.Runnable, Observer

See Also:
Serialized Form

Field Summary
private  InfoSapientController alc
          Controller used for mediating requests from rules engine
private  java.lang.String attrName
          Attribute name.
private  FzyAttribute fa
          Attribute.
private  FzySet fs
          Goal set.
private  InfoSapientClientImpl InfoSapientClient
          InfoSapientClientImpl used to communicate with the objects requesting knowledgebase sessions
private  java.lang.String kbTypeName
          The type of knowledgebase this thread handles.
private  java.lang.String name
          Name of this thread.
private  java.util.Properties runParameters
          Consultation session parameters sent from client to this thread.
 
Constructor Summary
protected InfoSapientKnowledgeWorker(java.lang.String kbTName, java.lang.String n)
          Create a knowledgeWorker with the kb name to load, the name of this thread, and the properties required to connect to the InfoSapientService
protected InfoSapientKnowledgeWorker(java.lang.String kbTName, java.lang.String n, java.util.Properties goal)
          Create a knowledgeWorker with the kb name to load, the name of this thread, and the properties required to connect to the InfoSapientService
 
Method Summary
protected  InfoSapientClientImpl getInfoSapientClient()
          Insert the method's description here.
 java.lang.String getName()
           
(package private)  void handleClient()
           
(package private)  void handleThreadPool()
           
 void run()
          InfoSapientin in a loop until runParameters have been set.
(package private)  void setGoalProperties(java.util.Properties wp)
           
protected  void setInfoSapientClient(InfoSapientClientImpl newInfoSapientClient)
          Insert the method's description here.
(package private)  void setName(java.lang.String n)
           
 void update(Observable obs, java.lang.Object obj)
           
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

InfoSapientClient

private InfoSapientClientImpl InfoSapientClient
InfoSapientClientImpl used to communicate with the objects requesting knowledgebase sessions

attrName

private java.lang.String attrName
Attribute name. Used in error processing and notification.

fa

private FzyAttribute fa
Attribute. Used in error processing and notification.

fs

private FzySet fs
Goal set. Used in error processing and notification.

runParameters

private java.util.Properties runParameters
Consultation session parameters sent from client to this thread. Used for rules processing.

kbTypeName

private java.lang.String kbTypeName
The type of knowledgebase this thread handles.

alc

private InfoSapientController alc
Controller used for mediating requests from rules engine

name

private java.lang.String name
Name of this thread.
Constructor Detail

InfoSapientKnowledgeWorker

protected InfoSapientKnowledgeWorker(java.lang.String kbTName,
                                     java.lang.String n)
Create a knowledgeWorker with the kb name to load, the name of this thread, and the properties required to connect to the InfoSapientService
Parameters:
String - - knowledgebase key in kb.properties file
String - - worker name.
Properties - - connection properties required.

InfoSapientKnowledgeWorker

protected InfoSapientKnowledgeWorker(java.lang.String kbTName,
                                     java.lang.String n,
                                     java.util.Properties goal)
Create a knowledgeWorker with the kb name to load, the name of this thread, and the properties required to connect to the InfoSapientService
Parameters:
String - - knowledgebase key in kb.properties file
String - - worker name.
Properties - - connection properties required.
Method Detail

getInfoSapientClient

protected InfoSapientClientImpl getInfoSapientClient()
Insert the method's description here. Creation date: (04/08/01 10:17:05 AM)
Returns:
infosapient.client.InfoSapientClientImpl

getName

public java.lang.String getName()

handleClient

final void handleClient()
                 throws java.lang.Exception

handleThreadPool

final void handleThreadPool()

run

public final void run()
InfoSapientin in a loop until runParameters have been set. When that happens, start the kb session by invoking handleClient(). When finished -- set runParameters to null, put me back into the thread pool, remove me from the InfoSapientService registry.
Specified by:
run in interface java.lang.Runnable

setGoalProperties

void setGoalProperties(java.util.Properties wp)

setInfoSapientClient

protected void setInfoSapientClient(InfoSapientClientImpl newInfoSapientClient)
Insert the method's description here. Creation date: (04/08/01 10:17:05 AM)
Parameters:
newInfoSapientClient - infosapient.client.InfoSapientClientImpl

setName

void setName(java.lang.String n)

update

public final void update(Observable obs,
                         java.lang.Object obj)
Specified by:
update in interface Observer

License to use this program is provided under the TERMS OF THE COMMON PUBLIC LICENSE 0.5. ("AGREEMENT"). ANY USE, REPRODUCTION OR DISTRIBUTION OF THE PROGRAM CONSTITUTES RECIPIENT'S ACCEPTANCE OF THIS AGREEMENT.

Copyright (c) 2001, Workplace Performance Tools, All Rights Reserved