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 booleanequals(Object obj)StringgetFileName()Gets the filename (name.ogg) of thisBabelAudio.it.uniroma1.lcl.jlt.util.LanguagegetLanguage()Gets theLanguageof thisBabelAudioStringgetLemma()Gets the lemma of thisBabelAudio.static intgetResponseCode(String urlString)Gets the response code for an input URL stringStringgetUrl()Gets the full URL thisBabelAudio.StringgetValidatedUrl()Deprecated.Returns a valid URL for the audio fileinthashCode()static voidmain(String[] args)StringtoString()
-
-
-
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 theLanguageof thisBabelAudio- Returns:
- the
Languageof 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
BabelAudiocan 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)
-
-