Skip to topic | Skip to bottom


Home

AMR
AMR.CombinationResultsr1.15 - 24 Jul 2007 - 13:14 - MariusMarin

Start of topic | Skip to actions
-- MariusMarin - 17 May 2006

Results of aspect mining experiments on JHotDraw 5.4b1

Details about the experiment: A common framework for aspect mining based on crosscutting concern sorts. In Proceedings of the 13th Working Conference on Reverse Engineering (WCRE), 2006. (pdf)

Tool version: FINT 0.6

Fan-in analysis seeds

Seed - simple name Seed (CH.ifa.draw.*) Fan-in Sort Sort instance Context description Seed quality
toolDone() applet.DrawApplet.toolDone() 16 Consistent behavior Tool done notification Mouse events handlers for tools 12/16=75%
toolDone() application.DrawApplication.toolDone() 19 Consistent behavior Tool done notification Mouse events handlers for tools 12/19=63%
displayBox figures.BorderDecorator.displayBox() 55 Redirection layer Border decorator Border Decorator – whole proj. -
includes(Figure) figures.NullFigure.includes(Figure) 13 Role superimpositon Composite figure role Composite figure – whole proj. -
changed() figures.TextFigure.changed() 36 Consistent behavior Figure changed post-notification Figure change Observer 36/36=100%
toolDone() framework.DrawingEditor.toolDone() 21 Consistent behavior Tool done notification Mouse events handlers for tools 12/21=57%
add(Figure) framework.DrawingView.add(Figure) 10 Role superimpositon Composite figure role Composite figure – whole proj. -
checkDamage() framework.DrawingView.checkDamage() 28 Consistent behavior Notification for view refreshment if changes occurred "execute" methods in Command hierarchy + Mouse and keys events handlers in StandardDrawingView? 18/28=64%
clearSelection() framework.DrawingView.clearSelection() 31 Consistent behavior Reset current selection for undo/redo operations Undo/Redo activities 17/31=55%
selectionCount() framework.DrawingView.selectionCount() 16 Consistent behavior Check selection count for command executability isExecutableWithView methods in Command hierarchy 10/16=63%
addFigureChangeListener(FigureChangeListener) framework.Figure.addFigureChangeListener(FigureChangeListener) 11 Consistent behavior Figure changed observer registration Figure change Observer 11/11=100%
changed() framework.Figure.changed() 36 Consistent behavior Figure post-change notification Figure change Observer 36/36=100%
figures() framework.Figure.figures() 24 Role superimpositon Composite figure role Composite figure – whole proj. -
includes(Figure) framework.Figure.includes(Figure) 14 Role superimpositon Composite figure role Composite figure – whole proj. -
listener() framework.Figure.listener() 21 Role superimpositon Figure changed observer role Figure change Observer -
removeFigureChangeListener(FigureChangeListener) framework.Figure.removeFigureChangeListener(FigureChangeListener) 10 Consistent behavior Figure change listener un-registration Figure change Observer 10/10=100%
willChange() framework.Figure.willChange() 25 Consistent behavior Figure pre-change notification Figure change Observer 25/25=100%
owner() framework.Handle.owner() 37 Role superimpositon Handle adapter Handle adapter – whole proj. -
JHotDrawRuntimeException? framework.JHotDrawRuntimeException.JHotDrawRuntimeException 11 (Contract enforcement) Response mechanism to conditions that do not hold Response through rising runtime exception - whole proj. 6/11=55%
displayBox samples.javadraw.AnimationDecorator.displayBox 55 Redirection layer Animation decorator Animation Decorator – whole proj. -
add samples.javadraw.BouncingDrawing.add 11 Role superimpositon Composite figure role Composite figure – whole proj. -
toolDone() samples.javadraw.JavaDrawViewer.toolDone 14 Consistent behavior Tool done notification Mouse events handlers for tools 12/14=86%
AbstractCommand?() standard.AbstractCommand.AbstractCommand 19 Consistent behavior Command initialization Command constructors in Command hierarchy 12/19=63%
execute() standard.AbstractCommand.execute() 24 Contract enforcement Command pre-execution check execute methods in Command hierarchy 17/24=71%
isExecutable() standard.AbstractCommand.isExecutable 12 Consistent behavior Shared condition for command executability isExecutable methods in anonymous classes of the Command hierarchy 7/12=58%
addFigureChangeListener(FigureChangeListener) standard.AbstractFigure.addFigureChangeListener(FigureChangeListener) 11 Consistent behavior Figure change listener registration Figure change Observer 11/11=100%
changed() standard.AbstractFigure.changed() 37 Consistent behavior Figure changed post-notification Figure change Observer 37/37=100%
figures() standard.AbstractFigure.figures() 24 Role superimpositon Composite figure role Composite figure – whole proj. -
includes(Figure) standard.AbstractFigure.includes(Figure) 14 Role superimpositon Composite figure role Composite figure – whole proj. -
removeFigureChangeListener(FigureChangeListener) standard.AbstractFigure.removeFigureChangeListener(FigureChangeListener) 10 Consistent behavior Figure change listener de-registration Figure change Observer 10/10=100%
willChange() standard.AbstractFigure.willChange() 25 Consistent behavior Figure pre-change notification Figure change Observer 25/25=100%
AbstractTool?(DrawinEditor?) standard.AbstractTool.AbstractTool(DrawingEditor) 15 Consistent behavior Consistent tool initialization(Sharing of tool initialization steps) Tool hierarchy 15/15=100%
activate() standard.AbstractTool.activate() 10 Consistent behavior Consistent tool activation (Sharing of tool activation steps) “activate” methods in the Tool hierarchy 6/10=60%
      Consistent behavior Consistent tool activation (Sharing of tool activation steps) “setTool” methods in the DrawingEditor hierarchy 2/10=20%
