public TransferNotice(string key, DetectionCompany company, PipeType pipeType, PipePosition position,Account creator, DateTime dateCreated) : base(key) { this.Company = company; this.Creator = creator; this.DateCreated = dateCreated; this.PipeType = pipeType; this.Position = position; this.State = TransferNoticeState.Created; }
public static Boolean Exist(PipePosition pos) { IList<PipePosition> postions = RepositoryFactory.GetRepository<IPipePositionRepository, PipePosition>().FindAll(); return postions.Where(p => string.Equals(pos.Company.Key.ToString(), p.Company.Key.ToString(), StringComparison.InvariantCultureIgnoreCase) && p.ToString().Equals(pos.ToString())).Count() != 0; }
public static bool CanDelete(PipePosition pos) { if (pos.IsLocked) return false; // TODO: Other Check return true; }
public void CopyTo(PipePosition pos) { if (pos == null) { throw new ArgumentNullException("pos"); } pos.Area = this.Area; pos.Column = this.Column; pos.Field = this.Field; pos.Height = this.Height; pos.Length = this.Length; pos.Name = this.Name; pos.Row = this.Row; pos.Type = this.Type; pos.Width = this.Width; }