Learn a little Java every day

Source: Internet
Author: User

Reflection mechanism of 1.JAVA

At run time, judge the class to which any object belongs, construct an object of any class at run time, judge the member variables and methods of any class at run time, invoke the method of any object at run time, and generate dynamic proxy.

2. About ArrayList

There are a total of three ArrayList constructors:

(1) ArrayList () constructs an empty list with an initial capacity of 10. (2) ArrayList (collection<? extends e> c) constructs a list of elements that contain the specified Collection, arranged in the order in which they are returned by the Collection iterator. (3) ArrayList (int initialcapacity) constructs an empty list with the specified initial capacity. 3, abstract when an entity class integrates an abstract class, an abstract method in the abstract class must be implemented. 4.list&set the difference between list and set, the set cannot be duplicated.
The duplicate definition in set, without defining its own Equels method, calls the default, that is, the direct ==.5.ceil () expands and floor () shrinks.

Learn a little Java every day

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.