# -*- 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::Behavioral_Elements::Common_Behavior::Procedure;

#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
#

=head1 NAME

UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure -- 

=head1 VERSION

1.5

=head1 SYNOPSIS

=head1 DESCRIPTION 

=head1 USAGE

=head1 EXPORT

=head1 METATYPE

L<UMMF::UML_1_5::Foundation::Core::Class|UMMF::UML_1_5::Foundation::Core::Class>

=head1 SUPERCLASSES

L<UMMF::UML_1_5::Foundation::Core::ModelElement|UMMF::UML_1_5::Foundation::Core::ModelElement>




=head1 ATTRIBUTES


=head2 C<language> : UMMF::UML_1_5::Foundation::Data_Types::Name 


=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::Attribute|UMMF::UML_1_5::Foundation::Core::Attribute>

=item type = L<UMMF::UML_1_5::Foundation::Data_Types::Name|UMMF::UML_1_5::Foundation::Data_Types::Name>

=item visibility = C<private>

=item multiplicity = C<1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<unordered>

=item initialValue = I<UNSPECIFIED>

=item container_type = C<Set::Object>

=back


=head2 C<body> : UMMF::UML_1_5::Foundation::Data_Types::String 


=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::Attribute|UMMF::UML_1_5::Foundation::Core::Attribute>

=item type = L<UMMF::UML_1_5::Foundation::Data_Types::String|UMMF::UML_1_5::Foundation::Data_Types::String>

=item visibility = C<private>

=item multiplicity = C<1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<unordered>

=item initialValue = I<UNSPECIFIED>

=item container_type = C<Set::Object>

=back


=head2 C<isList> : UMMF::UML_1_5::Foundation::Data_Types::Boolean 


=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::Attribute|UMMF::UML_1_5::Foundation::Core::Attribute>

=item type = L<UMMF::UML_1_5::Foundation::Data_Types::Boolean|UMMF::UML_1_5::Foundation::Data_Types::Boolean>

=item visibility = C<private>

=item multiplicity = C<1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<unordered>

=item initialValue = I<UNSPECIFIED>

=item container_type = C<Set::Object>

=back



=head1 ASSOCIATIONS


=head2 C<procedure> : I<THIS> C<0..1> E<lt>---E<gt>  C<expression> : UMMF::UML_1_5::Foundation::Data_Types::Expression C<0..*>



=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::AssociationEnd|UMMF::UML_1_5::Foundation::Core::AssociationEnd>

=item type = L<UMMF::UML_1_5::Foundation::Data_Types::Expression|UMMF::UML_1_5::Foundation::Data_Types::Expression>

=item multiplicity = C<0..*>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<>

=item isNavigable = C<1>

=item aggregation = C<none>

=item visibility = C<public>

=item container_type = C<Set::Object>

=back


=head2 C<procedure> : I<THIS> C<0..1> E<lt>---E<gt>  C<method> : UMMF::UML_1_5::Foundation::Core::Method C<0..*>



=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::AssociationEnd|UMMF::UML_1_5::Foundation::Core::AssociationEnd>

=item type = L<UMMF::UML_1_5::Foundation::Core::Method|UMMF::UML_1_5::Foundation::Core::Method>

=item multiplicity = C<0..*>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<>

=item isNavigable = C<1>

=item aggregation = C<none>

=item visibility = C<public>

=item container_type = C<Set::Object>

=back


=head2 C<doActivity> : I<THIS> C<0..1> E<lt>---E<gt>  C<state_doActivity> : UMMF::UML_1_5::Behavioral_Elements::State_Machines::State C<0..1>



=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::AssociationEnd|UMMF::UML_1_5::Foundation::Core::AssociationEnd>

=item type = L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>

=item multiplicity = C<0..1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<>

=item isNavigable = C<1>

=item aggregation = C<composite>

=item visibility = C<private>

=item container_type = C<Set::Object>

=back


=head2 C<entry> : I<THIS> C<0..1> E<lt>---E<gt>  C<state_entry> : UMMF::UML_1_5::Behavioral_Elements::State_Machines::State C<0..1>



=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::AssociationEnd|UMMF::UML_1_5::Foundation::Core::AssociationEnd>

=item type = L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>

=item multiplicity = C<0..1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<>

=item isNavigable = C<1>

=item aggregation = C<composite>

=item visibility = C<private>

=item container_type = C<Set::Object>

=back


=head2 C<exit> : I<THIS> C<0..1> E<lt>---E<gt>  C<state_exit> : UMMF::UML_1_5::Behavioral_Elements::State_Machines::State C<0..1>



=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::AssociationEnd|UMMF::UML_1_5::Foundation::Core::AssociationEnd>

=item type = L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>

=item multiplicity = C<0..1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<>

=item isNavigable = C<1>

=item aggregation = C<composite>

=item visibility = C<private>

=item container_type = C<Set::Object>

=back


=head2 C<dispatchAction> : I<THIS> C<1> E<lt>---E<gt>  C<stimulus> : UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus C<0..*>



=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::AssociationEnd|UMMF::UML_1_5::Foundation::Core::AssociationEnd>

=item type = L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus>

=item multiplicity = C<0..*>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<>

=item isNavigable = C<1>

=item aggregation = C<none>

=item visibility = C<private>

=item container_type = C<Set::Object>

=back


=head2 C<effect> : I<THIS> C<0..1> E<lt>---E<gt>  C<transition> : UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition C<0..1>



=over 4

=item metatype = L<UMMF::UML_1_5::Foundation::Core::AssociationEnd|UMMF::UML_1_5::Foundation::Core::AssociationEnd>

=item type = L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition|UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition>

=item multiplicity = C<0..1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<>

=item isNavigable = C<1>

=item aggregation = C<composite>

=item visibility = C<private>

=item container_type = C<Set::Object>

=back



=head1 METHODS

=cut



#################################################################
# 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
#


=head2 C<__validate_type>

  UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure->__validate_type($value);

Returns true if C<$value> is a valid representation of L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure>.

=cut
sub __validate_type($$)
{
  my ($self, $x) = @_;

  no warnings;

  UNIVERSAL::isa($x, 'UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure')  ;
}


=head2 C<__typecheck>

  UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure->__typecheck($value, $msg);

Calls C<confess()> with C<$msg> if C<<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure->__validate_type($value)>> is false.

=cut
sub __typecheck
{
  my ($self, $x, $msg) = @_;

  confess("typecheck: $msg: type '" . 'UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure' . ": value '$x'")
    unless __validate_type($self, $x);
}


=head2 C<isaProcedure>


Returns true if receiver is a L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure>.
Other receivers will return false.

=cut
sub isaProcedure { 1 }


=head2 C<isaBehavioral_Elements__Common_Behavior__Procedure>


Returns true if receiver is a L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure>.
Other receivers will return false.
This is the fully qualified version of the C<isaProcedure> method.

=cut
sub isaBehavioral_Elements__Common_Behavior__Procedure { 1 }


#################################################################
# Introspection
#

=head2 C<__model_name> 

  my $name = $obj_or_package->__model_name;

Returns the UML Model name (C<'Behavioral_Elements::Common_Behavior::Procedure'>) for an object or package of
this Classifier.

=cut
sub __model_name { 'Behavioral_Elements::Common_Behavior::Procedure' }



=head2 C<__isAbstract>

  $package->__isAbstract;

Returns C<0>.

=cut
sub __isAbstract { 0; }


my $__tangram_schema;
=head2 C<__tangram_schema>

  my $tangram_schema $obj_or_package->__tangram_schema

Returns a HASH ref that describes this Classifier for Tangram.

See L<UMMF::Export::Perl::Tangram|UMMF::Export::Perl::Tangram>

