removed unused method

This commit is contained in:
Tony Tam 2012-09-20 14:16:34 -07:00
parent 59cd5380aa
commit 26bcc80ae3

View File

@ -28,17 +28,6 @@ import scala.io.Source
object CoreUtils {
def m = JsonUtil.getJsonMapper
def fetchAndExtractAllModels(baseDoc: Documentation): Map[String, DocumentationSchema] = {
val modelObjects = new HashMap[String, DocumentationSchema]
baseDoc.getApis.foreach(api => {
val apiPath = (baseDoc.basePath + api.path).replaceAll(".\\{format\\}", ".json")
val sd = m.readValue(Source.fromURL(apiPath).mkString, classOf[Documentation])
for ((nm, model) <- extractModels(sd)) modelObjects += nm -> model
if (sd.getModels != null) sd.getModels.foreach(sm => modelObjects += sm._1 -> sm._2)
})
modelObjects.toMap
}
def extractAllModels(docs: List[Documentation]): Map[String, DocumentationSchema] = {
val modelObjects = new HashMap[String, DocumentationSchema]
docs.foreach(sd => {