cancel
Showing results for 
Search instead for 
Did you mean: 

JCR & Alfresco, monolingual by design?

Not applicable
Hello,

I plan to store content plus metadata in an Alfresco installation, but need to access it using the JCR interface. Is there any way I can benefit from Alfresco's MLText property type? ATM, it is only presented to the JCR interface as a single STRING property.

As far as I can see, JSR-170 was intentionally designed without explicit support for multilingual strings, but I don't know if there is a canonical way of working around this. The second most intuitive solution I can think of is adding (automatically generated) aspects for each localization, which is somewhat more complex.

Thanks in advance for all kinds of advice,

Julian
2 REPLIES 2

davidc
Star Contributor
Star Contributor
JSR-170 does not have explicit support multi-lingual strings.

I'm not sure the aspect approach would work because it still needs a mapping to the mltext property.

You might be able to do some mltext manipulation by changing the locale before setting and getting the mltext property via JCR.  Another (non-JCR) approach is to mix JCR/Alfresco calls.

http://wiki.alfresco.com/wiki/Introducing_the_Alfresco_Java_Content_Repository_API#Mixing_JCR_and_Al...

Not applicable
What I meant was that I would introduce aspects for each localization that duplicate the base model's properties as d:text. Then I could read the object's main title via my:title, the German title via my:title_de (from the aspect) etc., so I'd basically avoid MLText altogether; or yes, I may use mixed calls.

Is there anything related to this which could change in the future which I could take into account?

Thanks so far,
Julian