WireArray is the base iterable array type used throughout the ProcessWire framework.
Nearly all collections of items in ProcessWire are derived from the Wire Below are all the public methods you can use to interact with Wire Click any linked item for full usage details and examples. Hookable methods are indicated with the icon. In addition to those shown below, the These methods are only useful for hooking and should not be called directly. In addition to the methods and properties above, Wireforeach()
them and get or set elements using array syntax, i.e. $value = $items[$key];
to get an item or $items[] = $item;
to add an item.Wire
class also inherits all the methods and properties of: Wire.Traversal
Name Return Summary Wire
Return a new copy of this Wire array
null
string
Wire
Perform an action upon each item in the Wire Wire
mixed
bool
Returns the first item in the Wire
Can also be used as property: Wire ArrayObject
Wire
Allows iteration of the Wire Wire
mixed
bool
Returns the last item in the Wire
Can also be used as property: Wire array
Divide this Wire Retrieval
Manipulation
Info
Name Return Summary bool
Does this Wire bool
Is the given Wire bool
Is the given item valid for storange in this array? bool
Is the given item key valid for use in this array? bool
Determines if the given item iterable as an array. Output rendering
Name Return Summary array
null
string
Wire
Perform an action upon each item in the Wire string
Combine all elements into a delimiter-separated string containing the given property from each item Other data storage
Name Return Summary Wire
mixed
array
null
Store or retrieve an extra data value in this Wire $this
Remove a property/value previously set with the Wire Changes
Name Return Summary array
Wire
Return array of all items added to this Wire array
Wire
Return array of all items removed from this Wire Fun tools
Name Return Summary Wire
Return a new copy of this Wire null
mixed
Handler for when an unknown/unhooked method call is executed array
null
string
Wire
Perform an action upon each item in the Wire array
Return a plain array of the requested property from each item string
Combine all elements into a delimiter-separated string containing the given property from each item For hooks
Name Return Summary null
mixed
Handler for when an unknown/unhooked method call is executed Common
Name Return Summary static
) Wire array
All keys used in this Wire (nothing) Set the current duplicate checking state Wire array
All values used in this Wire Additional methods and properties
API reference based on ProcessWire core version 3.0.236