Skip to content

Instantly share code, notes, and snippets.

@hagbarddenstore
Created August 6, 2013 17:37
Show Gist options
  • Save hagbarddenstore/6166681 to your computer and use it in GitHub Desktop.
Save hagbarddenstore/6166681 to your computer and use it in GitHub Desktop.
Coding guidelines
public class A
{
// Fields
public const string PublicConstField = "";
protected const string ProtectedConstField = "";
private const string PrivateConstField = "";
public static string PublicStaticField = "";
protected static string ProtectedStaticField = "";
private static string PrivateStaticField = "";
public string PublicField = "";
protected string ProtectedField = "";
private string PrivateField = "";
// Events
public event EventHandler<EventArgs> PublicEvent;
protected event EventHandler<EventArgs> ProtectedEvent;
private event EventHandler<EventArgs> PrivateEvent;
// Constructors
static A()
{
}
public A()
{
}
protected A()
{
}
private A()
{
}
// Properties
public static string PublicStaticProperty { get; set; }
protected static string ProtectedStaticProperty { get; set; }
private static string PrivateStaticString { get; set; }
public string PublicProperty { get; set; }
protected string ProtectedProperty { get; set; }
private string PrivateProperty { get; set; }
// Methods
public static void PublicStaticMethod()
{
}
protected static void ProtectedStaticMethod()
{
}
private static void PrivateStaticMethod()
{
}
public void PublicMethod()
{
}
protected void ProtectedMethod()
{
}
private void PrivateMethod()
{
}
// Classes
public class PublicClass
{
}
protected class ProtectedClass
{
}
private class PrivateClass
{
}
// Enums
public enum PublicEnum
{
}
protected enum ProtectedEnum
{
}
private enum PrivateEnum
{
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment