You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by "Henri Yandell (JIRA)" <ji...@apache.org> on 2006/07/10 09:02:32 UTC
[jira] Resolved: (CLI-21) [cli] clone method in Option should use
super.clone()
[ http://issues.apache.org/jira/browse/CLI-21?page=all ]
Henri Yandell resolved CLI-21:
------------------------------
Fix Version: 1.1
Resolution: Fixed
> [cli] clone method in Option should use super.clone()
> -----------------------------------------------------
>
> Key: CLI-21
> URL: http://issues.apache.org/jira/browse/CLI-21
> Project: Commons CLI
> Type: Bug
> Versions: 1.0
> Environment: Operating System: other
> Platform: Other
> Reporter: Nathan McDonald
> Fix For: 1.1
>
> In
> org.apache.commons.cli.Option
> public method clone is implemented by creating a new instance through one of
> the class Constructors, and then assigning values as required through the
> setter methods.
> This means that any subclasses of the Option class will not return a true
> clone, but a new Option instance instead.
> A proper implementation of clone should use super.clone() to create a new
> instance, rather than calling the class constructor. This allows shallows
> clones to propogate correctly down to subclasses.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org