xapian-core  1.4.26
backendmanager_remoteprog.h
Go to the documentation of this file.
1 
4 /* Copyright (C) 2007,2009,2011 Olly Betts
5  * Copyright (C) 2008 Lemur Consulting Ltd
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License as
9  * published by the Free Software Foundation; either version 2 of the
10  * License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, write to the Free Software
19  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20  */
21 
22 #ifndef XAPIAN_INCLUDED_BACKENDMANAGER_REMOTEPROG_H
23 #define XAPIAN_INCLUDED_BACKENDMANAGER_REMOTEPROG_H
24 
25 #include "backendmanager.h"
26 #include "backendmanager_remote.h"
27 
28 #include <string>
29 
30 #include <xapian/types.h>
31 #include <xapian/postingiterator.h>
32 
36  void operator=(const BackendManagerRemoteProg &);
37 
40 
42  std::string last_wdb_name;
43 
45  Xapian::Database do_get_database(const std::vector<std::string> & files);
46 
47  public:
48  explicit BackendManagerRemoteProg(BackendManager* sub_manager_)
49  : BackendManagerRemote(sub_manager_,
50  "remoteprog_" + sub_manager_->get_dbtype())
51  { }
52 
55  const std::string & file);
56 
59  get_remote_writable_database(std::string args);
60 
62  Xapian::Database get_remote_database(const std::vector<std::string> & files,
63  unsigned int timeout);
64 
66  Xapian::Database get_database_by_path(const std::string& path);
67 
70 
73 };
74 
75 #endif // XAPIAN_INCLUDED_BACKENDMANAGER_REMOTEPROG_H
void operator=(const BackendManagerRemoteProg &)
Don&#39;t allow assignment.
typedefs for Xapian
BackendManagerRemoteProg(const BackendManagerRemoteProg &)
Don&#39;t allow copying.
const std::string & get_dbtype() const
Get the database type currently in use.
Xapian::Database get_database_by_path(const std::string &path)
Get RemoteProg Xapian::Database instance of database at path.
This class is used to access a database, or a group of databases.
Definition: database.h:68
unsigned timeout
A timeout value in milliseconds.
Definition: types.h:100
Xapian::WritableDatabase get_writable_database(const std::string &name, const std::string &file)
Create a RemoteProg Xapian::WritableDatabase object indexing a single file.
Xapian::Database get_remote_database(const std::vector< std::string > &files, unsigned int timeout)
Create a RemoteProg Xapian::Database with the specified timeout.
BackendManager subclass for remote databases.
Base class for backend handling in test harness.
std::string last_wdb_name
The path of the last writable database used.
This class provides read/write access to a database.
Definition: database.h:789
Xapian::WritableDatabase get_writable_database_again()
Create a WritableDatabase object for the last opened WritableDatabase.
BackendManager subclass for remoteprog databases.
Xapian::WritableDatabase get_remote_writable_database(std::string args)
Create a RemoteProg Xapian::WritableDatabase object with specified args.
BackendManagerRemoteProg(BackendManager *sub_manager_)
Xapian::Database do_get_database(const std::vector< std::string > &files)
Create a Xapian::Database object indexing multiple files.
Definition: header.h:151
Class for iterating over a list of document ids.
BackendManager subclass for remote databases.
Xapian::Database get_writable_database_as_database()
Create a Database object for the last opened WritableDatabase.