OC_FileChunking

class OC_FileChunking
Source:lib/private/legacy/OC_FileChunking.php#33

Properties

protected static property OC_FileChunking::$info
Source:lib/private/legacy/OC_FileChunking.php#34
protected static property OC_FileChunking::$cache
Source:lib/private/legacy/OC_FileChunking.php#35
protected static property OC_FileChunking::$ttl
TTL of chunks
Source:lib/private/legacy/OC_FileChunking.php#42
Type:int

Methods

public static OC_FileChunking::decodeName($name)
Source:lib/private/legacy/OC_FileChunking.php#44
public OC_FileChunking::__construct($info)
Source:

lib/private/legacy/OC_FileChunking.php#52

Parameters:
  • $info (string[])
public OC_FileChunking::getPrefix()
Source:lib/private/legacy/OC_FileChunking.php#57
protected OC_FileChunking::getCache()
Source:lib/private/legacy/OC_FileChunking.php#64
public OC_FileChunking::store($index, $data)
Stores the given $data under the given $key - the number of stored bytes is returned
Source:

lib/private/legacy/OC_FileChunking.php#78

Parameters:
  • $index (string)
  • $data (resource)
Returns:

int

public OC_FileChunking::isComplete()
Source:lib/private/legacy/OC_FileChunking.php#86
public OC_FileChunking::assemble($f)
Assembles the chunks into the file specified by the path.
Chunks are deleted afterwards.
Source:

lib/private/legacy/OC_FileChunking.php#111

Parameters:
  • $f (resource) target path
Returns:

int assembled file size

Throws:

\OC\InsufficientStorageException when file could not be fully assembled due to lack of free space

public OC_FileChunking::getCurrentSize()
Returns the size of the chunks already present
Source:lib/private/legacy/OC_FileChunking.php#131
Returns:int size in bytes
public OC_FileChunking::cleanup()
Removes all chunks which belong to this transmission
Source:lib/private/legacy/OC_FileChunking.php#144
public OC_FileChunking::remove($index)
Removes one specific chunk
Source:

lib/private/legacy/OC_FileChunking.php#156

Parameters:
  • $index (string)
public OC_FileChunking::file_assemble($storage, $path)
Assembles the chunks into the file specified by the path.
Also triggers the relevant hooks and proxies.
Source:

lib/private/legacy/OC_FileChunking.php#172

Parameters:
Returns:

bool true on success or false if file could not be created

Throws:

\OC\ServerNotAvailableException