当前位置:网站首页>C# Coding Conventions Handbook
C# Coding Conventions Handbook
2022-08-02 06:57:00 【Calm Nine】
C# Coding Standards Manual
Introduction
Purpose
Make it clear that the source program and test program written in C# conform to the same specification, so as to achieve consistency and unity, so as to facilitate the later maintenance and change of the program.
In the life cycle of a software, 80% of the cost is maintenance.Almost no software is maintained by the original developer throughout its entire life cycle;
coding standards can improve the readability of software and allow programmers to understand new code as quickly and thoroughly as possible.In order to enforce the specification, every software developer must consistently follow the coding specification;
The main reason for using the unified coding specification is to standardize the structure and coding style of the application so that it is easier to read and understand this code;
GoodThe coding conventions used in this document make the source code rigorous, readable, and meaningful, consistent with other language conventions, and as intuitive as possible.
Note: The coding standard is to increase the readability of the code, there is no so-called right or wrong, and you don't have to worry about whether it is right or wrong.Term Definition
- Pascal nomenclature: Capitalize the first letter of an identifier and the first letter of each word that follows.Pascal case can be used for identifiers of three or more characters.For example: BackColor.
- Camel nomenclature: Identifiers are lowercase and each subsequent word is capitalized.For example: backColor.
- Capitalization: All letters in the identifier are capitalized.Use this convention only for identifiers consisting of two or fewer letters.For example: System.IO, System.Web.UI.
- The specification of the document is divided into three types: [mandatory] [recommended] [reference], indicating the level of specification that needs to be followed
- Hungarian nomenclature: Hungarian nomenclature is a type of
边栏推荐
猜你喜欢

家用 NAS 服务器(4)| MergerFS和SnapRaid数据定时备份

Launch Space on-premises deployment (local) Beta!

Machine learning -- - theory of support vector machine (SVM)

双重for循环案例(用js打印九九乘法表)

How to install the specified version package with NPM and view the version number

A list of 300+ learning resources compiled by senior engineers of the Tao Department (the latest version in 2021)

zabbix邮件报警和微信报警

Node的安装与环境变量的配置

APP special test: traffic test

Nacos注册中心的部署与用法详细介绍
随机推荐
APP专项测试:流量测试
Tips for programmers to write PPT
zabbix auto-discovery and auto-registration
Toolbox App 1.25 新功能一览 | 版本更新
秒杀系统小demo
一文搞懂C操作符
Nacos installation configuration and single-machine deployment tutorial
zabbix自动发现和自动注册
Ant three sides: MQ message loss, duplication, backlog problem, what are the solutions?
MySQL Advanced SQL Statements (2)
APP special test: traffic test
深度学习——CNN实现MNIST手写数字的识别
pytorch常用函数
Home NAS server (4) | MergerFS and SnapRaid data backup
Technology empowers Lhasa's "lungs", Huawei helps Lalu Wetland Smart Management to protect lucid waters and lush mountains
Analysis of the source code of the JS UI framework of Hongmeng system
有人开源全凭“为爱发电”,有人却用开源“搞到了钱”
mysql高阶语句(一)
[OpenCV from entry to practice] image processing technology [pixel] (the most detailed in the whole network)
Nacos installation detailed process