private function persistGeneric(
        NodeInterface $node,
        DocumentAccessor $accessor,
        $fieldName,
        $locale,
        array $fieldMapping
    ) {
        try {
            $phpcrName = $this->encoder->encode($fieldMapping['encoding'], $fieldMapping['property'], $locale);
            $value = $accessor->get($fieldName);
            $this->validateFieldValue($value, $fieldName, $fieldMapping);
            $node->setProperty($phpcrName, $value);
        } catch (InvalidLocaleException $ex) {
            // arguments invalid, no valid propertyname could be generated (e.g. no locale given for localized encoding)
            return;
        }
    }
private function persistGeneric(
        NodeInterface $node,
        DocumentAccessor $accessor,
        $fieldName,
        $locale,
        array $fieldMapping
    ) {
        try {
            $phpcrName = $this->encoder->encode($fieldMapping['encoding'], $fieldMapping['property'], $locale);
            $value = $accessor->get($fieldName);
            $this->validateFieldValue($value, $fieldName, $fieldMapping);
            $node->setProperty($phpcrName, $value);
        } catch (InvalidLocaleException $ex) {
            // arguments invalid, no valid propertyname could be generated (e.g. no locale given for localized encoding)
            return;
        }
    }
private function persistGeneric ( NodeInterface $ node , DocumentAccessor $ accessor , $ fieldName , $ locale , array $ fieldMapping ) { try { $ phpcrName = $ this -> encoder -> encode ( $ fieldMapping [ 'encoding' ] , $ fieldMapping [ 'property' ] , $ locale ) ; $ value = $ accessor -> get ( $ fieldName ) ; $ this -> validateFieldValue ( $ value , $ fieldName , $ fieldMapping ) ; $ node -> setProperty ( $ phpcrName , $ value ) ; } catch ( InvalidLocaleException $ ex ) { // arguments invalid, no valid propertyname could be generated (e.g. no locale given for localized encoding) return ; } }
Persist "scalar" field types.

@param NodeInterface $node
@param DocumentAccessor $accessor
@param mixed $fieldName
@param mixed $locale
@param array $fieldMapping
Persist scalar field types .