diff options
Diffstat (limited to 'filter/source/msfilter/powerpoint')
-rw-r--r-- | filter/source/msfilter/powerpoint/makefile.mk | 65 | ||||
-rw-r--r-- | filter/source/msfilter/powerpoint/pptcom.hxx | 76 | ||||
-rw-r--r-- | filter/source/msfilter/powerpoint/pptimporter.cxx | 163 | ||||
-rw-r--r-- | filter/source/msfilter/powerpoint/pptimporter.hxx | 91 | ||||
-rw-r--r-- | filter/source/msfilter/powerpoint/pptimporteruno.cxx | 79 | ||||
-rw-r--r-- | filter/source/msfilter/powerpoint/ppttoxml.cxx | 91 | ||||
-rw-r--r-- | filter/source/msfilter/powerpoint/ppttoxml.hxx | 51 |
7 files changed, 616 insertions, 0 deletions
diff --git a/filter/source/msfilter/powerpoint/makefile.mk b/filter/source/msfilter/powerpoint/makefile.mk new file mode 100644 index 000000000000..0ad3d4202f1f --- /dev/null +++ b/filter/source/msfilter/powerpoint/makefile.mk @@ -0,0 +1,65 @@ +#************************************************************************* +# +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. +# +# Copyright 2000, 2010 Oracle and/or its affiliates. +# +# OpenOffice.org - a multi-platform office productivity suite +# +# This file is part of OpenOffice.org. +# +# OpenOffice.org is free software: you can redistribute it and/or modify +# it under the terms of the GNU Lesser General Public License version 3 +# only, as published by the Free Software Foundation. +# +# OpenOffice.org is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU Lesser General Public License version 3 for more details +# (a copy is included in the LICENSE file that accompanied this code). +# +# You should have received a copy of the GNU Lesser General Public License +# version 3 along with OpenOffice.org. If not, see +# <http://www.openoffice.org/license.html> +# for a copy of the LGPLv3 License. +# +#************************************************************************* + +PRJ=..$/..$/.. +PRJNAME=filter +TARGET=PptImporter + +ENABLE_EXCEPTIONS=TRUE + +# --- Settings ---------------------------------- + +.INCLUDE : settings.mk + +# --- Files ------------------------------------- + +SLOFILES= $(SLO)$/pptimporter.obj \ + $(SLO)$/pptimporteruno.obj \ + $(SLO)$/ppttoxml.obj + +# --- Library ----------------------------------- + +SHL1TARGET=$(TARGET)$(DLLPOSTFIX) +SHL1STDLIBS=\ + $(SOTLIB) \ + $(TOOLSLIB) \ + $(CPPUHELPERLIB) \ + $(CPPULIB) \ + $(SALLIB) + +SHL1DEPN= +SHL1IMPLIB= i$(SHL1TARGET) +SHL1LIBS= $(SLB)$/$(TARGET).lib +SHL1VERSIONMAP=$(SOLARENV)/src/component.map +SHL1DEF= $(MISC)$/$(SHL1TARGET).def + +DEF1NAME=$(SHL1TARGET) + +# --- Targets ---------------------------------- + +.INCLUDE : target.mk + diff --git a/filter/source/msfilter/powerpoint/pptcom.hxx b/filter/source/msfilter/powerpoint/pptcom.hxx new file mode 100644 index 000000000000..64dff7e54b30 --- /dev/null +++ b/filter/source/msfilter/powerpoint/pptcom.hxx @@ -0,0 +1,76 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef _PPTCOM_HXX +#define _PPTCOM_HXX + +#include <rtl/ustring.hxx> +#include <tools/debug.hxx> +#include <tools/stream.hxx> +#include <tools/string.hxx> +#include <tools/urlobj.hxx> +#include <tools/stack.hxx> + +#include <com/sun/star/uno/Reference.h> +#include <com/sun/star/uno/RuntimeException.hpp> +#include <com/sun/star/lang/XMultiServiceFactory.hpp> +#include <com/sun/star/lang/XComponent.hpp> +#include <com/sun/star/registry/XRegistryKey.hpp> +#include <com/sun/star/lang/XComponent.hpp> +#include <com/sun/star/io/XInputStream.hpp> +#include <com/sun/star/xml/sax/XDocumentHandler.hpp> +#include <xmloff/xmlexp.hxx> +#include <xmloff/nmspmap.hxx> +#include <cppuhelper/implbase1.hxx> +#include <cppuhelper/implbase4.hxx> +#include <com/sun/star/document/XFilter.hpp> +#include <com/sun/star/document/XImporter.hpp> +#include <com/sun/star/lang/XInitialization.hpp> +#include <com/sun/star/lang/XServiceInfo.hpp> + +// ----------------------------------------------------------------------------- + +#define NMSP_CPPU cppu +#define NMSP_RTL rtl +#define NMSP_UTL utl +#define NMSP_COMPHELPER comphelper +#define NMSP_UNO com::sun::star::uno +#define NMSP_BEANS com::sun::star::beans +#define NMSP_LANG com::sun::star::lang +#define NMSP_IO com::sun::star::io +#define NMSP_SAX com::sun::star::xml::sax +#define NMSP_PRES com::sun::star::presentation +#define NMSP_REGISTRY com::sun::star::registry +#define NMSP_DOCUMENT com::sun::star::document + + +#define REF( _def_Obj ) NMSP_UNO::Reference< _def_Obj > +#define SEQ( _def_Obj ) NMSP_UNO::Sequence< _def_Obj > +#define ANY NMSP_UNO::Any +#define B2UCONST( _def_pChar ) (NMSP_RTL::OUString(RTL_CONSTASCII_USTRINGPARAM(_def_pChar ))) +#define PPT_DTD_STRING B2UCONST( "<!DOCTYPE office:document-styles PUBLIC \"-//OpenOffice.org//DTD OfficeDocument 1.0//EN\" \"office.dtd\">" +#endif diff --git a/filter/source/msfilter/powerpoint/pptimporter.cxx b/filter/source/msfilter/powerpoint/pptimporter.cxx new file mode 100644 index 000000000000..960987700980 --- /dev/null +++ b/filter/source/msfilter/powerpoint/pptimporter.cxx @@ -0,0 +1,163 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +// MARKER(update_precomp.py): autogen include statement, do not remove +#include "precompiled_filter.hxx" +#include "pptimporter.hxx" + +#ifdef DBG_DUMP_PPT_IMPORT +#ifndef _COM_SUN_STAR_IO_XACTIVEDATASOURCE_HDL_ +#include <com/sun/star/io/XActiveDataSource.hpp> +#endif +#include <unotools/streamwrap.hxx> +#include <comphelper/processfactory.hxx> +#endif + +#include <uno/mapping.hxx> + +// ----------------- +// - PptImporter - +// ----------------- + +NMSP_RTL::OUString PptImporter_getImplementationName() + throw( NMSP_UNO::RuntimeException ) +{ + return B2UCONST( "com.sun.star.presentation.PptImporter" ); +} +#define SERVICE_NAME "com.sun.star.document.ImportFilter" +sal_Bool SAL_CALL PptImporter_supportsService( const NMSP_RTL::OUString& ServiceName ) + throw( NMSP_UNO::RuntimeException ) +{ + return ServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( SERVICE_NAME ) ); +} + +SEQ( NMSP_RTL::OUString ) SAL_CALL PptImporter_getSupportedServiceNames() + throw( NMSP_UNO::RuntimeException ) +{ + SEQ( NMSP_RTL::OUString ) aRet(1); + NMSP_RTL::OUString* pArray = aRet.getArray(); + pArray[0] = B2UCONST( SERVICE_NAME ); + return aRet; +} +#undef SERVICE_NAME + +// ----------------------------------------------------------------------------- + +PptImporter::PptImporter( const REF( NMSP_LANG::XMultiServiceFactory )& rxMgr ) : + xFact( rxMgr ) +{ + NMSP_RTL::OUString sService( B2UCONST( "com.sun.star.comp.Impress.XMLImporter" ) ); + try + { + xHdl = REF( NMSP_SAX::XDocumentHandler ) ( xFact->createInstance( sService ), NMSP_UNO::UNO_QUERY ); + xImporter = REF( NMSP_DOCUMENT::XImporter )( xHdl, NMSP_UNO::UNO_QUERY ); + } + catch( NMSP_UNO::Exception & ) + { + } +} + +// ----------------------------------------------------------------------------- + +PptImporter::~PptImporter() +{ +} + +// ----------------------------------------------------------------------------- + +void SAL_CALL PptImporter::acquire() throw() +{ + OWeakObject::acquire(); +} + +// ----------------------------------------------------------------------------- + +void SAL_CALL PptImporter::release() throw() +{ + OWeakObject::release(); +} + +// XFilter +sal_Bool SAL_CALL PptImporter::filter( const SEQ( NMSP_BEANS::PropertyValue )& aDescriptor ) + throw ( NMSP_UNO::RuntimeException ) +{ + + +#ifdef DBG_DUMP_PPT_IMPORT + + REF( NMSP_LANG::XMultiServiceFactory ) xServiceFactory( NMSP_COMPHELPER::getProcessServiceFactory() ); + REF( NMSP_UNO::XInterface ) xWriter( xServiceFactory->createInstance( B2UCONST( "com.sun.star.xml.sax.Writer" ) ) ); + SvFileStream aStrm( B2UCONST( "d:\\test2.xml" ), STREAM_READ | STREAM_WRITE | STREAM_TRUNC ); + REF( NMSP_IO::XOutputStream ) xOutStream( (::cppu::OWeakObject*) new NMSP_UTL::OOutputStreamWrapper( aStrm ), NMSP_UNO::UNO_QUERY ); + REF( NMSP_IO::XActiveDataSource ) xDataSource( xWriter , NMSP_UNO::UNO_QUERY ); + xDataSource->setOutputStream( xOutStream ); + aFilter.filter( aDescriptor, REF( NMSP_SAX::XDocumentHandler )( xWriter, NMSP_UNO::UNO_QUERY ) ); + +// REF( NMSP_BEANS::XPropertySet ) xPropSet( xServiceFactory->createInstance( B2UCONST( "com.sun.star.beans.PropertySet" ) ) ); +// Any aAny; +// aAny <<= (sal_Bool)sal_True; +// xPropSet->setPropertyValue( B2UCONST( "UsePrettyPrinting" ), aAny ); + +#endif + + return aFilter.filter( aDescriptor, xHdl ); +} +void SAL_CALL PptImporter::cancel() + throw ( NMSP_UNO::RuntimeException ) +{ + aFilter.cancel(); +} + +// XImporter +void SAL_CALL PptImporter::setTargetDocument( const REF( NMSP_LANG::XComponent )& xDoc ) + throw ( NMSP_LANG::IllegalArgumentException, NMSP_UNO::RuntimeException) +{ + xImporter->setTargetDocument( xDoc ); +} + +// XInitialization +void SAL_CALL PptImporter::initialize( const SEQ( NMSP_UNO::Any )& /* aArguments */ ) + throw ( NMSP_UNO::Exception, NMSP_UNO::RuntimeException ) +{ +} + +// XServiceInfo +NMSP_RTL::OUString SAL_CALL PptImporter::getImplementationName() + throw( NMSP_UNO::RuntimeException ) +{ + return PptImporter_getImplementationName(); +} +sal_Bool SAL_CALL PptImporter::supportsService( const NMSP_RTL::OUString& rServiceName ) + throw( NMSP_UNO::RuntimeException ) +{ + return PptImporter_supportsService( rServiceName ); +} +SEQ( NMSP_RTL::OUString ) SAL_CALL PptImporter::getSupportedServiceNames() + throw ( NMSP_UNO::RuntimeException ) +{ + return PptImporter_getSupportedServiceNames(); +} diff --git a/filter/source/msfilter/powerpoint/pptimporter.hxx b/filter/source/msfilter/powerpoint/pptimporter.hxx new file mode 100644 index 000000000000..6366d0fda054 --- /dev/null +++ b/filter/source/msfilter/powerpoint/pptimporter.hxx @@ -0,0 +1,91 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef _PPTIMPORTER_HXX +#define _PPTIMPORTER_HXX + +#include "pptcom.hxx" +#include "ppttoxml.hxx" + +// --------------- +// - PptImporter - +// --------------- + +class PptImporter : public NMSP_CPPU::WeakImplHelper4 +< + NMSP_DOCUMENT::XFilter, + NMSP_DOCUMENT::XImporter, + NMSP_LANG::XInitialization, + NMSP_LANG::XServiceInfo +> +{ + PptToXml aFilter; + REF( NMSP_SAX::XDocumentHandler ) xHdl; + REF( NMSP_LANG::XMultiServiceFactory ) xFact; + REF( NMSP_DOCUMENT::XImporter ) xImporter; + +public: + + PptImporter( const REF( NMSP_LANG::XMultiServiceFactory )& rxMgr ); + virtual ~PptImporter(); + + // XInterface + virtual void SAL_CALL acquire() throw(); + virtual void SAL_CALL release() throw(); + + // XFilter + virtual sal_Bool SAL_CALL filter( const SEQ( NMSP_BEANS::PropertyValue )& aDescriptor ) + throw ( NMSP_UNO::RuntimeException ); + virtual void SAL_CALL cancel( ) + throw ( NMSP_UNO::RuntimeException ); + + // XImporter + virtual void SAL_CALL setTargetDocument( const REF(NMSP_LANG::XComponent)& xDoc ) + throw ( NMSP_LANG::IllegalArgumentException, NMSP_UNO::RuntimeException ); + + // XInitialization + virtual void SAL_CALL initialize( const SEQ( NMSP_UNO::Any )& aArguments ) + throw ( NMSP_UNO::Exception, NMSP_UNO::RuntimeException ); + + // XServiceInfo + virtual NMSP_RTL::OUString SAL_CALL getImplementationName() + throw ( NMSP_UNO::RuntimeException ); + virtual sal_Bool SAL_CALL supportsService( const NMSP_RTL::OUString& ServiceName ) + throw ( NMSP_UNO::RuntimeException ); + virtual SEQ( NMSP_RTL::OUString ) SAL_CALL getSupportedServiceNames() + throw ( NMSP_UNO::RuntimeException ); + +}; + +NMSP_RTL::OUString PptImporter_getImplementationName() + throw ( NMSP_UNO::RuntimeException ); +sal_Bool SAL_CALL PptImportert_supportsService( const NMSP_RTL::OUString& ServiceName ) + throw( NMSP_UNO::RuntimeException ); +SEQ( NMSP_RTL::OUString ) SAL_CALL PptImporter_getSupportedServiceNames() + throw( NMSP_UNO::RuntimeException ); + +#endif diff --git a/filter/source/msfilter/powerpoint/pptimporteruno.cxx b/filter/source/msfilter/powerpoint/pptimporteruno.cxx new file mode 100644 index 000000000000..325d360344cf --- /dev/null +++ b/filter/source/msfilter/powerpoint/pptimporteruno.cxx @@ -0,0 +1,79 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +// MARKER(update_precomp.py): autogen include statement, do not remove +#include "precompiled_filter.hxx" + +#include "pptimporter.hxx" + +#include <cppuhelper/factory.hxx> +#include <uno/mapping.hxx> + +// ------------------- +// - factory methods - +// ------------------- + +static REF( NMSP_UNO::XInterface ) SAL_CALL create_PptImporter( const REF( NMSP_LANG::XMultiServiceFactory )& rxFact ) +{ + return REF( NMSP_UNO::XInterface )( *new PptImporter( rxFact ) ); +} + +// ------------------------------------------ +// - component_getImplementationEnvironment - +// ------------------------------------------ + +extern "C" void SAL_CALL component_getImplementationEnvironment( const sal_Char ** ppEnvTypeName, uno_Environment ** /* ppEnv */ ) +{ + *ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME; +} + +// ------------------------ +// - component_getFactory - +// ------------------------ + +extern "C" void* SAL_CALL component_getFactory( const sal_Char* pImplName, void* pServiceManager, void* /* pRegistryKey */ ) +{ + REF( NMSP_LANG::XSingleServiceFactory ) xFactory; + void* pRet = 0; + + if( rtl_str_compare( pImplName, "com.sun.star.presentation.PptImporter" ) == 0 ) + { + const NMSP_RTL::OUString aServiceName( B2UCONST( "com.sun.star.presentation.PptImporter" ) ); + + xFactory = REF( NMSP_LANG::XSingleServiceFactory )( NMSP_CPPU::createSingleFactory( + reinterpret_cast< NMSP_LANG::XMultiServiceFactory* >( pServiceManager ), + B2UCONST( "com.sun.star.presentation.PptImporter" ), + create_PptImporter, SEQ( NMSP_RTL::OUString )( &aServiceName, 1 ) ) ); + } + if( xFactory.is() ) + { + xFactory->acquire(); + pRet = xFactory.get(); + } + + return pRet; +} diff --git a/filter/source/msfilter/powerpoint/ppttoxml.cxx b/filter/source/msfilter/powerpoint/ppttoxml.cxx new file mode 100644 index 000000000000..d4ec2af93e7b --- /dev/null +++ b/filter/source/msfilter/powerpoint/ppttoxml.cxx @@ -0,0 +1,91 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +// MARKER(update_precomp.py): autogen include statement, do not remove +#include "precompiled_filter.hxx" + +#include "ppttoxml.hxx" +#include <sot/storage.hxx> + +PptToXml::PptToXml() +{ +} + +PptToXml::~PptToXml() +{ +} + +sal_Bool PptToXml::filter( const SEQ( NMSP_BEANS::PropertyValue )& aDescriptor, + REF( NMSP_SAX::XDocumentHandler ) xHandler ) +{ + xHdl = xHandler; + + sal_Bool bStatus = sal_False; + sal_Int32 i; + for( i = 0; i < aDescriptor.getLength(); i++ ) + { + NMSP_RTL::OUString strTemp; + aDescriptor[ i ].Value >>= strTemp; + +/* we will open the document by url, so the stream is not needed + if( aDescriptor[i].Name == B2UCONST( "InputStream" ) ) + { + REF( NMSP_IO::XInputStream ) rInputStream; + aDescriptor[ i].Value >>= rInputStream; + } + else +*/ + if ( aDescriptor[ i ].Name == B2UCONST( "URL" ) ) + { + NMSP_RTL::OUString sURL; + aDescriptor[ i ].Value >>= sURL; + SotStorageRef xStg( new SotStorage( sURL, STREAM_STD_READ, 0 ) ); + if ( xStg.Is() ) + { + SotStorageStreamRef xDocStream( xStg->OpenSotStream( B2UCONST( "PowerPoint Document" ), STREAM_STD_READ ) ); + if( xDocStream.Is() ) + { + xDocStream->SetVersion( xStg->GetVersion() ); + xDocStream->SetKey( xStg->GetKey() ); + +// xHdl->unknown( PPT_DTD_STRING ); + xHdl->startDocument(); + + + xHdl->endDocument(); + bStatus = sal_True; + } + } + } + } + return bStatus; +} + +void PptToXml::cancel() +{ + +} diff --git a/filter/source/msfilter/powerpoint/ppttoxml.hxx b/filter/source/msfilter/powerpoint/ppttoxml.hxx new file mode 100644 index 000000000000..b77f85b0109b --- /dev/null +++ b/filter/source/msfilter/powerpoint/ppttoxml.hxx @@ -0,0 +1,51 @@ +/************************************************************************* + * + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. + * + * Copyright 2000, 2010 Oracle and/or its affiliates. + * + * OpenOffice.org - a multi-platform office productivity suite + * + * This file is part of OpenOffice.org. + * + * OpenOffice.org is free software: you can redistribute it and/or modify + * it under the terms of the GNU Lesser General Public License version 3 + * only, as published by the Free Software Foundation. + * + * OpenOffice.org is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Lesser General Public License version 3 for more details + * (a copy is included in the LICENSE file that accompanied this code). + * + * You should have received a copy of the GNU Lesser General Public License + * version 3 along with OpenOffice.org. If not, see + * <http://www.openoffice.org/license.html> + * for a copy of the LGPLv3 License. + * + ************************************************************************/ + +#ifndef _PPTTOXML_HXX +#define _PPTTOXML_HXX + +#include "pptcom.hxx" + +// ------------ +// - PptToXml - +// ------------ + +class PptToXml +{ + REF( NMSP_SAX::XDocumentHandler ) xHdl; + + public: + + PptToXml(); + ~PptToXml(); + + sal_Bool filter( const SEQ( NMSP_BEANS::PropertyValue )& aDescriptor, + REF(NMSP_SAX::XDocumentHandler) xHandler ); + void cancel(); +}; + +#endif |