BSE::TB::TagOwner - mixin for objects with tags
my $article = ...;
$article->set_tags([ qw/tag1 tag2/ ], \$error); $article->remove_tags;
my @tags = $article->tag_objects; my @tag_names = $article->tags; my @tag_ids = $article->tag_ids;
if ($article->has_tags([ "tag1", "tag2" ])) { ... }
This class is a mix-in that implements tags for the mixed-into object.
Set the specified tags on the object, replacing all existing tags.
Remove all tags from the object.
Return all existing tags on the object as tag objects.
Returns all existing tags on the object as tag names.
Returns all existing tags on the object as tag ids.
Return all tag membership links for the object.
has_tags(\@tags)
Check that all of the specified tags are on the object.
Return the tag (if any) by name for this object type.
Returns an empty list if no such tag is found.
collection_with_tags()
This is a wrapper for collection_with_tags() in the BSE::TB::TagOwners manpage
that passes $self as the self
parameter in \%opts.
These need to be implemented by the class that wants tags.
Return a short constant string identifying owner class of the tags.
The numeric id of the specific owner object of the tags.
The name of the class for collections of the tag owner.
Tony Cook <tony@develop-help.com>