Package de.umass.lastfm.Result

Examples of de.umass.lastfm.Result.Status


    try {
      Document document = newDocumentBuilder()
          .parse(new InputSource(new InputStreamReader(inputStream, "UTF-8")));
      Element root = document.getDocumentElement(); // lfm element
      String statusString = root.getAttribute("status");
      Status status = "ok".equals(statusString) ? Status.OK : Status.FAILED;
      if (status == Status.FAILED) {
        if (cache != null)
          cache.remove(cacheEntryName); // if request was failed remove from cache
        Element error = (Element) root.getElementsByTagName("error").item(0);
        int errorCode = Integer.parseInt(error.getAttribute("code"));
View Full Code Here

TOP

Related Classes of de.umass.lastfm.Result.Status

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.