Open
Description
Hi,
-
Question about inheritance: is it allowed? Cause the class is not final, but properties are
private
, and static methods use & returnself
instead ofstatic
, making inheritance not really possible (parent class will be returned instead of child) -
Asking 1. because I just need a method that return the value. Using
valueOr
is a bit disturbing when usinghasValue
.
$data = [];
$some = Option::some('value');
if ($some->hasValue()) {
$data[] = $some->valueOr(null); // this is disturbing
}
Regards,
Metadata
Metadata
Assignees
Labels
No labels