Dark Horse programmer-C # basic review

Source: Internet
Author: User

-------------------- Windows Phone 7 Mobile Phone development,. Net training, and hope to communicate with you! ----------------------

 

These days, I came into contact with the training class "Dark Horse programmers". I think this is an opportunity.

Download the video according to the application passed in the process, review the basics of C #, and summarize the important and easily forgotten knowledge points.

1. Class modifiers include: new, public, protected, Private, internal, abstract, sealed.

New: this parameter can only be used when an embedded class is declared. This indicates that the class hides the member inherited from the base class and has the same name as the base class.

Public, protected, private: same as in C ++.

Internal: only the project in which it is located can access it.

Abstract: abstract class. Instances of classes cannot be created.

Sealed: sealed class. Instances of the class cannot be created.

2. Differences between attributes and fields

Attribute is used for external calls. You can set or read a value through "object. Attribute,

Get {return xxx;} indicates readable

Set {xxx = value;} indicates writable

Fields are in the class and used to store data.

3. Parameter Array

The parameter array must be explicitly specified with the Params modifier. Only one parameter array is allowed in the parameter list of the method. When both fixed parameters and parameter arrays exist in the method, the parameter array must be placed at the end of the entire parameter list, the parameter array can only be a one-dimensional array.

-------------------- Windows Phone 7 Mobile Phone development,. Net training, and hope to communicate with you! ---------------------- For details, please refer to: http://net.itheima.com/

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.