=cut
sub __tangram_schema
{
  my ($self) = @_;

  $__tangram_schema ||=
  {
   'classes' =>
   [
     'UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure' =>
     {
       'table' => 'Behavioral_Elements__Common_Behavior__Procedure',
       'abstract' => 0,
       'slots' => 
       { 
	 # Attributes
	 	       'language'
       => {
	 'type_impl' => 'string',
                                             'col' => 'language', 

                                                                                                                   }
      ,
         	       'body'
       => {
	 'type_impl' => 'ref',
         'class' => 'UMMF::UML_1_5::Foundation::Data_Types::String',

                                             'col' => 'body', 

                                                                                                                   }
      ,
         	       'isList'
       => {
	 'type_impl' => 'string',
                                             'col' => 'isList', 

                                                                                                                   }
      ,
         
	 # Associations
	 	 	       'expression'
       => {
	 'type_impl' => 'iset',
         'class' => 'UMMF::UML_1_5::Foundation::Data_Types::Expression',

                           'table' => 'Behavioral_Elements__Common_Behavior__Procedure__expression', 

                                                               'coll' => 'procedure',

                                                                               }
      ,
                  	 	       'method'
       => {
	 'type_impl' => 'iset',
         'class' => 'UMMF::UML_1_5::Foundation::Core::Method',

                           'table' => 'Behavioral_Elements__Common_Behavior__Procedure__method', 

                                                               'coll' => 'procedure',

                                                                               }
      ,
                  	 	       'state_doActivity'
       => {
	 'type_impl' => 'ref',
         'class' => 'UMMF::UML_1_5::Behavioral_Elements::State_Machines::State',

                  'null' => '1', 

                                    'col' => 'state_doActivity', 

                                                                                                                   }
      ,
                  	 	       'state_entry'
       => {
	 'type_impl' => 'ref',
         'class' => 'UMMF::UML_1_5::Behavioral_Elements::State_Machines::State',

                  'null' => '1', 

                                    'col' => 'state_entry', 

                                                                                                                   }
      ,
                  	 	       'state_exit'
       => {
	 'type_impl' => 'ref',
         'class' => 'UMMF::UML_1_5::Behavioral_Elements::State_Machines::State',

                  'null' => '1', 

                                    'col' => 'state_exit', 

                                                                                                                   }
      ,
                  	 	       'stimulus'
       => {
	 'type_impl' => 'iset',
         'class' => 'UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus',

                           'table' => 'Behavioral_Elements__Common_Behavior__Procedure__stimulus', 

                                                               'coll' => 'dispatchAction',

                                                                               }
      ,
                  	 	       'transition'
       => {
	 'type_impl' => 'ref',
         'class' => 'UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition',

                  'null' => '1', 

                                    'col' => 'transition', 

                                                                                                                   }
      ,
                         },
       '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
#


=head2 C<___initialize>

Initialize all Attributes and AssociationEnds in a instance of this Classifier.
Does B<not> initalize slots in its Generalizations.

See also: C<__initialize>.

=cut
sub ___initialize
{
  my ($self) = @_;

  # Attributes

    # Attribute language
  if ( exists $self->{'language'} ) {
    my $x = $self->{'language'};
    $self->{'language'} = undef;
        $self->set_language($x);
      } else {
      }
  
    # Attribute body
  if ( exists $self->{'body'} ) {
    my $x = $self->{'body'};
    $self->{'body'} = undef;
        $self->set_body($x);
      } else {
      }
  
    # Attribute isList
  if ( exists $self->{'isList'} ) {
    my $x = $self->{'isList'};
    $self->{'isList'} = undef;
        $self->set_isList($x);
      } else {
      }
  


  # Associations

  # AssociationEnd 
  #  procedure 0..1
  #  <--> 
  #  expression 0..* UMMF::UML_1_5::Foundation::Data_Types::Expression.
    if ( defined $self->{'expression'} ) {
    my $x = $self->{'expression'};
        $self->{'expression'} = Set::Object->new();
        $self->set_expression(@$x);
  }
  
  # AssociationEnd 
  #  procedure 0..1
  #  <--> 
  #  method 0..* UMMF::UML_1_5::Foundation::Core::Method.
    if ( defined $self->{'method'} ) {
    my $x = $self->{'method'};
        $self->{'method'} = Set::Object->new();
        $self->set_method(@$x);
  }
  
  # AssociationEnd 
  #  doActivity 0..1
  #  <--> 
  #  state_doActivity 0..1 UMMF::UML_1_5::Behavioral_Elements::State_Machines::State.
    if ( defined $self->{'state_doActivity'} ) {
    my $x = $self->{'state_doActivity'};
    $self->{'state_doActivity'} = undef;
    $self->set_state_doActivity($x);
  }
  
  # AssociationEnd 
  #  entry 0..1
  #  <--> 
  #  state_entry 0..1 UMMF::UML_1_5::Behavioral_Elements::State_Machines::State.
    if ( defined $self->{'state_entry'} ) {
    my $x = $self->{'state_entry'};
    $self->{'state_entry'} = undef;
    $self->set_state_entry($x);
  }
  
  # AssociationEnd 
  #  exit 0..1
  #  <--> 
  #  state_exit 0..1 UMMF::UML_1_5::Behavioral_Elements::State_Machines::State.
    if ( defined $self->{'state_exit'} ) {
    my $x = $self->{'state_exit'};
    $self->{'state_exit'} = undef;
    $self->set_state_exit($x);
  }
  
  # AssociationEnd 
  #  dispatchAction 1
  #  <--> 
  #  stimulus 0..* UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus.
    if ( defined $self->{'stimulus'} ) {
    my $x = $self->{'stimulus'};
        $self->{'stimulus'} = Set::Object->new();
        $self->set_stimulus(@$x);
  }
  
  # AssociationEnd 
  #  effect 0..1
  #  <--> 
  #  transition 0..1 UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition.
    if ( defined $self->{'transition'} ) {
    my $x = $self->{'transition'};
    $self->{'transition'} = undef;
    $self->set_transition($x);
  }
  

  $self;
}


my $__initialize_use;

=head2 C<__initialize>

Initialize all slots in this Classifier and all its Generalizations.

See also: C<___initialize>.

=cut
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::Behavioral_Elements::Common_Behavior::Procedure::___initialize;
  $self->UMMF::UML_1_5::Foundation::Core::Element::___initialize;
  $self->UMMF::UML_1_5::Foundation::Core::ModelElement::___initialize;

  $self;
}
      

=head2 C<__create>

Calls all <<create>> Methods for this Classifier and all Generalizations.

See also: C<___create>.

=cut
sub __create
{
  my ($self, @args) = @_;

  # $DB::single = 1;
  $self->UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure::___create(@args);
  $self->UMMF::UML_1_5::Foundation::Core::Element::___create();
  $self->UMMF::UML_1_5::Foundation::Core::ModelElement::___create();

  $self;
}




#################################################################
# Attributes
#



=for html <hr/>

=cut

#################################################################
# Attribute language
# type = UMMF::UML_1_5::Foundation::Data_Types::Name
# multiplicity = 1
# ordering = unordered
# ownerScope = instance
# initialValue = 

=head2 C<language>

  my $val = $obj->language;

Returns the L<UMMF::UML_1_5::Foundation::Data_Types::Name|UMMF::UML_1_5::Foundation::Data_Types::Name> value of Attribute C<language>.

=cut
sub language ($)
{
  my ($self) = @_;

  ;

  my $val = $self->{'language'};

  ;

  $val;
}


=head2 C<set_language>

  $obj->set_language($val);

Sets the value of Attribute C<language>.
C<$val> must be of type L<UMMF::UML_1_5::Foundation::Data_Types::Name|UMMF::UML_1_5::Foundation::Data_Types::Name> or C<undef>.
Returns C<$obj>.

=cut
sub set_language ($$)
{
  my ($self, $val) = @_;

  ;

  if ( defined $val ) {
    ;
  }

    $self->{'language'} = $val
  ;

  ;

  $self;
}


=head2 C<count_language>

  $obj->count_language;

Returns the number of elements (0 or 1) in C<language>.

=cut
sub count_language ($)
{
  my ($self) = @_;

  ;

  my $val = $self->{'language'};

  ;

  defined $val ? 1 : 0;
}



=for html <hr/>

=cut

#################################################################
# Attribute body
# type = UMMF::UML_1_5::Foundation::Data_Types::String
# multiplicity = 1
# ordering = unordered
# ownerScope = instance
# initialValue = 

=head2 C<body>

  my $val = $obj->body;

Returns the L<UMMF::UML_1_5::Foundation::Data_Types::String|UMMF::UML_1_5::Foundation::Data_Types::String> value of Attribute C<body>.

=cut
sub body ($)
{
  my ($self) = @_;

  ;

  my $val = $self->{'body'};

  ;

  $val;
}


=head2 C<set_body>

  $obj->set_body($val);

Sets the value of Attribute C<body>.
C<$val> must be of type L<UMMF::UML_1_5::Foundation::Data_Types::String|UMMF::UML_1_5::Foundation::Data_Types::String> or C<undef>.
Returns C<$obj>.

=cut
sub set_body ($$)
{
  my ($self, $val) = @_;

  ;

  if ( defined $val ) {
    ;
  }

    $self->{'body'} = $val
  ;

  ;

  $self;
}


=head2 C<count_body>

  $obj->count_body;

Returns the number of elements (0 or 1) in C<body>.

=cut
sub count_body ($)
{
  my ($self) = @_;

  ;

  my $val = $self->{'body'};

  ;

  defined $val ? 1 : 0;
}



=for html <hr/>

=cut

#################################################################
# Attribute isList
# type = UMMF::UML_1_5::Foundation::Data_Types::Boolean
# multiplicity = 1
# ordering = unordered
# ownerScope = instance
# initialValue = 

=head2 C<isList>

  my $val = $obj->isList;

Returns the L<UMMF::UML_1_5::Foundation::Data_Types::Boolean|UMMF::UML_1_5::Foundation::Data_Types::Boolean> value of Attribute C<isList>.

=cut
sub isList ($)
{
  my ($self) = @_;

  ;

  my $val = $self->{'isList'};

  ;

  $val;
}


=head2 C<set_isList>

  $obj->set_isList($val);

Sets the value of Attribute C<isList>.
C<$val> must be of type L<UMMF::UML_1_5::Foundation::Data_Types::Boolean|UMMF::UML_1_5::Foundation::Data_Types::Boolean> or C<undef>.
Returns C<$obj>.

=cut
sub set_isList ($$)
{
  my ($self, $val) = @_;

  ;

  if ( defined $val ) {
    ;
  }

    $self->{'isList'} = $val
  ;

  ;

  $self;
}


=head2 C<count_isList>

  $obj->count_isList;

Returns the number of elements (0 or 1) in C<isList>.

=cut
sub count_isList ($)
{
  my ($self) = @_;

  ;

  my $val = $self->{'isList'};

  ;

  defined $val ? 1 : 0;
}




#################################################################
# Association
#


=for html <hr/>

=cut

#################################################################
# AssociationEnd procedure <---> expression
# type = UMMF::UML_1_5::Foundation::Data_Types::Expression
# multiplicity = 0..*
# ordering = 

=head2 C<expression>

  my @val = $obj->expression;
  my $ary_val = $obj->expression;

Returns the AssociationEnd C<expression> values of type L<UMMF::UML_1_5::Foundation::Data_Types::Expression|UMMF::UML_1_5::Foundation::Data_Types::Expression>.
In array context, returns all the objects in the Association.
In scalar context, returns an array ref of all the objects in the Association.

=cut
sub expression ($)
{
  my ($self) = @_;

    my $x = $self->{'expression'};

  # confess("Container for expression $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() : () ];
  
}


=head2 C<set_expression>

  $obj->set_expression(@val);

Sets the AssociationEnd C<expression> value.
Elements of C<@val> must of type L<UMMF::UML_1_5::Foundation::Data_Types::Expression|UMMF::UML_1_5::Foundation::Data_Types::Expression>.
Returns C<$obj>.

=cut
sub set_expression ($@)
{
  my ($self, @val) = @_;
  
  $self->clear_expression;
  $self->add_expression(@val);
}


=head2 C<add_expression>

  $obj->add_expression(@val);

Adds AssociationEnd C<expression> values.
Elements of C<@val> must of type L<UMMF::UML_1_5::Foundation::Data_Types::Expression|UMMF::UML_1_5::Foundation::Data_Types::Expression>.
Returns C<$obj>.

=cut
sub add_expression ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'expression'} ||= 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::Data_Types::Expression')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.expression");

    # Recursion lock
        $x->insert($val);
    # weaken?
    
    # Remove and add associations with other ends.
        
    $old->remove_procedure($self) if $old;
    $val->add_procedure($self)    if $val;

    }
  
  $self;
}


