org.apache.slide.macro
Class CopyRouteRedirector.CopyRoute

java.lang.Object
  extended byorg.apache.slide.macro.CopyRouteRedirector.CopyRoute
Enclosing class:
CopyRouteRedirector

public static class CopyRouteRedirector.CopyRoute
extends java.lang.Object

A CopyRoute defines the source and the destination URI of a copy operation.

Version:
$Revision: 1.5 $

Field Summary
static java.lang.String DESTINATION_MUST_NOT_BE_NULL
          Message of the IllegalArgumentException that is thrown by constructor if parameter destinationUri is null.
protected  java.lang.String destinationUri
          The destination Uri.
static java.lang.String SOURCE_MUST_NOT_BE_NULL
          Message of the IllegalArgumentException that is thrown by constructor if parameter sourceUri is null.
protected  java.lang.String sourceUri
          The source Uri.
 
Constructor Summary
CopyRouteRedirector.CopyRoute(java.lang.String sourceUri, java.lang.String destinationUri)
          Creates a CopyRoute from the given URIs.
 
Method Summary
 boolean equals(java.lang.Object other)
          Returns true if the other Object is a CopyRoute and both routes source and destination URIs are equal.
 java.lang.String getDestinationUri()
          Returns the destination Uri.
 java.lang.String getSourceUri()
          Returns the source Uri.
 int hashCode()
          Returns the hash code of this instance.
 java.lang.String toString()
          Returns a String representation of the CopyRoute.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

SOURCE_MUST_NOT_BE_NULL

public static java.lang.String SOURCE_MUST_NOT_BE_NULL
Message of the IllegalArgumentException that is thrown by constructor if parameter sourceUri is null.


DESTINATION_MUST_NOT_BE_NULL

public static java.lang.String DESTINATION_MUST_NOT_BE_NULL
Message of the IllegalArgumentException that is thrown by constructor if parameter destinationUri is null.


sourceUri

protected java.lang.String sourceUri
The source Uri.


destinationUri

protected java.lang.String destinationUri
The destination Uri.

Constructor Detail

CopyRouteRedirector.CopyRoute

public CopyRouteRedirector.CopyRoute(java.lang.String sourceUri,
                                     java.lang.String destinationUri)
                              throws java.lang.IllegalArgumentException
Creates a CopyRoute from the given URIs.

Parameters:
sourceUri - the Uri of the source. Must not be null.
destinationUri - the Uri of the destination. Must not be null.
Throws:
java.lang.IllegalArgumentException - if one of the parameters is null.
Method Detail

getSourceUri

public java.lang.String getSourceUri()
Returns the source Uri.

Returns:
the source Uri.

getDestinationUri

public java.lang.String getDestinationUri()
Returns the destination Uri.

Returns:
the destination Uri.

toString

public java.lang.String toString()
Returns a String representation of the CopyRoute.

Returns:
a String representation of the CopyRoute.

equals

public boolean equals(java.lang.Object other)
Returns true if the other Object is a CopyRoute and both routes source and destination URIs are equal.

Parameters:
other - the Object to test for equality.
Returns:
true if the other Object is a CopyRoute and both routes source and destination URIs are equal.

hashCode

public int hashCode()
Returns the hash code of this instance. Due to specification equal objects must have the same hash code.

Returns:
the hash code of this instance.