App-Requirement-Arch

 view release on metacpan or  search on metacpan

lib/App/Requirement/Arch.pm  view on Meta::CPAN


=cut

my ($master_template_file) = @_ ;
	
croak "Error: Can't find file '$master_template_file'" unless -f $master_template_file;

my $master_template = do $master_template_file or croak "Bad template '$master_template_file'! $@." ;

croak 'Error: Requirement is not a hash reference!' unless 'HASH' eq ref $master_template ;

croak "Error: This script can only handle update to version 2.0 of the requirement and use case template!" unless $master_template->{VERSION} == 2.0 ;

my $requirement_template = $master_template->{TEMPLATE} ;

return $requirement_template ;
}

#--------------------------------------------------------------------------------------------------------------

sub load_master_categories
{

=head2 load_master_categories($master_categories_file)

Load and verify the master template.

I<Arguments>

=over 2

=item * $master_categories_file - Name to a file containing the master categories.

=back

I<Returns>

=over 2

=item * %master_categories - A data structure containing the categories hierarchy

=back

=cut

my ($master_categories_file) = @_ ;
	
croak "Error: Can't find file '$master_categories_file'" unless -f $master_categories_file ;

my $master_categories = do $master_categories_file or croak "Bad template '$master_categories_file'! $@." ;

croak 'Error: Requirement is not a hash reference!' unless 'HASH' eq ref $master_categories;

return $master_categories;
}

#-------------------------------------------------------------------------------

1 ;

=head1 BUGS AND LIMITATIONS

None so far.

=head1 AUTHORS

	Nadim ibn hamouda el Khemir
	CPAN ID: NH
	mailto: nadim@cpan.org

=head1 LICENSE AND COPYRIGHT

This program is free software; you can redistribute
it and/or modify it under the same terms as Perl itself.

=head1 SUPPORT

You can find documentation for this module with the perldoc command.

    perldoc App::Requirement::Arch

You can also look for information at:

=over 4

=item * AnnoCPAN: Annotated CPAN documentation

L<http://annocpan.org/dist/App-Requirement-Arch>

=item * RT: CPAN's request tracker

Please report any bugs or feature requests to  L <bug-app-requirement-arch@rt.cpan.org>.

We will be notified, and then you'll automatically be notified of progress on
your bug as we make changes.

=item * Search CPAN

L<http://search.cpan.org/dist/App-Requirement-Arch>

=back

=head1 SEE ALSO


=cut



( run in 1.905 second using v1.01-cache-2.11-cpan-39bf76dae61 )