Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Example Stock Item class without dependency injection
<?php
class StockItem {
private $quantity;
private $status;
public function __construct($quantity, $status){
$this->quantity = $quantity;
$this->status = $status;
}
public function getQuantity(){
return $this->quantity;
}
public function getStatus(){
return $this->status;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.