aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAdrian Kummerlaender2014-08-16 23:30:36 +0200
committerAdrian Kummerlaender2014-08-16 23:30:36 +0200
commitf6ff54c492df81018cf48da039ee681508f88e46 (patch)
tree0659e0f5bf4529b8c83bebc87119607638f98b7f /test
parent7f6611cded8c1591f1aa1a4c7d70505cb21e7967 (diff)
downloadInputXSLT-f6ff54c492df81018cf48da039ee681508f88e46.tar
InputXSLT-f6ff54c492df81018cf48da039ee681508f88e46.tar.gz
InputXSLT-f6ff54c492df81018cf48da039ee681508f88e46.tar.bz2
InputXSLT-f6ff54c492df81018cf48da039ee681508f88e46.tar.lz
InputXSLT-f6ff54c492df81018cf48da039ee681508f88e46.tar.xz
InputXSLT-f6ff54c492df81018cf48da039ee681508f88e46.tar.zst
InputXSLT-f6ff54c492df81018cf48da039ee681508f88e46.zip
Implemented primitive optional parameter support for external functions
* renamed FunctionExternalTextFormatter into FunctionExternalCommand ** the goal is to provide a general interface to a variety of external commands *** e.g. not just text formatters but system utilities for file management and so on ** this requires the stdin parameter to be optional as not all external commands require stdin input * implemented "filter_derived" helper template to determine amount of optional parameters ** optional parameters are defined as "boost::optional" specializations *** they in turn can be detected by checking if "boost::optional_detail::optional_tag" is a base class * "callConstructDocument" member method of "FunctionBase" performs additional bounds checking of parameter vector * "boost::optional<std::string>" specific member overload was added to "XObjectValue" helper class ** we will have to provide full specializations for all optional types as C++ prohibits partial member function template specialization * renamed the external function in "PlattformGuard" * changed README.md and test cases accordingly
Diffstat (limited to 'test')
-rw-r--r--test/external_text_formatter/reference.xml2
-rw-r--r--test/external_text_formatter/transformation.xsl2
2 files changed, 2 insertions, 2 deletions
diff --git a/test/external_text_formatter/reference.xml b/test/external_text_formatter/reference.xml
index a98b3d8..b7ae62f 100644
--- a/test/external_text_formatter/reference.xml
+++ b/test/external_text_formatter/reference.xml
@@ -4,7 +4,7 @@
<p>
<strong>Lorem ipsum</strong> dolor sit amet, <em>consectetur</em> adipisicing elit, sed do <code>eiusmod</code> tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.</p>
<blockquote>
- <p>Duis aute irure dolor in reprehenderit in voluptate
+<p>Duis aute irure dolor in reprehenderit in voluptate
velit esse cillum dolore eu fugiat nulla pariatur.</p>
</blockquote>
<p>Excepteur sint <strong>occaecat</strong> cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p>
diff --git a/test/external_text_formatter/transformation.xsl b/test/external_text_formatter/transformation.xsl
index aa9a300..c6f11fc 100644
--- a/test/external_text_formatter/transformation.xsl
+++ b/test/external_text_formatter/transformation.xsl
@@ -16,7 +16,7 @@
<xsl:variable name="content" select="InputXSLT:read-file($file)/text()"/>
- <xsl:copy-of select="InputXSLT:external-text-formatter(
+ <xsl:copy-of select="InputXSLT:external-command(
$format,
$content
)"/>