001// *************************************************************************************************************************** 002// * Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file * 003// * distributed with this work for additional information regarding copyright ownership. The ASF licenses this file * 004// * to you under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance * 005// * with the License. You may obtain a copy of the License at * 006// * * 007// * http://www.apache.org/licenses/LICENSE-2.0 * 008// * * 009// * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an * 010// * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the * 011// * specific language governing permissions and limitations under the License. * 012// *************************************************************************************************************************** 013package org.apache.juneau.dto.html5; 014 015import org.apache.juneau.annotation.*; 016 017/** 018 * DTO for an HTML {@doc ExtHTML5.forms#the-progress-element <progress>} 019 * element. 020 * 021 * <ul class='seealso'> 022 * <li class='link'>{@doc DtoHtml5} 023 * </ul> 024 */ 025@Bean(typeName="progress") 026public class Progress extends HtmlElementMixed { 027 028 /** 029 * Creates an empty {@link Progress} element. 030 */ 031 public Progress() {} 032 033 /** 034 * Creates a {@link Progress} element with the specified child nodes. 035 * 036 * @param children The child nodes. 037 */ 038 public Progress(Object...children) { 039 children(children); 040 } 041 042 /** 043 * {@doc ExtHTML5.forms#attr-progress-max max} attribute. 044 * 045 * <p> 046 * Upper bound of range. 047 * 048 * @param max 049 * The new value for this attribute. 050 * Typically a {@link Number} or {@link String}. 051 * @return This object (for method chaining). 052 */ 053 public final Progress max(Object max) { 054 attr("max", max); 055 return this; 056 } 057 058 /** 059 * {@doc ExtHTML5.forms#attr-progress-value value} attribute. 060 * 061 * <p> 062 * Current value of the element. 063 * 064 * @param value 065 * The new value for this attribute. 066 * Typically a {@link Number} or {@link String}. 067 * @return This object (for method chaining). 068 */ 069 public final Progress value(Object value) { 070 attr("value", value); 071 return this; 072 } 073 074 075 //----------------------------------------------------------------------------------------------------------------- 076 // Overridden methods 077 //----------------------------------------------------------------------------------------------------------------- 078 079 @Override /* HtmlElement */ 080 public final Progress _class(String _class) { 081 super._class(_class); 082 return this; 083 } 084 085 @Override /* HtmlElement */ 086 public final Progress id(String id) { 087 super.id(id); 088 return this; 089 } 090 091 @Override /* HtmlElement */ 092 public final Progress style(String style) { 093 super.style(style); 094 return this; 095 } 096 097 @Override /* HtmlElementMixed */ 098 public Progress children(Object...children) { 099 super.children(children); 100 return this; 101 } 102 103 @Override /* HtmlElementMixed */ 104 public Progress child(Object child) { 105 super.child(child); 106 return this; 107 } 108}