=head2 C<remove_expression>

  $obj->remove_expression(@val);

Removes the AssociationEnd C<expression> values C<@val>.
Elements of C<@val> must of type L<UMMF::UML_1_5::Foundation::Data_Types::Expression|UMMF::UML_1_5::Foundation::Data_Types::Expression>.
Returns C<$obj>.

=cut
sub remove_expression ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'expression'} ||= Set::Object->new();
  
  for my $old ( @val ) {
    # Recursion lock
        next unless $x->includes($old);
    
    my $val = $old;
      
    $self->__use('UMMF::UML_1_5::Foundation::Data_Types::Expression')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.expression");

    # Recursion lock
        $x->remove($old);
    
    $val = undef;

    # Remove associations with other ends.

        
    $old->remove_procedure($self) if $old;
    $val->add_procedure($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<clear_expression>

  $obj->clear_expression;

Clears the AssociationEnd C<expression> links to L<UMMF::UML_1_5::Foundation::Data_Types::Expression|UMMF::UML_1_5::Foundation::Data_Types::Expression>.
Returns C<$obj>.

=cut
sub clear_expression ($) 
{
  my ($self) = @_;
  
    my $x = $self->{'expression'} ||= Set::Object->new();
  
  my $val; # Place holder for other MACRO.
  
    $self->{'expression'} = Set::Object->new(); # Recursion lock
  for my $old ( $x->members() ) {     # Recursion lock
  
    # Remove associations with other ends.

        
    $old->remove_procedure($self) if $old;
    $val->add_procedure($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<count_expression>

  $obj->count_expression;

Returns the number of elements associated with C<expression>.

=cut
sub count_expression ($)
{
  my ($self) = @_;

  my $x = $self->{'expression'};

    defined $x ? $x->size : 0;
  }




=for html <hr/>

=cut

#################################################################
# AssociationEnd procedure <---> method
# type = UMMF::UML_1_5::Foundation::Core::Method
# multiplicity = 0..*
# ordering = 

=head2 C<method>

  my @val = $obj->method;
  my $ary_val = $obj->method;

Returns the AssociationEnd C<method> values of type L<UMMF::UML_1_5::Foundation::Core::Method|UMMF::UML_1_5::Foundation::Core::Method>.
In array context, returns all the objects in the Association.
In scalar context, returns an array ref of all the objects in the Association.

=cut
sub method ($)
{
  my ($self) = @_;

    my $x = $self->{'method'};

  # confess("Container for method $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() : () ];
  
}


=head2 C<set_method>

  $obj->set_method(@val);

Sets the AssociationEnd C<method> value.
Elements of C<@val> must of type L<UMMF::UML_1_5::Foundation::Core::Method|UMMF::UML_1_5::Foundation::Core::Method>.
Returns C<$obj>.

=cut
sub set_method ($@)
{
  my ($self, @val) = @_;
  
  $self->clear_method;
  $self->add_method(@val);
}


=head2 C<add_method>

  $obj->add_method(@val);

Adds AssociationEnd C<method> values.
Elements of C<@val> must of type L<UMMF::UML_1_5::Foundation::Core::Method|UMMF::UML_1_5::Foundation::Core::Method>.
Returns C<$obj>.

=cut
sub add_method ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'method'} ||= 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::Core::Method')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.method");

    # Recursion lock
        $x->insert($val);
    # weaken?
    
    # Remove and add associations with other ends.
        
    $old->remove_procedure($self) if $old;
    $val->add_procedure($self)    if $val;

    }
  
  $self;
}


=head2 C<remove_method>

  $obj->remove_method(@val);

Removes the AssociationEnd C<method> values C<@val>.
Elements of C<@val> must of type L<UMMF::UML_1_5::Foundation::Core::Method|UMMF::UML_1_5::Foundation::Core::Method>.
Returns C<$obj>.

=cut
sub remove_method ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'method'} ||= Set::Object->new();
  
  for my $old ( @val ) {
    # Recursion lock
        next unless $x->includes($old);
    
    my $val = $old;
      
    $self->__use('UMMF::UML_1_5::Foundation::Core::Method')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.method");

    # Recursion lock
        $x->remove($old);
    
    $val = undef;

    # Remove associations with other ends.

        
    $old->remove_procedure($self) if $old;
    $val->add_procedure($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<clear_method>

  $obj->clear_method;

Clears the AssociationEnd C<method> links to L<UMMF::UML_1_5::Foundation::Core::Method|UMMF::UML_1_5::Foundation::Core::Method>.
Returns C<$obj>.

=cut
sub clear_method ($) 
{
  my ($self) = @_;
  
    my $x = $self->{'method'} ||= Set::Object->new();
  
  my $val; # Place holder for other MACRO.
  
    $self->{'method'} = Set::Object->new(); # Recursion lock
  for my $old ( $x->members() ) {     # Recursion lock
  
    # Remove associations with other ends.

        
    $old->remove_procedure($self) if $old;
    $val->add_procedure($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<count_method>

  $obj->count_method;

Returns the number of elements associated with C<method>.

=cut
sub count_method ($)
{
  my ($self) = @_;

  my $x = $self->{'method'};

    defined $x ? $x->size : 0;
  }




=for html <hr/>

=cut

#################################################################
# AssociationEnd doActivity <---> state_doActivity
# type = UMMF::UML_1_5::Behavioral_Elements::State_Machines::State
# multiplicity = 0..1
# ordering = 

=head2 C<state_doActivity>

  my $val = $obj->state_doActivity;

Returns the AssociationEnd C<state_doActivity> value of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.

=cut
sub state_doActivity ($)
{
  my ($self) = @_;
		  
  $self->{'state_doActivity'};
}


=head2 C<set_state_doActivity>

  $obj->set_state_doActivity($val);

Sets the AssociationEnd C<state_doActivity> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Returns C<$obj>.

=cut
sub set_state_doActivity ($$)
{
  my ($self, $val) = @_;
		  
  no warnings; # Use of uninitialized value in string ne at ...
		  
  my $old;
  if ( ($old = $self->{'state_doActivity'}) ne $val ) { # Recursion lock

    if ( defined $val ) { $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::State')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.state_doActivity") }

    # Recursion lock
        $self->{'state_doActivity'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_doActivity($self) if $old;
    $val->add_doActivity($self)    if $val;

    }
		  
  $self;
}


=head2 C<add_state_doActivity>

  $obj->add_state_doActivity($val);

Adds the AssociationEnd C<state_doActivity> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Throws exception if a value already exists.
Returns C<$obj>.

=cut
sub add_state_doActivity ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'state_doActivity'}) ne $val ) { # Recursion lock
    $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::State')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.state_doActivity");
      
    # confess("UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure::state_doActivity: too many")
    # if defined $self->{'state_doActivity'};

    # Recursion lock
        $self->{'state_doActivity'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_doActivity($self) if $old;
    $val->add_doActivity($self)    if $val;

  
  }

  $self;
}


=head2 C<remove_state_doActivity>

  $obj->remove_state_doActivity($val);

Removes the AssociationEnd C<state_doActivity> value C<$val>.
Returns C<$obj>.

=cut
sub remove_state_doActivity ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'state_doActivity'}) eq $val ) { # Recursion lock
    $val = $self->{'state_doActivity'} = undef;         # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_doActivity($self) if $old;
    $val->add_doActivity($self)    if $val;

  
  }
}


=head2 C<clear_state_doActivity>

  $obj->clear_state_doActivity;

Clears the AssociationEnd C<state_doActivity> links to L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Returns C<$obj>.

=cut
sub clear_state_doActivity ($@)
{
  my ($self) = @_;

  my $old;
  if ( defined ($old = $self->{'state_doActivity'}) ) { # Recursion lock
    my $val = $self->{'state_doActivity'} = undef;      # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_doActivity($self) if $old;
    $val->add_doActivity($self)    if $val;

    }

  $self;
}


=head2 C<count_state_doActivity>

  $obj->count_state_doActivity;

Returns the number of elements of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State> associated with C<state_doActivity>.

=cut
sub count_state_doActivity ($)
{
  my ($self) = @_;

  my $x = $self->{'state_doActivity'};

  defined $x ? 1 : 0;
}




=for html <hr/>

=cut

#################################################################
# AssociationEnd entry <---> state_entry
# type = UMMF::UML_1_5::Behavioral_Elements::State_Machines::State
# multiplicity = 0..1
# ordering = 

=head2 C<state_entry>

  my $val = $obj->state_entry;

Returns the AssociationEnd C<state_entry> value of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.

=cut
sub state_entry ($)
{
  my ($self) = @_;
		  
  $self->{'state_entry'};
}


=head2 C<set_state_entry>

  $obj->set_state_entry($val);

Sets the AssociationEnd C<state_entry> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Returns C<$obj>.

=cut
sub set_state_entry ($$)
{
  my ($self, $val) = @_;
		  
  no warnings; # Use of uninitialized value in string ne at ...
		  
  my $old;
  if ( ($old = $self->{'state_entry'}) ne $val ) { # Recursion lock

    if ( defined $val ) { $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::State')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.state_entry") }

    # Recursion lock
        $self->{'state_entry'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_entry($self) if $old;
    $val->add_entry($self)    if $val;

    }
		  
  $self;
}


=head2 C<add_state_entry>

  $obj->add_state_entry($val);

Adds the AssociationEnd C<state_entry> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Throws exception if a value already exists.
Returns C<$obj>.

=cut
sub add_state_entry ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'state_entry'}) ne $val ) { # Recursion lock
    $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::State')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.state_entry");
      
    # confess("UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure::state_entry: too many")
    # if defined $self->{'state_entry'};

    # Recursion lock
        $self->{'state_entry'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_entry($self) if $old;
    $val->add_entry($self)    if $val;

  
  }

  $self;
}


