示例#1
0
        private Expression VisitAssociationFilter(OAssociationFilterExpression exp)
        {
            var source = exp.Source as FieldExpression;

            this.Write(source.Name); // this probably has very limited support

            if (exp.Origin == AssociationOrigin.Source)
            {
                this.Write(".outE()");
            }
            else
            {
                this.Write(".inE()");
            }

            var edgeType = exp.Type.GetGenericArguments()[0];
            if (edgeType.Implements<IProxyIdentifiable>())
            {
                edgeType = edgeType.BaseType;
            }
            if (!edgeType.Equals(typeof(IAssociation)))
            {
                this.Write(string.Format("[@class='{0}']", edgeType.Name));
            }

            this.Write("[");
            this.Visit(exp.Predicate); // this needs to be changed
            this.Write("]");
            return exp;
        }
示例#2
0
 private Expression VisitAssociationFilter(OAssociationFilterExpression exp)
 {
     return exp;
 }