deactivate() standard.AbstractTool.deactivate() 14 Consistent behavior Consistent tool de-activation (Sharing of tool de-activation steps) "deactivate(..)" methods in the Tool hierarchy 8/14=57%
      Consistent behavior Consistent tool de-activation (Sharing of tool de-activation steps) “setTool” methods in the DrawingEditor hierarchy 2/14=14%
mouseDown(MouseEvent, int, int) standard.AbstractTool.mouseDown(MouseEvent, int, int) 15 Consistent behavior Consistent handling of mouse down events for tools (Sharing behavior for handling of mouse down events for tools) "mouseDown(..)" methods in the Tool hierarchy 13/15=87%
figures() standard.CompositeFigure.figures 24 Role superimpositon Composite figure role Composite figure – whole proj. -
includes(Figure) standard.CompositeFigure.includes(Figure) 14 Role superimpositon Composite figure role Composite figure - whole proj. -
containsPoint(int, int) standard.DecoratorFigure.containsPoint(int, int) 15 Redirection layer Decorator figure Decorator figure - whole proj. -
displayBox() standard.DecoratorFigure.displayBox() 57 Redirection layer Decorator figure Decorator figure - whole proj. -
includes(Figure) standard.DecoratorFigure.includes(Figure) 13 Role superimposition + Redirection layer Composite + Decorator figure Composite + Decorator figure - whole proj. -
moveBy(int, int) standard.DecoratorFigure.moveBy(int, int) 19 Redirection layer Decorator figure Decorator figure - whole proj. -
checkDamage() standard.NullDrawingView.checkDamage() 23 Consistent behavior Notification for view refreshment if changes occurred "execute" methods in Command hierarchy 14/23=61%
clearSelection() standard.NullDrawingView.clearSelection() 30 Consistent behavior Reset current selection for undo/redo operations Undo/Redo activities 17/30=57%
selectionCount() standard.NullDrawingView.selectionCount() 13 Consistent behavior Check selection count for command executability isExecutableWithView methods in Command hierarchy 10/13=77%
add(Figure) standard.StandardDrawing.add(Figure) 12 Role superimpositon Composite figure role Composite figure – whole proj. -
add(Figure) standard.StandardDrawingView.add(Figure) 10 Role superimpositon Composite figure role Composite figure – whole proj. -
checkDamage() standard.StandardDrawingView.checkDamage() 28 Consistent behavior Notification for view refreshment if changes occurred "execute" methods in Command hierarchy + Mouse an keys events handlers in StandardDrawingView? (14+4)/28=64%
clearSelection() standard.StandardDrawingView.clearSelection() 31 Consistent behavior Reset current selection for undo/redo operations Undo/Redo activities 17/31=55%
selectionCount() standard.StandardDrawingView.selectionCount() 16 Consistent behavior Check selection count for command executability isExecutableWithView methods in Command hierarchy 10/16=63%
readInt util.StorableInput.readInt() 22 Role superimposition Figure persistence Persistent figures - Storable hierarchy -
readStorable util.StorableInput.readStorable() 20 Role superimposition Figure persistence Persistent figures - Storable hierarchy -
readString util.StorableInput.readString() 10 Role superimposition Figure persistence Persistent figures - Storable hierarchy -
writeInt(int) util.StorableOutput.writeInt(int) 21 Role superimposition Figure persistence Persistent figures - Storable hierarchy -
writeStorable(Storable) util.StorableOutput.writeStorable(Storable) 18 Role superimposition Figure persistence Persistent figures - Storable hierarchy -
writeString(String) util.StorableOutput.writeString(String) 10 Role superimposition Figure persistence Persistent figures - Storable hierarchy -
isRedoable() util.Undoable.isRedoable() 24 Contract enforcement Checking redoable state before execution "redo" methods in the Undoable hierarchy 20/24=83%
undo() util.UndoableAdapter.undo() 24 Contract enforcement Checking undoable state before execution "undo" methods in the Undoable hierarchy 22/24=92%
UndoableAdapter?(DrawingView) util.UndoableAdapter.UndoableAdapter(DrawingView) 25 Consistent behavior Sharing initialization for UndoActivity? objects UndoActivity? constructors - constructors in the Undoable hierarchy 22/25=88%

