Start learning Spring boot, start class annotations (i) (weekday)

Source: Internet
Author: User

The purpose of this blog is only to give lazy self-learning knowledge when summed up with

Those who like advanced knowledge, please go to other space, thank you!!!

Although I've been through two spring boot projects, I still don't know what I'm doing, how it's done, and it's completely unclear.

So on the Internet to read some people's information, decided to according to their own understanding, write down this blog, as a work diary!!!

Say the spring boot feeling, feel very convenient, deployment environment quickly, in the work I basically copy an existing module, cut off I do not use the file, change the pom file, belong to their own module came out.

Maven then loads the required jar packages, then starts the service, and if it starts, it does not delete the error (laughter), and then begins its own development.

Today to light up Baidu on the spring boot of the source code, first see how others understand.


That's a lot of crap, and it's starting to record.

First New Start Project we only have this one note, the ghost know what it is to use, do not know to surf the internet (below the three do not see, not the range I see today)

Online information said to Ctrl see his source, so I point in, found: Oh ~~~~! still don't understand!!!!!!!!!!!

If you don't understand, just look it up. There are 7 annotations, and I'll look it up in one.

[Email protected] (Elementtype.type)

First word meaning, target: destination; element type: Elements

Meaning in the code see this article: @Target

This annotation is mainly about declaring the scope of the annotation, and later relate enlement is a similar scope enumeration: Probably

Although I read the explanation of others, but still indefinitely. Put it aside first, let's see the next one.

[Email protected] (Retentionpolicy.runtime)

The word meaning retention:n. Retention, detention, retention, memory; retention policy: saving policies

Meaning in the code see this article annotation (@[email protected]) detailed

The meaning of this annotation is to declare the life cycle of the annotation, okay? The life cycle in development is often present but many situations tend not to be very accurate, but this is probably understood, continue the next

[Email protected]

The meaning of the word is adj. With supporting documents (incredibly adjectives)

The meaning of the code read this article documented

To tell the truth, I don't understand, it seems to mean that this is a high-level comment that generates a document explaining the class or method that owns the code.

[Email protected]

The meaning of a word: adj, inheritance, inheritance, etc.

Meaning Inheritance of code

To say is to allow subclasses to inherit the annotations, finally have a good understanding of (laughter)

Finally to the point (knocking on the blackboard!!!)

[Email protected]

The word meaning is the Spring boot configuration

The meaning of the code is to @configuration a package, there are many articles on the Internet, but I am sorry, I have not read, so first not too ugly

[Email protected]

The meaning of the word is an editable automatic configuration (approximate)

The meaning of the Code enableautoconfiguration

This annotation allows all eligible beans that have useful configuration annotations to be loaded in.

[Email protected]

The meaning of the word is the scanning of ingredients

It's about scanning files under specific paths for automatic loading.

  

If you don't understand, just look it up. There are 7 annotations, and I'll look it up in one.

[Email protected] (Elementtype.type)

First word meaning, target: destination; element type: Elements

Meaning in the code see this article: @Target

This annotation is mainly about declaring the scope of the annotation, and later relate enlement is a similar scope enumeration: Probably

Although I read the explanation of others, but still indefinitely. Put it aside first, let's see the next one.

[Email protected] (Retentionpolicy.runtime)

The word meaning retention:n. Retention, detention, retention, memory; retention policy: saving policies

Meaning in the code see this article annotation (@[email protected]) detailed

The meaning of this annotation is to declare the life cycle of the annotation, okay? The life cycle in development is often present but many situations tend not to be very accurate, but this is probably understood, continue the next

[Email protected]

The meaning of the word is adj. With supporting documents (incredibly adjectives)

The meaning of the code read this article documented

To tell the truth, I don't understand, it seems to mean that this is a high-level comment that generates a document explaining the class or method that owns the code.

[Email protected]

The meaning of a word: adj, inheritance, inheritance, etc.

Meaning Inheritance of code

To say is to allow subclasses to inherit the annotations, finally have a good understanding of (laughter)

Finally to the point (knocking on the blackboard!!!)

[Email protected]

The word meaning is the Spring boot configuration

The meaning of the code is to @configuration a package, there are many articles on the Internet, but I am sorry, I have not read, so first not too ugly

[Email protected]

The meaning of the word is an editable automatic configuration (approximate)

The meaning of the Code enableautoconfiguration

This annotation allows all eligible beans that have useful configuration annotations to be loaded in.

[Email protected]

The meaning of the word is the scanning of ingredients

It's about scanning files under specific paths for automatic loading.

  

Start learning Spring boot, start class annotations (i) (weekday)

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.