Files
tgstation-server/TGServiceInterface/Components/Chat.cs
T
Cyberboss 3137be7abb Massive sanity reorganization of project structure
Overall:
- Removed all 'TG' prefixes on classes and enums
Service:
- TGStationServer => ServerInstance
- TGServerService => Service
- Moved all ServerInstance partial classes to a subfolder
- Moved ChatProvider classes, delegate, and interface to a namespace
- Moved EventID and ChatMessageType to their own .cs files
- Moved SanitizeTopicString to Program
- ServerService.cs => Service.cs
- Fixed ProjectInstaller being in it's own namespace instead of
TGServerService
Interface:
- Moved ExitCode enum to Command class
- Moved all components to a namespace
- Moved all component enums to Enumerations.cs
- DDInteropCallHolder => DreamDaemonBridge
- Move PullRequestInfo and DreamDaemonBridge to their own .cs files
- Changes the type of ChannelFactory cache from Dictionary<Type,
ChannelFactory> to IDictionary<Type, ChannelFactory>
2017-10-20 14:00:09 -04:00

42 lines
1.3 KiB
C#

using System.Collections.Generic;
using System.ServiceModel;
namespace TGServiceInterface.Components
{
/// <summary>
/// Interface for handling chat bot
/// </summary>
[ServiceContract]
public interface ITGChat
{
/// <summary>
/// Sets a chat provider <paramref name="info"/>
/// </summary>
/// <param name="info">The info to set</param>
[OperationContract]
string SetProviderInfo(ChatSetupInfo info);
/// <summary>
/// Returns <see cref="ChatSetupInfo"/> for all <see cref="ChatProvider"/>s
/// </summary>
/// <returns>A list of all <see cref="ChatSetupInfo"/>s</returns>
[OperationContract]
IList<ChatSetupInfo> ProviderInfos();
/// <summary>
/// Checks connection status
/// </summary>
/// <param name="providerType">The type of provider to check if connected</param>
/// <returns><see langword="true"/> if connected, <see langword="false"/> otherwise</returns>
[OperationContract]
bool Connected(ChatProvider providerType);
/// <summary>
/// Reconnect a specific <paramref name="providerType"/> to it's chat service
/// </summary>
/// <param name="providerType">The type of provider to reconnect</param>
/// <returns><see langword="null"/> on success, error message <see cref="string"/> on failure</returns>
[OperationContract]
string Reconnect(ChatProvider providerType);
}
}