Skip to content

KeyValuePair

Properties

key

protected \Qubus\ValueObjects\ValueObject $key

value

protected \Qubus\ValueObjects\ValueObject $value

Methods

__construct

Returns a KeyValuePair.

public __construct(\Qubus\ValueObjects\ValueObject $key, \Qubus\ValueObjects\ValueObject $value): mixed

Parameters:

Parameter Type Description
$key \Qubus\ValueObjects\ValueObject
$value \Qubus\ValueObjects\ValueObject

__toString

Returns a string representation of the KeyValuePair in format "$key => $value".

public __toString(): string

fromNative

Returns a KeyValuePair from native PHP arguments evaluated as strings.

public static fromNative(): \Qubus\ValueObjects\Structure\KeyValuePair|\Qubus\ValueObjects\ValueObject
  • This method is static.

Throws:


equals

Tells whether two KeyValuePair are equal.

public equals(\Qubus\ValueObjects\Structure\KeyValuePair|\Qubus\ValueObjects\ValueObject $keyValuePair): bool

Parameters:

Parameter Type Description
$keyValuePair \Qubus\ValueObjects\Structure\KeyValuePair|\Qubus\ValueObjects\ValueObject

getKey

Returns key.

public getKey(): \Qubus\ValueObjects\ValueObject

getValue

Returns value.

public getValue(): \Qubus\ValueObjects\ValueObject


Automatically generated on 2025-10-13