in commons-transfer/commons-transfer-http/src/main/java/org/apache/archiva/commons/transfer/http/HttpTransferUploader.java [145:183]
public Stack<URI> davGetMissingPaths( URI targetURI )
throws TransferException
{
Stack<URI> missingPaths = new Stack<URI>();
URI currentURI = targetURI;
if ( !currentURI.getPath().endsWith( "/" ) )
{
try
{
currentURI = new URI( targetURI.toASCIIString() + "/" );
}
catch ( URISyntaxException e )
{
LOG.info( "Should never happen.", e );
}
}
boolean done = false;
while ( !done )
{
if ( targetURI.equals( baseuri ) )
{
done = true;
break;
}
if ( davCollectionExists( currentURI ) )
{
done = true;
break;
}
missingPaths.push( currentURI );
currentURI = currentURI.resolve( "../" ).normalize();
}
return missingPaths;
}