Classes | Defines | Typedefs | Functions

pd_DocumentRDF.cpp File Reference

#include "pd_DocumentRDF.h"
#include "pd_Document.h"
#include "pt_PieceTable.h"
#include "ut_debugmsg.h"
#include "pf_Frag_Object.h"
#include "pf_Frag_Strux.h"
#include "pp_Property.h"
#include "ut_std_string.h"
#include "ut_conversion.h"
#include "xap_App.h"
#include <sstream>
#include <set>
#include <fstream>
#include <iterator>
#include "pd_RDFQuery.h"
#include "xap_Frame.h"
#include "fv_View.h"

Classes

class  PD_SemanticItemFactoryNull
class  PD_RDFDialogsNull
class  PD_RDFModelFromAP
class  PD_RDFModelFromStartEndPos
 The idea of this class is to be able to slice up a document's RDF. More...
class  PD_RDFModelFromStartEndPos::StatementIterator
class  RDFModel_SPARQLLimited
 A view on the given delegate model, restricted to showing only the triples which match a given SPARQL query. More...
class  RDFModel_XMLIDLimited
class  PD_RDFMutation_XMLIDLimited

Defines

#define DEBUG_LOWLEVEL_IO   0

Typedefs

typedef std::map< std::string,
std::string > 
stringmap_t

Functions

std::pair< PT_DocPosition,
PT_DocPosition
runInsertReferenceDialog (FV_View *pView)
 Insert a reference to a semenatic item.
void runSemanticStylesheetsDialog (FV_View *pView)
static std::string readLengthPrefixedString (std::istream &iss)
 Read a string which is prefixed with it's length in ascii from the given stream.
static std::string createLengthPrefixedString (const std::string &s)
 Given a string z, create a new string which contains the length of z as an ascii string, a space and then z itself.
static std::string combinePO (const PD_URI &p, const PD_Object &o)
 Given an predicate and object, create a serialized "packed" double of these two.
static std::pair< PD_URI,
PD_Object
splitPO (const std::string &po)
 Split up a packed double that contains a predicate and object.
static POCol decodePOCol (const std::string &data)
 Decode a list of predicate,object pairings that was created with encodePOCol().
static std::string encodePOCol (const POCol &l)
 Encode a list of predicate,object pairings into a single string.
bool operator< (const std::pair< PD_URI, PD_URI > &a, const PD_URI &b)
bool operator< (const PD_URI &a, const std::pair< PD_URI, PD_URI > &b)

Define Documentation

#define DEBUG_LOWLEVEL_IO   0

Typedef Documentation

typedef std::map< std::string, std::string > stringmap_t

Function Documentation

static std::string combinePO ( const PD_URI p,
const PD_Object o 
) [static]

Given an predicate and object, create a serialized "packed" double of these two.

See also:
splitPO()

References PD_Object::write(), and PD_URI::write().

Referenced by encodePOCol().

static std::string createLengthPrefixedString ( const std::string &  s  )  [static]

Given a string z, create a new string which contains the length of z as an ascii string, a space and then z itself.

Parameters:
s the string z to create a length z string from
Returns:
a string containing the length of z, a space, then z

Referenced by encodePOCol(), PD_Object::write(), and PD_URI::write().

static POCol decodePOCol ( const std::string &  data  )  [static]
static std::string encodePOCol ( const POCol l  )  [static]
bool operator< ( const std::pair< PD_URI, PD_URI > &  a,
const PD_URI b 
)
bool operator< ( const PD_URI a,
const std::pair< PD_URI, PD_URI > &  b 
)
static std::string readLengthPrefixedString ( std::istream &  iss  )  [static]

Read a string which is prefixed with it's length in ascii from the given stream.

Parameters:
iss stream to read length and string from
Returns:
string

References DEBUG_LOWLEVEL_IO, and UT_DEBUGMSG.

Referenced by decodePOCol(), PD_Object::read(), and PD_URI::read().

std::pair< PT_DocPosition, PT_DocPosition > runInsertReferenceDialog ( FV_View pView  ) 

Insert a reference to a semenatic item.

References PD_DocumentRDF::getRDFDialogs(), and PD_RDFDialogs::runInsertReferenceDialog().

Referenced by Defun1().

void runSemanticStylesheetsDialog ( FV_View pView  ) 
static std::pair< PD_URI, PD_Object > splitPO ( const std::string &  po  )  [static]

Split up a packed double that contains a predicate and object.

See also:
combinePO()

References PD_Object::read(), and PD_URI::read().

Referenced by decodePOCol().