try {  resource.setProperties(); userName = getIWSlideSession().getUserFullName(); } catch (IOException e) { e.printStackTrace(); }
	protected void initializeContent() {				WebdavExtendedResource resource = getWebdavExtendedResource();		String userName = null;		try {			// Making sure all properties are set			resource.setProperties();			userName = getIWSlideSession().getUserFullName();		}		catch (IOException e) {			e.printStackTrace();		}				if (resource != null) {			String resourceName = resource.getDisplayName();			int row = 1;						Table table = new Table();			table.setId(this.getId() + "_table");//			table.setWidth("100%");//			table.setBorder(1);						table.mergeCells(1, row, 2, row);			HtmlOutputText docDetails = getBundle().getLocalizedText("document_details");			docDetails.setStyleClass("wf_text");			table.add(docDetails);							HtmlOutputLink link = new HtmlOutputLink();			link.setValue(resource.getEncodedPath());			link.setStyleClass("wf_listlink");			link.setId(getId() + "_dl");			link.getChildren().add(getBundle().getLocalizedText("download_view"));						table.add(getText("document_name"), 1, ++row);			table.add(WFUtil.getText(resourceName,"wf_listtext"), 2, row);			table.add(link, 2, ++row);			table.add(getText("size"), 1, ++row);			table.add(WFUtil.getText(FileUtil.getHumanReadableSize(resource.getGetContentLength()),"wf_listtext"), 2, row);			table.add(getText("content_type"), 1, ++row);			table.add(WFUtil.getText(resource.getGetContentType(),"wf_listtext"), 2, row);						table.add(getText("creation_date"), 1, ++row);			table.add(WFUtil.getText(new IWTimestamp(resource.getCreationDate()).toString(),"wf_listtext"), 2, row);						table.add(getText("modification_date"), 1, ++row);			table.add(WFUtil.getText(new IWTimestamp(resource.getGetLastModified()).toString(),"wf_listtext"), 2, row);						table.add(getText("locked_unlocked"), 1, ++row);			if (resource.isLocked()) {				HtmlGraphicImage lock = new HtmlGraphicImage();				lock.setUrl(IWMainApplication.getDefaultIWMainApplication().getURIFromURL(WFUtil.getContentBundle().getResourcesVirtualPath())+"/images/locked.gif");				lock.setId(this.getId()+"_lock");				lock.setHeight("16");// sizes that make sense 16/32/64/128				lock.setStyle("alignment:bottom");				table.add(lock, 2, row);				table.add(getText("locked", "wf_listtext"), 2, row);			} else {				table.add(getText("unlocked", "wf_listtext"), 2, row);			}			table.add(WFUtil.getText("  - "), 2, row);						HtmlCommandButton lockToggler = new HtmlCommandButton();			lockToggler.setId(getId()+"_lockTogg");			lockToggler.getAttributes().put(PARAMETER_RESOURCE_PATH, resource.getPath());			if (resource.isLocked()) {				getBundle().getLocalizedUIComponent("unlock", lockToggler);//				lockToggler.setValue("Unlock");			} else {				getBundle().getLocalizedUIComponent("lock", lockToggler);//				lockToggler.setValue("Lock");			}			lockToggler.setStyleClass("wf_listlink");			lockToggler.setActionListener(WFUtil.createMethodBinding("#{contentviewerbean.processAction}", new Class[]{ActionEvent.class}));			lockToggler.getAttributes().put(ACTION, ACTION_TOGGLE_LOCK);			table.add(lockToggler, 2, row);			table.add(getText("checkout_status"), 1, ++row);			String checkedOut = resource.getCheckedOut();			if (checkedOut == null || "".equals(checkedOut)) {				table.add(getText("not_checked_out", "wf_listtext"), 2, row);			} else {				table.add(getText("checked_out", "wf_listtext"), 2, row);				table.add(WFUtil.getText(" ("+checkedOut.substring(checkedOut.lastIndexOf("/")+1)+")","wf_listtext"), 2, row);			}			table.add(WFUtil.getText("  - "), 2, row);						HtmlCommandButton checker = new HtmlCommandButton();			checker.setId(getId()+"_check");			checker.getAttributes().put(PARAMETER_RESOURCE_PATH, resource.getPath());			if (checkedOut == null || "".equals(checkedOut)) {				getBundle().getLocalizedUIComponent("check_out", checker);//				checker.setValue("Check out");				checker.getAttributes().put(ACTION, ACTION_CHECK_OUT);			} else if (VersionHelper.hasUserCheckedOutResource(resource, userName)) {				// Checka if current user has file checked out, or not...//				getBundle().getLocalizedUIComponent("check_out", checker);				getBundle().getLocalizedUIComponent("uncheck_out", checker);//			checker.setValue("Check out");			checker.getAttributes().put(ACTION, ACTION_UNCHECK_OUT);			} else {				checker.setValue("Check in/uncheck something...");			}			checker.setStyleClass("wf_listlink");			checker.setActionListener(WFUtil.createMethodBinding("#{contentviewerbean.processAction}", new Class[]{ActionEvent.class}));			table.add(checker, 2, row);									//Then add the version table			Table vTable = getVersionReportTable(resource);						++row;			table.mergeCells(1, row, 2, row);			table.add(vTable, 1, row);			this.getChildren().add(table);		}	}