task4/solution06/src/org/apidesign/apifest08/currency/UnsupportedConversionException.java
author Jaroslav Tulach <jaroslav.tulach@apidesign.org>
Sat, 11 Oct 2008 23:38:46 +0200
changeset 61 58ec6da75f6f
parent 45 task3/solution06/src/org/apidesign/apifest08/currency/UnsupportedConversionException.java@251d0ed461fb
child 64 51f7b894eba6
permissions -rw-r--r--
Copying structure for task4
     1 package org.apidesign.apifest08.currency;
     2 
     3 import java.util.Currency;
     4 
     5 public final class UnsupportedConversionException extends ConversionException{
     6 
     7 	private static final long serialVersionUID = 1L; 
     8 	
     9 	private Currency from;
    10 	private Currency to;
    11 
    12 	public UnsupportedConversionException(Currency from, Currency to) {
    13 		super("Conversion from  the currency " + from + " to the currency " + to + " or vice versa in not supported.");
    14 		this.from = from;
    15 		this.to = to;
    16 	}
    17 
    18 	public Currency getFrom() {
    19 		return from;
    20 	}
    21 
    22 	public Currency getTo() {
    23 		return to;
    24 	}
    25 	
    26 	
    27 }