@@ -4,13 +4,13 @@ using LightGraphs
4
4
using JLD2
5
5
6
6
import Base:
7
- convert, eltype, show, == , Pair, Tuple, in, copy, length, start, next, done, issubset, zero, one,
7
+ convert, eltype, show, == , Pair, Tuple, in, copy, length, issubset, zero, one,
8
8
size, getindex, setindex!, length, IndexStyle
9
9
10
10
import LightGraphs:
11
- _NI, _insert_and_dedup!, AbstractEdge, AbstractEdgeIter,
11
+ _NI, AbstractEdge, AbstractEdgeIter,
12
12
src, dst, edgetype, nv, ne, vertices, edges, is_directed,
13
- has_vertex, has_edge, in_neighbors, out_neighbors ,
13
+ has_vertex, has_edge, inneighbors, outneighbors ,
14
14
indegree, outdegree, degree, insorted, squash,
15
15
16
16
AbstractGraphFormat, loadgraph, savegraph
@@ -57,7 +57,7 @@ indtype(g::AbstractStaticGraph{T, U}) where T where U = U
57
57
eltype (x:: AbstractStaticGraph ) = vectype (x)
58
58
59
59
function show (io:: IO , g:: AbstractStaticGraph )
60
- dir = is_directed (g)? " directed" : " undirected"
60
+ dir = is_directed (g) ? " directed" : " undirected"
61
61
print (io, " {$(nv (g)) , $(ne (g)) } $dir simple static {$(vectype (g)) , $(indtype (g)) } graph" )
62
62
end
63
63
69
69
70
70
@inline function fadj (g:: AbstractStaticGraph , s:: Integer )
71
71
r = _fvrange (g, s)
72
- return fastview (g. f_vec, r)
72
+ return view (g. f_vec, r)
73
73
end
74
74
75
75
nv (g:: AbstractStaticGraph{T, U} ) where T where U = T (length (g. f_ind) - 1 )
76
76
vertices (g:: AbstractStaticGraph{T, U} ) where T where U = one (T): nv (g)
77
77
78
-
79
78
has_edge (g:: AbstractStaticGraph , e:: AbstractStaticEdge ) =
80
- insorted (dst (e), out_neighbors (g, src (e)))
79
+ insorted (dst (e), outneighbors (g, src (e)))
81
80
82
81
edgetype (g:: AbstractStaticGraph{T} ) where T = StaticEdge{T}
83
82
edges (g:: AbstractStaticGraph ) = StaticEdgeIter (g)
84
83
85
84
has_vertex (g:: AbstractStaticGraph , v:: Integer ) = v in vertices (g)
86
85
87
- out_neighbors (g:: AbstractStaticGraph , v:: Integer ) = fadj (g, v)
88
- in_neighbors (g:: AbstractStaticGraph , v:: Integer ) = badj (g, v)
86
+ outneighbors (g:: AbstractStaticGraph , v:: Integer ) = fadj (g, v)
87
+ inneighbors (g:: AbstractStaticGraph , v:: Integer ) = badj (g, v)
89
88
90
89
zero (g:: T ) where T<: AbstractStaticGraph = T ()
91
90
@@ -97,6 +96,7 @@ include("staticgraph.jl")
97
96
include (" staticdigraph.jl" )
98
97
include (" persistence.jl" )
99
98
99
+
100
100
const SGraph = StaticGraph
101
101
const SDiGraph = StaticDiGraph
102
102
@@ -105,5 +105,6 @@ const StaticEdgeIter{G} = LightGraphs.SimpleGraphs.SimpleEdgeIter{G}
105
105
eltype (:: Type{StaticEdgeIter{StaticGraph{T, U}}} ) where T where U = StaticGraphEdge{T}
106
106
eltype (:: Type{StaticEdgeIter{StaticDiGraph{T, U}}} ) where T where U = StaticDiGraphEdge{T}
107
107
108
+ include (" overrides.jl" )
108
109
109
110
end # module
0 commit comments