OQueryTableConnection::OQueryTableConnection(const OQueryTableConnection& rConn)
: VclReferenceBase(),
OTableConnection( rConn )
, m_bVisited(false)
{ // no own members, so base class functionality is sufficient
}
OTableConnection::operator=(rConn); // no own members ... return *this;
}
bool OQueryTableConnection::operator==(const OQueryTableConnection& rCompare) const
{
OSL_ENSURE(GetData() && rCompare.GetData(), "OQueryTableConnection::operator== : one of the two participants has no data!");
// I don't have to compare all too much (especially not all the members) : merely the windows, which we are connected to, and the indices in the corresponding table have to match.
OQueryTableConnectionData* pMyData = static_cast<OQueryTableConnectionData*>(GetData().get());
OQueryTableConnectionData* pCompData = static_cast<OQueryTableConnectionData*>(rCompare.GetData().get());
// Connections are seen as equal, if source and destination window names and source and destination field Indices match... return ( ( (pMyData->getReferencedTable() == pCompData->getReferencedTable()) &&
(pMyData->getReferencingTable() == pCompData->getReferencingTable()) &&
(pMyData->GetFieldIndex(JTCS_TO) == pCompData->GetFieldIndex(JTCS_TO)) &&
(pMyData->GetFieldIndex(JTCS_FROM) == pCompData->GetFieldIndex(JTCS_FROM))
)
|| // ... or this cross matching is given
( (pMyData->getReferencingTable() == pCompData->getReferencedTable()) &&
(pMyData->getReferencedTable() == pCompData->getReferencingTable()) &&
(pMyData->GetFieldIndex(JTCS_TO) == pCompData->GetFieldIndex(JTCS_FROM)) &&
(pMyData->GetFieldIndex(JTCS_FROM) == pCompData->GetFieldIndex(JTCS_TO))
)
);
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.