
com.mangofactory.swagger.models.ScalaConverters Maven / Gradle / Ivy
The newest version!
package com.mangofactory.swagger.models;
import com.wordnik.swagger.model.ModelProperty;
import scala.Option;
import java.util.Map;
public class ScalaConverters {
public static scala.collection.mutable.LinkedHashMap
toScalaLinkedHashMap(Map propertyMap) {
scala.collection.mutable.LinkedHashMap properties = new scala.collection.mutable
.LinkedHashMap();
for (Map.Entry entry : propertyMap.entrySet()) {
properties.put(entry.getKey(), entry.getValue());
}
return properties;
}
public static T fromOption(Option o) {
if (!o.isDefined()) {
return null;
}
return o.get();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy