You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Diana Shannon <sh...@apache.org> on 2002/06/21 14:12:41 UTC

[doc] draft FAQ xinclude/cinclude

Q.
What are the similarities and differences of xinclude and cinclude?

A.

Similarities
- Both provides mechanisms to include content from other documents
- Both support cocoon:/ protocol (i.e. they both use Cocoon's resolver).

xinclude transformer
- implements the W3C XInclude spec.
- allows you to include text or xml content (via parse="text|xml" )
- allows you to use xpointer syntax(via '#' or xpointer() syntax) within 
href attribute
- does *not* support Cocoon's caching mechanism

cinclude transformer
- helps you serve documents with inclusions and tags in xinclude 
namespace. Thus, you can create document
with xinclude *and* cinclude tags, process it through cinclude, and 
xinclude tags will remain intact.
- allows you to specify the wrapper element of the included content, 
i.e. element="wrapper",
- allows you to wrap included content in a particular namespace: 
ns="wrapper_ns"
- allows you to add prefixes to included content element tags: 
prefix="wrapper_prefix"
- supports Cocoon's caching mechanism

Please cross check. Did I overlook any important points?

-- Diana


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>


RE: [doc] draft FAQ xinclude/cinclude

Posted by Vadim Gritsenko <va...@verizon.net>.
> From: Diana Shannon [mailto:shannon@apache.org]
> 
> Q.
> What are the similarities and differences of xinclude and cinclude?
> 
> A.
> 
> Similarities
> - Both provides mechanisms to include content from other documents
> - Both support cocoon:/ protocol (i.e. they both use Cocoon's
resolver).
> 
> xinclude transformer
> - implements the W3C XInclude spec.
> - allows you to include text or xml content (via parse="text|xml" )
> - allows you to use xpointer syntax(via '#' or xpointer() syntax)
within
> href attribute
> - does *not* support Cocoon's caching mechanism

There are two implementations of cinclude:

 - CIncludeTransformer (used in samples)
 - CachingCIncludeTransformer (not used!)

xinclude has only one implementation.


Hence, better statement would be:
Cinclude does have cacheable implementation (see
CachingCIncludeTransformer), while xinclude has only non-cacheable.


> cinclude transformer
> - helps you serve documents with inclusions and tags in xinclude
> namespace. Thus, you can create document
> with xinclude *and* cinclude tags, process it through cinclude, and
> xinclude tags will remain intact.
> - allows you to specify the wrapper element of the included content,
> i.e. element="wrapper",

 - allows you to (optionally) specify namespace and prefix for the
wrapper element:
 ns="wrapper_ns" prefix="wrapper_prefix"

 - Has cacheable implementation.



PS In some future, we should have one IncludeTransformer with support of
both cinclude and xinclude, and configurable namespace.


Vadim


> Please cross check. Did I overlook any important points?
> 
> -- Diana


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>