kDB: Knowledge DataBase
Loading...
Searching...
No Matches
kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ > Class Template Reference

Public Types

using Derive = _TDerive_
 
using ValueType = typename FocusNodeCollectionTrait<Derive>::ValueType
 

Public Member Functions

bool operator== (const Derive &_rhs) const
 
bool isValid () const
 
bool isReadOnly () const
 
knowCore::Uri uri () const
 
kDB::Repository::Connection connection () const
 
cres_qresult< std::size_t > count () const
 
cres_qresult< QList< ValueType > > all () const
 

Static Public Member Functions

static cres_qresult< Derive > get (const kDB::Repository::Connection &_connection, const knowCore::Uri &_graph)
 
static cres_qresult< Derive > create (const kDB::Repository::Connection &_connection, const knowCore::Uri &_graph)
 
static cres_qresult< Derive > getOrCreate (const kDB::Repository::Connection &_connection, const knowCore::Uri &_graph)
 
static cres_qresult< void > registerCollection (const kDB::Repository::QueryConnectionInfo &_connection)
 

Protected Member Functions

 operator Derive () const
 
cres_qresult< ValueType > focusNode (const knowCore::Uri &_uri) const
 
cres_qresult< bool > hasFocusNode (const knowCore::Uri &_focusNodeUri, const knowCore::Uri &_typeUri=Derive::primaryType()) const
 
cres_qresult< QList< ValueType > > focusNodes (const QList< QPair< knowCore::Uri, knowCore::ConstrainedValue > > &_constraints, const FocusNodeCollection::OperatorOptions &_operatorOptions) const
 
template<typename... _TArgs_>
cres_qresult< QList< ValueType > > focusNodes (const knowCore::Uri &_uri, const knowCore::ConstrainedValue &_constraint, const _TArgs_ &... _args) const
 
cres_qresult< ValueType > createFocusNode (const knowCore::Uri &_typeUri, const knowCore::ValueHash &_properties, const knowCore::Uri &_focusNodeUri)
 
FocusNodeCollectionfocusNodeCollection ()
 
const FocusNodeCollectionfocusNodeCollection () const
 

Member Function Documentation

◆ all()

template<typename _TDerive_ >
cres_qresult< QList< ValueType > > kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::all ( ) const
inline
Returns
all the values contained in this document.

◆ connection()

template<typename _TDerive_ >
kDB::Repository::Connection kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::connection ( ) const
inline
Returns
the connection

◆ count()

template<typename _TDerive_ >
cres_qresult< std::size_t > kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::count ( ) const
inline
Returns
the number of datasets in this document.

◆ create()

template<typename _TDerive_ >
static cres_qresult< Derive > kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::create ( const kDB::Repository::Connection & _connection,
const knowCore::Uri & _graph )
inlinestatic

Create a new kDB::Repository::TripleStore with uri _graph, add it to the union of collections Uris::kdb_sensing::datasets.

Returns
an invalid Collection if an error occurs or if the collection already exists

◆ get()

template<typename _TDerive_ >
static cres_qresult< Derive > kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::get ( const kDB::Repository::Connection & _connection,
const knowCore::Uri & _graph )
inlinestatic

Return an unique instance of the collection stored in _graph for a given _connection

Returns
an invalid Collection if it does not exists

◆ getOrCreate()

template<typename _TDerive_ >
static cres_qresult< Derive > kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::getOrCreate ( const kDB::Repository::Connection & _connection,
const knowCore::Uri & _graph )
inlinestatic

Create or access the collection specified in _graph

Returns
an invalid Collection if an error occurs

◆ isReadOnly()

template<typename _TDerive_ >
bool kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::isReadOnly ( ) const
inline
Returns
true if it can only be used to access datasets and not insert one.

◆ isValid()

template<typename _TDerive_ >
bool kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::isValid ( ) const
inline
Returns
true if it is a valid collection of datasets

◆ uri()

template<typename _TDerive_ >
knowCore::Uri kDB::Repository::RDF::FocusNodeCollectionWrapper< _TDerive_ >::uri ( ) const
inline
Returns
the uri for the graph

The documentation for this class was generated from the following file: