The Birthday astronomical Calendar Java Packaging Finishing Edition

Source: Internet
Author: User

Because of life and work, "Birthday Astronomical Calendar" I have not moved, after a long time to discard, when re-pick up, more laborious. Programming is so, the spark of thought only in the original moment, once extinguished, re-ignite the broken thinking is very difficult. Because people's "forget" ability, really is very strong, sometimes review or maintain the previous code, often sigh: this is I write it? It's good enough to read! Hehe, this time the function of the annotation is highlighted, although it is sometimes difficult to find the previous ideas by annotation alone.

Off the topic, then, first of all, waiting for the "Birthday Astronomical Calendar" Encapsulation of the code, say sorry to you. This time the collation of the code, fixed some small bugs and thread safety issues, while the structure of the arrangement is easier to understand, and with the birthday of the Longevity astronomical calendar JS original structure of the code to maintain consistent, to facilitate reading and understanding, you would like to rename the variable and JS original consistent, but finally did not do so, The reason is that the JS source of the variable naming method. Comments on the original variable name corresponding to the description, you want to understand the source code or continue to improve, you can trouble yourself to see it.

This time the package version, essentially or relatively simple, no further depth and excavation, but also basic enough. Readers can be based on their own needs for further finishing, but before the reorganization and transformation, it is recommended to understand the relevant knowledge, otherwise you will not be able to start, even if changed, in the case of not understanding the logic, but also prone to error.

Description

1. Lunarcalendar objects are calendar-based, for example: August 2014 calendar data.

2. All methods of Lunarcalendar are for the lunar calendar, such as the GetMonth method, which represents the lunar calendar, rather than the Gregorian calendar.

3. Lunarcalendar instantiation, by default today, can be specified as one day, most methods are returned based on the day specified at the time the instantiation was instantiated.

4. The Lunardate class is the lunar data object for a given day, and has been split, rather than being mixed up in the past.

5. The Juliandate class, which is a Gregorian data object.

6. The Lunarconstant class, which is a basic constant data object, contains a large amount of basic data.

Because of a lot of code, so I have the form of documents to the CSDN Resource library, it will not post.

Java source code:

http://download.csdn.net/detail/wangpeng047/7755661

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.