我想使用 SBApplication sendEvent 发送原始数据(void*)
不幸的是,我没有找到与此相关的文档。
您有什么想法来实现这一目标吗?
预先感谢您的帮助,
问候,
最佳答案
sendEvent:id:parameters:
实际上是所有 SBObject 响应的消息,而不仅仅是 SBApplications。 SBObject.h 说:
// Send an Apple event. The direct parameter is the specifier of the receiver if it // is non-null. Other parameters are given using "parameters:" as a list of pairs // of the parameter four-byte code followed by an Objective-C object; use a parameter // code of 0 to mark the end of the list.
因此,尝试将数据装箱到 NSData 对象中,然后传递该对象。
关于objective-c - SB应用程序: how to send raw data,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3816193/