Java Doc for UTILPluginAdapter.java in  » Science » Cougaar12_4 » org » cougaar » lib » filter » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Science » Cougaar12_4 » org.cougaar.lib.filter 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.cougaar.core.plugin.ComponentPlugin
   org.cougaar.lib.filter.UTILPluginAdapter

All known Subclasses:   org.cougaar.logistics.plugin.trans.AssetStimulator,  org.cougaar.lib.filter.UTILBufferingPluginAdapter,  org.cougaar.logistics.plugin.trans.RescindWatcher,  org.cougaar.glm.plugins.tools.GLMStimulatorPlugin,
UTILPluginAdapter
public class UTILPluginAdapter extends ComponentPlugin implements UTILPlugin(Code)
 Implementation of UTILPlugin interface.
 parameters are read when the plugin is loaded.
 filterCallbacks are added just before the plugin
 thread is started.
 


Field Summary
protected  doubleHIGH_CONFIDENCE
    
protected  UTILAggregateaggregateHelper
    
protected  UTILAllocateallocHelper
    
protected  UTILAssetassetHelper
    
protected  booleancheckedDidRehydrate
    
protected  UTILExpandexpandHelper
    
protected  PlanningFactoryldmf
    
protected  LoggingServicelogger
    
protected  StringmyClusterName
    
protected  StringmyName
    
protected  ParamMapmyParams
    
protected  VectormySubscriptions
    
protected  ParamParserparamParser
    
protected  PersistentStatepersistentState
    
protected  UTILPreferenceprefHelper
    
protected  UTILPrepPhraseprepHelper
    
protected  PlanrealityPlan
    
protected  booleanshowinfoOnFailure
    
protected  booleanskipLowConfidence
    
protected  UTILVerifyverifyHelper
    


Method Summary
public  voidaddFilter(UTILFilterCallback callbackObj)
     mySubscriptions is synchronized here and in cycle to make sure that no subscriptions are added while iterating over the list of current subscriptions (in cycle ()).
protected  ParamMapcreateParamTable(Vector envParams, MessageAddress ident)
     Subclass to return a different ParamTable.
protected  voiddebug(String message)
     Equivalent to "log(debug, ..)".
protected  booleandidSpawn()
    
protected  voiderror(String message)
     Equivalent to "log(ERROR, ..)".
protected  voidexecute()
     Called every time one of the filterCallback subscriptions change.
protected  voidfatal(String message)
     Equivalent to "log(FATAL, ..)".
protected  PersistentStatefindState()
    
protected  StringgetClassName()
    
protected  StringgetClassName(Object obj)
    
public  StringgetClusterName()
    
public  voidgetEnvData()
     Allows child classes to read additional data from environment files.
final protected  LDMServicegetLDMService()
    
protected  LoggingServicegetLoggingService()
     Get the logging service, for subclass use.
public  ParamMapgetMyParams()
     Accessor to param table.
public  StringgetName()
    
protected  MessageAddressgetOriginalAgentID()
    
protected  voidinfo(String message)
     Equivalent to "log(info, ..)".
protected  booleanisDebugEnabled()
    
protected  booleanisErrorEnabled()
    
protected  booleanisFatalEnabled()
    
protected  booleanisInfoEnabled()
    
protected  booleanisWarnEnabled()
    
protected  voidjustRehydrated()
     Automatic support for persistent state.
public  voidlocalSetup()
    
 Place to put any local plugin startup initiallization.
public  voidpreFilterSetup()
     A place to put setup actions that will occur before any filters are active. I.e.
final protected  voidpublishAdd(Object o)
    
final protected  voidpublishChange(Object o)
    
final protected  voidpublishRemove(Object o)
    
protected  voidregisterPersistentState(Object obj)
     Call this method to add your state to what will be persisted Call from inside of a transaction.
protected  voidrehydrateState(List stuff)
    
public  voidremoveFilter(UTILFilterCallback callbackObj)
     mySubscriptions is synchronized here and in cycle to make sure that no subscriptions are removed while iterating over the list of current subscriptions (in cycle ()).
