org.skyscreamer.yoga.listener
Class CountLimitRenderingListener
java.lang.Object
org.skyscreamer.yoga.listener.CountLimitRenderingListener
- All Implemented Interfaces:
- RenderingListener
public class CountLimitRenderingListener
- extends Object
- implements RenderingListener
This is a mechanism that will limit the number of children that are added to
a response. This is a security mechanism that will prevent potential yoga
induced OutOfMemoryError.
- See Also:
RenderingListener,
RenderingListenerRegistry,
YogaRequestContext
|
Method Summary |
|
eventOccurred(RenderingEvent<T> event)
The eventOccurred method is invoked by Yoga on each RenderingListener in the application's registry
before the response data is returned to the user |
void |
setMaxCount(int maxCount)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CountLimitRenderingListener
public CountLimitRenderingListener(int maxCount)
setMaxCount
public void setMaxCount(int maxCount)
eventOccurred
public <T> void eventOccurred(RenderingEvent<T> event)
- Description copied from interface:
RenderingListener
- The eventOccurred method is invoked by Yoga on each RenderingListener in the application's registry
before the response data is returned to the user
- Specified by:
eventOccurred in interface RenderingListener
- Parameters:
event - The RenderingEvent object provides the RenderingListener with context information about the
Yoga call, including the HTTP request and response, the selectors used, and the response data
Copyright © 2013. All Rights Reserved.