-
Notifications
You must be signed in to change notification settings - Fork 151
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
memory-card and stateswitch #64
base: master
Are you sure you want to change the base?
Conversation
update pom.xml add onLougout event
2. 暂时完成stateswitch
2. 添加一些错误处理
Good job, you are very fast! I believe this PR should link to our SoC at wechaty/summer#4 |
|
||
fun removeEventListener(type: StateEnum, listener: StateSwitchListener) { | ||
super.removeListener(type, object : Listener { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
直接把 listener 传入就可以了
|
||
} | ||
// get the current on state | ||
fun on(): String { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
返回枚举,方便调用方使用
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
原本是返回枚举的,后来我感觉返回字符串更直观,但是返回枚举确实用起来更简单
2. 完善stateswitch的测试 3. 将stateswitch的name属性作为构造函数
2. Message.kt添加date,forward等方法 3. 添加say方法 4. 还未测试
2. Message.kt添加age方法 3. MemoryCard.kt添加getName()fangfa
2. Contact添加获取信息的方法 3. Room添加member方法 4. Wechaty添加say和onReady事件 5. WechatyListener修改FriendShiplistener参数 6.
没测试过的好像都是测试类,好像是因为我有本地文件和obs的连接配置所以ci的时候过不了 |
2. 添加messageQueryFilterFactory方法,新增相关的typealias
this.name = "default" | ||
_options.name = "default" | ||
} | ||
this.options = _options |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
!的写法可以更 koltin 一些
好的,这个好像是刚开始写kotlin的时候写的
…------------------ 原始邮件 ------------------
发件人: "犀利豆"<[email protected]>;
发送时间: 2020年10月18日(星期天) 晚上8:57
收件人: "wechaty/java-wechaty"<[email protected]>;
抄送: "."<[email protected]>; "State change"<[email protected]>;
主题: Re: [wechaty/java-wechaty] memory-card and stateswitch (#64)
@diaozxin007 approved this pull request.
In wechaty-puppet/src/main/kotlin/io/github/wechaty/memorycard/MemoryCard.kt:
> + val _options: MemoryCardOptions = options ?: MemoryCardOptions() + log.info("MemoryCard, constructor({})", JsonUtils.write(_options)) + + if(name != null) { + _options.name = name + } + + else if (_options.name != null) { + this.name = _options.name + } + else { + // 如果没有给名字就用一个default作为名字 + this.name = "default" + _options.name = "default" + } + this.options = _options
!的写法可以更 koltin 一些
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub, or unsubscribe.
|
完成了memory-card和stateswitch