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

CompilerConfigBuilder #109

Open
leolara opened this issue Aug 23, 2023 · 6 comments
Open

CompilerConfigBuilder #109

leolara opened this issue Aug 23, 2023 · 6 comments
Assignees
Labels
gfi easy Easy good first issue good first issue Good for newcomers

Comments

@leolara
Copy link
Collaborator

leolara commented Aug 23, 2023

Create a builder patter struct that allows to give some options and will create a compiler config for us. It uses a fluid interface, each method returns a &mut of self.

The interface is this:

config_builder().max_width(10).build() will return a config with MaxWidthCellManager{max_height, same_height: true}, SimpleStepSelectorBuilder

config_builder().max_height(1).build() will return a config with MaxWidthCellManager, SimpleStepSelectorBuilder

Things that have no Cell Manager should throw a panic.

Like:

config_builder().max_width(10).max_height(2).build()

@leolara leolara added good first issue Good for newcomers gfi easy Easy good first issue labels Aug 23, 2023
@cwkang1998
Copy link

Would like to give this a try!

@leolara
Copy link
Collaborator Author

leolara commented Aug 27, 2023

Use Option to keep the options in a struct, then put an algorithm in build() based on those values.

@000wan
Copy link
Contributor

000wan commented Sep 19, 2023

Hi @cwkang1998 :)
I want to gently ask how the task is going on, since I'm interested in this.
If possible, I'd like to work on this issue; and if not it's totally fine, I'll find another one to work on.

@leolara
Copy link
Collaborator Author

leolara commented Sep 19, 2023

@cwkang1998 are you working on this?

@cwkang1998
Copy link

Yup I am working on this, sorry for the delay, will get the PR up soon

@cwkang1998
Copy link

Sorry for taking a long time, first revision at #138.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
gfi easy Easy good first issue good first issue Good for newcomers
Projects
Status: Backlog
Development

Successfully merging a pull request may close this issue.

3 participants