Interface CloneSupported

  • All Superinterfaces:
    java.lang.Cloneable
    All Known Implementing Classes:
    Count

    public interface CloneSupported
    extends java.lang.Cloneable
    Indicates that a class implements cloning.

    This interface is needed because of the deficiencies of the standard Java Object.clone() framework. This interface makes clone() public and guarantees that CloneNotSupportedException will not be thrown, method signature notwithstanding.

    Author:
    Garret Wilson
    See Also:
    The clone Dilemma
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      java.lang.Object clone()
      This version is guaranteed not to throw CloneNotSupportedException.
    • Method Detail

      • clone

        java.lang.Object clone()
                        throws java.lang.CloneNotSupportedException
        This version is guaranteed not to throw CloneNotSupportedException.
        Throws:
        java.lang.CloneNotSupportedException