X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Fnet%2Fpterodactylus%2Fsonitus%2Fio%2FOggVorbisIdentifier.java;h=769acf2f1a910e2babe8b50659c013d1fe477734;hb=865e9a8fce99285dfd6c1efb6a01991076e1a773;hp=49daa2780459842a858d51a35881450a79864418;hpb=ee261ec959322c6d1969aff67319559ba1480859;p=sonitus.git diff --git a/src/main/java/net/pterodactylus/sonitus/io/OggVorbisIdentifier.java b/src/main/java/net/pterodactylus/sonitus/io/OggVorbisIdentifier.java index 49daa27..769acf2 100644 --- a/src/main/java/net/pterodactylus/sonitus/io/OggVorbisIdentifier.java +++ b/src/main/java/net/pterodactylus/sonitus/io/OggVorbisIdentifier.java @@ -20,7 +20,7 @@ package net.pterodactylus.sonitus.io; import java.io.IOException; import java.io.InputStream; -import net.pterodactylus.sonitus.data.Format; +import net.pterodactylus.sonitus.data.Metadata; import com.google.common.base.Optional; import com.jcraft.jogg.Packet; @@ -49,16 +49,16 @@ public class OggVorbisIdentifier { /** * Tries to parse the given stream as Ogg Vorbis file and returns a {@link - * Format} describing the stream. + * Metadata} describing the stream. * * @param inputStream * The input stream to identify as Ogg Vorbis - * @return The identified format, or {@link com.google.common.base.Optional#absent()} - * if the stream could not be identified + * @return The identified metadata, or {@link Optional#absent()} if the stream + * could not be identified * @throws IOException * if an I/O error occurs */ - public static Optional identify(InputStream inputStream) throws IOException { + public static Optional identify(InputStream inputStream) throws IOException { /* stuff needed to decode Ogg. */ Packet packet = new Packet(); @@ -115,7 +115,7 @@ public class OggVorbisIdentifier { buffer = syncState.data; } - return Optional.of(new Format(info.channels, info.rate, "Vorbis")); + return Optional.of(new Metadata(info.channels, info.rate, "Vorbis")); } }