Well 95% of code is accessing external COM libraries which work with a GIS application. Some code is generic (see below), but how could this be an object - and would it be necessary??
Code:
private static int RoundToNearest100(int iNumberToRound)
{
int iToNearest = 100;
int iNearest = 0;
bool bIsUpper = false;
int iRest = iNumberToRound % iToNearest;
if (iNumberToRound == 550) bIsUpper = true;
if (bIsUpper == true)
{
iNearest = (iNumberToRound - iRest) + iToNearest;
return iNearest;
}
else if (iRest > (iToNearest/2))
{
iNearest = (iNumberToRound - iRest) + iToNearest;
return iNearest;
}
else if (iRest < (iToNearest/2))
{
iNearest =(iNumberToRound - iRest);
return iNearest;
}
return 0;
}