I haven't touched Java before, but suddenly I touched JSF, so I tried to get started. I'm going to output a memo of what I did because it's a big deal
First of all, make a note about building the development environment
Step1 Install the JDK Step2 Edit PATH Step3 Install NetBeans Step4 Try to make a project
Download the JDK from the following site Java SE Development Kit 8 Downloads
At this time, download ** Java SE 8 ** instead of Java SE 10. If I install the latest 10 ones, I get an error when installing NetBeans Thanks to this guy, 30 minutes wasted ...
Once the download is complete, follow the installer and you're good to go
Open "Control Panel"-> "System and Security"-> "System"-> "Advanced system settings" Click the "Environment variable (N) ..." button to open the environment variable setting screen.
There is a variable called "Path" in "System environment variables", so press the new button from the edit window and add the path of the bin directory of the location where you installed the JDK.
Example: C: \ Program Files \ Java \ jdk1.8.0_181 \ bin
Launch a command prompt and check if the PATH is correct
javac
If you enter and the following is displayed, it is ok
>javac
how to use: javac <options> <source files>
The available options are:
-g Generate all debug information
-g:none Do not generate debug information
-g:{lines,vars,source}Generate only some debug information
-nowarn do not raise a warning
~Omission~
-J<flag> <flag>Pass directly to the execution system
-Quit compilation when Werror warning occurs
@<filename>Read from file options and filename
Next, add a new variable called JAVA_HOME
to the system environment variables.
The value will be the path where you installed the JDK
Example: C: \ Program Files \ Java \ jdk1.8.0_181
Also, launch the command prompt again and check if it is set correctly.
set java_home
If you enter and the following is displayed, it is ok
>set JAVA_HOME
JAVA_HOME=C:\Program Files\Java\jdk1.8.0_181
Download the installer from the following site NetBeans IDE Download
There are several types of download bundles, but this time I downloaded "Java EE" Launch the installer when the download is complete
If Java SE 8 is installed and the PATH is set correctly, you can install it according to the installer without any problem.
Select "Java Web" for the category and "Web Application" for the project.
Named "jsf-sample"
Server and settings are default
Select "Java Server Faces" as the framework At this time, note that JSF will not be selected if you exit without checking as shown below.
Right-click on the project name and click "Run"
The browser will start and the contents of index.html
will be displayed.
And, when the screen is displayed safely, the development environment construction memo ends here
Recommended Posts