List of usage examples for javax.xml.registry.infomodel Slot hashCode
@HotSpotIntrinsicCandidate public native int hashCode();
From source file:it.cnr.icar.eric.client.ui.thin.RegistryObjectCollectionBean.java
private List<RegistryObjectBean> getSlotsSearchResultsBeans(RegistryObjectBean roBean) throws ClassNotFoundException, NoSuchMethodException, ExceptionInInitializerError, Exception { List<?> slots = roBean.getSlots(); if (slots == null) { return null; }// w w w.j a va2 s . c o m int numSlotObjects = slots.size(); @SuppressWarnings("unused") List<Object> list = new ArrayList<Object>(numSlotObjects); Iterator<?> roItr = slots.iterator(); if (log.isDebugEnabled()) { log.debug("Query results: "); } String objectType = "Slot"; int numCols = 5; // Replace ObjectType with Id. TODO - formalize this convention ArrayList<RegistryObjectBean> roBeans = new ArrayList<RegistryObjectBean>(numSlotObjects); for (@SuppressWarnings("unused") int i = 0; roItr.hasNext(); i++) { Slot slot = (Slot) roItr.next(); String header = null; Object columnValue = null; @SuppressWarnings("unused") ArrayList<Object> srvbHeader = new ArrayList<Object>(numCols); List<SearchResultValueBean> searchResultValueBeans = new ArrayList<SearchResultValueBean>(numCols); header = WebUIResourceBundle.getInstance().getString("Details"); columnValue = roBean.getId() + "." + slot.hashCode(); searchResultValueBeans.add(new SearchResultValueBean(header, columnValue)); header = WebUIResourceBundle.getInstance().getString("Name"); columnValue = slot.getName(); searchResultValueBeans.add(new SearchResultValueBean(header, columnValue)); header = WebUIResourceBundle.getInstance().getString("Slot Type"); columnValue = slot.getSlotType(); searchResultValueBeans.add(new SearchResultValueBean(header, columnValue)); header = WebUIResourceBundle.getInstance().getString("Values"); columnValue = slot.getValues(); searchResultValueBeans.add(new SearchResultValueBean(header, columnValue)); RegistryObjectBean srb = new RegistryObjectBean(searchResultValueBeans, roBean.getRegistryObject(), objectType, slot, false); roBeans.add(srb); } return roBeans; }