java getter setter snippet for sublime

May 7th, 2014
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <snippet>
  2.     <content><![CDATA[
  3. private ${1:returnType} ${2:property};
  5. public ${1:returnType} get${2/^(.)(.*)/\U$1\E$2/}(){
  6.     return ${2:property};
  7. }
  9. public void set${2/^(.)(.*)/\U$1\E$2/}(${1:returnType} ${2:property}){
  10.     this.${2:property} = ${2:property};
  11. }
  12. ]]></content>
  13.     <!-- Optional: Set a tabTrigger to define how to trigger the snippet -->
  14.     <tabTrigger>property</tabTrigger>
  15.     <!-- Optional: Set a scope to limit where the snippet will trigger -->
  16.     <scope>source.java</scope>
  17. </snippet>
RAW Paste Data

Adblocker detected! Please consider disabling it...

We've detected AdBlock Plus or some other adblocking software preventing Pastebin.com from fully loading.

We don't have any obnoxious sound, or popup ads, we actively block these annoying types of ads!

Please add Pastebin.com to your ad blocker whitelist or disable your adblocking software.