Download the PHP package osw3/php-cloud-manager without Composer
On this page you can find all versions of the php package osw3/php-cloud-manager. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download osw3/php-cloud-manager
More information about osw3/php-cloud-manager
Files in osw3/php-cloud-manager
Package php-cloud-manager
Short Description Provides cloud connection and file manipulation tools.
License MIT
Homepage https://osw3.net
Informations about the package php-cloud-manager
Cloud Manager
Provides cloud connection and file manipulation tools.
How to install
Supported services
- Dropbox
- FTP
How to use
Create new connection
Prepare the DSN
Client instance
Don't auto connect
DSN Infos
-
dsn(): DsnService
Bridge to DsnService.
-
getDriver(): ?string
-
getHost(): ?string
-
getUser(): ?string
-
getPass(): ?string
-
getAuth(): ?int
Get the Auth mode
-
getToken(): ?int
-
getPort(): ?int
-
get(): ?string
Get the DSN string
Driver Statement
-
connect(): bool
Proceed to driver connection and return the connection state
-
disconnect(): bool
Proceed to disconnection and return the connection status
-
isConnected(): bool
return
true
when the driver is connected
Temp directory
-
setTempDirectory(string $directory): static
Set the local server Temp directory for file manipulation.
-
getTempDirectory(): string
Get the local server Temp directory for file manipulation.
Navigation
-
location(): string
Return the current location (like PWD)
-
navigateTo(string $folder): bool
Set the pointer to a specific folder.
-
parent(): bool
Set the pointer to a parent folder.
-
root(): bool
Set the pointer to the root of the driver.
Entry infos
-
infos(?string $path=null, ?string $part=null): array|string
Retrieve the entry infos. Return an array if $part is null.
-
isFolder(string $path): bool
True if $path is a folder type.
-
isDirectory(string $path): bool
An alias of isFolder
-
isFile(string $path): bool
True if $path is a file type.
-
isLink(string $path): bool
True if $path is a link type.
-
isBlock(string $path): bool
True if $path is a block type
-
isCharacter(string $path): bool
True if $path is a character type.
-
isSocket(string $path): bool
True if $path is a socket type.
-
isPipe(string $path): bool
True if $path is a pipe type.
Permissions
-
permissions(string $path, ?int $code=null): string|bool
Permissions getter and setter. Set permission to path if
$code
is notnull
. Get permission code if$code
isnull
-
setPermission(string $path, int $code): bool
Set permissions code to a $path
-
getPermission(string $path): string
Read permissions code from a $path
Folder API
-
browse(?string $directory=null): array
Return the content of a directory, like the Unix PWD command. Return the current pointer location content if the
$directory
parameter isnull
. -
createFolder(string $directory, int $permissions=0700, bool $navigateTo = true): bool
Create a directory and set the pointer into the new location id
$navigateTo
istrue
. -
deleteFolder(?string $directory, bool $recursive=true): bool
Delete a directory and its contains.
-
duplicateFolder(string $source, string $destination): bool
Duplicate a directory on the Client
-
copyFolder(string $source, string $destination): bool
Alias for
duplicateFolder
. -
moveFolder(string $source, string $destination, bool $override=false): bool
Move a folder (cut + paste)
-
uploadFolder(string $source, string $destination, bool $override=false): bool
Send a directory from your server to the remote Client
-
downloadFolder(string $source, string $destination, bool $override=false): bool
Get a directory from a Client to your server
Files API
-
createFile(string $filename, string $content="", bool $binary=false): bool
Create a file from Stream to the Client.
-
deleteFile(?string $filename): bool
Delete a file from a Client.
-
duplicateFile(string $source, string $destination): bool
Duplicate a file on the Client
-
copyFile(string $source, string $destination): bool
Alias for
duplicateFile
. -
moveFile(string $source, string $destination, bool $override=false): bool
Move a file
-
uploadFile(string $source, string $destination, bool $override=false): bool
Send a file from your server to the remote Client
-
downloadFile(string $source, string $destination, bool $override=false): bool
Get a file from a Client to your server
Folder & Files API (Hybrid aliases of previous API)
-
delete(?string $path, bool $recursive=true): bool
;Delete a directory or a file
-
duplicate(string $source, string $destination): bool
;Duplicate a directory or a file
-
copy(string $source, string $destination): bool
;Alias of
duplicate
-
move(string $source, string $destination): bool
;Duplicate a directory or a file and delete the
$source
. -
rename(string $source, string $destination): bool
;Alias of
move
-
upload(string $source, string $destination, bool $override=false): bool
;Send a directory or a file from your server to the Client
-
download(string $source, string $destination, bool $override=false): bool
;Get a directory or a file from the Client to your server