Skip to content
Snippets Groups Projects
Commit b0e9a9fe authored by Thorsten Vitt's avatar Thorsten Vitt
Browse files

Skeleton for infrastructure to collect aggregation trees

parent 25ef713f
Branches develop
No related tags found
No related merge requests found
package info.textgrid.services.aggregator.tree;
import info.textgrid.namespaces.metadata.core._2010.ObjectType;
public class Aggregation extends AggregationEntry {
public Aggregation(final ObjectType metadata) {
super(metadata);
}
}
package info.textgrid.services.aggregator.tree;
import info.textgrid.namespaces.metadata.core._2010.ObjectType;
public class AggregationEntry {
private final ObjectType metadata;
public AggregationEntry(final ObjectType metadata) {
this.metadata = metadata;
}
public ObjectType getMetadata() {
return metadata;
}
}
package info.textgrid.services.aggregator.tree;
import info.textgrid.namespaces.metadata.core._2010.ObjectType;
import info.textgrid.services.aggregator.AggregationTreeWalker;
import java.util.Deque;
import com.google.common.collect.Lists;
public class AggregationTreeFactory extends AggregationTreeWalker {
private final Deque<AggregationEntry> stack = Lists.newLinkedList();
private final Aggregation root;
protected AggregationTreeFactory(final ObjectType root) {
super();
this.root = new Aggregation(root);
stack.push(this.root);
walkAggregation(root, false);
}
@Override
protected boolean walk(final ObjectType object, final boolean again) {
// TODO Auto-generated method stub
return super.walk(object, again);
}
@Override
protected void walkAggregation(final ObjectType aggregation,
final boolean again) {
// TODO Auto-generated method stub
super.walkAggregation(aggregation, again);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment