Package com.networknt.schema
Interface Collector<E>
- Type Parameters:
E
- element
- All Known Implementing Classes:
AbstractCollector
public interface Collector<E>
Basic interface that allows the implementers to collect the information and
return it.
-
Method Summary
-
Method Details
-
combine
This method should be called by the intermediate touch points that want to combine the data being collected by this collector. This is an optional method and could be used when the same collector is used for collecting data at multiple touch points or accumulating data at same touch point.- Parameters:
object
- Object
-
collect
E collect()Final method called by the framework that returns the actual collected data. If the collector is not accumulating data or being used to collect data at multiple touch points, only this method can be implemented.- Returns:
- E element
-