[Yanel-dev] Toolbar

Michael Wechner michael.wechner at wyona.com
Tue Apr 17 15:44:12 CEST 2007


Josias Thöny wrote:

> Michael Wechner wrote:
>
>> Hi
>>
>> The Toolbar menus are now configurable per Realm, e.g. take a look at 
>> the Welcome or Yanel Website realm configuration:
>>
>> src/realms/welcome-admin/yanel/config/yanel-realm-config.xml
>>
>> src/realms/yanel-website/config/yanel-realm-config.xml
>>
>> whereas this lead me to the first questio if one shouldn't use a 
>> different namespace for this and also
>> more the method Realm.getMenuClass() into some other class, because 
>> this seems to me a "webapp thing" and not
>> really part of the core?
>
>
> I see two alternative solutions:
> - add properties to the realm: realm.getProperty("menu-class")
>   (it might be a bit more generic)


I think this way the servlet and realm would be at least decoupled

> - attach the menu class to the realm: realm.getMenu(....)
>
> Not sure if any of those two solutions is better than the one you 
> implemented...


I think is better than I did above, but doesn't really solve the decoupling

>
>>
>> WDYT?
>>
>> My second question is about the API:
>>
>> src/core/java/org/wyona/yanel/servlet/menu/Menu.java
>>
>> which I did very quickly and I am sure some of you have much better 
>> ideas how to do this better.
>>
>> Any suggestions are very welcome :-)
>
>
> I don't have any suggestions right now...


hopefully later :-)

>
>>
>> My third question is about how we shall add java libraries of a 
>> realm, for instance the class
>>
>> src/core/java/org/wyona/yanel/servlet/menu/impl/YanelWebsiteMenu.java
>>
>> should rather go into the Yanel Website Realm, which I guess means 
>> that a realm can also have a build.xml file just as
>> a resource has.
>
>
> Yeah, the build system would have to be modified to build the java 
> code of each realm. I don't know whether the central yanel build.xml 
> should build the realms, or if each realm should have its own build.xml.


I guess realms could also have their own dependencies and hence we end 
up with a similar build as with the resources.
So maybe we can share most of the code

>
>
>>
>> WDYT?
>>
>> My fourth point is not a question but rather a comment that I will 
>> also make the menus configurable per resource configuration
>
>
> If some menu entries come from the realm, and some from the resource, 
> would it make sense to have menu sections named "Realm" and 
> "Resource", instead of "File"/"Edit"/whatever?


you mean in the case of the DefaultMenu?

Cheers

Michi

>
> Josias
>
>
>>
>> Thanks
>>
>> Michi
>>
>
>
> _______________________________________________
> Yanel-development mailing list
> Yanel-development at wyona.com
> http://wyona.com/cgi-bin/mailman/listinfo/yanel-development
>


-- 
Michael Wechner
Wyona      -   Open Source Content Management   -    Apache Lenya
http://www.wyona.com                      http://lenya.apache.org
michael.wechner at wyona.com                        michi at apache.org
+41 44 272 91 61




More information about the Yanel-development mailing list