NAME
WWW::USF::Directory::Entry::Affiliation - Information about an affiliation of an entry
VERSION
Version 0.002_002
SYNOPSIS
# Print the afflilation
say $affiliation;
# Does the affiliation have a department?
say $affiliation->has_department ? 'yes' : 'no';
DESCRIPTION
Information about an affiliation of an entry. These objects are typically created by WWW::USF::Directory.
CONSTRUCTOR
This is fully object-oriented, and as such before any method can be used, the constructor needs to be called to create an object to work with.
new
This will construct a new object.
- new(%attributes)
-
%attributes
is a HASH where the keys are attributes (specified in the "ATTRIBUTES" section). - new($attributes)
-
$attributes
is a HASHREF where the keys are attributes (specified in the "ATTRIBUTES" section). - new($role_department_string)
-
This is a special case where the
$role_department_string
is a string that came from the directory page in the formatrole \s+ : \s+ department
.
ATTRIBUTES
department
This is the department in which the affiliation applies.
role
Required. This is the role of the affiliation.
METHODS
stringify
This method is used to return a string that will be given when this object is used in a string context. This returns "role: department" or "role".
my $affiliation = WWW::USF::Directory::Entry::Affiliation->new(
role => 'My Role'
department => 'Department'
);
say $affiliation; # Prints "My Role: Department"
DEPENDENCIES
Moose 0.89
namespace::clean 0.04
AUTHOR
Douglas Christopher Wilson, <doug at somethingdoug.com>
BUGS AND LIMITATIONS
Please report any bugs or feature requests to bug-www-usf-directory at rt.cpan.org
, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=WWW::USF::Directory. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
I highly encourage the submission of bugs and enhancements to my modules.
LICENSE AND COPYRIGHT
Copyright 2010 Douglas Christopher Wilson.
This program is free software; you can redistribute it and/or modify it under the terms of either:
the GNU General Public License as published by the Free Software Foundation; either version 1, or (at your option) any later version, or
the Artistic License version 2.0.