本文整理了Java中org.fourthline.cling.model.meta.Device.getDetails()
方法的一些代码示例,展示了Device.getDetails()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Device.getDetails()
方法的具体详情如下:
包路径:org.fourthline.cling.model.meta.Device
类名称:Device
方法名:getDetails
暂无
代码示例来源:origin: 4thline/cling
public DeviceDetails getDetails(RemoteClientInfo info) {
return this.getDetails();
}
代码示例来源:origin: 4thline/cling
@Override
public String getTitle() {
return device != null ? device.getDetails().getFriendlyName() : "(NO DEVICE)";
}
代码示例来源:origin: 4thline/cling
menuItem = new JMenu(entry.getKey().getDetails().getFriendlyName());
for (int i = 0; i < SUPPORTED_INSTANCES; i++) {
final int instanceId = i;
entry.getKey().getDetails().getFriendlyName() + " (Not Compatible)"
);
menuItem.setEnabled(false);
代码示例来源:origin: 4thline/cling
@Override
public String toString() {
String name =
getDevice().getDetails() != null && getDevice().getDetails().getFriendlyName() != null
? getDevice().getDetails().getFriendlyName()
: getDevice().getDisplayString();
// Display a little star while the device is being loaded (see performance optimization earlier)
return device.isFullyHydrated() ? name : name + " *";
}
}
代码示例来源:origin: 4thline/cling
@Override
public void failure(ActionInvocation invocation,
UpnpResponse operation,
String defaultMsg) {
addMediaRendererInformation(foundMediaRenderer, Collections.EMPTY_LIST);
updateStatusFailure(
"Error retrieving protocol info from " +
foundMediaRenderer.getDetails().getFriendlyName() + ". " + defaultMsg
);
}
代码示例来源:origin: 4thline/cling
@Override
public void success(ActionInvocation invocation) {
updateStatus(
"Successfuly sent URI to: (Instance: " + instanceId + ") " +
avTransportService.getDevice().getDetails().getFriendlyName()
);
}
代码示例来源:origin: 4thline/cling
String cleanModelNumber = null;
if (getDetails() != null && getDetails().getModelDetails() != null) {
ModelDetails modelDetails = getDetails().getModelDetails();
if (modelDetails.getModelName() != null) {
cleanModelName = modelDetails.getModelNumber() != null && modelDetails.getModelName().endsWith(modelDetails.getModelNumber())
if (getDetails() != null && getDetails().getManufacturerDetails() != null) {
if (cleanModelName != null && getDetails().getManufacturerDetails().getManufacturer() != null) {
cleanModelName = cleanModelName.startsWith(getDetails().getManufacturerDetails().getManufacturer())
? cleanModelName.substring(getDetails().getManufacturerDetails().getManufacturer().length()).trim()
: cleanModelName.trim();
if (getDetails().getManufacturerDetails().getManufacturer() != null) {
sb.append(getDetails().getManufacturerDetails().getManufacturer());
代码示例来源:origin: 4thline/cling
public List<ValidationError> validate() {
List<ValidationError> errors = new ArrayList<>();
if (getType() != null) {
// Only validate the graph if we have a device type - that means we validate only if there
// actually is a fully hydrated graph, not just a discovered device of which we haven't even
// retrieved the descriptor yet. This assumes that the descriptor will ALWAYS contain a device
// type. Now that is a risky assumption...
errors.addAll(getVersion().validate());
if(getIdentity() != null) {
errors.addAll(getIdentity().validate());
}
if (getDetails() != null) {
errors.addAll(getDetails().validate());
}
if (hasServices()) {
for (Service service : getServices()) {
if (service != null)
errors.addAll(service.validate());
}
}
if (hasEmbeddedDevices()) {
for (Device embeddedDevice : getEmbeddedDevices()) {
if (embeddedDevice != null)
errors.addAll(embeddedDevice.validate());
}
}
}
return errors;
}
代码示例来源:origin: 4thline/cling
public MessageBoxController(Controller parentController, final ControlPoint controlPoint, final Service service) {
super(new JFrame("MessageBoxService on: " + service.getDevice().getDetails().getFriendlyName()), parentController);
this.controlPoint = controlPoint;
this.service = service;
代码示例来源:origin: 4thline/cling
public void init(Service service) {
this.service = service;
view.setPresenter(this);
view.setTitle("WAN IP Connection on " + service.getDevice().getRoot().getDetails().getFriendlyName());
portMappingPresenter.init(
view.getPortMappingListView(),
view.getPortMappingEditView(),
service,
this
);
updateConnectionInfo();
}
代码示例来源:origin: 4thline/cling
view.setTitle(service.getDevice().getDetails().getFriendlyName());
代码示例来源:origin: kingthy/TVRemoteIME
public DeviceDetails getDetails(RemoteClientInfo info) {
return this.getDetails();
}
代码示例来源:origin: 4thline/cling
public void init(Service service) {
view.setPresenter(this);
view.setTitle("Content Directory on " + service.getDevice().getDetails().getFriendlyName());
view.getTreeView().setPresenter(detailPresenter);
view.getTreeView().init(controlPoint, service);
detailPresenter.init(view.getDetailView());
}
代码示例来源:origin: 4thline/cling
view.setTitle(service.getDevice().getDetails().getFriendlyName());
代码示例来源:origin: 4thline/cling
if (device.getDetails().getDlnaDocs() != null) {
for (DLNADoc dlnaDoc : device.getDetails().getDlnaDocs()) {
addIfNotNull(deviceNode, "DLNA Doc: ", dlnaDoc);
addIfNotNull(deviceNode, "DLNA Caps: ", device.getDetails().getDlnaCaps());
addIfNotNull(deviceNode, "Manufacturer: ", device.getDetails().getManufacturerDetails().getManufacturer());
addIfNotNull(deviceNode, "Manufacturer URL/URI: ", device.getDetails().getManufacturerDetails().getManufacturerURI(), device);
addIfNotNull(deviceNode, "Model Name: ", device.getDetails().getModelDetails().getModelName());
addIfNotNull(deviceNode, "Model #: ", device.getDetails().getModelDetails().getModelNumber());
addIfNotNull(deviceNode, "Model Description: ", device.getDetails().getModelDetails().getModelDescription());
addIfNotNull(deviceNode, "Model URL/URI: ", device.getDetails().getModelDetails().getModelURI(), device);
addIfNotNull(deviceNode, "Serial #: ", device.getDetails().getSerialNumber());
addIfNotNull(deviceNode, "Universal Product Code: ", device.getDetails().getUpc());
addIfNotNull(deviceNode, "Presentation URI: ", device.getDetails().getPresentationURI(), device);
代码示例来源:origin: 4thline/cling
+ " (UPnP Version: " + nodeDevice.getVersion().getMajor() + "." + nodeDevice.getVersion().getMinor() + ")"
);
setText(nodeDevice.getDetails().getFriendlyName());
代码示例来源:origin: kingthy/TVRemoteIME
public static boolean isLocalIpAddress(Device device) {
try {
String addrip = device.getDetails().getBaseURL().toString();
addrip = addrip.substring("http://".length(), addrip.length());
addrip = addrip.substring(0, addrip.indexOf(":"));
boolean ret = isLocalIpAddress(addrip);
ret = false;
return ret;
} catch (Exception e) {
e.printStackTrace();
}
return false;
}
代码示例来源:origin: kingthy/TVRemoteIME
String cleanModelNumber = null;
if (getDetails() != null && getDetails().getModelDetails() != null) {
ModelDetails modelDetails = getDetails().getModelDetails();
if (modelDetails.getModelName() != null) {
cleanModelName = modelDetails.getModelNumber() != null && modelDetails.getModelName().endsWith(modelDetails.getModelNumber())
if (getDetails() != null && getDetails().getManufacturerDetails() != null) {
if (cleanModelName != null && getDetails().getManufacturerDetails().getManufacturer() != null) {
cleanModelName = cleanModelName.startsWith(getDetails().getManufacturerDetails().getManufacturer())
? cleanModelName.substring(getDetails().getManufacturerDetails().getManufacturer().length()).trim()
: cleanModelName.trim();
if (getDetails().getManufacturerDetails().getManufacturer() != null) {
sb.append(getDetails().getManufacturerDetails().getManufacturer());
代码示例来源:origin: kingthy/TVRemoteIME
public List<ValidationError> validate() {
List<ValidationError> errors = new ArrayList();
if (getType() != null) {
// Only validate the graph if we have a device type - that means we validate only if there
// actually is a fully hydrated graph, not just a discovered device of which we haven't even
// retrieved the descriptor yet. This assumes that the descriptor will ALWAYS contain a device
// type. Now that is a risky assumption...
errors.addAll(getVersion().validate());
if (getDetails() != null) {
errors.addAll(getDetails().validate());
}
if (hasServices()) {
for (Service service : getServices()) {
if (service != null)
errors.addAll(service.validate());
}
}
if (hasEmbeddedDevices()) {
for (Device embeddedDevice : getEmbeddedDevices()) {
if (embeddedDevice != null)
errors.addAll(embeddedDevice.validate());
}
}
}
return errors;
}
代码示例来源:origin: 4thline/cling
DeviceDetails deviceModelDetails = deviceModel.getDetails(info);
appendNewElementIfNotNull(
descriptor, deviceElement, ELEMENT.friendlyName,
内容来源于网络,如有侵权,请联系作者删除!