=head2 C<remove_state_entry>

  $obj->remove_state_entry($val);

Removes the AssociationEnd C<state_entry> value C<$val>.
Returns C<$obj>.

=cut
sub remove_state_entry ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'state_entry'}) eq $val ) { # Recursion lock
    $val = $self->{'state_entry'} = undef;         # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_entry($self) if $old;
    $val->add_entry($self)    if $val;

  
  }
}


=head2 C<clear_state_entry>

  $obj->clear_state_entry;

Clears the AssociationEnd C<state_entry> links to L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Returns C<$obj>.

=cut
sub clear_state_entry ($@)
{
  my ($self) = @_;

  my $old;
  if ( defined ($old = $self->{'state_entry'}) ) { # Recursion lock
    my $val = $self->{'state_entry'} = undef;      # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_entry($self) if $old;
    $val->add_entry($self)    if $val;

    }

  $self;
}


=head2 C<count_state_entry>

  $obj->count_state_entry;

Returns the number of elements of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State> associated with C<state_entry>.

=cut
sub count_state_entry ($)
{
  my ($self) = @_;

  my $x = $self->{'state_entry'};

  defined $x ? 1 : 0;
}




=for html <hr/>

=cut

#################################################################
# AssociationEnd exit <---> state_exit
# type = UMMF::UML_1_5::Behavioral_Elements::State_Machines::State
# multiplicity = 0..1
# ordering = 

