HTML::O...lection(3)
π NAME π
HTML::Object::Collection β HTML Object XQuery Collection Class. This is the HTML::O...lection(3) manual page, from User Contributed Perl Documentation, bestie, and it's here to make collections of HTML elements make sense π
β¨
πΈ SYNOPSIS πΈ
use HTML::Object::Collection;
my $col = HTML::Object::Collection->new ||
die( HTML::Object::Collection->error, "\n" );
π¦ VERSION π¦
v0.2.0 β tiny version number, big main character energy π
π DESCRIPTION π
Okay so HTML::Object::Collection is literally a collection of HTML elements. XQuery uses it when a query is made with a selector or other criteria to group several HTML objects together, just like jQuery does. No cap, that's the whole vibe.
It inherits from HTML::Object::Document and does not do much except for a handful methods. Low-key iconic for being low-key π«Ά
π INHERITANCE π
Here's the family tree, and it's giving pipeline realness:
+-----------------------+ +----------------------------+ +--------------------------+
| HTML::Object::Element | --> | HTML::Object::DOM::Element | --> | HTML::Object::Collection |
+-----------------------+ +----------------------------+ +--------------------------+
π PROPERTIES π
π nodeValue
This returns or sets the value of the current node.
For document, element or collection, this returns undef; for attribute, text or comment, this returns the objct value π
For more information, the page points here: https://developer.mozilla.org/en-US/docs/Web/API/Node/nodeValue
π₯ METHODS π₯
β¨ as_string
When called, this will return the string representation of the first HTML element object it contains, similar to the behaviour of jQuery. But wait, there's an added feature: if this method is called with all set to 1 or a positive value, then it will return the string representation for all the HTML element objects it holds. Obsessed π«Ά
π¦ end
Set or get the end element. Simple, clean, slay π
π AUTHOR π
Jacques Deguest <jack@deguest.jp> π
β SEE ALSO β
All the little friends:
HTML::ObjectHTML::Object::AttributeHTML::Object::BooleanHTML::Object::ClosingHTML::Object::CollectionHTML::Object::CommentHTML::Object::DeclarationHTML::Object::DocumentHTML::Object::ElementHTML::Object::ExceptionHTML::Object::LiteralHTML::Object::NumberHTML::Object::RootHTML::Object::SpaceHTML::Object::TextHTML::Object::XQuery
π COPYRIGHT & LICENSE π
Copyright (c) 2021 DEGUEST Pte. Ltd.
All rights reserved
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
π cute sign-off: this page is from perl v5.42.2, dated 2026-02-15 β mwah, bestie! πβ¨
π¦ where this page comes from
- alpine 3.24: perl-html-object-doc 0.6.0-r1 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms