Class Tr


@Bean(typeName="tr") public class Tr extends HtmlElementContainer
DTO for an HTML <tr> element.

The tr element represents a row of cells in a table. It is used to group table cells (td and th elements) into horizontal rows. The tr element can contain multiple td (data cell) or th (header cell) elements, and is typically used within thead, tbody, or tfoot elements to organize table structure.

Examples:

import static org.apache.juneau.bean.html5.HtmlBuilder.*; // Simple table row with data cells Tr simple = tr( td("John"), td("25"), td("New York") ); // Table row with header cells Tr header = tr( th("Name"), th("Age"), th("City") ); // Table row with styling Tr styled = tr( td("Product A"), td("100"), td("$10.00") )._class("highlight-row"); // Table row with click handler Tr clickable = tr( td("Clickable Row") ).onclick("selectRow(this)"); // Table row with mixed cell types Tr mixed = tr( th("Total"), td("$1,000"), td("$2,000") ); // Table row with complex content Tr complex = tr( td( strong("Important"), " data" ), td("Value") );

The following convenience methods are provided for constructing instances of this bean:

See Also: