Skip to content

Commit

Permalink
Function addNewNode() renamed to addNewNode!().
Browse files Browse the repository at this point in the history
(Forgot to do the rename last commit.)
Related to Issue #65.

Signed-off-by: Ted Steiner <tsteiner2@gmail.com>
  • Loading branch information
tedsteiner committed Feb 6, 2015
1 parent 2bb5d4a commit 5703f2b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/crop.jl
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ function cropHighway!(nodes::Dict, bounds::Bounds, highway::Highway, valids::Bit
if !(Geodesy.onBounds(prev_node, bounds) ||
Geodesy.onBounds(node, bounds))
new_node = Geodesy.boundaryPoint(prev_node, node, bounds)
new_id = addNewNode(nodes, new_node)
new_id = addNewNode!(nodes, new_node)
insert!(highway.nodes, ni + !valid, new_id)
ni += 1
end
Expand Down
2 changes: 1 addition & 1 deletion src/intersections.jl
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,7 @@ function findIntersectionClusters( nodes::Dict{Int,ENU},
if length(clusters_nodes[k]) > 1
n = [clusters_nodes[k]...]
c = centroid(nodes,n)
cluster_node_id = addNewNode(nodes,c)
cluster_node_id = addNewNode!(nodes,c)

for j = 1:length(n)
cluster_map[n[j]] = cluster_node_id
Expand Down
6 changes: 3 additions & 3 deletions src/nodes.jl
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@ function nodesWithinRange{T<:Union(ENU,ECEF)}(nodes::Dict{Int,T},
end

### Add a new node ###
function addNewNode{T<:Union(LLA,ENU)}(nodes::Dict{Int,T},
loc::T,
start_id::Int=abs(int(hash(loc))) )
function addNewNode!{T<:Union(LLA,ENU)}(nodes::Dict{Int,T},
loc::T,
start_id::Int=abs(int(hash(loc))) )
id = start_id
while id <= typemax(Int)
if !haskey(nodes, id)
Expand Down

0 comments on commit 5703f2b

Please sign in to comment.