Package it.uniroma1.lcl.babelnet.data
Class BabelAudio
- java.lang.Object
-
- it.uniroma1.lcl.babelnet.data.BabelAudio
-
public class BabelAudio extends Object
Au audio item in BabelNet.- Author:
- navigli, vannella
-
-
Constructor Summary
Constructors Constructor Description BabelAudio(String lemma, it.uniroma1.lcl.jlt.util.Language language, String filename)
Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean
equals(Object obj)
String
getFileName()
Gets the filename (name.ogg) of thisBabelAudio
.it.uniroma1.lcl.jlt.util.Language
getLanguage()
Gets theLanguage
of thisBabelAudio
String
getLemma()
Gets the lemma of thisBabelAudio
.static int
getResponseCode(String urlString)
Gets the response code for an input URL stringString
getUrl()
Gets the full URL thisBabelAudio
.String
getValidatedUrl()
Deprecated.Returns a valid URL for the audio fileint
hashCode()
static void
main(String[] args)
String
toString()
-
-
-
Method Detail
-
getLemma
public String getLemma()
Gets the lemma of thisBabelAudio
.- Returns:
- the lemma of this
BabelAudio
.
-
getLanguage
public it.uniroma1.lcl.jlt.util.Language getLanguage()
Gets theLanguage
of thisBabelAudio
- Returns:
- the
Language
of thisBabelAudio
.
-
getFileName
public String getFileName()
Gets the filename (name.ogg) of thisBabelAudio
.- Returns:
- the filename (name.ogg) of this
BabelAudio
.
-
getUrl
public String getUrl()
Gets the full URL thisBabelAudio
.- Returns:
- the URL from which this
BabelAudio
can be retrieved.
-
getValidatedUrl
@Deprecated public String getValidatedUrl()
Deprecated.Returns a valid URL for the audio file- Returns:
- valid URL
-
getResponseCode
public static int getResponseCode(String urlString) throws MalformedURLException, IOException
Gets the response code for an input URL string- Parameters:
urlString
- the URL string- Returns:
- the response code for an input URL
- Throws:
MalformedURLException
- thrown if the URL is malformedIOException
- thrown if the URL cannot be opened
-
main
public static void main(String[] args)
-
-