ILinkDescriptorCmd::GetRelationshipType

The GetRelationshipType method returns the location of the link item relative to the other linked objects.

RelationshipType enLinkType = spILinkDescriptor->GetRelationshipType();
Parameters
None.
Results
Returns a RelationshipType enumeration, that defines the location of the link item relative to the other linked objects, which can be set to one of the following:
- eTypeLinkTo, indicates that the object store item is the first or head link in the list.
- eTypeLinkFrom, indicates that the object store item is the last or tail link in the list.
Sample
   _bstr_t bstrLinkClassID = spILinkDescriptor->GetLinkClassId();
std::cout << "Link Class ID=" << (bstrLinkClassID.length() ? (LPCSTR) bstrLinkClassID : _T("")) << std::endl; _bstr_t bstrPropertiesXml = spILinkDescriptor->GetPropertiesXml();
std::cout << "Properties XML=" << (bstrPropertiesXml.length() ? (LPCSTR) bstrPropertiesXml : _T("")) << std::endl; std::cout << "Relationship=" << (LPCSTR) CItemTypeConverter::EnumToBSTR(spILinkDescriptor->GetRelationshipType()) << std::endl; IObjectStoreItemPtr spIObjectStoreItemLinked = spILinkDescriptor->GetObjectStoreItem();
std::cout << "ObjectStoreName=" << (LPCSTR) spIObjectStoreItemLinked->GetObjectStoreName() << std::endl;
std::cout << "ItemType=" << (LPCSTR) CItemTypeConverter::EnumToBSTR(spIObjectStoreItemLinked->GetItemType()) << std::endl;
std::cout << "VersionSeriesID=" << (LPCSTR) spIObjectStoreItemLinked->GetVersionSeriesID() << std::endl;
std::cout << "VersionID=" << (LPCSTR) spIObjectStoreItemLinked->GetVersionID() << std::endl;