From 7a6bb0f05e349068b0a89514f1da33d6d7de30a9 Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Tue, 24 Apr 2012 23:29:38 +0200 Subject: emacs.d/lisp/yasnippet: added yasnippet --- .../lisp/yasnippet/snippets/csharp-mode/attrib.2 | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 emacs.d/lisp/yasnippet/snippets/csharp-mode/attrib.2 (limited to 'emacs.d/lisp/yasnippet/snippets/csharp-mode/attrib.2') diff --git a/emacs.d/lisp/yasnippet/snippets/csharp-mode/attrib.2 b/emacs.d/lisp/yasnippet/snippets/csharp-mode/attrib.2 new file mode 100644 index 0000000..566eacf --- /dev/null +++ b/emacs.d/lisp/yasnippet/snippets/csharp-mode/attrib.2 @@ -0,0 +1,21 @@ +#contributor : Alejandro Espinoza Esparza +#name : private _attribute ....; public Property ... ... { ... } +# -- +/// +/// $3 +/// +private $1 ${2:$(if (> (length text) 0) (format "_%s%s" (downcase (substring text 0 1)) (substring text 1 (length text))) "")}; + +/// +/// ${3:Description} +/// +/// $1 +public ${1:Type} ${2:Name} +{ + get { + return this.${2:$(if (> (length text) 0) (format "_%s%s" (downcase (substring text 0 1)) (substring text 1 (length text))) "")}; + } + set { + this.${2:$(if (> (length text) 0) (format "_%s%s" (downcase (substring text 0 1)) (substring text 1 (length text))) "")} = value; + } +} -- cgit v1.2.3