XarayaTranslationMemory  1.6
Public Member Functions | Private Attributes | List of all members
StringIterator Class Reference
Inheritance diagram for StringIterator:

Public Member Functions

 __construct ($projectID)
 
 rewind ()
 
 hasMore ()
 
 key ()
 
 current ()
 
 next ()
 
 valid ()
 

Private Attributes

 $ProjectID
 
 $ProjectStrings = []
 
 $Current
 
 $IsValid
 

Detailed Description

Class to list and iterate TranslationString objects as they are stored in the database.

StringIterator can be initialized with a project ID and then strings belonging to that project can be looped.

Definition at line 28 of file StringIterator.php.

Constructor & Destructor Documentation

◆ __construct()

StringIterator::__construct (   $projectID)

Create a new TranslationString iterator for looping on contained strings.

Parameters
$projectIDWhich project's strings to load.

Definition at line 41 of file StringIterator.php.

References $DB, GetDbConn(), GetTables(), and rewind().

Member Function Documentation

◆ current()

StringIterator::current ( )

Iterator interface: current function.

Definition at line 96 of file StringIterator.php.

References $Current.

Referenced by TranslationBackend\LocateStringNext().

◆ hasMore()

StringIterator::hasMore ( )

Iterator interface: hasMore function.

Definition at line 80 of file StringIterator.php.

◆ key()

StringIterator::key ( )

Iterator interface: key function.

Definition at line 88 of file StringIterator.php.

References $Current.

◆ next()

StringIterator::next ( )

Iterator interface: next function.

Definition at line 104 of file StringIterator.php.

◆ rewind()

StringIterator::rewind ( )

Iterator interface: rewind function.

Definition at line 72 of file StringIterator.php.

Referenced by __construct().

◆ valid()

StringIterator::valid ( )

Iterator interface: valid function.

Definition at line 112 of file StringIterator.php.

Member Data Documentation

◆ $Current

StringIterator::$Current
private

Index of the current string in the iterator

Definition at line 33 of file StringIterator.php.

Referenced by current(), and key().

◆ $IsValid

StringIterator::$IsValid
private

Iterator valid or not.

Definition at line 34 of file StringIterator.php.

◆ $ProjectID

StringIterator::$ProjectID
private

Stores which project's strings are loaded.

Definition at line 30 of file StringIterator.php.

◆ $ProjectStrings

StringIterator::$ProjectStrings = []
private

Loaded strings.

Definition at line 31 of file StringIterator.php.


The documentation for this class was generated from the following file: