Public Types | Public Member Functions

Insert Class Reference

Models an INSERT statement in SPARQL. More...

Inheritance diagram for Insert:
Inheritance graph
[legend]

List of all members.

Public Types

enum  ConflictStrategy { Abort, Replace }

Public Member Functions

CUBI_EXPLICIT Insert (ConflictStrategy strategy=Abort)
 Constructs an empty INSERT statement.
Q_DECL_DEPRECATED CUBI_EXPLICIT Insert (const ResourceValue &graph)
 Constructs an empty INSERT statement.
Q_DECL_DEPRECATED Insert (ConflictStrategy strategy, const ResourceValue &graph)
 Constructs an empty INSERT statement.
void setConflictStrategy (ConflictStrategy strategy)
ConflictStrategy conflictStrategy () const

Detailed Description

Models an INSERT statement in SPARQL.

A Insert statement has two parts, the first one, called the "data" part, being the graph pattern that has to be inserted, and the second one, called the "restriction" part, being the pattern that must be matched for the actual insertion to happen. The first part can be manipulated using the UpdateBase::addData() functions, while the second part is manipulated using the UpdateBase::addRestriction() functions.

Most of the useful functions of this class are defined in UpdateBase, which is the common base to Delete and Insert (since they share a very similar structure).


Constructor & Destructor Documentation

Insert::Insert ( ConflictStrategy  strategy = Abort  ) 

Constructs an empty INSERT statement.

The strategy argument permits switching between regular INSERT that aborts if existing resources have conflicting data in single-value properties, and INSERT OR REPLACE which overwrites values for single valued properties.

Deprecated:
INSERT INTO variant is deprecated. New code should create a Graph and add it using UpdateBase::addData().
Insert::Insert ( const ResourceValue graph  ) 

Constructs an empty INSERT statement.

An optional graph can be set, if you want to generate a INSERT INTO ... query.

Deprecated:
INSERT INTO variant is deprecated. New code should create a Graph and add it using UpdateBase::addData().
Insert::Insert ( ConflictStrategy  strategy,
const ResourceValue graph 
)

Constructs an empty INSERT statement.

An optional graph can be set, if you want to generate a INSERT INTO ... query.

The strategy argument permits switching between regular INSERT that aborts if existing resources have conflicting data in single-value properties, and INSERT OR REPLACE which overwrites values for single valued properties.

Deprecated:
INSERT INTO variant is deprecated. New code should create a Graph and add it using UpdateBase::addData().

The documentation for this class was generated from the following files:
 All Classes Functions Enumerations