Created
June 8, 2016 20:30
-
-
Save Mulkave/12ae8ab3e0113ca6013889c35b44fe62 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Directory\Foundation; | |
class Value | |
{ | |
protected $value; | |
public function __construct($value) | |
{ | |
$this->setValue($value); | |
} | |
public function validation(array $input, array $rules) | |
{ | |
return app(‘Directory\Foundation\Validation’) | |
->make($input, $rules); | |
} | |
public function setValue($value) | |
{ | |
$this->value = $value; | |
} | |
public function getValue() | |
{ | |
return $this->value; | |
} | |
public function __toString() | |
{ | |
return sprintf(‘%s’, $this->value); | |
} | |
public function __set($name, $value) | |
{ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment