use of org.polymap.core.data.pipeline.Param in project polymap4-core by Polymap4.
the class StatisticsSupplier method createContents.
@Override
public Control createContents(Composite parent, Param<Object> param, PipelineProcessorSite site) {
this.layerId = site.layerId.get();
Composite container = new Composite(parent, SWT.NONE);
container.setLayout(FormLayoutFactory.defaults().spacing(3).margins(0, 0, 3, 0).create());
// Label
l = new Label(container, SWT.NONE);
l.setFont(UIUtils.italic(l.getFont()));
updateUI();
//
Button btn = new Button(container, SWT.PUSH);
btn.setText("FLUSH CACHE");
btn.setToolTipText("Reset timestamp so that next access will re-fetch contents from backend store");
btn.addSelectionListener(UIUtils.selectionListener(ev -> {
StoreCacheProcessor.lastUpdated.put(layerId, new AtomicLong2());
updateUI();
}));
// layout
FormDataFactory.on(l).fill().noBottom();
FormDataFactory.on(btn).top(l).left(30).right(70).bottom(100);
return container;
}
Aggregations