Documentation

OcisResource
in package

Class representing a file or folder inside a Drive in ownCloud Infinite Scale

Table of Contents

Methods

createSharingLink()  : ShareLink
create a new (public) link
getCheckSums()  : array<int, array<string, string>>
getContent()  : string
returns the content of this resource
getContentStream()  : resource
returns a stream to get the content of this resource
getContentType()  : string
getEtag()  : string
getId()  : string
getLastModifiedTime()  : string
getName()  : string
getParent()  : string
getPermission()  : string
getPreview()  : string
the aspect-ratio of previews will be preserved even if not matching sizes are requested
getPrivatelink()  : string
Returns the private link to the resource.
getRoles()  : array<string|int, SharingRole>
Gets all possible Roles for the resource
getSize()  : int
getSpaceId()  : string
getTags()  : array<int, string>
getType()  : string
invite()  : ShareCreated
Invite a user or group to the resource.
isFavorited()  : bool

Methods

create a new (public) link

public createSharingLink([SharingLinkType $type = SharingLinkType::VIEW ][, DateTimeImmutable|null $expiration = null ][, string|null $password = null ][, string|null $displayName = null ]) : ShareLink
Parameters
$type : SharingLinkType = SharingLinkType::VIEW
$expiration : DateTimeImmutable|null = null
$password : string|null = null
$displayName : string|null = null
Tags
throws
UnauthorizedException
throws
ForbiddenException
throws
HttpException
throws
InvalidResponseException
throws
BadRequestException
throws
NotFoundException
throws
InternalServerErrorException
Return values
ShareLink

getPreview()

the aspect-ratio of previews will be preserved even if not matching sizes are requested

public getPreview(int $width, int $height) : string
Parameters
$width : int
$height : int
Return values
string

Returns the private link to the resource.

public getPrivatelink() : string

This link can be used by any user with the correct permissions to navigate to the resource in the web UI. The link is urldecoded.

Tags
throws
InvalidResponseException
Return values
string

invite()

Invite a user or group to the resource.

public invite(User|Group $recipient, SharingRole $role[, DateTimeImmutable|null $expiration = null ]) : ShareCreated

Every recipient will result in an own ShareCreated object in the returned array.

Parameters
$recipient : User|Group
$role : SharingRole
$expiration : DateTimeImmutable|null = null
Tags
throws
BadRequestException
throws
ForbiddenException
throws
HttpException
throws
InvalidResponseException
throws
NotFoundException
throws
UnauthorizedException
throws
InternalServerErrorException
Return values
ShareCreated

        
On this page

Search results