Author: aadamchik
Date: Tue May 20 07:20:49 2008
New Revision: 658258
URL: http://svn.apache.org/viewvc?rev=658258&view=rev
Log:
deprecating some unused ResourceLocator methods
Modified:
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/util/ResourceLocator.java
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/util/ResourceLocatorTest.java
Modified:
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/util/ResourceLocator.java
URL:
http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/util/ResourceLocator.java?rev=658258&r1=658257&r2=658258&view=diff
==============================================================================
---
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/util/ResourceLocator.java
(original)
+++
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/main/java/org/apache/cayenne/util/ResourceLocator.java
Tue May 20 07:20:49 2008
@@ -57,6 +57,8 @@
* Returns a resource as InputStream if it is found in CLASSPATH or
<code>null</code>
* otherwise. Lookup is normally performed in all JAR and ZIP files and
directories
* available to the ClassLoader.
+ *
+ * @deprecated since 3.0 unused.
*/
public static InputStream findResourceInClasspath(String name) {
try {
@@ -80,6 +82,8 @@
* <code>null</code> otherwise. Lookup is first performed relative to the
user's
* home directory (as defined by "user.home" system property), and then
relative to
* the current directory.
+ *
+ * @deprecated since 3.0 unused
*/
public static InputStream findResourceInFileSystem(String name) {
try {
@@ -213,6 +217,8 @@
/**
* Returns a base URL as a String from which this class was loaded. This
is normally a
* JAR or a file URL, but it is ClassLoader dependent.
+ *
+ * @deprecated since 3.0 unused.
*/
public static String classBaseUrl(Class<?> aClass) {
String pathToClass = aClass.getName().replace('.', '/') + ".class";
Modified:
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/util/ResourceLocatorTest.java
URL:
http://svn.apache.org/viewvc/cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/util/ResourceLocatorTest.java?rev=658258&r1=658257&r2=658258&view=diff
==============================================================================
---
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/util/ResourceLocatorTest.java
(original)
+++
cayenne/main/trunk/framework/cayenne-jdk1.5-unpublished/src/test/java/org/apache/cayenne/util/ResourceLocatorTest.java
Tue May 20 07:20:49 2008
@@ -47,6 +47,9 @@
throw new Exception("Error deleting temporary file: " +
fTmpFileInCurrentDir);
}
+ /**
+ * @deprecated since 3.0 unused
+ */
public void testFindResourceInCurrentDirectory() throws
java.lang.Exception {
InputStream in =
ResourceLocator.findResourceInFileSystem(fTmpFileName);
try {
@@ -57,6 +60,9 @@
}
}
+ /**
+ * @deprecated since 3.0
+ */
public void testClassBaseUrl() throws java.lang.Exception {
String me = ResourceLocator.classBaseUrl(this.getClass());
assertNotNull(me);
@@ -64,6 +70,9 @@
|| me.startsWith("file:"));
}
+ /**
+ * @deprecated since 3.0 unused
+ */
public void testFindResourceInClasspath() throws java.lang.Exception {
InputStream in =
ResourceLocator.findResourceInClasspath("testfile1.txt");
try {