Two weeks of personal projects (software engineering)

Source: Internet
Author: User

In the graphical user interface, set up two panels and set the layout to display their components individually. Set two menu items, respectively "open" and "save", set two buttons, respectively "Encrypt" and "decrypt", create a text area, with a label labeled "File Browser window", this is the entire graphical user interface.

Added a window event windowclosing to close the running program.

Where the code for the Window event is implemented:

Addwindowlistener (New Windowadapter ()

{

public void windowclosing (WindowEvent e)

{

System.exit (0);

}

});

}

Commissioning and

Experience ha

This program uses a simple encryption algorithm, that is, the text file obtained from the text area, initialized, stored in an array, and then perform an XOR operation, the results are stored in the array, thus appearing in the "File browser window." Decryption operation is in fact the same as the encryption operation, still open the encrypted file first, so that it appears in the text area, and then the same elements in the array initialization, the XOR operation, you can get the decrypted file, and then displayed in the "File browser window." When I study those classes, I think it is still a bit difficult, and then call several classes of methods, see the results of the operation, so very intuitive to the class to learn, and memory is very deep.

Learning language, repeated operations, often write code, we have a problem when we have certain ideas. Waste, learning programming language needs a relatively long stage, solid foundation. Do not think that you have written a simple small program, you think you have learned very well, this is just a little practice in your learning programming process. Do not be satisfied with the status quo, to constantly improve their knowledge system, good at summing up practical experience. To correct their learning attitude, is the initiative to learn, rather than passive! Improve self-study ability. Then you should not be satisfied to put the code to pass, you should think about if I do not write this, another way, try again trial not.

Two weeks of personal projects (software engineering)

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.