FI + GC (fan-in: 10) (Seeds for Consistent behavior and Contract enforcement instances)

Candidate Fan-in val. GC (highest) fan-in Note Quality of combination result as given by GC results
framework.DrawingView.checkDamage 28 12 SEED 100.00%
framework.DrawingView.clearSelection 31 11 SEED 100.00%
framework.DrawingView.selection 17      
framework.DrawingView.selectionCount 16 12 SEED 83.00%
framework.Figure.displayBox 90      
framework.Figure.displayBox(QPoint;QPoint) 14      
standard.AbstractCommand.execute 24 12 SEED 100.00%
standard.AbstractCommand.view 47      
standard.AbstractFigure.changed 37 25 SEED 100.00%
standard.AbstractFigure.willChange 25 25 SEED 100.00%
util.CommandMenu.add(QCommand) 14      
util.CommandMenu.CommandMenu(QString) 14      
util.StorableInput.readInt 22 10    
util.StorableInput.readStorable 20 10    
util.StorableInput.writeInt(I) 21 10    
util.StorableInput.writeStorable(QStorable) 18 10    
util.UndoableAdapter.undo 24 11 SEED 100.00%

All results of Fan-in analysis

Analysis setup

  • filter libs
  • filter accessors by name
  • filter accessors by implementation (including methods in interfaces whose all implementors are accessors)
  • filter test classes (callees and callers)
  • fan-in threshold: 10
  • filter utilities: Collection wrappers defined in JHotDraw
  • the value of the fan-in metric of a method m is given by the number of distinct method bodies invoking m

