Minor Alias cleanup.

This commit is contained in:
Joakim Erdfelt 2022-09-06 20:03:48 -05:00
parent ff35c0e5ef
commit 6fa9f4a159
No known key found for this signature in database
GPG Key ID: 2D0E1FB8FE4B68B4
2 changed files with 2 additions and 20 deletions

View File

@ -287,26 +287,6 @@ public class PathResource extends Resource
return r.getClass() == PathResource.class && path.startsWith(r.getPath()); return r.getClass() == PathResource.class && path.startsWith(r.getPath());
} }
@Override
public boolean isAlias()
{
return this.alias != null;
}
/**
* The Alias as a Path.
* <p>
* Note: this cannot return the alias as a DIFFERENT path in 100% of situations,
* due to Java's internal Path/File normalization.
* </p>
*
* @return the alias as a path.
*/
public Path getAliasPath()
{
return this.alias;
}
@Override @Override
public URI getAlias() public URI getAlias()
{ {

View File

@ -344,6 +344,8 @@ public abstract class Resource implements Iterable<Resource>
} }
/** /**
* The canonical Alias for the Resource as a URI.
*
* @return The canonical Alias of this resource or null if none. * @return The canonical Alias of this resource or null if none.
*/ */
public URI getAlias() public URI getAlias()