task2/solution09/src/org/apidesign/apifest08/currency/Convertor.java
author Jaroslav Tulach <jaroslav.tulach@apidesign.org>
Wed, 01 Oct 2008 10:43:05 +0200
changeset 29 f6073056b9fe
parent 6 task1/solution09/src/org/apidesign/apifest08/currency/Convertor.java@97662396c0fd
permissions -rw-r--r--
Getting ready for task2: copying all solutions to new locations
     1 package org.apidesign.apifest08.currency;
     2 
     3 /** This is the skeleton class for your API. You need to make it public, so
     4  * it is accessible to your client code (currently in Task1Test.java) file.
     5  * <p>
     6  * Feel free to create additional classes or rename this one, just keep all
     7  * the API and its implementation in this package. Do not spread it outside
     8  * to other packages.
     9  */
    10 public interface Convertor {
    11 
    12     /**
    13      * converts amount in first currency to amount second currency.
    14      * @param amountInCents the amount of first currency in cents (or equivalent)
    15      * @return the amount in the second currency in cents (or equivalent)
    16      */
    17     public long convertTo(long amountInCents);
    18 
    19 
    20     /**
    21      * converts from second currency amount to first currency amount.
    22      * @param amountInCents the amount of second currency in cents (or equivalent)
    23      * @return the amount in the first currency in cents (or equivalent)
    24      */
    25     public long convertFrom(long amountInCents);
    26 }