In IBM Domino, how can you retrieve Java Class files from Agents and Script Libraries - lotus-domino

Java Agents and Script Libraries in IBM Domino have a unique container format. It's not clear how to extract specifically the class files from those containers, or where in Domino Designer to extract/export the class files.
How to do this?

A the way to do this is to open the Java agent or script library in Designer, then go to the Navigator view (Window -> Show Eclipse Views...). In there, there will be a stub project for the Java element, and you can right-click on the "bin" dir in there and do Export -> File System to extract the class files.

Related

How to create an empty JavaFX project in IntelliJ

Every time I create a new JavaFX project in IntelliJ it loads a simple HelloWorld project in it. How can I make it empty instead (without the need to delete those .java files every time)? Also how can I choose to create the project without a building system (as you can see in the picture, I'm always forced to create the project with Maven or Gradle)
When creating the new project, choose "Java" instead of "JavaFX".
A JavaFX application is just a Java application, so if you don't want the additional things which IntelliJ is doing when you choose to create a JavaFX project (e.g. supplying example code and associating with a build system like Maven or Gradle), you can just choose a basic Java application project from the wizard and it won't do those other things.
See the section in openjfx.io documentation titled "JavaFX and IntelliJ IDEA" for other steps you need to take:
Set the project JDK
File -> Project Structure -> Project
Create a JavaFX library in Idea
File -> Project Structure -> Libraries
Point to the lib folder of the JavaFX SDK.
Add VM options for the module path
Run -> Edit Configurations...
--module-path /path/to/javafx-sdk-15.0.1/lib --add-modules javafx.controls,javafx.fxml
For windows use quotes around the path and \ rather than /.
Run the project
Run -> Run...
You might also need to take the actions identified in the accepted answer to:
How to convert a normal java project in intellij into a JavaFx project
But that answer was written a while back and setting the resource copy configuration to include JavaFX fxml and css files might not be needed anymore.
Now, you might think that is annoying amount of things to do, and I might agree with you.

how to register for files of specific type in intellij plugin

I want to write an intellij plugin that needs to have a file viewer of certain type/s.
say I have a bunch of .abc files in my project at various locations. I need my plugin to show a tree view of all those .abc files keeping their hierarchy intact.
what is the api I should look at ?
Plugin repository can discover file types supported by a plugin and later IDE gets information about file types supported by different plugins. When you open a file of the file type supported by some plugin you get a notification in the IDE.
Registering a File Type

Add external java files(*.java file, not a jar file) to project in Intellij

I have many java files on one directory and I want to use it in my Intellij project. But I don't want to copy the java files to my project each time when I start a new project.
I know I can use reference in Visual Studio and Xcode.
I'm wondering whether I can do it in Intellij(14 CE)
Project Structure -> Modules -> Add Content Root -> (select directory containing external source files).
IntelliJ should detect the content as a Source Folder. If it doesn't detect it correctly, you can select it in the right-hand-side of Project Structure, and Mark as: (Sources).

Deploying a JavaFX Application with IntelliJ

Ive gone through tons of documentation and tutorials but nothing seems to work. Heres what i need
I want to package an deploy a desktop JavaFX application as a self contained package for Mac and Windows.
I want the application to have a custom icon (of course)
I want this application to be able to reference a text file that is in a resources folder (that can be modified by the user) to connect to a database.
Here is what i have tried:
Building artifacts in IntelliJ -This creates a jar with related 3rd party jars and a bundle folder with an exe and dmg. The icon is the default java one, and i cant reference by db.config file from the exe or dmg, i can reference it from the jar however
Generating an ANT build file - Once created this file contains errors complaining that various tags are not allowed and that properties are not defined.
Ive tried placing my .ico image which is the same name as my deployed application in every possible folder.
Im in serious need of help.
build.xml : http://tinypic.com/r/2md2zbn/8

Cannot reference jdbc.SQLServerDriver in Eclipse (ClassNotFoundException)

I am trying to use the MSSQL driver for JDBC. I have followed the instructions on how to add an external JAR file to the Eclipse Windows IDE as follow:
- Download the installation from here http://msdn.microsoft.com/en-us/sqlserver/aa937724.aspx (Microsoft JDBC Driver 4.0 for SQL Server)
- Extract the zip to a file location I have extracted it here (c:\MsJDBCforSqlDriver)
- In Eclipse Package Explorer right click your project -> Build Path -> Configure Build Path -> Java Build Path -> Libraries Tab- Add External JAR file and then I browse to
"C:\MsJDBCforSqlDriver\sqljdbc_4.0\enu\sqljdbc4.jar"
- I then view the successful reference as in image below including SQLServerDriver.class
When I try to execute Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver") I get a ClassNotFound Exception as below:
I tried all suggestions I could find on Google including setting the classpath in Windows Environment Variables.
Under the Run -> Run Configurations menu item you should find an entry for a Java application with the same name as the class that contains your main() method.
Have a look at the classpath tab. You should find your project listed under user entries. Expand it and see if the Microsoft JDBC Jar is listed.
The class path you use for compilation need not be the same as you choose for runtime, though Eclipse usually mirrors any changes to your build path to any launch configurations.
Your spelling and case for the package and class names look correct (Java is case-sensitive on names).
And yes, learning Java and Eclipse will take effort - Eclipse is quite different from other IDEs and it takes time to get to know it.
I found the answer here: http://code.google.com/p/android/issues/detail?id=27490
Seems like includes under Referenced Libraries is not available at runtime and I couldn't see how to change this in my version of Eclipse
"
Reported by fred...#mobileinteraction.se, Mar 22, 2012
Host OS: Windows 7 x64
SDK tools version: 17
Eclipse version: 3.7.2
ADT plug-in version:17.0.0v201203161636-291853
Platform targeted by your project: 2,2
Version of the platform running in the emulator: 2.2
STEPS TO REPRODUCE:
1. Create a project that uses external jars (in my case android-support-v4.jar ).
2. Added the android-support-v4.jar using Properties - Java Build Path - Add External Jar. Have the Activity extends from FragmentActivity.
3. Clean and run project
EXPECTED RESULTS: Application would run launching the FragmentActivity
OBSERVED RESULTS: Application crashes, android-support-v4.jar is placed within "References Libraries" and thus Android can't find it at runtime.
SOLUTION:
Manualy create a folder /libs within your project, copy the android-support-v4.jar to that folder and the ADT will place it under 'Android Dependencies' and it works.
This is the case for all external jars added using Properties - Java Build Path - Add External Jar.
"
Adding the JDBC driver of MS SQL Server to Eclipse:
Download the JDBC driver and uncompress it
Secondary click in the root of the Eclipse project and go to "Properties".
Now go to the section "Java Build Path - Libreries" y then click "Add External JARs".
Search the "sqljdbc.jar" file in the directory where you unpacked the downloaded driver, double click y finish pressing "ok".
I faced the problem and then solved the issue i.e. If You are using the Tomcat as a server for your Web application, the same Exception was coming as the Driver was unavailable to the project, later I put the jar file (sqljdbc4-2.0.jar) into the WEB-INF/lib folder then it was working