Home / Projects / Quality assurance / Tools

ebrowse  - a class browser for emacs

Author: Peter Sherwood

This is a tool for displaying C++ classes. It is installed on lxplus machines. I have found it useful for:

The tool has lots of specialised emacs stuff which I ignore, but allows rapid detailed navigation in a package with mouse clicks.

As the navigation is done inside of emacs, it is great for immediately editing your files.

ebrowse documentation

On lxplus (and others), type "info ebrowse"

What it does for you:

Allows you to see all schematically methods, variables, class hierarchies.
Will also display the code.

Here is AtlfastEvent, copied from an emacs window:

*Globals*
  Atlfast
  Atlfast::CellDescriptor
  Atlfast::ClusterCollection
  Atlfast::DataObject
      Atlfast::EventHeader
  Atlfast::EPileupDeposit
  Atlfast::HepMC
  Atlfast::IAOO
      Atlfast::AOObase
    Atlfast::Cell
        Atlfast::TwoCptCell
    Atlfast::Cluster
        Atlfast::KtCluster
    Atlfast::Jet
    Atlfast::ReconstructedParticle
    Atlfast::SimpleKinematic
    Atlfast::Track
      Atlfast::IKinematic
    Atlfast::ICell
        Atlfast::Cell
     Atlfast::TwoCptCell
        Atlfast::ITwoCptCell
     Atlfast::TwoCptCell
    Atlfast::ICluster
        Atlfast::Cluster
     Atlfast::KtCluster
        Atlfast::IKtCluster
     Atlfast::KtCluster
    Atlfast::Jet
    Atlfast::ReconstructedParticle
    Atlfast::SimpleKinematic
    Atlfast::Track
  Atlfast::IAOOvisitor
  Atlfast::ICellCollection
  Atlfast::IKinematicCollection
  Atlfast::ITrackParameters
      Atlfast::TrackParameters
  Atlfast::ITwoCptCellCollection
  Atlfast::JetCollection
  Atlfast::ParticleCodes
  Atlfast::ProtoJet
      Atlfast::AtlfastProtoJet
  Atlfast::Quartet<>
  Atlfast::ReconstructedParticleCollection
  Atlfast::SimpleKinematicCollection
  Atlfast::TrackCollection
  Atlfast::TrackTrajectory
  Atlfast::std
  Atlfast::std::vector
  Phi

clicking on Atlfast::ITwoCptCell with right mouse button, and choosing "functions" gives
the methods of all the classes in the heirarchy, and information about those methods:
whether the method is pure, vitrual, constant, inline etc.

class Atlfast::TwoCptCell:

<---------> TwoCptCell       <---------> TwoCptCell    <--v-c----> accept
<--v------> addEgen       <--v-c----> clone     <--v-c----> cloneITCC
<--v------> depositEcal       <--v------> depositHcal    <--v-c----> eGen
<--v-c----> ecalEt       <--v-c----> hcalEt     <---------> operator =
<--v------> resetCell       <--v------> ~TwoCptCell
 

class Atlfast::Cell:

<---------> Cell       <---------> Cell     <--v-c----> accept
<--v------> addParticle       <--v-c----> clone     <--v-c----> eT
<--v-c----> eta        <--v-c----> mT     <--v-c----> momentum
<--v------> newHit       <--v------> newHit     <--v------> newHit
<--v-c----> numberOfHits      <---------> operator =    <--v-c----> pT
<--v-c----> particles       <--v-c----> phi     <--v------> resetCell
<--v------> setPt       <--v------> ~Cell
 

class Atlfast::ITwoCptCell:

<--v--0---> addEgen       <--v-c0---> cloneITCC    <--v--0---> depositEcal
<--v--0---> depositHcal       <--v-c0---> ecalEt     <--v-c0---> hcalEt
<--v------> ~ITwoCptCell
 

class Atlfast::ICell:

<--v--0---> addParticle       <--v--0---> newHit     <--v--0---> newHit
<--v-c0---> numberOfHits      <--v-c0---> particles    <--v--0---> resetCell
<--v--0---> setPt       <--v------> ~ICell
 

class Atlfast::IKinematic:

<--v-c0---> clone       <--v-c0---> eT     <--v-c0---> eta
<--v-c0---> mT        <--v-c0---> momentum    <--v-c0---> pT
<--v-c0---> phi        <--v------> ~IKinematic
 

class Atlfast::IAOO:

<--v-c0---> accept       <--v--0---> associate    <--v-c0---> begin
<--v-c0---> end        <--v--0---> reset     <--v-c0---> unAssociated
<--v------> ~IAOO
 

class Atlfast::AOObase:

<--v------> associate       <--v-c----> begin     <--v-c----> end
<--v------> reset       <--v-c----> unAssociated    <--v------> ~AOObase

there are many more displays to play with.
 
 

How to set it up:

[pcatlas191] pwd
/local_disk/sherwood/CMT/7.4.0/Simulation/Atlfast/AtlfastEvent/AtlfastEvent-00-05-16

[pcatlas191] ebrowse AtlfastEvent/*.h (this creates a file called BROWSE in the current directory)

then, from an emacs window Ctrl x Ctrl f , and fill in the path to the   BROWSE file.

↑ Top