import java.util.Collections;
import java.util.List;
import java.util.function.Consumer;
+import java.util.function.Supplier;
import net.haspamelodica.swt.helper.gcs.GeneralGC;
import net.haspamelodica.swt.helper.swtobjectwrappers.Rectangle;
private final List<Runnable> redrawListeners;
private final Runnable redrawListenerForSubcomponents;
+ // Defines how the GUIComponent is referenced in SubmodelComponentParams
+ protected Supplier<String> identifierDelegate = () -> "class:".concat(getClass().getCanonicalName());
public GUIComponent(ViewModelModifiable model)
{
pin.removeRedrawListener(redrawListenerForSubcomponents);
callRedrawListeners();
}
+
+ /**
+ * @return an identifier used to reference this GUIComponent inside of {@link SubmodelComponentParams}
+ */
+ public String getIdentifier()
+ {
+ return identifierDelegate.get();
+ }
}
\ No newline at end of file