=head2 C<state_exit>

  my $val = $obj->state_exit;

Returns the AssociationEnd C<state_exit> value of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.

=cut
sub state_exit ($)
{
  my ($self) = @_;
		  
  $self->{'state_exit'};
}


=head2 C<set_state_exit>

  $obj->set_state_exit($val);

Sets the AssociationEnd C<state_exit> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Returns C<$obj>.

=cut
sub set_state_exit ($$)
{
  my ($self, $val) = @_;
		  
  no warnings; # Use of uninitialized value in string ne at ...
		  
  my $old;
  if ( ($old = $self->{'state_exit'}) ne $val ) { # Recursion lock

    if ( defined $val ) { $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::State')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.state_exit") }

    # Recursion lock
        $self->{'state_exit'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_exit($self) if $old;
    $val->add_exit($self)    if $val;

    }
		  
  $self;
}


=head2 C<add_state_exit>

  $obj->add_state_exit($val);

Adds the AssociationEnd C<state_exit> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Throws exception if a value already exists.
Returns C<$obj>.

=cut
sub add_state_exit ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'state_exit'}) ne $val ) { # Recursion lock
    $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::State')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.state_exit");
      
    # confess("UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure::state_exit: too many")
    # if defined $self->{'state_exit'};

    # Recursion lock
        $self->{'state_exit'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_exit($self) if $old;
    $val->add_exit($self)    if $val;

  
  }

  $self;
}


=head2 C<remove_state_exit>

  $obj->remove_state_exit($val);

Removes the AssociationEnd C<state_exit> value C<$val>.
Returns C<$obj>.

=cut
sub remove_state_exit ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'state_exit'}) eq $val ) { # Recursion lock
    $val = $self->{'state_exit'} = undef;         # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_exit($self) if $old;
    $val->add_exit($self)    if $val;

  
  }
}


=head2 C<clear_state_exit>

  $obj->clear_state_exit;

Clears the AssociationEnd C<state_exit> links to L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State>.
Returns C<$obj>.

=cut
sub clear_state_exit ($@)
{
  my ($self) = @_;

  my $old;
  if ( defined ($old = $self->{'state_exit'}) ) { # Recursion lock
    my $val = $self->{'state_exit'} = undef;      # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_exit($self) if $old;
    $val->add_exit($self)    if $val;

    }

  $self;
}


=head2 C<count_state_exit>

  $obj->count_state_exit;

Returns the number of elements of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::State|UMMF::UML_1_5::Behavioral_Elements::State_Machines::State> associated with C<state_exit>.

=cut
sub count_state_exit ($)
{
  my ($self) = @_;

  my $x = $self->{'state_exit'};

  defined $x ? 1 : 0;
}




=for html <hr/>

=cut

#################################################################
# AssociationEnd dispatchAction <---> stimulus
# type = UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus
# multiplicity = 0..*
# ordering = 

=head2 C<stimulus>

  my @val = $obj->stimulus;
  my $ary_val = $obj->stimulus;

Returns the AssociationEnd C<stimulus> values of type L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus>.
In array context, returns all the objects in the Association.
In scalar context, returns an array ref of all the objects in the Association.

=cut
sub stimulus ($)
{
  my ($self) = @_;

    my $x = $self->{'stimulus'};

  # confess("Container for stimulus $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() : () ];
  
}


=head2 C<set_stimulus>

  $obj->set_stimulus(@val);

Sets the AssociationEnd C<stimulus> value.
Elements of C<@val> must of type L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus>.
Returns C<$obj>.

=cut
sub set_stimulus ($@)
{
  my ($self, @val) = @_;
  
  $self->clear_stimulus;
  $self->add_stimulus(@val);
}


=head2 C<add_stimulus>

  $obj->add_stimulus(@val);

Adds AssociationEnd C<stimulus> values.
Elements of C<@val> must of type L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus>.
Returns C<$obj>.

