Path::I...p::File(3)

hii bestie πŸ’– welcome to the Path::I...p::File(3) page β€” it’s the User Contributed Perl Documentation version, and the full module name is a whole mouthful: Path::IsDev::Role::Matcher::Child::BaseName::MatchRegexp::File.

🌸 NAME 🌸

Path::IsDev::Role::Matcher::Child::BaseName::MatchRegexp::File β€” this role matches when any children have basenames that match a regexp, and those matching children are also files. No cap, that’s the whole vibe. πŸ’…

πŸ’– VERSION πŸ’–

version 1.001003 β€” that’s the version, bestie. ✨

✨ METHODS ✨

child_basename_matchregexp_file

Okay so the call looks like this:

$class->child_basename_matchregexp_file( $result_object, $regexp );

Given a regexp $regexp, match if any of "$result_object->path->children" match the given regexp, on the condition that those that match are also files. Basically: regexp match + file check, together, iconic. πŸŽ€

Example time:

if ( $self->child_basename_matchregexp_file( $result_object, qr/^Change(.*)$/i ) ) {
    # result_object->path() contains at least one child that is a file and matches the regexp
}

We love a clear example 🫢

🫢 PRIVATE METHODS 🫢

_this_child_isfile

Private helper call, bestie:

if ( $class->_this_child_isfile( $result_object, $child_path ) ) {
    ...
}

iykyk πŸ™ˆ

πŸ‘‘ AUTHOR πŸ‘‘

Kent Fredric <kentnl@cpan.org> β€” author, periodt. πŸ‘‘

This software is copyright (c) 2017 by Kent Fredric <kentfredric@gmail.com>.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

Okay bye bestie 🫢 this page comes from perl v5.42.0, dated 2017-03-11, with manual tag Path::I...p::File(3) β€” slay. πŸ’…

πŸ“¦ where this page comes from