| UMMF documentation | Contained in the UMMF distribution. |
__validate_type__typecheckisaTagDefinitionisaFoundation__Extension_Mechanisms__TagDefinition__model_name __isAbstract__tangram_schema___initialize__initialize__createtagTypeset_tagTypecount_tagTypemultiplicityset_multiplicitycount_multiplicityownerset_owneradd_ownerremove_ownerclear_ownercount_ownertypedValueset_typedValueadd_typedValueremove_typedValueclear_typedValuecount_typedValue
UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition --
1.5
tagType : UMMF::UML_1_5::Foundation::Data_Types::Name private1changeableinstanceunorderedSet::Objectmultiplicity : UMMF::UML_1_5::Foundation::Data_Types::Multiplicity private1changeableinstanceunorderedSet::ObjectdefinedTag : THIS 0..* <---> owner : UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype 0..10..1changeableinstancenonepublicSet::Objecttype : THIS 1 <---> typedValue : UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue 0..*0..*changeableinstancenonepublicSet::Object__validate_typeUMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition->__validate_type($value);
Returns true if $value is a valid representation of UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition.
__typecheckUMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition->__typecheck($value, $msg);
Calls confess() with $msg if <UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition-__validate_type($value)>> is false.
isaTagDefinitionReturns true if receiver is a UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition. Other receivers will return false.
isaFoundation__Extension_Mechanisms__TagDefinitionReturns true if receiver is a UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition.
Other receivers will return false.
This is the fully qualified version of the isaTagDefinition method.
__model_name my $name = $obj_or_package->__model_name;
Returns the UML Model name ('Foundation::Extension_Mechanisms::TagDefinition') for an object or package of
this Classifier.
__isAbstract$package->__isAbstract;
Returns 0.
__tangram_schemamy $tangram_schema $obj_or_package->__tangram_schema
Returns a HASH ref that describes this Classifier for Tangram.
___initializeInitialize all Attributes and AssociationEnds in a instance of this Classifier. Does not initalize slots in its Generalizations.
See also: __initialize.
__initializeInitialize all slots in this Classifier and all its Generalizations.
See also: ___initialize.
__createCalls all <<create>> Methods for this Classifier and all Generalizations.
See also: ___create.
tagTypemy $val = $obj->tagType;
Returns the UMMF::UML_1_5::Foundation::Data_Types::Name value of Attribute tagType.
set_tagType$obj->set_tagType($val);
Sets the value of Attribute tagType.
$val must be of type UMMF::UML_1_5::Foundation::Data_Types::Name or undef.
Returns $obj.
count_tagType$obj->count_tagType;
Returns the number of elements (0 or 1) in tagType.
multiplicitymy $val = $obj->multiplicity;
Returns the UMMF::UML_1_5::Foundation::Data_Types::Multiplicity value of Attribute multiplicity.
set_multiplicity$obj->set_multiplicity($val);
Sets the value of Attribute multiplicity.
$val must be of type UMMF::UML_1_5::Foundation::Data_Types::Multiplicity or undef.
Returns $obj.
count_multiplicity$obj->count_multiplicity;
Returns the number of elements (0 or 1) in multiplicity.
ownermy $val = $obj->owner;
Returns the AssociationEnd owner value of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype.
set_owner$obj->set_owner($val);
Sets the AssociationEnd owner value.
$val must of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype.
Returns $obj.
add_owner$obj->add_owner($val);
Adds the AssociationEnd owner value.
$val must of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype.
Throws exception if a value already exists.
Returns $obj.
remove_owner$obj->remove_owner($val);
Removes the AssociationEnd owner value $val.
Returns $obj.
clear_owner$obj->clear_owner;
Clears the AssociationEnd owner links to UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype.
Returns $obj.
count_owner$obj->count_owner;
Returns the number of elements of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype associated with owner.
typedValuemy @val = $obj->typedValue; my $ary_val = $obj->typedValue;
Returns the AssociationEnd typedValue values of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue.
In array context, returns all the objects in the Association.
In scalar context, returns an array ref of all the objects in the Association.
set_typedValue$obj->set_typedValue(@val);
Sets the AssociationEnd typedValue value.
Elements of @val must of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue.
Returns $obj.
add_typedValue$obj->add_typedValue(@val);
Adds AssociationEnd typedValue values.
Elements of @val must of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue.
Returns $obj.
remove_typedValue$obj->remove_typedValue(@val);
Removes the AssociationEnd typedValue values @val.
Elements of @val must of type UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue.
Returns $obj.
clear_typedValue$obj->clear_typedValue;
Clears the AssociationEnd typedValue links to UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue.
Returns $obj.
count_typedValue$obj->count_typedValue;
Returns the number of elements associated with typedValue.
END OF DOCUMENT
| UMMF documentation | Contained in the UMMF distribution. |
# -*- perl -*- # DO NOT EDIT - This file is generated by UMMF; http://ummf.sourceforge.net # From template: $Id: Perl.txt,v 1.77 2006/05/14 01:40:03 kstephens Exp $ package UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition; #use 5.6.1; use strict; use warnings; ################################################################# # Version # our $VERSION = do { my @r = (q{1.5} =~ /\d+/g); sprintf "%d." . "%03d" x $#r, @r }; ################################################################# # Documentation #
################################################################# # Dependencies # use Carp qw(croak confess); use Set::Object 1.05; use Class::Multimethods 1.70; use Data::Dumper; use Scalar::Util qw(weaken); use UMMF::UML_1_5::__ObjectBase qw(:__ummf_array); ################################################################# # Generalizations # use base qw( UMMF::UML_1_5::Foundation::Core::ModelElement ); ################################################################# # Exports # our @EXPORT_OK = qw( ); our %EXPORT_TAGS = ( 'all' => \@EXPORT_OK ); ################################################################# # Validation #
sub __validate_type($$) { my ($self, $x) = @_; no warnings; UNIVERSAL::isa($x, 'UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition') ; }
sub __typecheck { my ($self, $x, $msg) = @_; confess("typecheck: $msg: type '" . 'UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition' . ": value '$x'") unless __validate_type($self, $x); }
sub isaTagDefinition { 1 }
sub isaFoundation__Extension_Mechanisms__TagDefinition { 1 } ################################################################# # Introspection #
sub __model_name { 'Foundation::Extension_Mechanisms::TagDefinition' }
sub __isAbstract { 0; } my $__tangram_schema;
sub __tangram_schema { my ($self) = @_; $__tangram_schema ||= { 'classes' => [ 'UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition' => { 'table' => 'Foundation__Extension_Mechanisms__TagDefinition', 'abstract' => 0, 'slots' => { # Attributes 'tagType' => { 'type_impl' => 'string', 'col' => 'tagType', } , 'multiplicity' => { 'type_impl' => 'ref', 'class' => 'UMMF::UML_1_5::Foundation::Data_Types::Multiplicity', 'col' => 'multiplicity', } , # Associations 'owner' => { 'type_impl' => 'ref', 'class' => 'UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype', 'null' => '1', 'col' => 'owner', } , 'typedValue' => { 'type_impl' => 'iset', 'class' => 'UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue', 'table' => 'Foundation__Extension_Mechanisms__TagDefinition__typedValue', 'coll' => 'type', } , }, 'bases' => [ 'UMMF::UML_1_5::Foundation::Core::ModelElement', ], 'sql' => { }, }, ], 'sql' => { # Note Tangram::Ref::get_exporter() has # "UPDATE $table SET $self->{col} = $refid WHERE id = $id", # The id_col is hard-coded, # Thus id_col will not work. #'id_col' => '__sid', #'class_col' => '__stype', }, # 'set_id' => sub { } # 'get_id' => sub { } }; } ################################################################# # Class Attributes # ################################################################# # Class Associations # ################################################################# # Initialization #
sub ___initialize { my ($self) = @_; # Attributes # Attribute tagType if ( exists $self->{'tagType'} ) { my $x = $self->{'tagType'}; $self->{'tagType'} = undef; $self->set_tagType($x); } else { } # Attribute multiplicity if ( exists $self->{'multiplicity'} ) { my $x = $self->{'multiplicity'}; $self->{'multiplicity'} = undef; $self->set_multiplicity($x); } else { } # Associations # AssociationEnd # definedTag 0..* # <--> # owner 0..1 UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype. if ( defined $self->{'owner'} ) { my $x = $self->{'owner'}; $self->{'owner'} = undef; $self->set_owner($x); } # AssociationEnd # type 1 # <--> # typedValue 0..* UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue. if ( defined $self->{'typedValue'} ) { my $x = $self->{'typedValue'}; $self->{'typedValue'} = Set::Object->new(); $self->set_typedValue(@$x); } $self; } my $__initialize_use;
sub __initialize { my ($self) = @_; # $DB::single = 1; unless ( ! $__initialize_use ) { $__initialize_use = 1; $self->__use('UMMF::UML_1_5::Foundation::Core::Element'); $self->__use('UMMF::UML_1_5::Foundation::Core::ModelElement'); } $self->UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition::___initialize; $self->UMMF::UML_1_5::Foundation::Core::Element::___initialize; $self->UMMF::UML_1_5::Foundation::Core::ModelElement::___initialize; $self; }
sub __create { my ($self, @args) = @_; # $DB::single = 1; $self->UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition::___create(@args); $self->UMMF::UML_1_5::Foundation::Core::Element::___create(); $self->UMMF::UML_1_5::Foundation::Core::ModelElement::___create(); $self; } ################################################################# # Attributes #
################################################################# # Attribute tagType # type = UMMF::UML_1_5::Foundation::Data_Types::Name # multiplicity = 1 # ordering = unordered # ownerScope = instance # initialValue =
sub tagType ($) { my ($self) = @_; ; my $val = $self->{'tagType'}; ; $val; }
sub set_tagType ($$) { my ($self, $val) = @_; ; if ( defined $val ) { ; } $self->{'tagType'} = $val ; ; $self; }
sub count_tagType ($) { my ($self) = @_; ; my $val = $self->{'tagType'}; ; defined $val ? 1 : 0; }
################################################################# # Attribute multiplicity # type = UMMF::UML_1_5::Foundation::Data_Types::Multiplicity # multiplicity = 1 # ordering = unordered # ownerScope = instance # initialValue =
sub multiplicity ($) { my ($self) = @_; ; my $val = $self->{'multiplicity'}; ; $val; }
sub set_multiplicity ($$) { my ($self, $val) = @_; ; if ( defined $val ) { $self->__use('UMMF::UML_1_5::Foundation::Data_Types::Multiplicity')->__typecheck($val, "UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition.multiplicity"); } $self->{'multiplicity'} = $val ; ; $self; }
sub count_multiplicity ($) { my ($self) = @_; ; my $val = $self->{'multiplicity'}; ; defined $val ? 1 : 0; } ################################################################# # Association #
################################################################# # AssociationEnd definedTag <---> owner # type = UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype # multiplicity = 0..1 # ordering =
sub owner ($) { my ($self) = @_; $self->{'owner'}; }
sub set_owner ($$) { my ($self, $val) = @_; no warnings; # Use of uninitialized value in string ne at ... my $old; if ( ($old = $self->{'owner'}) ne $val ) { # Recursion lock if ( defined $val ) { $self->__use('UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype')->__typecheck($val, "UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition.owner") } # Recursion lock $self->{'owner'} = $val ; # Remove and add associations with other ends. $old->remove_definedTag($self) if $old; $val->add_definedTag($self) if $val; } $self; }
sub add_owner ($$) { my ($self, $val) = @_; no warnings; # Use of uninitialized value in string ne at ... my $old; if ( ($old = $self->{'owner'}) ne $val ) { # Recursion lock $self->__use('UMMF::UML_1_5::Foundation::Extension_Mechanisms::Stereotype')->__typecheck($val, "UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition.owner"); # confess("UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition::owner: too many") # if defined $self->{'owner'}; # Recursion lock $self->{'owner'} = $val ; # Remove and add associations with other ends. $old->remove_definedTag($self) if $old; $val->add_definedTag($self) if $val; } $self; }
sub remove_owner ($$) { my ($self, $val) = @_; no warnings; # Use of uninitialized value in string ne at ... my $old; if ( ($old = $self->{'owner'}) eq $val ) { # Recursion lock $val = $self->{'owner'} = undef; # Recursion lock # Remove and add associations with other ends. $old->remove_definedTag($self) if $old; $val->add_definedTag($self) if $val; } }
sub clear_owner ($@) { my ($self) = @_; my $old; if ( defined ($old = $self->{'owner'}) ) { # Recursion lock my $val = $self->{'owner'} = undef; # Recursion lock # Remove and add associations with other ends. $old->remove_definedTag($self) if $old; $val->add_definedTag($self) if $val; } $self; }
sub count_owner ($) { my ($self) = @_; my $x = $self->{'owner'}; defined $x ? 1 : 0; }
################################################################# # AssociationEnd type <---> typedValue # type = UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue # multiplicity = 0..* # ordering =
sub typedValue ($) { my ($self) = @_; my $x = $self->{'typedValue'}; # confess("Container for typedValue $x is not a blessed ref: " . Data::Dumper->new([ $self ], [qw($self)])->Maxdepth(2)->Dump()) if $x && ref($x) !~ /::/; wantarray ? ($x ? $x->members() : ()) : [ $x ? $x->members() : () ]; }
sub set_typedValue ($@) { my ($self, @val) = @_; $self->clear_typedValue; $self->add_typedValue(@val); }
sub add_typedValue ($@) { my ($self, @val) = @_; my $x = $self->{'typedValue'} ||= Set::Object->new(); my $old; # Place holder for other MACRO. for my $val ( @val ) { # Recursion lock next if $x->includes($val); $self->__use('UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue')->__typecheck($val, "UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition.typedValue"); # Recursion lock $x->insert($val); # weaken? # Remove and add associations with other ends. $old->remove_type($self) if $old; $val->add_type($self) if $val; } $self; }
sub remove_typedValue ($@) { my ($self, @val) = @_; my $x = $self->{'typedValue'} ||= Set::Object->new(); for my $old ( @val ) { # Recursion lock next unless $x->includes($old); my $val = $old; $self->__use('UMMF::UML_1_5::Foundation::Extension_Mechanisms::TaggedValue')->__typecheck($val, "UMMF::UML_1_5::Foundation::Extension_Mechanisms::TagDefinition.typedValue"); # Recursion lock $x->remove($old); $val = undef; # Remove associations with other ends. $old->remove_type($self) if $old; $val->add_type($self) if $val; ; } $self; }
sub clear_typedValue ($) { my ($self) = @_; my $x = $self->{'typedValue'} ||= Set::Object->new(); my $val; # Place holder for other MACRO. $self->{'typedValue'} = Set::Object->new(); # Recursion lock for my $old ( $x->members() ) { # Recursion lock # Remove associations with other ends. $old->remove_type($self) if $old; $val->add_type($self) if $val; ; } $self; }
sub count_typedValue ($) { my ($self) = @_; my $x = $self->{'typedValue'}; defined $x ? $x->size : 0; } # End of Class TagDefinition
############################################################################ 1; # is true! ############################################################################ ### Keep these comments at end of file: kstephens@users.sourceforge.net 2003/04/06 ### ### Local Variables: ### ### mode:perl ### ### perl-indent-level:2 ### ### perl-continued-statement-offset:0 ### ### perl-brace-offset:0 ### ### perl-label-offset:0 ### ### End: ###