Thanks for the help.

On 14/09/2007, at 12:30 AM, Howard Lewis Ship wrote:

Oh, then ComponentClassEnhancementWorker is almost certainly the way to go.

At the moment I'm persisting with ComponentInstantiatorSource, as I can do *anything* to the class with that, and I'm still experimenting. I agree that the worker chain is cleaner.

I'm trying to substitute my implementation (instead of just replacing the class) via my AppModule:

public class AppModule {
public CalComponentInstantiatorSourceImpl buildCalComponentInstantiator(@InjectService("ClassFactory")
                    ClassFactory classFactory,
                    ComponentClassTransformer transformer,
                    Log log)
                    {
CalComponentInstantiatorSourceImpl source = new CalComponentInstantiatorSourceImpl(classFactory
                                .getClassLoader(), transformer, log);

//_updateListenerHub.addUpdateListener(source); -- fix this later

                        return source;
                    }
public static void contributeAlias(@InjectService ("CalComponentInstantiator") ComponentInstantiatorSource myService,
                     Configuration<AliasContribution> configuration)
                  {
configuration.add(AliasContribution.create (ComponentInstantiatorSource.class, myService));
                  }     
}

but I get the error:
java.lang.IllegalStateException: Construction of service 'Alias' has failed due to recursion: the service depends on itself in some way. Please check org.apache.tapestry.services.TapestryModule.build (Log, String, AliasManager, Collection) (at TapestryModule.java:249) for references to another service that is itself dependent on service 'Alias'.

I've looked at TapestryModule.java, and Googled the error, but I'm not sure how to resolve it -- I think I need to explictly @Inject 'Configuration<AliasContribution> configuration', but I can't figure out what Id to use...

I get a similar error if I contribute to AliasOverrides, and I'm not sure what the difference between the two is?

Thanks,
  Tom

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to