Esempio n. 1
0
        public ChabuImpl(ChabuFactory factory, ChabuSetupInfo localSetupInfo, int priorityCount,
                         List <ChabuChannelImpl> channels, Runnable xmitRequestListener, ChabuConnectingValidator connectingValidator)
        {
            this.notifierWhenRecvAndXmitCompletedStartup = new SingleEventNotifierFromTwoSources(eventCompletedStartup);
            this.xmitRequestListener = xmitRequestListener;
            verifyLocalSetup(localSetupInfo);
            xmitAbortMessage   = new AbortMessage(xmitRequestListener);
            this.channels      = channels;
            this.priorityCount = priorityCount;
            this.factory       = factory;

            this.setup = new Setup(localSetupInfo, xmitAbortMessage, connectingValidator);

            this.xmitter = factory.createXmitterStartup(xmitAbortMessage, xmitRequestListener, setup, xmitCompletedStartup);

            this.receiver = factory.createReceiverStartup(xmitAbortMessage, setup, recvCompletedStartup);
            verifyPriorityCount();
            verifyChannels();
        }
Esempio n. 2
0
 private void xmitCompletedStartup()
 {
     xmitter = factory.createXmitterNormal(xmitAbortMessage, xmitRequestListener, priorityCount, channels, (int _priorityCount, int _channelCount) => new Priorizer(_priorityCount, _channelCount), setup.getRemoteMaxReceiveSize());
     notifierWhenRecvAndXmitCompletedStartup.event1();
 }