Previous CloneSet | Next CloneSet | Back to Main Report |
Clone Mass | Clones in CloneSet | Parameter Count | Clone Similarity | Syntax Category [Sequence Length] |
---|---|---|---|---|
89 | 2 | 1 | 0.995 | class_body_declarations[11] |
Clone Abstraction | Parameter Bindings |
Clone Instance (Click to see clone) | Line Count | Source Line | Source File |
---|---|---|---|
1 | 87 | 33 | plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/callhierarchy/CallHierarchyImageDescriptor.java |
2 | 89 | 73 | plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/JavaElementImageDescriptor.java |
| ||||
private ImageDescriptor fBaseImage; private int fFlags; private Point fSize; /** * Creates a new CallHierarchyImageDescriptor. * * @param baseImage an image descriptor used as the base image * @param flags flags indicating which adornments are to be rendered. See <code>setAdornments</code> * for valid values. * @param size the size of the resulting image * @see #setAdornments(int) */ public CallHierarchyImageDescriptor(ImageDescriptor baseImage, int flags, Point size) { fBaseImage = baseImage; Assert.isNotNull(fBaseImage); fFlags = flags; Assert.isTrue(fFlags >= 0); fSize = size; Assert.isNotNull(fSize); } /** * Sets the descriptors adornments. Valid values are: <code>RECURSIVE</code>, <code>CALLER</code>, * <code>CALLEE</code>, <code>MAX_LEVEL</code>, or any combination of those. * * @param adornments the image descritpors adornments */ public void setAdornments(int adornments) { Assert.isTrue(adornments >= 0); fFlags = adornments; } /** * Returns the current adornments. * * @return the current adornments */ public int getAdronments() { return fFlags; } /** * Sets the size of the image created by calling <code>createImage()</code>. * * @param size the size of the image returned from calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ public void setImageSize(Point size) { Assert.isNotNull(size); Assert.isTrue(size.x >= 0 && size.y >= 0); fSize = size; } /** * Returns the size of the image created by calling <code>createImage()</code>. * * @return the size of the image created by calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ public Point getImageSize() { return new Point(fSize.x, fSize.y); } /* (non-Javadoc) * Method declared in CompositeImageDescriptor */ protected Point getSize() { return fSize; } /* (non-Javadoc) * Method declared on Object. */ public boolean equals(Object object) { if (object == null || !CallHierarchyImageDescriptor.class .equals(object.getClass())) return false; CallHierarchyImageDescriptor other = (CallHierarchyImageDescriptor) object; return (fBaseImage.equals(other.fBaseImage) && fFlags == other.fFlags && fSize.equals(other.fSize)); } /* (non-Javadoc) * Method declared on Object. */ public int hashCode() { return fBaseImage.hashCode()| fFlags| fSize.hashCode(); } |
| ||||
private ImageDescriptor fBaseImage; private int fFlags; private Point fSize; /** * Creates a new JavaElementImageDescriptor. * * @param baseImage an image descriptor used as the base image * @param flags flags indicating which adornments are to be rendered. See <code>setAdornments</code> * for valid values. * @param size the size of the resulting image * @see #setAdornments(int) */ public JavaElementImageDescriptor(ImageDescriptor baseImage, int flags, Point size) { fBaseImage = baseImage; Assert.isNotNull(fBaseImage); fFlags = flags; Assert.isTrue(fFlags >= 0); fSize = size; Assert.isNotNull(fSize); } /** * Sets the descriptors adornments. Valid values are: <code>ABSTRACT</code>, <code>FINAL</code>, * <code>SYNCHRONIZED</code>, </code>STATIC<code>, </code>RUNNABLE<code>, </code>WARNING<code>, * </code>ERROR<code>, </code>OVERRIDDES<code>, <code>IMPLEMENTS</code>, <code>CONSTRUCTOR</code>, * <code>DEPRECATED</code>, or any combination of those. * * @param adornments the image descriptors adornments */ public void setAdornments(int adornments) { Assert.isTrue(adornments >= 0); fFlags = adornments; } /** * Returns the current adornments. * * @return the current adornments */ public int getAdronments() { return fFlags; } /** * Sets the size of the image created by calling <code>createImage()</code>. * * @param size the size of the image returned from calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ public void setImageSize(Point size) { Assert.isNotNull(size); Assert.isTrue(size.x >= 0 && size.y >= 0); fSize = size; } /** * Returns the size of the image created by calling <code>createImage()</code>. * * @return the size of the image created by calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ public Point getImageSize() { return new Point(fSize.x, fSize.y); } /* (non-Javadoc) * Method declared in CompositeImageDescriptor */ protected Point getSize() { return fSize; } /* (non-Javadoc) * Method declared on Object. */ public boolean equals(Object object) { if (object == null || !JavaElementImageDescriptor.class .equals(object.getClass())) return false; JavaElementImageDescriptor other = (JavaElementImageDescriptor) object; return (fBaseImage.equals(other.fBaseImage) && fFlags == other.fFlags && fSize.equals(other.fSize)); } /* (non-Javadoc) * Method declared on Object. */ public int hashCode() { return fBaseImage.hashCode()| fFlags| fSize.hashCode(); } |
| |||
private ImageDescriptor fBaseImage; private int fFlags; private Point fSize; /** * Creates a new JavaElementImageDescriptor. * * @param baseImage an image descriptor used as the base image * @param flags flags indicating which adornments are to be rendered. See <code>setAdornments</code> * for valid values. * @param size the size of the resulting image * @see #setAdornments(int) */ /** * Creates a new CallHierarchyImageDescriptor. * * @param baseImage an image descriptor used as the base image * @param flags flags indicating which adornments are to be rendered. See <code>setAdornments</code> * for valid values. * @param size the size of the resulting image * @see #setAdornments(int) */ public [[#variablebd9ff3c0]](ImageDescriptor baseImage, int flags, Point size) { fBaseImage = baseImage; Assert.isNotNull(fBaseImage); fFlags = flags; Assert.isTrue(fFlags >= 0); fSize = size; Assert.isNotNull(fSize); } /** * Sets the descriptors adornments. Valid values are: <code>ABSTRACT</code>, <code>FINAL</code>, * <code>SYNCHRONIZED</code>, </code>STATIC<code>, </code>RUNNABLE<code>, </code>WARNING<code>, * </code>ERROR<code>, </code>OVERRIDDES<code>, <code>IMPLEMENTS</code>, <code>CONSTRUCTOR</code>, * <code>DEPRECATED</code>, or any combination of those. * * @param adornments the image descriptors adornments */ /** * Sets the descriptors adornments. Valid values are: <code>RECURSIVE</code>, <code>CALLER</code>, * <code>CALLEE</code>, <code>MAX_LEVEL</code>, or any combination of those. * * @param adornments the image descritpors adornments */ public void setAdornments(int adornments) { Assert.isTrue(adornments >= 0); fFlags = adornments; } /** * Returns the current adornments. * * @return the current adornments */ /** * Returns the current adornments. * * @return the current adornments */ public int getAdronments() { return fFlags; } /** * Sets the size of the image created by calling <code>createImage()</code>. * * @param size the size of the image returned from calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ /** * Sets the size of the image created by calling <code>createImage()</code>. * * @param size the size of the image returned from calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ public void setImageSize(Point size) { Assert.isNotNull(size); Assert.isTrue(size.x >= 0 && size.y >= 0); fSize = size; } /** * Returns the size of the image created by calling <code>createImage()</code>. * * @return the size of the image created by calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ /** * Returns the size of the image created by calling <code>createImage()</code>. * * @return the size of the image created by calling <code>createImage()</code> * @see ImageDescriptor#createImage() */ public Point getImageSize() { return new Point(fSize.x, fSize.y); } /* (non-Javadoc) * Method declared in CompositeImageDescriptor */ /* (non-Javadoc) * Method declared in CompositeImageDescriptor */ protected Point getSize() { return fSize; } /* (non-Javadoc) * Method declared on Object. */ /* (non-Javadoc) * Method declared on Object. */ public boolean equals(Object object) { if (object == null || ! [[#variablebd9ff3c0]].class .equals(object.getClass())) return false; [[#variablebd9ff3c0]] other = ( [[#variablebd9ff3c0]]) object; return (fBaseImage.equals(other.fBaseImage) && fFlags == other.fFlags && fSize.equals(other.fSize)); } /* (non-Javadoc) * Method declared on Object. */ /* (non-Javadoc) * Method declared on Object. */ public int hashCode() { return fBaseImage.hashCode()|fFlags|fSize.hashCode(); } |
CloneAbstraction |
Parameter Index | Clone Instance | Parameter Name | Value |
---|---|---|---|
1 | 1 | [[#bd9ff3c0]] | JavaElementImageDescriptor |
1 | 2 | [[#bd9ff3c0]] | CallHierarchyImageDescriptor |