Java io stream + swing programming to make graphical file copy application

After learning java io some time ago, I came up with the idea of ​​making something. I knew java swing programming before, so I wanted to make a visual java

desktop application


The effect diagram is as follows

The .exe file packaged by the jar package

I will attach a link to the packaging tutorial later



The page is as follows


Project Architecture



The code is not difficult, use the byte stream to operate, write the tool class and directly develop it, mainly in the details such as the closing of the stream,

The source file to be copied does not exist or the format is not correct to throw an exception warning box, the file to be copied to does not exist to be created and

How to create (of course, the pain of layout brought to me when writing java swing programming is omitted here, no problem anyway, I will not engage in this aspect in the future

But it is really troublesome to write pages in java, laugh and cry)


Finally, export the project jar package and use the software exe4j to export it into an .exe file, which can be used directly by clicking

Attached below is a tutorial link to import a java program into an .exe file

https://blog.csdn.net/m0_38100471/article/details/72811145


If the code structure is messy, I will not post it. This blog post can be regarded as a summary of myself.


Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324501733&siteId=291194637