NAME

OBO::Util::SubsetDefSet - A Set implementation of a subset definition.

SYNOPSIS

use OBO::Util::SubsetDefSet;

use OBO::Core::SubsetDef;

use strict;

my $my_set = OBO::Util::SubsetDefSet->new();

my @arr = $my_set->get_set();

my $n1 = OBO::Core::SubsetDef->new();

my $n2 = OBO::Core::SubsetDef->new();

my $n3 = OBO::Core::SubsetDef->new();

$n1->name("GO_SLIM");

$n2->name("CCO_SLIM");

$n3->name("SO_SLIM");

$n1->description("GO terms");

$n2->description("CCO terms");

$n3->description("SO terms");

$my_set->add($n1);

$my_set->add($n2);

$my_set->add($n3);

$my_set->remove($n1);

$my_set->add($n1);

$my_set->remove($n1);

DESCRIPTION

A set (OBO::Util::Set) of subset definitions (OBO::Core::SubsetDef).

AUTHOR

Erick Antezana, <erick.antezana -@- gmail.com>

COPYRIGHT AND LICENSE

Copyright (C) 2006, 2007, 2008, 2009, 2010 by Erick Antezana

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.7 or, at your option, any later version of Perl 5 you may have available.

contains

Usage    - $set->contains()
Returns  - true if this set contains the given element
Args     - the element (OBO::Core::SubsetDef) to be checked
Function - checks if this set constains the given element

equals

Usage    - $set->equals()
Returns  - true or false
Args     - the set (OBO::Util::SubsetDefSet) to compare with
Function - tells whether this set is equal to the given one

remove

Usage    - $set->remove($element)
Returns  - the removed element
Args     - the element (OBO::Core::SubsetDef) to be removed
Function - removes an element from this set