org.apache.maven.doxia.site.decoration.inheritance
Class PathUtils

java.lang.Object
  extended by org.apache.maven.doxia.site.decoration.inheritance.PathUtils

public abstract class PathUtils
extends java.lang.Object

Utilities that allow conversion of old and new pathes and URLs relative to each other.

Version:
$Id: PathUtils.java 746997 2009-02-23 12:51:29Z vsiveton $
Author:
Brett Porter, Henning P. Schmiedehausen

Method Summary
static PathDescriptor convertPath(PathDescriptor oldPath, PathDescriptor newPath)
          convertPath
static java.lang.String getRelativePath(PathDescriptor oldPathDescriptor, PathDescriptor newPathDescriptor)
          getRelativePath
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

convertPath

public static final PathDescriptor convertPath(PathDescriptor oldPath,
                                               PathDescriptor newPath)
                                        throws java.net.MalformedURLException

convertPath

Parameters:
oldPath - not null
newPath - not null
Returns:
a PathDescriptor converted by the new path
Throws:
java.net.MalformedURLException - if any

getRelativePath

public static final java.lang.String getRelativePath(PathDescriptor oldPathDescriptor,
                                                     PathDescriptor newPathDescriptor)

getRelativePath

Parameters:
oldPathDescriptor - not null
newPathDescriptor - not null
Returns:
a relative path depending if PathDescriptor is a file or a web url.
See Also:
PathTool.getRelativeFilePath(String, String), PathTool.getRelativeWebPath(String, String)


Copyright © 2005-2009 The Apache Software Foundation. All Rights Reserved.