001/* 002 * Copyright (c) 2012, the Last.fm Java Project and Committers 003 * All rights reserved. 004 * 005 * Redistribution and use of this software in source and binary forms, with or without modification, are 006 * permitted provided that the following conditions are met: 007 * 008 * - Redistributions of source code must retain the above 009 * copyright notice, this list of conditions and the 010 * following disclaimer. 011 * 012 * - Redistributions in binary form must reproduce the above 013 * copyright notice, this list of conditions and the 014 * following disclaimer in the documentation and/or other 015 * materials provided with the distribution. 016 * 017 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED 018 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A 019 * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR 020 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT 021 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 022 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR 023 * TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 024 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 025 */ 026 027package de.umass.lastfm.scrobble; 028 029/** 030 * The rating of the track. See <a href="https://www.last.fm/api/submissions#subs">https://www.last.fm/api/submissions#subs</a> 031 * for more information. 032 * 033 * @author Lukasz Wisniewski 034 * @deprecated The 1.2.x scrobble protocol has now been deprecated in favour of the 2.0 protocol which is part of the Last.fm web services API. 035 */ 036@Deprecated 037public enum Rating { 038 039 /** 040 * Love (on any mode if the user has manually loved the track). This implies a listen. 041 */ 042 LOVE("L"), 043 044 /** 045 * Ban (only if source=L). This implies a skip, and the client should skip to the next track when a ban happens 046 */ 047 BAN("B"), 048 049 /** 050 * Skip (only if source=L) 051 */ 052 SKIP("S"); 053 054 private String code; 055 056 Rating(String code) { 057 this.code = code; 058 } 059 060 /** 061 * Returns the corresponding code for this rating. 062 * 063 * @return the code 064 */ 065 public String getCode() { 066 return code; 067 } 068}