Example #1
0
        internal static CfAction FromAction(Action source)
        {
            if (source == null)
            {
                return(null);
            }

            CfAction item = null;

            if (source.GetType() == typeof(Text))
            {
                item = TextMapper.FromText((Text)source);
            }
            else if (source.GetType() == typeof(Call))
            {
                item = CallMapper.FromCall((Call)source);
            }
            return(item);
        }
Example #2
0
        internal static Action ToAction(CfAction source)
        {
            if (source == null)
            {
                return(null);
            }

            Action item = null;

            if (source.GetType() == typeof(CfText))
            {
                item = TextMapper.ToText((CfText)source);
            }
            else if (source.GetType() == typeof(CfCall))
            {
                item = CallMapper.ToCall((CfCall)source);
            }
            return(item);
        }