001/** 002 * Copyright 2005-2018 The Kuali Foundation 003 * 004 * Licensed under the Educational Community License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.opensource.org/licenses/ecl2.php 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package org.kuali.rice.krad.uif.element; 017 018import org.kuali.rice.krad.datadictionary.parse.BeanTag; 019 020/** 021 * Content element that renders a non-breaking space HTML <code>&nbsp;</code> tag 022 * 023 * @author Kuali Rice Team (rice.collab@kuali.org) 024 */ 025@BeanTag(name = "space", parent = "Uif-Space") 026public class Space extends ContentElementBase { 027 private static final long serialVersionUID = 4655642965438419569L; 028 029 public Space() { 030 super(); 031 } 032 033 /** 034 * Indicates that this element renders itself and does not use a template 035 * 036 * <p> 037 * Since this method returns true, the renderOutput property provides 038 * the HTML string representing this element. 039 * </p> 040 * 041 * @return true - this object renders itself 042 * {@inheritDoc} 043 */ 044 @Override 045 public boolean isSelfRendered() { 046 return true; 047 } 048 049 /** 050 * Provides the HTML string to be used to render a non-breaking space 051 * 052 * <p>The HTML for a Space element is <code>&nbsp;</code></p> 053 * 054 * @return the HTML string for a non-breaking space 055 * {@inheritDoc} 056 */ 057 @Override 058 public String getRenderedHtmlOutput() { 059 return " "; 060 } 061}