Free cookie consent management tool by TermsFeed Policy Generator

source: branches/FitnessLandscapeAnalysis/HeuristicLab.Problems.NK/BinaryVectorComparers/BinaryVectorComparer.cs @ 11247

Last change on this file since 11247 was 7128, checked in by epitzer, 13 years ago

#1696 Integrate fitness landscape analysis plugins from Heureka! repository.

File size: 1.1 KB
Line 
1using System;
2using System.Collections.Generic;
3using System.Linq;
4using System.Text;
5using HeuristicLab.Core;
6using HeuristicLab.Data;
7using HeuristicLab.Common;
8using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
9using HeuristicLab.Encodings.BinaryVectorEncoding;
10
11namespace HeuristicLab.Problems.NK {
12
13  public interface IBinaryVectorComparer : INamedItem, IComparer<BinaryVector> { }
14
15  [StorableClass]
16  public abstract class BinaryVectorComparer : NamedItem, IBinaryVectorComparer {
17
18    public override bool CanChangeName { get { return false; } }
19    public override bool CanChangeDescription { get { return false; } }
20
21    [StorableConstructor]
22    protected BinaryVectorComparer(bool serializing) : base(serializing) { }
23    protected BinaryVectorComparer(BinaryVectorComparer original, Cloner cloner)
24      : base(original, cloner) { }
25    public BinaryVectorComparer() {
26      name = ItemName;
27      description = ItemDescription;
28    }   
29
30    public abstract int Compare(BinaryVector x, BinaryVector y);
31  } 
32}
Note: See TracBrowser for help on using the repository browser.