Basically you simply need to bundle the JRE files with your distributable, and then unzip them into a directory in your installation directory. Then have your startup script call use that JRE by calling the java command via a relative path. There are installers (such as
install4j ) that will automatically do this for you, including the generation of the platform specific startup script.
If you want to see how others do this, download and install an application that does this, look at how it is set up, and reverse engineer the concepts. You will want to look at how the directory structure is set up, and the startup script or executable they use.
SmartCVS (be sure to grab the installer with JRE when you download) and
IntelliJ IDEA are two such applications. that I know of off hand.