We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
因为该作品已经申请个人软著,osgi实现不方便在作品中发布。 于是贴在这里。作者已经调通论证如下。
String jarCategoryLink= ""; FileDialog filedialog= new FileDialog(new Frame(), StableData.ATTENSION_LOAD_HISTORY , FileDialog.LOAD); filedialog.setFilenameFilter(new TXTFilter(StableData.FILE_FORMAT_ETL)); filedialog.setVisible(true); jarCategoryLink= filedialog.getDirectory(); System.out.println(jarCategoryLink); if(null== jarCategoryLink|| jarCategoryLink.isEmpty()|| jarCategoryLink.contains (StableData.FILE_FORMAT_JAR)) { System.out.println(StableData.ATTENSION_RECHOICE); return first; } File file= new File(jarCategoryLink); if(file.isFile()) { System.out.println(StableData.ATTENSION_FILE_CHOICE); return first; } File[] files= file.listFiles(); for(int i= 0; i< files.length; i++) { @SuppressWarnings("deprecation") URLClassLoader loader= new URLClassLoader(new URL[]{ files[i].toURL() }); String filename= files[i].getName().replace(".jar", ""); String[] columns= filename.split("\."); //如下2行代码 refer https://www.cnblogs.com/chinaxin/p/3678442.html //这小伙子以后有前途。哈哈 //Class myclass = loader.loadClass("hand.java.loadjar.TestClass"); //Gene new object //Object myobject = myclass.newInstance(); Class myclass= loader.loadClass(filename+ "."+ columns[columns.length- 1]+ "NodeInterface"); Object myobject= myclass.newInstance(); //我准备之后设计成病毒式热插拔,因为绕过虚拟机的思想涉及情报学特工和计算机病毒领域,害怕国家相关安全体系管控,暂时不研发。 ObjectInterface objectInterface= (ObjectInterface) myobject; first = link.addNode(first, objectInterface); }
The text was updated successfully, but these errors were encountered:
将OSGI扫描集成在华瑞集,
cf27329
扫描插件文档代码 完整来源Refer: :yaoguangluo/ETL_Unicorn#7 20200425 罗瑶光
No branches or pull requests
因为该作品已经申请个人软著,osgi实现不方便在作品中发布。
于是贴在这里。作者已经调通论证如下。
String jarCategoryLink= "";
FileDialog filedialog= new FileDialog(new Frame(), StableData.ATTENSION_LOAD_HISTORY
, FileDialog.LOAD);
filedialog.setFilenameFilter(new TXTFilter(StableData.FILE_FORMAT_ETL));
filedialog.setVisible(true);
jarCategoryLink= filedialog.getDirectory();
System.out.println(jarCategoryLink);
if(null== jarCategoryLink|| jarCategoryLink.isEmpty()|| jarCategoryLink.contains
(StableData.FILE_FORMAT_JAR)) {
System.out.println(StableData.ATTENSION_RECHOICE);
return first;
}
File file= new File(jarCategoryLink);
if(file.isFile()) {
System.out.println(StableData.ATTENSION_FILE_CHOICE);
return first;
}
File[] files= file.listFiles();
for(int i= 0; i< files.length; i++) {
@SuppressWarnings("deprecation")
URLClassLoader loader= new URLClassLoader(new URL[]{ files[i].toURL() });
String filename= files[i].getName().replace(".jar", "");
String[] columns= filename.split("\.");
//如下2行代码 refer https://www.cnblogs.com/chinaxin/p/3678442.html
//这小伙子以后有前途。哈哈
//Class myclass = loader.loadClass("hand.java.loadjar.TestClass"); //Gene new object //Object myobject = myclass.newInstance(); Class myclass= loader.loadClass(filename+ "."+ columns[columns.length- 1]+ "NodeInterface");
Object myobject= myclass.newInstance();
//我准备之后设计成病毒式热插拔,因为绕过虚拟机的思想涉及情报学特工和计算机病毒领域,害怕国家相关安全体系管控,暂时不研发。
ObjectInterface objectInterface= (ObjectInterface) myobject;
first = link.addNode(first, objectInterface);
}
The text was updated successfully, but these errors were encountered: