mirror of
https://github.com/ServUO/ServUO
synced 2026-08-11 20:23:04 -04:00
If a class has a field that's not marked readonly but is only set in the constructor, it could cause confusion about the field's intended use. To avoid confusion, such fields should be marked readonly to make their intended use explicit, and to prevent future maintainers from inadvertently changing their use.
19 lines
572 B
C#
19 lines
572 B
C#
namespace Server.Engines.Chat
|
|
{
|
|
public delegate void OnChatAction(ChatUser from, Channel channel, string param);
|
|
|
|
public class ChatActionHandler
|
|
{
|
|
private readonly bool m_RequireConference;
|
|
private readonly OnChatAction m_Callback;
|
|
|
|
public bool RequireConference => m_RequireConference;
|
|
public OnChatAction Callback => m_Callback;
|
|
|
|
public ChatActionHandler(bool requireConference, OnChatAction callback)
|
|
{
|
|
m_RequireConference = requireConference;
|
|
m_Callback = callback;
|
|
}
|
|
}
|
|
}
|