# -*- perl -*-
# DO NOT EDIT - This file is generated by UMMF; http://ummf.sourceforge.net 
# From template: $Id: PerlTemplate.txt,v 1.74 2004/08/01 03:50:07 kstephens Exp $

package UMMF::UML::MetaModel::Model_Management::ElementImport;

#use 5.6.1;
use strict;
use warnings;

#################################################################
# Version
#

our $VERSION = do { my @r = (q{1.0} =~ /\d+/g); sprintf "%d." . "%03d" x $#r, @r };


#################################################################
# Documentation
#

=head1 NAME

UMMF::UML::MetaModel::Model_Management::ElementImport -- 

=head1 VERSION

1.0

=head1 SYNOPSIS

=head1 DESCRIPTION 

=head1 USAGE

=head1 EXPORT

=head1 METATYPE

L<UMMF::UML::MetaModel::Foundation::Core::AssociationClass|UMMF::UML::MetaModel::Foundation::Core::AssociationClass>

=head1 SUPERCLASSES

L<UMMF::UML::MetaModel::__ObjectBase|UMMF::UML::MetaModel::__ObjectBase>




=head1 ATTRIBUTES


=head2 C<visibility> : UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind 


=over 4

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

=item type = L<UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind|UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind>

=item visibility = C<private>

=item multiplicity = C<1>

=item changeability = C<changeable>

=item targetScope = C<instance>

=item ordering = C<unordered>

=item initialValue = C<<"public">>

=item container_type = C<Set::Object>

=back


=head2 C<alias> : UMMF::UML::MetaModel::Foundation::Data_Types::Name 


=over 4

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

=item type = L<UMMF::UML::MetaModel::Foundation::Data_Types::Name|UMMF::UML::MetaModel::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<isSpecification> : UMMF::UML::MetaModel::Foundation::Data_Types::Boolean 


=over 4

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

=item type = L<UMMF::UML::MetaModel::Foundation::Data_Types::Boolean|UMMF::UML::MetaModel::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 = C<<"false">>

=item container_type = C<Set::Object>

=back



=head1 ASSOCIATIONS


=head2 C<0..*> : C<package_AC> E<lt>---E<gt>  C<importedElement> : UMMF::UML::MetaModel::Foundation::Core::ModelElement C<0..*>



=over 4

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

=item type = L<UMMF::UML::MetaModel::Foundation::Core::ModelElement|UMMF::UML::MetaModel::Foundation::Core::ModelElement>

=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<0..*> : C<importedElement_AC> E<lt>---E<gt>  C<package> : UMMF::UML::MetaModel::Model_Management::Package C<0..*>



=over 4

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

=item type = L<UMMF::UML::MetaModel::Model_Management::Package|UMMF::UML::MetaModel::Model_Management::Package>

=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



=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::MetaModel::__ObjectBase qw(:__ummf_array);


#################################################################
# Generalizations
#

use base qw(


  UMMF::UML::MetaModel::__ObjectBase

);


#################################################################
# Exports
#

our @EXPORT_OK = qw(
);
our %EXPORT_TAGS = ( 'all' => \@EXPORT_OK );





#################################################################
# Validation
#


=head2 C<__validate_type>

  UMMF::UML::MetaModel::Model_Management::ElementImport->__validate_type($value);

Returns true if C<$value> is a valid representation of L<UMMF::UML::MetaModel::Model_Management::ElementImport|UMMF::UML::MetaModel::Model_Management::ElementImport>.

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

  no warnings;

  UNIVERSAL::isa($x, 'UMMF::UML::MetaModel::Model_Management::ElementImport')  ;
}


=head2 C<__typecheck>

  UMMF::UML::MetaModel::Model_Management::ElementImport->__typecheck($value, $msg);

Calls C<confess()> with C<$msg> if C<<UMMF::UML::MetaModel::Model_Management::ElementImport->__validate_type($value)>> is false.

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

  confess("typecheck: $msg: type '" . 'UMMF::UML::MetaModel::Model_Management::ElementImport' . ": value '$x'")
    unless __validate_type($self, $x);
}


