Share via


SetIterator.next Method

Moves the iterator to the next element.

Syntax

public void next()

Run On

Called

Remarks

Use SetIterator.more to determine whether the iterator points to a valid element.

Examples

The following example uses the SetIterator.next method to move the iterator to the next element in the set, before testing whether there is another element, and if there is another element, adding the value to a container.

static public void saveSequence(classId _classId, Set _sequence) 
{ 
    SysCheckListItemTable sysCheckListItemTable; 
    SetIterator           si; 
    container             con = connull(); 
  
    if (_sequence) 
    { 
        si = new SetIterator(_sequence); 
        si.begin(); 
        while (si.more()) 
        { 
             con += si.value(); 
             si.next(); 
        } 
    } 
  
    //... 
}

See Also

SetIterator Class

SetIterator.more Method