KotlinDeepMutation:替换嵌套数据类结构中更深的字段的实用程序 源码
深层突变 用来替换嵌套Kotlin数据类结构中更深的字段的实用程序。 用法 取代栏位 val newUser = oldUser .mutate { ::userInfo } .then { ::company } .then { ::addresses } .then { ::secondary } .then { ::streetName } .replaceWith( " Joe Dassin " ) 转换场 val newUser = oldUser .mutate { ::userInfo } .then { ::homes } .then { ::principal } .then { ::pets } .tranform { plus(newPet) } :warning: 仅适用于数据类
下载地址
用户评论