internal void UseTemplate(IMessagesTemplate template) { if (!_messagesTemplates.Any(x => x.GetType().Equals(template.GetType()))) { _messagesTemplates.Add(template); } }
private Mid ProcessPackage(IMessagesTemplate template, object package) { if (package.GetType().Equals(typeof(byte[]))) { return(template.ProcessPackage(package as byte[])); } return(template.ProcessPackage(package as string)); }