Top Description Fields Constructors Methods
org.apache.derby.impl.io.vfmem

public Class PathUtil

extends Object
Class Inheritance
Imports
java.io.File

Helper methods to deal with paths in the in-memory "file system".

These methods are similar to those in java.io.File.

Note

The system has been hardcoded to use the separator specified by java.io.File.

Field Summary

Modifier and TypeField and Description
public static final char
public static final String

Constructor Summary

AccessConstructor and Description
private
PathUtil()

This class cannot be instantiated.

Method Summary

Modifier and TypeMethod and Description
private static void
public static String

Returns:

The base name of the path.
getBaseName
(String
the path to process
path
)

Returns the base name of the path.

public static String

Returns:

The parent path, which may be the empty string ("") if the path is a relative path, or null if XXXX TODO
getParent
(String
the path to process
path
)

Returns the parent of the path.

public static String

Returns:

A merged path.
join
(String
parent directory
parent
,
String
file/directory name
base
)

Joins the two paths by inserting the separator chararcter between them.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

SEPback to summary
public static final char SEP
SEP_STRback to summary
public static final String SEP_STR

Constructor Detail

PathUtilback to summary
private PathUtil()

This class cannot be instantiated.

Method Detail

basicPathChecksback to summary
private static void basicPathChecks(String path)
getBaseNameback to summary
public static String getBaseName(String path)

Returns the base name of the path.

Parameters
path:String

the path to process

Returns:String

The base name of the path.

getParentback to summary
public static String getParent(String path)

Returns the parent of the path.

Parameters
path:String

the path to process

Returns:String

The parent path, which may be the empty string ("") if the path is a relative path, or null if XXXX TODO

joinback to summary
public static String join(String parent, String base)

Joins the two paths by inserting the separator chararcter between them.

Parameters
parent:String

parent directory

base:String

file/directory name

Returns:String

A merged path.