001 package org.apache.myfaces.tobago.taglib.component;
002
003 /*
004 * Licensed to the Apache Software Foundation (ASF) under one or more
005 * contributor license agreements. See the NOTICE file distributed with
006 * this work for additional information regarding copyright ownership.
007 * The ASF licenses this file to You under the Apache License, Version 2.0
008 * (the "License"); you may not use this file except in compliance with
009 * the License. You may obtain a copy of the License at
010 *
011 * http://www.apache.org/licenses/LICENSE-2.0
012 *
013 * Unless required by applicable law or agreed to in writing, software
014 * distributed under the License is distributed on an "AS IS" BASIS,
015 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
016 * See the License for the specific language governing permissions and
017 * limitations under the License.
018 */
019
020 import org.apache.myfaces.tobago.apt.annotation.Facet;
021 import org.apache.myfaces.tobago.apt.annotation.Tag;
022 import org.apache.myfaces.tobago.apt.annotation.TagAttribute;
023 import org.apache.myfaces.tobago.apt.annotation.UIComponentTag;
024 import org.apache.myfaces.tobago.apt.annotation.UIComponentTagAttribute;
025 import org.apache.myfaces.tobago.taglib.decl.HasBinding;
026 import org.apache.myfaces.tobago.taglib.decl.HasDimension;
027 import org.apache.myfaces.tobago.taglib.decl.HasId;
028 import org.apache.myfaces.tobago.taglib.decl.HasLabel;
029 import org.apache.myfaces.tobago.taglib.decl.HasState;
030
031 /**
032 * Renders a page element.
033 */
034 @Tag(name = "page")
035 @UIComponentTag(
036 uiComponent = "org.apache.myfaces.tobago.component.UIPage",
037 rendererType = "Page",
038 facets =
039 {@Facet(name = "action", description = "Contains an instance of UICommand (tc:command) for an auto-action",
040 allowedChildComponenents = "org.apache.myfaces.tobago.Command"),
041 @Facet(name = "resizeAction",
042 description ="Contains an instance of UICommand (tc:command) or a UIForm (tc:form) with a UICommand"
043 + " for a resize-action",
044 allowedChildComponenents = {"org.apache.myfaces.tobago.Command", "org.apache.myfaces.tobago.Form"}),
045 @Facet(name = "menuBar", description = "Menubar"),
046 @Facet(name = "layout", description = "Contains an instance of UILayout")})
047
048 public interface PageTagDeclaration extends TobagoBodyTagDeclaration, HasLabel, HasId, HasDimension, HasBinding,
049 HasState {
050 /**
051 * Possible values for doctype are:
052 * <dl>
053 * <dt>strict</dt><dd>HTML 4.01 Strict DTD</dd>
054 * <dt>loose</dt><dd>HTML 4.01 Transitional DTD</dd>
055 * <dt>frameset</dt><dd>HTML 4.01 Frameset DTD</dd>
056 * </dl>
057 * All other values are ignored and no DOCTYPE is set.
058 */
059 @TagAttribute
060 @UIComponentTagAttribute(defaultValue = "loose")
061 @Deprecated
062 void setDoctype(String doctype);
063
064 /**
065 * Contains the id of the component wich should have the focus after
066 * loading the page.
067 * Set to emtpy string for disabling setting of focus.
068 * Default (null) enables the "auto focus" feature.
069 */
070 @TagAttribute
071 @UIComponentTagAttribute()
072 void setFocusId(String focusId);
073
074 /**
075 * Absolute URL to an image or image name to lookup in tobago resource path
076 * representing the application. In HTML it is used as a favicon.
077 */
078 @TagAttribute
079 @UIComponentTagAttribute()
080 void setApplicationIcon(String icon);
081
082 }