A first flow was saved to disk
This commit is contained in:
parent
9f4d0b3aef
commit
4d48966d24
13 changed files with 363 additions and 241 deletions
34
src/Yavsc/Interfaces/IConnexionManager.cs
Normal file
34
src/Yavsc/Interfaces/IConnexionManager.cs
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
using System;
|
||||
using System.Collections.Generic;
|
||||
using Yavsc.ViewModels.Chat;
|
||||
|
||||
namespace Yavsc.Services
|
||||
{
|
||||
public interface IConnexionManager {
|
||||
void SetUserName(string cxId, string userName);
|
||||
|
||||
string GetUserName (string cxId);
|
||||
void OnConnected(string userName, bool isCop);
|
||||
bool IsConnected(string candidate);
|
||||
bool IsPresent(string roomName, string userName);
|
||||
|
||||
ChatRoomInfo Join(string roomName, string userName);
|
||||
|
||||
bool Part(string cxId, string roomName, string reason);
|
||||
|
||||
bool Kick(string cxId, string userName, string roomName, string reason);
|
||||
|
||||
bool Op(string roomName, string userName);
|
||||
bool Deop(string roomName, string userName);
|
||||
bool Hop(string roomName, string userName);
|
||||
bool Dehop(string roomName, string userName);
|
||||
bool TryGetChanInfo(string room, out ChatRoomInfo chanInfo);
|
||||
|
||||
IEnumerable<string> GetConnexionIds(string userName);
|
||||
void Abort(string connectionId);
|
||||
|
||||
void SetErrorHandler(Action<string,string> errorHandler);
|
||||
IEnumerable<ChannelShortInfo> ListChannels(string pattern);
|
||||
|
||||
}
|
||||
}
|
||||
28
src/Yavsc/Interfaces/ILiveProcessor.cs
Normal file
28
src/Yavsc/Interfaces/ILiveProcessor.cs
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
using System.Collections.Concurrent;
|
||||
using System.Threading.Tasks;
|
||||
using Microsoft.AspNet.Http;
|
||||
using Yavsc.ViewModels.Streaming;
|
||||
|
||||
namespace Yavsc.Services
|
||||
{
|
||||
public interface ILiveProcessor {
|
||||
/// <summary>
|
||||
/// instance keeping reference on
|
||||
/// all collections of casting and listenning websockets
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
ConcurrentDictionary<string, LiveCastHandler> Casters { get; }
|
||||
/// <summary>
|
||||
/// Try and accept websocket from aspnet http context
|
||||
/// </summary>
|
||||
/// <param name="context"></param>
|
||||
/// <returns></returns>
|
||||
Task<bool> AcceptStream (HttpContext context);
|
||||
|
||||
/// <summary>
|
||||
/// live cast entry point
|
||||
/// </summary>
|
||||
/// <value></value>
|
||||
PathString LiveCastingPath {get; set;}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue