util
[ class tree: util ] [ index: util ] [ all elements ]

Class: RDF_StatementIterator

Source Location: /RDF-0.2.0/RDF/StatementIterator.php

Class Overview

RDF_Object
   |
   --RDF_StatementIterator

Iterator for traversing models.


Author(s):

Version:

  • V0.7

Variables

Methods


Inherited Variables

Inherited Methods

Class: RDF_Object

RDF_Object::factory()
RDF_Object::toString()
Serializes a object into a string

Class Details

[line 15]
Iterator for traversing models.

This class can be used for iterating forward and backward trough Model_Memorys. It should be instanced using the getIterator() method of a Model_Memory.



[ Top ]


Class Variables

$model =

[line 23]

Reference to the Model_Memory
  • Access: protected

Type:   object Model_Memory


[ Top ]

$position =

[line 33]

Current position StatementIterator does not use the build in PHP array iterator, so you can use serveral iterators on a single Model_Memory.
  • Access: protected

Type:   integer


[ Top ]



Method Detail

RDF_StatementIterator (Constructor)   [line 39]

RDF_StatementIterator RDF_StatementIterator( object Model_Memory &$model)

  • Access: public

Parameters:

object Model_Memory   &$model   — 

[ Top ]

current   [line 113]

statement current( )

Returns the current statement.
  • Return: or null if there is no current statement.
  • Access: public

[ Top ]

getCurrentPosition   [line 162]

integer getCurrentPosition( )

Returns the current position of the iterator.
  • Access: public

[ Top ]

hasNext   [line 51]

boolean hasNext( )

Returns TRUE if there are more statements.
  • Access: public

[ Top ]

hasPrevious   [line 66]

boolean hasPrevious( )

Returns TRUE if the first statement has not been reached.
  • Access: public

[ Top ]

moveFirst   [line 128]

void moveFirst( )

Moves the pointer to the first statement.
  • Access: public

[ Top ]

moveLast   [line 139]

void moveLast( )

Moves the pointer to the last statement.
  • Access: public

[ Top ]

moveTo   [line 151]

void moveTo( $position)

Moves the pointer to a specific statement.

If you set an off-bounds value, next(), previous() and current() will return null

  • Access: public

Parameters:

   $position   — 

[ Top ]

next   [line 81]

statement next( )

Returns the next statement.
  • Return: or null if there is no next statement.
  • Access: public

[ Top ]

previous   [line 97]

statement previous( )

Returns the previous statement.
  • Return: or null if there is no previous statement.
  • Access: public

[ Top ]


Documentation generated on Mon, 11 Mar 2019 15:39:30 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.