SIPSorcery.SimpleWizardManager.AddRule C# (CSharp) Method

AddRule() private method

private AddRule ( SimpleWizardRule rule ) : void
rule SIPSorcery.Entities.SimpleWizardRule
return void
        private void AddRule(SimpleWizardRule rule)
        {
            rule.ID = Guid.NewGuid().ToString();
            rule.Owner = m_owner;
            rule.DialPlanID = m_dialPlan.ID;

            m_riaContext.SimpleWizardRules.Add(rule);

            if (rule.Direction == SIPCallDirection.Out.ToString())
            {
                m_outgoingRulesUpdateControl.SetStatusMessage("Saving...", true);
            }
            else
            {
                m_incomingRulesUpdateControl.SetStatusMessage("Saving...", true);
            }

            m_riaContext.SubmitChanges(AddRuleComplete, rule);
        }