if (editor instanceof DialectEditor) {
DialectEditor dialectEditor = (DialectEditor)editor;
DRepresentation representation = dialectEditor.getRepresentation();
if (representation instanceof DDiagram) {
DDiagram diagram = (DDiagram)representation;
List<Layer> layers = diagram.getActivatedLayers();
for (Layer layer : layers) {
if ("PAR ValueBinding Layer".equals(layer.getName()))
return true;
}
}