final public  voidsetLDMService(LDMService s)
    
public  voidsetLoggingService(LoggingService bs)
     rely upon load-time introspection to set these services - don't worry about revokation.
public  voidsetupFilters()
    
 The idea is to add subscriptions (via the filterCallback), and when 
 they change, to have the callback react to the change, and tell 
 the listener (many times the plugin) what to do.
final protected  voidsetupSubscriptions()
     This method is called before cycle is ever called to set up safe transactions for container subscriptions.
public  IncrementalSubscriptionsubscribeFromCallback(UnaryPredicate pred)
     Implemented for UTILFilterCallbackListener This allows callbacks to make subscriptions.
public  IncrementalSubscriptionsubscribeFromCallback(UnaryPredicate pred, Collection specialContainer)
     Implemented for UTILFilterCallbackListener This allows callbacks to make subscriptions with a special container.
public  voidupdateAllocationResult(PlanElement cpe)
    
 if the reported allocation result has been successfully calculated
 set the estimated equal to the reported to send a notification
 back up.
 Only reports results if the confidence is above a threshold.
 This threshold is currently 0.99.
protected  voidwarn(String message)
     Equivalent to "log(WARN, ..)".

Field Detail
HIGH_CONFIDENCE
protected double HIGH_CONFIDENCE(Code)



aggregateHelper
protected UTILAggregate aggregateHelper(Code)



allocHelper
protected UTILAllocate allocHelper(Code)



assetHelper
protected UTILAsset assetHelper(Code)



checkedDidRehydrate
protected boolean checkedDidRehydrate(Code)



expandHelper
protected UTILExpand expandHelper(Code)



ldmf
protected PlanningFactory ldmf(Code)



logger
protected LoggingService logger(Code)



myClusterName
protected String myClusterName(Code)



myName
protected String myName(Code)



myParams
protected ParamMap myParams(Code)



mySubscriptions
protected Vector mySubscriptions(Code)



paramParser
protected ParamParser paramParser(Code)



persistentState
protected PersistentState persistentState(Code)



prefHelper
protected UTILPreference prefHelper(Code)



prepHelper
protected UTILPrepPhrase prepHelper(Code)



realityPlan
protected Plan realityPlan(Code)



showinfoOnFailure
protected boolean showinfoOnFailure(Code)



skipLowConfidence
protected boolean skipLowConfidence(Code)



verifyHelper
protected UTILVerify verifyHelper(Code)





Method Detail
addFilter
public void addFilter(UTILFilterCallback callbackObj)(Code)
mySubscriptions is synchronized here and in cycle to make sure that no subscriptions are added while iterating over the list of current subscriptions (in cycle ()). This method can be called at any time, not just from setupFilters ().
See Also:   UTILPluginAdapter.setupFilters()



createParamTable
protected ParamMap createParamTable(Vector envParams, MessageAddress ident)(Code)
Subclass to return a different ParamTable.



debug
protected void debug(String message)(Code)
Equivalent to "log(debug, ..)".



didSpawn
protected boolean didSpawn()(Code)



error
protected void error(String message)(Code)
Equivalent to "log(ERROR, ..)".



execute
protected void execute()(Code)
Called every time one of the filterCallback subscriptions change. What the plugin does in response to a changed subscription. Directs the filterCallback with the changed subscription to react to the change in some way.



fatal
protected void fatal(String message)(Code)
Equivalent to "log(FATAL, ..)".



findState
protected PersistentState findState()(Code)



getClassName
protected String getClassName()(Code)
utility function to get just the name of this class (no package qualification)



getClassName
protected String getClassName(Object obj)(Code)
utility function to get just the name of the class of an object (no package)



getClusterName
public String getClusterName()(Code)
the name of the cluster



getEnvData
public void getEnvData()(Code)
Allows child classes to read additional data from environment files. Derived classes should call super ().



getLDMService
final protected LDMService getLDMService()(Code)



getLoggingService
protected LoggingService getLoggingService()(Code)
Get the logging service, for subclass use.



getMyParams
public ParamMap getMyParams()(Code)
Accessor to param table. Child classes can use this to add additional parameters. ParamTable



