在蓝牙文档中,有一个代码示例来解释 J2ME 与蓝牙的功能。该代码使用 BCC ,可能是蓝牙控制中心,并且它调用的方法不包含在 javadoc 中。这是代码示例的 URL: code sample
我查看了javadoc,但没有找到前三个方法。
那么什么是密件抄送?以及如何创建它?
最佳答案
您链接到的页面明确指出:
The underlying Bluetooth system upon which the Java APIs will be built must also meet certain requirements:
- The underlying system must be "qualified," in accordance with the Bluetooth Qualification Program, for at least the Generic Access Profile, Service Discovery Application Profile, and Serial Port Profile.
- The system must support three communication layers or protocols as defined in the 1.1 Bluetooth Specification, and the implementation of this API must have access to them: Service Discovery Protocol (SDP), Radio Frequency Communications Protocol (RFCOMM), and Logical Link Control and Adaptation Protocol (L2CAP).
- The system must provide a Bluetooth Control Center (BCC), a control panel much like the application that allows a user or OEM to define specific values for certain configuration parameters in a stack.
您不必创建密件抄送:系统必须提供密件抄送。此外:
What Is the BCC?
Bluetooth devices that implement this API may allow multiple applications to execute concurrently. The BCC prevents any application from harming another. The BCC is a set of capabilities that allow a user or OEM to resolve conflicting application requests by defining specific values for certain configuration parameters in a Bluetooth stack. It is the central authority for local Bluetooth device settings. The BCC might be a native application, an application with a separate API, or simply a group of settings that are specified by the manufacturer and cannot be changed by the user. Note that the BCC is not a class or an interface defined in this specification but an important part of its security architecture.
您指向的代码示例是:
// set the port number
BCC.setPortNumber("COM1");
// set the baud rate
BCC.setBaudRate(50000);
// set the connectable mode
BCC.setConnectable(true);
// set the discovery mode to Limited Inquiry Access Code
BCC.setDiscoverable(DiscoveryAgent.LIAC);
但是,文章在这个示例上面指出:
As an example, Atinav's Java Bluetooth solution requires the developer to initialize the stack with a series of settings like the ones in the following code snippet - note well that the APIs invoked are not part of JSR 82.
关于java - 这是什么物体?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/6831101/