一:打印机 1.Slice定义: interface Printer { void printString(string s); }; 我们的Slice定义含有一个接口,叫作Printer.目前,我们的接口非常 简单,只提供了一个操作,叫作printString.该定义保存为Printer.ice 2.要创建我们的C++应用,第一步是要编译我们的Slice定义,生成C++代理和骨架.在UNIX上,你可以这样编译定义: $ slice2cpp Printer.ice slice2cpp编译器根据这…