Wirebox & VirtualEntityService

I keep going over the documentation http://wiki.coldbox.org/wiki/WireBox.cfm
but I just don't see it.

If I'm using a VirtualEntityService say like..

component extends="coldbox.system.orm.hibernate.VirtualEntityService"
singleton {
  public UserService function init(){
    super.init(entityName="User");
    return this;
  }
}

I don't see how wirebox can come into play? I'd like the User object
be created by wirebox so inside of User, it can be injected with other
objects
component name="User" {
  property name="whateverobj" inject="coldbox:whatever";
}

Just to expand, this is in my config:
binder.map("UserService").toDSL("entityService:User").asSingleton();

In my handlers, is this:
property name="userService" inject="model:userService";

in my events, is this:
User = userService.get(UserID);

in my User obj, is this (just for testing to see if it actually gets
injected)
property name="userService" inject="model:userService";

but, when I dump the User object, userService is '[empty string]'

So, I'm really confused. Its wired in the binder, the handler &
events get the service, create the User object (right?) but, the User
object doesnt get injected with anything.

I am assuming that User is a persistent CFC, so there are a few other things you need to do to make this work.

1) Turn on eventhandling for you application.

<cfset this.ormsettings = {

eventhandling=true,

eventhandler="model.ORMEventHandler",
flushAtRequestEnd=false

} />

2) Turn on property injection in your autowire interceptor,

//Autowire

{class="coldbox.system.interceptors.Autowire",

properties={entityInjection = true}

}

3) Create that model.ORMEventHandler cfc we set above and have it extend coldbox.system.orm.hibernate.EventHandler

component extends="coldbox.system.orm.hibernate.EventHandler"{

}

That should do it for you.

Thanks,

Curt Gratz
Computer Know How

No luck...
I had everything like you said, except
properties={entityInjection=true}, so.. I turned that one, no luck

I wasn't quite sure where or how that should be declared, so in
Config.cfc, Wirebox.cfc and in my ModuleConfig.cfc in the module im
trying to create, each one had both of these:
listeners =
[{class="coldbox.system.interceptors.Autowire",properties={entityInjection
= true}}];
interceptors =
[{class="coldbox.system.interceptors.Autowire",properties={entityInjection=true}}];

and still no luck =/

ah! hah! Thanks Curt, that actually did work, I misspelled the
injector property.. but, Just to make sure, which one of those is
correct listeners/interceptors and, it can just be in the moduleconfig
right?

The interceptor in the Coldbox.cfc...