I then obtained a interface with the following issues:
public Map<String> GetPermissions(); the map has only one key type and is missing the value type which might be String too.
All the methods containing the parameter _interfaceName have a comma missing right after the parameter. For example I get the method StateChanged(String _path, String _interfaceNameUInt32 _state). This problem was seen in all calsses created: Device.Wireless.java, Settings.Connection.java.
The reference to the super(_path, _interfaceName) referencing the DBusSignal(String objectpath, Object... args) method must throw an exception.
Please correct me if I did something wrong.
Below full output of the above command:
import java.util.List;
import java.util.Map;
import org.freedesktop.dbus.DBusPath;
import org.freedesktop.dbus.interfaces.DBusInterface;
import org.freedesktop.dbus.messages.DBusSignal;
import org.freedesktop.dbus.types.UInt32;
import org.freedesktop.dbus.types.Variant;
/**
* Auto-generated class.
*/
public interface NetworkManager extends DBusInterface {
public void Reload(UInt32 flags);
public List<DBusPath> GetDevices();
public List<DBusPath> GetAllDevices();
public DBusPath GetDeviceByIpIface(String iface);
public DBusPath ActivateConnection(DBusPath connection, DBusPath device, DBusPath specificObject);
public DBusPath AddAndActivateConnection(Map<String, Map<String, Variant<?>>> connection, DBusPath device, DBusPath specificObject);
public DBusPath AddAndActivateConnection2(Map<String, Map<String, Variant<?>>> connection, DBusPath device, DBusPath specificObject, Map<String, Variant<?>> options);
public void DeactivateConnection(DBusPath activeConnection);
public void Sleep(boolean sleep);
public void Enable(boolean enable);
public Map<String> GetPermissions();
public void SetLogging(String level, String domains);
public String GetLogging();
public UInt32 CheckConnectivity();
public UInt32 state();
public DBusPath CheckpointCreate(List<DBusPath> devices, UInt32 rollbackTimeout, UInt32 flags);
public void CheckpointDestroy(DBusPath checkpoint);
public Map<String, UInt32> CheckpointRollback(DBusPath checkpoint);
public void CheckpointAdjustRollbackTimeout(DBusPath checkpoint, UInt32 addTimeout);
public static class StateChanged extends DBusSignal {
private final UInt32 state;
StateChanged(String _path, String _interfaceNameUInt32 _state) {
super(_path, _interfaceName);
this.state = _state;
}
public UInt32 getState() {
return state;
}
}
public static class PropertiesChanged extends DBusSignal {
private final Map<String, Variant<?>> properties;
PropertiesChanged(String _path, String _interfaceNameMap<String, Variant<?>> _properties) {
super(_path, _interfaceName);
this.properties = _properties;
}
public Map<String, Variant<?>> getProperties() {
return properties;
}
}
public static class DeviceAdded extends DBusSignal {
private final DBusPath devicePath;
DeviceAdded(String _path, String _interfaceNameDBusPath _devicePath) {
super(_path, _interfaceName);
this.devicePath = _devicePath;
}
public DBusPath getDevicePath() {
return devicePath;
}
}
public static class DeviceRemoved extends DBusSignal {
private final DBusPath devicePath;
DeviceRemoved(String _path, String _interfaceNameDBusPath _devicePath) {
super(_path, _interfaceName);
this.devicePath = _devicePath;
}
public DBusPath getDevicePath() {
return devicePath;
}
}
}
I run the main function of InterfaceCodeGenerator.java using the below arguments. This generated the
NetworkManager
interface.I then obtained a interface with the following issues:
public Map<String> GetPermissions();
the map has only one key type and is missing the value type which might beString
too._interfaceName
have a comma missing right after the parameter. For example I get the methodStateChanged(String _path, String _interfaceNameUInt32 _state)
. This problem was seen in all calsses created: Device.Wireless.java, Settings.Connection.java.super(_path, _interfaceName)
referencing theDBusSignal(String objectpath, Object... args)
method must throw an exception.Please correct me if I did something wrong.
Below full output of the above command: