public IPosition NearestNeighbor(IPosition targetPoint) { NearestNeighbor_ByM2MStructure NN = new NearestNeighbor_ByM2MStructure(m2mStructure); if (GetQueryPosition != null) { NN.GetQueryPosition += GetQueryPosition; } if (GetQueryPart != null) { NN.GetQueryPart += GetQueryPart; } if (SearchOnePartBeginAndGetSearchPartSequence != null) { NN.SearchOnePartBeginAndGetSearchPartSequence += SearchOnePartBeginAndGetSearchPartSequence; } if (GetSearchPart != null) { NN.GetSearchPart += GetSearchPart; } if (GetComparedPoint != null) { NN.GetComparedPoint += GetComparedPoint; } if (CurrentNearestPointChanged != null) { NN.CurrentNearestPointChanged += CurrentNearestPointChanged; } if (SearchBoundChanged != null) { NN.SearchBoundChanged += SearchBoundChanged; } return(NN.NearestNeighbor(targetPoint)); }
public IPosition ApproximateNearestNeighbor(IPosition targetPoint) { NearestNeighbor_ByM2MStructure NN = new NearestNeighbor_ByM2MStructure(m2mStructure); return(NN.ApproximateNearestNeighbor(targetPoint)); }
public IPositionSet ApproximateKNearestNeighbor(IPosition targetPoint, int k) { NearestNeighbor_ByM2MStructure NN = new NearestNeighbor_ByM2MStructure(m2mStructure); return(NN.ApproximateSearchKNearestNeighbor(targetPoint, k)); }