=head2 C<isaElementImport>


Returns true if receiver is a L<UMMF::UML::MetaModel::Model_Management::ElementImport|UMMF::UML::MetaModel::Model_Management::ElementImport>.
Other receivers will return false.

=cut
sub isaElementImport { 1 }


=head2 C<isaModel_Management__ElementImport>


Returns true if receiver is a L<UMMF::UML::MetaModel::Model_Management::ElementImport|UMMF::UML::MetaModel::Model_Management::ElementImport>.
Other receivers will return false.
This is the fully qualified version of the C<isaElementImport> method.

=cut
sub isaModel_Management__ElementImport { 1 }


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

=head2 C<__model_name> 

  my $name = $obj_or_package->__model_name;

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

=cut
sub __model_name { 'Model_Management::ElementImport' }



=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::UML::Export::Perl::Tangram|UMMF::UML::Export::Perl::Tangram>

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

  $__tangram_schema ||=
  {
   'classes' =>
   [
     'UMMF::UML::MetaModel::Model_Management::ElementImport' =>
     {
       'table' => 'Model_Management__ElementImport',
       'abstract' => 0,
       'slots' => 
       { 
	 # Attributes
	 	       'visibility'
       => {
	 'type_impl' => 'string',
                                             'col' => 'visibility', 

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

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

                                                                                                                   }
      ,
         
	 # Associations
	 	 	       'importedElement'
       => {
	 'type_impl' => 'set',
         'class' => 'UMMF::UML::MetaModel::Foundation::Core::ModelElement',

                           'table' => 'Model_Management__ElementImport_importedElement_ElementImport_AC', 

                                                      'item' => 'importedElement', 

                  'coll' => 'package_AC',

                                                                               }
      ,
                  	 	       'package'
       => {
	 'type_impl' => 'set',
         'class' => 'UMMF::UML::MetaModel::Model_Management::Package',

                           'table' => 'Model_Management__ElementImport_package_ElementImport_AC', 

                                                      'item' => 'package', 

                  'coll' => 'importedElement_AC',

                                                                               }
      ,
                         },
       'bases' => [  ],
       '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 visibility
  if ( exists $self->{'visibility'} ) {
    my $x = $self->{'visibility'};
    $self->{'visibility'} = undef;
    $self->set_visibility($x);
  } else {
        $self->{'visibility'} = "public";
      }
  
    # Attribute alias
  if ( exists $self->{'alias'} ) {
    my $x = $self->{'alias'};
    $self->{'alias'} = undef;
    $self->set_alias($x);
  } else {
      }
  
    # Attribute isSpecification
  if ( exists $self->{'isSpecification'} ) {
    my $x = $self->{'isSpecification'};
    $self->{'isSpecification'} = undef;
    $self->set_isSpecification($x);
  } else {
        $self->{'isSpecification'} = "false";
      }
  


  # Associations

  # AssociationEnd 
  #  package_AC 0..*
  #  <--> 
  #  importedElement 0..* UMMF::UML::MetaModel::Foundation::Core::ModelElement.
    if ( defined $self->{'importedElement'} ) {
    my $x = $self->{'importedElement'};
        $self->{'importedElement'} = Set::Object->new();
        $self->set_importedElement(@$x);
  }
  
  # AssociationEnd 
  #  importedElement_AC 0..*
  #  <--> 
  #  package 0..* UMMF::UML::MetaModel::Model_Management::Package.
    if ( defined $self->{'package'} ) {
    my $x = $self->{'package'};
        $self->{'package'} = Set::Object->new();
        $self->set_package(@$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->UMMF::UML::MetaModel::Model_Management::ElementImport::___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::MetaModel::Model_Management::ElementImport::___create(@args);

  $self;
}




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



=for html <hr/>

=cut

#################################################################
# Attribute visibility
# type = UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind
# multiplicity = 1
# ordering = unordered
# ownerScope = instance
# initialValue = "public"

=head2 C<visibility>

  my $val = $obj->visibility;

Returns the L<UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind|UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind> value of Attribute C<visibility>.

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

  ;

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

  ;

  $val;
}


=head2 C<set_visibility>

  $obj->set_visibility($val);

Sets the value of Attribute C<visibility>.
C<$val> must be of type L<UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind|UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind> or C<undef>.
Returns C<$obj>.

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

  ;

  if ( defined $val ) {
    $self->__use('UMMF::UML::MetaModel::Foundation::Data_Types::VisibilityKind')->__typecheck($val, "UMMF::UML::MetaModel::Model_Management::ElementImport.visibility");
  }

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

  ;

  $self;
}


=head2 C<count_visibility>

  $obj->count_visibility;

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

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

  ;

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

  ;

  defined $val ? 1 : 0;
}



=for html <hr/>

=cut

#################################################################
# Attribute alias
# type = UMMF::UML::MetaModel::Foundation::Data_Types::Name
# multiplicity = 1
# ordering = unordered
# ownerScope = instance
# initialValue = 

=head2 C<alias>

  my $val = $obj->alias;

Returns the L<UMMF::UML::MetaModel::Foundation::Data_Types::Name|UMMF::UML::MetaModel::Foundation::Data_Types::Name> value of Attribute C<alias>.

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

  ;

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

  ;

  $val;
}


