共享对象语法
在 AS3 中,我想使用字符串的内容设置共享对象的密钥,而不是专门命名密钥。
so.data.test = "andy" // this is the basic working system
我不想写测试我想要这样的东西
// this is a non working and incorrect solution but shows what I am trying to do.
String myKey = "test"
so.data.{myKey} = "andy"
这是一个不可能的问题吗?
In AS3 I would like to set the key of a shared object with the contents of a string as opposed to specifically naming the key.
so.data.test = "andy" // this is the basic working system
I do not want to write test I want something like this
// this is a non working and incorrect solution but shows what I am trying to do.
String myKey = "test"
so.data.{myKey} = "andy"
Is this an impossible ask?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
未经测试,但你可以尝试:
Untested, but you could try: