Lines Matching refs:curlRequest

67 …CredentialsData( CurlSession *curlSession, CurlRequest &curlRequest, const DAVRequestEnvironment &…  in CredentialsData()
69 , request( curlRequest ) in CredentialsData()
723 void CurlSession::addEnvironmentRequestHeaders( CurlRequest &curlRequest, const DAVRequestEnvironme… in addEnvironmentRequestHeaders() argument
741 curlRequest.addHeader( aHeader, aValue ); in addEnvironmentRequestHeaders()
749curlRequest.addHeader( "User-Agent", rtl::OUStringToOString( rUserAgent, RTL_TEXTENCODING_UTF8 ) ); in addEnvironmentRequestHeaders()
753 void CurlSession::processResponse( CurlRequest &curlRequest, CURLcode curlCode ) in processResponse() argument
760 statusCode = curlRequest.getStatusCode(); in processResponse()
765 const CurlRequest::Header *server = curlRequest.findResponseHeader( "server" ); in processResponse()
808 …rtl::OUString reasonPhrase = rtl::OStringToOUString( curlRequest.getReasonPhrase(), RTL_TEXTENCODI… in processResponse()
820 const CurlRequest::Header *location = curlRequest.findResponseHeader( "location" ); in processResponse()
845 curlRequest.setChunkedEncoding( !curlRequest.isChunkedEncoding() ); in processResponse()
907 void CurlSession::propfind( CurlRequest &curlRequest, in propfind() argument
914 addEnvironmentRequestHeaders( curlRequest, rEnv ); in propfind()
917 curlRequest.addHeader( "Depth", "0" ); in propfind()
919 curlRequest.addHeader( "Depth", "1" ); in propfind()
921 curlRequest.addHeader( "Depth", "infinity" ); in propfind()
926 curlRequest.addHeader( "Content-Type", "application/xml" ); in propfind()
927 curlRequest.setRequestBody( xml.getStr(), xml.getLength() ); in propfind()
930 CredentialsData credsData( this, curlRequest, rEnv ); in propfind()
931 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in propfind()
933 CURLcode rc = curlRequest.propfind( m_aUri, inPath ); in propfind()
934 processResponse( curlRequest, rc ); in propfind()
949 CurlRequest curlRequest( m_pCurl ); in PROPFIND() local
951 propfind( curlRequest, inPath, inDepth, &inPropNames, false, rEnv ); in PROPFIND()
953 …const std::vector< DAVResource > rResources( parseWebDAVPropFindResponse( curlRequest.getResponseB… in PROPFIND()
972 CurlRequest curlRequest( m_pCurl ); in PROPFIND() local
974 propfind( curlRequest, inPath, inDepth, NULL, true, rEnv ); in PROPFIND()
976 …const std::vector< DAVResourceInfo > rResInfo( parseWebDAVPropNameResponse( curlRequest.getRespons… in PROPFIND()
994 CurlRequest curlRequest( m_pCurl ); in PROPPATCH() local
996 addEnvironmentRequestHeaders( curlRequest, rEnv ); in PROPPATCH()
1008 curlRequest.addHeader( "If", in PROPPATCH()
1015 curlRequest.addHeader( "Content-Type", "application/xml" ); in PROPPATCH()
1016 curlRequest.setRequestBody( xml.getStr(), xml.getLength() ); in PROPPATCH()
1019 CredentialsData credsData( this, curlRequest, rEnv ); in PROPPATCH()
1020 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in PROPPATCH()
1022 CURLcode rc = curlRequest.proppatch( m_aUri, inPath ); in PROPPATCH()
1023 processResponse( curlRequest, rc ); in PROPPATCH()
1040 CurlRequest curlRequest( m_pCurl ); in HEAD() local
1042 addEnvironmentRequestHeaders( curlRequest, rEnv ); in HEAD()
1047 CredentialsData credsData( this, curlRequest, rEnv ); in HEAD()
1048 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in HEAD()
1050 CURLcode rc = curlRequest.head( m_aUri, inPath ); in HEAD()
1051 processResponse( curlRequest, rc ); in HEAD()
1052 responseHeadersToDAVResource( curlRequest.getResponseHeaders(), inHeaderNames, ioResource ); in HEAD()
1068 CurlRequest curlRequest( m_pCurl ); in GET() local
1070 addEnvironmentRequestHeaders( curlRequest, rEnv ); in GET()
1072 CredentialsData credsData( this, curlRequest, rEnv ); in GET()
1073 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in GET()
1075 CURLcode rc = curlRequest.get( m_aUri, inPath ); in GET()
1076 processResponse( curlRequest, rc ); in GET()
1078 return uno::Reference< io::XInputStream >( curlRequest.getResponseBody().get() ); in GET()
1094 CurlRequest curlRequest( m_pCurl ); in GET() local
1096 addEnvironmentRequestHeaders( curlRequest, rEnv ); in GET()
1098 CredentialsData credsData( this, curlRequest, rEnv ); in GET()
1099 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in GET()
1101 curlRequest.saveResponseBodyTo( ioOutputStream ); in GET()
1102 CURLcode rc = curlRequest.get( m_aUri, inPath ); in GET()
1103 processResponse( curlRequest, rc ); in GET()
1121 CurlRequest curlRequest( m_pCurl ); in GET() local
1123 addEnvironmentRequestHeaders( curlRequest, rEnv ); in GET()
1125 CredentialsData credsData( this, curlRequest, rEnv ); in GET()
1126 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in GET()
1128 CURLcode rc = curlRequest.get( m_aUri, inPath ); in GET()
1129 processResponse( curlRequest, rc ); in GET()
1130 responseHeadersToDAVResource( curlRequest.getResponseHeaders(), inHeaderNames, ioResource ); in GET()
1132 return uno::Reference< io::XInputStream >( curlRequest.getResponseBody().get() ); in GET()
1151 CurlRequest curlRequest( m_pCurl ); in GET() local
1153 addEnvironmentRequestHeaders( curlRequest, rEnv ); in GET()
1155 CredentialsData credsData( this, curlRequest, rEnv ); in GET()
1156 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in GET()
1158 curlRequest.saveResponseBodyTo( ioOutputStream ); in GET()
1159 CURLcode rc = curlRequest.get( m_aUri, inPath ); in GET()
1160 processResponse( curlRequest, rc ); in GET()
1161 responseHeadersToDAVResource( curlRequest.getResponseHeaders(), inHeaderNames, ioResource ); in GET()
1177 CurlRequest curlRequest( m_pCurl ); in PUT() local
1179 addEnvironmentRequestHeaders( curlRequest, rEnv ); in PUT()
1184 curlRequest.setRequestBody( reinterpret_cast< const char * >( aDataToSend.getConstArray() ), in PUT()
1187 CredentialsData credsData( this, curlRequest, rEnv ); in PUT()
1188 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in PUT()
1200 curlRequest.addHeader( "If", in PUT()
1204 CURLcode rc = curlRequest.put( m_aUri, inPath ); in PUT()
1205 processResponse( curlRequest, rc ); in PUT()
1224 CurlRequest curlRequest( m_pCurl ); in POST() local
1226 addEnvironmentRequestHeaders( curlRequest, rEnv ); in POST()
1231 curlRequest.setRequestBody( reinterpret_cast< const char * >( aDataToSend.getConstArray() ), in POST()
1234 CredentialsData credsData( this, curlRequest, rEnv ); in POST()
1235 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in POST()
1238curlRequest.addHeader( "Content-Type", rtl::OUStringToOString( rContentType, RTL_TEXTENCODING_UTF8… in POST()
1240curlRequest.addHeader( "Referer", rtl::OUStringToOString( rReferer, RTL_TEXTENCODING_UTF8 ).getStr… in POST()
1252 curlRequest.addHeader( "If", in POST()
1256 CURLcode rc = curlRequest.post( m_aUri, inPath ); in POST()
1257 processResponse( curlRequest, rc ); in POST()
1258 return uno::Reference< io::XInputStream >( curlRequest.getResponseBody().get() ); in POST()
1277 CurlRequest curlRequest( m_pCurl ); in POST() local
1279 addEnvironmentRequestHeaders( curlRequest, rEnv ); in POST()
1284 curlRequest.setRequestBody( reinterpret_cast< const char * >( aDataToSend.getConstArray() ), in POST()
1287 CredentialsData credsData( this, curlRequest, rEnv ); in POST()
1288 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in POST()
1291curlRequest.addHeader( "Content-Type", rtl::OUStringToOString( rContentType, RTL_TEXTENCODING_UTF8… in POST()
1293curlRequest.addHeader( "Referer", rtl::OUStringToOString( rReferer, RTL_TEXTENCODING_UTF8 ).getStr… in POST()
1305 curlRequest.addHeader( "If", in POST()
1309 curlRequest.saveResponseBodyTo( oOutputStream ); in POST()
1310 CURLcode rc = curlRequest.post( m_aUri, inPath ); in POST()
1311 processResponse( curlRequest, rc ); in POST()
1326 CurlRequest curlRequest( m_pCurl ); in MKCOL() local
1328 addEnvironmentRequestHeaders( curlRequest, rEnv ); in MKCOL()
1330 CredentialsData credsData( this, curlRequest, rEnv ); in MKCOL()
1331 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in MKCOL()
1343 curlRequest.addHeader( "If", in MKCOL()
1347 CURLcode rc = curlRequest.mkcol( m_aUri, inPath ); in MKCOL()
1348 processResponse( curlRequest, rc ); in MKCOL()
1365 CurlRequest curlRequest( m_pCurl ); in COPY() local
1367 addEnvironmentRequestHeaders( curlRequest, rEnv ); in COPY()
1369 CredentialsData credsData( this, curlRequest, rEnv ); in COPY()
1370 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in COPY()
1372curlRequest.addHeader( "Destination", rtl::OUStringToOString( inDestinationURL, RTL_TEXTENCODING_U… in COPY()
1373 curlRequest.addHeader( "Overwrite", inOverWrite? "T" : "F" ); in COPY()
1385 curlRequest.addHeader( "If", in COPY()
1389 CURLcode rc = curlRequest.copy( m_aUri, CurlUri( inSourceURL ).GetPath() ); in COPY()
1390 processResponse( curlRequest, rc ); in COPY()
1407 CurlRequest curlRequest( m_pCurl ); in MOVE() local
1409 addEnvironmentRequestHeaders( curlRequest, rEnv ); in MOVE()
1411 CredentialsData credsData( this, curlRequest, rEnv ); in MOVE()
1412 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in MOVE()
1414curlRequest.addHeader( "Destination", rtl::OUStringToOString( inDestinationURL, RTL_TEXTENCODING_U… in MOVE()
1415 curlRequest.addHeader( "Overwrite", inOverWrite? "T" : "F" ); in MOVE()
1427 curlRequest.addHeader( "If", in MOVE()
1431 CURLcode rc = curlRequest.copy( m_aUri, CurlUri( inSourceURL ).GetPath() ); in MOVE()
1432 processResponse( curlRequest, rc ); in MOVE()
1447 CurlRequest curlRequest( m_pCurl ); in DESTROY() local
1449 addEnvironmentRequestHeaders( curlRequest, rEnv ); in DESTROY()
1451 CredentialsData credsData( this, curlRequest, rEnv ); in DESTROY()
1452 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in DESTROY()
1464 curlRequest.addHeader( "If", in DESTROY()
1468 CURLcode rc = curlRequest.delete_( m_aUri, inPath ); in DESTROY()
1469 processResponse( curlRequest, rc ); in DESTROY()
1527 CurlRequest curlRequest( m_pCurl ); in LOCK() local
1529 addEnvironmentRequestHeaders( curlRequest, rEnv ); in LOCK()
1531 CredentialsData credsData( this, curlRequest, rEnv ); in LOCK()
1532 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in LOCK()
1535 curlRequest.addHeader( "Timeout", "Infinite" ); in LOCK()
1537 curlRequest.addHeader( "Timeout", "Second-" + rtl::OString::valueOf( inLock.Timeout ) ); in LOCK()
1545 curlRequest.addHeader( "Depth", "0" ); in LOCK()
1548 curlRequest.addHeader( "Depth", "1" ); in LOCK()
1551 curlRequest.addHeader( "Depth", "infinity" ); in LOCK()
1556 curlRequest.addHeader( "Content-Type", "application/xml" ); in LOCK()
1557 curlRequest.setRequestBody( xml.getStr(), xml.getLength() ); in LOCK()
1562 CURLcode rc = curlRequest.lock( m_aUri, inPath ); in LOCK()
1563 processResponse( curlRequest, rc ); in LOCK()
1567 … const DAVPropertyValue outLock( parseWebDAVLockResponse( curlRequest.getResponseBody().get() ) ); in LOCK()
1637 CurlRequest curlRequest( m_pCurl ); in LOCK() local
1643 curlRequest.addHeader( "Timeout", "Infinite" ); in LOCK()
1645 curlRequest.addHeader( "Timeout", "Second-" + rtl::OString::valueOf( inLock.Timeout ) ); in LOCK()
1653 curlRequest.addHeader( "Depth", "0" ); in LOCK()
1656 curlRequest.addHeader( "Depth", "1" ); in LOCK()
1659 curlRequest.addHeader( "Depth", "infinity" ); in LOCK()
1665 curlRequest.addHeader( "If", in LOCK()
1670 curlRequest.addHeader( "Content-Type", "application/xml" ); in LOCK()
1671 curlRequest.setRequestBody( xml.getStr(), xml.getLength() ); in LOCK()
1676 CURLcode rc = curlRequest.lock( m_aUri, inPath ); in LOCK()
1677 processResponse( curlRequest, rc ); in LOCK()
1681 … const DAVPropertyValue outLock( parseWebDAVLockResponse( curlRequest.getResponseBody().get() ) ); in LOCK()
1712 CurlRequest curlRequest( m_pCurl ); in UNLOCK() local
1714 addEnvironmentRequestHeaders( curlRequest, rEnv ); in UNLOCK()
1716 CredentialsData credsData( this, curlRequest, rEnv ); in UNLOCK()
1717 curlRequest.setProvideCredentialsCallback( Curl_ProvideCredentials, &credsData ); in UNLOCK()
1720 curlRequest.addHeader( "Lock-Token", in UNLOCK()
1728 CURLcode rc = curlRequest.unlock( m_aUri, inPath ); in UNLOCK()
1729 processResponse( curlRequest, rc ); in UNLOCK()
1742 CurlRequest curlRequest( m_pCurl ); in UNLOCK() local
1746 curlRequest.addHeader( "Lock-Token", in UNLOCK()
1749 CURLcode rc = curlRequest.unlock( m_aUri, inPath ); in UNLOCK()
1750 processResponse( curlRequest, rc ); in UNLOCK()