What is CEDET ? |
CEDET is a Collection of Emacs Development Environment Tools written with the end goal of creating an advanced development environment in Emacs. CEDET is hosted at Source Forge and is Free Software. You can view CEDET's CVS archive, project summary, and mailing lists at the CEDET Project page.
Emacs already is a great environment for writing software, but there are additional areas that need improvement. Many new ideas for integrated environments have been developed in newer products, such as Microsoft's Visual environment, JBuilder, or Eclipse. CEDET is a project which implements several advanced features developers have come to expect from an Editor.
CEDET: A User's View |
So what does an Emacs User get out of CEDET? CEDET includes the following major user features:
The CEDET Project management system provides a few simple keystrokes for organizing your files, building Makefiles or Automake files, and compiling your sources.
If you don't want CEDET to manage your Makefiles, CEDET will still be able to identify some types of projects based on pre-existing build configurations, such as the Emacs sources, the Linux kernel, or any project built using Automake.
The entire CEDET Makefile tree was built with CEDET's project management system, so when you download and build the distribution package, you will be using a CEDET project.
The image to the right shows a part of the Project management menu.
Write code with smart code completion,
sometimes known as "Intellisense". The CEDET infrastructure for
parsing and tagging files, and analyzing source code is one of the
most accurate completion tools for C++ anywhere. It will correctly
handle inheritance scoping rules, templates, smart-pointers, and
automatically filters based on what the value will be assigned into.
Code completion is not restricted to just C or C++. The completion engine is generic and works for any language that has a robust tagging parser written for CEDET, and a thin adaptation layer for the language. See the language support page to see if your language is supported.
The image to the right shows smart completion configured to use a
popup menu in a CEDET unit test source file going through a
templated smart pointer.
Smart help shows the prototype of the variable or method under point. As with the smart completion, it will correctly identify the method under point, deriving it's correct prototype by dereferencing the datatypes through templates and smart pointers.
The smart jump feature is similar to the classic Emacs TAGS
feature, except it always goes to the correct location. Using TAGS
on a method name makes you scan through all the possible methods
with the same name to find the one you want. Using the CEDET
smart jump feature takes you to the right definition the first time.
Analyze
where symbols are referenced in your
code base. The Symbol References tool in CEDET can use
external tools such as GNU Global, ID Utils, CScope, or even
find/grep to locate usages of your symbols. Every location is
analyzed and displayed hierarchically showing you the file and
function the reference occurs in, instead of a flat list of
locations.
The image to the right shows integration with GNU Global running in
the GNU Global source code.
Generate code with a
powerful language-independent template
system. The template system in CEDET is a framework
designed for code-generating application developers. Even so, the
base system and templates can also be used to insert small
repetitive code blocks. The template language is straight-forward,
and flexible. Because it uses the same code analytics as the Smart
completion, it often can correctly guess a wide range of values to
be used in your templates, saving you typing.
Some pre-existing tools that use CEDET's code generation system will write texinfo documentation for you, create doxygen style comments fully filled out from the local context, or insert get/set methods for variables in a class.
The image to the right shows a simple class declaration inserted
into an empty buffer.
Create UML diagrams either by hand, or automatically generate
simple 3-tier class diagrams from your sources. The diagrams are
linked to your source-code, so you can browse quickly through you
code from the convenience of UML.
The image to the right shows CEDET's UML tool's source code, called 'COGRE', diagramming and browsing itself. Optional unicode character support is enabled for the special characters.
With the CEDET
parsing backend, advanced code browsing tools
like ECB can be
used. ECB, or the Emacs Code Browser provides an
advanced set of UI windows docked to your Emacs frame. The extra
windows provide a wide range of features, including:
The ECB image on the right shows a sample of ECB (in full size). ECB is NOT a part of CEDET, and must be downloaded and installed seperately.
Setting up a
tool as large and complex as CEDET can seem daunting. Fortunately, a
minimal CEDET initialization can take up only a couple lines of code in
your .emacs file. If you are brave and enjoy customizing your CEDET
past this, then you are in luck as there are more options and small features to play
with than anyone sane person might want.
Alex Ott has written a great article called A Gentle Introduction to CEDET that shows both the simple CEDET configuration process, and a wide array of customizations that helps tune your Emacs for programming the smart way.
The image to the right shows the CEDET internal package and
revision testing output. Making sure all the package revisions
needed are accurate is important, and fully automatic.
In many ways, CEDET is a big pile of infrastructure with a
thin user interface sitting on it. Consider helping CEDET
by using the infrastructure to build better or more user interface
tools. You can also help by adding more
support for different languages. Join
the cedet-devel
mailing list to learn more.