\Pydio\Access\CoreSchemeTranslatorWrapper

Class SchemeTranslatorWrapper Simple Wrapper that justs converts a given protocol to another one.

Global streamWrapper that encapsulates all wrappers to access a driver's resource. Registered under the "pydio" protocol, it should replace all the old ajxp.XX direct calls. The static "appendMetaWrapper" method allows to add additional wrapper that will be sequentially called until reaching the driver ajxp.XX wrapper.

Summary

Methods
Properties
Constants
register()
detectWrapperForNode()
appendMetaWrapper()
translateScheme()
actualRepositoryWrapperClass()
actualRepositoryWrapperProtocol()
applyInitPathHook()
getRealFSReference()
copyFileInStream()
changeMode()
isRemote()
isSeekable()
wrapperIsRemote()
wrapperIsSeekable()
nodesUseSameWrappers()
dir_closedir()
dir_opendir()
dir_readdir()
dir_rewinddir()
mkdir()
rename()
rmdir()
stream_close()
stream_eof()
stream_flush()
stream_open()
stream_read()
stream_seek()
stream_stat()
stream_tell()
stream_write()
unlink()
url_stat()
getResolvedOptionsForNode()
No public properties found
No constants found
getMetaWrappers()
getNextScheme()
findWrapperClassName()
findSubWrapperClassName()
actualRepositoryWrapperData()
innerReadDirFiltered()
$handle
$currentDirPath
$metaWrappers
$metaWrappersOrders
$cachedRepositoriesWrappers
$currentUniquePath
N/A
No private methods found
No private properties found
N/A

Properties

$handle

$handle : resource

Type

resource

$currentDirPath

$currentDirPath : string

Type

string

$metaWrappers

$metaWrappers : 

Type

$metaWrappersOrders

$metaWrappersOrders : 

Type

$cachedRepositoriesWrappers

$cachedRepositoriesWrappers : 

Type

$currentUniquePath

$currentUniquePath : 

Type

Methods

register()

register(null  $registered_wrappers = null) 

Register the stack of protocols/wrappers.

Parameters

null $registered_wrappers

detectWrapperForNode()

detectWrapperForNode(\Pydio\Access\Core\Model\AJXP_Node  $node, boolean  $register = false, array|null  $streams = null, array|boolean  $streamData = false) : boolean

Check if a repository accessDriver declares a streamWrapper, and eventually register it.

Parameters

\Pydio\Access\Core\Model\AJXP_Node $node
boolean $register
array|null $streams
array|boolean $streamData

Returns

boolean

appendMetaWrapper()

appendMetaWrapper(  $name,   $className, integer  $order = 50, string  $parent = "core") 

Register an addition protocol/wrapper in the stack

Parameters

$name

string

$className

string

integer $order
string $parent

Throws

\Pydio\Core\Exception\PydioException

translateScheme()

translateScheme(string  $url, \Pydio\Access\Core\MetaStreamWrapper  $crtInstance = null) : string

Parameters

string $url
\Pydio\Access\Core\MetaStreamWrapper $crtInstance

Throws

\Exception

Returns

string

actualRepositoryWrapperClass()

actualRepositoryWrapperClass(  $node) : string

Return the final ajxp.XX wrapper class name.

Parameters

$node

AJXP_Node

Throws

\Exception

Returns

string —

mixed

actualRepositoryWrapperProtocol()

actualRepositoryWrapperProtocol(  $node) : string

Return the final ajxp.XX wrapper protocol.

Parameters

$node

AJXP_Node

Throws

\Exception

Returns

string —

mixed

applyInitPathHook()

applyInitPathHook(string  $path,   $context = 'core') 

Initialise the path for a file

Parameters

string $path
$context

getRealFSReference()

getRealFSReference(string  $path, boolean  $persistent = false) : string

Get a "usable" reference to a file : the real file or a tmp copy.

Parameters

string $path
boolean $persistent

Throws

\Exception

Returns

string

copyFileInStream()

copyFileInStream(string  $path, resource  $stream) 

Read a file (by chunks) and copy the data directly inside the given stream.

Parameters

string $path
resource $stream

changeMode()

changeMode(string  $path, \Pydio\Access\Core\number  $chmodValue) 

Chmod implementation for this type of access.

Parameters

string $path
\Pydio\Access\Core\number $chmodValue

isRemote()

isRemote() : boolean

Describe whether the current wrapper operates on a remote server or not.

Throws

\Exception

Returns

boolean

isSeekable()

isSeekable(String  $url) : boolean

Describe whether the current wrapper operates on a remote server or not.

Parameters

String $url

Url of the resource

Throws

\Exception

Returns

boolean

wrapperIsRemote()

wrapperIsRemote(string  $url) : boolean

Parameters

string $url

Returns

boolean

wrapperIsSeekable()

wrapperIsSeekable(string  $url) : boolean

Parameters

string $url

Returns

boolean

nodesUseSameWrappers()

nodesUseSameWrappers(  $url1,   $url2) : boolean

Parameters

$url1
$url2

Returns

boolean

dir_closedir()

dir_closedir() : boolean

Returns

boolean

dir_opendir()

dir_opendir(string  $path, integer  $options) : boolean

Enter description here.

..

Parameters

string $path
integer $options

Returns

boolean

dir_readdir()

dir_readdir() : string

Enter description here.

..

Returns

string

dir_rewinddir()

dir_rewinddir() : boolean

Enter description here.

..

Returns

boolean

mkdir()

mkdir(string  $path, integer  $mode, integer  $options) : boolean

Enter description here.

..

Parameters

string $path
integer $mode
integer $options

Returns

boolean

rename()

rename(string  $path_from, string  $path_to) : boolean

Enter description here.

..

Parameters

string $path_from
string $path_to

Returns

boolean

rmdir()

rmdir(string  $path, integer  $options) : boolean

Enter description here.

..

Parameters

string $path
integer $options

Returns

boolean

stream_close()

stream_close() 

Enter description here.

..

stream_eof()

stream_eof() : boolean

Enter description here.

..

Returns

boolean

stream_flush()

stream_flush() : boolean

Enter description here.

..

Returns

boolean

stream_open()

stream_open(string  $path, string  $mode, integer  $options,   $context) : boolean

Enter description here.

..

Parameters

string $path
string $mode
integer $options
$context

Returns

boolean

stream_read()

stream_read(integer  $count) : string

Enter description here.

..

Parameters

integer $count

Returns

string

stream_seek()

stream_seek(integer  $offset, integer  $whence = SEEK_SET) : boolean

Enter description here.

..

Parameters

integer $offset
integer $whence

= SEEK_SET

Returns

boolean

stream_stat()

stream_stat() : array

Enter description here.

..

Returns

array

stream_tell()

stream_tell() : integer

Enter description here.

..

Returns

integer

stream_write()

stream_write(string  $data) : integer

Enter description here.

..

Parameters

string $data

Returns

integer

unlink()

unlink(string  $path) : boolean

Enter description here.

..

Parameters

string $path

Returns

boolean

url_stat()

url_stat(string  $path, integer  $flags) : array

Enter description here.

..

Parameters

string $path
integer $flags

Returns

array

getResolvedOptionsForNode()

getResolvedOptionsForNode(\Pydio\Access\Core\Model\AJXP_Node  $node) : array

Parameters

\Pydio\Access\Core\Model\AJXP_Node $node

Returns

array

getMetaWrappers()

getMetaWrappers(  $scheme) : array

Parameters

$scheme

Returns

array

getNextScheme()

getNextScheme(  $url, string  $context = 'core') : mixed

Parameters

$url
string $context

Throws

\Exception

Returns

mixed

findWrapperClassName()

findWrapperClassName(\Pydio\Core\Model\ContextInterface  $ctx,   $scheme, string  $context = "core") : mixed|string

Parameters

\Pydio\Core\Model\ContextInterface $ctx
$scheme
string $context

Throws

\Exception

Returns

mixed|string

findSubWrapperClassName()

findSubWrapperClassName(  $url) : mixed|string

Parameters

$url

Throws

\Exception

Returns

mixed|string

innerReadDirFiltered()

innerReadDirFiltered(Resource  $resource) : string

Skip values until correct one is found

Parameters

Resource $resource

Returns

string