=cut
sub add_stimulus ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'stimulus'} ||= 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::Behavioral_Elements::Common_Behavior::Stimulus')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.stimulus");

    # Recursion lock
        $x->insert($val);
    # weaken?
    
    # Remove and add associations with other ends.
        
    $old->remove_dispatchAction($self) if $old;
    $val->add_dispatchAction($self)    if $val;

    }
  
  $self;
}


=head2 C<remove_stimulus>

  $obj->remove_stimulus(@val);

Removes the AssociationEnd C<stimulus> values C<@val>.
Elements of C<@val> must of type L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus>.
Returns C<$obj>.

=cut
sub remove_stimulus ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'stimulus'} ||= Set::Object->new();
  
  for my $old ( @val ) {
    # Recursion lock
        next unless $x->includes($old);
    
    my $val = $old;
      
    $self->__use('UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.stimulus");

    # Recursion lock
        $x->remove($old);
    
    $val = undef;

    # Remove associations with other ends.

        
    $old->remove_dispatchAction($self) if $old;
    $val->add_dispatchAction($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<clear_stimulus>

  $obj->clear_stimulus;

Clears the AssociationEnd C<stimulus> links to L<UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus|UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Stimulus>.
Returns C<$obj>.

=cut
sub clear_stimulus ($) 
{
  my ($self) = @_;
  
    my $x = $self->{'stimulus'} ||= Set::Object->new();
  
  my $val; # Place holder for other MACRO.
  
    $self->{'stimulus'} = Set::Object->new(); # Recursion lock
  for my $old ( $x->members() ) {     # Recursion lock
  
    # Remove associations with other ends.

        
    $old->remove_dispatchAction($self) if $old;
    $val->add_dispatchAction($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<count_stimulus>

  $obj->count_stimulus;

Returns the number of elements associated with C<stimulus>.

=cut
sub count_stimulus ($)
{
  my ($self) = @_;

  my $x = $self->{'stimulus'};

    defined $x ? $x->size : 0;
  }




=for html <hr/>

=cut

#################################################################
# AssociationEnd effect <---> transition
# type = UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition
# multiplicity = 0..1
# ordering = 

=head2 C<transition>

  my $val = $obj->transition;

Returns the AssociationEnd C<transition> value of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition|UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition>.

=cut
sub transition ($)
{
  my ($self) = @_;
		  
  $self->{'transition'};
}


=head2 C<set_transition>

  $obj->set_transition($val);

Sets the AssociationEnd C<transition> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition|UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition>.
Returns C<$obj>.

=cut
sub set_transition ($$)
{
  my ($self, $val) = @_;
		  
  no warnings; # Use of uninitialized value in string ne at ...
		  
  my $old;
  if ( ($old = $self->{'transition'}) ne $val ) { # Recursion lock

    if ( defined $val ) { $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.transition") }

    # Recursion lock
        $self->{'transition'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_effect($self) if $old;
    $val->add_effect($self)    if $val;

    }
		  
  $self;
}


=head2 C<add_transition>

  $obj->add_transition($val);

Adds the AssociationEnd C<transition> value.
C<$val> must of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition|UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition>.
Throws exception if a value already exists.
Returns C<$obj>.

=cut
sub add_transition ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'transition'}) ne $val ) { # Recursion lock
    $self->__use('UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition')->__typecheck($val, "UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure.transition");
      
    # confess("UMMF::UML_1_5::Behavioral_Elements::Common_Behavior::Procedure::transition: too many")
    # if defined $self->{'transition'};

    # Recursion lock
        $self->{'transition'} = $val
    ;

    # Remove and add associations with other ends.
        
    $old->remove_effect($self) if $old;
    $val->add_effect($self)    if $val;

  
  }

  $self;
}


=head2 C<remove_transition>

  $obj->remove_transition($val);

Removes the AssociationEnd C<transition> value C<$val>.
Returns C<$obj>.

=cut
sub remove_transition ($$)
{
  my ($self, $val) = @_;

  no warnings; # Use of uninitialized value in string ne at ...

  my $old;
  if ( ($old = $self->{'transition'}) eq $val ) { # Recursion lock
    $val = $self->{'transition'} = undef;         # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_effect($self) if $old;
    $val->add_effect($self)    if $val;

  
  }
}


=head2 C<clear_transition>

  $obj->clear_transition;

Clears the AssociationEnd C<transition> links to L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition|UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition>.
Returns C<$obj>.

=cut
sub clear_transition ($@)
{
  my ($self) = @_;

  my $old;
  if ( defined ($old = $self->{'transition'}) ) { # Recursion lock
    my $val = $self->{'transition'} = undef;      # Recursion lock

    # Remove and add associations with other ends.
        
    $old->remove_effect($self) if $old;
    $val->add_effect($self)    if $val;

    }

  $self;
}


=head2 C<count_transition>

  $obj->count_transition;

Returns the number of elements of type L<UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition|UMMF::UML_1_5::Behavioral_Elements::State_Machines::Transition> associated with C<transition>.

=cut
sub count_transition ($)
{
  my ($self) = @_;

  my $x = $self->{'transition'};

  defined $x ? 1 : 0;
}







# End of Class Procedure


=pod

=for html <hr/>

I<END OF DOCUMENT>

=cut

############################################################################

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: ###

