[ Index ]

PHP Cross Reference of moodle-2.8

title

Body

[close]

/lib/google/Google/Http/ -> MediaFileUpload.php (summary)

Copyright 2012 Google Inc. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

File Size: 292 lines (8 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

Google_Http_MediaFileUpload:: (9 methods):
  __construct()
  setFileSize()
  getProgress()
  getHttpResultCode()
  nextChunk()
  process()
  transformToUploadUrl()
  getUploadType()
  getResumeUri()


Class: Google_Http_MediaFileUpload  - X-Ref


__construct(Google_Client $client,Google_Http_Request $request,$mimeType,$data,$resumable = false,$chunkSize = false,$boundary = false)   X-Ref

param: $mimeType string
param: $data string The bytes you want to upload.
param: $resumable bool
param: bool $chunkSize File will be uploaded in chunks of this many bytes.

setFileSize($size)   X-Ref
Set the size of the file that is being uploaded.

param: $size - int file size in bytes

getProgress()   X-Ref
Return the progress on the upload

return: int progress in bytes uploaded.

getHttpResultCode()   X-Ref
Return the HTTP result code from the last call made.

return: int code

nextChunk($chunk = false)   X-Ref
Send the next part of the file to upload.

param: [$chunk] the next set of bytes to send. If false will used $data passed

process()   X-Ref

param: $meta
param: $params
return: array|bool

transformToUploadUrl()   X-Ref
No description

getUploadType($meta)   X-Ref
Valid upload types:
- resumable (UPLOAD_RESUMABLE_TYPE)
- media (UPLOAD_MEDIA_TYPE)
- multipart (UPLOAD_MULTIPART_TYPE)

param: $meta
return: string

getResumeUri()   X-Ref
No description



Generated: Fri Nov 28 20:29:05 2014 Cross-referenced by PHPXref 0.7.1