summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorMatúš Kukan <matus.kukan@gmail.com>2012-01-11 20:44:49 +0100
committerMatúš Kukan <matus.kukan@gmail.com>2012-01-11 20:44:49 +0100
commit0482c914c7480dcc3bcf739e19d8372ea3fad35c (patch)
tree38d8954a13f9d5b838d70667bccf29acd6a3b724 /extensions
parent134803653fecd62f64bb063df6b48713626e94b7 (diff)
extensions: remove unused xmx library
Diffstat (limited to 'extensions')
-rw-r--r--extensions/Library_xmx.mk54
-rw-r--r--extensions/Module_extensions.mk1
-rw-r--r--extensions/source/xmlextract/xmx.component34
-rw-r--r--extensions/source/xmlextract/xmxcom.hxx62
-rw-r--r--extensions/source/xmlextract/xmxtrct.cxx198
-rw-r--r--extensions/source/xmlextract/xmxtrct.hxx57
-rw-r--r--extensions/source/xmlextract/xmxuno.cxx73
7 files changed, 0 insertions, 479 deletions
diff --git a/extensions/Library_xmx.mk b/extensions/Library_xmx.mk
deleted file mode 100644
index dfef71dd21dd..000000000000
--- a/extensions/Library_xmx.mk
+++ /dev/null
@@ -1,54 +0,0 @@
-# -*- Mode: makefile; tab-width: 4; indent-tabs-mode: t -*-
-#
-# Version: MPL 1.1 / GPLv3+ / LGPLv3+
-#
-# The contents of this file are subject to the Mozilla Public License Version
-# 1.1 (the "License"); you may not use this file except in compliance with
-# the License or as specified alternatively below. You may obtain a copy of
-# the License at http://www.mozilla.org/MPL/
-#
-# Software distributed under the License is distributed on an "AS IS" basis,
-# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
-# for the specific language governing rights and limitations under the
-# License.
-#
-# The Initial Developer of the Original Code is
-# Peter Foley <pefoley2@verizon.net>
-# Portions created by the Initial Developer are Copyright (C) 2011 the
-# Initial Developer. All Rights Reserved.
-#
-# Major Contributor(s):
-#
-# For minor contributions see the git repository.
-#
-# Alternatively, the contents of this file may be used under the terms of
-# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
-# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
-# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
-# instead of those above.
-#
-
-$(eval $(call gb_Library_Library,xmx))
-
-$(eval $(call gb_Library_set_componentfile,xmx,extensions/source/xmlextract/xmx))
-
-$(eval $(call gb_Library_add_api,xmx,\
- offapi \
- udkapi \
-))
-
-$(eval $(call gb_Library_add_exception_objects,xmx,\
- extensions/source/xmlextract/xmxtrct \
- extensions/source/xmlextract/xmxuno \
-))
-
-$(eval $(call gb_Library_add_linked_libs,xmx,\
- sot \
- utl \
- tl \
- cppuhelper \
- cppu \
- sal \
-))
-
-# vim:set shiftwidth=4 softtabstop=4 expandtab:
diff --git a/extensions/Module_extensions.mk b/extensions/Module_extensions.mk
index f63e31a0bb02..9719f2b79305 100644
--- a/extensions/Module_extensions.mk
+++ b/extensions/Module_extensions.mk
@@ -46,7 +46,6 @@ $(eval $(call gb_Module_add_targets,extensions,\
Library_updatecheckui \
Library_updatefeed \
Library_updchk \
- Library_xmx \
Package_bib \
Package_pcr \
))
diff --git a/extensions/source/xmlextract/xmx.component b/extensions/source/xmlextract/xmx.component
deleted file mode 100644
index 456ff33b6c06..000000000000
--- a/extensions/source/xmlextract/xmx.component
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--**********************************************************************
-*
-* 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.
-*
-**********************************************************************-->
-
-<component loader="com.sun.star.loader.SharedLibrary"
- xmlns="http://openoffice.org/2010/uno-components">
- <implementation name="com.sun.star.comp.io.XMLExtractor">
- <service name="com.sun.star.io.XMLExtractor"/>
- </implementation>
-</component>
diff --git a/extensions/source/xmlextract/xmxcom.hxx b/extensions/source/xmlextract/xmxcom.hxx
deleted file mode 100644
index da634b2bdce2..000000000000
--- a/extensions/source/xmlextract/xmxcom.hxx
+++ /dev/null
@@ -1,62 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*************************************************************************
- *
- * 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 _XMXCOM_HXX
-#define _XMXCOM_HXX
-
-#include <cppuhelper/weak.hxx>
-#include <rtl/ustring.hxx>
-#include <tools/stream.hxx>
-#include <cppuhelper/implbase1.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/registry/XRegistryKey.hpp>
-#include <com/sun/star/lang/XComponent.hpp>
-#include <com/sun/star/io/XInputStream.hpp>
-#include <com/sun/star/io/XXMLExtractor.hpp>
-
-// -----------------------------------------------------------------------------
-
-#define NMSP_CPPU ::cppu
-#define NMSP_RTL ::rtl
-#define NMSP_UNO ::com::sun::star::uno
-#define NMSP_LANG ::com::sun::star::lang
-#define NMSP_IO ::com::sun::star::io
-#define NMSP_REGISTRY ::com::sun::star::registry
-
-
-#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 )))
-
-#endif // _XMXCOM_HXX
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/extensions/source/xmlextract/xmxtrct.cxx b/extensions/source/xmlextract/xmxtrct.cxx
deleted file mode 100644
index 62abbea74899..000000000000
--- a/extensions/source/xmlextract/xmxtrct.cxx
+++ /dev/null
@@ -1,198 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*************************************************************************
- *
- * 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.
- *
- ************************************************************************/
-
-
-#include "xmxtrct.hxx"
-
-#include <rtl/memory.h>
-#include <tools/zcodec.hxx>
-#include <unotools/streamhelper.hxx>
-#include <sot/storage.hxx>
-
-// ----------------
-// - XMXLockBytes -
-// ----------------
-
-class XMXLockBytes : public SvLockBytes
-{
- REF( NMSP_IO::XInputStream ) mxIStm;
- SEQ( sal_Int8 ) maSeq;
-
- XMXLockBytes();
-
-public:
-
- XMXLockBytes( const REF( NMSP_IO::XInputStream )& rxIStm );
- virtual ~XMXLockBytes();
-
- virtual ErrCode ReadAt( sal_Size nPos, void* pBuffer, sal_Size nCount, sal_Size* pRead ) const;
- virtual ErrCode WriteAt( sal_Size nPos, const void* pBuffer, sal_Size nCount, sal_Size* pWritten );
- virtual ErrCode Flush() const;
- virtual ErrCode SetSize( sal_Size nSize );
- virtual ErrCode Stat( SvLockBytesStat*, SvLockBytesStatFlag ) const;
-};
-
-// ------------------------------------------------------------------------
-
-XMXLockBytes::XMXLockBytes( const REF( NMSP_IO::XInputStream )& rxIStm ) :
- mxIStm( rxIStm )
-{
- if( mxIStm.is() )
- {
- const sal_uInt32 nBytesToRead = 65535;
- sal_uInt32 nRead;
-
- do
- {
- SEQ( sal_Int8 ) aReadSeq;
-
- nRead = mxIStm->readSomeBytes( aReadSeq, nBytesToRead );
-
- if( nRead )
- {
- const sal_uInt32 nOldLength = maSeq.getLength();
- maSeq.realloc( nOldLength + nRead );
- rtl_copyMemory( maSeq.getArray() + nOldLength, aReadSeq.getConstArray(), aReadSeq.getLength() );
- }
- }
- while( nBytesToRead == nRead );
- }
-}
-
-// ------------------------------------------------------------------------
-
-XMXLockBytes::~XMXLockBytes()
-{
-}
-
-// ------------------------------------------------------------------------
-
-ErrCode XMXLockBytes::ReadAt( sal_Size nPos, void* pBuffer, sal_Size nCount, sal_Size* pRead ) const
-{
- const sal_Size nSeqLen = maSeq.getLength();
- ErrCode nErr = ERRCODE_NONE;
-
- if( nPos < nSeqLen )
- {
- if( ( nPos + nCount ) > nSeqLen )
- nCount = nSeqLen - nPos;
-
- rtl_copyMemory( pBuffer, maSeq.getConstArray() + nPos, nCount );
- *pRead = nCount;
- }
- else
- *pRead = 0UL;
-
- return nErr;
-}
-
-// ------------------------------------------------------------------------
-
-ErrCode XMXLockBytes::WriteAt( sal_Size /*nPos*/, const void* /*pBuffer*/, sal_Size /*nCount*/, sal_Size* /*pWritten*/ )
-{
- return ERRCODE_IO_CANTWRITE;
-}
-
-// ------------------------------------------------------------------------
-
-ErrCode XMXLockBytes::Flush() const
-{
- return ERRCODE_NONE;
-}
-
-// ------------------------------------------------------------------------
-
-ErrCode XMXLockBytes::SetSize( sal_Size /*nSize*/ )
-{
- return ERRCODE_IO_CANTWRITE;
-}
-
-// ------------------------------------------------------------------------
-
-ErrCode XMXLockBytes::Stat( SvLockBytesStat* pStat, SvLockBytesStatFlag /*eFlag*/ ) const
-{
- pStat->nSize = maSeq.getLength();
- return ERRCODE_NONE;
-}
-
-// ----------------
-// - XMLExtractor -
-// ----------------
-
-XMLExtractor::XMLExtractor( const REF( NMSP_LANG::XMultiServiceFactory )& rxMgr ) :
- mxFact( rxMgr )
-{
-}
-
-// -----------------------------------------------------------------------------
-
-XMLExtractor::~XMLExtractor()
-{
-}
-
-// -----------------------------------------------------------------------------
-
-REF( NMSP_IO::XInputStream ) SAL_CALL XMLExtractor::extract( const REF( NMSP_IO::XInputStream )& rxIStm ) throw( NMSP_UNO::RuntimeException )
-{
- REF( NMSP_IO::XInputStream ) xRet;
-
- if( rxIStm.is() )
- {
- SvStream aIStm( new XMXLockBytes( rxIStm ) );
- SvStorageRef aStorage( new SvStorage( aIStm ) );
- String aStmName;
- const String aFormat1( String::CreateFromAscii( "XMLFormat" ) );
- const String aFormat2( String::CreateFromAscii( "XMLFormat2" ) );
-
- if( aStorage->IsContained( aFormat2 ) )
- aStmName = aFormat2;
- else if( aStorage->IsContained( aFormat1 ) )
- aStmName = aFormat1;
-
- if( !aStorage->GetError() && aStmName.Len() && aStorage->IsStream( aStmName ) )
- {
- SvStorageStreamRef xStream( aStorage->OpenSotStream( aStmName ) );
-
- if( xStream.Is() )
- {
- SvMemoryStream* pMemStm = new SvMemoryStream( 65535, 65535 );
- ZCodec aCodec;
-
- aCodec.BeginCompression( ZCODEC_BEST_COMPRESSION );
- aCodec.Decompress( *xStream, *pMemStm );
- aCodec.EndCompression();
-
- xRet = new ::utl::OInputStreamHelper( new SvLockBytes( pMemStm, sal_True ), 65535 );
- }
- }
- }
-
- return xRet;
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/extensions/source/xmlextract/xmxtrct.hxx b/extensions/source/xmlextract/xmxtrct.hxx
deleted file mode 100644
index 264609b8d6a7..000000000000
--- a/extensions/source/xmlextract/xmxtrct.hxx
+++ /dev/null
@@ -1,57 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*************************************************************************
- *
- * 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 _XMXTRCT_HXX
-#define _XMXTRCT_HXX
-
-#include "xmxcom.hxx"
-
-// ----------------
-// - XMLExtractor -
-// ----------------
-
-class XMLExtractor : public ::cppu::WeakImplHelper1< NMSP_IO::XXMLExtractor >
-{
-private:
-
- REF( NMSP_LANG::XMultiServiceFactory ) mxFact;
-
- XMLExtractor();
-
-public:
-
- XMLExtractor( const REF( NMSP_LANG::XMultiServiceFactory )& rxMgr );
- virtual ~XMLExtractor();
-
- // XXMLExtractor
- virtual REF( NMSP_IO::XInputStream ) SAL_CALL extract( const REF( NMSP_IO::XInputStream )& rxIStm ) throw( NMSP_UNO::RuntimeException );
-};
-
-#endif
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/extensions/source/xmlextract/xmxuno.cxx b/extensions/source/xmlextract/xmxuno.cxx
deleted file mode 100644
index e399cd485c83..000000000000
--- a/extensions/source/xmlextract/xmxuno.cxx
+++ /dev/null
@@ -1,73 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*************************************************************************
- *
- * 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.
- *
- ************************************************************************/
-
-
-#include "xmxcom.hxx"
-#include "xmxtrct.hxx"
-#include <osl/diagnose.h>
-#include <cppuhelper/factory.hxx>
-#include <uno/mapping.hxx>
-
-// -------------------
-// - factory methods -
-// -------------------
-
-static REF( NMSP_UNO::XInterface ) SAL_CALL create_XMLExtractor( const REF( NMSP_LANG::XMultiServiceFactory )& rxFact )
-{
- return REF( NMSP_UNO::XInterface )( *new XMLExtractor( rxFact ) );
-}
-
-extern "C"
-{
-SAL_DLLPUBLIC_EXPORT void * SAL_CALL component_getFactory(
- const sal_Char * pImplName, void * pServiceManager, void * /*pRegistryKey*/ )
-{
- void * pRet = 0;
-
- if (rtl_str_compare( pImplName, "com.sun.star.comp.io.XMLExtractor" ) == 0)
- {
- NMSP_RTL::OUString aServiceName( B2UCONST( "com.sum.star.io.XMLExtractor" ) );
-
- REF( NMSP_LANG::XSingleServiceFactory ) xFactory( NMSP_CPPU::createSingleFactory(
- reinterpret_cast< NMSP_LANG::XMultiServiceFactory * >( pServiceManager ),
- NMSP_RTL::OUString( RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.io.XMLExtractor") ),
- create_XMLExtractor,
- SEQ( NMSP_RTL::OUString )( &aServiceName, 1 ) ) );
-
- if (xFactory.is())
- {
- xFactory->acquire();
- pRet = xFactory.get();
- }
- }
-
- return pRet;
-}
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */