SUBD_Gerimovich_Ilya_PIbd-22/FurnitureAssembly/FurnitureAssemblyListImplement/DataListSingleton.cs

36 lines
864 B
C#
Raw Permalink Normal View History

2024-05-24 12:23:50 +04:00
using FurnitureAssemblyListImplement.Models;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace FurnitureAssemblyListImplement
{
public class DataListSingleton
{
private static DataListSingleton? _instance;
2024-05-24 13:05:47 +04:00
public List<Ad> Orders { get; set; }
public List<Users> Furnitures { get; set; }
2024-05-24 12:23:50 +04:00
2024-05-24 13:05:47 +04:00
public List<Komment> WorkPiece { get; set; }
2024-05-24 12:23:50 +04:00
public DataListSingleton()
{
2024-05-24 13:05:47 +04:00
WorkPiece = new List<Komment>();
Furnitures = new List<Users>();
Orders = new List<Ad>();
2024-05-24 12:23:50 +04:00
}
public static DataListSingleton GetInstance()
{
if(_instance == null)
{
_instance = new DataListSingleton();
}
return _instance;
}
}
}