Files
Aaru/Aaru.Dto/CdOffsetDto.cs

61 lines
2.3 KiB
C#
Raw Permalink Normal View History

2019-01-01 16:43:34 +00:00
// /***************************************************************************
2020-02-27 12:31:23 +00:00
// Aaru Data Preservation Suite
2019-01-01 16:43:34 +00:00
// ----------------------------------------------------------------------------
//
2020-03-11 21:56:55 +00:00
// Filename : CdOffsetDto.cs
2019-01-01 16:43:34 +00:00
// Author(s) : Natalia Portillo <claunia@claunia.com>
//
2020-03-11 21:56:55 +00:00
// Component : DTOs.
2019-01-01 16:43:34 +00:00
//
// --[ Description ] ----------------------------------------------------------
//
2020-03-11 21:56:55 +00:00
// DTO for syncing Compact Disc read offsets.
2019-01-01 16:43:34 +00:00
//
// --[ License ] --------------------------------------------------------------
//
// This library is free software; you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as
// published by the Free Software Foundation; either version 2.1 of the
// License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful, but
// WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, see <http://www.gnu.org/licenses/>.
//
// ----------------------------------------------------------------------------
2024-12-19 10:45:18 +00:00
// Copyright © 2011-2025 Natalia Portillo
2019-01-01 16:43:34 +00:00
// ****************************************************************************/
2023-10-05 01:05:22 +01:00
using System.Diagnostics.CodeAnalysis;
2022-03-07 07:36:43 +00:00
using Aaru.CommonTypes.Metadata;
namespace Aaru.Dto;
2022-03-06 13:29:37 +00:00
/// <inheritdoc />
2022-03-07 07:36:43 +00:00
/// <summary>DTO from a CD drive read offset</summary>
2023-10-05 01:05:22 +01:00
[SuppressMessage("ReSharper", "UnusedMember.Global")]
2022-03-06 13:29:37 +00:00
public class CdOffsetDto : CdOffset
2019-01-01 16:43:34 +00:00
{
2022-03-07 07:36:43 +00:00
/// <summary>Build an empty DTO</summary>
2022-03-06 13:29:37 +00:00
public CdOffsetDto() {}
2019-01-01 16:43:34 +00:00
2022-03-07 07:36:43 +00:00
/// <summary>Build a DTO using the specified offset and database ID</summary>
2022-03-06 13:29:37 +00:00
/// <param name="offset">CD reading offset</param>
/// <param name="id">Database ID</param>
public CdOffsetDto(CdOffset offset, int id)
{
Manufacturer = offset.Manufacturer;
Model = offset.Model;
Offset = offset.Offset;
Submissions = offset.Submissions;
Agreement = offset.Agreement;
Id = id;
2019-01-01 16:43:34 +00:00
}
2022-03-06 13:29:37 +00:00
2022-03-07 07:36:43 +00:00
/// <summary>Database ID</summary>
2022-03-06 13:29:37 +00:00
public int Id { get; set; }
2019-01-01 16:43:34 +00:00
}