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

Use GWT generator to generate the ginjector #63

Closed
christiangoudreau opened this issue Dec 6, 2012 · 17 comments
Closed

Use GWT generator to generate the ginjector #63

christiangoudreau opened this issue Dec 6, 2012 · 17 comments
Assignees
Milestone

Comments

@christiangoudreau
Copy link
Member

We require that the users manually add a method to their ginjector whenever they create a new presenter. However it may be possible to automatically generate the ginjector with a GWT generator.

See issue 207 on GoogleCode

@branflake2267
Copy link
Contributor

Nice job! :)

@kuhnroyal
Copy link
Contributor

I just tried to use the ApplicationController. The Ginjector is emitted correctly in the GWT .generated folder but the GinjectorInspector fails to find the class with "The configuration property 'gin.ginjector' is 'com.example.client.gin.ClientInjector' which doesn't identify a type inheriting from 'Ginjector'.".
Any idea why this could be happening? Isn't GWT supposed to have access to previously generated artifacts?

@christiangoudreau
Copy link
Member Author

the gin.ginjector property must be set to ClientGinjector

you don't need any ginjector anymore.

Known issue: Gatekeepers are not included yet and I have to find an elegant
way to include form factors permutations

On Fri, Dec 14, 2012 at 12:10 PM, Peter Leibiger
notifications@github.comwrote:

I just tried to use the ApplicationController. The Ginjector is emitted
correctly in the GWT .generated folder but the GinjectorInspector fails to
find the class with "The configuration property 'gin.ginjector' is
'com.example.client.gin.ClientInjector' which doesn't identify a type
inheriting from 'Ginjector'.".
Any idea why this could be happening? Isn't GWT supposed to have access to
previously generated artifacts?


Reply to this email directly or view it on GitHubhttps://github.com//issues/63#issuecomment-11383795.

Christian Goudreau | CEO - Président
M: 1.877.635.1585 | S: christian.goudreau
ArcBees http://www.arcbees.com | Blog http://blog.arcbees.com |
Facebookhttps://www.facebook.com/QueenOfTheBees|
LinkedIn http://www.linkedin.com/company/arcbees

@kuhnroyal
Copy link
Contributor

I have no manual Ginjector. Only the one that is being generated, however the GinjectorInspector still fails when trying to generate a Proxy.

I have already implemented Gatekeepers and fixed the PresenterBundles which don't work atm. I can open a pull request once I can get it running.

@christiangoudreau
Copy link
Member Author

Bizarre, do you have the latest in your maven repo?

ClientGinjector doesn't extends Ginjector into de gen folder? That's really
weird

On Sat, Dec 15, 2012 at 1:32 PM, Peter Leibiger notifications@github.comwrote:

I have no manual Ginjector. Only the one that is being generated, however
the GinjectorInspector still fails when trying to generate a Proxy.

I have already implemented Gatekeepers and fixed the PresenterBundles
which don't work atm. I can open a pull request once I can get it running.


Reply to this email directly or view it on GitHubhttps://github.com//issues/63#issuecomment-11408140.

Christian Goudreau | CEO - Président
M: 1.877.635.1585 | S: christian.goudreau
ArcBees http://www.arcbees.com | Blog http://blog.arcbees.com |
Facebookhttps://www.facebook.com/QueenOfTheBees|
LinkedIn http://www.linkedin.com/company/arcbees

@kuhnroyal
Copy link
Contributor

I build from master. It does extent Ginjector, the code is solid but the class can not be found by the inspector.

@christiangoudreau
Copy link
Member Author

Uhm, I've just sent a pull request on the GWTP-Samples for the basic
sample. This one is working.

I had to clean my .m2/com/gwtplatorm repo when I updated to the last
version, could you verify if that solves the problem?

On Sat, Dec 15, 2012 at 3:28 PM, Peter Leibiger notifications@github.comwrote:

I build from master. It does extent Ginjector, the code is solid but the
class can not be found by the inspector.


Reply to this email directly or view it on GitHubhttps://github.com//issues/63#issuecomment-11409965.

Christian Goudreau | CEO - Président
M: 1.877.635.1585 | S: christian.goudreau
ArcBees http://www.arcbees.com | Blog http://blog.arcbees.com |
Facebookhttps://www.facebook.com/QueenOfTheBees|
LinkedIn http://www.linkedin.com/company/arcbees

@kuhnroyal
Copy link
Contributor

I got it to work now in a complex setup with 40+ presenters in multiple bundles, also with gatekeepers and @DefaultGatekeeper.

Problem was that the class given in 'gin.ginjector' property has to be named ClientGinjector, mine was called ClientInjector. This should be documented more thoroughly or maybe we can find a way to allow arbitrary a class name.

While we are at it, maybe we can also try to generate the ProviderBundles?

I will prepare a pull request tomorrow for the gatekeeper stuff.

@christiangoudreau
Copy link
Member Author

Cool! Good job! Yes, we could mark it more clearly in the Javadoc. The doc
for this features still has to be done though :D First we have to update
and move all the doc from Google code to Github, then add the new stuff!

So much to do!

A new undocumented feature is that you can now add as a fourth parameters
in the ctor the slot of your presenter, removing the need to override
revealInSlot. There's also an enum for the root: RevealType. Here was the
pull request:
#33

On Sun, Dec 16, 2012 at 10:24 AM, Peter Leibiger
notifications@github.comwrote:

I got it to work now in a complex setup with 40+ presenters in multiple
bundles, also with gatekeepers and @DefaultGatekeeper.

Problem was that the class given in 'gin.ginjector' property has to be
named ClientGinjector, mine was called ClientInjector. This should be
documented more thoroughly or maybe we can find a way to allow arbitrary a
class name.

While we are at it, maybe we can also try to generate the ProviderBundles?

I will prepare a pull request tomorrow for the gatekeeper stuff.


Reply to this email directly or view it on GitHubhttps://github.com//issues/63#issuecomment-11418744.

Christian Goudreau | CEO - Président
M: 1.877.635.1585 | S: christian.goudreau
ArcBees http://www.arcbees.com | Blog http://blog.arcbees.com |
Facebookhttps://www.facebook.com/QueenOfTheBees|
LinkedIn http://www.linkedin.com/company/arcbees

@branflake2267
Copy link
Contributor

Wow nice job!

@kuhnroyal
Copy link
Contributor

Got around to work on this a little more.
I sent a pull request #77

@ghost
Copy link

ghost commented Jan 15, 2013

Sorry to butt in, but where is the gen folder now?

@ghost
Copy link

ghost commented Jan 15, 2013

@kuhnroyal
Copy link
Contributor

By default in .generated I think

@christiangoudreau
Copy link
Member Author

the gen folder is where ever you chosen. You have to specify -gen generated if you want it to be in the "generated" folder. I personally always use -gen gen

@ghost
Copy link

ghost commented Jan 16, 2013

I think something may have changed in GWTP 0.8+ or GWT 2.5 as I now get my
ClientGinjector generated in a 'gen' folder but I can't figure out where!

When I use -gen gen I get it in my project root

This is all fine for me , but it's certainly less useful for beginners than
the old code that would output the full path to it's partially generated
ginjector

On 16 January 2013 00:35, christiangoudreau notifications@github.comwrote:

the gen folder is where ever you chosen. You have to specify -gen
generated if you want it to be in the "generated" folder. I personally
always use -gen gen


Reply to this email directly or view it on GitHubhttps://github.com//issues/63#issuecomment-12297987.

Cheers!
Ben Ritchie
draft pitch video http://www.youtube.com/watch?v=1oRK3cJCBHA&feature=plcp
facebook.secretstatus.com
blog.secretstatus.com/
www.secretstatus.com

@kuhnroyal
Copy link
Contributor

I just checked with the samples, if you don't provide the <gen> parameter to the maven-gwt-plugin it will end up in target/.generated by default. That folder may be hidden depending on your system.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants