newValueInput.setId(NEW_VALUES_ID);
newValueInput.setId(getNewInputId());
	public Table getMetadataTable(String resourcePath) {		WFResourceUtil localizer = WFResourceUtil.getResourceUtilContent();				//Create the table		Table metadataTable = new Table(3,2);		metadataTable.setId(metadataTable.getId() + "_ver");		metadataTable.setRowStyleClass(1,"wf_listheading");		metadataTable.setStyleClass("wf_listtable");				//Add the lines		List l = new ArrayList();				//Type dropdown selector		UIInput dropdown = new HtmlSelectOneMenu();		dropdown.setId(DROPDOWN_ID);		Locale locale = IWContext.getInstance().getCurrentLocale();				//First get the list with all metadata types		ArrayList tempTypes = new ArrayList(MetadataUtil.getMetadataTypes());		IWContext iwc = IWContext.getInstance();		WebDAVMetadataResource resource;		try {			resource = (WebDAVMetadataResource) IBOLookup.getSessionInstance(					iwc, WebDAVMetadataResource.class);			MetadataValueBean[] ret = resource.getMetadata(resourcePath);			//Remove already used types from the dropdown list			for(int i=0; i<ret.length;i++) {				tempTypes.remove(ret[i].getType());			}		}		catch (IBOLookupException e) {			e.printStackTrace();		}		catch (RemoteException e) {			e.printStackTrace();		}		catch (IOException e) {			e.printStackTrace();		}		int row = 1;				//Display dropdown if there are any more metadata types left to add		if(tempTypes.size()>0) {			Iterator iter = tempTypes.iterator();				//		Iterator iter = MetadataUtil.getMetadataTypes().iterator();			while(iter.hasNext()) {				String type = (String)iter.next();				String label = ContentBlock.getBundle().getLocalizedString(type,locale);								SelectItem item = new SelectItem(type, label, type, false);				l.add(item);			}				UISelectItems sItems = new UISelectItems();			sItems.setValue(l) ;			dropdown.getChildren().add(sItems);						metadataTable.add(dropdown, 1, row);						HtmlInputText newValueInput = new HtmlInputText();			newValueInput.setSize(40);			newValueInput.setId(NEW_VALUES_ID);			metadataTable.add(newValueInput, 2, row++);		}				HtmlCommandButton addButton = localizer.getButtonVB(ADD_ID, "save", this);		addButton.getAttributes().put(RESOURCE_PATH,resourcePath);		metadataTable.add(addButton, 2, row);		//		mainContainer.add(metadataTable);		return metadataTable;	}