public function Carbon::addYears in Persian Date for Drupal 8 8.4
Add years to the instance. Positive $value travel forward while negative $value travel into the past.
Parameters
int $value:
Return value
static
3 calls to Carbon::addYears()
- Carbon::addCenturies in src/
Library/ Carbon/ Carbon.php - Add centuries to the instance. Positive $value travels forward while negative $value travels into the past.
- Carbon::addYear in src/
Library/ Carbon/ Carbon.php - Add a year to the instance
- Carbon::subYears in src/
Library/ Carbon/ Carbon.php - Remove years from the instance.
File
- src/
Library/ Carbon/ Carbon.php, line 1969
Class
- Carbon
- A simple API extension for DateTime
Namespace
Drupal\persian_date\Library\CarbonCode
public function addYears($value) {
return $this
->modify((int) $value . ' year');
}