Esempio n. 1
0
        private void ConfigureOptions(RasDialerOptions options, ref RASDIALPARAMS rasDialParams)
        {
            if (options == null)
            {
                return;
            }

            rasDialParams.dwIfIndex = options.InterfaceIndex;
        }
Esempio n. 2
0
        public void ReturnsInterfaceIndexAsExpected()
        {
            var target = new RasDialerOptions
            {
                InterfaceIndex = 1
            };

            Assert.AreEqual(1, target.InterfaceIndex);
        }
        private static RDEOPT BuildOptions(RasDialerOptions options)
        {
            if (options == null)
            {
                throw new ArgumentNullException(nameof(options));
            }

            var builder = new RasDialExtensionsOptionsBuilder();

            return(builder.Result);
        }
Esempio n. 4
0
        private static RDEOPT BuildOptions(RasDialerOptions options)
        {
            if (options == null)
            {
                throw new ArgumentNullException(nameof(options));
            }

            var builder = new RasDialExtensionsOptionsBuilder();

            //builder.AppendFlagIfTrue(options.UsePrefixSuffix, RDEOPT.UsePrefixSuffix);
            //builder.AppendFlagIfTrue(options.PausedStates, RDEOPT.PausedStates);
            //builder.AppendFlagIfTrue(options.SetModemSpeaker, RDEOPT.SetModemSpeaker);
            //builder.AppendFlagIfTrue(options.SetSoftwareCompression, RDEOPT.SetSoftwareCompression);
            //builder.AppendFlagIfTrue(options.DisableConnectedUI, RDEOPT.DisableConnectedUI);
            //builder.AppendFlagIfTrue(options.DisableReconnectUI, RDEOPT.DisableReconnectUI);
            //builder.AppendFlagIfTrue(options.DisableReconnect, RDEOPT.DisableReconnect);
            //builder.AppendFlagIfTrue(options.NoUser, RDEOPT.NoUser);
            //builder.AppendFlagIfTrue(options.Router, RDEOPT.Router);
            //builder.AppendFlagIfTrue(options.CustomDial, RDEOPT.CustomDial);
            //builder.AppendFlagIfTrue(options.UseCustomScripting, RDEOPT.UseCustomScripting);

            return(builder.Result);
        }