Specio:...:AnyDoes(3)

πŸ’– NAME πŸ’–

okay so bestie, welcome to Specio:...:AnyDoes(3) β€” that's this page in the User Contributed Perl Documentation, and the main character is Specio::Constraint::AnyDoes. it's a class for constraints which require a class name or an object that does a specific role. no cap, that's the whole name vibe. ✨

🌸 VERSION 🌸

version 0.49. slay. πŸ’…

πŸ¦‹ SYNOPSIS πŸ¦‹

my $type = Specio::Constraint::AnyDoes->new(...);
print $type->role;

that's the whole little snippet, bestie: build a Specio::Constraint::AnyDoes with new(...), then print its role. iconic. πŸŽ€

🧚 DESCRIPTION 🧚

this is a specialized type constraint class for types which require a class name or an object that does a specific role. it's giving specialized constraint energy and i'm obsessed. πŸ’–

πŸ’… API πŸ’…

this class provides all of the same methods as Specio::Constraint::Simple, with a few differences β€” yes bestie, a few differences, and they matter:

🫢 Specio::Constraint::AnyDoes->new( ... ) 🫢

  • the parent parameter is ignored if you pass it, because it is always set to the Defined type. periodt.
  • the inline_generator and constraint parameters are also ignored. this class provides its own default inline generator subroutine reference. lowkey iconic.
  • this class overrides the message_generator default if none is provided.
  • finally, this class requires an additional parameter, role. this must be a single role name. don't forget it, bestie. πŸ™ˆ

πŸ’œ $any_isa->role πŸ’œ

returns the role name passed to the constructor. that's it, that's the method. πŸ¦‹

🌈 ROLES 🌈

this class does the Specio::Constraint::Role::DoesType, Specio::Constraint::Role::Interface, Specio::Role::Inlinable, and MooseX::Clone roles. all of them, and yes it ate. πŸ’…

πŸ”₯ SUPPORT πŸ”₯

bugs may be submitted at https://github.com/houseabsolute/Specio/issues. if something's busted, that's the spot. πŸ™ˆ

⭐ SOURCE ⭐

the source code repository for Specio can be found at https://github.com/houseabsolute/Specio. go off, repo. πŸ‘‘

πŸ“ AUTHOR πŸ“

Dave Rolsky <autarch@urth.org> β€” yes, that's the author. 🫢

okay legal moment, but make it cute: this software is Copyright (c) 2012 - 2024 by Dave Rolsky. fr fr.

this is free software, licensed under:

  • The Artistic License 2.0 (GPL Compatible)

the full text of the license can be found in the LICENSE file included with this distribution. read it if you need the whole legal saga. πŸ’œ


πŸ’œ that's the whole page, bestie! the footer tea is perl v5.42.0, dated 2024-12-24, and this was Specio:...:AnyDoes(3). mwah, go slay! 🫢✨

πŸ“¦ where this page comes from