Bravo3\Orm\Mappers\Metadata\Relationship::getRelationshipType PHP Method

getRelationshipType() public method

Get relationship type
public getRelationshipType ( ) : RelationshipType
return Bravo3\Orm\Enum\RelationshipType
    public function getRelationshipType()
    {
        return $this->relationship_type;
    }

Usage Example

Example #1
0
 /**
  * Get an array containing an array of foreign entities to remove the local entity from, and an array of foreign
  * entities to add the local entity to and an array of entities which remain the same in the relationship
  *
  * @param string          $key          Local relationship key
  * @param Relationship    $relationship Relationship in question
  * @param object|object[] $new_value    New local value containing foreign entities
  * @return array
  */
 private function getRelationshipDeltas($key, Relationship $relationship, $new_value)
 {
     $this->getDriver()->debugLog('Getting inverse relationship deltas: ' . $key);
     if (RelationshipType::isMultiIndex($relationship->getRelationshipType())) {
         return $this->getRelationshipDeltasMulti($key, $new_value);
     } else {
         return $this->getRelationshipDeltasSingle($key, $new_value);
     }
 }
All Usage Examples Of Bravo3\Orm\Mappers\Metadata\Relationship::getRelationshipType