private ConstructorBuilderInfo CreateInternalClassCtor(DeclarationClass n, string name) { _currentType = name; _currentTypeBuilder = _typeManager.GetBuilderInfo(n.Name); var method = new DeclarationMethod(name, n.Statements) { Type = new TypeFunction(true), Descriptor = new MethodDescriptor(n.Type, name, n.Descriptor) }; _typeManager.AddCtor(name, method); return(_currentTypeBuilder.ConstructorBuilder); }
//this is a special case since it will be the entry point.. private MethodBuilderInfo CreateEntryPointMethod(DeclarationClass n, string name) { _currentType = name; _currentTypeBuilder = _typeManager.GetBuilderInfo(n.Name); var method = new DeclarationMethod(name, n.Statements) { Type = new TypeFunction(true), Descriptor = new MethodDescriptor(n.Type, name, n.Descriptor) }; _typeManager.AddMethod(name, method); return(_typeManager.GetMethodBuilderInfo(_currentType, n.Name)); }
private void SetCurrentType(string name) { _currentType = name; _currentTypeBuilder = _typeManager.GetBuilderInfo(name); }
private bool IsSubClass(TypeBuilderInfo b) { return new[] { "CollateralItem", "Bond", "InterestRules","PrincipalRules" }.Contains(b.Name); }
private ConstructorBuilderInfo CreateInternalClassCtor(DeclarationClass n, string name) { _currentType = name; _currentTypeBuilder = _typeManager.GetBuilderInfo(n.Name); var method = new DeclarationMethod(name, n.Statements) { Type = new TypeFunction(true), Descriptor = new MethodDescriptor(n.Type, name, n.Descriptor) }; _typeManager.AddCtor(name, method); return _currentTypeBuilder.ConstructorBuilder; }
//this is a special case since it will be the entry point.. private MethodBuilderInfo CreateEntryPointMethod(DeclarationClass n, string name) { _currentType = name; _currentTypeBuilder = _typeManager.GetBuilderInfo(n.Name); var method = new DeclarationMethod(name, n.Statements) { Type = new TypeFunction(true), Descriptor = new MethodDescriptor(n.Type, name, n.Descriptor) }; _typeManager.AddMethod(name, method); return _typeManager.GetMethodBuilderInfo(_currentType, n.Name); }
private bool IsSubClass(TypeBuilderInfo b) { return(new[] { "CollateralItem", "Bond", "InterestRules", "PrincipalRules" }.Contains(b.Name)); }