src/Descriptor/RelationsMap.php
public function set($key, $value)
    {
        if (! $value instanceof RelationInterface) {
            throw new InvalidArgumentException(
                "Only RelationInterface objects can be putted in a ".
                "RelationsMap."
            );
        }
        return parent::set($key, $value);
    }
public function set($key, $value)
    {
        if (! $value instanceof RelationInterface) {
            throw new InvalidArgumentException(
                "Only RelationInterface objects can be putted in a ".
                "RelationsMap."
            );
        }
        return parent::set($key, $value);
    }
public function set ( $ key , $ value ) { if ( ! $ value instanceof RelationInterface ) { throw new InvalidArgumentException ( "Only RelationInterface objects can be putted in a " . "RelationsMap." ) ; } return parent :: set ( $ key , $ value ) ; }
Puts a new relation in the map.

@param mixed $key
@param mixed $value

@return RelationsMap
Puts a new relation in the map .