Changeset 11913 for trunk/sources
- Timestamp:
- 02/05/15 13:56:26 (10 years ago)
- Location:
- trunk/sources/HeuristicLab.Core/3.3/Interfaces/DirectedGraph
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Core/3.3/Interfaces/DirectedGraph/IArc.cs
r11256 r11913 21 21 22 22 using System; 23 using HeuristicLab.Common; 23 24 24 25 namespace HeuristicLab.Core { … … 28 29 string Label { get; set; } 29 30 double Weight { get; set; } 30 object Data { get; set; }31 31 32 32 event EventHandler Changed; // generic event for when the label, weight or data were changed 33 33 } 34 34 35 public interface IArc<T> : IArc where T : class,IItem { 36 new IVertex<T> Source { get; } 37 new IVertex<T> Target { get; } 35 public interface IArc<T> : IArc where T : class,IDeepCloneable { 36 T Data { get; set; } 38 37 } 39 38 } -
trunk/sources/HeuristicLab.Core/3.3/Interfaces/DirectedGraph/IDirectedGraph.cs
r11391 r11913 26 26 namespace HeuristicLab.Core { 27 27 public interface IDirectedGraph : IItem { 28 IEnumerable<IVertex> Vertices { get; } 29 IEnumerable<IArc> Arcs { get; } 30 28 31 void Clear(); 29 32 void AddVertex(IVertex vertex); 33 void RemoveVertex(IVertex vertex); 34 30 35 void AddVertices(IEnumerable<IVertex> vertexList); 36 void RemoveVertices(IEnumerable<IVertex> vertexList); 37 31 38 IArc AddArc(IVertex source, IVertex target); 32 39 void AddArc(IArc arc); 33 void RemoveVertices(IEnumerable<IVertex> vertexList);34 void RemoveVertex(IVertex vertex);35 40 void RemoveArc(IArc arc); 36 IEnumerable<IVertex> Vertices { get; } 37 IEnumerable<IArc> Arcs { get; } 41 42 void AddArcs(IEnumerable<IArc> arcs); 43 void RemoveArcs(IEnumerable<IArc> removeArcs); 38 44 39 45 event EventHandler<EventArgs<IVertex>> VertexAdded; -
trunk/sources/HeuristicLab.Core/3.3/Interfaces/DirectedGraph/IVertex.cs
r11241 r11913 36 36 double Weight { get; set; } 37 37 38 IDeepCloneable Data { get; set; }39 40 38 void AddArc(IArc arc); 41 39 void RemoveArc(IArc arc); … … 46 44 } 47 45 48 public interface IVertex<T> : IVertex 49 where T : class { 50 new T Data { get; set; } 46 public interface IVertex<T> : IVertex where T : class, IDeepCloneable { 47 T Data { get; set; } 51 48 } 52 49 }
Note: See TracChangeset
for help on using the changeset viewer.