public CodeParameterDeclarationExpression AddParameter(Type type, string name) { return(AddParameter(Easy.TypeRef(type), name)); }
/// <summary> /// Declares a local variable. /// </summary> public CodeVariableDeclarationStatement DeclareVariable(Type type, string name) { return(DeclareVariable(Easy.TypeRef(type), name)); }
public static CodeAttributeDeclaration AddAttribute(this CodeTypeMember typeMember, Type type, params CodeExpression[] arguments) { return(Easy.AddAttribute(typeMember.CustomAttributes, Easy.TypeRef(type), arguments)); }
/// <summary> /// Adds a method with return type <paramref name="type"/> and attributes=Public|Final to this type. /// </summary> public static EasyMethod AddMethod(this CodeTypeDeclaration typeDecl, Type type, string name) { return(AddMethod(typeDecl, Easy.TypeRef(type), name)); }
public static EasyProperty AddProperty(this CodeTypeDeclaration typeDecl, Type type, string name) { return(AddProperty(typeDecl, Easy.TypeRef(type), name)); }
public static CodeMemberField AddField(this CodeTypeDeclaration typeDecl, Type type, string name) { return(typeDecl.AddField(Easy.TypeRef(type), name)); }
public static CodeCastExpression CastTo(this CodeExpression expr, Type type) { return(expr.CastTo(Easy.TypeRef(type))); }