コード例 #1
0
        public GetConfigurationResponse GetConfiguration()
        {
            ToastHelper.PopToast("Get configuration");

            var response = new GetConfigurationResponse();

            response.FirewallEnabled = FirewallHelper.IsEnabled();
            return(response);
        }
コード例 #2
0
        public ConfigureResponse Configure(ConfigureRequest request)
        {
            ToastHelper.PopToast("Configure");

            if (request.FirewallEnabled)
            {
                FirewallHelper.EnableFirewall();
            }
            else
            {
                FirewallHelper.DisableFirewall();
            }

            var response = new ConfigureResponse();

            response.FirewallEnabled = FirewallHelper.IsEnabled();
            return(response);
        }