Documentation

Address
in package
uses ArrayEnabled

Table of Contents

Constants

ADDRESS_ABSOLUTE  = 1
ADDRESS_COLUMN_RELATIVE  = 2
ADDRESS_RELATIVE  = 4
ADDRESS_ROW_RELATIVE  = 3
REFERENCE_STYLE_A1  = true
REFERENCE_STYLE_R1C1  = false

Properties

$arrayArgumentHelper  : ArrayArgumentHelper
$initializationNeeded  : bool

Methods

cell()  : array<string|int, mixed>|string
ADDRESS.
evaluateArrayArguments()  : array<string|int, mixed>
Handles array argument processing when the function accepts multiple arguments, and any of them can be an array argument.
evaluateArrayArgumentsIgnore()  : array<string|int, mixed>
Handles array argument processing when the function accepts multiple arguments, and any of them can be an array argument except for the one specified by ignore.
evaluateArrayArgumentsSubset()  : array<string|int, mixed>
Handles array argument processing when the function accepts multiple arguments, but only the first few (up to limit) can be an array arguments.
evaluateArrayArgumentsSubsetFrom()  : array<string|int, mixed>
Handles array argument processing when the function accepts multiple arguments, but only the last few (from start) can be an array arguments.
evaluateSingleArgumentArray()  : array<string|int, mixed>
Handles array argument processing when the function accepts a single argument that can be an array argument.
formatAsA1()  : string
formatAsR1C1()  : string
initialiseHelper()  : void
sheetName()  : string
testFalse()  : bool

Constants

ADDRESS_ABSOLUTE

public mixed ADDRESS_ABSOLUTE = 1

ADDRESS_COLUMN_RELATIVE

public mixed ADDRESS_COLUMN_RELATIVE = 2

ADDRESS_RELATIVE

public mixed ADDRESS_RELATIVE = 4

ADDRESS_ROW_RELATIVE

public mixed ADDRESS_ROW_RELATIVE = 3

REFERENCE_STYLE_A1

public mixed REFERENCE_STYLE_A1 = true

REFERENCE_STYLE_R1C1

public mixed REFERENCE_STYLE_R1C1 = false

Properties

$initializationNeeded

private static bool $initializationNeeded = true

Methods

cell()

ADDRESS.

public static cell(mixed $row, mixed $column[, mixed $relativity = 1 ][, mixed $referenceStyle = true ][, mixed $sheetName = '' ]) : array<string|int, mixed>|string

Creates a cell address as text, given specified row and column numbers.

Excel Function: =ADDRESS(row, column, [relativity], [referenceStyle], [sheetText])

Parameters
$row : mixed

Row number (integer) to use in the cell reference Or can be an array of values

$column : mixed

Column number (integer) to use in the cell reference Or can be an array of values

$relativity : mixed = 1

Integer flag indicating the type of reference to return 1 or omitted Absolute 2 Absolute row; relative column 3 Relative row; absolute column 4 Relative Or can be an array of values

$referenceStyle : mixed = true

A logical (boolean) value that specifies the A1 or R1C1 reference style. TRUE or omitted ADDRESS returns an A1-style reference FALSE ADDRESS returns an R1C1-style reference Or can be an array of values

$sheetName : mixed = ''

Optional Name of worksheet to use Or can be an array of values

Return values
array<string|int, mixed>|string

If an array of values is passed as the $testValue argument, then the returned result will also be an array with the same dimensions

evaluateArrayArguments()

Handles array argument processing when the function accepts multiple arguments, and any of them can be an array argument.

protected static evaluateArrayArguments(callable $method, mixed ...$arguments) : array<string|int, mixed>

Example use for: ROUND() or DATE().

Parameters
$method : callable
$arguments : mixed
Return values
array<string|int, mixed>

evaluateArrayArgumentsIgnore()

Handles array argument processing when the function accepts multiple arguments, and any of them can be an array argument except for the one specified by ignore.

protected static evaluateArrayArgumentsIgnore(callable $method, int $ignore, mixed ...$arguments) : array<string|int, mixed>

Example use for: HLOOKUP() and VLOOKUP(), where argument 1 is a matrix that needs to be treated as a database rather than as an array argument.

Parameters
$method : callable
$ignore : int
$arguments : mixed
Return values
array<string|int, mixed>

evaluateArrayArgumentsSubset()

Handles array argument processing when the function accepts multiple arguments, but only the first few (up to limit) can be an array arguments.

protected static evaluateArrayArgumentsSubset(callable $method, int $limit, mixed ...$arguments) : array<string|int, mixed>

Example use for: NETWORKDAYS() or CONCATENATE(), where the last argument is a matrix (or a series of values) that need to be treated as a such rather than as an array arguments.

Parameters
$method : callable
$limit : int
$arguments : mixed
Return values
array<string|int, mixed>

evaluateArrayArgumentsSubsetFrom()

Handles array argument processing when the function accepts multiple arguments, but only the last few (from start) can be an array arguments.

protected static evaluateArrayArgumentsSubsetFrom(callable $method, int $start, mixed ...$arguments) : array<string|int, mixed>

Example use for: Z.TEST() or INDEX(), where the first argument 1 is a matrix that needs to be treated as a dataset rather than as an array argument.

Parameters
$method : callable
$start : int
$arguments : mixed
Return values
array<string|int, mixed>

evaluateSingleArgumentArray()

Handles array argument processing when the function accepts a single argument that can be an array argument.

protected static evaluateSingleArgumentArray(callable $method, array<string|int, mixed> $values) : array<string|int, mixed>

Example use for: DAYOFMONTH() or FACT().

Parameters
$method : callable
$values : array<string|int, mixed>
Return values
array<string|int, mixed>

formatAsA1()

private static formatAsA1(int $row, int $column, int $relativity, string $sheetName) : string
Parameters
$row : int
$column : int
$relativity : int
$sheetName : string
Return values
string

formatAsR1C1()

private static formatAsR1C1(int $row, int $column, int $relativity, string $sheetName) : string
Parameters
$row : int
$column : int
$relativity : int
$sheetName : string
Return values
string

initialiseHelper()

private static initialiseHelper(array<string|int, mixed>|false $arguments) : void
Parameters
$arguments : array<string|int, mixed>|false

Can be changed to array for Php8.1+

sheetName()

private static sheetName(string $sheetName) : string
Parameters
$sheetName : string
Return values
string

testFalse()

private static testFalse(mixed $value) : bool
Parameters
$value : mixed
Return values
bool

        
On this page

Search results