1 package org.apidesign.apifest08.currency;
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.
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
10 public interface Convertor {
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)
17 public long convertTo(long amountInCents);
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)
25 public long convertFrom(long amountInCents);