You are on page 1of 2

C:\Users\YikChong\SkyDrive\VS2012\GeoAppCopy\GeoApp\Class.

cs
usingSystem;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Text;
usingSystem.Threading.Tasks;
namespaceGeoApp
{
classClass
{
}
[Serializable]
publicclassPointG
{
privatedoublex;
privatedoubley;
privatestringid;
publicdoubleX
{
get
{
returnx;
}
set
{
x=value;
}
}
publicdoubleY
{
get
{
returny;
}
set
{
y=value;
}
}
publicstringID
{
get
{
returnid;
}
set
{
id=value;
}
}
publicPointListCollectionGDuplicatedPointList(PointListGPL)
{
PointListCollectionGPLCollection=newPointListCollectionG();
for(inti=0;i<PL.Count;i++)
{
PointListGNewPointList=newPointListG();
for(intj=i+1;j<PL.Count;j++)
{
if(PL[i].X==PL[j].X&&PL[i].Y==PL[j].Y)
{
NewPointList.Add(PL[j]);
PL.Remove(PL[j]);
j=j1;
}
}
if(NewPointList.Count>0)
{
NewPointList.Add(PL[i]);
PLCollection.Add(NewPointList);

C:\Users\YikChong\SkyDrive\VS2012\GeoAppCopy\GeoApp\Class.cs
PL.Remove(PL[i]);
i=i1;
}
}
returnPLCollection;
}
}

You might also like