/// <summary> ///Sets the state of the attribute from a ZclAttributeDao which has been restored from a persisted state. /// @param dao the ZclAttributeDao to restore /// </summary> public void SetDao(ZclCluster cluster, ZclAttributeDao dao) { this._cluster = cluster; Id = dao.Id; Name = dao.Name; DataType = dao.DataType; Mandatory = dao.Mandatory; Implemented = dao.Implemented; Writable = dao.Writable; Readable = dao.Readable; Reportable = dao.Reportable; LastValue = dao.LastValue; LastReportTime = dao.LastReportTime; MinimumReportingPeriod = dao.MinimumReportingPeriod; MaximumReportingPeriod = dao.MaximumReportingPeriod; ReportingChange = dao.ReportingChange; ReportingTimeout = dao.ReportingTimeout; }
/// <summary> ///Returns a Data Acquisition Object for this attribute. This is a clean class recording the state of the primary ///fields of the attribute for persistence purposes. /// ///@return the {@link ZclAttributeDao} from this {@link ZclAttribute} /// </summary> public ZclAttributeDao GetDao() { ZclAttributeDao dao = new ZclAttributeDao(); dao.Id = Id; dao.DataType = DataType; dao.Name = Name; dao.Mandatory = Mandatory; dao.Implemented = Implemented; dao.MinimumReportingPeriod = MinimumReportingPeriod; dao.MaximumReportingPeriod = MaximumReportingPeriod; dao.Readable = Readable; dao.Writable = Writable; dao.Reportable = Reportable; dao.ReportingChange = ReportingChange; dao.ReportingTimeout = ReportingTimeout; dao.LastValue = LastValue; dao.LastReportTime = LastReportTime; return(dao); }