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