public CreateAmendment ( string value, string note, System.DateTime samplingTime, System.DateTime resultTime, |
||
value | string | |
note | string | |
samplingTime | System.DateTime | |
resultTime | System.DateTime | |
obtainingMethod | ||
parameterId | System.Int64 | The identifier of the parameter that the amendment will be linked to. needs more clarification |
tuple | The data tuple receiving the amendment.ku | |
return |
public Amendment CreateAmendment(string value, string note, DateTime samplingTime, DateTime resultTime, ObtainingMethod obtainingMethod, Int64 parameterId, DataTuple tuple)
{
Contract.Requires(!string.IsNullOrWhiteSpace(value));
Contract.Requires(parameterId > 0);
Contract.Requires(tuple != null);
Contract.Ensures(Contract.Result<Amendment>() != null);
Amendment e = new Amendment()
{
Value = value,
Note = note,
SamplingTime = samplingTime,
ResultTime = resultTime,
ObtainingMethod = obtainingMethod,
ParameterId = parameterId,
Tuple = tuple,
};
//using (IUnitOfWork uow = this.GetUnitOfWork())
//{
// IRepository<Amendment> repo = uow.GetRepository<Amendment>();
// repo.Put(e);
// uow.Commit();
//}
return (e);
}