Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F7430891
Tuple2.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
864 B
Referenced Files
None
Subscribers
None
Tuple2.php
View Options
<?php
declare
(
strict_types
=
1
);
namespace
Phan\Library
;
/**
* A tuple of 2 elements.
*
* @template T0
* The type of element zero
*
* @template T1
* The type of element one
*
* @inherits Tuple1<T0>
* phpcs:disable PSR2.Classes.PropertyDeclaration.Underscore
*/
class
Tuple2
extends
Tuple1
{
/** @var int */
public
const
ARITY
=
2
;
/** @var T1 element 1 of this tuple (0-based index) */
public
$_1
;
/**
* @param T0 $_0
* The 0th element
*
* @param T1 $_1
* The 1st element
*/
public
function
__construct
(
$_0
,
$_1
)
{
$this
->
_0
=
$_0
;
$this
->
_1
=
$_1
;
}
/**
* @return array{0:T0,1:T1}
* An array of all elements in this tuple.
*/
public
function
toArray
():
array
{
return
[
$this
->
_0
,
$this
->
_1
,
];
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sun, Nov 22, 10:41 (8 h, 42 m)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
b2/2c/b5dce83b529c809358739b0047fd
Default Alt Text
Tuple2.php (864 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment