42 lines
1.1 KiB
C#
42 lines
1.1 KiB
C#
using System.ComponentModel.DataAnnotations;
|
|
using Newtonsoft.Json;
|
|
using Microsoft.EntityFrameworkCore.Metadata.Internal;
|
|
using System.ComponentModel.DataAnnotations.Schema;
|
|
using isnd.Data.Packages;
|
|
|
|
namespace isnd.Data
|
|
{
|
|
public class Dependency
|
|
{
|
|
[JsonIgnore]
|
|
[Key][DatabaseGenerated(DatabaseGeneratedOption.Identity)]
|
|
public string Id { get;set;}
|
|
|
|
/// <summary>
|
|
/// Dependency Package Identifier
|
|
/// </summary>
|
|
/// <value></value>
|
|
[JsonProperty("id")]
|
|
public string PackageId { get;set;}
|
|
|
|
/// <summary>
|
|
/// Dependency Group Id
|
|
/// </summary>
|
|
/// <value></value>
|
|
[Required]
|
|
[ForeignKey("Group")]
|
|
[JsonIgnore]
|
|
public string DependencyGroupId { set ; get ; }
|
|
|
|
[JsonIgnore]
|
|
public virtual PackageDependencyGroup Group{ get; set; }
|
|
|
|
// TODO Version Range
|
|
[JsonProperty("range")][StringLength(1024)]
|
|
public string Version { get; set; }
|
|
|
|
[JsonProperty("exclude")][StringLength(2048)]
|
|
public string Exclude { get; set; }
|
|
|
|
}
|
|
} |