2024-10-16 20:15:49 +00:00
|
|
|
using System;
|
|
|
|
using System.Collections.Generic;
|
|
|
|
using System.Linq;
|
|
|
|
using System.Text;
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
namespace Demo.domain.Models
|
|
|
|
{
|
|
|
|
public class User
|
|
|
|
{
|
|
|
|
public required string FIO { get; set; }
|
|
|
|
public Guid Guid { get; set; }
|
|
|
|
|
|
|
|
public required Group Group { get; set; }
|
2024-10-17 12:35:14 +00:00
|
|
|
|
|
|
|
|
|
|
|
public static User Parse(string input){
|
|
|
|
string[] words = input.Split(" ");
|
|
|
|
return new User{FIO = words[0], Guid = Guid.Parse(words[1]), Group = new Group{Id = Convert.ToInt32(words[2]), Name = words[3]}};
|
|
|
|
}
|
2024-10-16 20:15:49 +00:00
|
|
|
}
|
|
|
|
}
|