##========================================================================
## POD DOCUMENTATION, auto-generated by podextract.perl

##========================================================================
## NAME
=pod

=head1 NAME

DiaColloDB::Temp::Vec - DiaColloDB: temporary mmaped vec() buffers

=cut

##========================================================================
## SYNOPSIS
=pod

=head1 SYNOPSIS

 ##========================================================================
 ## PRELIMINARIES
 
 use DiaColloDB::Temp::Vec;
 
 ##========================================================================
 ## Constructors etc.
 
 $tmpvec = CLASS->new($size, $bits);
 
 ##========================================================================
 ## Accessors
 
 \$buf = $tmpv->bufr();
 $bits = $tmpv->bits();
 $size = $tmpv->size();
 

=cut

##========================================================================
## DESCRIPTION
=pod

=head1 DESCRIPTION

DiaColloDB::Temp::Hash provides a simple interface
to large temporary L<vec()|perlfunc/vec> scalars
mmap()ed to anonymous memory blocks.
This is mostly useful to ensure that the memory used by large intermediate
vectors is freed when the objects are destroyed, since mmap() bypasses
perl's internal memory management.

=cut

##----------------------------------------------------------------
## DESCRIPTION: DiaColloDB::Temp::Vec: Globals & Constants
=pod

=head2 Globals & Constants

=over 4

=item Variable: @ISA

DiaColloDB::Temp::Hash inherits from
L<DiaColloDB::Temp|DiaColloDB::Temp>.

=item Variable: $LOG_DEFAULT

Default log-level for debugging;
default=undef: off.

=back

=cut

##----------------------------------------------------------------
## DESCRIPTION: DiaColloDB::Temp::Vec: Constructors etc.
=pod

=head2 Constructors etc.

=over 4

=item new

 $tmpvec = CLASS->new($size, $bits);

Creates a new temporary buffer for use e.g. with L<vec()|perlfunc/vec>
suitable for storing C<$size> logical elements of C<$bits> width each.

%opts, %$mmvec:

 (
  log  => $level,      ##-- logging verbosity (default=$LOG_DEFAULT)
  buf  => $buf,        ##-- guts: real underlying mmap()ed buffer data
  size => $size,       ##-- number of logical elements
  bits => $bits,       ##-- number of bits per element
 )

=back

=cut

##----------------------------------------------------------------
## DESCRIPTION: DiaColloDB::Temp::Vec: Accessors
=pod

=head2 Accessors

=over 4

=item bufr

 \$buf = $tmpv->bufr();

Returns reference to the underlying mmap()ed buffer.

=item bits

 $bits = $tmpv->bits();

Returns number of bits per logical element as specified in constructor.

=item size

 $size = $tmpv->size();

Returns number of logical elements as specified in constructor.

=back

=cut

##========================================================================
## END POD DOCUMENTATION, auto-generated by podextract.perl

##======================================================================
## Footer
##======================================================================
=pod

=head1 AUTHOR

Bryan Jurish E<lt>moocow@cpan.orgE<gt>

=head1 COPYRIGHT AND LICENSE

Copyright (C) 2015-2016 by Bryan Jurish

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

=head1 SEE ALSO

L<DiaColloDB::Temp::Array(3pm)|DiaColloDB::Temp::Array>,
L<DiaColloDB::Temp::Hash(3pm)|DiaColloDB::Temp::Hash>,
L<DiaColloDB::PDL::MM(3pm)|DiaColloDB::PDL::MM>,
L<DiaColloDB::Temp(3pm)|DiaColloDB::Temp>,
L<DiaColloDB(3pm)|DiaColloDB>,
L<perl(1)|perl>,
...



=cut
