diff options
author | Kai Sommerfeld <kso@openoffice.org> | 2001-06-13 15:42:16 +0000 |
---|---|---|
committer | Kai Sommerfeld <kso@openoffice.org> | 2001-06-13 15:42:16 +0000 |
commit | 22a226e70e14830a5e87801e3e3b169fd7fe1d8a (patch) | |
tree | d970e4fd4e23756f8d8bb191e1c672b2f789a3d9 /ucb | |
parent | acaaa79b6223a7b564855e17bd86ec6f38846834 (diff) |
#86708# - Removed support for command "split".
Diffstat (limited to 'ucb')
-rw-r--r-- | ucb/source/ucp/package/pkgcontent.cxx | 57 | ||||
-rw-r--r-- | ucb/source/ucp/package/pkgcontent.hxx | 11 | ||||
-rw-r--r-- | ucb/source/ucp/package/pkgcontentcaps.cxx | 217 | ||||
-rw-r--r-- | ucb/source/ucp/package/ucppkg.xml | 2 |
4 files changed, 69 insertions, 218 deletions
diff --git a/ucb/source/ucp/package/pkgcontent.cxx b/ucb/source/ucp/package/pkgcontent.cxx index f708469aa33b..6d1a2223bd6d 100644 --- a/ucb/source/ucp/package/pkgcontent.cxx +++ b/ucb/source/ucp/package/pkgcontent.cxx @@ -2,9 +2,9 @@ * * $RCSfile: pkgcontent.cxx,v $ * - * $Revision: 1.29 $ + * $Revision: 1.30 $ * - * last change: $Author: kso $ $Date: 2001-06-13 12:51:46 $ + * last change: $Author: kso $ $Date: 2001-06-13 16:42:16 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -91,9 +91,6 @@ #ifndef _COM_SUN_STAR_IO_XOUTPUTSTREAM_HPP_ #include <com/sun/star/io/XOutputStream.hpp> #endif -#ifndef _COM_SUN_STAR_PACKAGES_XPACKAGESPLITTER_HPP_ -#include <com/sun/star/packages/XPackageSplitter.hpp> -#endif #ifndef _COM_SUN_STAR_SDBC_XROW_HPP_ #include <com/sun/star/sdbc/XRow.hpp> #endif @@ -115,9 +112,6 @@ #ifndef _COM_SUN_STAR_UCB_INSERTCOMMANDARGUMENT_HPP_ #include <com/sun/star/ucb/InsertCommandArgument.hpp> #endif -#ifndef _COM_SUN_STAR_UCB_SPLITCOMMANDARGUMENT_HPP_ -#include <com/sun/star/ucb/SplitCommandArgument.hpp> -#endif #ifndef _COM_SUN_STAR_UCB_TRANSFERINFO_HPP_ #include <com/sun/star/ucb/TransferInfo.hpp> #endif @@ -609,29 +603,6 @@ Any SAL_CALL Content::execute( const Command& aCommand, flushData(); } - else if ( aCommand.Name.compareToAscii( "split" ) == 0 ) - { - ////////////////////////////////////////////////////////////////// - // split - // ( Only available at root folder content ) - ////////////////////////////////////////////////////////////////// - - star::ucb::SplitCommandArgument aArg; - if ( !( aCommand.Argument >>= aArg ) ) - { - OSL_ENSURE( sal_False, - "Content::execute - invalid parameter!" ); - throw star::ucb::CommandAbortedException(); - } - - uno::Sequence< rtl::OUString > aSegments; - split( aArg, Environment, aSegments ); - - if ( aSegments.getLength() == 0 ) - throw star::ucb::CommandAbortedException(); - - aRet <<= aSegments; - } else { ////////////////////////////////////////////////////////////////// @@ -1739,30 +1710,6 @@ void Content::transfer( const TransferInfo& rInfo, } //========================================================================= -void Content::split( const star::ucb::SplitCommandArgument& rArg, - const uno::Reference< - star::ucb::XCommandEnvironment > & xEnv, - uno::Sequence< rtl::OUString > & rResult ) - throw( uno::Exception ) -{ - osl::Guard< osl::Mutex > aGuard( m_aMutex ); - - uno::Reference< container::XHierarchicalNameAccess > xNA = getPackage(); - if ( !xNA.is() ) - return; - - uno::Reference< packages::XPackageSplitter > xSplitter( - xNA, uno::UNO_QUERY ); - OSL_ENSURE( xSplitter.is(), - "Content::split - Got no XPackageSplitter interface!" ); - - if ( xSplitter.is() ) - rResult = xSplitter->split( rArg.SegmentSize, - rArg.TargetFolderURL, - rArg.SegmentNamePrefix ); -} - -//========================================================================= sal_Bool Content::exchangeIdentity( const Reference< XContentIdentifier >& xNewId ) { diff --git a/ucb/source/ucp/package/pkgcontent.hxx b/ucb/source/ucp/package/pkgcontent.hxx index 4e3f70c67f48..0b8360e39f7e 100644 --- a/ucb/source/ucp/package/pkgcontent.hxx +++ b/ucb/source/ucp/package/pkgcontent.hxx @@ -2,9 +2,9 @@ * * $RCSfile: pkgcontent.hxx,v $ * - * $Revision: 1.17 $ + * $Revision: 1.18 $ * - * last change: $Author: kso $ $Date: 2001-06-13 12:51:46 $ + * last change: $Author: kso $ $Date: 2001-06-13 16:42:16 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -104,7 +104,6 @@ namespace com { namespace sun { namespace star { namespace ucb { struct OpenCommandArgument2; - struct SplitCommandArgument; struct TransferInfo; } } } } @@ -273,12 +272,6 @@ private: ::com::sun::star::ucb::InteractiveBadTransferURLException ); - void split( const ::com::sun::star::ucb::SplitCommandArgument& rArg, - const ::com::sun::star::uno::Reference< - ::com::sun::star::ucb::XCommandEnvironment > & xEnv, - ::com::sun::star::uno::Sequence< ::rtl::OUString > & rResult ) - throw( ::com::sun::star::uno::Exception ); - ::com::sun::star::uno::Reference< ::com::sun::star::io::XInputStream > getInputStream(); diff --git a/ucb/source/ucp/package/pkgcontentcaps.cxx b/ucb/source/ucp/package/pkgcontentcaps.cxx index 24012572ce8c..ba18cbe283c4 100644 --- a/ucb/source/ucp/package/pkgcontentcaps.cxx +++ b/ucb/source/ucp/package/pkgcontentcaps.cxx @@ -2,9 +2,9 @@ * * $RCSfile: pkgcontentcaps.cxx,v $ * - * $Revision: 1.11 $ + * $Revision: 1.12 $ * - * last change: $Author: kso $ $Date: 2001-06-13 13:18:13 $ + * last change: $Author: kso $ $Date: 2001-06-13 16:42:16 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -86,7 +86,6 @@ open x x transfer x flush x - split x (root folder only) *************************************************************************/ @@ -105,9 +104,6 @@ #ifndef _COM_SUN_STAR_UCB_OPENCOMMANDARGUMENT2_HPP_ #include <com/sun/star/ucb/OpenCommandArgument2.hpp> #endif -#ifndef _COM_SUN_STAR_UCB_SPLITCOMMANDARGUMENT_HPP_ -#include <com/sun/star/ucb/SplitCommandArgument.hpp> -#endif #ifndef _COM_SUN_STAR_UCB_TRANSFERINFO_HPP_ #include <com/sun/star/ucb/TransferInfo.hpp> #endif @@ -340,155 +336,72 @@ Sequence< CommandInfo > Content::getCommands( if ( isFolder() ) { - if ( m_aUri.getPath().compareToAscii( "/" ) == 0 ) - { - //============================================================= - // - // Root Folder: Supported commands - // - //============================================================= - - static CommandInfo aRootFolderCommandInfoTable[] = - { - /////////////////////////////////////////////////////////// - // Required commands - /////////////////////////////////////////////////////////// - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "getCommandInfo" ) ), - -1, - getCppuVoidType() - ), - CommandInfo( - OUString( - RTL_CONSTASCII_USTRINGPARAM( "getPropertySetInfo" ) ), - -1, - getCppuVoidType() - ), - CommandInfo( - OUString( - RTL_CONSTASCII_USTRINGPARAM( "getPropertyValues" ) ), - -1, - getCppuType( static_cast< Sequence< Property > * >( 0 ) ) - ), - CommandInfo( - OUString( - RTL_CONSTASCII_USTRINGPARAM( "setPropertyValues" ) ), - -1, - getCppuType( - static_cast< Sequence< PropertyValue > * >( 0 ) ) - ), - /////////////////////////////////////////////////////////// - // Optional standard commands - /////////////////////////////////////////////////////////// - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "delete" ) ), - -1, - getCppuBooleanType() - ), - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "insert" ) ), - -1, - getCppuVoidType() - ), - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "open" ) ), - -1, - getCppuType( static_cast< OpenCommandArgument2 * >( 0 ) ) - ), - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "transfer" ) ), - -1, - getCppuType( static_cast< TransferInfo * >( 0 ) ) - ), - /////////////////////////////////////////////////////////// - // New commands - /////////////////////////////////////////////////////////// - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "flush" ) ), - -1, - getCppuVoidType() - ), - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "split" ) ), - -1, - getCppuType( static_cast< SplitCommandArgument * >( 0 ) ) - ) - }; + //================================================================= + // + // Folder: Supported commands + // + //================================================================= - return Sequence< CommandInfo >( aRootFolderCommandInfoTable, 10 ); - } - else + static CommandInfo aFolderCommandInfoTable[] = { - //============================================================= - // - // Folder: Supported commands - // - //============================================================= - - static CommandInfo aFolderCommandInfoTable[] = - { - /////////////////////////////////////////////////////////// - // Required commands - /////////////////////////////////////////////////////////// - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "getCommandInfo" ) ), - -1, - getCppuVoidType() - ), - CommandInfo( - OUString( - RTL_CONSTASCII_USTRINGPARAM( "getPropertySetInfo" ) ), - -1, - getCppuVoidType() - ), - CommandInfo( - OUString( - RTL_CONSTASCII_USTRINGPARAM( "getPropertyValues" ) ), - -1, - getCppuType( static_cast< Sequence< Property > * >( 0 ) ) - ), - CommandInfo( - OUString( - RTL_CONSTASCII_USTRINGPARAM( "setPropertyValues" ) ), - -1, - getCppuType( - static_cast< Sequence< PropertyValue > * >( 0 ) ) - ), - /////////////////////////////////////////////////////////// - // Optional standard commands - /////////////////////////////////////////////////////////// - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "delete" ) ), - -1, - getCppuBooleanType() - ), - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "insert" ) ), - -1, - getCppuVoidType() - ), - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "open" ) ), - -1, - getCppuType( static_cast< OpenCommandArgument2 * >( 0 ) ) - ), - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "transfer" ) ), - -1, - getCppuType( static_cast< TransferInfo * >( 0 ) ) - ), - /////////////////////////////////////////////////////////// - // New commands - /////////////////////////////////////////////////////////// - CommandInfo( - OUString( RTL_CONSTASCII_USTRINGPARAM( "flush" ) ), - -1, - getCppuVoidType() - ) - }; + /////////////////////////////////////////////////////////////// + // Required commands + /////////////////////////////////////////////////////////////// + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "getCommandInfo" ) ), + -1, + getCppuVoidType() + ), + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "getPropertySetInfo" ) ), + -1, + getCppuVoidType() + ), + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "getPropertyValues" ) ), + -1, + getCppuType( static_cast< Sequence< Property > * >( 0 ) ) + ), + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "setPropertyValues" ) ), + -1, + getCppuType( + static_cast< Sequence< PropertyValue > * >( 0 ) ) + ), + /////////////////////////////////////////////////////////////// + // Optional standard commands + /////////////////////////////////////////////////////////////// + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "delete" ) ), + -1, + getCppuBooleanType() + ), + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "insert" ) ), + -1, + getCppuVoidType() + ), + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "open" ) ), + -1, + getCppuType( static_cast< OpenCommandArgument2 * >( 0 ) ) + ), + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "transfer" ) ), + -1, + getCppuType( static_cast< TransferInfo * >( 0 ) ) + ), + /////////////////////////////////////////////////////////////// + // New commands + /////////////////////////////////////////////////////////////// + CommandInfo( + OUString( RTL_CONSTASCII_USTRINGPARAM( "flush" ) ), + -1, + getCppuVoidType() + ) + }; - return Sequence< CommandInfo >( aFolderCommandInfoTable, 9 ); - } + return Sequence< CommandInfo >( aFolderCommandInfoTable, 9 ); } else { diff --git a/ucb/source/ucp/package/ucppkg.xml b/ucb/source/ucp/package/ucppkg.xml index 102c449e516c..3b6eb2926deb 100644 --- a/ucb/source/ucp/package/ucppkg.xml +++ b/ucb/source/ucp/package/ucppkg.xml @@ -63,7 +63,6 @@ <type> com.sun.star.lang.XServiceInfo </type> <type> com.sun.star.lang.XSingleServiceFactory </type> <type> com.sun.star.lang.XTypeProvider </type> - <type> com.sun.star.packages.XPackageSplitter </type> <type> com.sun.star.registry.XRegistryKey </type> <type> com.sun.star.sdbc.XCloseable </type> <type> com.sun.star.sdbc.XColumnLocate </type> @@ -76,7 +75,6 @@ <type> com.sun.star.ucb.OpenCommandArgument2 </type> <type> com.sun.star.ucb.OpenMode </type> <type> com.sun.star.ucb.ResultSetException </type> - <type> com.sun.star.ucb.SplitCommandArgument </type> <type> com.sun.star.ucb.TransferInfo </type> <type> com.sun.star.ucb.XCommandInfo </type> <type> com.sun.star.ucb.XCommandProcessor </type> |