public void Process(ReportCell cell, Entity entity)
 {
     if (entity.Score < 3)
     {
         cell.AddProperty(Bad);
     }
     else if (entity.Score >= 9)
     {
         cell.AddProperty(Good);
     }
 }
Example #2
0
 public void Process(ReportCell cell, TSourceEntity entity)
 {
     foreach (ReportCellProperty property in this.propertySelector(entity).Where(p => p != null))
     {
         cell.AddProperty(property);
     }
 }
Example #3
0
 private void AddProperties(ReportCell <TValue> cell)
 {
     foreach (ReportCellProperty property in this.Properties)
     {
         cell.AddProperty(property);
     }
 }
Example #4
0
 private void AddHeaderProperties(ReportCell cell)
 {
     foreach (ReportCellProperty property in this.headerProperties)
     {
         cell.AddProperty(property);
     }
 }
        private ReportCell CreateReportCell <TValue>(TValue title, params ReportCellProperty[] properties)
        {
            ReportCell <TValue> cell = new ReportCell <TValue>(title);

            foreach (ReportCellProperty property in properties)
            {
                cell.AddProperty(property);
            }

            return(cell);
        }
Example #6
0
        protected ReportCell AddGlobalProperties(ReportCell cell)
        {
            foreach (ReportCellProperty property in this.GlobalProperties)
            {
                if (!cell.HasProperty(property.GetType()))
                {
                    cell.AddProperty(property);
                }
            }

            return(cell);
        }
        private ReportCell CreateComplexHeaderCell(string title, int columnSpan)
        {
            ReportCell cell = new ReportCell <string>(title)
            {
                ColumnSpan = columnSpan,
            };

            foreach (ReportCellProperty property in this.CommonComplexHeaderProperties)
            {
                cell.AddProperty(property);
            }

            if (this.ComplexHeaderProperties.ContainsKey(title))
            {
                foreach (ReportCellProperty property in this.ComplexHeaderProperties[title])
                {
                    cell.AddProperty(property);
                }
            }

            return(cell);
        }
Example #8
0
 public void Process(ReportCell cell, string data)
 {
     cell.AddProperty(new CustomProperty(true));
 }