List of usage examples for com.vaadin.ui AbstractComponent hashCode
@Override public int hashCode()
From source file:com.expressui.core.util.StringUtil.java
License:Open Source License
/** * Generates a debug ID that is inserted into the HTML, which can be useful finding elements in a tool like FireBug. * * @param prefix prefix to prepend to debug ID * @param mainComponent component to add debug ID to, debug ID contains this component's class name * @param subComponent includes object hashcode from subcomponent to ensure uniqueness * @param suffix suffix to append to debug ID * @return debug ID/*from w w w. j a v a 2 s . c o m*/ */ public static String generateDebugId(String prefix, Object mainComponent, AbstractComponent subComponent, String suffix) { Class currentClass = mainComponent.getClass(); String simpleName = currentClass.getSimpleName(); return prefix + "-" + StringUtil.hyphenateCamelCase(simpleName) + "-" + suffix + "-" + subComponent.hashCode(); }