Java Doc for UTILExpanderPluginAdapter.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.lib.filter.UTILPluginAdapter
   org.cougaar.lib.filter.UTILBufferingPluginAdapter
      org.cougaar.lib.filter.UTILExpanderPluginAdapter

All known Subclasses:   org.cougaar.logistics.plugin.strattrans.StrategicTransportProjectorPlugin,  org.cougaar.logistics.plugin.trans.TransportExpanderPlugin,  org.cougaar.logistics.plugin.trans.AmmoLowFidelityExpanderPlugin,  org.cougaar.logistics.plugin.trans.base.GLMTransOneToManyExpanderPlugin,
UTILExpanderPluginAdapter
public class UTILExpanderPluginAdapter extends UTILBufferingPluginAdapter implements UTILExpanderPlugin(Code)
 The UTILExpanderPluginAdapter is a handy base class for TOPS/GLMTrans
 Expanders.  getSubtasks should be redefined in subclasses.
 Has hooks for handling various replanning conditions.
 Defines handleFailedExpansion with the default behavior of reporting a
 changed expansion.
 

See Also:   UTILExpanderPluginAdapter.handleFailedExpansion


Field Summary
protected  UTILExpandexpand
    
protected  UTILExpandableTaskCallbackmyInputTaskCallback
    
protected  booleanwantConfidence
    


Method Summary
public  voidchangeExpansion(Expansion exp)
     The plugin changes the expansion.
protected  UTILFilterCallbackcreateExpansionCallback()
    
protected  UTILFilterCallbackcreateThreadCallback(UTILGenericListener bufferingThread)
     Provide the callback that is paired with the buffering thread, which is a listener.
protected  UTILFilterCallbackgetInputTaskCallback()
    
public  VectorgetSubtasks(Task t)
    
 Implemented for UTILExpanderPlugin interface
 The guts of the expansion.
public  voidhandleConstraintViolation(Expansion exp, List violatedConstraints)
     At least one constraint has been violated.
public  voidhandleFailedExpansion(Expansion exp, List failedSubTaskResults)
    
 Implemented for UTILExpansionListener
 An expansion has failed.
public  voidhandleIllFormedTask(Task t)
     Implemented for UTILBufferingPlugin Got an ill-formed task, now handle it, by publishing a failed expansion for the task.
public  voidhandleRemovedTask(Task t)
    
public  voidhandleSuccessfulExpansion(Expansion exp, List successfulSubtasks)
     Handle a successful expansion

Does nothing by default, unless very verbose output is turned on.

public  voidhandleTask(Task t)
    
 Implemented for UTILGenericListener interface
 This method Expands the given Task and publishes the PlanElement.
public  booleaninterestingExpandedTask(Task t)
     Implemented for UTILExpansionListener Gives plugin a way to filter out which expanded tasks it's interested in.
public  booleaninterestingTask(Task t)
     Implemented for UTILBufferingPlugin interface filter for tasks you find interesting.
public  voidlocalSetup()
    
public  voidprocessTasks(List tasks)
    
public  voidpublishChangedExpansion(Expansion exp)
    
public  voidreportChangedExpansion(Expansion exp)
     Report to superior that the expansion has changed.
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.
public  booleanwantToChangeExpansion(Expansion exp)
    
 Implemented for UTILExpansionListener
 Does the plugin want to change the expansion?
 For instance, although no individual preference may have been exceeded,
 the total score for the expansion may exceed some threshold, and so the
 plugin may want to alter the expansion.

Field Detail
expand
protected UTILExpand expand(Code)



myInputTaskCallback
protected UTILExpandableTaskCallback myInputTaskCallback(Code)



wantConfidence
protected boolean wantConfidence(Code)





Method Detail
changeExpansion
public void changeExpansion(Expansion exp)(Code)
The plugin changes the expansion. Default does nothing.
See Also:   UTILExpanderPluginAdapter.wantToChangeExpansion
Parameters:
  exp - expansion to change



createExpansionCallback
protected UTILFilterCallback createExpansionCallback()(Code)
create the expansion callback



createThreadCallback
protected UTILFilterCallback createThreadCallback(UTILGenericListener bufferingThread)(Code)
Provide the callback that is paired with the buffering thread, which is a listener. The buffering thread is the listener to the callback an ExpandableTaskCallback with the buffering thread as its listener
See Also:   org.cougaar.lib.callback.UTILWorkflowCallback



getInputTaskCallback
protected UTILFilterCallback getInputTaskCallback()(Code)
Filter out/listen for expandable tasks



getSubtasks
public Vector getSubtasks(Task t)(Code)
 Implemented for UTILExpanderPlugin interface
 The guts of the expansion.
 Default does nothing!  Subclass should override.
 



handleConstraintViolation
public void handleConstraintViolation(Expansion exp, List violatedConstraints)(Code)
At least one constraint has been violated. It's up to the plugin how to deal with the violation(s). Ideally, this will not happen very often, and when it does, we should hear about it.
Parameters:
  exp - expansion that failed
Parameters:
  violatedConstraints - list of Constraints that have been violated



handleFailedExpansion
public void handleFailedExpansion(Expansion exp, List failedSubTaskResults)(Code)
 Implemented for UTILExpansionListener
 An expansion has failed.  It's up to the plugin how to deal with the
 failure.
 Just report it to superior, where hopefully it will be dealt with.
 Dumps to error info about the failed tasks.
 

Parameters:
  exp - expansion that failed
Parameters:
  failedSubTaskResults - - the subtasks of the expansion that failed



handleIllFormedTask
public void handleIllFormedTask(Task t)(Code)
Implemented for UTILBufferingPlugin Got an ill-formed task, now handle it, by publishing a failed expansion for the task.
Parameters:
  t - badly-formed task to handle



handleRemovedTask
public void handleRemovedTask(Task t)(Code)
react to a rescinded task -- by default does nothing



handleSuccessfulExpansion
public void handleSuccessfulExpansion(Expansion exp, List successfulSubtasks)(Code)
Handle a successful expansion

Does nothing by default, unless very verbose output is turned on.
Parameters:
  exp - Expansion that has succeeded.




handleTask
public void handleTask(Task t)(Code)
 Implemented for UTILGenericListener interface
 This method Expands the given Task and publishes the PlanElement.
 The method expandTask should be implemented by child classes.
 

Parameters:
  t - the task to be expanded.



interestingExpandedTask
public boolean interestingExpandedTask(Task t)(Code)
Implemented for UTILExpansionListener Gives plugin a way to filter out which expanded tasks it's interested in.
Parameters:
  t - Task that has been expanded (getTask of Expansion) true if task is interesting to this plugin



interestingTask
public boolean interestingTask(Task t)(Code)
Implemented for UTILBufferingPlugin interface filter for tasks you find interesting.
Parameters:
  t - Task to check for interest boolean true if task is interesting
See Also:   UTILBufferingPlugin



localSetup
public void localSetup()(Code)



processTasks
public void processTasks(List tasks)(Code)
Implemented for UTILBufferingPlugin interface
Parameters:
  tasks - that have been buffered up to this point
See Also:   UTILBufferingPlugin



publishChangedExpansion
public void publishChangedExpansion(Expansion exp)(Code)
publish the change
See Also:   UTILExpanderPluginAdapter.wantToChangeExpansion
Parameters:
  exp - expansion to change



reportChangedExpansion
public void reportChangedExpansion(Expansion exp)(Code)
Report to superior that the expansion has changed. Usually just a pass through to the UTILPluginAdapter's updateAllocationResult.
Parameters:
  exp - Expansion that has changed.
See Also:   UTILPluginAdapter.updateAllocationResult



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.
 Override and call super to add new filters, or override 
 createXXXCallback to change callback behaviour.
 



wantToChangeExpansion
public boolean wantToChangeExpansion(Expansion exp)(Code)
 Implemented for UTILExpansionListener
 Does the plugin want to change the expansion?
 For instance, although no individual preference may have been exceeded,
 the total score for the expansion may exceed some threshold, and so the
 plugin may want to alter the expansion.
 Defaults to FALSE.
 

See Also:   org.cougaar.lib.util.UTILAllocate.scoreAgainstPreferences
Parameters:
  exp - expansion to check true if plugin wants to change expansion



Fields inherited from org.cougaar.lib.filter.UTILBufferingPluginAdapter
protected AgentIdentificationService agentIDService(Code)(Java Doc)
protected UTILBufferingThread bufferingThread(Code)(Java Doc)
protected PluginAlarm currentAlarm(Code)(Java Doc)
protected UTILPreference prefHelper(Code)(Java Doc)
protected QuiescenceReportService qService(Code)(Java Doc)
protected Schedulable schedulable(Code)(Java Doc)
protected ThreadService threadService(Code)(Java Doc)
protected UTILVerify verify(Code)(Java Doc)

