ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dominique Devienne" <ddevie...@gmail.com>
Subject Re: svn commit: r469781 - in /ant/core/trunk/src/main/org/apache/tools/ant: ProjectComponent.java types/AbstractFileSet.java types/DataType.java types/PatternSet.java
Date Wed, 01 Nov 2006 13:43:10 GMT
> -public abstract class DataType extends ProjectComponent {
> +public abstract class DataType extends ProjectComponent implements Cloneable {
> +    public Object clone() throws CloneNotSupportedException {
> +        DataType dt = (DataType) super.clone();
> +        dt.setDescription(getDescription());
> +        if (getRefid() != null) {
> +           dt.setRefid(getRefid());
> +       }
> +        dt.setChecked(isChecked());
> +        return dt;
> +    }
>  }
>
> --- ant/core/trunk/src/main/org/apache/tools/ant/types/PatternSet.java (original)
> +++ ant/core/trunk/src/main/org/apache/tools/ant/types/PatternSet.java Tue Oct > 
   public Object clone() {
> -        if (isReference()) {
> -            return getRef(getProject()).clone();
> -        } else {
> ...
> +        try {
> +            PatternSet ps = (PatternSet) super.clone();

You've removed the isReference check Antoine. Did you really intend to
clone the reference'r rather than the reference'd? I prefer to ask,
since I don't understand the reason for these changes (which is not to
say I context the changes). --DD

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message