COPASI API  4.40.278
CRDFObject Class Reference

#include <CRDFObject.h>

Public Types

enum  eObjectType { RESOURCE = 0 , BLANK_NODE , LITERAL }
 

Public Member Functions

void clearData ()
 
 CRDFObject ()
 
 CRDFObject (const CRDFObject &src)
 
const std::string & getBlankNodeID () const
 
CRDFLiteralgetLiteral ()
 
const CRDFLiteralgetLiteral () const
 
const std::string & getResource () const
 
const eObjectTypegetType () const
 
const bool & isLocal () const
 
CRDFObjectoperator= (const CRDFObject &rhs)
 
void setBlankNodeId (const std::string &blankNodeId)
 
void setLiteral (const CRDFLiteral &literal)
 
void setResource (const std::string &resource, const bool &isLocal)
 
void setType (const eObjectType &type)
 
virtual ~CRDFObject ()
 

Private Member Functions

bool operator== (const CRDFObject &rhs) const
 

Private Attributes

std::string mBlankNodeId
 
bool mIsLocalResource
 
CRDFLiteralmpLiteral
 
std::string mResource
 
eObjectType mType
 

Member Enumeration Documentation

◆ eObjectType

The three different types possible for objects

Enumerator
RESOURCE 
BLANK_NODE 
LITERAL 

Constructor & Destructor Documentation

◆ CRDFObject() [1/2]

CRDFObject::CRDFObject ( )

Default Constructor

◆ CRDFObject() [2/2]

CRDFObject::CRDFObject ( const CRDFObject src)

Copy Constructor

Parameters
constCRDFObject & src

◆ ~CRDFObject()

CRDFObject::~CRDFObject ( )
virtual

Destructor

References mpLiteral, and pdelete.

Member Function Documentation

◆ clearData()

void CRDFObject::clearData ( )

Reset all Data

References mBlankNodeId, mIsLocalResource, mpLiteral, mResource, mType, and RESOURCE.

◆ getBlankNodeID()

const std::string & CRDFObject::getBlankNodeID ( ) const

Retrieve the ID of the blank node of the object

Returns
const std::string & blankNodeId

References mBlankNodeId.

Referenced by CRDFGraph::destroyUnreferencedNode(), CRDFNode::getFieldValue(), CRDFNode::setObject(), and CRDFWriter::write().

◆ getLiteral() [1/2]

CRDFLiteral & CRDFObject::getLiteral ( )

Retrieve the literal of the object

Returns
CRDFLiteral & literal

References mpLiteral.

Referenced by CRDFNode::getFieldValue(), CRDFNode::setFieldValue(), and CRDFWriter::write().

◆ getLiteral() [2/2]

const CRDFLiteral & CRDFObject::getLiteral ( ) const

Retrieve the literal of the object

Returns
const CRDFLiteral & literal

References mpLiteral.

◆ getResource()

const std::string & CRDFObject::getResource ( ) const

◆ getType()

const CRDFObject::eObjectType & CRDFObject::getType ( ) const

Retrieve the type of the object

Returns
const eObjectType & type

References mType.

Referenced by CRDFGraph::addTriplet(), CRDFGraph::destroyUnreferencedNode(), CRDFNode::getFieldValue(), CRDFNode::setFieldValue(), CRDFNode::setObject(), and CRDFWriter::write().

◆ isLocal()

const bool & CRDFObject::isLocal ( ) const

Check whehter the resource is local

Returns
const bool & isLocal

References mIsLocalResource.

Referenced by CRDFGraph::destroyUnreferencedNode(), and setResource().

◆ operator=()

CRDFObject & CRDFObject::operator= ( const CRDFObject rhs)

◆ operator==()

bool CRDFObject::operator== ( const CRDFObject rhs) const
private

◆ setBlankNodeId()

void CRDFObject::setBlankNodeId ( const std::string &  blankNodeId)

◆ setLiteral()

void CRDFObject::setLiteral ( const CRDFLiteral literal)

Set the literal of the object

Parameters
conststd::string & lexicalData

References mpLiteral, and pdelete.

Referenced by CRDFParser::TripleHandler().

◆ setResource()

void CRDFObject::setResource ( const std::string &  resource,
const bool &  isLocal 
)

◆ setType()

Member Data Documentation

◆ mBlankNodeId

std::string CRDFObject::mBlankNodeId
private

The Id of the blank node for type BLANK_NODE

Referenced by clearData(), getBlankNodeID(), operator=(), operator==(), and setBlankNodeId().

◆ mIsLocalResource

bool CRDFObject::mIsLocalResource
private

Stores whether the reources is resolve locally or remotely.

Referenced by clearData(), isLocal(), operator=(), operator==(), and setResource().

◆ mpLiteral

CRDFLiteral* CRDFObject::mpLiteral
mutableprivate

The pointer to the literal for type LITERAL

Referenced by clearData(), getLiteral(), operator=(), operator==(), setLiteral(), and ~CRDFObject().

◆ mResource

std::string CRDFObject::mResource
private

The URI of the resource of type RESOURCE

Referenced by clearData(), getResource(), operator=(), operator==(), and setResource().

◆ mType

eObjectType CRDFObject::mType
private

The type of the object

Referenced by clearData(), getType(), operator=(), operator==(), and setType().


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