serialize() public method

public serialize ( ) : serialize
return serialize
 public function build()
 {
     $request = new PaymentRequest($this->card, $this->order, $this->billing, $this->delivery, $this->basket);
     $validator = new PaymentRequestValidator($request);
     $validator->validate();
     $serializer = new PaymentRequestSerializer($request, $this->configuration);
     $rawData = $serializer->serialize();
     $request->setRawData($rawData);
     return $request;
 }