You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Problems to set the result ob getBpm() into an int variable.
Exception in thread "main" java.lang.NumberFormatException: For input string: "0 Bpm"
at java.base/jdk.internal.math.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:2054)
at java.base/jdk.internal.math.FloatingDecimal.parseFloat(FloatingDecimal.java:122)
at java.base/java.lang.Float.parseFloat(Float.java:455)
at com.mpatric.mp3agic.AbstractID3v2Tag.getBPM(AbstractID3v2Tag.java:600)
The text was updated successfully, but these errors were encountered:
MaWiLi
changed the title
Error with Metatag bpm - Floating Decima Error
Error with Metatag bpm - Floating Decimal Error
Jan 12, 2021
@Test
public void shouldStoreAndRetrieveBPM() throws Exception {
final ID3v22Tag id3tag = new ID3v22Tag();
final int bpm = 8 * 44100;
id3tag.setBPM(bpm);
final byte[] bytes = id3tag.toBytes();
final ID3v22Tag newId3tag = new ID3v22Tag(bytes);
assertEquals(bpm, newId3tag.getBPM());
}
It works fine. What is the code you use to produce the above exception?
Problems to set the result ob getBpm() into an int variable.
Exception in thread "main" java.lang.NumberFormatException: For input string: "0 Bpm"
at java.base/jdk.internal.math.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:2054)
at java.base/jdk.internal.math.FloatingDecimal.parseFloat(FloatingDecimal.java:122)
at java.base/java.lang.Float.parseFloat(Float.java:455)
at com.mpatric.mp3agic.AbstractID3v2Tag.getBPM(AbstractID3v2Tag.java:600)
The text was updated successfully, but these errors were encountered: