Hi Ed,
Am 13.11.2012 um 23:20 schrieb Edward Burns <edward.burns_at_oracle.com>:
>
>>>>>> On Fri, 9 Nov 2012 14:12:06 -0800, Edward Burns <edward.burns_at_oracle.com> said:
>
> EB> CONDITIONALLY_RESOLVED: How are contracts made available to the
> EB> application.
>
> EB> This is where I bring in the syntax from Manfred I mentioned earlier.
>
> EB> If we have a resource-library-contracts element in the application
> EB> configuration resources, any mappings and contract declarations it has
> EB> are added to the data structure of such things for the application.
>
> EB> <faces-config>
>
> EB> <resource-library-contracts>
> EB> <mappings>
> EB> <view pattern="" contracts="default1"/>
> EB> <view pattern="/registration/*" contracts="default1, registration1"/>
> EB> <view pattern="/welcome" contracts="welcome1"/>
> EB> <view pattern="/print" contracts=""/>
> EB> </mappings>
>
> EB> <contracts>
> EB> <contract id="default1" href="$CONTRACT_ROOT/default1"/>
> EB> <contract id="registration1" href="$CONTRACT_ROOT/registration1"/>
> EB> </contracts>
>
> EB> </resource-library-contracts>
>
> EB> </faces-config>
>
> As Leonardo pointed out, the <contracts> section is really unnecessary,
> because we scan for the existence of contracts at startup. I'll be
> taking it out.
>
> I'd also like to introduce a convention. If there are no
> <resource-library-contracts> in the application configuration resources,
> the templates of any resource library contracts are implicitly available to
> be used template clients anywhere in the app.
I really love convention over configuration, but I don't understand this. E.g. if the runtime finds contractA and contractB with the same resources, which one is chosen?
Ciao Frank