Exemple #1
0
 private function serialize(VisitorInterface $visitor, $data, Type $type, Context $context)
 {
     if ($visitor instanceof XmlSerializationVisitor && false === $this->xmlCData) {
         return $visitor->visitSimpleString($data);
     }
     return $visitor->visitString($data, $type, $context);
 }
 public function serializeFormError(VisitorInterface $visitor, FormError $formError, Type $type, Context $context)
 {
     return $visitor->visitString($this->getErrorMessage($formError), $type, $context);
 }