📄 bank.idl
字号:
/*
* This idl file is generated by the ORB Plugin
*/
// 银行账户管理程序的对象接口定义
module Bank {
// 账户
interface Account {
// 存款
void deposit(in float amount);
// 取款
boolean withdraw(in float amount);
// 查询余额
float getBalance();
string getId();
string getName();
void setName(in string name);
void setId(in string id);
void setBalance(in float amount);
};
// 账户管理员
interface AccountManager {
//根据帐户标识查找帐户
Account getAccountById(in string id);
//
void releaseObject(in Account acc);
//查询指定名字的账户,查无则新开账户
Account open(in string id);
//根据指定id的帐户,撤销帐户
void close(in string id);
};
struct AccountInfo{
string id;
string name;
float balance;
};
typedef sequence<AccountInfo> AccountInfoSeq;
interface AccountIterator{
//判断迭代器中向后是否还有数据
boolean hasNext();
//判断迭代器中向前是否还有数据
boolean hasPre();
//返回下一组数据
AccountInfoSeq next(in string sql);
//返回上一组数据
AccountInfoSeq pre();
//返回查询结果总页数
long getTotalPage();
//返回当前页码
long getNowPage();
//清空重新查询
void clean();
//返回第一页
AccountInfoSeq returnFirstPage();
//返回最后一页
AccountInfoSeq returnLastPage();
//设置当前页数值
void setNowPage(in long nowPage);
};
};
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -