Contains the data and behavior for a single part in a Multipart FormData request body.
Added to Cake\Network\Http\FormData when sending data to a remote server.
$_contentId
protected string
$_disposition
protected string
$_filename
protected string
$_name
protected string
$_transferEncoding
protected string
$_type
protected string
$_value
protected string
__construct( string $name , string $value , string $disposition 'form-data' )
Constructor
$name
$value
$disposition
optional 'form-data' __toString( )
Convert the part into a string.
Creates a string suitable for use in HTTP requests.
contentId( null|string $id null )
Get/set the contentId for a part.
$id
optional null disposition( null|string $disposition null )
Get/set the disposition type
By passing in false
you can disable the disposition header from being added.
$disposition
optional null filename( null|string $filename null )
Get/set the filename.
Setting the filename to false
will exclude it from the generated output.
$filename
optional null transferEncoding( null|string $type )
Set the transfer-encoding for multipart.
Useful when content bodies are in encodings like base64.
$type
type( null|string $type )
Get/set the content type.
$type
© 2005–2016 The Cake Software Foundation, Inc.
Licensed under the MIT License.
CakePHP is a registered trademark of Cake Software Foundation, Inc.
We are not endorsed by or affiliated with CakePHP.
http://api.cakephp.org/3.2/class-Cake.Network.Http.FormData.Part.html