TrueZIP Kernel 7.0-rc1

de.schlichtherle.truezip.io
Class Paths.Splitter

java.lang.Object
  extended by de.schlichtherle.truezip.io.Paths.Splitter
Direct Known Subclasses:
FsArchiveFileSystem.Splitter
Enclosing class:
Paths

public static class Paths.Splitter
extends Object

A splitter for path names.


Field Summary
private  String memberName
           
private  String parentPath
           
private  char separatorChar
           
 
Constructor Summary
Paths.Splitter(char separatorChar)
           
 
Method Summary
 String getMemberName()
           
 String getParentPath()
           
 Paths.Splitter split(String path)
          Splits a path name into its parent path name and its base name, recognizing platform specific file system roots.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

separatorChar

private final char separatorChar

parentPath

@CheckForNull
private String parentPath

memberName

private String memberName
Constructor Detail

Paths.Splitter

public Paths.Splitter(char separatorChar)
Method Detail

split

public Paths.Splitter split(String path)
Splits a path name into its parent path name and its base name, recognizing platform specific file system roots. The returned array will hold the following strings:
  1. At index zero: The parent path name or null if the path name does not specify a parent. This compares equal with File.getParent().
  2. At index one: The base name. This compares equal with File.getName().

Parameters:
path - The name of the path which's parent path name and base name are to be returned.
Returns:
this

getParentPath

@CheckForNull
public String getParentPath()

getMemberName

public String getMemberName()

TrueZIP Kernel 7.0-rc1

Copyright © 2005-2011 Schlichtherle IT Services. All Rights Reserved.