Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Console] Add ability to regress the ProgressBar#19824

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

@jameshalsall
Copy link
Contributor

@jameshalsalljameshalsall commentedSep 2, 2016
edited
Loading

QA
Branch?master
Bug fix?no
New feature?yes
BC breaks?no
Deprecations?no
Tests pass?yes
Fixed tickets#15227
LicenseMIT
Doc PRhttps://github.com/symfony/symfony-docs/pull/6949/files

fsevestre reacted with thumbs up emoji
@jameshalsall
Copy link
ContributorAuthor

The build failure in AppVeyor does not look related to these changes.

*
* @param int $step Number of steps to regress
*/
publicfunctionregress($step =1)
Copy link
Member

Choose a reason for hiding this comment

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

I think we don't need a new method. What about just allowing negative numbers for advance?

HeahDude reacted with thumbs up emoji
Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

We could do that, but that sounds like an oxymoron callingadvance() to actually step backwards, addingregress() at least keeps the API consistent

Nek-, ScullWM, and robfrawley reacted with thumbs up emoji
Copy link
Contributor

Choose a reason for hiding this comment

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

But it would keep it consistent with the progress property too, although I'm fine with both, I don't see anything shocking about using negative here.

Copy link
Contributor

Choose a reason for hiding this comment

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

I prefer a clean API with simple, straight-forward methods, myself.

Copy link
Member

Choose a reason for hiding this comment

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

Then, we need an exception inadvance when used with a negative number and another one inregress when used with a negative number as well.

Copy link
Member

@nicolas-grekasnicolas-grekasSep 14, 2016
edited
Loading

Choose a reason for hiding this comment

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

An exception would be a DX issue, forcing one to call the correct method with boilerplate just for the sign. I agree with the first comment, we need only progress.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

This has now been updated so there is noregress() method.

@fabpot
Copy link
Member

Thank you@jameshalsall.

@fabpotfabpot merged commit42971bb intosymfony:masterSep 14, 2016
fabpot added a commit that referenced this pull requestSep 14, 2016
…shalsall)This PR was merged into the 3.2-dev branch.Discussion----------[Console] Add ability to regress the ProgressBar| Q             | A| ------------- | ---| Branch?       | master| Bug fix?      | no| New feature?  | yes| BC breaks?    | no| Deprecations? | no| Tests pass?   | yes| Fixed tickets |#15227| License       | MIT| Doc PR        |https://github.com/symfony/symfony-docs/pull/6949/filesCommits-------42971bb [Console] Add ability to regress the ProgressBar
xabbuh added a commit to symfony/symfony-docs that referenced this pull requestOct 14, 2016
…halsall)This PR was squashed before being merged into the master branch (closes#6949).Discussion----------Update ProgressBar docs with regress informationDoc updates for changes introduced insymfony/symfony#19824Commits-------d3346d8 Update ProgressBar docs with regress information
@fabpotfabpot mentioned this pull requestOct 27, 2016
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

6 participants

@jameshalsall@fabpot@nicolas-grekas@robfrawley@HeahDude@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp