ManaTools::Shared::PropertiesRole - a Properties Moose::Role
with 'ManaTools::Shared::PropertiesRole'; 1; ... my $f = Foo->new(); my @props = $f->properties(); my $vendor = $f->prop('vendor'); $f->prop('vendor', 'myself'); $f->remove('vendor'); $f->prop_from_file('vendor', '/sys/bus/scsi/2:0:0:0/vendor');
This Role is a collection of Properties
You can find documentation for this Role with the perldoc command: perldoc ManaTools::Shared::PropertiesRole
Maarten Vanraes <firstname.lastname@example.org>
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2, as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
array of string
this method returns a list of Property keys
1 if Property is assigned, 0 otherwise
this method checks if it has the properties assigned
$key: string $value: optional value to set
value of the Property
this method gets the value of a Property and optionally sets it
$key: string $file: file with value to set
value of the Property, or undef if failed
this method sets the value of a Property from a file and returns the value
this method removes a property