aboutsummaryrefslogtreecommitdiffstats
path: root/server/src/com/vaadin/ui/declarative
diff options
context:
space:
mode:
authorJohn Ahlroos <john.ahlroos@jasoft.fi>2015-04-12 09:59:07 +0300
committerJohn Ahlroos <john@vaadin.com>2015-04-13 14:57:23 +0300
commit72d2fabc95384e1f7fdb6fbd9a9f5757437087ed (patch)
treef692871b48ecfc2ee6af5ae9ab2621f0033f9a38 /server/src/com/vaadin/ui/declarative
parent68c7963f085fc299ac9ebded9394b638c7392bb1 (diff)
downloadvaadin-framework-72d2fabc95384e1f7fdb6fbd9a9f5757437087ed.tar.gz
vaadin-framework-72d2fabc95384e1f7fdb6fbd9a9f5757437087ed.zip
Add getter for local id #17444
Change-Id: I0007bdf111bf516cb9e2f244b63fde42213f5c98
Diffstat (limited to 'server/src/com/vaadin/ui/declarative')
-rw-r--r--server/src/com/vaadin/ui/declarative/DesignContext.java13
1 files changed, 13 insertions, 0 deletions
diff --git a/server/src/com/vaadin/ui/declarative/DesignContext.java b/server/src/com/vaadin/ui/declarative/DesignContext.java
index fe3abcfb77..657e15896c 100644
--- a/server/src/com/vaadin/ui/declarative/DesignContext.java
+++ b/server/src/com/vaadin/ui/declarative/DesignContext.java
@@ -170,6 +170,7 @@ public class DesignContext implements Serializable {
* component, the mapping from c to the string is removed. Similarly, if
* component was mapped to some string s different from localId, the mapping
* from s to component is removed.
+ *
* @param component
* The component whose local id is to be set.
* @param localId
@@ -185,6 +186,18 @@ public class DesignContext implements Serializable {
}
/**
+ * Returns the local id for a component
+ *
+ * @param component
+ * The component whose local id to get.
+ * @return the local id of the component, or null if the component has no
+ * local id assigned
+ */
+ public String getComponentLocalId(Component component) {
+ return componentToLocalId.get(component);
+ }
+
+ /**
* Creates a mapping between the given caption and the component. Returns
* true if caption was already mapped to some component.
*