C# 9 Cleanup (#325)
- [X] Removes EventArgs - not needed - [X] Merges sequential checks - [X] Removes redundant type declarations
This commit is contained in:
parent
351611a23a
commit
3551d962f7
417 changed files with 2209 additions and 2213 deletions
|
|
@ -5,7 +5,7 @@ namespace Server.Diagnostics
|
|||
{
|
||||
public class GumpProfile : BaseProfile
|
||||
{
|
||||
private static readonly Dictionary<Type, GumpProfile> _profiles = new Dictionary<Type, GumpProfile>();
|
||||
private static readonly Dictionary<Type, GumpProfile> _profiles = new();
|
||||
|
||||
public GumpProfile(Type type) : base(type.FullName)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ namespace Server.Diagnostics
|
|||
|
||||
public class PacketSendProfile : BasePacketProfile
|
||||
{
|
||||
private static readonly Dictionary<Type, PacketSendProfile> _profiles = new Dictionary<Type, PacketSendProfile>();
|
||||
private static readonly Dictionary<Type, PacketSendProfile> _profiles = new();
|
||||
|
||||
private long _created;
|
||||
|
||||
|
|
@ -70,7 +70,7 @@ namespace Server.Diagnostics
|
|||
public class PacketReceiveProfile : BasePacketProfile
|
||||
{
|
||||
private static readonly Dictionary<int, PacketReceiveProfile>
|
||||
_profiles = new Dictionary<int, PacketReceiveProfile>();
|
||||
_profiles = new();
|
||||
|
||||
public PacketReceiveProfile(int packetId)
|
||||
: base($"0x{packetId:X2}")
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ namespace Server.Diagnostics
|
|||
{
|
||||
public class TargetProfile : BaseProfile
|
||||
{
|
||||
private static readonly Dictionary<Type, TargetProfile> _profiles = new Dictionary<Type, TargetProfile>();
|
||||
private static readonly Dictionary<Type, TargetProfile> _profiles = new();
|
||||
|
||||
public TargetProfile(Type type)
|
||||
: base(type.FullName)
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ namespace Server.Diagnostics
|
|||
{
|
||||
public class TimerProfile : BaseProfile
|
||||
{
|
||||
private static readonly Dictionary<string, TimerProfile> _profiles = new Dictionary<string, TimerProfile>();
|
||||
private static readonly Dictionary<string, TimerProfile> _profiles = new();
|
||||
|
||||
public TimerProfile(string name)
|
||||
: base(name)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue