Created
August 18, 2017 06:25
-
-
Save parth7676/5de4f93b9e883a94c4b129d0371b994a to your computer and use it in GitHub Desktop.
Notifiable Property C# Code Snippet.
This file contains 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
<?xml version="1.0" encoding="utf-8"?> | |
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet"> | |
<CodeSnippet Format="1.0.0"> | |
<Header> | |
<SnippetTypes> | |
<SnippetType>Expansion</SnippetType> | |
</SnippetTypes> | |
<Title>propn</Title> | |
<Author>Microsoft Corporation</Author> | |
<Description>Code snippet for an automatically implemented $name$Property | |
Language Version: C# 3.0 or higher</Description> | |
<HelpUrl> | |
</HelpUrl> | |
<Shortcut>propn</Shortcut> | |
</Header> | |
<Snippet> | |
<Declarations> | |
<Literal Editable="true"> | |
<ID>name</ID> | |
<ToolTip>name</ToolTip> | |
<Default>name</Default> | |
<Function> | |
</Function> | |
</Literal> | |
<Literal Editable="true"> | |
<ID>Name</ID> | |
<ToolTip>Name</ToolTip> | |
<Default>Name</Default> | |
<Function> | |
</Function> | |
</Literal> | |
<Literal Editable="true"> | |
<ID>type</ID> | |
<ToolTip>type</ToolTip> | |
<Default>Type</Default> | |
<Function> | |
</Function> | |
</Literal> | |
</Declarations> | |
<Code Language="csharp"><![CDATA[ | |
private $type$ $name$; | |
public $type$ $Name$ | |
{ | |
get { return $name$; } | |
set { SetPropertyValue("$Name$", ref $name$, value); } | |
} | |
$end$]]></Code> | |
</Snippet> | |
</CodeSnippet> | |
</CodeSnippets> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment