更新时间:2021-07-14 08:32:21
您不能这样做.既不迅速也不客观-c.
You can't do this. Neither in swift nor objective-c.
要做的是存储要检索的数据.也就是说...将名称存储在某个地方,然后使用它来加载图像.并非如此.
The thing to do is to store the data you want to retrieve. That is... store the name somewhere and use that to load the image. Not the other way around.
因此,请创建类似于imageName
的属性,然后使用该属性加载图像.
So create a property something like imageName
and then use that to load the image.