You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/abstractmultilayergraph.jl
+39-31Lines changed: 39 additions & 31 deletions
Original file line number
Diff line number
Diff line change
@@ -33,7 +33,7 @@ abstract type AbstractMultilayerGraph{T<:Integer,U<:Real} <: AbstractGraph{T} en
33
33
34
34
# Nodes
35
35
"""
36
-
nodes(mg::M) where {M <: AbstractMultilayerGraph}
36
+
nodes(mg::AbstractMultilayerGraph
37
37
38
38
Return the nodes of the AbstractMultilayerGraph `mg`, in order of addition.
39
39
"""
@@ -110,11 +110,11 @@ Return true if `v` is in mg, else false.
110
110
Graphs.has_vertex(mg::M, v::T ) where {T, M <:AbstractMultilayerGraph{T}} = v indomain(mg.v_V_associations) # && !(mg.v_V_associations[v] isa MissingVertex)
111
111
112
112
"""
113
-
has_vertex(mg::M, mv::MultilayerVertex) where {T,U, M <: AbstractMultilayerGraph{T,U}}
@@ -204,18 +204,18 @@ Add a MultilayerEdge between `src` and `dst` with weight `weight` and metadata `
204
204
Graphs.add_edge!(mg::M, src::V, dst::V; weight::Union{Nothing, U}=one(U), metadata::Union{Tuple,NamedTuple}=NamedTuple() ) where {T,U, M <:AbstractMultilayerGraph{T,U}, V <:MultilayerVertex} =add_edge!(mg, ME(src, dst, weight, metadata))
205
205
206
206
"""
207
-
rem_edge!(mg::M, src::T, dst::T) where {T,U, M <: AbstractMultilayerGraph{T,U}}
207
+
rem_edge!(mg::M, src::T, dst::T) where {T, M <: AbstractMultilayerGraph{T}}
208
208
209
209
Remove edge from `src` to `dst` from `mg`. Return true if succeeds, false otherwise.
210
210
"""
211
-
Graphs.rem_edge!(mg::M, src::T, dst::T) where {T,U, M <:AbstractMultilayerGraph{T,U}} =rem_edge!(mg, mg.v_V_associations[src], mg.v_V_associations[dst])
211
+
Graphs.rem_edge!(mg::M, src::T, dst::T) where {T, M <:AbstractMultilayerGraph{T}} =rem_edge!(mg, mg.v_V_associations[src], mg.v_V_associations[dst])
212
212
213
213
"""
214
-
rem_edge!(mg::M, src::T, dst::T) where {T,U, M <: AbstractMultilayerGraph{T,U}}
Return the weight associated to the `MultilayerEdge` from `src` to `dst`.
244
244
"""
245
-
SimpleWeightedGraphs.get_weight(mg::M, src::MultilayerVertex, dst::MultilayerVertex) where M <:AbstractMultilayerGraph=get_halfegde(mg, src, dst).weight
@@ -513,18 +513,18 @@ Get the degree of vertices `vs` in `mg`.
513
513
Graphs.degree(mg::M, vs::AbstractVector{V}=vertices(mg)) where {T,M<:AbstractMultilayerGraph{T,<:Real},V<:MultilayerVertex} = [degree(mg, x) for x in vs]
514
514
515
515
"""
516
-
inneighbors( mg::M, mv::V ) where {T,M<:AbstractMultilayerGraph{T,<:Real},V<:MultilayerVertex}
0 commit comments