Sorted Methods
This commit is contained in:
parent
585a9213ce
commit
a54b189b08
@ -37,20 +37,6 @@ namespace Pathfinding
|
||||
return this._regions.Values.ToArray();
|
||||
}
|
||||
|
||||
public OsmNode? GetNode(Coordinates coordinates)
|
||||
{
|
||||
Region? regionWithNode = GetRegion(coordinates);
|
||||
if (regionWithNode is not null)
|
||||
return regionWithNode.GetNode(coordinates);
|
||||
else return null;
|
||||
}
|
||||
|
||||
public OsmNode? GetNode(ulong nodeId, ulong regionId)
|
||||
{
|
||||
Region? r = GetRegion(regionId);
|
||||
return r?.GetNode(nodeId);
|
||||
}
|
||||
|
||||
private Region? RegionFromFile(string filePath)
|
||||
{
|
||||
Region? retRegion = null;
|
||||
@ -68,5 +54,19 @@ namespace Pathfinding
|
||||
string filePath = Path.Join(workingDirectory, $"{regionId}.region");
|
||||
return RegionFromFile(filePath);
|
||||
}
|
||||
|
||||
public OsmNode? GetNode(Coordinates coordinates)
|
||||
{
|
||||
Region? regionWithNode = GetRegion(coordinates);
|
||||
if (regionWithNode is not null)
|
||||
return regionWithNode.GetNode(coordinates);
|
||||
return null;
|
||||
}
|
||||
|
||||
public OsmNode? GetNode(ulong nodeId, ulong regionId)
|
||||
{
|
||||
Region? r = GetRegion(regionId);
|
||||
return r?.GetNode(nodeId);
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user