mirror of
https://github.com/tribufu/tribufu-dotnet
synced 2026-02-04 18:59:06 +00:00
Generate client with open-api-generator (#1)
* Generate project with open-api-generator * Add example project * Create wrapper class
This commit is contained in:
299
src/Tribufu.Generated/Model/UserInfo.cs
Normal file
299
src/Tribufu.Generated/Model/UserInfo.cs
Normal file
@@ -0,0 +1,299 @@
|
||||
/*
|
||||
* Tribufu API
|
||||
*
|
||||
* REST API to access Tribufu services.
|
||||
*
|
||||
* The version of the OpenAPI document: 1.1.0
|
||||
* Contact: contact@tribufu.com
|
||||
* Generated by: https://github.com/openapitools/openapi-generator.git
|
||||
*/
|
||||
|
||||
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.ObjectModel;
|
||||
using System.Linq;
|
||||
using System.IO;
|
||||
using System.Runtime.Serialization;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Converters;
|
||||
using Newtonsoft.Json.Linq;
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
using OpenAPIDateConverter = Tribufu.Generated.Client.OpenAPIDateConverter;
|
||||
|
||||
namespace Tribufu.Generated.Model
|
||||
{
|
||||
/// <summary>
|
||||
/// UserInfo
|
||||
/// </summary>
|
||||
[DataContract(Name = "UserInfo")]
|
||||
public partial class UserInfo : IValidatableObject
|
||||
{
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Type
|
||||
/// </summary>
|
||||
[DataMember(Name = "type", EmitDefaultValue = false)]
|
||||
public UserType? Type { get; set; }
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the <see cref="UserInfo" /> class.
|
||||
/// </summary>
|
||||
/// <param name="id">id.</param>
|
||||
/// <param name="uuid">uuid.</param>
|
||||
/// <param name="name">name.</param>
|
||||
/// <param name="displayName">displayName.</param>
|
||||
/// <param name="email">email.</param>
|
||||
/// <param name="type">type.</param>
|
||||
/// <param name="flags">flags.</param>
|
||||
/// <param name="permissions">permissions.</param>
|
||||
/// <param name="verified">verified.</param>
|
||||
/// <param name="level">level.</param>
|
||||
/// <param name="experience">experience.</param>
|
||||
/// <param name="publicBirthday">publicBirthday.</param>
|
||||
/// <param name="birthday">birthday.</param>
|
||||
/// <param name="points">points.</param>
|
||||
/// <param name="location">location.</param>
|
||||
/// <param name="language">language.</param>
|
||||
/// <param name="timezone">timezone.</param>
|
||||
/// <param name="currency">currency.</param>
|
||||
/// <param name="photoUrl">photoUrl.</param>
|
||||
/// <param name="bannerUrl">bannerUrl.</param>
|
||||
/// <param name="lastOnline">lastOnline.</param>
|
||||
/// <param name="biography">biography.</param>
|
||||
/// <param name="viewCount">viewCount.</param>
|
||||
/// <param name="created">created.</param>
|
||||
/// <param name="updated">updated.</param>
|
||||
public UserInfo(string id = default(string), Guid uuid = default(Guid), string name = default(string), string displayName = default(string), string email = default(string), UserType? type = default(UserType?), string flags = default(string), string permissions = default(string), bool verified = default(bool), int level = default(int), double experience = default(double), bool publicBirthday = default(bool), DateOnly? birthday = default(DateOnly?), double points = default(double), string location = default(string), string language = default(string), string timezone = default(string), string currency = default(string), string photoUrl = default(string), string bannerUrl = default(string), DateTime? lastOnline = default(DateTime?), string biography = default(string), int viewCount = default(int), DateTime created = default(DateTime), DateTime? updated = default(DateTime?))
|
||||
{
|
||||
this.Id = id;
|
||||
this.Uuid = uuid;
|
||||
this.Name = name;
|
||||
this.DisplayName = displayName;
|
||||
this.Email = email;
|
||||
this.Type = type;
|
||||
this.Flags = flags;
|
||||
this.Permissions = permissions;
|
||||
this.Verified = verified;
|
||||
this.Level = level;
|
||||
this.Experience = experience;
|
||||
this.PublicBirthday = publicBirthday;
|
||||
this.Birthday = birthday;
|
||||
this.Points = points;
|
||||
this.Location = location;
|
||||
this.Language = language;
|
||||
this.Timezone = timezone;
|
||||
this.Currency = currency;
|
||||
this.PhotoUrl = photoUrl;
|
||||
this.BannerUrl = bannerUrl;
|
||||
this.LastOnline = lastOnline;
|
||||
this.Biography = biography;
|
||||
this.ViewCount = viewCount;
|
||||
this.Created = created;
|
||||
this.Updated = updated;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Id
|
||||
/// </summary>
|
||||
[DataMember(Name = "id", EmitDefaultValue = false)]
|
||||
public string Id { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Uuid
|
||||
/// </summary>
|
||||
[DataMember(Name = "uuid", EmitDefaultValue = false)]
|
||||
public Guid Uuid { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Name
|
||||
/// </summary>
|
||||
[DataMember(Name = "name", EmitDefaultValue = true)]
|
||||
public string Name { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets DisplayName
|
||||
/// </summary>
|
||||
[DataMember(Name = "display_name", EmitDefaultValue = true)]
|
||||
public string DisplayName { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Email
|
||||
/// </summary>
|
||||
[DataMember(Name = "email", EmitDefaultValue = true)]
|
||||
public string Email { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Flags
|
||||
/// </summary>
|
||||
[DataMember(Name = "flags", EmitDefaultValue = false)]
|
||||
public string Flags { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Permissions
|
||||
/// </summary>
|
||||
[DataMember(Name = "permissions", EmitDefaultValue = false)]
|
||||
public string Permissions { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Verified
|
||||
/// </summary>
|
||||
[DataMember(Name = "verified", EmitDefaultValue = true)]
|
||||
public bool Verified { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Level
|
||||
/// </summary>
|
||||
[DataMember(Name = "level", EmitDefaultValue = false)]
|
||||
public int Level { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Experience
|
||||
/// </summary>
|
||||
[DataMember(Name = "experience", EmitDefaultValue = false)]
|
||||
public double Experience { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets PublicBirthday
|
||||
/// </summary>
|
||||
[DataMember(Name = "public_birthday", EmitDefaultValue = true)]
|
||||
public bool PublicBirthday { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Birthday
|
||||
/// </summary>
|
||||
[DataMember(Name = "birthday", EmitDefaultValue = true)]
|
||||
public DateOnly? Birthday { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Points
|
||||
/// </summary>
|
||||
[DataMember(Name = "points", EmitDefaultValue = false)]
|
||||
public double Points { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Location
|
||||
/// </summary>
|
||||
[DataMember(Name = "location", EmitDefaultValue = true)]
|
||||
public string Location { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Language
|
||||
/// </summary>
|
||||
[DataMember(Name = "language", EmitDefaultValue = true)]
|
||||
public string Language { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Timezone
|
||||
/// </summary>
|
||||
[DataMember(Name = "timezone", EmitDefaultValue = true)]
|
||||
public string Timezone { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Currency
|
||||
/// </summary>
|
||||
[DataMember(Name = "currency", EmitDefaultValue = true)]
|
||||
public string Currency { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets PhotoUrl
|
||||
/// </summary>
|
||||
[DataMember(Name = "photo_url", EmitDefaultValue = true)]
|
||||
public string PhotoUrl { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets BannerUrl
|
||||
/// </summary>
|
||||
[DataMember(Name = "banner_url", EmitDefaultValue = true)]
|
||||
public string BannerUrl { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets LastOnline
|
||||
/// </summary>
|
||||
[DataMember(Name = "last_online", EmitDefaultValue = true)]
|
||||
public DateTime? LastOnline { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Biography
|
||||
/// </summary>
|
||||
[DataMember(Name = "biography", EmitDefaultValue = true)]
|
||||
public string Biography { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets ViewCount
|
||||
/// </summary>
|
||||
[DataMember(Name = "view_count", EmitDefaultValue = false)]
|
||||
public int ViewCount { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Created
|
||||
/// </summary>
|
||||
[DataMember(Name = "created", EmitDefaultValue = false)]
|
||||
public DateTime Created { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Gets or Sets Updated
|
||||
/// </summary>
|
||||
[DataMember(Name = "updated", EmitDefaultValue = true)]
|
||||
public DateTime? Updated { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// Returns the string presentation of the object
|
||||
/// </summary>
|
||||
/// <returns>String presentation of the object</returns>
|
||||
public override string ToString()
|
||||
{
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.Append("class UserInfo {\n");
|
||||
sb.Append(" Id: ").Append(Id).Append("\n");
|
||||
sb.Append(" Uuid: ").Append(Uuid).Append("\n");
|
||||
sb.Append(" Name: ").Append(Name).Append("\n");
|
||||
sb.Append(" DisplayName: ").Append(DisplayName).Append("\n");
|
||||
sb.Append(" Email: ").Append(Email).Append("\n");
|
||||
sb.Append(" Type: ").Append(Type).Append("\n");
|
||||
sb.Append(" Flags: ").Append(Flags).Append("\n");
|
||||
sb.Append(" Permissions: ").Append(Permissions).Append("\n");
|
||||
sb.Append(" Verified: ").Append(Verified).Append("\n");
|
||||
sb.Append(" Level: ").Append(Level).Append("\n");
|
||||
sb.Append(" Experience: ").Append(Experience).Append("\n");
|
||||
sb.Append(" PublicBirthday: ").Append(PublicBirthday).Append("\n");
|
||||
sb.Append(" Birthday: ").Append(Birthday).Append("\n");
|
||||
sb.Append(" Points: ").Append(Points).Append("\n");
|
||||
sb.Append(" Location: ").Append(Location).Append("\n");
|
||||
sb.Append(" Language: ").Append(Language).Append("\n");
|
||||
sb.Append(" Timezone: ").Append(Timezone).Append("\n");
|
||||
sb.Append(" Currency: ").Append(Currency).Append("\n");
|
||||
sb.Append(" PhotoUrl: ").Append(PhotoUrl).Append("\n");
|
||||
sb.Append(" BannerUrl: ").Append(BannerUrl).Append("\n");
|
||||
sb.Append(" LastOnline: ").Append(LastOnline).Append("\n");
|
||||
sb.Append(" Biography: ").Append(Biography).Append("\n");
|
||||
sb.Append(" ViewCount: ").Append(ViewCount).Append("\n");
|
||||
sb.Append(" Created: ").Append(Created).Append("\n");
|
||||
sb.Append(" Updated: ").Append(Updated).Append("\n");
|
||||
sb.Append("}\n");
|
||||
return sb.ToString();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the JSON string presentation of the object
|
||||
/// </summary>
|
||||
/// <returns>JSON string presentation of the object</returns>
|
||||
public virtual string ToJson()
|
||||
{
|
||||
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// To validate all properties of the instance
|
||||
/// </summary>
|
||||
/// <param name="validationContext">Validation context</param>
|
||||
/// <returns>Validation Result</returns>
|
||||
IEnumerable<ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
|
||||
{
|
||||
yield break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user