/// <summary> /// Creates a new NGRIDController object. /// </summary> /// <param name="name">Name of the controller</param> public NGRIDController(string name) : base(name, CommunicationLayer.CreateApplicationId()) { _settings = NGRIDSettings.Instance; //_designSettings = NGRIDDesignSettings.Instance; MessageReceived += NGRIDController_MessageReceived; }
/// <summary> /// Constructor. /// </summary> /// <param name="name">Name of the remote application</param> protected MDSPersistentRemoteApplicationBase(string name) : base(name, CommunicationLayer.CreateApplicationId()) { _waitingMessages = new LinkedList <WaitingMessage>(); _biggestWaitingMessageId = 0; _biggestWaitingMessageIdInList = 0; }
/// <summary> /// Creates a new MDSController object. /// </summary> /// <param name="name">Name of the controller</param> public MDSController(string name) : base(name, CommunicationLayer.CreateApplicationId()) { _settings = MDSSettings.Instance; _designSettings = MDSDesignSettings.Instance; MessageReceived += MDSController_MessageReceived; }
public void Flush() { for (int i = 0; i < 10; i++) { SendAction(Actions.ClearBuffer); } CommunicationLayer.Transmit(); }
public void Draw() { SendAction(Actions.Render); Console.WriteLine($"{1000 / Math.Max(lastDraw.ElapsedMilliseconds, 1)} FPS"); CommunicationLayer.Transmit(); lastDraw.Restart(); //Thread.Sleep(3); }
/// <summary> /// Constructor. /// </summary> /// <param name="communicationLayer">Reference to the Communication Layer</param> /// <param name="storageManager">Reference to the Storage Manager</param> /// <param name="routingTable">Reference to the routing table</param> /// <param name="serverGraph">Reference to server graph</param> /// <param name="clientApplicationList">Reference to application list</param> /// <param name="ngridManager">Reference to NGRID Manager object</param> public OrganizationLayer(CommunicationLayer communicationLayer, IStorageManager storageManager, RoutingTable routingTable, NGRIDServerGraph serverGraph, NGRIDClientApplicationList clientApplicationList, NGRIDController ngridManager) { _settings = NGRIDSettings.Instance; _communicationLayer = communicationLayer; _storageManager = storageManager; _routingTable = routingTable; _serverGraph = serverGraph; _clientApplicationList = clientApplicationList; _ngridManager = ngridManager; _waitingMessages = new SortedList <string, WaitingMessage>(); PrepareCommunicationLayer(); }
public ApplicationService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/apps"; }
public DynabicMarketingPlansService(CommunicationLayer service) { _service = service; // TODO: this REST service is not implemented yet. _gatewayURL = service.Environment.GatewayURL + ""; }
public SiteService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/sites"; }
public void PrintIncoming() { CommunicationLayer.PrintIncoming(); }
public CompanyInfoService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/companyinfo"; }
private void SetPixel(byte position, byte r, byte g, byte b) { byte[] buffer = { position, r, g, b }; CommunicationLayer.Queue(buffer); }
private void SendAction(Actions action) { CommunicationLayer.Queue((byte)action); }
public void Dispose() { CommunicationLayer?.Dispose(); }
protected internal ProductsService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/products"; }
public UserService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/users"; }
protected internal TransactionService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/transactions"; }
protected internal CustomerService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/customers"; }
protected internal SubscriptionService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/subscriptions"; }
public SettingService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/settings"; }
public EventService(CommunicationLayer service) { _service = service; _gatewayURL = service.Environment.GatewayURL + "/events"; }