public static function textBatch(Api\MtBatchTextSmsCreate $batch)
    {
        $fields = Serialize::_createBatchHelper($batch);

        $fields['type'] = 'mt_text';
        $fields['body'] = $batch->getBody();

        if (!empty($batch->getParameters())) {
            $fields['parameters'] = $batch->getParameters();
        }

        return Serialize::_toJson($fields);
    }
public static function textBatch(Api\MtBatchTextSmsCreate $batch)
    {
        $fields = Serialize::_createBatchHelper($batch);

        $fields['type'] = 'mt_text';
        $fields['body'] = $batch->getBody();

        if (!empty($batch->getParameters())) {
            $fields['parameters'] = $batch->getParameters();
        }

        return Serialize::_toJson($fields);
    }
public static function textBatch ( Api \ MtBatchTextSmsCreate $ batch ) { $ fields = Serialize :: _createBatchHelper ( $ batch ) ; $ fields [ 'type' ] = 'mt_text' ; $ fields [ 'body' ] = $ batch -> getBody ( ) ; if ( ! empty ( $ batch -> getParameters ( ) ) ) { $ fields [ 'parameters' ] = $ batch -> getParameters ( ) ; } return Serialize :: _toJson ( $ fields ) ; }
Serializes the given text batch into JSON.

@param Api\MtBatchTextSmsCreate $batch the batch to serialize

@return string JSON formatted string
Serializes the given text batch into JSON .