using System; using System.Collections; namespace BCG { /// /// Provides a stream that with distinct rows with respect to the columns /// the user specifies in the argument /// [DataStreamUserRespresentation ("distinct")] public class DistinctRowStream : ViewStream { public DistinctRowStream (ViewStream stream, params string[] cols) { ArrayList groupByCols = new ArrayList (); foreach (string col in cols) foreach (string c in col.Split (' ')) groupByCols.Add (c); mySetRealSource (AttachStream(new GroupByStream (stream, new DistinctRowEvaluator (groupByCols.ToArray (typeof(string)) as string[]), false))); } } }