Пример #1
0
        /// <summary>
        /// instance field </summary>
//JAVA TO C# CONVERTER WARNING: 'final' parameters are ignored unless the option to convert to C# 7.2 'in' parameters is selected:
//ORIGINAL LINE: public static ExpressionTemplate get(final ExpressionTemplate target, final FieldReference field)
        public static ExpressionTemplate Get(ExpressionTemplate target, FieldReference field)
        {
            if (target is Expression)
            {
                return(Expression.Get(( Expression )target, field));
            }
            return(new ExpressionTemplateAnonymousInnerClass5(field.Type(), target, field));
        }
Пример #2
0
        /// <summary>
        /// invoke an instance method </summary>
//JAVA TO C# CONVERTER WARNING: 'final' parameters are ignored unless the option to convert to C# 7.2 'in' parameters is selected:
//ORIGINAL LINE: public static ExpressionTemplate invoke(final ExpressionTemplate target, final MethodReference method, final ExpressionTemplate... arguments)
        public static ExpressionTemplate Invoke(ExpressionTemplate target, MethodReference method, params ExpressionTemplate[] arguments)
        {
            if (target is Expression)
            {
                Expression[] materialized = TryMaterialize(arguments);
                if (materialized != null)
                {
                    return(Expression.Invoke(( Expression )target, method, materialized));
                }
            }
            return(new ExpressionTemplateAnonymousInnerClass3(method.Returns(), target, method, arguments));
        }
Пример #3
0
 public static ExpressionTemplate Cast(TypeReference type, ExpressionTemplate expression)
 {
     return(new ExpressionTemplateAnonymousInnerClass8(type, expression));
 }
Пример #4
0
 public static ExpressionTemplate Cast(Type clazz, ExpressionTemplate expression)
 {
     return(Cast(typeReference(clazz), expression));
 }
Пример #5
0
 public ExpressionAnonymousInnerClass(ExpressionTemplate outerInstance, Org.Neo4j.Codegen.TypeReference type, Org.Neo4j.Codegen.CodeBlock method) : base(type)
 {
     this.outerInstance = outerInstance;
     this._method       = method;
 }
Пример #6
0
        /// <summary>
        /// instance field </summary>
//JAVA TO C# CONVERTER WARNING: 'final' parameters are ignored unless the option to convert to C# 7.2 'in' parameters is selected:
//ORIGINAL LINE: public static ExpressionTemplate get(final ExpressionTemplate target, final Lookup<FieldReference> field, TypeReference type)
        public static ExpressionTemplate Get(ExpressionTemplate target, Lookup <FieldReference> field, TypeReference type)
        {
            return(new ExpressionTemplateAnonymousInnerClass6(type, target, field));
        }
Пример #7
0
 /// <summary>
 /// instance field </summary>
 public static ExpressionTemplate Get(ExpressionTemplate target, TypeReference fieldType, string fieldName)
 {
     return(Get(target, Lookup.Field(fieldType, fieldName), fieldType));
 }
Пример #8
0
 public virtual Builder InvokeSuper()
 {
     return(Expression(ExpressionTemplate.InvokeSuperConstructor(new ExpressionTemplate[] {}, TypeReference.NoTypes)));
 }
Пример #9
0
 public static ExpressionTemplate Get(ExpressionTemplate target, Type fieldType, string fieldName)
 {
     return(get(target, typeReference(fieldType), fieldName));
 }
Пример #10
0
 public virtual Builder Returns(ExpressionTemplate value)
 {
     Statements.Add(Statement.Returns(value));
     return(this);
 }
Пример #11
0
 public virtual Builder Put(ExpressionTemplate target, TypeReference fieldType, string fieldName, ExpressionTemplate expression)
 {
     Statements.Add(Statement.Put(target, Lookup.Field(fieldType, fieldName), expression));
     return(this);
 }
Пример #12
0
 public virtual Builder Put(ExpressionTemplate target, Type fieldType, string fieldName, ExpressionTemplate expression)
 {
     return(Put(target, typeReference(fieldType), fieldName, expression));
 }
Пример #13
0
 public virtual Builder Expression(ExpressionTemplate expression)
 {
     Statements.Add(Statement.Expression(expression));
     return(this);
 }
Пример #14
0
 public virtual Builder InvokeSuper(ExpressionTemplate[] parameters, TypeReference[] parameterTypes)
 {
     return(Expression(ExpressionTemplate.InvokeSuperConstructor(parameters, parameterTypes)));
 }