![JAR search and dependency download from the Maven repository](/logo.png)
org.ow2.binjiu.description.model2java.M2JProcessor Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of upnp2java Show documentation
Show all versions of upnp2java Show documentation
Description generator for convert UPnP XML description to java interfaces.
package org.ow2.binjiu.description.model2java;
import org.ow2.binjiu.description.exception.UnpleasantTypeException;
import org.ow2.binjiu.description.model.Service;
import org.ow2.binjiu.description.model.Type;
public class M2JProcessor {
public static String process(Service service) throws UnpleasantTypeException{
JavaSerializer serializer = new JavaSerializer(service);
return serializer.process();
}
public static Class> getAssociatedType(Type type) throws UnpleasantTypeException{
//FIXME deport to another place
if (type.equals(new Type("integer"))){
return int.class;
} else if (type.equals(new Type("string"))){
return String.class;
}
throw new UnpleasantTypeException(type.getName());
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy