public interface IPrinterDelegate extends IPrinter {
abstract void PrintAll(IPrintable printable);
}
public class PrinterDelegate implements IPrinterDelegate {
@Override
public void PrintString(String string) {
System.out.print(string);
}
@Override
public void PrintChar(char character) {
System.out.print(character);
}
@Override
public void PrintAll(IPrintable printable) {
printable.Print(this);
}
}