146 lines
4.0 KiB
C#
146 lines
4.0 KiB
C#
using System.Text.Json.Serialization;
|
|
|
|
namespace xApi.Models
|
|
{
|
|
public class AzureConnectionDataDto
|
|
{
|
|
[JsonPropertyName("instanceId")]
|
|
public string? InstanceId { get; set; }
|
|
|
|
[JsonPropertyName("deploymentId")]
|
|
public string? DeploymentId { get; set; }
|
|
|
|
[JsonPropertyName("deploymentType")]
|
|
public string? DeploymentType { get; set; }
|
|
|
|
[JsonPropertyName("authorizedUser")]
|
|
public AzureUserDetailsDto? AuthorizedUser { get; set; }
|
|
|
|
[JsonPropertyName("authenticatedUser")]
|
|
public AzureUserDetailsDto? AuthenticatedUser { get; set; }
|
|
|
|
[JsonPropertyName("locationServiceData")]
|
|
public AzureLocationServiceDto? LocationServiceData { get; set; }
|
|
}
|
|
|
|
public class AzurePropertyValueDto
|
|
{
|
|
[JsonPropertyName("$type")]
|
|
public string? Type { get; set; }
|
|
|
|
[JsonPropertyName("$value")]
|
|
public string? Value { get; set; }
|
|
}
|
|
|
|
public class AzureUserDetailsDto
|
|
{
|
|
[JsonPropertyName("id")]
|
|
public string? Id { get; set; }
|
|
|
|
[JsonPropertyName("isActive")]
|
|
public bool IsActive { get; set; }
|
|
|
|
[JsonPropertyName("metaTypeId")]
|
|
public int MetaTypeId { get; set; }
|
|
|
|
[JsonPropertyName("descriptor")]
|
|
public string? Descriptor { get; set; }
|
|
|
|
[JsonPropertyName("resourceVersion")]
|
|
public int ResourceVersion { get; set; }
|
|
|
|
[JsonPropertyName("subjectDescriptor")]
|
|
public string? SubjectDescriptor { get; set; }
|
|
|
|
[JsonPropertyName("providerDisplayName")]
|
|
public string? ProviderDisplayName { get; set; }
|
|
|
|
[JsonPropertyName("properties")]
|
|
public Dictionary<string, AzurePropertyValueDto>? Properties { get; set; }
|
|
}
|
|
|
|
public class AzureLocationServiceDto
|
|
{
|
|
[JsonPropertyName("lastChangeId")]
|
|
public int LastChangeId { get; set; }
|
|
|
|
[JsonPropertyName("lastChangeId64")]
|
|
public long LastChangeId64 { get; set; }
|
|
|
|
[JsonPropertyName("clientCacheTimeToLive")]
|
|
public int ClientCacheTimeToLive { get; set; }
|
|
|
|
[JsonPropertyName("defaultAccessMappingMoniker")]
|
|
public string? DefaultAccessMappingMoniker { get; set; }
|
|
}
|
|
|
|
public class AzureProjectDto
|
|
{
|
|
[JsonPropertyName("id")]
|
|
public Guid Id { get; set; }
|
|
|
|
[JsonPropertyName("name")]
|
|
public string? Name { get; set; }
|
|
|
|
[JsonPropertyName("description")]
|
|
public string? Description { get; set; }
|
|
|
|
[JsonPropertyName("url")]
|
|
public string? Url { get; set; }
|
|
|
|
[JsonPropertyName("state")]
|
|
public string? State { get; set; }
|
|
|
|
[JsonPropertyName("revision")]
|
|
public int? Revision { get; set; }
|
|
|
|
[JsonPropertyName("visibility")]
|
|
public string? Visibility { get; set; }
|
|
|
|
[JsonPropertyName("lastUpdateTime")]
|
|
public DateTime LastUpdateTime { get; set; }
|
|
}
|
|
|
|
public class AzureRepositoryDto
|
|
{
|
|
[JsonPropertyName("id")]
|
|
public Guid Id { get; set; }
|
|
|
|
[JsonPropertyName("size")]
|
|
public long Size { get; set; }
|
|
|
|
[JsonPropertyName("name")]
|
|
public string? Name { get; set; }
|
|
|
|
[JsonPropertyName("url")]
|
|
public string? Url { get; set; }
|
|
|
|
[JsonPropertyName("webUrl")]
|
|
public string? WebUrl { get; set; }
|
|
|
|
[JsonPropertyName("sshUrl")]
|
|
public string? SshUrl { get; set; }
|
|
|
|
[JsonPropertyName("isDisabled")]
|
|
public bool IsDisabled { get; set; }
|
|
|
|
[JsonPropertyName("remoteUrl")]
|
|
public string? RemoteUrl { get; set; }
|
|
|
|
[JsonPropertyName("defaultBranch")]
|
|
public string? DefaultBranch { get; set; }
|
|
|
|
[JsonPropertyName("project")]
|
|
public AzureProjectDto? Project { get; set; }
|
|
}
|
|
|
|
public class AzureListDto<T>
|
|
where T : class
|
|
{
|
|
[JsonPropertyName("count")]
|
|
public int Count { get; set; }
|
|
|
|
[JsonPropertyName("value")]
|
|
public List<T> Value { get; set; } = [];
|
|
}
|
|
} |