org.kuali.rice.krms.framework.engine
Class EngineResultsImpl

java.lang.Object
  extended by org.kuali.rice.krms.framework.engine.EngineResultsImpl
All Implemented Interfaces:
EngineResults

public class EngineResultsImpl
extends Object
implements EngineResults

An implementation of EngineResults using List<ResultEvent> for results and Map for attributes

Author:
Kuali Rice Team (rice.collab@kuali.org)

Constructor Summary
EngineResultsImpl()
           
 
Method Summary
 void addResult(ResultEvent result)
          Add the given ResultEvent
 List<ResultEvent> getAllResults()
          Return a shallow copy of the list of ResultEvents.
 Object getAttribute(String key)
          Return the attribute of the given key
 ResultEvent getResultEvent(int index)
          Deprecated. use getAllResults() instead, this method will be removed in a future version
 List<ResultEvent> getResultsOfType(String type)
          Return the ResultEvents of the given type
 void setAttribute(String key, Object attr)
          Set the attribute of the given values
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EngineResultsImpl

public EngineResultsImpl()
Method Detail

addResult

public void addResult(ResultEvent result)
Description copied from interface: EngineResults
Add the given ResultEvent

Specified by:
addResult in interface EngineResults
Parameters:
result - to add

getAllResults

public List<ResultEvent> getAllResults()
Return a shallow copy of the list of ResultEvents.

Specified by:
getAllResults in interface EngineResults
Returns:
a shallow copy of all the ResultEvents

getResultEvent

@Deprecated
public ResultEvent getResultEvent(int index)
Deprecated. use getAllResults() instead, this method will be removed in a future version

Returns null, unimplemented.

Specified by:
getResultEvent in interface EngineResults
Parameters:
index - of the ResultEvent to return
Returns:
null

getResultsOfType

public List<ResultEvent> getResultsOfType(String type)
Description copied from interface: EngineResults
Return the ResultEvents of the given type

Specified by:
getResultsOfType in interface EngineResults
Parameters:
type - of result events to return
Returns:
List of the given type

getAttribute

public Object getAttribute(String key)
Description copied from interface: EngineResults
Return the attribute of the given key

Specified by:
getAttribute in interface EngineResults
Parameters:
key - to return the attribute of
Returns:
Object that is the attribute for the given key
See Also:
EngineResults.getAttribute(java.lang.String)

setAttribute

public void setAttribute(String key,
                         Object attr)
Description copied from interface: EngineResults
Set the attribute of the given values

Specified by:
setAttribute in interface EngineResults
Parameters:
key - to set the given attribute of
attr - to set as the given key's attribute
See Also:
EngineResults.setAttribute(java.lang.String, java.lang.Object)


Copyright © 2005-2014 The Kuali Foundation. All Rights Reserved.