@@ -1,5 +1,5 @@
/*
/*
* Copyright 2000-2004 The Apache Software Foundation
* Copyright 2000-2005 The Apache Software Foundation
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
@@ -17,12 +17,8 @@
package org.apache.tools.ant.util;
package org.apache.tools.ant.util;
import org.apache.tools.ant.BuildException;
import org.apache.tools.ant.util.optional.WeakishReference12;
import org.apache.tools.ant.util.optional.WeakishReference12;
import java.lang.reflect.Constructor;
/**
/**
* This is a weak reference on java1.2 and up, that is all
* This is a weak reference on java1.2 and up, that is all
* platforms Ant1.6 supports.
* platforms Ant1.6 supports.
@@ -32,7 +28,7 @@ public abstract class WeakishReference {
/**
/**
* create the appropriate type of reference for the java version
* create the appropriate type of reference for the java version
* @param object
* @param object the object that the reference will refer to.
* @return reference to the Object.
* @return reference to the Object.
*/
*/
public static WeakishReference createReference(Object object) {
public static WeakishReference createReference(Object object) {
@@ -44,7 +40,7 @@ public abstract class WeakishReference {
* been cleared, then this method returns <code>null</code>.
* been cleared, then this method returns <code>null</code>.
*
*
* @return The object to which this reference refers, or
* @return The object to which this reference refers, or
* <code>null</code> if this reference object has been cleared
* <code>null</code> if this reference object has been cleared.
*/
*/
public abstract Object get();
public abstract Object get();
@@ -56,8 +52,8 @@ public abstract class WeakishReference {
private Object object;
private Object object;
/**
/**
* construct
* @param object
* constructor.
* @param object the object that the reference will refer to.
*/
*/
public HardReference(Object object) {
public HardReference(Object object) {
this.object = object;
this.object = object;
@@ -65,6 +61,7 @@ public abstract class WeakishReference {
/**
/**
* Returns this reference object's referent.
* Returns this reference object's referent.
* @return the object to which this reference refers.
*/
*/
public Object get() {
public Object get() {
return object;
return object;