Method Fan-in
standard.AbstractHandle.displayBox() 12
util.CommandMenu.CommandMenu(QString;) 14
framework.Tool.editor() 30
framework.DrawingView.selectionCount() 16
samples.net.NodeFigure.displayBox() 59
framework.Figure.includes(QFigure;) 14
figures.TextFigure.changed() 36
framework.Handle.owner() 37
framework.Figure.removeFigureChangeListener(QFigureChangeListener?;) 10
framework.JHotDrawRuntimeException.JHotDrawRuntimeException(QString;) 11
figures.GroupFigure.displayBox() 54
standard.StandardDrawingView.selectionCount() 16
contrib.TextAreaFigure.moveBy(II) 18
contrib.DiamondFigure.containsPoint(II) 15
standard.StandardDrawingView.addToSelection(QFigure;) 11
standard.AbstractCommand.view() 47
framework.Figure.displayBox() 90
standard.AbstractFigure.moveBy(II) 19
framework.Figure.willChange() 25
standard.AbstractFigure.changed() 37
figures.TextFigure.displayBox() 60
util.StorableInput.readInt() 22
standard.AbstractTool.mouseDown(QMouseEvent?;II) 15
standard.CompositeFigure.figures() 24
figures.RectangleFigure.displayBox() 60
figures.NullFigure.includes(QFigure;) 13
standard.AbstractCommand.execute() 24
figures.LineConnection.updateConnection() 12
framework.Figure.size() 10
standard.NullDrawingView.checkDamage() 23
framework.Figure.displayBox(QPoint;QPoint;) 14
contrib.TextAreaFigure.displayBox() 60
standard.CreationTool.CreationTool(QDrawingEditor?;QFigure;) 12
standard.DecoratorFigure.displayBox() 57
util.StorableInput.readString() 10
util.StorableOutput.writeInt(I) 21
standard.AbstractTool.drawing() 19
standard.AbstractTool.activate() 10
standard.DecoratorFigure.moveBy(II) 19
standard.AbstractFigure.figures() 24
standard.DecoratorFigure.includes(QFigure;) 13
standard.AbstractFigure.displayBox() 90
standard.AbstractCommand.AbstractCommand(QString;QDrawingEditor;) 19
framework.DrawingView.selection() 17
figures.EllipseFigure.displayBox() 57
contrib.GraphicalCompositeFigure.displayBox() 56
framework.Handle.displayBox() 12
util.Command.name() 15
contrib.TriangleFigure.containsPoint(II) 15
util.StorableInput.readStorable() 20
framework.DrawingEditor.toolDone() 21
standard.NullDrawingView.selectionCount() 13
applet.DrawApplet.toolDone() 16
standard.StandardDrawingView.add(QFigure;) 10
figures.PolyLineFigure.containsPoint(II) 15
util.StorableOutput.writeString(QString;) 10
framework.Figure.containsPoint(II) 15
figures.ElbowConnection.updateConnection() 11
standard.StandardDrawingView.clearSelection() 31
standard.AbstractTool.AbstractTool(QDrawingEditor?;) 15
standard.StandardDrawing.add(QFigure;) 12
samples.javadraw.BouncingDrawing.add(QFigure;) 11
framework.DrawingView.add(QFigure;) 10
util.UndoableAdapter.UndoableAdapter(QDrawingView?;) 25
standard.AbstractFigure.containsPoint(II) 16
standard.StandardDrawingView.checkDamage() 28
application.DrawApplication.toolDone() 19
framework.DrawingView.clearSelection() 31
samples.pert.PertFigure.displayBox() 54
figures.PolyLineFigure.pointAt(I) 15
standard.NullDrawingView.selection() 14
util.UndoableCommand.name() 15
standard.NullDrawingView.clearSelection() 30
contrib.html.HTMLTextAreaFigure.containsPoint(II) 15
framework.Figure.addFigureChangeListener(QFigureChangeListener?;) 11
util.StorableOutput.writeStorable(QStorable;) 18
contrib.ComponentFigure.displayBox() 55
util.CommandMenu.add(QCommand;) 14
standard.StandardDrawing.displayBox() 58
framework.Figure.moveBy(II) 19
samples.javadraw.JavaDrawViewer.toolDone() 14
standard.CompositeFigure.includes(QFigure;) 14
standard.AbstractFigure.willChange() 25
figures.RoundRectangleFigure.displayBox() 59
standard.AbstractFigure.displayBox(QPoint;QPoint;) 14
standard.StandardDrawingView.selection() 16
figures.ImageFigure.displayBox() 54
figures.BorderDecorator.displayBox() 55
framework.DrawingView.checkDamage() 28
figures.PolyLineFigure.displayBox() 55
framework.DrawingView.addToSelection(QFigure;) 11
contrib.PolygonFigure.containsPoint(II) 15
framework.Figure.changed() 36
contrib.PolygonFigure.displayBox() 55
framework.ConnectionFigure.updateConnection() 11
samples.javadraw.AnimationDecorator.displayBox() 55
figures.TextFigure.moveBy(II) 18
standard.AbstractCommand.isExecutable() 12
standard.AbstractFigure.includes(QFigure;) 14
standard.AbstractFigure.size() 10
util.UndoableAdapter.undo() 24
samples.net.NodeFigure.containsPoint(II) 15
framework.Figure.figures() 24
standard.DecoratorFigure.containsPoint(II) 15
contrib.html.HTMLTextAreaFigure.moveBy(II) 18
standard.AbstractTool.deactivate() 14
util.Undoable.isRedoable() 24
standard.AbstractFigure.addFigureChangeListener(FigureChangeListener) 11
standard.AbstractFigure.removeFigureChangeListener(FigureChangeListener) 10

GC results (Seeds for Consistent behavior and Contract enforcement instances)

  • fan-in >= 10 (quality >= 50%)

GC candidate FI Seed Extended Quality extended Quality
{displayBox; displayBox; } 10     -  
{selection; view; } 10     -  
{readInt; readStorable; } 10 - {readInt; readStorable; } 100% 100%
{writeInt; writeStorable; } 10 - {writeInt; writeStorable; } 100% 100%
{checkDamage; execute; view; } 11 SEED {checkDamage; execute; view; setUndoActivity; getUndoActivity; setAffectedFigures} 100% 100%
{clearSelection; undo; } 11 SEED {clearSelection; undo; getDrawingView} 100% 100%
{checkDamage; execute; view; } 12 SEED {checkDamage; execute; view; setUndoActivity; getUndoActivity;} 100% 100%
{selectionCount; view; } 12 SEED {selectionCount; view; } 83% 83%
{CommandMenu; add; } 13     -  
{execute; view; } 14 SEED {execute; view; } 50% 50%
{changed; willChange; } 25 SEED {changed; willChange; } 100% 100%

  • fan-in >= 7 (quality => 50%)

GC candidate FI Seed Extended
{checkDamage; execute; view; } 7 SEED {checkDamage; execute; view; getUndoActivity; setUndoActivity; view; getAffectedFigures; setAffectedFigures; }
{clearSelection; undo; } 7 SEED {clearSelection; undo; getAffectedFigures; getDrawingView}
{TextTool; ConnectionTool?; CreationTool?; } 7 -  
{write; writeInt; } 7 SEED {write; writeInt; }
{canConnect; includes; } 7 SEED {canConnect; includes; }
{checkDamage; selection; execute; view; } 8 SEED {checkDamage; execute; view; getUndoActivity; setUndoActivity; view; setAffectedFigures; }
{clearSelection; undo; } 8 SEED {clearSelection; undo; getAffectedFigures; getDrawingView; }
{displayBox; displayBox; } 8 -  
{CommandMenu; add; UndoableCommand?; } 8 -  
{read; readInt; } 8 -  
{selection; execute; view; } 9 -  
{displayBox; displayBox; } 10 -  
{selection; view; } 10 -  
{readInt; readStorable; } 10 - {readInt; readStorable; }
{writeInt; writeStorable; } 10 - {writeInt; writeStorable; }
{checkDamage; execute; view; } 11 SEED {checkDamage; execute; view; getUndoActivity; setUndoActivity; setAffectedFigures}
{clearSelection; undo; } 11 SEED {clearSelection; undo; getDrawingView; }
{checkDamage; execute; view; } 12 SEED {checkDamage; execute; view; getUndoActivity; setUndoActivity}
{selectionCount; view; } 12 SEED {selectionCount; view; }
{CommandMenu; add; } 13 -  
{execute; view; } 14 SEED {execute; view; }
{changed; willChange; } 25 SEED {changed; willChange; }

RF results

  • no. redirectors >= 3; percentage >= 50% (Note: the tool also reports constructors, but we chose to filter them from the set of results)

Candidate Seed no. reported methods Quality
{standard.ResizeHandle -> standard.ResizeHandle$UndoActivity} - 3  
{contrib.html.AttributeFigureContentProducer -> contrib.html.FigureDataContentProducer} SEED 3 100%
{standard.ChangeConnectionStartHandle -> framework.ConnectionFigure} SEED 5 100%
{util.UndoRedoActivity -> util.Undoable} SEED 11 100%
{contrib.zoom.ZoomTool -> framework.Tool} SEED 3 100%
{standard.DecoratorFigure -> framework.Figure} SEED 22 100%
{samples.javadraw.AnimationDecorator -> standard.DecoratorFigure} SEED 5 80%
{standard.ChangeConnectionEndHandle -> framework.ConnectionFigure} SEED 5 100%
{figures.BorderDecorator -> standard.DecoratorFigure} SEED 4 75%
{standard.HandleTracker -> framework.Handle} SEED 3 100%
{samples.javadraw.BouncingDrawing -> standard.CompositeFigure} SEED 3 67%
{standard.AbstractTool$EventDispatcher -> framework.ToolListener} SEED 6 100%
{util.UndoableHandle -> framework.Handle} SEED 10 100%



Edit | Attach | Printable | Raw | More topic actions
Revisions: | r1.15 | > | r1.14 | > | r1.13 | Page history | Backlinks
AMR.CombinationResults moved from AMRIntra.SomeExperiments on 10 Jun 2006 - 10:09 by MariusMarin - put it back
You are here: AMR > CombinationResults

to top

Copyright © 2003-2017, Software Engineering Research Group, Delft University of Technology, The Netherlands