org.springframework.roo.project
Class Path

java.lang.Object
  extended by org.springframework.roo.project.Path
All Implemented Interfaces:
Comparable<Path>

public class Path
extends Object
implements Comparable<Path>

Immutable representation of common file path conventions used in Maven projects.

PathResolver instances provide the ability to resolve these paths to and from physical locations.

A name cannot include the question mark character.

Presented as a class instead of an enumeration to enable extension.

Since:
1.0
Author:
Ben Alex

Field Summary
static Path ROOT
           
static Path SPRING_CONFIG_ROOT
           
static Path SRC_MAIN_JAVA
           
static Path SRC_MAIN_RESOURCES
           
static Path SRC_MAIN_WEBAPP
           
static Path SRC_TEST_JAVA
           
static Path SRC_TEST_RESOURCES
           
 
Constructor Summary
Path(String name)
          Creates a name with the specified string.
 
Method Summary
 int compareTo(Path o)
           
 boolean equals(Object obj)
           
 String getName()
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

SRC_MAIN_JAVA

public static final Path SRC_MAIN_JAVA

SRC_MAIN_RESOURCES

public static final Path SRC_MAIN_RESOURCES

SRC_TEST_JAVA

public static final Path SRC_TEST_JAVA

SRC_TEST_RESOURCES

public static final Path SRC_TEST_RESOURCES

SRC_MAIN_WEBAPP

public static final Path SRC_MAIN_WEBAPP

ROOT

public static final Path ROOT

SPRING_CONFIG_ROOT

public static final Path SPRING_CONFIG_ROOT
Constructor Detail

Path

public Path(String name)
Creates a name with the specified string.

A name cannot contain a question mark character, due to it being a reserved character for metadata identification string tokenization.

Parameters:
name - the name (required and cannot contain a "?" character)
Method Detail

getName

public String getName()

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

compareTo

public int compareTo(Path o)
Specified by:
compareTo in interface Comparable<Path>

toString

public final String toString()
Overrides:
toString in class Object


Copyright © 2009-2010 VMware, Inc. All Rights Reserved.