Inject controllers and services

This commit is contained in:
CWX
2025-01-11 18:14:39 +00:00
parent 8f22759ec5
commit 0ca4ec0887
70 changed files with 209 additions and 58 deletions
+3 -1
View File
@@ -1,4 +1,5 @@
using Core.Context;
using Core.Annotations;
using Core.Context;
using Core.Generators;
using Core.Helpers;
using Core.Models.Common;
@@ -18,6 +19,7 @@ using ILogger = Core.Models.Utils.ILogger;
namespace Core.Controllers;
[Injectable]
public class BotController
{
protected ILogger _logger;
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Annotations;
using Core.Models.Eft.Builds;
using Core.Models.Eft.PresetBuild;
using Core.Models.Eft.Profile;
namespace Core.Controllers;
[Injectable]
public class BuildController
{
/// <summary>
@@ -65,4 +67,4 @@ public class BuildController
{
throw new NotImplementedException();
}
}
}
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Annotations;
using Core.Models.Spt.Logging;
namespace Core.Controllers;
[Injectable]
public class ClientLogController
{
/// <summary>
@@ -12,4 +14,4 @@ public class ClientLogController
{
throw new NotImplementedException();
}
}
}
+3 -1
View File
@@ -1,3 +1,4 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Customization;
@@ -7,6 +8,7 @@ using Core.Models.Eft.Profile;
namespace Core.Controllers;
[Injectable]
public class CustomizationController
{
/// <summary>
@@ -140,4 +142,4 @@ public class CustomizationController
{
throw new NotImplementedException();
}
}
}
+2
View File
@@ -1,3 +1,4 @@
using Core.Annotations;
using Core.Models.Eft.Dialog;
using Core.Models.Eft.HttpResponse;
using Core.Models.Eft.Profile;
@@ -5,6 +6,7 @@ using Core.Models.Enums;
namespace Core.Controllers;
[Injectable]
public class DialogueController
{
/// <summary>
+2
View File
@@ -1,9 +1,11 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Game;
using Core.Models.Eft.Profile;
namespace Core.Controllers;
[Injectable]
public class GameController
{
/// <summary>
+4 -1
View File
@@ -1,10 +1,13 @@
using Core.Annotations;
namespace Core.Controllers;
// TODO: This seems unused, is it even needed?
[Injectable]
public class HandBookController
{
public void Load()
{
throw new NotImplementedException();
}
}
}
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Health;
using Core.Models.Eft.ItemEvent;
namespace Core.Controllers;
[Injectable]
public class HealthController
{
/// <summary>
@@ -66,4 +68,4 @@ public class HealthController
{
throw new NotImplementedException();
}
}
}
+4 -1
View File
@@ -1,6 +1,9 @@
using Core.Annotations;
namespace Core.Controllers;
[Injectable]
public class HideoutController
{
// TODO
}
}
+2
View File
@@ -1,3 +1,4 @@
using Core.Annotations;
using Core.Context;
using Core.Helpers;
using Core.Models.Eft.InRaid;
@@ -9,6 +10,7 @@ using ILogger = Core.Models.Utils.ILogger;
namespace Core.Controllers;
[Injectable]
public class InRaidController
{
protected ILogger _logger;
+4 -1
View File
@@ -1,6 +1,9 @@
using Core.Annotations;
namespace Core.Controllers;
[Injectable]
public class InsuranceController
{
// TODO
}
}
+4 -1
View File
@@ -1,6 +1,9 @@
using Core.Annotations;
namespace Core.Controllers;
[Injectable]
public class InventoryController
{
// TODO
}
}
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Location;
namespace Core.Controllers;
[Injectable]
public class LocationController
{
/// <summary>
@@ -25,4 +27,4 @@ public class LocationController
{
throw new NotImplementedException();
}
}
}
+2
View File
@@ -1,7 +1,9 @@
using Core.Annotations;
using Core.Models.Eft.Match;
namespace Core.Controllers;
[Injectable]
public class MatchController
{
/// <summary>
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.ItemEvent;
using Core.Models.Eft.Notes;
namespace Core.Controllers;
[Injectable]
public class NoteController
{
/// <summary>
@@ -50,4 +52,4 @@ public class NoteController
{
throw new NotImplementedException();
}
}
}
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Annotations;
using Core.Models.Eft.Notifier;
namespace Core.Controllers;
[Injectable]
public class NotifierController
{
/// <summary>
@@ -36,4 +38,4 @@ public class NotifierController
{
throw new NotImplementedException();
}
}
}
+4 -1
View File
@@ -1,5 +1,8 @@
using Core.Annotations;
namespace Core.Controllers;
[Injectable]
public class PresetController
{
/// <summary>
@@ -9,4 +12,4 @@ public class PresetController
{
throw new NotImplementedException();
}
}
}
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
namespace Core.Controllers;
[Injectable]
public class PrestigeController
{
/// <summary>
@@ -30,4 +32,4 @@ public class PrestigeController
{
throw new NotImplementedException("Method not Implemented");
}
}
}
+2
View File
@@ -1,3 +1,4 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.ItemEvent;
@@ -5,6 +6,7 @@ using Core.Models.Eft.Quests;
namespace Core.Controllers;
[Injectable]
public class QuestController
{
// TODO
+2
View File
@@ -1,9 +1,11 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.ItemEvent;
using Core.Models.Eft.Ragfair;
namespace Core.Controllers;
[Injectable]
public class RagfairController
{
// TODO
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.ItemEvent;
using Core.Models.Eft.Repair;
namespace Core.Controllers;
[Injectable]
public class RepairController
{
/// <summary>
@@ -38,4 +40,4 @@ public class RepairController
{
throw new NotImplementedException();
}
}
}
@@ -1,3 +1,4 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.ItemEvent;
@@ -5,6 +6,7 @@ using Core.Models.Eft.Quests;
namespace Core.Controllers;
[Injectable]
public class RepeatableQuestController
{
// TODO
+3 -1
View File
@@ -1,3 +1,4 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.ItemEvent;
@@ -7,6 +8,7 @@ using Core.Models.Enums;
namespace Core.Controllers;
[Injectable]
public class TradeController
{
/// <summary>
@@ -146,4 +148,4 @@ public class TradeController
{
throw new NotImplementedException();
}
}
}
+2
View File
@@ -1,8 +1,10 @@
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Game;
namespace Core.Controllers;
[Injectable]
public class TraderController
{
/// <summary>
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Annotations;
using Core.Models.Eft.Weather;
using Core.Models.Spt.Weather;
namespace Core.Controllers;
[Injectable]
public class WeatherController
{
/// <summary>
@@ -23,4 +25,4 @@ public class WeatherController
{
throw new NotImplementedException();
}
}
}
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.ItemEvent;
using Core.Models.Eft.Wishlist;
namespace Core.Controllers;
[Injectable]
public class WishlistController
{
/// <summary>
@@ -50,4 +52,4 @@ public class WishlistController
{
throw new NotImplementedException();
}
}
}
+3 -1
View File
@@ -1,10 +1,12 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Location;
using Core.Models.Enums;
using Core.Models.Spt.Services;
namespace Core.Services;
[Injectable]
public class AirdropService
{
public GetAirdropLootResponse GenerateCustomAirdropLoot(GetAirdropLootRequest request)
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable]
public class BackupService
{
/**
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Spt.Bots;
using Core.Models.Spt.Config;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class BotEquipmentFilterService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class BotEquipmentModPoolService
{
/**
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class BotGenerationCacheService
{
/**
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Spt.Bots;
using Props = Core.Models.Eft.Common.Props;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class BotLootCacheService
{
/// <summary>
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Spt.Bots;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class BotNameService
{
/// <summary>
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Spt.Bots;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class BotWeaponModLimitService
{
/// <summary>
+3 -1
View File
@@ -1,4 +1,5 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Hideout;
using Core.Models.Eft.ItemEvent;
@@ -8,6 +9,7 @@ using Hideout = Core.Models.Eft.Common.Tables.Hideout;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class CircleOfCultistService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class CustomLocationWaveService
{
/// <summary>
+3 -1
View File
@@ -1,10 +1,12 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Spt.Config;
using Core.Models.Spt.Fence;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class FenceService
{
/// <summary>
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Models.Enums;
using Core.Annotations;
using Core.Models.Enums;
using Core.Models.Spt.Config;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class GiftService
{
/**
+2
View File
@@ -1,8 +1,10 @@
using System.Text.Json;
using Core.Annotations;
using Core.Utils;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class I18nService
{
private List<string> _locales;
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class InMemoryCacheService
{
// Store data into an in-memory object
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Spt.Services;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class InsuranceService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class ItemBaseClassService
{
/**
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class ItemFilterService
{
/**
@@ -1,9 +1,11 @@
using System.Text.Json.Serialization;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Match;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class LegacyLocationLifecycleService
{
/// <summary>
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Match;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class LocationLifecycleService
{
/** Handle client/match/local/start */
+3 -1
View File
@@ -1,4 +1,5 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Inventory;
using Core.Models.Eft.Profile;
@@ -7,6 +8,7 @@ using Core.Models.Spt.Dialog;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class MapMarkerService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class MatchBotDeatilsCacheService
{
/// <summary>
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class MatchLocationService
{
public void DeleteGroup(object info)
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class ModCompilerService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Ws;
using Core.Annotations;
using Core.Models.Eft.Ws;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class NotificationService
{
public Dictionary<string, List<object>> GetMessageQueue()
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class OpenZoneService
{
/// <summary>
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.ItemEvent;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class PaymentService
{
/**
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class PlayerService
{
public int CalculateLevel(PmcData pmcData)
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Profile;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class PmcChatResponseService
{
/**
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class PostDbLoadService
{
public void PerformPostDbLoadActions()
+4 -1
View File
@@ -1,5 +1,8 @@
namespace Core.Services;
using Core.Annotations;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class ProfileActivityService
{
/**
+3 -1
View File
@@ -1,4 +1,5 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Hideout;
using Core.Models.Eft.Profile;
@@ -6,6 +7,7 @@ using Core.Models.Enums;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class ProfileFixerService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Ragfair;
using Core.Annotations;
using Core.Models.Eft.Ragfair;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RagfairCategoriesService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RagfairLinkedItemService
{
public HashSet<string> GetLinkedItems(string linkedSearchId)
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.Ragfair;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RagfairOfferService
{
/// <summary>
+3 -1
View File
@@ -1,9 +1,11 @@
using Core.Models.Common;
using Core.Annotations;
using Core.Models.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Spt.Config;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RagfairPriceService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Ragfair;
using Core.Annotations;
using Core.Models.Eft.Ragfair;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RagfairRequiredItemsService
{
public List<RagfairOffer> GetRequiredItemsById(string searchId)
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Ragfair;
using Core.Annotations;
using Core.Models.Eft.Ragfair;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RagfairTaxService
{
public void StoreClientOfferTaxValue(string sessionId, StorePlayerOfferTaxAmountRequestData offer)
+3 -1
View File
@@ -1,10 +1,12 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Game;
using Core.Models.Spt.Config;
using Core.Models.Spt.Location;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RaidTimeAdjustmentService
{
/// <summary>
+3 -1
View File
@@ -1,8 +1,10 @@
using Core.Models.Eft.Weather;
using Core.Annotations;
using Core.Models.Eft.Weather;
using Core.Models.Enums;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RaidWeatherService
{
/// <summary>
+2
View File
@@ -1,4 +1,5 @@
using System.Text.Json.Serialization;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Eft.ItemEvent;
@@ -7,6 +8,7 @@ using Core.Models.Enums;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class RepairService
{
/// <summary>
+3 -1
View File
@@ -1,10 +1,12 @@
using Core.Models.Eft.Common;
using Core.Annotations;
using Core.Models.Eft.Common;
using Core.Models.Eft.Common.Tables;
using Core.Models.Enums;
using Core.Models.Spt.Config;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class SeasonalEventService
{
/// <summary>
+3 -1
View File
@@ -1,7 +1,9 @@
using Core.Models.Eft.Common.Tables;
using Core.Annotations;
using Core.Models.Eft.Common.Tables;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class TraderAssortService
{
public TraderAssort GetPristineTraderAssort(string traderId)
@@ -1,7 +1,9 @@
using Core.Models.Eft.Profile;
using Core.Annotations;
using Core.Models.Eft.Profile;
namespace Core.Services;
[Injectable(InjectionType.Singleton)]
public class TraderPurchasePersisterService
{
/**