6 |
|
|
7 |
|
#include <cxx/standard.hh> |
8 |
|
|
9 |
+ |
#include <apr_tables.h> |
10 |
+ |
|
11 |
|
#include "Client.hpp" |
12 |
|
|
13 |
|
namespace Subversion |
16 |
|
Client::Client() |
17 |
|
{ |
18 |
|
CheckError(::svn_client_create_context(&context, pool)); |
19 |
+ |
|
20 |
+ |
::apr_array_header_t *providers(::apr_array_make(pool, 5, sizeof (::svn_auth_provider_object_t *))); |
21 |
+ |
|
22 |
+ |
#ifdef _WIN32 |
23 |
+ |
::svn_client_get_windows_simple_provider(reinterpret_cast< ::svn_auth_provider_object_t **>(::apr_array_push(providers)), pool); |
24 |
+ |
#endif |
25 |
+ |
::svn_client_get_simple_provider(reinterpret_cast< ::svn_auth_provider_object_t **>(::apr_array_push(providers)), pool); |
26 |
+ |
::svn_client_get_username_provider(reinterpret_cast< ::svn_auth_provider_object_t **>(::apr_array_push(providers)), pool); |
27 |
+ |
::svn_client_get_ssl_server_trust_file_provider(reinterpret_cast< ::svn_auth_provider_object_t **>(::apr_array_push(providers)), pool); |
28 |
+ |
::svn_client_get_ssl_client_cert_file_provider(reinterpret_cast< ::svn_auth_provider_object_t **>(::apr_array_push(providers)), pool); |
29 |
+ |
::svn_client_get_ssl_client_cert_pw_file_provider(reinterpret_cast< ::svn_auth_provider_object_t **>(::apr_array_push(providers)), pool); |
30 |
+ |
::svn_auth_open(&context->auth_baton, providers, pool); |
31 |
|
} |
32 |
|
|
33 |
|
cse::String Client::GetProperty(const cse::String &property, const cse::String &target) const |
34 |
|
{ |
35 |
+ |
api::Apr::Pool pool; |
36 |
|
::apr_hash_t *hash; |
37 |
|
::svn_opt_revision_t revision = { ::svn_opt_revision_unspecified }; |
38 |
|
|
52 |
|
|
53 |
|
_L<Entry> Client::GetEntries(const cse::String &target) const |
54 |
|
{ |
55 |
+ |
api::Apr::Pool pool; |
56 |
|
::apr_hash_t *hash; |
57 |
|
::svn_opt_revision_t revision = { ::svn_opt_revision_unspecified }; |
58 |
|
|