Created
February 27, 2014 20:22
-
-
Save dhrrgn/9258747 to your computer and use it in GitHub Desktop.
Sublime Text Snippet for creating a Getter/Setter in PHP.
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
| <snippet> | |
| <content><![CDATA[ | |
| /** | |
| * ${1:Get the Var} | |
| * | |
| * @return ${2:string} | |
| */ | |
| public function get${3:Var}() | |
| { | |
| return \$this->${4:var}; | |
| } | |
| /** | |
| * ${5:Set the Var} | |
| * | |
| * @param $2 \$$4 ${6:The Var} | |
| */ | |
| public function set$3(\$$4) | |
| { | |
| \$this->$4 = \$$4; | |
| } | |
| ]]></content> | |
| <tabTrigger>getset</tabTrigger> | |
| <scope>source.php</scope> | |
| </snippet> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment