// Charter 标准库 - ACC-1410 分区代币协议 // 版本: 1.0 | NAC 原生分区代币标准(证券分区/股权分区) /// ACC-1410 分区代币接口 /// 支持将代币分割为多个分区(普通股、优先股、限制股等) protocol Acc1410 { /// 创建新分区 fn create_partition(name: String, gnacs: ExtendedGNACS, partition_type: PartitionType) -> Hash; /// 向分区发行代币 fn issue_to_partition(partition_id: Hash, to: Address, amount: u128) -> Result; /// 查询分区余额 fn balance_of_by_partition(partition_id: Hash, account: Address) -> u128; /// 分区间转账 fn transfer_by_partition(from: Address, to: Address, amount: u128, partition_id: Hash) -> Result; /// 授权操作员 fn authorize_operator(account: Address, operator: Address); /// 操作员代理转账 fn operator_transfer_by_partition( operator: Address, from: Address, to: Address, amount: u128, partition_id: Hash ) -> Result; /// 查询账户持有的分区列表 fn partitions_of(account: Address) -> Vec; } /// 分区类型枚举 enum PartitionType { CommonStock, // 普通股 PreferredStock, // 优先股 RestrictedStock, // 限制股 EmployeeOption, // 员工期权 IncomeRight, // 收益权 VotingRight, // 投票权 } /// GNACS 扩展编码(64位) struct ExtendedGNACS { base_gnacs: Bytes, // 基础 GNACS 编码(48位) extension: GNACSExtension, // 扩展字段(16位) }