felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Lars-Erik Kimmel (JIRA)" <j...@apache.org>
Subject [jira] Created: (FELIX-2579) deviceType in desciption of subdevices missing
Date Mon, 06 Sep 2010 10:20:32 GMT
deviceType in desciption of subdevices missing

                 Key: FELIX-2579
                 URL: https://issues.apache.org/jira/browse/FELIX-2579
             Project: Felix
          Issue Type: Bug
            Reporter: Lars-Erik Kimmel
            Priority: Minor

The desciption lacks of deviceType for subdevices.
It can be pinned down to BuildDevice, where only in the description of the root device the
deviceType with the highest supported version is added to the document.

a simple workaround helps by introducing a method made of the code in the build of the root
	private static void setDeviceTypeWithHighestVersion(Device devUPnP, ServiceReference sr)
		Object aux = sr.getProperty(UPnPDevice.TYPE);
		}else if(aux instanceof String){
			devUPnP.setDeviceType((String) aux);
		}else if(aux instanceof String[]){
			//The property key UPnP.device.type should be a String
			String[] v = (String[]) aux;
			int maxindex=0;
			int max=Integer.parseInt(v[0].substring(v[0].lastIndexOf(":")+1));
			int tmp;
			for (int i = 1; i < v.length; i++) {

And call
setDeviceTypeWithHighestVersion(devUPnP, sr);
in buildRootDeviceNode(..) and buildDevice(..)

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message