\OCP\Files\ExternalDefinitionParameter

Parameter for an external storage definition

Summary

Methods
Properties
Constants
__construct()
getName()
getText()
getType()
setType()
getTypeName()
getFlags()
setFlags()
setFlag()
isFlagSet()
jsonSerialize()
isOptional()
validateValue()
No public properties found
VALUE_TEXT
VALUE_BOOLEAN
VALUE_PASSWORD
VALUE_HIDDEN
FLAG_NONE
FLAG_OPTIONAL
FLAG_USER_PROVIDED
No protected methods found
No protected properties found
N/A
No private methods found
$name
$text
$type
$flags
N/A

Constants

VALUE_TEXT

VALUE_TEXT

Value constants

VALUE_BOOLEAN

VALUE_BOOLEAN

VALUE_PASSWORD

VALUE_PASSWORD

VALUE_HIDDEN

VALUE_HIDDEN

FLAG_NONE

FLAG_NONE

Flag constants

FLAG_OPTIONAL

FLAG_OPTIONAL

FLAG_USER_PROVIDED

FLAG_USER_PROVIDED

Properties

$name

$name : string

Type

string — name of parameter

$text

$text : string

Type

string — human-readable parameter text

$type

$type : integer

Type

integer — value type, see self::VALUE_* constants

$flags

$flags : integer

Type

integer — flags, see self::FLAG_* constants

Methods

__construct()

__construct(string  $name, string  $text) 

Parameters

string $name
string $text

getName()

getName() : string

Returns

string

getText()

getText() : string

Returns

string

getType()

getType() : integer

Get value type

Returns

integer

setType()

setType(integer  $type) : self

Set value type

Parameters

integer $type

Returns

self

getTypeName()

getTypeName() : string

Returns

string

getFlags()

getFlags() : integer

Returns

integer

setFlags()

setFlags(integer  $flags) : self

Parameters

integer $flags

Returns

self

setFlag()

setFlag(integer  $flag) : self

Parameters

integer $flag

Returns

self

isFlagSet()

isFlagSet(integer  $flag) : boolean

Parameters

integer $flag

Returns

boolean

jsonSerialize()

jsonSerialize() : string

Serialize into JSON for client-side JS

Returns

string

isOptional()

isOptional() : boolean

Returns whether the parameter is optional

Returns

boolean —

true if optional, false otherwise

validateValue()

validateValue(mixed  $value) : boolean

Validate a parameter value against this Convert type as necessary

Parameters

mixed $value

Value to check

Returns

boolean —

success