You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by gmparker2000 <gr...@brovada.com> on 2016/11/23 15:16:02 UTC

Resource loading question

I have a rather unique situation where I need to use the same page with
different properties files.  Just wondering if there is any support for
this.  By default properties are loaded and cached based on the class name. 
My situation requires more flexibility.  Also, inheritance doesn't work in
my situation.  So I can't do something like "class PageASituation1 extends
PageA {}".  I realize that this is technically possible but just not
applicable in my circumstance.

So, for example, I need something based on naming convention,  

- com/myapp/
    - PageA.java
    - PageA.properties
    - PageA_situation1.properties
    - PageA_situation1_en.properties
    - PageA_situation1_fr.properties
    - PageA_situation2.properties
    - PageA_situation2_en.properties
    - PageA_situation2_fr.properties

Or perhaps based on sub-folder/package

- com/myapp
   - PageA.java
   - PageA.properties
   - situation 1
         - PageA.properties
         - PageA_en.properties
         - PageA_fr.properties
   - situation 2
         - PageA.properties
         - PageA_en.properties
         - PageA_fr.properties


Does anything like this exist?  Any implementation suggestions?  

I am still using wicket 6.

--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Resource-loading-question-tp4676259.html
Sent from the Users forum mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Resource loading question

Posted by Sven Meier <sv...@meiers.net>.
https://cwiki.apache.org/confluence/display/WICKET/Multiple+markups+per+page

https://cwiki.apache.org/confluence/display/WICKET/Localization+and+Skinning+of+Applications#LocalizationandSkinningofApplications-MarkupFiles

Sven


On 23.11.2016 16:16, gmparker2000 wrote:
> I have a rather unique situation where I need to use the same page with
> different properties files.  Just wondering if there is any support for
> this.  By default properties are loaded and cached based on the class name.
> My situation requires more flexibility.  Also, inheritance doesn't work in
> my situation.  So I can't do something like "class PageASituation1 extends
> PageA {}".  I realize that this is technically possible but just not
> applicable in my circumstance.
>
> So, for example, I need something based on naming convention,
>
> - com/myapp/
>      - PageA.java
>      - PageA.properties
>      - PageA_situation1.properties
>      - PageA_situation1_en.properties
>      - PageA_situation1_fr.properties
>      - PageA_situation2.properties
>      - PageA_situation2_en.properties
>      - PageA_situation2_fr.properties
>
> Or perhaps based on sub-folder/package
>
> - com/myapp
>     - PageA.java
>     - PageA.properties
>     - situation 1
>           - PageA.properties
>           - PageA_en.properties
>           - PageA_fr.properties
>     - situation 2
>           - PageA.properties
>           - PageA_en.properties
>           - PageA_fr.properties
>
>
> Does anything like this exist?  Any implementation suggestions?
>
> I am still using wicket 6.
>
> --
> View this message in context: http://apache-wicket.1842946.n4.nabble.com/Resource-loading-question-tp4676259.html
> Sent from the Users forum mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org