Methods inherited from org.cougaar.lib.filter.UTILBufferingPluginAdapter
protected UTILBufferingThread createBufferingThread()(Code)(Java Doc)
abstract protected UTILFilterCallback createThreadCallback(UTILGenericListener listener)(Code)(Java Doc)
public void examineBufferAgainIn(long delayTime)(Code)(Java Doc)
protected void execute()(Code)(Java Doc)
protected UTILBufferingThread getBufferingThread()(Code)(Java Doc)
public boolean interestingTask(Task t)(Code)(Java Doc)
public boolean isTaskWellFormed(Task t)(Code)(Java Doc)
public void localSetup()(Code)(Java Doc)
abstract public void processTasks(List tasks)(Code)(Java Doc)
protected void reportIllFormedTask(Task t)(Code)(Java Doc)
public void resume()(Code)(Java Doc)
final public void setQuiescenceReportService(QuiescenceReportService qService)(Code)(Java Doc)
public void setupFilters()(Code)(Java Doc)
public void wakeUp()(Code)(Java Doc)

Fields inherited from org.cougaar.lib.filter.UTILPluginAdapter
protected double HIGH_CONFIDENCE(Code)(Java Doc)
protected UTILAggregate aggregateHelper(Code)(Java Doc)
protected UTILAllocate allocHelper(Code)(Java Doc)
protected UTILAsset assetHelper(Code)(Java Doc)
protected boolean checkedDidRehydrate(Code)(Java Doc)
protected UTILExpand expandHelper(Code)(Java Doc)
protected PlanningFactory ldmf(Code)(Java Doc)
protected LoggingService logger(Code)(Java Doc)
protected String myClusterName(Code)(Java Doc)
protected String myName(Code)(Java Doc)
protected ParamMap myParams(Code)(Java Doc)
protected Vector mySubscriptions(Code)(Java Doc)
protected ParamParser paramParser(Code)(Java Doc)
protected PersistentState persistentState(Code)(Java Doc)
protected UTILPreference prefHelper(Code)(Java Doc)
protected UTILPrepPhrase prepHelper(Code)(Java Doc)
protected Plan realityPlan(Code)(Java Doc)
protected boolean showinfoOnFailure(Code)(Java Doc)
protected boolean skipLowConfidence(Code)(Java Doc)
protected UTILVerify verifyHelper(Code)(Java Doc)

Methods inherited from org.cougaar.lib.filter.UTILPluginAdapter
public void addFilter(UTILFilterCallback callbackObj)(Code)(Java Doc)
protected ParamMap createParamTable(Vector envParams, MessageAddress ident)(Code)(Java Doc)
protected void debug(String message)(Code)(Java Doc)
protected boolean didSpawn()(Code)(Java Doc)
protected void error(String message)(Code)(Java Doc)
protected void execute()(Code)(Java Doc)
protected void fatal(String message)(Code)(Java Doc)
protected PersistentState findState()(Code)(Java Doc)
protected String getClassName()(Code)(Java Doc)
protected String getClassName(Object obj)(Code)(Java Doc)
public String getClusterName()(Code)(Java Doc)
public void getEnvData()(Code)(Java Doc)
final protected LDMService getLDMService()(Code)(Java Doc)
protected LoggingService getLoggingService()(Code)(Java Doc)
public ParamMap getMyParams()(Code)(Java Doc)
public String getName()(Code)(Java Doc)
protected MessageAddress getOriginalAgentID()(Code)(Java Doc)
protected void info(String message)(Code)(Java Doc)
protected boolean isDebugEnabled()(Code)(Java Doc)
protected boolean isErrorEnabled()(Code)(Java Doc)
protected boolean isFatalEnabled()(Code)(Java Doc)
protected boolean isInfoEnabled()(Code)(Java Doc)
protected boolean isWarnEnabled()(Code)(Java Doc)
protected void justRehydrated()(Code)(Java Doc)
public void localSetup()(Code)(Java Doc)
public void preFilterSetup()(Code)(Java Doc)
final protected void publishAdd(Object o)(Code)(Java Doc)
final protected void publishChange(Object o)(Code)(Java Doc)
final protected void publishRemove(Object o)(Code)(Java Doc)
protected void registerPersistentState(Object obj)(Code)(Java Doc)
protected void rehydrateState(List stuff)(Code)(Java Doc)
public void removeFilter(UTILFilterCallback callbackObj)(Code)(Java Doc)
final public void setLDMService(LDMService s)(Code)(Java Doc)
public void setLoggingService(LoggingService bs)(Code)(Java Doc)
public void setupFilters()(Code)(Java Doc)
final protected void setupSubscriptions()(Code)(Java Doc)
public IncrementalSubscription subscribeFromCallback(UnaryPredicate pred)(Code)(Java Doc)
public IncrementalSubscription subscribeFromCallback(UnaryPredicate pred, Collection specialContainer)(Code)(Java Doc)
public void updateAllocationResult(PlanElement cpe)(Code)(Java Doc)
protected void warn(String message)(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.