Categories:
Audio (13)
Biotech (29)
Bytecode (36)
Database (77)
Framework (7)
Game (7)
General (507)
Graphics (53)
I/O (35)
IDE (2)
JAR Tools (101)
JavaBeans (21)
JDBC (121)
JDK (426)
JSP (20)
Logging (108)
Mail (58)
Messaging (8)
Network (84)
PDF (97)
Report (7)
Scripting (84)
Security (32)
Server (121)
Servlet (26)
SOAP (24)
Testing (54)
Web (15)
XML (309)
Collections:
Other Resources:
JBrowser Source Code Files
JBrowser Source Code Files are provided in the
source package file.
You can download JBrowser source package as described in the previous tutorial and go to the "src" sub-folder to view Source Code files.
You can also browse JBrowser Source Code files below:
✍: FYIcenter
⏎ ru/atomation/jbrowser/impl/JBrowserBuilder.java
/** * No restrictions for this source. * * Author: CA>>> * Site: atomation.ru * Mail: Sashusik_EntXXI@Mail.ru */ package ru.atomation.jbrowser.impl; import java.io.File; import javax.swing.JFrame; import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.mozilla.browser.MozillaExecutor; import ru.atomation.jbrowser.interfaces.BrowserManager; import ru.atomation.jbrowser.interfaces.BrowserWindowCreator; import ru.atomation.xulnative.XulExtractor; /** * Entry point for coding of jbrowser aplication, prepare and create BrowserManager. * <hr> * Любая разработка приложения jbrowser должна начинатся с создания BrowserManager * класс предаставляет такие возможности * @author caiiiycuk */ public class JBrowserBuilder { private static Log logger = LogFactory.getLog(JBrowserBuilder.class); public static final String XULRUNNER_DEFAULT_DIR = "jbrowser"; public static final String PROFILE_DEFAULT_DIR = "jbrowser/profile"; private BrowserWindowCreator browserWindowCreator; private JComponentFactory<?> browserFactory; /** * directory with XULRunner binaries */ private File xulRunnerPath; private File profilePath; public JBrowserBuilder() { browserWindowCreator = new JBrowserWindowCreator(); browserFactory = new JComponentFactory<JFrame>(JBrowserFrame.class); } public BrowserWindowCreator getBrowserWindowCreator() { return browserWindowCreator; } public JBrowserBuilder setBrowserWindowCreator(BrowserWindowCreator browserWindowCreator) { this.browserWindowCreator = browserWindowCreator; return this; } /** * Set directory where xulrunner binaries are located. * * If set to null, jbrowser will use default xulrunner directory * * @param path directory with XULRunner binaries */ public JBrowserBuilder setXulRunnerPath(File path) { xulRunnerPath = path.getAbsoluteFile(); if (!isValidPath(xulRunnerPath.getPath())) { String oldPath = xulRunnerPath.getPath(); xulRunnerPath = new File(new File(System.getProperty("java.io.tmpdir")), XULRUNNER_DEFAULT_DIR).getAbsoluteFile(); logger.error("xullpath[" + oldPath + "] is invalid, using instead [" + xulRunnerPath.getPath() + "]"); } return this; } /** * Returns directory, where xulrunner binaries are located. * * @return directory with XULRunner binaries */ public File getXulRunnerPath() { if (xulRunnerPath == null) { setXulRunnerPath(new File(System.getProperty("user.dir"), XULRUNNER_DEFAULT_DIR).getAbsoluteFile()); } File xulRunner = new File(xulRunnerPath, "xulrunner/xulrunner"); if (!xulRunnerPath.exists()) { xulRunnerPath.mkdirs(); } if (!(new File(xulRunner, "javaxpcom.jar")).exists()) { logger.info("Unpacking mozilla to: " + xulRunnerPath.getPath()); new XulExtractor().extract(xulRunnerPath); } return xulRunner; } /** * Set directory where profile should be created. * * @param profilePath profile directory */ public void setProfilePath(File profilePath) { this.profilePath = profilePath.getAbsoluteFile(); } /** * Returns directory, where profile is created. * * @return profile directory */ public File getProfilePath() { if (profilePath == null) { setProfilePath(new File(System.getProperty("user.dir"), PROFILE_DEFAULT_DIR).getAbsoluteFile()); } if (!profilePath.exists()) { profilePath.mkdir(); } return profilePath; } public BrowserManager buildBrowserManager() { JBrowserManager jBrowserManager = new JBrowserManager(this); MozillaExecutor.setBrowserMangerInitilized(true); return jBrowserManager; } /** * On nix platform xulrunner not work when locatet in directory with * non english charchers * @param path * @return */ protected boolean isValidPath(String path) { return path != null && path.length() > 0 && path.matches("^[\\p{ASCII}]*$"); } public JBrowserBuilder setBrowserFactory(JComponentFactory<?> browserFactory) { this.browserFactory = browserFactory; return this; } public JComponentFactory<?> getBrowserFactory() { return browserFactory; } }
⏎ ru/atomation/jbrowser/impl/JBrowserBuilder.java
Or download all of them as a single archive file:
File name: jbrowser-1.9-fyi.zip File size: 625318 bytes Release date: 2022-11-10 Download
⇐ Download and Install JBrowser Source Package
2017-07-17, 9301👍, 1💬
Popular Posts:
What Is commons-net-ftp-2.0.jar? commons-net-ftp-2.0.jar is the JAR file for Apache Commons Net FTP ...
Java Cryptography Extension 1.2.2 JAR File Size and Download Location: File name: jce.jar, jce-1.2.2...
JDK 11 jdk.compiler.jmod is the JMOD file for JDK 11 Compiler tool, which can be invoked by the "jav...
What Is ojdbc8.jar for Oracle 12c R2? ojdbc8.jar for Oracle 12c R2 is the JAR files of ojdbc.jar, JD...
How to read XML document with DTD validation from socket connections with the socket\DelayedInput.ja.. .