/** * 输出数据到Dto处 * * @param partner Dto */ public void toDto(PartnerInfo partner) { partner.setId(this.getId()); partner.setName(this.getName()); partner.setPassword(this.getPassword()); partner.setPublicKey(this.getPublicKey()); partner.setPrivateKey(this.getPrivateKey()); }
/** * 从Dto读取数据 * * @param partner Dto */ public void fromDto(PartnerInfo partner) { this.setId(partner.getId()); this.setName(partner.getName()); this.setPassword(partner.getPassword()); this.setPublicKey(partner.getPublicKey()); this.setPrivateKey(partner.getPrivateKey()); }