Exemplo n.º 1
0
		///	<summary> 
		///		This method copy's each database field which is in the <paramref name="includedColumns"/> 
		///		from the <paramref name="source"/> interface to this data row.
		/// </summary>
		public void Copy_From_But_TakeOnly(IRComputer source, params string[] includedColumns)
		{
			if (includedColumns.Contains(RComputersTable.IdCol)) this.Id = source.Id;
			if (includedColumns.Contains(RComputersTable.NameCol)) this.Name = source.Name;
			if (includedColumns.Contains(RComputersTable.OsNameCol)) this.OsName = source.OsName;
			if (includedColumns.Contains(RComputersTable.OsVersionCol)) this.OsVersion = source.OsVersion;
			if (includedColumns.Contains(RComputersTable.OsProductTypeNumberCol)) this.OsProductTypeNumber = source.OsProductTypeNumber;
			if (includedColumns.Contains(RComputersTable.OsRegisteredUserCol)) this.OsRegisteredUser = source.OsRegisteredUser;
			if (includedColumns.Contains(RComputersTable.OsCodeSetCol)) this.OsCodeSet = source.OsCodeSet;
			if (includedColumns.Contains(RComputersTable.OsCountryCodeCol)) this.OsCountryCode = source.OsCountryCode;
			if (includedColumns.Contains(RComputersTable.ReceivedRPacketsCol)) this.ReceivedRPackets = source.ReceivedRPackets;
			if (includedColumns.Contains(RComputersTable.LatestRPacketCol)) this.LatestRPacket = source.LatestRPacket;
			if (includedColumns.Contains(RComputersTable.CreationTimeCol)) this.CreationTime = source.CreationTime;
		}
Exemplo n.º 2
0
		///	<summary> This method copy's each database field into the <paramref name="target"/> interface. </summary>
		public void Copy_To(IRComputer target, bool includePrimaryKey = false)
		{
			if (includePrimaryKey) target.Id = this.Id;
			target.Name = this.Name;
			target.OsName = this.OsName;
			target.OsVersion = this.OsVersion;
			target.OsProductTypeNumber = this.OsProductTypeNumber;
			target.OsRegisteredUser = this.OsRegisteredUser;
			target.OsCodeSet = this.OsCodeSet;
			target.OsCountryCode = this.OsCountryCode;
			target.ReceivedRPackets = this.ReceivedRPackets;
			target.LatestRPacket = this.LatestRPacket;
			target.CreationTime = this.CreationTime;
		}
Exemplo n.º 3
0
		///	<summary> This method copy's each database field from the <paramref name="source"/> interface to this data row.</summary>
		public void Copy_From(IRComputer source, bool includePrimaryKey = false)
		{
			if (includePrimaryKey) this.Id = source.Id;
			this.Name = source.Name;
			this.OsName = source.OsName;
			this.OsVersion = source.OsVersion;
			this.OsProductTypeNumber = source.OsProductTypeNumber;
			this.OsRegisteredUser = source.OsRegisteredUser;
			this.OsCodeSet = source.OsCodeSet;
			this.OsCountryCode = source.OsCountryCode;
			this.ReceivedRPackets = source.ReceivedRPackets;
			this.LatestRPacket = source.LatestRPacket;
			this.CreationTime = source.CreationTime;
		}
Exemplo n.º 4
0
		public static void CopyInto(this CsspIdentity packet, IRComputer target)
		{
			target.Id = packet.ComputerId;
		}