X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;ds=sidebyside;f=src%2Ffilter_record_transform.cpp;h=221a609e59c3c3b0a11fc8c0f898c2ac5237c738;hb=b8550b672196ca7e6fe11a8cba7155beb8794286;hp=f95d0404385038252d3087a5091b160bd3b3d510;hpb=c1d953eee6c00432493bc364da6284704ccd9cc2;p=metaproxy-moved-to-github.git diff --git a/src/filter_record_transform.cpp b/src/filter_record_transform.cpp index f95d040..221a609 100644 --- a/src/filter_record_transform.cpp +++ b/src/filter_record_transform.cpp @@ -1,5 +1,5 @@ /* This file is part of Metaproxy. - Copyright (C) 2005-2011 Index Data + Copyright (C) 2005-2012 Index Data Metaproxy is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free @@ -39,7 +39,7 @@ namespace metaproxy_1 { Impl(); ~Impl(); void process(metaproxy_1::Package & package) const; - void configure(const xmlNode * xml_node); + void configure(const xmlNode * xml_node, const char *path); private: yaz_retrieval_t m_retrieval; }; @@ -56,9 +56,10 @@ yf::RecordTransform::~RecordTransform() { // must have a destructor because of boost::scoped_ptr } -void yf::RecordTransform::configure(const xmlNode *xmlnode, bool test_only) +void yf::RecordTransform::configure(const xmlNode *xmlnode, bool test_only, + const char *path) { - m_p->configure(xmlnode); + m_p->configure(xmlnode, path); } void yf::RecordTransform::process(mp::Package &package) const @@ -83,11 +84,10 @@ yf::RecordTransform::Impl::~Impl() yaz_retrieval_destroy(m_retrieval); } -void yf::RecordTransform::Impl::configure(const xmlNode *xml_node) +void yf::RecordTransform::Impl::configure(const xmlNode *xml_node, + const char *path) { - //const char *srcdir = getenv("srcdir"); - //if (srcdir) - // yaz_retrieval_set_path(m_retrieval, srcdir); + yaz_retrieval_set_path(m_retrieval, path); if (!xml_node) throw mp::XMLError("RecordTransform filter config: empty XML DOM");