Beispiel #1
0
 public string Serialize(CogniPy.CNL.DL.Paragraph p)
 {
     signature      = new HashSet <Tuple <EntityKind, string> >();
     dataValues     = new HashSet <Tuple <string, string, string> >();
     foundValues    = new Dictionary <string, Value>();
     dependentAttrs = new Dictionary <string, HashSet <string> >();
     instanceValues = new List <InstanceValue>();
     return(p.accept(this) as string);
 }
Beispiel #2
0
        public virtual object Visit(CogniPy.CNL.DL.Paragraph e)
        {
            List <Statement> newStmt = new List <Statement>();

            foreach (var x in e.Statements)
            {
                x.accept(this);
            }
            return(e);
        }
Beispiel #3
0
        public object Visit(CogniPy.CNL.DL.Paragraph e)
        {
            StringBuilder sb = new StringBuilder();

            foreach (var x in e.Statements)
            {
                if (x != null)
                {
                    var str = x.accept(this) as string;
                    if (!System.String.IsNullOrWhiteSpace(str))
                    {
                        sb.AppendLine(str);
                    }
                }
            }
            return(sb.ToString());
        }