18590a0fdSAndre Fischer /************************************************************** 28590a0fdSAndre Fischer * 38590a0fdSAndre Fischer * Licensed to the Apache Software Foundation (ASF) under one 48590a0fdSAndre Fischer * or more contributor license agreements. See the NOTICE file 58590a0fdSAndre Fischer * distributed with this work for additional information 68590a0fdSAndre Fischer * regarding copyright ownership. The ASF licenses this file 78590a0fdSAndre Fischer * to you under the Apache License, Version 2.0 (the 88590a0fdSAndre Fischer * "License"); you may not use this file except in compliance 98590a0fdSAndre Fischer * with the License. You may obtain a copy of the License at 108590a0fdSAndre Fischer * 118590a0fdSAndre Fischer * http://www.apache.org/licenses/LICENSE-2.0 128590a0fdSAndre Fischer * 138590a0fdSAndre Fischer * Unless required by applicable law or agreed to in writing, 148590a0fdSAndre Fischer * software distributed under the License is distributed on an 158590a0fdSAndre Fischer * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 168590a0fdSAndre Fischer * KIND, either express or implied. See the License for the 178590a0fdSAndre Fischer * specific language governing permissions and limitations 188590a0fdSAndre Fischer * under the License. 198590a0fdSAndre Fischer * 208590a0fdSAndre Fischer *************************************************************/ 218590a0fdSAndre Fischer 228590a0fdSAndre Fischer // MARKER(update_precomp.py): autogen include statement, do not remove 238590a0fdSAndre Fischer #include "precompiled_ucb.hxx" 248590a0fdSAndre Fischer 258590a0fdSAndre Fischer #include <SerfRequestProcessorImplFac.hxx> 268590a0fdSAndre Fischer #include <SerfPropFindReqProcImpl.hxx> 278590a0fdSAndre Fischer #include <SerfPropPatchReqProcImpl.hxx> 288590a0fdSAndre Fischer #include <SerfGetReqProcImpl.hxx> 298590a0fdSAndre Fischer #include <SerfHeadReqProcImpl.hxx> 308590a0fdSAndre Fischer #include <SerfPutReqProcImpl.hxx> 318590a0fdSAndre Fischer #include <SerfPostReqProcImpl.hxx> 328590a0fdSAndre Fischer #include <SerfDeleteReqProcImpl.hxx> 338590a0fdSAndre Fischer #include <SerfMkColReqProcImpl.hxx> 348590a0fdSAndre Fischer #include <SerfCopyReqProcImpl.hxx> 358590a0fdSAndre Fischer #include <SerfMoveReqProcImpl.hxx> 368590a0fdSAndre Fischer 378590a0fdSAndre Fischer namespace http_dav_ucp 388590a0fdSAndre Fischer { 398590a0fdSAndre Fischer SerfRequestProcessorImpl* createPropFindReqProcImpl( const char* inPath, 40*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 418590a0fdSAndre Fischer const Depth inDepth, 428590a0fdSAndre Fischer const std::vector< ::rtl::OUString > & inPropNames, 438590a0fdSAndre Fischer std::vector< DAVResource > & ioResources ) 448590a0fdSAndre Fischer { 458590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfPropFindReqProcImpl( inPath, 46*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 478590a0fdSAndre Fischer inDepth, 488590a0fdSAndre Fischer inPropNames, 498590a0fdSAndre Fischer ioResources ); 508590a0fdSAndre Fischer return pReqProcImpl; 518590a0fdSAndre Fischer } 528590a0fdSAndre Fischer 538590a0fdSAndre Fischer SerfRequestProcessorImpl* createPropFindReqProcImpl( const char* inPath, 54*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 558590a0fdSAndre Fischer const Depth inDepth, 568590a0fdSAndre Fischer std::vector< DAVResourceInfo > & ioResInfo ) 578590a0fdSAndre Fischer { 588590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfPropFindReqProcImpl( inPath, 59*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 608590a0fdSAndre Fischer inDepth, 618590a0fdSAndre Fischer ioResInfo ); 628590a0fdSAndre Fischer return pReqProcImpl; 638590a0fdSAndre Fischer } 648590a0fdSAndre Fischer 658590a0fdSAndre Fischer SerfRequestProcessorImpl* createPropPatchReqProcImpl( const char* inPath, 66*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 678590a0fdSAndre Fischer const std::vector< ProppatchValue > & inProperties ) 688590a0fdSAndre Fischer { 698590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfPropPatchReqProcImpl( inPath, 70*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 718590a0fdSAndre Fischer inProperties ); 728590a0fdSAndre Fischer return pReqProcImpl; 738590a0fdSAndre Fischer } 748590a0fdSAndre Fischer 758590a0fdSAndre Fischer SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath, 76*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 778590a0fdSAndre Fischer const com::sun::star::uno::Reference< SerfInputStream >& xioInStrm ) 788590a0fdSAndre Fischer { 798590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath, 80*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 818590a0fdSAndre Fischer xioInStrm ); 828590a0fdSAndre Fischer return pReqProcImpl; 838590a0fdSAndre Fischer } 848590a0fdSAndre Fischer 858590a0fdSAndre Fischer SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath, 86*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 878590a0fdSAndre Fischer const com::sun::star::uno::Reference< SerfInputStream >& xioInStrm, 888590a0fdSAndre Fischer const std::vector< ::rtl::OUString > & inHeaderNames, 898590a0fdSAndre Fischer DAVResource& ioResource ) 908590a0fdSAndre Fischer { 918590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath, 92*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 938590a0fdSAndre Fischer xioInStrm, 948590a0fdSAndre Fischer inHeaderNames, 958590a0fdSAndre Fischer ioResource ); 968590a0fdSAndre Fischer return pReqProcImpl; 978590a0fdSAndre Fischer } 988590a0fdSAndre Fischer 998590a0fdSAndre Fischer SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath, 100*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 1018590a0fdSAndre Fischer const com::sun::star::uno::Reference< com::sun::star::io::XOutputStream >& xioOutStrm ) 1028590a0fdSAndre Fischer { 1038590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath, 104*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 1058590a0fdSAndre Fischer xioOutStrm ); 1068590a0fdSAndre Fischer return pReqProcImpl; 1078590a0fdSAndre Fischer } 1088590a0fdSAndre Fischer 1098590a0fdSAndre Fischer SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath, 110*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 1118590a0fdSAndre Fischer const com::sun::star::uno::Reference<com::sun::star::io::XOutputStream >& xioOutStrm, 1128590a0fdSAndre Fischer const std::vector< ::rtl::OUString > & inHeaderNames, 1138590a0fdSAndre Fischer DAVResource& ioResource ) 1148590a0fdSAndre Fischer { 1158590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath, 116*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 1178590a0fdSAndre Fischer xioOutStrm, 1188590a0fdSAndre Fischer inHeaderNames, 1198590a0fdSAndre Fischer ioResource ); 1208590a0fdSAndre Fischer return pReqProcImpl; 1218590a0fdSAndre Fischer } 1228590a0fdSAndre Fischer 1238590a0fdSAndre Fischer SerfRequestProcessorImpl* createHeadReqProcImpl( const char* inPath, 124*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 1258590a0fdSAndre Fischer const std::vector< ::rtl::OUString > & inHeaderNames, 1268590a0fdSAndre Fischer DAVResource& ioResource ) 1278590a0fdSAndre Fischer { 1288590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfHeadReqProcImpl( inPath, 129*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 1308590a0fdSAndre Fischer inHeaderNames, 1318590a0fdSAndre Fischer ioResource ); 1328590a0fdSAndre Fischer return pReqProcImpl; 1338590a0fdSAndre Fischer } 1348590a0fdSAndre Fischer 1358590a0fdSAndre Fischer 1368590a0fdSAndre Fischer SerfRequestProcessorImpl* createPutReqProcImpl( const char* inPath, 137*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 1388590a0fdSAndre Fischer const char* inData, 1398590a0fdSAndre Fischer apr_size_t inDataLen ) 1408590a0fdSAndre Fischer { 1418590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfPutReqProcImpl( inPath, 142*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 1438590a0fdSAndre Fischer inData, 1448590a0fdSAndre Fischer inDataLen ); 1458590a0fdSAndre Fischer return pReqProcImpl; 1468590a0fdSAndre Fischer } 1478590a0fdSAndre Fischer 1488590a0fdSAndre Fischer SerfRequestProcessorImpl* createPostReqProcImpl( const char* inPath, 149*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 1508590a0fdSAndre Fischer const char* inData, 1518590a0fdSAndre Fischer apr_size_t inDataLen, 1528590a0fdSAndre Fischer const char* inContentType, 1538590a0fdSAndre Fischer const char* inReferer, 1548590a0fdSAndre Fischer const com::sun::star::uno::Reference< SerfInputStream >& xioInStrm ) 1558590a0fdSAndre Fischer { 1568590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfPostReqProcImpl( inPath, 157*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 1588590a0fdSAndre Fischer inData, 1598590a0fdSAndre Fischer inDataLen, 1608590a0fdSAndre Fischer inContentType, 1618590a0fdSAndre Fischer inReferer, 1628590a0fdSAndre Fischer xioInStrm ); 1638590a0fdSAndre Fischer return pReqProcImpl; 1648590a0fdSAndre Fischer } 1658590a0fdSAndre Fischer 1668590a0fdSAndre Fischer SerfRequestProcessorImpl* createPostReqProcImpl( const char* inPath, 167*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 1688590a0fdSAndre Fischer const char* inData, 1698590a0fdSAndre Fischer apr_size_t inDataLen, 1708590a0fdSAndre Fischer const char* inContentType, 1718590a0fdSAndre Fischer const char* inReferer, 1728590a0fdSAndre Fischer const com::sun::star::uno::Reference< com::sun::star::io::XOutputStream >& xioOutStrm ) 1738590a0fdSAndre Fischer { 1748590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfPostReqProcImpl( inPath, 175*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 1768590a0fdSAndre Fischer inData, 1778590a0fdSAndre Fischer inDataLen, 1788590a0fdSAndre Fischer inContentType, 1798590a0fdSAndre Fischer inReferer, 1808590a0fdSAndre Fischer xioOutStrm ); 1818590a0fdSAndre Fischer return pReqProcImpl; 1828590a0fdSAndre Fischer } 1838590a0fdSAndre Fischer 184*e9ff7e89SOliver-Rainer Wittmann SerfRequestProcessorImpl* createDeleteReqProcImpl( const char* inPath, 185*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders ) 1868590a0fdSAndre Fischer { 187*e9ff7e89SOliver-Rainer Wittmann SerfRequestProcessorImpl* pReqProcImpl = new SerfDeleteReqProcImpl( inPath, 188*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders ); 1898590a0fdSAndre Fischer return pReqProcImpl; 1908590a0fdSAndre Fischer } 1918590a0fdSAndre Fischer 192*e9ff7e89SOliver-Rainer Wittmann SerfRequestProcessorImpl* createMkColReqProcImpl( const char* inPath, 193*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders ) 1948590a0fdSAndre Fischer { 195*e9ff7e89SOliver-Rainer Wittmann SerfRequestProcessorImpl* pReqProcImpl = new SerfMkColReqProcImpl( inPath, 196*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders ); 1978590a0fdSAndre Fischer return pReqProcImpl; 1988590a0fdSAndre Fischer } 1998590a0fdSAndre Fischer 2008590a0fdSAndre Fischer SerfRequestProcessorImpl* createCopyReqProcImpl( const char* inSourcePath, 201*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 2028590a0fdSAndre Fischer const char* inDestinationPath, 2038590a0fdSAndre Fischer const bool inOverwrite ) 2048590a0fdSAndre Fischer { 2058590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfCopyReqProcImpl( inSourcePath, 206*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 2078590a0fdSAndre Fischer inDestinationPath, 2088590a0fdSAndre Fischer inOverwrite ); 2098590a0fdSAndre Fischer return pReqProcImpl; 2108590a0fdSAndre Fischer } 2118590a0fdSAndre Fischer 2128590a0fdSAndre Fischer SerfRequestProcessorImpl* createMoveReqProcImpl( const char* inSourcePath, 213*e9ff7e89SOliver-Rainer Wittmann const DAVRequestHeaders& inRequestHeaders, 2148590a0fdSAndre Fischer const char* inDestinationPath, 2158590a0fdSAndre Fischer const bool inOverwrite ) 2168590a0fdSAndre Fischer { 2178590a0fdSAndre Fischer SerfRequestProcessorImpl* pReqProcImpl = new SerfMoveReqProcImpl( inSourcePath, 218*e9ff7e89SOliver-Rainer Wittmann inRequestHeaders, 2198590a0fdSAndre Fischer inDestinationPath, 2208590a0fdSAndre Fischer inOverwrite ); 2218590a0fdSAndre Fischer return pReqProcImpl; 2228590a0fdSAndre Fischer } 2238590a0fdSAndre Fischer 2248590a0fdSAndre Fischer } // namespace http_dav_ucp 225