mirror of
https://github.com/claunia/marechai.git
synced 2025-12-16 19:14:25 +00:00
Add optical media tracks.
This commit is contained in:
6675
Marechai.Database/Migrations/20200611215624_AddOpticalMediaTableOfContents.Designer.cs
generated
Normal file
6675
Marechai.Database/Migrations/20200611215624_AddOpticalMediaTableOfContents.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,38 @@
|
|||||||
|
/******************************************************************************
|
||||||
|
// MARECHAI: Master repository of computing history artifacts information
|
||||||
|
// ----------------------------------------------------------------------------
|
||||||
|
//
|
||||||
|
// Author(s) : Natalia Portillo <claunia@claunia.com>
|
||||||
|
//
|
||||||
|
// --[ License ] --------------------------------------------------------------
|
||||||
|
//
|
||||||
|
// This program is free software: you can redistribute it and/or modify
|
||||||
|
// it under the terms of the GNU General Public License as
|
||||||
|
// published by the Free Software Foundation, either version 3 of the
|
||||||
|
// License, or (at your option) any later version.
|
||||||
|
//
|
||||||
|
// This program 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 General Public License for more details.
|
||||||
|
//
|
||||||
|
// You should have received a copy of the GNU General Public License
|
||||||
|
// along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
//
|
||||||
|
// ----------------------------------------------------------------------------
|
||||||
|
// Copyright © 2003-2020 Natalia Portillo
|
||||||
|
*******************************************************************************/
|
||||||
|
|
||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
|
||||||
|
namespace Marechai.Database.Migrations
|
||||||
|
{
|
||||||
|
public partial class AddOpticalMediaTableOfContents : Migration
|
||||||
|
{
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder) =>
|
||||||
|
migrationBuilder.AddColumn<string>("TableOfContents", "Media", nullable: true);
|
||||||
|
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder) =>
|
||||||
|
migrationBuilder.DropColumn("TableOfContents", "Media");
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -2017,6 +2017,8 @@ namespace Marechai.Database.Migrations
|
|||||||
|
|
||||||
b.Property<int?>("StorageInterface").HasColumnType("int");
|
b.Property<int?>("StorageInterface").HasColumnType("int");
|
||||||
|
|
||||||
|
b.Property<string>("TableOfContents").HasColumnType("json");
|
||||||
|
|
||||||
b.Property<string>("Title").HasColumnType("varchar(255) CHARACTER SET utf8mb4");
|
b.Property<string>("Title").HasColumnType("varchar(255) CHARACTER SET utf8mb4");
|
||||||
|
|
||||||
b.Property<ushort?>("Tracks").HasColumnType("smallint unsigned");
|
b.Property<ushort?>("Tracks").HasColumnType("smallint unsigned");
|
||||||
|
|||||||
@@ -55,6 +55,7 @@ namespace Marechai.Database.Models
|
|||||||
public int? LogicalBlockSize { get; set; }
|
public int? LogicalBlockSize { get; set; }
|
||||||
public JsonObject<VariableBlockSize[]> BlockSizes { get; set; }
|
public JsonObject<VariableBlockSize[]> BlockSizes { get; set; }
|
||||||
public StorageInterface? StorageInterface { get; set; }
|
public StorageInterface? StorageInterface { get; set; }
|
||||||
|
public JsonObject<OpticalDiscTrack[]> TableOfContents { get; set; }
|
||||||
|
|
||||||
public virtual ICollection<LogicalPartitionsByMedia> LogicalPartitions { get; set; }
|
public virtual ICollection<LogicalPartitionsByMedia> LogicalPartitions { get; set; }
|
||||||
public virtual ICollection<MediaDump> MediaDumps { get; set; }
|
public virtual ICollection<MediaDump> MediaDumps { get; set; }
|
||||||
|
|||||||
14
Marechai.Database/Models/OpticalDiscTrack.cs
Normal file
14
Marechai.Database/Models/OpticalDiscTrack.cs
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
using Aaru.CommonTypes.Enums;
|
||||||
|
|
||||||
|
namespace Marechai.Database.Models
|
||||||
|
{
|
||||||
|
// Not for a table
|
||||||
|
public class OpticalDiscTrack
|
||||||
|
{
|
||||||
|
public int TrackNumber { get; set; }
|
||||||
|
public int SessionNumber { get; set; }
|
||||||
|
public long FirstSector { get; set; }
|
||||||
|
public long LastSector { get; set; }
|
||||||
|
public TrackType Type { get; set; }
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<TargetFramework>netcoreapp3.1</TargetFramework>
|
<TargetFramework>netcoreapp3.1</TargetFramework>
|
||||||
<Version>4.0.0.1723</Version>
|
<Version>4.0.0.1724</Version>
|
||||||
<Company>Canary Islands Computer Museum</Company>
|
<Company>Canary Islands Computer Museum</Company>
|
||||||
<Copyright>Copyright © 2003-2020 Natalia Portillo</Copyright>
|
<Copyright>Copyright © 2003-2020 Natalia Portillo</Copyright>
|
||||||
<Product>Canary Islands Computer Museum Website</Product>
|
<Product>Canary Islands Computer Museum Website</Product>
|
||||||
|
|||||||
Reference in New Issue
Block a user