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 java.net.*; 016 017import org.apache.juneau.*; 018import org.apache.juneau.annotation.*; 019import org.apache.juneau.internal.*; 020 021/** 022 * DTO for an HTML <a class="doclink" href="https://www.w3.org/TR/html5/embedded-content-0.html#the-source-element"><source></a> 023 * element. 024 * 025 * <h5 class='section'>See Also:</h5><ul> 026 * <li class='link'><a class="doclink" href="../../../../../index.html#jd.Html5">Overview > juneau-dto > HTML5</a> 027 * </ul> 028 */ 029@Bean(typeName="source") 030@FluentSetters 031public class Source extends HtmlElementVoid { 032 033 /** 034 * Creates an empty {@link Source} element. 035 */ 036 public Source() {} 037 038 /** 039 * Creates a {@link Source} element with the specified {@link Source#src(Object)} and {@link Source#type(String)} 040 * attributes. 041 * 042 * @param src The {@link Source#src(Object)} attribute. 043 * @param type The {@link Source#type(String)} attribute. 044 */ 045 public Source(Object src, String type) { 046 src(src).type(type); 047 } 048 049 /** 050 * <a class="doclink" href="https://www.w3.org/TR/html5/embedded-content-0.html#attr-source-src">src</a> attribute. 051 * 052 * <p> 053 * Address of the resource. 054 * 055 * <p> 056 * The value can be of any of the following types: {@link URI}, {@link URL}, {@link String}. 057 * Strings must be valid URIs. 058 * 059 * <p> 060 * URIs defined by {@link UriResolver} can be used for values. 061 * 062 * @param src 063 * The new value for this attribute. 064 * Typically a {@link URL} or {@link String}. 065 * @return This object. 066 */ 067 public final Source src(Object src) { 068 attrUri("src", src); 069 return this; 070 } 071 072 /** 073 * <a class="doclink" href="https://www.w3.org/TR/html5/embedded-content-0.html#attr-source-type">type</a> attribute. 074 * 075 * <p> 076 * Type of embedded resource. 077 * 078 * @param type The new value for this attribute. 079 * @return This object. 080 */ 081 public final Source type(String type) { 082 attr("type", type); 083 return this; 084 } 085 086 087 //----------------------------------------------------------------------------------------------------------------- 088 // Overridden methods 089 //----------------------------------------------------------------------------------------------------------------- 090 091 // <FluentSetters> 092 093 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 094 public Source _class(String _class) { 095 super._class(_class); 096 return this; 097 } 098 099 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 100 public Source accesskey(String accesskey) { 101 super.accesskey(accesskey); 102 return this; 103 } 104 105 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 106 public Source contenteditable(Object contenteditable) { 107 super.contenteditable(contenteditable); 108 return this; 109 } 110 111 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 112 public Source dir(String dir) { 113 super.dir(dir); 114 return this; 115 } 116 117 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 118 public Source hidden(Object hidden) { 119 super.hidden(hidden); 120 return this; 121 } 122 123 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 124 public Source id(String id) { 125 super.id(id); 126 return this; 127 } 128 129 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 130 public Source lang(String lang) { 131 super.lang(lang); 132 return this; 133 } 134 135 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 136 public Source onabort(String onabort) { 137 super.onabort(onabort); 138 return this; 139 } 140 141 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 142 public Source onblur(String onblur) { 143 super.onblur(onblur); 144 return this; 145 } 146 147 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 148 public Source oncancel(String oncancel) { 149 super.oncancel(oncancel); 150 return this; 151 } 152 153 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 154 public Source oncanplay(String oncanplay) { 155 super.oncanplay(oncanplay); 156 return this; 157 } 158 159 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 160 public Source oncanplaythrough(String oncanplaythrough) { 161 super.oncanplaythrough(oncanplaythrough); 162 return this; 163 } 164 165 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 166 public Source onchange(String onchange) { 167 super.onchange(onchange); 168 return this; 169 } 170 171 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 172 public Source onclick(String onclick) { 173 super.onclick(onclick); 174 return this; 175 } 176 177 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 178 public Source oncuechange(String oncuechange) { 179 super.oncuechange(oncuechange); 180 return this; 181 } 182 183 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 184 public Source ondblclick(String ondblclick) { 185 super.ondblclick(ondblclick); 186 return this; 187 } 188 189 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 190 public Source ondurationchange(String ondurationchange) { 191 super.ondurationchange(ondurationchange); 192 return this; 193 } 194 195 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 196 public Source onemptied(String onemptied) { 197 super.onemptied(onemptied); 198 return this; 199 } 200 201 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 202 public Source onended(String onended) { 203 super.onended(onended); 204 return this; 205 } 206 207 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 208 public Source onerror(String onerror) { 209 super.onerror(onerror); 210 return this; 211 } 212 213 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 214 public Source onfocus(String onfocus) { 215 super.onfocus(onfocus); 216 return this; 217 } 218 219 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 220 public Source oninput(String oninput) { 221 super.oninput(oninput); 222 return this; 223 } 224 225 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 226 public Source oninvalid(String oninvalid) { 227 super.oninvalid(oninvalid); 228 return this; 229 } 230 231 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 232 public Source onkeydown(String onkeydown) { 233 super.onkeydown(onkeydown); 234 return this; 235 } 236 237 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 238 public Source onkeypress(String onkeypress) { 239 super.onkeypress(onkeypress); 240 return this; 241 } 242 243 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 244 public Source onkeyup(String onkeyup) { 245 super.onkeyup(onkeyup); 246 return this; 247 } 248 249 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 250 public Source onload(String onload) { 251 super.onload(onload); 252 return this; 253 } 254 255 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 256 public Source onloadeddata(String onloadeddata) { 257 super.onloadeddata(onloadeddata); 258 return this; 259 } 260 261 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 262 public Source onloadedmetadata(String onloadedmetadata) { 263 super.onloadedmetadata(onloadedmetadata); 264 return this; 265 } 266 267 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 268 public Source onloadstart(String onloadstart) { 269 super.onloadstart(onloadstart); 270 return this; 271 } 272 273 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 274 public Source onmousedown(String onmousedown) { 275 super.onmousedown(onmousedown); 276 return this; 277 } 278 279 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 280 public Source onmouseenter(String onmouseenter) { 281 super.onmouseenter(onmouseenter); 282 return this; 283 } 284 285 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 286 public Source onmouseleave(String onmouseleave) { 287 super.onmouseleave(onmouseleave); 288 return this; 289 } 290 291 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 292 public Source onmousemove(String onmousemove) { 293 super.onmousemove(onmousemove); 294 return this; 295 } 296 297 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 298 public Source onmouseout(String onmouseout) { 299 super.onmouseout(onmouseout); 300 return this; 301 } 302 303 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 304 public Source onmouseover(String onmouseover) { 305 super.onmouseover(onmouseover); 306 return this; 307 } 308 309 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 310 public Source onmouseup(String onmouseup) { 311 super.onmouseup(onmouseup); 312 return this; 313 } 314 315 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 316 public Source onmousewheel(String onmousewheel) { 317 super.onmousewheel(onmousewheel); 318 return this; 319 } 320 321 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 322 public Source onpause(String onpause) { 323 super.onpause(onpause); 324 return this; 325 } 326 327 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 328 public Source onplay(String onplay) { 329 super.onplay(onplay); 330 return this; 331 } 332 333 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 334 public Source onplaying(String onplaying) { 335 super.onplaying(onplaying); 336 return this; 337 } 338 339 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 340 public Source onprogress(String onprogress) { 341 super.onprogress(onprogress); 342 return this; 343 } 344 345 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 346 public Source onratechange(String onratechange) { 347 super.onratechange(onratechange); 348 return this; 349 } 350 351 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 352 public Source onreset(String onreset) { 353 super.onreset(onreset); 354 return this; 355 } 356 357 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 358 public Source onresize(String onresize) { 359 super.onresize(onresize); 360 return this; 361 } 362 363 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 364 public Source onscroll(String onscroll) { 365 super.onscroll(onscroll); 366 return this; 367 } 368 369 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 370 public Source onseeked(String onseeked) { 371 super.onseeked(onseeked); 372 return this; 373 } 374 375 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 376 public Source onseeking(String onseeking) { 377 super.onseeking(onseeking); 378 return this; 379 } 380 381 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 382 public Source onselect(String onselect) { 383 super.onselect(onselect); 384 return this; 385 } 386 387 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 388 public Source onshow(String onshow) { 389 super.onshow(onshow); 390 return this; 391 } 392 393 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 394 public Source onstalled(String onstalled) { 395 super.onstalled(onstalled); 396 return this; 397 } 398 399 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 400 public Source onsubmit(String onsubmit) { 401 super.onsubmit(onsubmit); 402 return this; 403 } 404 405 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 406 public Source onsuspend(String onsuspend) { 407 super.onsuspend(onsuspend); 408 return this; 409 } 410 411 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 412 public Source ontimeupdate(String ontimeupdate) { 413 super.ontimeupdate(ontimeupdate); 414 return this; 415 } 416 417 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 418 public Source ontoggle(String ontoggle) { 419 super.ontoggle(ontoggle); 420 return this; 421 } 422 423 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 424 public Source onvolumechange(String onvolumechange) { 425 super.onvolumechange(onvolumechange); 426 return this; 427 } 428 429 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 430 public Source onwaiting(String onwaiting) { 431 super.onwaiting(onwaiting); 432 return this; 433 } 434 435 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 436 public Source spellcheck(Object spellcheck) { 437 super.spellcheck(spellcheck); 438 return this; 439 } 440 441 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 442 public Source style(String style) { 443 super.style(style); 444 return this; 445 } 446 447 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 448 public Source tabindex(Object tabindex) { 449 super.tabindex(tabindex); 450 return this; 451 } 452 453 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 454 public Source title(String title) { 455 super.title(title); 456 return this; 457 } 458 459 @Override /* GENERATED - org.apache.juneau.dto.html5.HtmlElement */ 460 public Source translate(Object translate) { 461 super.translate(translate); 462 return this; 463 } 464 465 // </FluentSetters> 466}