public override object Visit(ObjectCreateExpression objectCreateExpression, object data) { return new CodeObjectCreateExpression(ConvType(objectCreateExpression.CreateType.Type), GetExpressionList(objectCreateExpression.Parameters)); }
void ObjectCreateExpression( #line 1701 "VBNET.ATG" out Expression oce) { #line 1703 "VBNET.ATG" TypeReference type = null; Expression initializer = null; ArrayList arguments = null; oce = null; Expect(128); ArrayTypeName( #line 1708 "VBNET.ATG" out type); if (la.kind == 25) { lexer.NextToken(); if (StartOf(17)) { ArgumentList( #line 1710 "VBNET.ATG" out arguments); } Expect(26); } if (la.kind == 21) { ArrayInitializer( #line 1714 "VBNET.ATG" out initializer); } #line 1717 "VBNET.ATG" if(initializer == null) { oce = new ObjectCreateExpression(type, arguments); } else { ArrayCreateExpression ace = new ArrayCreateExpression(type, initializer as ArrayInitializerExpression); ace.Parameters = arguments; oce = ace; } }
public virtual object Visit(ObjectCreateExpression objectCreateExpression, object data) { // nothing to visit return data; }
public object Visit(ObjectCreateExpression objectCreateExpression, object data) { return String.Format("new {0}{1}", GetTypeString(objectCreateExpression.CreateType), GetParameters(objectCreateExpression.Parameters) ); }
public override object Visit(ObjectCreateExpression objectCreateExpression, object data) { string name = resolver.SearchType(objectCreateExpression.CreateType.Type, resolver.CallingClass, resolver.CompilationUnit).FullyQualifiedName; return new ReturnType(name, (int[])objectCreateExpression.CreateType.RankSpecifier.ToArray(typeof(int)), 0); }