Exemplo n.º 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);
 }
Exemplo n.º 2
0
 public function serializeFormError(VisitorInterface $visitor, FormError $formError, Type $type, Context $context)
 {
     return $visitor->visitString($this->getErrorMessage($formError), $type, $context);
 }