public function unbind($value) : Data { Assertion::isArray($value); $data = Data::none(); foreach ($value as $index => $individualValue) { $data = $data->merge($this->wrappedMapping->withPrefixAndRelativeKey($this->key, (string) $index)->unbind($individualValue)); } return $data; }
public function withMapping(string $key, MappingInterface $mapping) : self { $clone = clone $this; $clone->mappings[$key] = $mapping->withPrefixAndRelativeKey($clone->key, $key); return $clone; }