Package se.despotify.client.protocol.command

Examples of se.despotify.client.protocol.command.ChecksumException


    }
    /* Create and return playlist. */
    Playlist.fromXMLElement(playlistElement, store, playlist);

    if (playlist.getTracks() != null && playlist.getChecksum() != playlist.calculateChecksum()) {
      throw new ChecksumException(playlist.getChecksum(), playlist.calculateChecksum());
    }

    playlist.setLoaded(new Date());
    return true;

View Full Code Here


    if (playlists.getItems().size() != Long.parseLong(versionTagValues[1])) {
      throw new RuntimeException("Size missmatch");
    }

    if (playlists.calculateChecksum() != playlists.getChecksum()) {
      throw new ChecksumException(playlists.calculateChecksum(), playlists.getChecksum());
    }
    if (playlist.isCollaborative() != (Integer.parseInt(versionTagValues[3]) == 1)) {
      throw new RuntimeException("Collaborative flag missmatch");
    }
View Full Code Here

    }
    /* Create and return playlist. */
    Playlist.fromXMLElement(playlistElement, store, playlist);

    if (playlist.getTracks() != null && playlist.getChecksum() != playlist.calculateChecksum()) {
      throw new ChecksumException(playlist.getChecksum(), playlist.calculateChecksum());
    }

    playlist.setLoaded(new Date());
    store.persist(playlist);
    return true;
View Full Code Here

    }
    if (playlist.getTracks().size() != Long.parseLong(versionTagValues[1])) {
      throw new RuntimeException("Size missmatch, playlist = " + playlist.getTracks().size() + ", received = " + versionTagValues[1]);
    }
    if (playlist.calculateChecksum() != playlist.getChecksum()) {
      throw new ChecksumException(playlist.getChecksum(), playlist.calculateChecksum());
    }

  }
View Full Code Here

    if (playlists.getItems().size() != Long.parseLong(versionTagValues[1])) {
      throw new RuntimeException("Size missmatch");
    }

    if (playlists.calculateChecksum() != playlists.getChecksum()) {
      throw new ChecksumException(playlists.calculateChecksum(), playlists.getChecksum());
    }
    if (playlist.isCollaborative() != (Integer.parseInt(versionTagValues[3]) == 1)) {
      throw new RuntimeException("Collaborative flag missmatch");
    }
View Full Code Here

      if (playlist.size() != Long.parseLong(versionTagValues[1])) {
        throw new RuntimeException("Size mismatch");
      }
      if(playlist.getChecksum() != playlist.calculateChecksum()) {
        throw new ChecksumException(playlist.getChecksum(), playlist.calculateChecksum());
      }
      if (playlist.isCollaborative() != (Integer.parseInt(versionTagValues[3]) == 1)) {
        throw new RuntimeException();
      }
View Full Code Here

      if (playlist.size() != Long.parseLong(versionTagValues[1])) {
        throw new RuntimeException("Size mismatch");
      }
      if(playlist.getChecksum() != playlist.calculateChecksum()) {
        throw new ChecksumException(playlist.getChecksum(), playlist.calculateChecksum());
      }
      if(playlist.isCollaborative() != (Integer.parseInt(versionTagValues[3]) == 1)) {
        throw new RuntimeException();
      }
View Full Code Here

    }
    /* Create and return playlist. */
    Playlist.fromXMLElement(playlistElement, store, playlist);

    if (playlist.getTracks() != null && playlist.getChecksum() != playlist.calculateChecksum()) {
      throw new ChecksumException(playlist.getChecksum(), playlist.calculateChecksum());
    }

    playlist.setLoaded(new Date());
    store.persist(playlist);
    return true;
View Full Code Here

TOP

Related Classes of se.despotify.client.protocol.command.ChecksumException

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.