Zonemaster::LDNS::RRList(3pm)

Zonemaster::LDNS::RRList3pm

Class representing lists of resource records.

Usage

    my $rrlist = Zonemaster::LDNS::RRList->new( $rrs_aref );

Class methods

new()

Creates a new empty Zonemaster::LDNS::RRList object.

new($rrs)

Creates a new Zonemaster::LDNS::RRList object for the given resource records.

Takes a reference to an array of Zonemaster::LDNS::RR objects.

Returns a Zonemaster::LDNS::RRList object.

Instance methods

count()

Returns the number of RRs in the list.

compare($other)

Compares two Zonemaster::LDNS::RRList. The order of Zonemaster::LDNS::RR objects in the list does not matter. The TTL field is ignored, and the comparison of domain names is case insensitive.

Returns an integer, where 0 indicates equality.

get($pos)
    my $rr = Zonemaster::LDNS::RRList->get( 0 );

Retrieves the RR in the given position from the list.

Takes an integer.

Returns a Zonemaster::LDNS::RR object, or "undef" if there was no RR.

push($rr)

Pushes an RR onto the list.

pop()

Pops an RR off the list.

is_rrset()

Returns true or false depending on if the list is an RRset or not.

Note that the underlying LDNS function appears to have a bug as the comparison of the owner name field is case sensitive. See https://github.com/NLnetLabs/ldns/pull/251.

string()

Returns a string with the list of RRs in presentation format.

do_compare($other)

Calls the XS "compare" method with the arguments it needs, rather than the ones overloading gives.

to_string

Calls the XS "string" method with the arguments it needs, rather than the ones overloading gives. Functionally identical to string() from the Perl level, except for being a tiny little bit slower.

Pod errors

Hey! The above document had some coding errors, which are explained below:

Around line 40:

'=item' outside of any '=over'

Releases

2 releases since Debian 12 (Bookworm); the text changed 1 time.

  1. 12
  2. 13

From libzonemaster-ldns-perl 4.1.0+ds-1 in Debian 13 (Trixie). Parsed by carta from the page's man source.