I think this is exactly what I am looking for. I had an older version of Wicket
REST Annotations that did not have this class.
I do have a question about its usage. I did the following in my resource class
and it does work.
DefaultBundleResolver defaultBundleResolver = new
DefaultBundleResolver(MyRestResource.class);
String message = defaultBundleResolver.getMessage("test", null);
Is this the correct way to use this class or is their a way for it to plug into
Wicket via Application#Init() method and then get the Localizer and use it?
Thanks,
Warren
On Dec 11, 2013, at 1:30 PM, Andrea Del Bene wrote:
> Hi,
>
> maybe you can have a look here:
> https://github.com/wicketstuff/core/blob/master/jdk-1.6-parent/wicketstuff-restannotations-parent/restannotations/src/main/java/org/wicketstuff/rest/utils/wicket/bundle/DefaultBundleResolver.java
>
> That's a resource bundle resolver that works with the stringResourceLoaders
> of the Application.
>> I want to access Wicket's string resources in a non component class. I am
>> aware of getLocalizer().getString(...) for a component, but how do you do
>> this in a non Component based class and how do you make Wicket aware of the
>> message bundle ? All of the Localizer#getString(...) methods require a
>> Component. I am using Wicket version 6.10.0. I have a REST resource named
>> UserResource.java and messages in UserResource.properties.
>>
>> Thanks
>>
>> Warren
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
>
> --
> This email was Virus checked by Clark's Nutrition's Astaro Security Gateway.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]