Nextcloud PHP API (master)

JrdResponse
in package
implements IResponse

FinalYes

A JSON Document Format (JDF) response to a well-known request

Tags
ref

https://tools.ietf.org/html/rfc6415#appendix-A

ref

https://tools.ietf.org/html/rfc7033#section-4.4

since
21.0.0

Table of Contents

Interfaces

IResponse

Properties

$aliases  : array<string|int, string>
$expires  : string|null
$links  : array<string|int, mixed>
$properties  : array<string|int, string|null>
$subject  : string

Methods

__construct()  : mixed
addAlias()  : $this
Add an alias
addLink()  : JrdResponse
Add a link
addProperty()  : $this
Add a property
isEmpty()  : bool
Does this response have any data attached to it?
setExpires()  : $this
toHttpResponse()  : Response

Properties

$aliases

private array<string|int, string> $aliases = []

$properties

private array<string|int, string|null> $properties = []

Methods

__construct()

public __construct(string $subject) : mixed
Parameters
$subject : string

https://tools.ietf.org/html/rfc7033#section-4.4.1

Tags
since
21.0.0

addAlias()

Add an alias

public addAlias(string $alias) : $this
Parameters
$alias : string
Tags
ref

https://tools.ietf.org/html/rfc7033#section-4.4.2

since
21.0.0
Return values
$this

Add a link

public addLink(string $rel, string|null $type, string|null $href[, array<string|int, string>|null $titles = [] ][, string|null $properties = [] ]) : JrdResponse
Parameters
$rel : string

https://tools.ietf.org/html/rfc7033#section-4.4.4.1

$type : string|null

https://tools.ietf.org/html/rfc7033#section-4.4.4.2

$href : string|null

https://tools.ietf.org/html/rfc7033#section-4.4.4.3

$titles : array<string|int, string>|null = []

https://tools.ietf.org/html/rfc7033#section-4.4.4.4

$properties : string|null = []

https://tools.ietf.org/html/rfc7033#section-4.4.4.5

Tags
ref

https://tools.ietf.org/html/rfc7033#section-8.4

psalm-param

array<string,(string|null)>|null $properties https://tools.ietf.org/html/rfc7033#section-4.4.4.5

since
21.0.0
Return values
JrdResponse

addProperty()

Add a property

public addProperty(string $property, string|null $value) : $this
Parameters
$property : string
$value : string|null
Tags
ref

https://tools.ietf.org/html/rfc7033#section-4.4.3

since
21.0.0
Return values
$this

isEmpty()

Does this response have any data attached to it?

public isEmpty() : bool
Tags
since
21.0.0
Return values
bool

setExpires()

public setExpires(string $expires) : $this
Parameters
$expires : string
Tags
since
21.0.0
Return values
$this

toHttpResponse()

public toHttpResponse() : Response
Tags
since
21.0.0
Return values
Response

        
On this page

Search results