get_Next Method

WRAPPER_API DatumShift *get_Next() const

 

Description

The get_Next method returns the DatumShift that follows the last DatumShift returned by this collection.  If the collection is empty, or if the last DatumShift returned was the last in the collection, this method will return NULL.  It is the user's responsibility to free the DatumShift returned by this method.

 

Example

void DatumShiftCollection_getNext(GeoCalcPBW::DatumShiftCollection & dsc, GeoCalcPBW::GeodeticPoint & inPt, GeoCalcPBW::GeodeticPoint & outPt)

{

GeoCalcPBW::GeodeticPoint startingPt(inPt);

GeoCalcPBW::DatumShift * ds = dsc.get_Front();

while(ds != NULL)

{

if(! ds->ShiftForward(inPt, outPt))

{

AfxMessageBox("ShiftForward failed");

return;

}

inPt.CopyLocation(outPt);

delete ds;

ds = dsc.get_Next();

}

inPt = startingPt;

}