// <auto-generated>
// DO NOT EDIT: generated by fsdgencsharp
// </auto-generated>
using System;
using System.Collections.Generic;
using Facility.Core;

namespace OapApi.v1.Client
{
	/// <summary>
	/// Response for GetApplications.
	/// </summary>
	[System.CodeDom.Compiler.GeneratedCode("fsdgencsharp", "")]
	public sealed partial class GetApplicationsResponseDto : ServiceDto<GetApplicationsResponseDto>
	{
		/// <summary>
		/// Creates an instance.
		/// </summary>
		public GetApplicationsResponseDto()
		{
		}

		/// <summary>
		/// The applications.
		/// </summary>
		public IReadOnlyList<ApplicationDto> Applications { get; set; }

		/// <summary>
		/// The total number of applications.
		/// </summary>
		public long? Total { get; set; }

		/// <summary>
		/// The token representing the next page of results.
		/// </summary>
		public string NextToken { get; set; }

		/// <summary>
		/// True if this is the last page of results, false otherwise.
		/// </summary>
		public bool? IsLastPage { get; set; }

		/// <summary>
		/// The JSON serializer.
		/// </summary>
		protected override JsonServiceSerializer JsonSerializer => SystemTextJsonServiceSerializer.Instance;

		/// <summary>
		/// Determines if two DTOs are equivalent.
		/// </summary>
		public override bool IsEquivalentTo(GetApplicationsResponseDto other)
		{
			return other != null &&
				ServiceDataUtility.AreEquivalentFieldValues(Applications, other.Applications) &&
				Total == other.Total &&
				NextToken == other.NextToken &&
				IsLastPage == other.IsLastPage;
		}
	}
}
