We are currently working on ditac 2.2, that's why we have reexamined
your support request. Sorry for this delay.
On 02/08/2012 05:51 PM, Darren Carlton wrote:
> Problem:
> ditac applies the "product" value to all child topicrefs.
>
> Details:
> I have a ditamap that contains the following entries:
> <topicref product="ShowProduct" href=foo.dita">
> <topicref product="HideProduct" href="bar.dita"/>
> </topicref>
>
> My ditaval file contains these entries:
> <prop att="product" val="ShowProduct" action="include"></prop>
> <prop att="product" val="HideProduct" action="exclude"></prop>
>
> I would expect bar.dita to be excluded from the output, but it is included.
>
> If I remove product="ShowProduct" from the parent topicref, bar.dita is
> excluded:
> <topicref href=foo.dita">
> <topicref product="HideProduct" href="bar.dita"/>
> </topicref>
>
> It's almost as if the child topicref inherits the product attribute
> value from the parent. Is this intended behavior?
In fact, yes. The "product" conditional processing attributes is
additive and may inherit some of its values from its ancestors. Thus:
---
<topicref product="ShowProduct" href=foo.dita">
<topicref product="HideProduct" href="bar.dita"/>
</topicref>
---
is equivalent to:
---
<topicref product="ShowProduct" href=foo.dita">
<topicref product="ShowProduct HideProduct" href="bar.dita"/>
</topicref>
---
That's why topic bar.dita is *not* excluded by ditac.
--> See
http://docs.oasis-open.org/dita/v1.2/os/spec/common/select-atts.html#select-atts
---
product
Contains the name of the product to which the element applies. This is a
property attribute which supports conditional processing for filtering
or flagging. If no value is specified, but the attribute is specified on
an ancestor within a map or within the related-links section, the value
will cascade from the closest ancestor. The attribute takes a
space-delimited set of values.
---
--> See
http://docs.oasis-open.org/dita/v1.2/os/spec/archSpec/cascading-in-a-ditamap.html
---
Attributes and metadata that cascade
The following attributes and metadata elements cascade:
Attributes
* @audience, @platform, @product, @otherprops, @rev
...
Cascading is additive for attributes and metadata elements that accept
multiple values. For attributes that take a single value, the closest
value defined on a containing element takes effect.
---
>
>
> Ditac Version:
> ditac: INFO: ditac version is 2.1.0_01
>
> OS used to run ditac:
> Ubuntu 10.10
>
> Java runtime version:
> java version "1.6.0_24"
>
> ditac command-line (launched through ant)
>
> <target name="ditac2javahelp">
> <java classname="com.xmlmind.ditac.convert.Converter"
> fork="true"
> failonerror="true"
> classpathref="maven.dependency.classpath"
> maxmemory="2248m">
> <arg line="-format xhtml"/>
> <arg line="-xslt2 xhtml ${ditac.dir}/ita/xsl/javahelp/ita-javahelp.xsl"/>
> <arg line="-filter ${dita.input.valfile}"/>
> <!-- Ditac stylesheet parameters -->
> <arg line="-p helpset-basename ${application}_helpset.hs -p map-basename
> ${application}_map.jhm"/>
> <arg line="-p toc-basename ${application}.js -p index-basename
> ${application}_index.xml"/>
> <arg line="-p xsl-resources-directory branding -p css-name
> ${application}.css"/>
> <!-- Output File -->
> <arg line="${output.dir}/_.html"/>
> <!-- Input File -->
> <arg line="${args.input}"/>
> <jvmarg
> value="-Djava.util.logging.config.file=${basedir}/tools/fop/logging.properties"/>
> <jvmarg
> value="-Dxml.catalog.files=${ditac.dir}/schema/catalog.xml;${basedir}/tools/${ita.dita.dir}/catalog-dita.xml"/>
> </java>
> </target>
>
>
>
>
> --
> XMLmind DITA Converter Support List
> [email protected]
> http://www.xmlmind.com/mailman/listinfo/ditac-support
--
XMLmind DITA Converter Support List
[email protected]
http://www.xmlmind.com/mailman/listinfo/ditac-support