A detailed introduction to the MyEclipse7.5 installation plug-in method

Source: Internet
Author: User
Tags object object

1. Download the installed plug-ins you need, the structure needs to be consistent with link installation:

+yourpluginname (Your plugin filename--parent)

----Plugins (folder required by default--child)

----Features (folder required by default--child)

2. Copy the plugin folder to the Custom plugins folder (which is your own easy to manage, self-built folder, this article is in D:/program Files/genuitec/common/myplugin)

3. Use MyEclipse to create a new Java file with the following code:

The code is as follows Copy Code

Package app;
Import Java.io.File;
Import java.util.ArrayList;
Import java.util.List;

/**
* MyEclipse 7.5 (2009-11-16) plug-in Configuration code generator
*/

public class Pluginconfigcreator
{

Public Pluginconfigcreator ()
{
}

public void print (String path)
{
list<string> list = getfilelist (path);
if (list = = null)
{
Return
}

int length = List.size ();
for (int i = 0; i < length; i++)
{
String result = "";
String thepath = Getformatpath (getString (List.get (i)));
File File = new file (thepath);
if (File.isdirectory ())
{
String fileName = File.getname ();
if (Filename.indexof ("_") < 0)
{
Print (Thepath);
Continue
}
string[] filenames = Filename.split ("_");
String filename1 = filenames[0];
String filename2 = filenames[1];
result = Filename1 + "," + filename2 + ", file:/" + path + "//"
+ FileName + "//,4,false";
SYSTEM.OUT.PRINTLN (result);
else if (File.isfile ())
{
String fileName = File.getname ();
if (Filename.indexof ("_") < 0)
{
Continue
}
int last = Filename.lastindexof ("_");//Final underline position
String filename1 = filename.substring (0, last);
String filename2 = filename.substring (last + 1, fileName
. Length ()-4);
result = Filename1 + "," + filename2 + ", file:/" + path + "//"
+ FileName + ", 4,false";
SYSTEM.OUT.PRINTLN (result);
}

}
}

Public list<string> getfilelist (String path)
{
Path = Getformatpath (path);
Path = path + "/";
File FilePath = new file (path);
if (!filepath.isdirectory ())
{
return null;
}
string[] filelist = Filepath.list ();
list<string> filelistfilter = new arraylist<string> ();

for (int i = 0; i < filelist.length; i++)
{
String tempfilename = getformatpath (path + filelist[i]);
Filelistfilter.add (TempFileName);
}
return filelistfilter;
}

Public String getString (Object object)
{
if (object = = null)
{
Return "";
}
return String.valueof (object);
}

public string Getformatpath (string path)
{
Path = Path.replaceall ("////", "/");
Path = Path.replaceall ("//", "/");
return path;
}

public static void Main (string[] args)
{
/* Your plugin's installation directory. Parameter string plugin the content is the absolute path of the plugin you want to install. Install the only need to replace their own plug-in path can be * * *
String plugin = "D://program files//genuitec//common//myplugin";
New Pluginconfigcreator (). print (plugin);
}
}

4. Run the above code to copy the contents of the console output to D:/program files/genuitec/myeclipse 7.5/configuration/ Org.eclipse.equinox.simpleconfigurator/bundles.info file.
5. Reboot MyEclipse Complete installation.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.