Skip to content

Dictionary

Methods

__construct

Returns a new Dictionary object.

public __construct(\SplFixedArray $pairs): mixed

Parameters:

Parameter Type Description
$pairs \SplFixedArray

Throws:


fromNative

Returns a new Dictionary object.

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

Throws:


keys

Returns a Collection of the keys.

public keys(): \Qubus\ValueObjects\Structure\Collection

Throws:


values

Returns a Collection of the values.

public values(): \Qubus\ValueObjects\Structure\Collection

Throws:


containsKey

Tells whether $object is one of the keys.

public containsKey(\Qubus\ValueObjects\ValueObject $object): bool

Parameters:

Parameter Type Description
$object \Qubus\ValueObjects\ValueObject

Throws:


containsValue

Tells whether $object is one of the values.

public containsValue(\Qubus\ValueObjects\ValueObject $object): bool

Parameters:

Parameter Type Description
$object \Qubus\ValueObjects\ValueObject

Throws:


Inherited methods

__construct

Returns a new Collection object.

public __construct(\SplFixedArray $items): mixed

Parameters:

Parameter Type Description
$items \SplFixedArray

Throws:


__toString

Returns a native string representation of the Collection object.

public __toString(): string

fromNative

Returns a new Collection object.

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

Throws:


equals

Tells whether two Collection are equal by comparing their size and items (item order matters).

public equals(\Qubus\ValueObjects\Structure\Collection|\Qubus\ValueObjects\ValueObject $collection): bool

Parameters:

Parameter Type Description
$collection \Qubus\ValueObjects\Structure\Collection|\Qubus\ValueObjects\ValueObject

Throws:


count

Returns the number of objects in the collection.

public count(): \Qubus\ValueObjects\Number\Natural

Throws:


contains

Tells whether the Collection contains an object.

public contains(\Qubus\ValueObjects\ValueObject $object): bool

Parameters:

Parameter Type Description
$object \Qubus\ValueObjects\ValueObject

toArray

Returns a native array representation of the Collection.

public toArray(): array


Automatically generated on 2025-10-13