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

Update factories.rst#3770

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

Closed
AlaaAttya wants to merge3 commits intosymfony:2.4fromAlaaAttya:patch-1
Closed

Conversation

AlaaAttya
Copy link
Contributor

your factory method should be static to work!

your factory method should be static to work!
@wouterj
Copy link
Member

Indeed, the method needs to be static when setting the factoryclass and it can be non-static when setting a factoryservice

@weaverryan
Copy link
Member

No, it's not quite right yet, unfortunately. If you look at line 80:

When you specify the class to use for the factory (viafactory_class)
the method will be called statically. If the factory itself should be instantiated
and the resulting object's method called (as in this example), configure the
factory itself as a service:

So, we're using this one example to explain bothfactory_class andfactory_service. I think weshould include this change, but reword this paragraph to something like:

When you specify the class to use for the factory (viafactory_class)
the method will be called statically. If the factory itself should be instantiated
and the resulting object's method called, configure the factory itself as a service.
In this case, the method (e.g.get) should be changed to be non-static:

@AlaaAttya Can you make this change please? :)

Thanks!

@AlaaAttya
Copy link
ContributorAuthor

@weaverryan done :)

@weaverryan
Copy link
Member

Awesome, thanks so much@AlaaAttya!

weaverryan added a commit that referenced this pull requestMay 2, 2014
This PR was submitted for the 2.4 branch but it was merged into the 2.3 branch instead (closes#3770).Discussion----------Update factories.rstyour factory method should be static to work!Commits-------97ed5ce Update factories.rstaefc36c Update factories.rsta9cfdb2 Update factories.rst
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@AlaaAttya@wouterj@weaverryan

[8]ページ先頭

©2009-2025 Movatter.jp