public function associate($type, array $items = null)
    {
        if ($this->getOwner() === null) {
            throw new DomainException('Unable to associate relations to a collection that does not have an owning entity!');
        }
        if ($type instanceof Entity\Content) {
            $this->addEntity((string) $type->getContenttype(), $type->getId(), $this->getOwner());

            return;
        }

        if (is_iterable($type)) {
            foreach ($type as $entity) {
                if ($entity instanceof Entity\Content) {
                    $this->associate($entity);
                }
            }

            return;
        }

        foreach ($items as $item) {
            $this->addEntity($type, $item, $this->getOwner());
        }
    }