COPASI API  4.40.278
CRDFSubject Class Reference

#include <CRDFSubject.h>

Public Types

enum  eSubjectType { RESOURCE = 0 , BLANK_NODE }
 

Public Member Functions

void clearData ()
 
 CRDFSubject ()
 
 CRDFSubject (const CRDFSubject &src)
 
const std::string & getBlankNodeID () const
 
const std::string & getResource () const
 
const eSubjectTypegetType () const
 
const bool & isLocal () const
 
CRDFSubjectoperator= (const CRDFSubject &rhs)
 
void setBlankNodeId (const std::string &blankNodeId)
 
void setResource (const std::string &resource, const bool &isLocal)
 
void setType (const eSubjectType &type)
 
 ~CRDFSubject ()
 

Private Member Functions

bool operator== (const CRDFSubject &rhs) const
 

Private Attributes

std::string mBlankNodeId
 
bool mIsLocalResource
 
std::string mResource
 
eSubjectType mType
 

Member Enumeration Documentation

◆ eSubjectType

The two different types possible for subjects

Enumerator
RESOURCE 
BLANK_NODE 

Constructor & Destructor Documentation

◆ CRDFSubject() [1/2]

CRDFSubject::CRDFSubject ( )

Default Constructor

◆ CRDFSubject() [2/2]

CRDFSubject::CRDFSubject ( const CRDFSubject src)

Copy Constructor

Parameters
constCRDFSubject & src

◆ ~CRDFSubject()

CRDFSubject::~CRDFSubject ( )

Destructor

Member Function Documentation

◆ clearData()

void CRDFSubject::clearData ( )

Reset all Data

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

◆ getBlankNodeID()

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

Retrieve the ID of the blank node of the subject

Returns
const std::string & blankNodeId

References mBlankNodeId.

Referenced by CRDFGraph::addTriplet(), operator<<(), CRDFNode::setSubject(), and CRDFWriter::write().

◆ getResource()

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

Retrieve the resource of the subject

Returns
const std::string & resource

References mResource.

Referenced by CRDFGraph::addTriplet(), CRDFGraph::guessGraphRoot(), operator<<(), and CRDFWriter::write().

◆ getType()

const CRDFSubject::eSubjectType & CRDFSubject::getType ( ) const

Retrieve the type of the subject

Returns
const eSubjectType & type

References mType.

Referenced by CRDFGraph::addTriplet(), CRDFGraph::guessGraphRoot(), operator<<(), CRDFNode::setSubject(), and CRDFWriter::write().

◆ isLocal()

const bool & CRDFSubject::isLocal ( ) const

Check whehter the resource is local

Returns
const bool & isLocal

References mIsLocalResource.

Referenced by CRDFGraph::addTriplet(), CRDFGraph::guessGraphRoot(), and setResource().

◆ operator=()

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

◆ operator==()

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

◆ setBlankNodeId()

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

Set the ID of the blank node of the subject

Parameters
conststd::string & blankNodeId

References mBlankNodeId.

Referenced by CRDFNode::setObject(), and CRDFParser::TripleHandler().

◆ setResource()

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

Set the resource of the subject

Parameters
conststd::string & resource
constbool & isLocal

References isLocal(), mIsLocalResource, and mResource.

Referenced by CRDFGraph::createAboutNode(), and CRDFParser::TripleHandler().

◆ setType()

void CRDFSubject::setType ( const eSubjectType type)

Set the type of the subject

Parameters
consteSubjectType & type

References mType.

Referenced by CRDFGraph::createAboutNode(), CRDFNode::setObject(), and CRDFParser::TripleHandler().

Member Data Documentation

◆ mBlankNodeId

std::string CRDFSubject::mBlankNodeId
private

The Id of the blank node for type BLANK_NODE

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

◆ mIsLocalResource

bool CRDFSubject::mIsLocalResource
private

Stores whether the reources is resolve locally or remotely.

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

◆ mResource

std::string CRDFSubject::mResource
private

The URI of the resource of type RESOURCE

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

◆ mType

eSubjectType CRDFSubject::mType
private

The type of the subject

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


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