001/*
002 * Licensed to the Apache Software Foundation (ASF) under one or more
003 * contributor license agreements.  See the NOTICE file distributed with
004 * this work for additional information regarding copyright ownership.
005 * The ASF licenses this file to You under the Apache License, Version 2.0
006 * (the "License"); you may not use this file except in compliance with
007 * the License.  You may obtain a copy of the License at
008 *
009 *      http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017package org.apache.juneau.bean.html5;
018
019import org.apache.juneau.marshall.*;
020
021/**
022 * DTO for an HTML <a class="doclink" href="https://www.w3.org/TR/html5/text-level-semantics.html#the-rt-element">&lt;rt&gt;</a>
023 * element.
024 *
025 * <p>
026 * The rt element represents the ruby text component of a ruby annotation. It is used within
027 * a ruby element to mark up the annotation text that provides pronunciation or translation
028 * information for the base text. The rt element is part of the ruby annotation system and
029 * is used to provide annotations above or below the base text in languages that use complex
030 * writing systems, such as Japanese, Chinese, or Korean. It is typically used with rb (ruby
031 * base) elements to provide complete ruby annotations.
032 *
033 * <h5 class='section'>Examples:</h5>
034 * <p class='bcode w800'>
035 *    <jk>import static</jk> org.apache.juneau.bean.html5.HtmlBuilder.*;
036 *
037 *    <jc>// Simple ruby text</jc>
038 *    Rt <jv>simple</jv> = <jsm>rt</jsm>(<js>"かんじ"</js>);
039 *
040 *    <jc>// Rt with styling</jc>
041 *    Rt <jv>styled</jv> = <jsm>rt</jsm>(<js>"にほんご"</js>)
042 *       .class_(<js>"ruby-text"</js>);
043 *
044 *    <jc>// Rt with complex content</jc>
045 *    Rt <jv>complex</jv> = <jsm>rt</jsm>(
046 *       <js>"ふくざつな"</js>,
047 *       <jsm>strong</jsm>(<js>"かんじ"</js>),
048 *       <js>"のれい"</js>
049 *    );
050 *
051 *    <jc>// Rt with ID</jc>
052 *    Rt <jv>withId</jv> = <jsm>rt</jsm>(<js>"かんじ"</js>)
053 *       .id(<js>"ruby-text-1"</js>);
054 *
055 *    <jc>// Rt with styling</jc>
056 *    Rt <jv>styled2</jv> = <jsm>rt</jsm>(<js>"かんじ"</js>)
057 *       .style(<js>"font-size: 0.8em; color: #666;"</js>);
058 *
059 *    <jc>// Rt with multiple elements</jc>
060 *    Rt <jv>multiple</jv> = <jsm>rt</jsm>(
061 *       <js>"ふくざつな"</js>,
062 *       <jsm>rt</jsm>(<js>"かんじ"</js>),
063 *       <js>"の"</js>,
064 *       <jsm>rt</jsm>(<js>"れい"</js>)
065 *       );
066 *
067 *    // Rt with links
068 *    Rt withLinks = new Rt()
069 *       .children(
070 *          "かんじ",
071 *          new A().href("/dictionary/kanji").children("じしょ")
072 *       );
073 * </p>
074 *
075 * <h5 class='section'>See Also:</h5><ul>
076 *    <li class='link'><a class="doclink" href="https://juneau.apache.org/docs/topics/JuneauBeanHtml5">juneau-bean-html5</a>
077 * </ul>
078 */
079@Marshalled(typeName = "rt")
080public class Rt extends HtmlElementMixed<Rt> {
081
082   /**
083    * Creates an empty {@link Rt} element.
084    */
085   public Rt() {}
086
087   /**
088    * Creates a {@link Rt} element with the specified {@link Rt#children(Object[])} nodes.
089    *
090    * @param children The {@link Rt#children(Object[])} nodes. Must not be <jk>null</jk>.
091    */
092   public Rt(Object...children) {
093      children(children);
094   }
095}