#98489# Corrections to updating and formatting

This commit is contained in:
Jörg Barfurth 2002-07-11 16:23:02 +00:00
parent 2f5a7b2368
commit 61fabac721
5 changed files with 25 additions and 26 deletions

View file

@ -2,9 +2,9 @@
*
* $RCSfile: basicparser.hxx,v $
*
* $Revision: 1.3 $
* $Revision: 1.4 $
*
* last change: $Author: jb $ $Date: 2002-07-03 14:07:19 $
* last change: $Author: jb $ $Date: 2002-07-11 17:23:01 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@ -65,9 +65,13 @@
#ifndef CONFIGMGR_XML_ELEMENTPARSER_HXX
#include "elementparser.hxx"
#endif
#ifndef CONFIGMGR_UTILITY_HXX_
#include "utility.hxx"
#endif
#ifndef CONFIGMGR_STACK_HXX_
#include "stack.hxx"
#endif
#ifndef _COM_SUN_STAR_XML_SAX_XDOCUMENTHANDLER_HPP_
#include <com/sun/star/xml/sax/XDocumentHandler.hpp>
@ -77,11 +81,6 @@
#include <cppuhelper/implbase1.hxx>
#endif
#ifndef INCLUDED_STACK
#include <stack>
#define INCLUDED_STACK
#endif
namespace configmgr
{
// -----------------------------------------------------------------------------
@ -106,7 +105,7 @@ namespace configmgr
uno::Reference< uno::XInterface > m_xTypeConverter;
uno::Reference< sax::XLocator > m_xLocator;
ElementParser m_aDataParser;
std::stack< ElementInfo > m_aNodes;
Stack< ElementInfo > m_aNodes;
uno::Type m_aValueType;
ValueData * m_pValueData;
sal_uInt16 m_nSkipLevels;

View file

@ -2,9 +2,9 @@
*
* $RCSfile: elementformatter.cxx,v $
*
* $Revision: 1.4 $
* $Revision: 1.5 $
*
* last change: $Author: jb $ $Date: 2002-07-03 14:07:20 $
* last change: $Author: jb $ $Date: 2002-07-11 17:23:01 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@ -205,7 +205,7 @@ void ElementFormatter::addOperation(Operation::Enum _eOp)
switch (_eOp)
{
case Operation::none: break;
case Operation::modify: addAttribute(ATTR_OPERATION, static_cast<OUString const &>(OPERATION_MODIFY)); break;
case Operation::modify: break ; //addAttribute(ATTR_OPERATION, static_cast<OUString const &>(OPERATION_MODIFY)); break;
case Operation::replace: addAttribute(ATTR_OPERATION, static_cast<OUString const &>(OPERATION_REPLACE)); break;
case Operation::remove: addAttribute(ATTR_OPERATION, static_cast<OUString const &>(OPERATION_REMOVE)); break;

View file

@ -2,9 +2,9 @@
*
* $RCSfile: layerwriter.cxx,v $
*
* $Revision: 1.3 $
* $Revision: 1.4 $
*
* last change: $Author: jb $ $Date: 2002-07-03 14:07:24 $
* last change: $Author: jb $ $Date: 2002-07-11 17:23:01 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@ -306,7 +306,7 @@ void LayerWriter::raiseIllegalTypeException(sal_Char const * pMsg)
bool LayerWriter::isInElement() const
{
return m_aTagStack.empty();
return !m_aTagStack.empty();
}
// -----------------------------------------------------------------------------
@ -334,6 +334,7 @@ void LayerWriter::startNode()
{
OUString sTag = m_aFormatter.getElementTag();
getWriteHandler()->startElement(sTag,m_aFormatter.getElementAttributes());
getWriteHandler()->ignorableWhitespace(OUString());
m_aTagStack.push(sTag);
}
// -----------------------------------------------------------------------------

View file

@ -2,9 +2,9 @@
*
* $RCSfile: layerwriter.hxx,v $
*
* $Revision: 1.4 $
* $Revision: 1.5 $
*
* last change: $Author: jb $ $Date: 2002-07-03 14:07:25 $
* last change: $Author: jb $ $Date: 2002-07-11 17:23:01 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@ -70,13 +70,12 @@
#include "elementformatter.hxx"
#endif
#include <drafts/com/sun/star/configuration/backend/XLayerHandler.hpp>
#ifndef INCLUDED_STACK
#include <stack>
#define INCLUDED_STACK
#ifndef CONFIGMGR_STACK_HXX_
#include "stack.hxx"
#endif
#include <drafts/com/sun/star/configuration/backend/XLayerHandler.hpp>
namespace configmgr
{
// -----------------------------------------------------------------------------
@ -172,7 +171,7 @@ namespace configmgr
void raiseMalformedDataException(sal_Char const * pMsg);
void raiseIllegalTypeException(sal_Char const * pMsg);
private:
typedef std::stack< OUString > TagStack;
typedef Stack< OUString > TagStack;
uno::Reference< uno::XInterface > m_xTCV;
TagStack m_aTagStack;
ElementFormatter m_aFormatter;

View file

@ -2,9 +2,9 @@
*
* $RCSfile: valueformatter.cxx,v $
*
* $Revision: 1.1 $
* $Revision: 1.2 $
*
* last change: $Author: jb $ $Date: 2002-05-28 15:42:24 $
* last change: $Author: jb $ $Date: 2002-07-11 17:23:02 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@ -495,11 +495,11 @@ OUString ValueFormatter::getContent(TypeConverter const & _xTCV) const
{
if (this->isList())
{
aResult = formatSimpleValue(m_aValue, _xTCV);
aResult = formatSequenceValue(m_aValue, m_sSeparator, _xTCV);
}
else
{
aResult = formatSequenceValue(m_aValue, m_sSeparator, _xTCV);
aResult = formatSimpleValue(m_aValue, _xTCV);
}
}
catch (script::CannotConvertException& cce)