som changes for uniform look of snippets
This commit is contained in:
parent
21a683b04d
commit
41c1148f34
@ -70,7 +70,7 @@ snippet simc
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
snippet svm
|
snippet svm
|
||||||
${1:public }static void Main(string[] args){
|
${1:public }static void Main(string[] args) {
|
||||||
${0}
|
${0}
|
||||||
}
|
}
|
||||||
# if condition
|
# if condition
|
||||||
@ -172,32 +172,32 @@ snippet ctor
|
|||||||
# properties - auto properties by default.
|
# properties - auto properties by default.
|
||||||
# default type is int with layout get / set.
|
# default type is int with layout get / set.
|
||||||
snippet prop
|
snippet prop
|
||||||
${1:public} ${2:int} ${3:} { get; set; }
|
${1:public} ${2:int} ${3} { get; set; }
|
||||||
snippet p
|
snippet p
|
||||||
${1:public} ${2:int} ${3:} { get; set; }
|
${1:public} ${2:int} ${3} { get; set; }
|
||||||
snippet p+
|
snippet p+
|
||||||
public ${1:int} ${2:} { get; set; }
|
public ${1:int} ${2} { get; set; }
|
||||||
snippet p+&
|
snippet p+&
|
||||||
public ${1:int} ${2:} { get; internal set; }
|
public ${1:int} ${2} { get; internal set; }
|
||||||
snippet p+|
|
snippet p+|
|
||||||
public ${1:int} ${2:} { get; protected set; }
|
public ${1:int} ${2} { get; protected set; }
|
||||||
snippet p+-
|
snippet p+-
|
||||||
public ${1:int} ${2:} { get; private set; }
|
public ${1:int} ${2} { get; private set; }
|
||||||
snippet p&
|
snippet p&
|
||||||
internal ${1:int} ${2:} { get; set; }
|
internal ${1:int} ${2} { get; set; }
|
||||||
snippet p&|
|
snippet p&|
|
||||||
internal ${1:int} ${2:} { get; protected set; }
|
internal ${1:int} ${2} { get; protected set; }
|
||||||
snippet p&-
|
snippet p&-
|
||||||
internal ${1:int} ${2:} { get; private set; }
|
internal ${1:int} ${2} { get; private set; }
|
||||||
snippet p|
|
snippet p|
|
||||||
protected ${1:int} ${2:} { get; set; }
|
protected ${1:int} ${2} { get; set; }
|
||||||
snippet p|-
|
snippet p|-
|
||||||
protected ${1:int} ${2:} { get; private set; }
|
protected ${1:int} ${2} { get; private set; }
|
||||||
snippet p-
|
snippet p-
|
||||||
private ${1:int} ${2:} { get; set; }
|
private ${1:int} ${2} { get; set; }
|
||||||
# property - bool
|
# property - bool
|
||||||
snippet pi
|
snippet pi
|
||||||
${1:public} int ${2:} { get; set; }
|
${1:public} int ${2} { get; set; }
|
||||||
snippet pi+
|
snippet pi+
|
||||||
public int ${1} { get; set; }
|
public int ${1} { get; set; }
|
||||||
snippet pi+&
|
snippet pi+&
|
||||||
@ -220,7 +220,7 @@ snippet pi-
|
|||||||
private int ${1} { get; set; }
|
private int ${1} { get; set; }
|
||||||
# property - bool
|
# property - bool
|
||||||
snippet pb
|
snippet pb
|
||||||
${1:public} bool ${2:} { get; set; }
|
${1:public} bool ${2} { get; set; }
|
||||||
snippet pb+
|
snippet pb+
|
||||||
public bool ${1} { get; set; }
|
public bool ${1} { get; set; }
|
||||||
snippet pb+&
|
snippet pb+&
|
||||||
@ -243,7 +243,7 @@ snippet pb-
|
|||||||
private bool ${1} { get; set; }
|
private bool ${1} { get; set; }
|
||||||
# property - string
|
# property - string
|
||||||
snippet ps
|
snippet ps
|
||||||
${1:public} string ${2:} { get; set; }
|
${1:public} string ${2} { get; set; }
|
||||||
snippet ps+
|
snippet ps+
|
||||||
public string ${1} { get; set; }
|
public string ${1} { get; set; }
|
||||||
snippet ps+&
|
snippet ps+&
|
||||||
@ -266,87 +266,87 @@ snippet ps-
|
|||||||
private string ${1} { get; set; }
|
private string ${1} { get; set; }
|
||||||
# members - void
|
# members - void
|
||||||
snippet m
|
snippet m
|
||||||
${1:public} ${2:void} ${3:}(${4:}) {
|
${1:public} ${2:void} ${3}(${4}) {
|
||||||
${5:}
|
${0}
|
||||||
}
|
}
|
||||||
snippet m+
|
snippet m+
|
||||||
public ${1:void} ${2:}(${3:}) {
|
public ${1:void} ${2}(${3}) {
|
||||||
${4:}
|
${0}
|
||||||
}
|
}
|
||||||
snippet m&
|
snippet m&
|
||||||
internal ${1:void} ${2:}(${3:}) {
|
internal ${1:void} ${2}(${3}) {
|
||||||
${4:}
|
${0}
|
||||||
}
|
}
|
||||||
snippet m|
|
snippet m|
|
||||||
protected ${1:void} ${2:}(${3:}) {
|
protected ${1:void} ${2}(${3}) {
|
||||||
${4:}
|
${0}
|
||||||
}
|
}
|
||||||
snippet m-
|
snippet m-
|
||||||
private ${1:void} ${2:}(${3:}) {
|
private ${1:void} ${2}(${3}) {
|
||||||
${4:}
|
${0}
|
||||||
}
|
}
|
||||||
# members - int
|
# members - int
|
||||||
snippet mi
|
snippet mi
|
||||||
${1:public} int ${2:}(${3:}) {
|
${1:public} int ${2}(${3}) {
|
||||||
${4:return 0;}
|
${0:return 0;}
|
||||||
}
|
}
|
||||||
snippet mi+
|
snippet mi+
|
||||||
public int ${1:}(${2:}) {
|
public int ${1}(${2}) {
|
||||||
${3:return 0;}
|
${0:return 0;}
|
||||||
}
|
}
|
||||||
snippet mi&
|
snippet mi&
|
||||||
internal int ${1:}(${2:}) {
|
internal int ${1}(${2}) {
|
||||||
${3:return 0;}
|
${0:return 0;}
|
||||||
}
|
}
|
||||||
snippet mi|
|
snippet mi|
|
||||||
protected int ${1:}(${2:}) {
|
protected int ${1}(${2}) {
|
||||||
${3:return 0;}
|
${0:return 0;}
|
||||||
}
|
}
|
||||||
snippet mi-
|
snippet mi-
|
||||||
private int ${1:}(${2:}) {
|
private int ${1}(${2}) {
|
||||||
${3:return 0;}
|
${0:return 0;}
|
||||||
}
|
}
|
||||||
# members - bool
|
# members - bool
|
||||||
snippet mb
|
snippet mb
|
||||||
${1:public} bool ${2:}(${3:}) {
|
${1:public} bool ${2}(${3}) {
|
||||||
${4:return false;}
|
${0:return false;}
|
||||||
}
|
}
|
||||||
snippet mb+
|
snippet mb+
|
||||||
public bool ${1:}(${2:}) {
|
public bool ${1}(${2}) {
|
||||||
${3:return false;}
|
${0:return false;}
|
||||||
}
|
}
|
||||||
snippet mb&
|
snippet mb&
|
||||||
internal bool ${1:}(${2:}) {
|
internal bool ${1}(${2}) {
|
||||||
${3:return false;}
|
${0:return false;}
|
||||||
}
|
}
|
||||||
snippet mb|
|
snippet mb|
|
||||||
protected bool ${1:}(${2:}) {
|
protected bool ${1}(${2}) {
|
||||||
${3:return false;}
|
${0:return false;}
|
||||||
}
|
}
|
||||||
snippet mb-
|
snippet mb-
|
||||||
private bool ${1:}(${2:}) {
|
private bool ${1}(${2}) {
|
||||||
${3:return false;}
|
${0:return false;}
|
||||||
}
|
}
|
||||||
# members - string
|
# members - string
|
||||||
snippet ms
|
snippet ms
|
||||||
${1:public} string ${2:}(${3:}) {
|
${1:public} string ${2}(${3}) {
|
||||||
${4:return "";}
|
${0:return "";}
|
||||||
}
|
}
|
||||||
snippet ms+
|
snippet ms+
|
||||||
public string ${1:}(${2:}) {
|
public string ${1}(${2}) {
|
||||||
${3:return "";}
|
${0:return "";}
|
||||||
}
|
}
|
||||||
snippet ms&
|
snippet ms&
|
||||||
internal string ${1:}(${2:}) {
|
internal string ${1}(${2}) {
|
||||||
${3:return "";}
|
${0:return "";}
|
||||||
}
|
}
|
||||||
snippet ms|
|
snippet ms|
|
||||||
protected string ${1:}(${2:}) {
|
protected string ${1:}(${2:}) {
|
||||||
${3:return "";}
|
${0:return "";}
|
||||||
}
|
}
|
||||||
snippet ms-
|
snippet ms-
|
||||||
private string ${1:}(${2:}) {
|
private string ${1}(${2}) {
|
||||||
${3:return "";}
|
${0:return "";}
|
||||||
}
|
}
|
||||||
# structure
|
# structure
|
||||||
snippet struct
|
snippet struct
|
||||||
@ -391,8 +391,8 @@ snippet cw
|
|||||||
|
|
||||||
# equals override
|
# equals override
|
||||||
snippet eq
|
snippet eq
|
||||||
public override bool Equals(object obj){
|
public override bool Equals(object obj) {
|
||||||
if (obj == null || GetType() != obj.GetType()){
|
if (obj == null || GetType() != obj.GetType()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
${0:throw new NotImplementedException();}
|
${0:throw new NotImplementedException();}
|
||||||
@ -400,7 +400,7 @@ snippet eq
|
|||||||
}
|
}
|
||||||
# exception
|
# exception
|
||||||
snippet exc
|
snippet exc
|
||||||
public class ${1:MyException} : ${2:Exception}{
|
public class ${1:MyException} : ${2:Exception} {
|
||||||
public $1() { }
|
public $1() { }
|
||||||
public $1(string message) : base(message) { }
|
public $1(string message) : base(message) { }
|
||||||
public $1(string message, Exception inner) : base(message, inner) { }
|
public $1(string message, Exception inner) : base(message, inner) { }
|
||||||
@ -411,62 +411,62 @@ snippet exc
|
|||||||
}
|
}
|
||||||
# indexer
|
# indexer
|
||||||
snippet index
|
snippet index
|
||||||
public ${1:object} this[${2:int} index]{
|
public ${1:object} this[${2:int} index] {
|
||||||
get { ${3:} }
|
get { ${0} }
|
||||||
set { ${0:} }
|
set { ${0} }
|
||||||
}
|
}
|
||||||
# eventhandler
|
# eventhandler
|
||||||
snippet inv
|
snippet inv
|
||||||
EventHandler temp = ${1:MyEvent};
|
EventHandler temp = ${1:MyEvent};
|
||||||
if (${2:temp} != null){
|
if (${2:temp} != null) {
|
||||||
$2();
|
$2();
|
||||||
}
|
}
|
||||||
# lock
|
# lock
|
||||||
snippet lock
|
snippet lock
|
||||||
lock (${1:this}){
|
lock (${1:this}) {
|
||||||
${0:}
|
${0}
|
||||||
}
|
}
|
||||||
# namespace
|
# namespace
|
||||||
snippet namespace
|
snippet namespace
|
||||||
namespace ${1:MyNamespace}{
|
namespace ${1:MyNamespace} {
|
||||||
${0:}
|
${0}
|
||||||
}
|
}
|
||||||
# property
|
# property
|
||||||
snippet prop
|
snippet prop
|
||||||
public ${1:int} ${2:MyProperty} { get; set;}
|
public ${1:int} ${2:MyProperty} { get; set; }
|
||||||
snippet propf
|
snippet propf
|
||||||
private ${1:int} ${2:myVar};
|
private ${1:int} ${2:myVar};
|
||||||
|
|
||||||
public $1 ${3:MyProperty}{
|
public $1 ${3:MyProperty} {
|
||||||
get { return $2;}
|
get { return $2; }
|
||||||
set { $2 = value;}
|
set { $2 = value; }
|
||||||
}
|
}
|
||||||
snippet propg
|
snippet propg
|
||||||
public ${1:int} ${2:MyProperty} { get; private set; }
|
public ${1:int} ${2:MyProperty} { get; private set; }
|
||||||
# switch
|
# switch
|
||||||
snippet switch
|
snippet switch
|
||||||
switch (${1:switch_on}){
|
switch (${1:switch_on}) {
|
||||||
${0}
|
${0}
|
||||||
default:
|
default:
|
||||||
}
|
}
|
||||||
# try
|
# try
|
||||||
snippet try
|
snippet try
|
||||||
try{
|
try {
|
||||||
${0}
|
${0}
|
||||||
}
|
}
|
||||||
catch (${1:System.Exception}){
|
catch (${1:System.Exception}) {
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
snippet tryf
|
snippet tryf
|
||||||
try{
|
try {
|
||||||
${0}
|
${0}
|
||||||
}
|
}
|
||||||
finally{
|
finally {
|
||||||
${1}
|
${1}
|
||||||
}
|
}
|
||||||
# using
|
# using
|
||||||
snippet usi
|
snippet usi
|
||||||
using(${1:resource}){
|
using(${1:resource}) {
|
||||||
${0}
|
${0}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user