public void AddFieldWithParameter(Field field, TypeWithName parameter) { Fields.Add(field); Parameters.Add(parameter); ParameterWithField.Add(new FieldWithParameter { Field = field, Parameter = parameter }); }
private TemplateParameter GetParameters(string name) { var parameters = new TemplateParameter(); parameters.Add(ConstructorConstants.ConstructorFields, Fields.Select(x => x.Build())); parameters.Add(ConstructorConstants.ConstructorParameters, ConstructorParameters(Parameters)); parameters.Add(ConstructorConstants.FieldWithParameter, ParameterWithField.Select(x => x.Build())); parameters.Add(ConstructorConstants.CustomImplementation, CustomImplementation); parameters.Add(ConstructorConstants.Name, name); return(parameters); }
public bool ShouldBeBuild() { return(ParameterWithField.Any() || Parameters.Any() || CustomImplementation.Any()); }