Version 4.0.2.1, tag libreoffice-4.0.2.1
[LibreOffice.git] / ucb / source / ucp / webdav / SerfRequestProcessorImplFac.cxx
blob33e79223845ef5e8489d2bf9039d0927325113cc
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #include <SerfRequestProcessorImplFac.hxx>
21 #include <SerfPropFindReqProcImpl.hxx>
22 #include <SerfPropPatchReqProcImpl.hxx>
23 #include <SerfGetReqProcImpl.hxx>
24 #include <SerfHeadReqProcImpl.hxx>
25 #include <SerfPutReqProcImpl.hxx>
26 #include <SerfPostReqProcImpl.hxx>
27 #include <SerfDeleteReqProcImpl.hxx>
28 #include <SerfMkColReqProcImpl.hxx>
29 #include <SerfCopyReqProcImpl.hxx>
30 #include <SerfMoveReqProcImpl.hxx>
32 namespace http_dav_ucp
34 SerfRequestProcessorImpl* createPropFindReqProcImpl( const char* inPath,
35 const DAVRequestHeaders& inRequestHeaders,
36 const Depth inDepth,
37 const std::vector< ::rtl::OUString > & inPropNames,
38 std::vector< DAVResource > & ioResources )
40 SerfRequestProcessorImpl* pReqProcImpl = new SerfPropFindReqProcImpl( inPath,
41 inRequestHeaders,
42 inDepth,
43 inPropNames,
44 ioResources );
45 return pReqProcImpl;
48 SerfRequestProcessorImpl* createPropFindReqProcImpl( const char* inPath,
49 const DAVRequestHeaders& inRequestHeaders,
50 const Depth inDepth,
51 std::vector< DAVResourceInfo > & ioResInfo )
53 SerfRequestProcessorImpl* pReqProcImpl = new SerfPropFindReqProcImpl( inPath,
54 inRequestHeaders,
55 inDepth,
56 ioResInfo );
57 return pReqProcImpl;
60 SerfRequestProcessorImpl* createPropPatchReqProcImpl( const char* inPath,
61 const DAVRequestHeaders& inRequestHeaders,
62 const std::vector< ProppatchValue > & inProperties )
64 SerfRequestProcessorImpl* pReqProcImpl = new SerfPropPatchReqProcImpl( inPath,
65 inRequestHeaders,
66 inProperties );
67 return pReqProcImpl;
70 SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath,
71 const DAVRequestHeaders& inRequestHeaders,
72 const com::sun::star::uno::Reference< SerfInputStream >& xioInStrm )
74 SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath,
75 inRequestHeaders,
76 xioInStrm );
77 return pReqProcImpl;
80 SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath,
81 const DAVRequestHeaders& inRequestHeaders,
82 const com::sun::star::uno::Reference< SerfInputStream >& xioInStrm,
83 const std::vector< ::rtl::OUString > & inHeaderNames,
84 DAVResource& ioResource )
86 SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath,
87 inRequestHeaders,
88 xioInStrm,
89 inHeaderNames,
90 ioResource );
91 return pReqProcImpl;
94 SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath,
95 const DAVRequestHeaders& inRequestHeaders,
96 const com::sun::star::uno::Reference< com::sun::star::io::XOutputStream >& xioOutStrm )
98 SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath,
99 inRequestHeaders,
100 xioOutStrm );
101 return pReqProcImpl;
104 SerfRequestProcessorImpl* createGetReqProcImpl( const char* inPath,
105 const DAVRequestHeaders& inRequestHeaders,
106 const com::sun::star::uno::Reference<com::sun::star::io::XOutputStream >& xioOutStrm,
107 const std::vector< ::rtl::OUString > & inHeaderNames,
108 DAVResource& ioResource )
110 SerfRequestProcessorImpl* pReqProcImpl = new SerfGetReqProcImpl( inPath,
111 inRequestHeaders,
112 xioOutStrm,
113 inHeaderNames,
114 ioResource );
115 return pReqProcImpl;
118 SerfRequestProcessorImpl* createHeadReqProcImpl( const char* inPath,
119 const DAVRequestHeaders& inRequestHeaders,
120 const std::vector< ::rtl::OUString > & inHeaderNames,
121 DAVResource& ioResource )
123 SerfRequestProcessorImpl* pReqProcImpl = new SerfHeadReqProcImpl( inPath,
124 inRequestHeaders,
125 inHeaderNames,
126 ioResource );
127 return pReqProcImpl;
131 SerfRequestProcessorImpl* createPutReqProcImpl( const char* inPath,
132 const DAVRequestHeaders& inRequestHeaders,
133 const char* inData,
134 apr_size_t inDataLen )
136 SerfRequestProcessorImpl* pReqProcImpl = new SerfPutReqProcImpl( inPath,
137 inRequestHeaders,
138 inData,
139 inDataLen );
140 return pReqProcImpl;
143 SerfRequestProcessorImpl* createPostReqProcImpl( const char* inPath,
144 const DAVRequestHeaders& inRequestHeaders,
145 const char* inData,
146 apr_size_t inDataLen,
147 const char* inContentType,
148 const char* inReferer,
149 const com::sun::star::uno::Reference< SerfInputStream >& xioInStrm )
151 SerfRequestProcessorImpl* pReqProcImpl = new SerfPostReqProcImpl( inPath,
152 inRequestHeaders,
153 inData,
154 inDataLen,
155 inContentType,
156 inReferer,
157 xioInStrm );
158 return pReqProcImpl;
161 SerfRequestProcessorImpl* createPostReqProcImpl( const char* inPath,
162 const DAVRequestHeaders& inRequestHeaders,
163 const char* inData,
164 apr_size_t inDataLen,
165 const char* inContentType,
166 const char* inReferer,
167 const com::sun::star::uno::Reference< com::sun::star::io::XOutputStream >& xioOutStrm )
169 SerfRequestProcessorImpl* pReqProcImpl = new SerfPostReqProcImpl( inPath,
170 inRequestHeaders,
171 inData,
172 inDataLen,
173 inContentType,
174 inReferer,
175 xioOutStrm );
176 return pReqProcImpl;
179 SerfRequestProcessorImpl* createDeleteReqProcImpl( const char* inPath,
180 const DAVRequestHeaders& inRequestHeaders )
182 SerfRequestProcessorImpl* pReqProcImpl = new SerfDeleteReqProcImpl( inPath,
183 inRequestHeaders );
184 return pReqProcImpl;
187 SerfRequestProcessorImpl* createMkColReqProcImpl( const char* inPath,
188 const DAVRequestHeaders& inRequestHeaders )
190 SerfRequestProcessorImpl* pReqProcImpl = new SerfMkColReqProcImpl( inPath,
191 inRequestHeaders );
192 return pReqProcImpl;
195 SerfRequestProcessorImpl* createCopyReqProcImpl( const char* inSourcePath,
196 const DAVRequestHeaders& inRequestHeaders,
197 const char* inDestinationPath,
198 const bool inOverwrite )
200 SerfRequestProcessorImpl* pReqProcImpl = new SerfCopyReqProcImpl( inSourcePath,
201 inRequestHeaders,
202 inDestinationPath,
203 inOverwrite );
204 return pReqProcImpl;
207 SerfRequestProcessorImpl* createMoveReqProcImpl( const char* inSourcePath,
208 const DAVRequestHeaders& inRequestHeaders,
209 const char* inDestinationPath,
210 const bool inOverwrite )
212 SerfRequestProcessorImpl* pReqProcImpl = new SerfMoveReqProcImpl( inSourcePath,
213 inRequestHeaders,
214 inDestinationPath,
215 inOverwrite );
216 return pReqProcImpl;
219 } // namespace http_dav_ucp
221 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */