Beispiel #1
0
 public Column(ColumnId id, ColumnBehavior behavior, bool groupable, ColumnHeader header, SortBoundaries sortBoundaries, params PropertyDefinition[] properties)
 {
     if (behavior == null)
     {
         behavior = Column.defaultBehavior;
     }
     if (groupable)
     {
         this.groupType = behavior.GroupType;
     }
     else
     {
         this.groupType = GroupType.None;
     }
     if (this.GroupType != GroupType.None && sortBoundaries == null)
     {
         throw new ArgumentException("sortBoundaries may not be null if groupType does not equal GroupType.None");
     }
     if (properties == null || properties.Length <= 0)
     {
         throw new ArgumentException("properties may not be null or an empty array");
     }
     this.id             = id;
     this.behavior       = behavior;
     this.properties     = properties;
     this.header         = header;
     this.sortBoundaries = sortBoundaries;
     if (1 <= properties.Length)
     {
         this.isTypeDownCapable = (properties[0].Type.Equals(typeof(string)) || properties[0].Type.Equals(typeof(string[])));
     }
 }
Beispiel #2
0
 public Column(ColumnId id, ColumnBehavior behavior, bool groupable, ColumnHeader header, SortBoundaries sortBoundaries, bool isTypeDownCapable, params PropertyDefinition[] properties) : this(id, behavior, groupable, header, sortBoundaries, properties)
 {
     this.isTypeDownCapable = isTypeDownCapable;
 }