Added RPC ChannelCreated, GuildCreated and GuildStatusUpdated events

This commit is contained in:
RogueException
2016-10-07 23:18:45 -03:00
parent c610710387
commit 15e8ef06dc
9 changed files with 202 additions and 51 deletions

View File

@@ -0,0 +1,27 @@
using Model = Discord.API.Rpc.ChannelCreatedEvent;
namespace Discord.Rpc
{
public class RpcChannel
{
public ulong Id { get; }
public string Name { get; set; }
public ChannelType Type { get; set; }
internal RpcChannel(ulong id)
{
Id = id;
}
internal static RpcChannel Create(Model model)
{
var entity = new RpcChannel(model.Id);
entity.Update(model);
return entity;
}
internal void Update(Model model)
{
Name = model.Name;
Type = model.Type;
}
}
}