Skip to content

Commit

Permalink
Refactor RecordMapProcessor to include a more generic metadataProcess…
Browse files Browse the repository at this point in the history
…or implementation. (#34)

* Refactor RecordMapProcessor to include a more generic metadataProcessor implementation.
  • Loading branch information
bjornandre authored Feb 9, 2024
1 parent 701327b commit 8631150
Showing 1 changed file with 2 additions and 7 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
package no.ssb.dlp.pseudo.core.map;

import io.reactivex.processors.FlowableProcessor;
import lombok.Getter;
import lombok.RequiredArgsConstructor;
import no.ssb.dlp.pseudo.core.field.ValueInterceptorChain;
Expand All @@ -11,12 +10,8 @@
public class RecordMapProcessor<T> {
private final ValueInterceptorChain valueInterceptorChain;
@Getter
private final MetadataProcessor<T> metadataProcessor;
@FunctionalInterface
public interface MetadataProcessor<T> {
// The MetadataProcessor is used to publish/subscribe to events related to the processing of each RecordMap
FlowableProcessor<T> toFlowableProcessor();
}
private final T metadataProcessor;

public Map<String, Object> init(Map<String, Object> r) {
return MapTraverser.traverse(r, valueInterceptorChain::init);
}
Expand Down

0 comments on commit 8631150

Please sign in to comment.