Design Snippets Eclipse Plugin, alpha version

9 November 2005: NEW RELEASE!! Still alpha, but better. Here's the zip file.

12 December 2005: BUG FIX!! Even better. Here's the zip file.


Installation FAQ

  1. Q: What languages are supported?
  2. Q: What operating systems are supported?
  3. Q: How do I get Eclipse?
  4. Q: What version of Eclipse do I need?
  5. Q: What is the worst thing that can happen to me while using the Design Snippets Eclipse Plugin?
  6. Q: I want to install the Plugin. What do I do?


Tool FAQ

  1. Q: I clicked on a snippet, but no information appears, or incorrect information appeared. What happened?
  2. Q: What do the edge labels found in Dependencies snippet views mean?
  3. Q: How can I learn more about how to use each Design Snippet?
  4. Q: How do I filter the Dependencies snippet view?
  5. Q: How do I set and change configuration options?


Q: What languages are supported?
A: Java 1.4.

Q: What operating systems are supported?
A: The plugin works best on Windows. On Unix, the "Dependencies snippet" does not work. In fact, trying to use the Dependencies Snippet on Unix usually makes Eclipse crash. According to our Mac user, design snippets work well, assuming you have already installed Eclipse and dot. Another person who tried it out on the Mac (me), who did not have dot installed, did
the following.

Q: How do I get Eclipse?
A: Click
here. I recommend that you setup an Eclipse Java Project that compiles correctly before you try installing the plugin. That way, you know that your Eclipse installation is working and that Eclipse is in a good starting state. (The plugin does a reasonably good job of handling code that doesn't compile, but if you are new to Eclipse, starting with code that does compile ensures that things in Eclipse are working the way they should be.) Need a sample Java project? Click here.

Q: What version of Eclipse do I need?
A: Eclipse 2.1 or Eclipse 3.0. Technically, the tool is a 2.1 plugin. However, it seems to work fine in Eclipse 3.0. We have little experience with Eclipse 3.01 or beyond.

Q: What is the worst thing that can happen to me while using the Design Snippets Eclipse Plugin?
A: I have received no reports of ill effects caused by the release version available on this website. But who knows? Use at your own risk! The worst thing I have ever seen happen with past versions is that the tool might make Eclipse crash, which means that you might lose work. So save often, and also keep an eye on Eclipse's Error Log. If the tool ever seems to slow down, save immediately. Remember, this plugin is alpha software.

Q: I want to install the Plugin. What do I do?
A: Here are the quick-n-easy installation instructions for Windows.

  1. Get Graphviz, the package that performs graph layout. The Windows install package is here. Click on the link, download the exe, and then launch the exe to install Graphviz. For more information, see the Graphviz home page.
  2. Make sure that the graph layout program "dot" is in your path.
  3. Create a directory called "edu.washington.cs.ds" in your eclipse plugins directory. For example, if your eclipse plugins directory is "c:\program files\eclipse\plugins," then create a directory called
    c:\program files\eclipse\plugins\edu.washington.cs.ds
  4. Unzip this zip file and put the unzipped files into the edu.washington.cs.ds directory. There should be 3 files -- ds.jar, plugin.xml, and snip.gif. Just put the three files into the edu.washington.cs.ds directory (don't create any subdirectories).
  5. Restart Eclipse and select Window -> Show View -> Other. There should be a "Design Snippets" directory with 4 options.
Q: I clicked on a snippet, but no information appears, or incorrect information appeared. What happened?
A: Here are some troubleshooting options:
Q: What do the edge labels found in Dependencies snippet views mean?
A: Check out this
cheat sheet. The most current version of the cheat sheet is in Appendix B of the dissertation.

Q: How do I filter the Dependencies snippet view?
A: In the main directory of the project, create a file called filter-list.txt. For example, say you have a project named "proj1" and that project is located at c:\Program Files\eclipse\workspace\proj1\
The location of filter-list.txt would be c:\Program Files\eclipse\workspace\proj1\filter-list.txt

In the file, put the fully qualified names of any classes you want to filter from the Dependencies view. If you want to filter an entire package, then end the name with ".*". For example, "java.lang.*" will filter the entire java.lang package. Put one package or class name per line. To collapse a package into a single node, add the term "AS-NODE" after the package name.

For example, my filter-list.txt currently contains:

java.lang.*
java.io.* AS-NODE
edu.washington.cs.ds.engine.FunctionInfoEngine
Q: How do I set and change configuration options?
A: In the main directory of the project, create a file called config.txt. For example, say you have a project named "proj1" and that project is located at c:\Program Files\eclipse\workspace\proj1\
The location of config.txt would be c:\Program Files\eclipse\workspace\proj1\config.txt

There are 6 configuration options of interest.

Config optionPossible valuesMeaning
indirectyes, noIf yes, then tool produces more complete views by chasing down types used indirectly (turning this feature on slows the tool down noticeably)
defacto list by memberyes, noIf yes, then De Facto snippet is organized by member instead of by client
package font size6, 8, 10, 12, 14, etc. use this if you are having trouble seeing the package names in Dependencies snippet views
node font size6, 8, 10, 12, 14, etc. use this if you are having trouble seeing node names in Dependencies snippet views
edge font size6, 8, 10, 12, 14, etc. use this if you are having trouble seeing edge labels in Dependencies snippet views
instance ofyes, noIf yes, then tool includes instance-of edges in Dependencies snippet views

Here is an example of my config.txt:

indirect : no
instance of : no
defacto list by member : yes
package font size : 8

Q: How can I learn more about how to use each Design Snippet?
A: Check out the
home page for design snippets. Of special interest may be the the slides from a talk I gave at OOPSLA.