Java Doc for AbstractExternalizedFlowExecutionTests.java in  » Workflow-Engines » spring-webflow-1.0.4 » org » springframework » webflow » test » execution » 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 » Workflow Engines » spring webflow 1.0.4 » org.springframework.webflow.test.execution 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.springframework.webflow.test.execution.AbstractFlowExecutionTests
   org.springframework.webflow.test.execution.AbstractExternalizedFlowExecutionTests

All known Subclasses:   org.springframework.webflow.test.execution.AbstractXmlFlowExecutionTests,
AbstractExternalizedFlowExecutionTests
abstract public class AbstractExternalizedFlowExecutionTests extends AbstractFlowExecutionTests (Code)
Base class for flow integration tests that verify an externalized flow definition executes as expected. Supports caching of the flow definition built from an externalized resource to speed up test execution.
author:
   Keith Donald



Constructor Summary
public  AbstractExternalizedFlowExecutionTests()
     Constructs a default externalized flow execution test.
public  AbstractExternalizedFlowExecutionTests(String name)
     Constructs an externalized flow execution test with given name.

Method Summary
final protected  FlowcreateFlow(FlowDefinitionResource resource, FlowServiceLocator serviceLocator)
     Factory method to assemble a flow definition from a resource.
abstract protected  FlowBuildercreateFlowBuilder(Resource resource, FlowServiceLocator serviceLocator)
     Factory method to create the builder that will build the flow definition whose execution will be tested.
final protected  FlowDefinitionResourcecreateFlowDefinitionResource(String filePath)
     Convenient factory method that creates a FlowDefinitionResource from a file path.
final protected  FlowDefinitionResourcecreateFlowDefinitionResource(String fileDirectory, String fileName)
     Convenient factory method that creates a FlowDefinitionResource from a file in a directory.
protected  FlowDefinitionResourcecreateFlowDefinitionResource(File file)
     Convenient factory method that creates a FlowDefinitionResource from a file.
protected  FlowServiceLocatorcreateFlowServiceLocator()
     Returns the flow service locator to use during flow definition construction time for accessing externally managed flow artifacts such as actions and flows to be used as subflows.
final protected  FlowDefinitiongetFlowDefinition()
     Returns the flow definition being tested.
abstract protected  FlowDefinitionResourcegetFlowDefinitionResource()
     Returns the pointer to the resource that houses the definition of the flow to be tested.
protected  booleanisCacheFlowDefinition()
     Returns if flow definition caching is turned on.
protected  voidregisterMockServices(MockFlowServiceLocator serviceRegistry)
     Template method called by AbstractExternalizedFlowExecutionTests.createFlowServiceLocator() to allow registration of mock implementations of services needed to test the flow execution.
protected  voidsetCacheFlowDefinition(boolean cacheFlowDefinition)
     Sets the flag indicating if the flow definition built from an externalized resource as part of this test should be cached.
protected  voidsetFlowExecutionAttributes(AttributeMap executionAttributes)
     Sets system attributes to be associated with the flow execution the next time one is AbstractExternalizedFlowExecutionTests.startFlow() started by this test.
protected  voidsetFlowExecutionListener(FlowExecutionListener executionListener)
     Set a single listener to be attached to the flow execution the next time one is AbstractExternalizedFlowExecutionTests.startFlow() started by this test.
protected  voidsetFlowExecutionListeners(FlowExecutionListener[] executionListeners)
     Set the listeners to be attached to the flow execution the next time one is AbstractExternalizedFlowExecutionTests.startFlow() started by this test.


Constructor Detail
AbstractExternalizedFlowExecutionTests
public AbstractExternalizedFlowExecutionTests()(Code)
Constructs a default externalized flow execution test.
See Also:   AbstractExternalizedFlowExecutionTests.setName(String)



AbstractExternalizedFlowExecutionTests
public AbstractExternalizedFlowExecutionTests(String name)(Code)
Constructs an externalized flow execution test with given name.
Parameters:
  name - the name of the test
since:
   1.0.2




Method Detail
createFlow
final protected Flow createFlow(FlowDefinitionResource resource, FlowServiceLocator serviceLocator)(Code)
Factory method to assemble a flow definition from a resource. Called by AbstractExternalizedFlowExecutionTests.getFlowDefinition() to create the "main" flow to test. May also be called by subclasses to create subflow definitions whose executions should also be exercised by this test.
Parameters:
  resource - the flow definition resource the built flow definition, ready for execution
See Also:   AbstractExternalizedFlowExecutionTests.createFlowBuilder(Resource,FlowServiceLocator)



createFlowBuilder
abstract protected FlowBuilder createFlowBuilder(Resource resource, FlowServiceLocator serviceLocator)(Code)
Factory method to create the builder that will build the flow definition whose execution will be tested. Subclasses must implement.

A subclass may return a builder that sets up mock implementations of services needed locally by the flow definition at runtime.
Parameters:
  resource - the externalized flow definition resource location
Parameters:
  serviceLocator - the flow service locator the flow builder that will build the flow to be tested




createFlowDefinitionResource
final protected FlowDefinitionResource createFlowDefinitionResource(String filePath)(Code)
Convenient factory method that creates a FlowDefinitionResource from a file path. Typically called by subclasses overriding AbstractExternalizedFlowExecutionTests.getFlowDefinitionResource() .
Parameters:
  filePath - the full path to the externalized flow definition file the flow definition resource



createFlowDefinitionResource
final protected FlowDefinitionResource createFlowDefinitionResource(String fileDirectory, String fileName)(Code)
Convenient factory method that creates a FlowDefinitionResource from a file in a directory. Typically called by subclasses overriding AbstractExternalizedFlowExecutionTests.getFlowDefinitionResource() .
Parameters:
  fileDirectory - the directory containing the file
Parameters:
  fileName - the short file name the flow definition resource pointing to the file



createFlowDefinitionResource
protected FlowDefinitionResource createFlowDefinitionResource(File file)(Code)
Convenient factory method that creates a FlowDefinitionResource from a file. Typically called by subclasses overriding AbstractExternalizedFlowExecutionTests.getFlowDefinitionResource() .
Parameters:
  file - the file the flow definition resource



createFlowServiceLocator
protected FlowServiceLocator createFlowServiceLocator()(Code)
Returns the flow service locator to use during flow definition construction time for accessing externally managed flow artifacts such as actions and flows to be used as subflows.

This implementation just creates a MockFlowServiceLocator and populates it with services by calling AbstractExternalizedFlowExecutionTests.registerMockServices(MockFlowServiceLocator) . the flow artifact factory




getFlowDefinition
final protected FlowDefinition getFlowDefinition()(Code)
Returns the flow definition being tested.



getFlowDefinitionResource
abstract protected FlowDefinitionResource getFlowDefinitionResource()(Code)
Returns the pointer to the resource that houses the definition of the flow to be tested. Subclasses must implement.

Example usage:

 protected FlowDefinitionResource getFlowDefinitionResource() {
 return createFlowDefinitionResource("/WEB-INF/flows/order-flow.xml");
 }
 
the flow definition resource



isCacheFlowDefinition
protected boolean isCacheFlowDefinition()(Code)
Returns if flow definition caching is turned on.



registerMockServices
protected void registerMockServices(MockFlowServiceLocator serviceRegistry)(Code)
Template method called by AbstractExternalizedFlowExecutionTests.createFlowServiceLocator() to allow registration of mock implementations of services needed to test the flow execution. Useful when testing flow definitions in execution in isolation from flows and middle-tier services. Subclasses may override.
Parameters:
  serviceRegistry - the mock service registry (and locator)



setCacheFlowDefinition
protected void setCacheFlowDefinition(boolean cacheFlowDefinition)(Code)
Sets the flag indicating if the flow definition built from an externalized resource as part of this test should be cached. Default is false.



setFlowExecutionAttributes
protected void setFlowExecutionAttributes(AttributeMap executionAttributes)(Code)
Sets system attributes to be associated with the flow execution the next time one is AbstractExternalizedFlowExecutionTests.startFlow() started by this test. Useful for assigning attributes that influence flow execution behavior.
Parameters:
  executionAttributes - the system attributes to assign



setFlowExecutionListener
protected void setFlowExecutionListener(FlowExecutionListener executionListener)(Code)
Set a single listener to be attached to the flow execution the next time one is AbstractExternalizedFlowExecutionTests.startFlow() started by this test. Useful for attaching a listener that does test assertions during the execution of the flow.
Parameters:
  executionListener - the listener to attach



setFlowExecutionListeners
protected void setFlowExecutionListeners(FlowExecutionListener[] executionListeners)(Code)
Set the listeners to be attached to the flow execution the next time one is AbstractExternalizedFlowExecutionTests.startFlow() started by this test. Useful for attaching listeners that do test assertions during the execution of the flow.
Parameters:
  executionListeners - the listeners to attach
since:
   1.0.4



Methods inherited from org.springframework.webflow.test.execution.AbstractFlowExecutionTests
protected ApplicationView applicationView(ViewSelection viewSelection)(Code)(Java Doc)
protected void assertActiveFlowEquals(String expectedActiveFlowId)(Code)(Java Doc)
protected void assertCurrentStateEquals(String expectedCurrentStateId)(Code)(Java Doc)
protected void assertFlowExecutionActive()(Code)(Java Doc)
protected void assertFlowExecutionEnded()(Code)(Java Doc)
protected void assertModelAttributeCollectionSize(int expectedSize, String attributeName, ApplicationView viewSelection)(Code)(Java Doc)
protected void assertModelAttributeEquals(Object expectedValue, String attributeName, ApplicationView viewSelection)(Code)(Java Doc)
protected void assertModelAttributeNotNull(String attributeName, ApplicationView viewSelection)(Code)(Java Doc)
protected void assertModelAttributeNull(String attributeName, ApplicationView viewSelection)(Code)(Java Doc)
protected void assertViewNameEquals(String expectedViewName, ApplicationView viewSelection)(Code)(Java Doc)
protected ExternalContext createExternalContext(ParameterMap requestParameters)(Code)(Java Doc)
protected FlowExecutionFactory createFlowExecutionFactory()(Code)(Java Doc)
protected Object evaluateModelAttributeExpression(String attributeName, Map model)(Code)(Java Doc)
protected ExternalRedirect externalRedirect(ViewSelection viewSelection)(Code)(Java Doc)
protected FlowDefinitionRedirect flowDefinitionRedirect(ViewSelection viewSelection)(Code)(Java Doc)
protected FlowExecutionRedirect flowExecutionRedirect(ViewSelection viewSelection)(Code)(Java Doc)
protected Object getConversationAttribute(String attributeName)(Code)(Java Doc)
protected Object getFlashAttribute(String attributeName)(Code)(Java Doc)
protected Object getFlowAttribute(String attributeName)(Code)(Java Doc)
abstract protected FlowDefinition getFlowDefinition()(Code)(Java Doc)
protected FlowExecution getFlowExecution() throws IllegalStateException(Code)(Java Doc)
protected FlowExecutionFactory getFlowExecutionFactory()(Code)(Java Doc)
protected Object getRequiredConversationAttribute(String attributeName) throws IllegalStateException(Code)(Java Doc)
protected Object getRequiredConversationAttribute(String attributeName, Class requiredType) throws IllegalStateException(Code)(Java Doc)
protected Object getRequiredFlashAttribute(String attributeName) throws IllegalStateException(Code)(Java Doc)
protected Object getRequiredFlashAttribute(String attributeName, Class requiredType) throws IllegalStateException(Code)(Java Doc)
protected Object getRequiredFlowAttribute(String attributeName) throws IllegalStateException(Code)(Java Doc)
protected Object getRequiredFlowAttribute(String attributeName, Class requiredType) throws IllegalStateException(Code)(Java Doc)
protected void nullView(ViewSelection viewSelection)(Code)(Java Doc)
protected ViewSelection refresh() throws FlowExecutionException(Code)(Java Doc)
protected ViewSelection refresh(ExternalContext context) throws FlowExecutionException(Code)(Java Doc)
public void setExpressionParser(ExpressionParser expressionParser)(Code)(Java Doc)
protected ViewSelection signalEvent(String eventId) throws FlowExecutionException(Code)(Java Doc)
protected ViewSelection signalEvent(String eventId, ParameterMap requestParameters) throws FlowExecutionException(Code)(Java Doc)
protected ViewSelection signalEvent(String eventId, ExternalContext context) throws FlowExecutionException(Code)(Java Doc)
protected ViewSelection startFlow() throws FlowExecutionException(Code)(Java Doc)
protected ViewSelection startFlow(MutableAttributeMap input) throws FlowExecutionException(Code)(Java Doc)
protected ViewSelection startFlow(MutableAttributeMap input, ExternalContext context) throws FlowExecutionException(Code)(Java Doc)
protected void updateFlowExecution(FlowExecution flowExecution)(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.