source/Spiral/ORM/Schemas/Definitions/RelationDefinition.php
public function withContext(RelationContext $source, RelationContext $target = null): self
    {
        $definition = clone $this;
        $definition->sourceContext = $source;
        $definition->targetContext = $target;

        return $definition;
    }
public function withContext(RelationContext $source, RelationContext $target = null): self
    {
        $definition = clone $this;
        $definition->sourceContext = $source;
        $definition->targetContext = $target;

        return $definition;
    }
public function withContext ( RelationContext $ source , RelationContext $ target = null ) : self { $ definition = clone $ this ; $ definition -> sourceContext = $ source ; $ definition -> targetContext = $ target ; return $ definition ; }
Set relation contexts.

@param RelationContext      $source
@param RelationContext|null $target

@return RelationDefinition
Set relation contexts .