/// <summary> /// Builds the data fields for category. /// </summary> /// <param name="category">The category.</param> /// <param name="instance">The instance.</param> /// <returns></returns> public PropertyCollectionExtended buildDataFieldsForCategory(String category, T instance) { PropertyCollectionExtended pce = new PropertyCollectionExtended(); PropertyCollectionExtended shema = this[category]; pce.name = shema.name; pce.description = shema.description; pce.AddMetaRangeFrom(shema); pce.setFromObject(instance); return(pce); }
/// <summary> /// Builds the data table for category. /// </summary> /// <param name="category">The category.</param> /// <param name="instance">The instance.</param> /// <returns></returns> /// <exception cref="NotImplementedException">-- not implemented --</exception> public DataTable buildDataTableForCategory(String category, T instance) { PropertyCollectionExtended pce = new PropertyCollectionExtended(); PropertyCollectionExtended shema = this[category]; pce.name = shema.name; pce.description = shema.description; pce.AddMetaRangeFrom(shema); pce.setFromObject(instance); throw new NotImplementedException("-- not implemented --"); return(null); // pce.buildDataTableVertical(category, shema.description); }
/// <summary> /// Builds the property collection extended list. /// </summary> /// <param name="category">The category.</param> /// <param name="instances">The instances.</param> /// <param name="instanceNameProperty">The instance name property.</param> /// <returns></returns> public PropertyCollectionExtendedList buildPropertyCollectionExtendedList(String category, IEnumerable <T> instances, String instanceNameProperty) { PropertyCollectionExtended shema = this[category]; PropertyCollectionExtendedList output = new PropertyCollectionExtendedList(); foreach (T instance in instances) { PropertyCollectionExtended pce = new PropertyCollectionExtended(); pce.name = shema.name; pce.description = shema.description; pce.AddMetaRangeFrom(shema); // String iName = //instance.GetPropertyValue().toStringSafe(); pce.name = getName(instance, instanceNameProperty); output.Add(pce, pce.name, true); } return(output); }
/// <summary> /// Builds the data table. /// </summary> /// <param name="category">The category.</param> /// <param name="instances">The instances.</param> /// <param name="instanceNameProperty">The instance name property.</param> /// <returns></returns> /// <exception cref="NotImplementedException">-- not implemented yet --</exception> public DataTable buildDataTable(String category, IEnumerable <T> instances, String instanceNameProperty) { PropertyCollectionExtended shema = this[category]; DataTable output = shema.getDataTable(); foreach (T instance in instances) { PropertyCollectionExtended pce = new PropertyCollectionExtended(); pce.name = shema.name; pce.description = shema.description; pce.AddMetaRangeFrom(shema); pce.name = getName(instance, instanceNameProperty); // output.Add(pce, pce.name, true); throw new NotImplementedException("-- not implemented yet --"); // output.AddDataTableRow(instance, imbDataTableExtensions.buildDataTableOptions.none); } return(output); }