getName
public String getName()(Code)
cluster name and plugin name



getOriginalAgentID
protected MessageAddress getOriginalAgentID()(Code)



info
protected void info(String message)(Code)
Equivalent to "log(info, ..)".



isDebugEnabled
protected boolean isDebugEnabled()(Code)



isErrorEnabled
protected boolean isErrorEnabled()(Code)



isFatalEnabled
protected boolean isFatalEnabled()(Code)



isInfoEnabled
protected boolean isInfoEnabled()(Code)



isWarnEnabled
protected boolean isWarnEnabled()(Code)



justRehydrated
protected void justRehydrated()(Code)
Automatic support for persistent state. Calls rehydrate if appropriate



localSetup
public void localSetup()(Code)
 Place to put any local plugin startup initiallization.
 This is a good place to read local data from files.
 This is useful during integration when getting as much as debugrmation
 as possible at the point of failure is critical.
 



preFilterSetup
public void preFilterSetup()(Code)
A place to put setup actions that will occur before any filters are active. I.e. objects created here can be referenced in filterCallback listener methods. Default does nothing.



publishAdd
final protected void publishAdd(Object o)(Code)



publishChange
final protected void publishChange(Object o)(Code)



publishRemove
final protected void publishRemove(Object o)(Code)



registerPersistentState
protected void registerPersistentState(Object obj)(Code)
Call this method to add your state to what will be persisted Call from inside of a transaction.



rehydrateState
protected void rehydrateState(List stuff)(Code)
anything you added with register, you will be debugrmed about here upon rehydration



removeFilter
public void removeFilter(UTILFilterCallback callbackObj)(Code)
mySubscriptions is synchronized here and in cycle to make sure that no subscriptions are removed while iterating over the list of current subscriptions (in cycle ()). This method can be called at any time, not just from setupFilters (). BOZO - should make addFilter automatically do subscribe too. Not enough time now (9-4-99) -- should do later!!! Problem is if we want special containers to be used with subscriptions. A number of API changes would be necessary...
See Also:   UTILPluginAdapter.setupFilters()



setLDMService
final public void setLDMService(LDMService s)(Code)



setLoggingService
public void setLoggingService(LoggingService bs)(Code)
rely upon load-time introspection to set these services - don't worry about revokation.



setupFilters
public void setupFilters()(Code)
 The idea is to add subscriptions (via the filterCallback), and when 
 they change, to have the callback react to the change, and tell 
 the listener (many times the plugin) what to do.
 The intent is that all "on start-up" filters get added here.
 Note that there is no restraint on when a subclass can add a 
 filter, as long as it doesn't happen before setupFilters ().
 

See Also:   UTILPluginAdapter.addFilter()



setupSubscriptions
final protected void setupSubscriptions()(Code)
This method is called before cycle is ever called to set up safe transactions for container subscriptions. setupFilters () is wrapped in an open/closeTransaction block.



subscribeFromCallback
public IncrementalSubscription subscribeFromCallback(UnaryPredicate pred)(Code)
Implemented for UTILFilterCallbackListener This allows callbacks to make subscriptions.



subscribeFromCallback
public IncrementalSubscription subscribeFromCallback(UnaryPredicate pred, Collection specialContainer)(Code)
Implemented for UTILFilterCallbackListener This allows callbacks to make subscriptions with a special container.



updateAllocationResult
public void updateAllocationResult(PlanElement cpe)(Code)
 if the reported allocation result has been successfully calculated
 set the estimated equal to the reported to send a notification
 back up.
 Only reports results if the confidence is above a threshold.
 This threshold is currently 0.99.  All changes will be reported
 if skipLowConfidence is set to false.
 Takes care not to copy nulls from reported aux query results into
 estimated fields.
 



warn
protected void warn(String message)(Code)
Equivalent to "log(WARN, ..)".



Methods inherited from org.cougaar.core.plugin.ComponentPlugin
abstract protected void execute()(Code)(Java Doc)
protected ConfigFinder getConfigFinder()(Code)(Java Doc)
abstract protected void setupSubscriptions()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.