Libraryless. Click here for Pure Java version (6213L/35K).
sclass Tok_SettableWithChangeFields > Tok_SettableOrGettableFields { *() { super("settableWithChange"); } *(S keyword) { super(keyword); } S replacement() { ret tok_formatDollarVars( "$fMod selfType $var aka $setVar($type $var) { if (!eq(this.$var, $var)) { this.$var = $var; change(); } this; }\n" + "gettable $modifiers $type", fMod := joinWithSpace(functionModifiers()) + " public", modifiers := joinWithSpace(modifiers), +type, +var, setVar := "set" + firstToUpper(var)); } }
Began life as a copy of #1033794
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, ekrmjmnbrukm, mowyntqkapby, mqqgnosmbjvj
No comments. add comment
| Snippet ID: | #1034142 | 
| Snippet name: | Tok_SettableWithChangeFields | 
| Eternal ID of this version: | #1034142/4 | 
| Text MD5: | 4a47bd59b8dede939be938892b017f2d | 
| Transpilation MD5: | 876261cb570897d4dc9045e1ed77fbfe | 
| Author: | stefan | 
| Category: | javax / transpiling | 
| Type: | JavaX fragment (include) | 
| Public (visible to everyone): | Yes | 
| Archived (hidden from active list): | No | 
| Created/modified: | 2022-02-07 19:46:09 | 
| Source code size: | 543 bytes / 14 lines | 
| Pitched / IR pitched: | No / No | 
| Views / Downloads: | 360 / 499 | 
| Version history: | 3 change(s) | 
| Referenced in: | [show references] |