source: valtobtest/subversion-1.6.2/subversion/bindings/javahl/native/InfoCallback.h @ 3

Last change on this file since 3 was 3, checked in by valtob, 15 years ago

subversion source 1.6.2 as test

File size: 1.8 KB
Line 
1/**
2 * @copyright
3 * ====================================================================
4 * Copyright (c) 2007 CollabNet.  All rights reserved.
5 *
6 * This software is licensed as described in the file COPYING, which
7 * you should have received as part of this distribution.  The terms
8 * are also available at http://subversion.tigris.org/license-1.html.
9 * If newer versions of this license are posted there, you may use a
10 * newer version instead, at your option.
11 *
12 * This software consists of voluntary contributions made by many
13 * individuals.  For exact contribution history, see the revision
14 * history and logs, available at http://subversion.tigris.org/.
15 * ====================================================================
16 * @endcopyright
17 *
18 * @file InfoCallback.h
19 * @brief Interface of the class InfoCallback
20 */
21
22#ifndef INFOCALLBACK_H
23#define INFOCALLBACK_H
24
25#include <jni.h>
26#include "svn_client.h"
27
28struct info_entry;
29
30/**
31 * This class holds a Java callback object, which will receive every line of
32 * the file for which the callback information is requested.
33 */
34class InfoCallback
35{
36 public:
37  InfoCallback(jobject jcallback);
38  ~InfoCallback();
39
40  static svn_error_t *callback(void *baton,
41                               const char *path,
42                               const svn_info_t *info,
43                               apr_pool_t *pool);
44
45 protected:
46  svn_error_t *singleInfo(const char *path,
47                          const svn_info_t *info,
48                          apr_pool_t *pool);
49
50 private:
51  /**
52   * A local reference to the corresponding Java object.
53   */
54  jobject m_callback;
55
56  jobject createJavaInfo2(const char *path,
57                          const svn_info_t *info,
58                          apr_pool_t *pool);
59};
60
61#endif  // INFOCALLBACK_H
Note: See TracBrowser for help on using the repository browser.