Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update DeviceInfo model #146

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 18 additions & 1 deletion src/Regula.DocumentReader.WebClient/Model/DocumentImage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ protected DocumentImage() { }
/// Initializes a new instance of the <see cref="DocumentImage" /> class.
/// </summary>
/// <param name="image">Base64 encoded image (required).</param>
public DocumentImage(string image = default(string))
/// <param name="format">Image format.</param>
public DocumentImage(string image = default(string), string format = default(string))
{
// to ensure "image" is required (not null)
if (image == null)
Expand All @@ -51,6 +52,7 @@ protected DocumentImage() { }
this.Image = image;
}

this.Format = format;
}

/// <summary>
Expand All @@ -60,6 +62,13 @@ protected DocumentImage() { }
[DataMember(Name="image", EmitDefaultValue=true)]
public string Image { get; set; }

/// <summary>
/// Image format
/// </summary>
/// <value>Image format</value>
[DataMember(Name="format", EmitDefaultValue=false)]
public string Format { get; set; }

/// <summary>
/// Returns the string presentation of the object
/// </summary>
Expand All @@ -69,6 +78,7 @@ public override string ToString()
var sb = new StringBuilder();
sb.Append("class DocumentImage {\n");
sb.Append(" Image: ").Append(Image).Append("\n");
sb.Append(" Format: ").Append(Format).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
Expand Down Expand Up @@ -107,6 +117,11 @@ public bool Equals(DocumentImage input)
this.Image == input.Image ||
(this.Image != null &&
this.Image.Equals(input.Image))
) &&
(
this.Format == input.Format ||
(this.Format != null &&
this.Format.Equals(input.Format))
);
}

Expand All @@ -121,6 +136,8 @@ public override int GetHashCode()
int hashCode = 41;
if (this.Image != null)
hashCode = hashCode * 59 + this.Image.GetHashCode();
if (this.Format != null)
hashCode = hashCode * 59 + this.Format.GetHashCode();
return hashCode;
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
namespace Regula.DocumentReader.WebClient.Model
{
/// <summary>
/// DocumentImageResult
/// Contains document image.
/// </summary>
[DataContract]
public partial class DocumentImageResult : ResultItem, IEquatable<DocumentImageResult>, IValidatableObject
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public partial class GetTransactionsByTagResponse : IEquatable<GetTransactionsB
/// <param name="id">Transaction id.</param>
/// <param name="state">Transaction status.</param>
/// <param name="updatedAt">Last time updated.</param>
public GetTransactionsByTagResponse(int id = default(int), int state = default(int), DateTime updatedAt = default(DateTime))
public GetTransactionsByTagResponse(Guid id = default(Guid), int state = default(int), DateTime updatedAt = default(DateTime))
{
this.Id = id;
this.State = state;
Expand All @@ -48,7 +48,7 @@ public partial class GetTransactionsByTagResponse : IEquatable<GetTransactionsB
/// </summary>
/// <value>Transaction id</value>
[DataMember(Name="id", EmitDefaultValue=false)]
public int Id { get; set; }
public Guid Id { get; set; }

/// <summary>
/// Transaction status
Expand Down
Loading
Loading