This file is indexed.

/usr/include/pqxx/nontransaction.hxx is in libpqxx-dev 4.0.1+dfsg-3ubuntu1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
/*-------------------------------------------------------------------------
 *
 *   FILE
 *	pqxx/nontransaction.hxx
 *
 *   DESCRIPTION
 *      definition of the pqxx::nontransaction class.
 *   pqxx::nontransaction provides nontransactional database access
 *   DO NOT INCLUDE THIS FILE DIRECTLY; include pqxx/nontransaction instead.
 *
 * Copyright (c) 2002-2008, Jeroen T. Vermeulen <jtv@xs4all.nl>
 *
 * See COPYING for copyright license.  If you did not receive a file called
 * COPYING with this source code, please notify the distributor of this mistake,
 * or contact the author.
 *
 *-------------------------------------------------------------------------
 */
#ifndef PQXX_H_NONTRANSACTION
#define PQXX_H_NONTRANSACTION

#include "pqxx/compiler-public.hxx"
#include "pqxx/compiler-internal-pre.hxx"

#include "pqxx/connection_base"
#include "pqxx/result"
#include "pqxx/transaction_base"

/* Methods tested in eg. self-test program test001 are marked with "//[t1]"
 */


namespace pqxx
{

/// Simple "transaction" class offering no transactional integrity.
/**
 * @addtogroup transaction Transaction classes
 *
 * nontransaction, like transaction or any other transaction_base-derived class,
 * provides access to a database through a connection.  Unlike its siblings,
 * however, nontransaction does not maintain any kind of transactional
 * integrity.  This may be useful eg. for read-only access to the database that
 * does not require a consistent, atomic view on its data; or for operations
 * that are not allowed within a backend transaction, such as creating tables.
 *
 * For queries that update the database, however, a real transaction is likely
 * to be faster unless the transaction consists of only a single record update.
 *
 * Also, you can keep a nontransaction open for as long as you like.  Actual
 * back-end transactions are limited in lifespan, and will sometimes fail just
 * because they took too long to execute or were left idle for too long.  This
 * will not happen with a nontransaction (although the connection may still time
 * out, e.g. when the network is unavailable for a very long time).
 *
 * Any query executed in a nontransaction is committed immediately, and neither
 * commit() nor abort() has any effect.
 *
 * Database features that require a backend transaction, such as cursors or
 * large objects, will not work in a nontransaction.
 */
class PQXX_LIBEXPORT nontransaction : public transaction_base
{
public:
  /// Constructor.
  /** Create a "dummy" transaction.
   * @param C Connection that this "transaction" will operate on.
   * @param Name Optional name for the transaction, beginning with a letter
   * and containing only letters and digits.
   */
  explicit nontransaction(connection_base &C,
		          const PGSTD::string &Name=PGSTD::string()) :	//[t14]
    namedclass("nontransaction", Name), transaction_base(C) { Begin(); }

  virtual ~nontransaction();						//[t14]

private:
  virtual void do_begin() {}						//[t14]
  virtual result do_exec(const char C[]);				//[t14]
  virtual void do_commit() {}						//[t14]
  virtual void do_abort() {}						//[t14]
};


} // namespace pqxx


#include "pqxx/compiler-internal-post.hxx"

#endif