=head2 C<set_alias>

  $obj->set_alias($val);

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

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

  ;

  if ( defined $val ) {
    ;
  }

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

  ;

  $self;
}


=head2 C<count_alias>

  $obj->count_alias;

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

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

  ;

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

  ;

  defined $val ? 1 : 0;
}



=for html <hr/>

=cut

#################################################################
# Attribute isSpecification
# type = UMMF::UML::MetaModel::Foundation::Data_Types::Boolean
# multiplicity = 1
# ordering = unordered
# ownerScope = instance
# initialValue = "false"

=head2 C<isSpecification>

  my $val = $obj->isSpecification;

Returns the L<UMMF::UML::MetaModel::Foundation::Data_Types::Boolean|UMMF::UML::MetaModel::Foundation::Data_Types::Boolean> value of Attribute C<isSpecification>.

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

  ;

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

  ;

  $val;
}


=head2 C<set_isSpecification>

  $obj->set_isSpecification($val);

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

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

  ;

  if ( defined $val ) {
    ;
  }

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

  ;

  $self;
}


=head2 C<count_isSpecification>

  $obj->count_isSpecification;

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

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

  ;

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

  ;

  defined $val ? 1 : 0;
}




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


=for html <hr/>

=cut

#################################################################
# AssociationEnd package_AC <---> importedElement
# type = UMMF::UML::MetaModel::Foundation::Core::ModelElement
# multiplicity = 0..*
# ordering = 

=head2 C<importedElement>

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

Returns the AssociationEnd C<importedElement> values of type L<UMMF::UML::MetaModel::Foundation::Core::ModelElement|UMMF::UML::MetaModel::Foundation::Core::ModelElement>.
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 importedElement ($)
{
  my ($self) = @_;

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

  # confess("Container for importedElement $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_importedElement>

  $obj->set_importedElement(@val);

Sets the AssociationEnd C<importedElement> value.
Elements of C<@val> must of type L<UMMF::UML::MetaModel::Foundation::Core::ModelElement|UMMF::UML::MetaModel::Foundation::Core::ModelElement>.
Returns C<$obj>.

=cut
sub set_importedElement ($@)
{
  my ($self, @val) = @_;
  
  $self->clear_importedElement;
  $self->add_importedElement(@val);
}


=head2 C<add_importedElement>

  $obj->add_importedElement(@val);

Adds AssociationEnd C<importedElement> values.
Elements of C<@val> must of type L<UMMF::UML::MetaModel::Foundation::Core::ModelElement|UMMF::UML::MetaModel::Foundation::Core::ModelElement>.
Returns C<$obj>.

=cut
sub add_importedElement ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'importedElement'} ||= 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::MetaModel::Foundation::Core::ModelElement')->__typecheck($val, "UMMF::UML::MetaModel::Model_Management::ElementImport.importedElement");

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

    }
  
  $self;
}


=head2 C<remove_importedElement>

  $obj->remove_importedElement(@val);

Removes the AssociationEnd C<importedElement> values C<@val>.
Elements of C<@val> must of type L<UMMF::UML::MetaModel::Foundation::Core::ModelElement|UMMF::UML::MetaModel::Foundation::Core::ModelElement>.
Returns C<$obj>.

=cut
sub remove_importedElement ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'importedElement'} ||= Set::Object->new();
  
  for my $old ( @val ) {
    # Recursion lock
        next unless $x->includes($old);
    
    my $val = $old;
      
    $self->__use('UMMF::UML::MetaModel::Foundation::Core::ModelElement')->__typecheck($val, "UMMF::UML::MetaModel::Model_Management::ElementImport.importedElement");

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

    # Remove associations with other ends.

        
    $old->remove_package_AC($self) if $old;
    $val->add_package_AC($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<clear_importedElement>

  $obj->clear_importedElement;

Clears the AssociationEnd C<importedElement> links to L<UMMF::UML::MetaModel::Foundation::Core::ModelElement|UMMF::UML::MetaModel::Foundation::Core::ModelElement>.
Returns C<$obj>.

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

        
    $old->remove_package_AC($self) if $old;
    $val->add_package_AC($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<count_importedElement>

  $obj->count_importedElement;

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

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

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

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




=for html <hr/>

=cut

#################################################################
# AssociationEnd importedElement_AC <---> package
# type = UMMF::UML::MetaModel::Model_Management::Package
# multiplicity = 0..*
# ordering = 

=head2 C<package>

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

Returns the AssociationEnd C<package> values of type L<UMMF::UML::MetaModel::Model_Management::Package|UMMF::UML::MetaModel::Model_Management::Package>.
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 package ($)
{
  my ($self) = @_;

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

  # confess("Container for package $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_package>

  $obj->set_package(@val);

Sets the AssociationEnd C<package> value.
Elements of C<@val> must of type L<UMMF::UML::MetaModel::Model_Management::Package|UMMF::UML::MetaModel::Model_Management::Package>.
Returns C<$obj>.

=cut
sub set_package ($@)
{
  my ($self, @val) = @_;
  
  $self->clear_package;
  $self->add_package(@val);
}


=head2 C<add_package>

  $obj->add_package(@val);

Adds AssociationEnd C<package> values.
Elements of C<@val> must of type L<UMMF::UML::MetaModel::Model_Management::Package|UMMF::UML::MetaModel::Model_Management::Package>.
Returns C<$obj>.

=cut
sub add_package ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'package'} ||= 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::MetaModel::Model_Management::Package')->__typecheck($val, "UMMF::UML::MetaModel::Model_Management::ElementImport.package");

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

    }
  
  $self;
}


=head2 C<remove_package>

  $obj->remove_package(@val);

Removes the AssociationEnd C<package> values C<@val>.
Elements of C<@val> must of type L<UMMF::UML::MetaModel::Model_Management::Package|UMMF::UML::MetaModel::Model_Management::Package>.
Returns C<$obj>.

=cut
sub remove_package ($@)
{
  my ($self, @val) = @_;
  
    my $x = $self->{'package'} ||= Set::Object->new();
  
  for my $old ( @val ) {
    # Recursion lock
        next unless $x->includes($old);
    
    my $val = $old;
      
    $self->__use('UMMF::UML::MetaModel::Model_Management::Package')->__typecheck($val, "UMMF::UML::MetaModel::Model_Management::ElementImport.package");

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

    # Remove associations with other ends.

        
    $old->remove_importedElement_AC($self) if $old;
    $val->add_importedElement_AC($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<clear_package>

  $obj->clear_package;

Clears the AssociationEnd C<package> links to L<UMMF::UML::MetaModel::Model_Management::Package|UMMF::UML::MetaModel::Model_Management::Package>.
Returns C<$obj>.

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

        
    $old->remove_importedElement_AC($self) if $old;
    $val->add_importedElement_AC($self)    if $val;

  ;

  }
  
  $self;
}


=head2 C<count_package>

  $obj->count_package;

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

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

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

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







# End of Class ElementImport


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

