Skip to content

Collect the option parameters into a bean #955

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

Closed
timnick-snow opened this issue Dec 18, 2023 · 2 comments
Closed

Collect the option parameters into a bean #955

timnick-snow opened this issue Dec 18, 2023 · 2 comments
Labels
status/declined Issue has been declined

Comments

@timnick-snow
Copy link

When there are a lot of option parameters, it is more convenient to use a bean to receive them.

For example, the following usage:

    @Command(command = "foo")
    public void foo(@OptionBody FooOption fooOption) {
        //...
    }
    public static class FooOption{
        @Option(longNames = "verbose",shortNames = 'v')
        private boolean verbose;
        @Option(longNames = "other",shortNames = 'o')
        private String other;
    }
@github-actions github-actions bot added the status/need-triage Team needs to triage and take a first look label Dec 18, 2023
@jvalkeal
Copy link
Contributor

Would be nice but it'd be good to see if framework implements similar ideas. spring-projects/spring-framework#23618

@jvalkeal jvalkeal added type/enhancement Is an enhancement request and removed status/need-triage Team needs to triage and take a first look labels Dec 18, 2023
@jvalkeal jvalkeal added status/declined Issue has been declined and removed type/enhancement Is an enhancement request labels Mar 10, 2024
@jvalkeal
Copy link
Contributor

As similar type of request in framework were declined we're also declining this as don't want to come up with just a shell feature.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/declined Issue has been declined
Projects
None yet
Development

No branches or pull requests

2 participants