Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Moved WithObject to generated code, added FromTemplate #43

Merged
merged 4 commits into from
Jan 14, 2024

Conversation

MelGrubb
Copy link
Owner

Related to #42, but still a work in progress.

I've moved the WithObject method out from the base class and into the generated half of the builder. This means that it can return the concrete builder type instead of the generic base class. I also added a new FromTemplate method that lets you make a shallow clone of an example object. I'm not married to the name. FromExample would work well too, since "Template" might gert confusing if/when I'm able to add configurable templates back in.

@MelGrubb MelGrubb added the enhancement New feature or request label Jan 14, 2024
@MelGrubb MelGrubb self-assigned this Jan 14, 2024
@MelGrubb MelGrubb linked an issue Jan 14, 2024 that may be closed by this pull request
@@ -7,10 +7,13 @@
</PropertyGroup>
<ItemGroup>
<AssemblyAttribute Include="System.Runtime.CompilerServices.InternalsVisibleToAttribute">
<_Parameter1>BuilderGenerator.IntegrationTests.Net60</_Parameter1>
<_Parameter1>BuilderGenerator.Tests.Integration.Net60</_Parameter1>
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reorganized the tests quite a bit.

Bumped version to 2.4.0
Added release notes
Refactores DTO mechanism
Moved license file
@MelGrubb MelGrubb merged commit e25b90c into main Jan 14, 2024
1 check passed
@MelGrubb MelGrubb deleted the 42-FromTemplate branch January 14, 2024 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Need guidance for building entities without parameterless constructor
1 participant