1 /* 2 * Licensed to the Apache Software Foundation (ASF) under one 3 * or more contributor license agreements. See the NOTICE file 4 * distributed with this work for additional information 5 * regarding copyright ownership. The ASF licenses this file 6 * to you under the Apache License, Version 2.0 (the 7 * "License"); you may not use this file except in compliance 8 * with the License. You may obtain a copy of the License at 9 * 10 * http://www.apache.org/licenses/LICENSE-2.0 11 * 12 * Unless required by applicable law or agreed to in writing, 13 * software distributed under the License is distributed on an 14 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 15 * KIND, either express or implied. See the License for the 16 * specific language governing permissions and limitations 17 * under the License. 18 */ 19 package javax.faces.component.html; 20 21 import javax.faces.component.UISelectOne; 22 23 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFComponent; 24 25 /** 26 * Allow the user to choose one option from a set of options. 27 * <p> 28 * Renders as an HTML table element, containing an input element for 29 * each child f:selectItem or f:selectItems elements. The input 30 * elements are rendered as type radio. 31 * </p> 32 * <p> 33 * The value attribute of this component is read to determine 34 * which of the available options is initially selected; its value should 35 * match the "value" property of one of the child SelectItem objects. 36 * </p> 37 * <p> 38 * On submit of the enclosing form, the value attribute's bound property 39 * is updated to contain the "value" property from the chosen SelectItem. 40 * </p> 41 * 42 */ 43 @JSFComponent 44 (name = "h:selectOneRadio", 45 clazz = "javax.faces.component.html.HtmlSelectOneRadio",template=true, 46 tagClass = "org.apache.myfaces.taglib.html.HtmlSelectOneRadioTag", 47 defaultRendererType = "javax.faces.Radio" 48 ) 49 abstract class _HtmlSelectOneRadio extends UISelectOne implements 50 _AccesskeyProperty, _UniversalProperties, _DisabledReadonlyProperties, 51 _FocusBlurProperties, _ChangeSelectProperties, _EventProperties, 52 _StyleProperties, _TabindexProperty, _DisabledClassEnabledClassProperties, 53 _LabelProperty 54 { 55 56 static public final String COMPONENT_FAMILY = 57 "javax.faces.SelectOne"; 58 static public final String COMPONENT_TYPE = 59 "javax.faces.HtmlSelectOneRadio"; 60 61 /** 62 * Width in pixels of the border to be drawn around the table containing the options list. 63 * 64 * @JSFProperty 65 * defaultValue="Integer.MIN_VALUE" 66 */ 67 public abstract int getBorder(); 68 69 /** 70 * Orientation of the options list. Valid values are 71 * "pageDirection" for a vertical layout, or "lineDirection" for 72 * horizontal. The default value is "lineDirection". 73 * 74 * @JSFProperty 75 */ 76 public abstract String getLayout(); 77 78 }