This page is designed to specify a coding guideline for contributors to Droid Explorer. These documents are a work in progress and are based on
Design Guidelines for Class Library Developers. Any missing information, the original source should be referenced for information.
The formatting of the code can be achieved by applying a the
codeformat Visual Studio 2010 settings file. This file defines where the curly braces are placed, number of spaces in tabs, spaces between empty methods calls, etc. -
Visual Studio 2008 Settings File
- Naming Guildelines
- Describes the guidelines for naming types in class libraries.
- Class Member Usage Guidelines
- Describes the guidelines for using properties, events, methods, constructors, fields, and parameters in class libraries.
- Type Usage Guidelines
- Describes the guidelines for using classes, value types, delegates, attributes, and nested types in class libraries.
- Guidelines for Exposing Functionality to COM
- Describes the guidelines for exposing class library types to COM.
- Error Raising and Handling Guidelines
- Describes the guidelines for raising and handling errors in class libraries.
- Array Usage Guidelines
- Describes the guidelines for using arrays in class libraries and how to decide whether to use an array vs. a collection.
- Operator Overloading Usage Guidelines
- Describes the guidelines for implementing operator overloading in base class libraries.
- Guidelines for Implementing Equals and the Equality Operator (==)
- Describes the guidelines for implementing the Equals method and the equality operator (==) in class libraries.
- Guidelines for Casting Types
- Describes the guidelines for casting types in class libraries.
- Common Design Patterns
- Describes how to implement design patterns for Finalize and Dispose methods, the Equals method, callback functions, and time-outs.
- Security in Class Libraries
- Describes the precautions to take when writing highly trusted class library code, and how to help protect resources with permissions.
- Threading Design Guidelines
- Describes the guidelines for implementing threading in class libraries.
- Guidelines for Asynchronous Programming
- Describes the guidelines for implementing asynchronous programming in class libraries and provides an asynchronous design pattern.