Help-Site Computer Manuals
Software
Hardware
Programming
Networking
  Algorithms & Data Structures   Programming Languages   Revision Control
  Protocols
  Cameras   Computers   Displays   Keyboards & Mice   Motherboards   Networking   Printers & Scanners   Storage
  Windows   Linux & Unix   Mac

RDF::Core::Enumerator
an object that provides access to a set of statements

RDF::Core::Enumerator - an object that provides access to a set of statements


NAME

RDF::Core::Enumerator - an object that provides access to a set of statements


SYNOPSIS


  #print content of a model

  my $enumerator = $model->getStmts;

  my $statement = $enumerator->getFirst;

  while (defined $statement) {

    print $statement->getLabel."\n";

    $statement = $enumerator->getNext

  }

  $enumerator->close;


DESCRIPTION

A set of statements (such as returned by $model->getStmts) is represented by some descendant of RDF::Core::Enumerator. Statements can be accessed by calling getNext method repeatedly until it returns undef, which means there are no more statements to get.

Interface

  • new
  • Constructors differ for different implementations of Enumerator, see RDF::Core::Enumerator::Memory, RDF::Core::Enumerator::DB_File, RDF::Core::Enumerator::Postgres

  • getFirst
  • Returns first statement in Enumerator, resets all preceding getNext calls. Returns undef if there is no statement.

  • getNext
  • Returns next statement or undef if there are no more statements.

  • close
  • Releases memory, disk, database cursor or whatever it used to provide the data.


AUTHOR

Ginger Alliance, rdf@gingerall.cz


SEE ALSO


 RDF::Core::Enumerator::Memory, RDF::Core::Enumerator::DB_File, RDF::Core::Enumerator::Postgres
Programminig
Wy
Wy
yW
Wy
Programming
Wy
Wy
Wy
Wy