本文整理匯總了Java中org.openhab.binding.homematic.internal.model.HmInterface.CUXD屬性的典型用法代碼示例。如果您正苦於以下問題:Java HmInterface.CUXD屬性的具體用法?Java HmInterface.CUXD怎麽用?Java HmInterface.CUXD使用的例子?那麽, 這裏精選的屬性代碼示例或許可以為您提供幫助。您也可以進一步了解該屬性所在類org.openhab.binding.homematic.internal.model.HmInterface
的用法示例。
在下文中一共展示了HmInterface.CUXD屬性的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: setChannelDatapointValues
/**
* Sets all datapoint values for the given channel.
*/
public void setChannelDatapointValues(HmChannel channel, HmParamsetType paramsetType) throws IOException {
RpcRequest<T> request = createRpcRequest("getParamset");
request.addArg(getRpcAddress(channel.getDevice().getAddress()) + ":" + channel.getNumber());
request.addArg(paramsetType.toString());
if (channel.getDevice().getHmInterface() == HmInterface.CUXD && paramsetType == HmParamsetType.VALUES) {
setChannelDatapointValues(channel);
} else {
try {
new GetParamsetParser(channel, paramsetType).parse(sendMessage(config.getRpcPort(channel), request));
} catch (UnknownRpcFailureException ex) {
if (paramsetType == HmParamsetType.VALUES) {
logger.debug(
"RpcResponse unknown RPC failure (-1 Failure), fetching values with another API method for device: {}, channel: {}, paramset: {}",
channel.getDevice().getAddress(), channel.getNumber(), paramsetType);
setChannelDatapointValues(channel);
} else {
throw ex;
}
}
}
}
示例2: initialize
@Override
public void initialize(HmDevice device) {
if (device.getType().startsWith(DEVICE_TYPE_19_REMOTE_CONTROL)
&& !(device.getHmInterface() == HmInterface.CUXD)) {
addDatapoint(device, 18, getName(), HmValueType.STRING, null, false);
}
}
示例3: initialize
@Override
public void initialize(HmDevice device) {
if (!device.isGatewayExtras() && !(device.getHmInterface() == HmInterface.CUXD)) {
HmDatapoint dp = addDatapoint(device, 0, getName(), HmValueType.ENUM, 0, false);
dp.setOptions(new String[] { MODE_LOCKED, MODE_RESET, MODE_FORCE, MODE_DEFER });
dp.setMinValue(0);
dp.setMaxValue(dp.getOptions().length - 1);
}
}
示例4: loadRssiValues
@Override
public void loadRssiValues() throws IOException {
for (HmInterface hmInterface : availableInterfaces.keySet()) {
if (hmInterface == HmInterface.RF || hmInterface == HmInterface.CUXD) {
List<HmRssiInfo> rssiInfos = getRpcClient(hmInterface).loadRssiInfo(hmInterface);
for (HmRssiInfo hmRssiInfo : rssiInfos) {
updateRssiInfo(hmRssiInfo.getAddress(), DATAPOINT_NAME_RSSI_DEVICE, hmRssiInfo.getDevice());
updateRssiInfo(hmRssiInfo.getAddress(), DATAPOINT_NAME_RSSI_PEER, hmRssiInfo.getPeer());
}
}
}
}
示例5: initialize
@Override
public void initialize(HmDevice device) {
if (!device.isGatewayExtras() && !(device.getHmInterface() == HmInterface.CUXD)) {
addDatapoint(device, 0, getName(), HmValueType.BOOL, Boolean.FALSE, false);
}
}