You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Andreas Hartmann <an...@apache.org> on 2005/04/26 10:40:19 UTC

Re: How the editor get's a schema (was Re: svn commit: r164636 - /lenya/trunk/src/java/org/apache/lenya/cms/publication/DocumentType.ja va /lenya/trunk/src/java/org/apache/lenya/cms/publication/DocumentTypeBui lderImpl.java)

Michael Wechner wrote:
> Torsten Schlabach wrote:
> 
>> Andreas,
>>
>>  
>>
>>> I agree that this functionality is useful. But IMO we can't restrict
>>> it to RelaxNG (e.g., Xopus requires XSD AFAIK).
>>>   
>>
>>
>> I have been thinking about this as well. I agree that we should not
>> necessarily limit this to RelaxNG, but one method can only return one 
>> type
>> of structure definition unless you do something like
>>
>> public String getSchemaDefinition(String format) {
>> ...
>> }
>>  
>>
> 
> is this causing a problem by specifying a format?

I guess this was just an example of a "configurable" getSchemaDefinition()
method. Before defining some "schema format identifiers", I'd rather look
for existing approaches.

-- Andreas


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: How the editor get's a schema (was Re: svn commit: r164636 -

Posted by Torsten Schlabach <ts...@apache.org>.
Andreas,

>> Before defining some "schema format identifiers", I'd rather look
>> for existing approaches.

Agreed. Tell me where to find any. (This is meant serious!)

>> BTW, is it even possible to register source factories
>> for URNs? The o.a.e.source javadocs aren't very clear about
>> this issue:

Sure. I am currently about to do this. Compare:

http://wiki.apache.org/lenya/Sitemap2JavaApiContractProposal

Didn't we discuss this already on this list? Not sure.

What I am not sure about is (and this is general questions to Internet
standards, not to Avalon or Lenya):

a) Do URNs start with urn:? Which would be correct:

urn:isbn:0-743-45681-5

or just

isbn:0-743-45681-5

b) How do I specify further what I want from a resource? If I was to
implement an isbn source for example, would it return the content of the
book or the metadata (title, author, publisher, price) for example?

I see no reason why you couldn't have an Avalon source for URNs and it
makes a lot of sense to me. You can start some discussion about how the
URN will resolve to a URL at the end of the day, because it ultimately has
to if you want to read from it. It's hard to generate SAX events from an
abstract concept. But in some places it makes a lot of sense not to say
WHERE something should be but WHAT you want to reference.

Regards,
Torsten



> Michael Wechner wrote:
>> Torsten Schlabach wrote:
>>
>>> Andreas,
>>>
>>>
>>>
>>>> I agree that this functionality is useful. But IMO we can't restrict
>>>> it to RelaxNG (e.g., Xopus requires XSD AFAIK).
>>>>
>>>
>>>
>>> I have been thinking about this as well. I agree that we should not
>>> necessarily limit this to RelaxNG, but one method can only return one
>>> type
>>> of structure definition unless you do something like
>>>
>>> public String getSchemaDefinition(String format) {
>>> ...
>>> }
>>>
>>>
>>
>> is this causing a problem by specifying a format?
>
> I guess this was just an example of a "configurable" getSchemaDefinition()
> method. Before defining some "schema format identifiers", I'd rather look
> for existing approaches.
>
> -- Andreas
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
> For additional commands, e-mail: dev-help@lenya.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org