diff options
author | Clyhtsuriva <61652557+clyhtsuriva@users.noreply.github.com> | 2021-06-26 14:54:04 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-26 14:54:04 +0000 |
commit | af3f000913ddcd6fdf4d8581c0e9dad1b1edc6a3 (patch) | |
tree | a0c875335ce68efd4959ee031dfa8671c9eaa78a /target/site/jacoco/musichub.business | |
parent | 4ff84568723b1663b9e20f95535d3213f8d3e92e (diff) | |
parent | e9ee951e570c441151385d1ccd8c4230abf704ca (diff) |
Merge pull request #6 from Said-Belhadj/feature/STZ-0002
Feature/stz 0002
Diffstat (limited to 'target/site/jacoco/musichub.business')
31 files changed, 990 insertions, 0 deletions
diff --git a/target/site/jacoco/musichub.business/Album.html b/target/site/jacoco/musichub.business/Album.html new file mode 100644 index 0000000..24287ce --- /dev/null +++ b/target/site/jacoco/musichub.business/Album.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Album</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">Album</span></div><h1>Album</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">330 of 330</td><td class="ctr2">0 %</td><td class="bar">14 of 14</td><td class="ctr2">0 %</td><td class="ctr1">16</td><td class="ctr2">16</td><td class="ctr1">84</td><td class="ctr2">84</td><td class="ctr1">9</td><td class="ctr2">9</td></tr></tfoot><tbody><tr><td id="a4"><a href="Album.java.html#L112" class="el_method">createXMLElement(Document, Element)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="129" alt="129"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="20" height="10" title="2" alt="2"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f1">2</td><td class="ctr2" id="g1">2</td><td class="ctr1" id="h0">26</td><td class="ctr2" id="i0">26</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a1"><a href="Album.java.html#L49" class="el_method">Album(Element)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="104" height="10" title="112" alt="112"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="12" alt="12"/></td><td class="ctr2" id="e1">0 %</td><td class="ctr1" id="f0">7</td><td class="ctr2" id="g0">7</td><td class="ctr1" id="h1">26</td><td class="ctr2" id="i1">26</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a2"><a href="Album.java.html#L35" class="el_method">Album(String, String, int, String)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="31" height="10" title="34" alt="34"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h2">12</td><td class="ctr2" id="i2">12</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a3"><a href="Album.java.html#L21" class="el_method">Album(String, String, int, String, String, ArrayList)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="30" height="10" title="33" alt="33"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d3"/><td class="ctr2" id="e3">n/a</td><td class="ctr1" id="f3">1</td><td class="ctr2" id="g3">1</td><td class="ctr1" id="h3">12</td><td class="ctr2" id="i3">12</td><td class="ctr1" id="j3">1</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a7"><a href="Album.java.html#L98" class="el_method">getSongsRandomly()</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="6" height="10" title="7" alt="7"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d4"/><td class="ctr2" id="e4">n/a</td><td class="ctr1" id="f4">1</td><td class="ctr2" id="g4">1</td><td class="ctr1" id="h4">3</td><td class="ctr2" id="i4">3</td><td class="ctr1" id="j4">1</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a0"><a href="Album.java.html#L89" class="el_method">addSong(UUID)</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="6" alt="6"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d5"/><td class="ctr2" id="e5">n/a</td><td class="ctr1" id="f5">1</td><td class="ctr2" id="g5">1</td><td class="ctr1" id="h5">2</td><td class="ctr2" id="i5">2</td><td class="ctr1" id="j5">1</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a6"><a href="Album.java.html#L94" class="el_method">getSongs()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f6">1</td><td class="ctr2" id="g6">1</td><td class="ctr1" id="h6">1</td><td class="ctr2" id="i6">1</td><td class="ctr1" id="j6">1</td><td class="ctr2" id="k6">1</td></tr><tr><td id="a8"><a href="Album.java.html#L104" class="el_method">getTitle()</a></td><td class="bar" id="b7"><img src="../jacoco-resources/redbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c7">0 %</td><td class="bar" id="d7"/><td class="ctr2" id="e7">n/a</td><td class="ctr1" id="f7">1</td><td class="ctr2" id="g7">1</td><td class="ctr1" id="h7">1</td><td class="ctr2" id="i7">1</td><td class="ctr1" id="j7">1</td><td class="ctr2" id="k7">1</td></tr><tr><td id="a5"><a href="Album.java.html#L108" class="el_method">getDate()</a></td><td class="bar" id="b8"><img src="../jacoco-resources/redbar.gif" width="2" height="10" title="3" alt="3"/></td><td class="ctr2" id="c8">0 %</td><td class="bar" id="d8"/><td class="ctr2" id="e8">n/a</td><td class="ctr1" id="f8">1</td><td class="ctr2" id="g8">1</td><td class="ctr1" id="h8">1</td><td class="ctr2" id="i8">1</td><td class="ctr1" id="j8">1</td><td class="ctr2" id="k8">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Album.java.html b/target/site/jacoco/musichub.business/Album.java.html new file mode 100644 index 0000000..107bbe9 --- /dev/null +++ b/target/site/jacoco/musichub.business/Album.java.html @@ -0,0 +1,146 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Album.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">Album.java</span></div><h1>Album.java</h1><pre class="source lang-java linenums">package musichub.business; + +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; + +import java.text.ParseException; +import java.text.SimpleDateFormat; +import java.util.*; + + +public class Album { + private final String title; + private final int lengthInSeconds; + private final UUID uuid; + private String artist; + private Date date; + private ArrayList<UUID> songsUIDs; + +<span class="nc" id="L21"> public Album(String title, String artist, int lengthInSeconds, String id, String date, ArrayList<UUID> songsUIDs) {</span> +<span class="nc" id="L22"> this.title = title;</span> +<span class="nc" id="L23"> this.artist = artist;</span> +<span class="nc" id="L24"> this.lengthInSeconds = lengthInSeconds;</span> +<span class="nc" id="L25"> this.uuid = UUID.fromString(id);</span> + try { +<span class="nc" id="L27"> SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");</span> +<span class="nc" id="L28"> this.date = sdf.parse(date);</span> +<span class="nc" id="L29"> } catch (ParseException ex) {</span> +<span class="nc" id="L30"> ex.printStackTrace();</span> +<span class="nc" id="L31"> }</span> +<span class="nc" id="L32"> this.songsUIDs = songsUIDs;</span> +<span class="nc" id="L33"> }</span> + +<span class="nc" id="L35"> public Album(String title, String artist, int lengthInSeconds, String date) {</span> +<span class="nc" id="L36"> this.title = title;</span> +<span class="nc" id="L37"> this.artist = artist;</span> +<span class="nc" id="L38"> this.lengthInSeconds = lengthInSeconds;</span> +<span class="nc" id="L39"> this.uuid = UUID.randomUUID();</span> + try { +<span class="nc" id="L41"> SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");</span> +<span class="nc" id="L42"> this.date = sdf.parse(date);</span> +<span class="nc" id="L43"> } catch (ParseException ex) {</span> +<span class="nc" id="L44"> ex.printStackTrace();</span> +<span class="nc" id="L45"> }</span> +<span class="nc" id="L46"> this.songsUIDs = new ArrayList<>();</span> +<span class="nc" id="L47"> }</span> + +<span class="nc" id="L49"> public Album(Element xmlElement) throws Exception {</span> + { +<span class="nc" id="L51"> this.title = xmlElement.getElementsByTagName("title").item(0).getTextContent();</span> +<span class="nc" id="L52"> this.lengthInSeconds = Integer.parseInt(xmlElement.getElementsByTagName("lengthInSeconds").item(0).getTextContent());</span> +<span class="nc" id="L53"> String uuid = null;</span> + try { +<span class="nc" id="L55"> uuid = xmlElement.getElementsByTagName("UUID").item(0).getTextContent();</span> +<span class="nc" id="L56"> } catch (Exception ex) {</span> +<span class="nc" id="L57"> System.out.println("Empty album UUID, will create a new one");</span> +<span class="nc" id="L58"> }</span> +<span class="nc bnc" id="L59" title="All 4 branches missed."> if ((uuid == null) || (uuid.isEmpty()))</span> +<span class="nc" id="L60"> this.uuid = UUID.randomUUID();</span> +<span class="nc" id="L61"> else this.uuid = UUID.fromString(uuid);</span> + +<span class="nc" id="L63"> SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");</span> +<span class="nc" id="L64"> this.date = sdf.parse(xmlElement.getElementsByTagName("date").item(0).getTextContent());</span> + //parse list of songs: +<span class="nc" id="L66"> Node songsElement = xmlElement.getElementsByTagName("songs").item(0);</span> +<span class="nc" id="L67"> NodeList songUUIDNodes = songsElement.getChildNodes();</span> +<span class="nc bnc" id="L68" title="All 2 branches missed."> if (songUUIDNodes == null) return;</span> + +<span class="nc" id="L70"> this.songsUIDs = new ArrayList<>();</span> + +<span class="nc bnc" id="L72" title="All 2 branches missed."> for (int i = 0; i < songUUIDNodes.getLength(); i++) {</span> +<span class="nc bnc" id="L73" title="All 2 branches missed."> if (songUUIDNodes.item(i).getNodeType() == Node.ELEMENT_NODE) {</span> +<span class="nc" id="L74"> Element songElement = (Element) songUUIDNodes.item(i);</span> +<span class="nc bnc" id="L75" title="All 2 branches missed."> if (songElement.getNodeName().equals("UUID")) {</span> + try { +<span class="nc" id="L77"> this.addSong(UUID.fromString(songElement.getTextContent()));</span> +<span class="nc" id="L78"> } catch (Exception ex) {</span> +<span class="nc" id="L79"> ex.printStackTrace();</span> +<span class="nc" id="L80"> }</span> + } + } + } + } +<span class="nc" id="L85"> }</span> + + + public void addSong(UUID song) { +<span class="nc" id="L89"> songsUIDs.add(song);</span> +<span class="nc" id="L90"> }</span> + + + public List<UUID> getSongs() { +<span class="nc" id="L94"> return songsUIDs;</span> + } + + public ArrayList<UUID> getSongsRandomly() { +<span class="nc" id="L98"> ArrayList<UUID> shuffledSongs = songsUIDs;</span> +<span class="nc" id="L99"> Collections.shuffle(shuffledSongs);</span> +<span class="nc" id="L100"> return shuffledSongs;</span> + } + + public String getTitle() { +<span class="nc" id="L104"> return title;</span> + } + + public Date getDate() { +<span class="nc" id="L108"> return date;</span> + } + + public void createXMLElement(Document document, Element parentElement) { +<span class="nc" id="L112"> Element albumElement = document.createElement("album");</span> +<span class="nc" id="L113"> parentElement.appendChild(albumElement);</span> + +<span class="nc" id="L115"> Element nameElement = document.createElement("title");</span> +<span class="nc" id="L116"> nameElement.appendChild(document.createTextNode(title));</span> +<span class="nc" id="L117"> albumElement.appendChild(nameElement);</span> + +<span class="nc" id="L119"> Element artistElement = document.createElement("artist");</span> +<span class="nc" id="L120"> artistElement.appendChild(document.createTextNode(artist));</span> +<span class="nc" id="L121"> albumElement.appendChild(artistElement);</span> + +<span class="nc" id="L123"> Element lengthElement = document.createElement("lengthInSeconds");</span> +<span class="nc" id="L124"> lengthElement.appendChild(document.createTextNode(Integer.valueOf(lengthInSeconds).toString()));</span> +<span class="nc" id="L125"> albumElement.appendChild(lengthElement);</span> + +<span class="nc" id="L127"> Element UUIDElement = document.createElement("UUID");</span> +<span class="nc" id="L128"> UUIDElement.appendChild(document.createTextNode(uuid.toString()));</span> +<span class="nc" id="L129"> albumElement.appendChild(UUIDElement);</span> + +<span class="nc" id="L131"> Element dateElement = document.createElement("date");</span> +<span class="nc" id="L132"> SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");</span> +<span class="nc" id="L133"> dateElement.appendChild(document.createTextNode(sdf.format(date)));</span> +<span class="nc" id="L134"> albumElement.appendChild(dateElement);</span> + +<span class="nc" id="L136"> Element songsElement = document.createElement("songs");</span> +<span class="nc bnc" id="L137" title="All 2 branches missed."> for (UUID currentUUID : this.songsUIDs) {</span> +<span class="nc" id="L138"> Element songUUIDElement = document.createElement("UUID");</span> +<span class="nc" id="L139"> songUUIDElement.appendChild(document.createTextNode(currentUUID.toString()));</span> +<span class="nc" id="L140"> songsElement.appendChild(songUUIDElement);</span> +<span class="nc" id="L141"> }</span> +<span class="nc" id="L142"> albumElement.appendChild(songsElement);</span> + +<span class="nc" id="L144"> }</span> +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/AudioBook.html b/target/site/jacoco/musichub.business/AudioBook.html new file mode 100644 index 0000000..aec1e56 --- /dev/null +++ b/target/site/jacoco/musichub.business/AudioBook.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>AudioBook</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">AudioBook</span></div><h1>AudioBook</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">164 of 164</td><td class="ctr2">0 %</td><td class="bar">10 of 10</td><td class="ctr2">0 %</td><td class="ctr1">17</td><td class="ctr2">17</td><td class="ctr1">39</td><td class="ctr2">39</td><td class="ctr1">9</td><td class="ctr2">9</td></tr></tfoot><tbody><tr><td id="a3"><a href="AudioBook.java.html#L64" class="el_method">createXMLElement(Document, Element)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="45" alt="45"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h0">10</td><td class="ctr2" id="i0">10</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a7"><a href="AudioBook.java.html#L33" class="el_method">setLanguage(String)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="77" height="10" title="29" alt="29"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="5" alt="5"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f0">5</td><td class="ctr2" id="g0">5</td><td class="ctr1" id="h1">7</td><td class="ctr2" id="i1">7</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a6"><a href="AudioBook.java.html#L47" class="el_method">setCategory(String)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="77" height="10" title="29" alt="29"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="5" alt="5"/></td><td class="ctr2" id="e1">0 %</td><td class="ctr1" id="f1">5</td><td class="ctr2" id="g1">5</td><td class="ctr1" id="h2">7</td><td class="ctr2" id="i2">7</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a0"><a href="AudioBook.java.html#L23" class="el_method">AudioBook(Element)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="53" height="10" title="20" alt="20"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d3"/><td class="ctr2" id="e3">n/a</td><td class="ctr1" id="f3">1</td><td class="ctr2" id="g3">1</td><td class="ctr1" id="h3">4</td><td class="ctr2" id="i3">4</td><td class="ctr1" id="j3">1</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a2"><a href="AudioBook.java.html#L11" class="el_method">AudioBook(String, String, int, String, String, String, String)</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="37" height="10" title="14" alt="14"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d4"/><td class="ctr2" id="e4">n/a</td><td class="ctr1" id="f4">1</td><td class="ctr2" id="g4">1</td><td class="ctr1" id="h4">4</td><td class="ctr2" id="i4">4</td><td class="ctr1" id="j4">1</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a1"><a href="AudioBook.java.html#L17" class="el_method">AudioBook(String, String, int, String, String, String)</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="34" height="10" title="13" alt="13"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d5"/><td class="ctr2" id="e5">n/a</td><td class="ctr1" id="f5">1</td><td class="ctr2" id="g5">1</td><td class="ctr1" id="h5">4</td><td class="ctr2" id="i5">4</td><td class="ctr1" id="j5">1</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a8"><a href="AudioBook.java.html#L58" class="el_method">toString()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="21" height="10" title="8" alt="8"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f6">1</td><td class="ctr2" id="g6">1</td><td class="ctr1" id="h6">1</td><td class="ctr2" id="i6">1</td><td class="ctr1" id="j6">1</td><td class="ctr2" id="k6">1</td></tr><tr><td id="a5"><a href="AudioBook.java.html#L29" class="el_method">getLanguage()</a></td><td class="bar" id="b7"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="3" alt="3"/></td><td class="ctr2" id="c7">0 %</td><td class="bar" id="d7"/><td class="ctr2" id="e7">n/a</td><td class="ctr1" id="f7">1</td><td class="ctr2" id="g7">1</td><td class="ctr1" id="h7">1</td><td class="ctr2" id="i7">1</td><td class="ctr1" id="j7">1</td><td class="ctr2" id="k7">1</td></tr><tr><td id="a4"><a href="AudioBook.java.html#L43" class="el_method">getCategory()</a></td><td class="bar" id="b8"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="3" alt="3"/></td><td class="ctr2" id="c8">0 %</td><td class="bar" id="d8"/><td class="ctr2" id="e8">n/a</td><td class="ctr1" id="f8">1</td><td class="ctr2" id="g8">1</td><td class="ctr1" id="h8">1</td><td class="ctr2" id="i8">1</td><td class="ctr1" id="j8">1</td><td class="ctr2" id="k8">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/AudioBook.java.html b/target/site/jacoco/musichub.business/AudioBook.java.html new file mode 100644 index 0000000..33a7924 --- /dev/null +++ b/target/site/jacoco/musichub.business/AudioBook.java.html @@ -0,0 +1,79 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>AudioBook.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">AudioBook.java</span></div><h1>AudioBook.java</h1><pre class="source lang-java linenums">package musichub.business; + +import org.w3c.dom.Document; +import org.w3c.dom.Element; + +public class AudioBook extends AudioElement { + private Language language; + private Category category; + + public AudioBook(String title, String artist, int lengthInSeconds, String uid, String content, String language, String category) { +<span class="nc" id="L11"> super(title, artist, lengthInSeconds, uid, content);</span> +<span class="nc" id="L12"> this.setLanguage(language);</span> +<span class="nc" id="L13"> this.setCategory(category);</span> +<span class="nc" id="L14"> }</span> + + public AudioBook(String title, String artist, int lengthInSeconds, String content, String language, String category) { +<span class="nc" id="L17"> super(title, artist, lengthInSeconds, content);</span> +<span class="nc" id="L18"> this.setLanguage(language);</span> +<span class="nc" id="L19"> this.setCategory(category);</span> +<span class="nc" id="L20"> }</span> + + public AudioBook(Element xmlElement) { +<span class="nc" id="L23"> super(xmlElement);</span> +<span class="nc" id="L24"> this.setLanguage(xmlElement.getElementsByTagName("language").item(0).getTextContent());</span> +<span class="nc" id="L25"> this.setCategory(xmlElement.getElementsByTagName("category").item(0).getTextContent());</span> +<span class="nc" id="L26"> }</span> + + public Language getLanguage() { +<span class="nc" id="L29"> return this.language;</span> + } + + public void setLanguage(String language) { +<span class="nc bnc" id="L33" title="All 5 branches missed."> switch (language.toLowerCase()) {</span> +<span class="nc" id="L34"> default -> this.language = Language.ENGLISH;</span> +<span class="nc" id="L35"> case "french" -> this.language = Language.FRENCH;</span> +<span class="nc" id="L36"> case "german" -> this.language = Language.GERMAN;</span> +<span class="nc" id="L37"> case "spanish" -> this.language = Language.SPANISH;</span> +<span class="nc" id="L38"> case "italian" -> this.language = Language.ITALIAN;</span> + } +<span class="nc" id="L40"> }</span> + + public Category getCategory() { +<span class="nc" id="L43"> return this.category;</span> + } + + public void setCategory(String category) { +<span class="nc bnc" id="L47" title="All 5 branches missed."> switch (category.toLowerCase()) {</span> +<span class="nc" id="L48"> default -> this.category = Category.YOUTH;</span> +<span class="nc" id="L49"> case "novel" -> this.category = Category.NOVEL;</span> +<span class="nc" id="L50"> case "theater" -> this.category = Category.THEATER;</span> +<span class="nc" id="L51"> case "documentary" -> this.category = Category.DOCUMENTARY;</span> +<span class="nc" id="L52"> case "speech" -> this.category = Category.SPEECH;</span> + } +<span class="nc" id="L54"> }</span> + + + public String toString() { +<span class="nc" id="L58"> return super.toString() + ", Language = " + getLanguage() + ", Category = " + getCategory() + "\n";</span> + } + + + public void createXMLElement(Document document, Element parentElement) { + // audiobook element +<span class="nc" id="L64"> Element audioBook = document.createElement("audiobook");</span> + +<span class="nc" id="L66"> super.createXMLElement(document, audioBook);</span> + +<span class="nc" id="L68"> Element languageElement = document.createElement("language");</span> +<span class="nc" id="L69"> languageElement.appendChild(document.createTextNode(language.getLanguage()));</span> +<span class="nc" id="L70"> audioBook.appendChild(languageElement);</span> + +<span class="nc" id="L72"> Element categoryElement = document.createElement("category");</span> +<span class="nc" id="L73"> categoryElement.appendChild(document.createTextNode(category.getCategory()));</span> +<span class="nc" id="L74"> audioBook.appendChild(categoryElement);</span> + +<span class="nc" id="L76"> parentElement.appendChild(audioBook);</span> +<span class="nc" id="L77"> }</span> +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/AudioElement.html b/target/site/jacoco/musichub.business/AudioElement.html new file mode 100644 index 0000000..7a6e499 --- /dev/null +++ b/target/site/jacoco/musichub.business/AudioElement.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>AudioElement</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">AudioElement</span></div><h1>AudioElement</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">266 of 266</td><td class="ctr2">0 %</td><td class="bar">11 of 11</td><td class="ctr2">0 %</td><td class="ctr1">16</td><td class="ctr2">16</td><td class="ctr1">72</td><td class="ctr2">72</td><td class="ctr1">9</td><td class="ctr2">9</td></tr></tfoot><tbody><tr><td id="a3"><a href="AudioElement.java.html#L75" class="el_method">createXMLElement(Document, Element)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="79" alt="79"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h1">16</td><td class="ctr2" id="i1">16</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a7"><a href="AudioElement.java.html#L99" class="el_method">manageAudioElement()</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="103" height="10" title="68" alt="68"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="7" alt="7"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f0">6</td><td class="ctr2" id="g0">6</td><td class="ctr1" id="h0">24</td><td class="ctr2" id="i0">24</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a0"><a href="AudioElement.java.html#L40" class="el_method">AudioElement(Element)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="95" height="10" title="63" alt="63"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="68" height="10" title="4" alt="4"/></td><td class="ctr2" id="e1">0 %</td><td class="ctr1" id="f1">3</td><td class="ctr2" id="g1">3</td><td class="ctr1" id="h2">14</td><td class="ctr2" id="i2">14</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a2"><a href="AudioElement.java.html#L24" class="el_method">AudioElement(String, String, int, String, String)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="28" height="10" title="19" alt="19"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d3"/><td class="ctr2" id="e3">n/a</td><td class="ctr1" id="f3">1</td><td class="ctr2" id="g3">1</td><td class="ctr1" id="h3">7</td><td class="ctr2" id="i3">7</td><td class="ctr1" id="j3">1</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a1"><a href="AudioElement.java.html#L32" class="el_method">AudioElement(String, String, int, String)</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="27" height="10" title="18" alt="18"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d4"/><td class="ctr2" id="e4">n/a</td><td class="ctr1" id="f4">1</td><td class="ctr2" id="g4">1</td><td class="ctr1" id="h4">7</td><td class="ctr2" id="i4">7</td><td class="ctr1" id="j4">1</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a8"><a href="AudioElement.java.html#L71" class="el_method">toString()</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="15" height="10" title="10" alt="10"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d5"/><td class="ctr2" id="e5">n/a</td><td class="ctr1" id="f5">1</td><td class="ctr2" id="g5">1</td><td class="ctr1" id="h5">1</td><td class="ctr2" id="i5">1</td><td class="ctr1" id="j5">1</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a6"><a href="AudioElement.java.html#L59" class="el_method">getUUID()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="4" height="10" title="3" alt="3"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f6">1</td><td class="ctr2" id="g6">1</td><td class="ctr1" id="h6">1</td><td class="ctr2" id="i6">1</td><td class="ctr1" id="j6">1</td><td class="ctr2" id="k6">1</td></tr><tr><td id="a4"><a href="AudioElement.java.html#L63" class="el_method">getArtist()</a></td><td class="bar" id="b7"><img src="../jacoco-resources/redbar.gif" width="4" height="10" title="3" alt="3"/></td><td class="ctr2" id="c7">0 %</td><td class="bar" id="d7"/><td class="ctr2" id="e7">n/a</td><td class="ctr1" id="f7">1</td><td class="ctr2" id="g7">1</td><td class="ctr1" id="h7">1</td><td class="ctr2" id="i7">1</td><td class="ctr1" id="j7">1</td><td class="ctr2" id="k7">1</td></tr><tr><td id="a5"><a href="AudioElement.java.html#L67" class="el_method">getTitle()</a></td><td class="bar" id="b8"><img src="../jacoco-resources/redbar.gif" width="4" height="10" title="3" alt="3"/></td><td class="ctr2" id="c8">0 %</td><td class="bar" id="d8"/><td class="ctr2" id="e8">n/a</td><td class="ctr1" id="f8">1</td><td class="ctr2" id="g8">1</td><td class="ctr1" id="h8">1</td><td class="ctr2" id="i8">1</td><td class="ctr1" id="j8">1</td><td class="ctr2" id="k8">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/AudioElement.java.html b/target/site/jacoco/musichub.business/AudioElement.java.html new file mode 100644 index 0000000..4401836 --- /dev/null +++ b/target/site/jacoco/musichub.business/AudioElement.java.html @@ -0,0 +1,133 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>AudioElement.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">AudioElement.java</span></div><h1>AudioElement.java</h1><pre class="source lang-java linenums">package musichub.business; + +import org.w3c.dom.Document; +import org.w3c.dom.Element; + +import java.io.File; +import java.io.IOException; +import java.util.Scanner; +import java.util.UUID; + +import javax.sound.sampled.AudioInputStream; +import javax.sound.sampled.AudioSystem; +import javax.sound.sampled.Clip; +import javax.sound.sampled.LineUnavailableException; +import javax.sound.sampled.UnsupportedAudioFileException; + +public abstract class AudioElement { + protected String title; + protected String artist; + protected int lengthInSeconds; + protected UUID uuid; + protected String content; + +<span class="nc" id="L24"> public AudioElement(String title, String artist, int lengthInSeconds, String id, String content) {</span> +<span class="nc" id="L25"> this.title = title;</span> +<span class="nc" id="L26"> this.artist = artist;</span> +<span class="nc" id="L27"> this.lengthInSeconds = lengthInSeconds;</span> +<span class="nc" id="L28"> this.uuid = UUID.fromString(id);</span> +<span class="nc" id="L29"> this.content = content;</span> +<span class="nc" id="L30"> }</span> + +<span class="nc" id="L32"> public AudioElement(String title, String artist, int lengthInSeconds, String content) {</span> +<span class="nc" id="L33"> this.title = title;</span> +<span class="nc" id="L34"> this.artist = artist;</span> +<span class="nc" id="L35"> this.lengthInSeconds = lengthInSeconds;</span> +<span class="nc" id="L36"> this.content = content;</span> +<span class="nc" id="L37"> this.uuid = UUID.randomUUID();</span> +<span class="nc" id="L38"> }</span> + +<span class="nc" id="L40"> public AudioElement(Element xmlElement) {</span> + { +<span class="nc" id="L42"> title = xmlElement.getElementsByTagName("title").item(0).getTextContent();</span> +<span class="nc" id="L43"> artist = xmlElement.getElementsByTagName("artist").item(0).getTextContent();</span> +<span class="nc" id="L44"> lengthInSeconds = Integer.parseInt(xmlElement.getElementsByTagName("length").item(0).getTextContent());</span> +<span class="nc" id="L45"> content = xmlElement.getElementsByTagName("content").item(0).getTextContent();</span> +<span class="nc" id="L46"> String uuid = null;</span> + try { +<span class="nc" id="L48"> uuid = xmlElement.getElementsByTagName("UUID").item(0).getTextContent();</span> +<span class="nc" id="L49"> } catch (Exception ex) {</span> +<span class="nc" id="L50"> System.out.println("Empty element UUID, will create a new one");</span> +<span class="nc" id="L51"> }</span> +<span class="nc bnc" id="L52" title="All 4 branches missed."> if ((uuid == null) || (uuid.isEmpty()))</span> +<span class="nc" id="L53"> this.uuid = UUID.randomUUID();</span> +<span class="nc" id="L54"> else this.uuid = UUID.fromString(uuid);</span> + } +<span class="nc" id="L56"> }</span> + + public UUID getUUID() { +<span class="nc" id="L59"> return this.uuid;</span> + } + + public String getArtist() { +<span class="nc" id="L63"> return this.artist;</span> + } + + public String getTitle() { +<span class="nc" id="L67"> return this.title;</span> + } + + public String toString() { +<span class="nc" id="L71"> return "Title = " + this.title + ", Artist = " + this.artist + ", Length = " + this.lengthInSeconds + ", Content = " + this.content;</span> + } + + public void createXMLElement(Document document, Element parentElement) { +<span class="nc" id="L75"> Element nameElement = document.createElement("title");</span> +<span class="nc" id="L76"> nameElement.appendChild(document.createTextNode(title));</span> +<span class="nc" id="L77"> parentElement.appendChild(nameElement);</span> + +<span class="nc" id="L79"> Element artistElement = document.createElement("artist");</span> +<span class="nc" id="L80"> artistElement.appendChild(document.createTextNode(artist));</span> +<span class="nc" id="L81"> parentElement.appendChild(artistElement);</span> + +<span class="nc" id="L83"> Element lengthElement = document.createElement("length");</span> +<span class="nc" id="L84"> lengthElement.appendChild(document.createTextNode(Integer.valueOf(lengthInSeconds).toString()));</span> +<span class="nc" id="L85"> parentElement.appendChild(lengthElement);</span> + +<span class="nc" id="L87"> Element UUIDElement = document.createElement("UUID");</span> +<span class="nc" id="L88"> UUIDElement.appendChild(document.createTextNode(uuid.toString()));</span> +<span class="nc" id="L89"> parentElement.appendChild(UUIDElement);</span> + +<span class="nc" id="L91"> Element contentElement = document.createElement("content");</span> +<span class="nc" id="L92"> contentElement.appendChild(document.createTextNode(content));</span> +<span class="nc" id="L93"> parentElement.appendChild(contentElement);</span> + +<span class="nc" id="L95"> }</span> + + public void manageAudioElement() throws UnsupportedAudioFileException, IOException, LineUnavailableException { + +<span class="nc" id="L99"> Scanner scanner = new Scanner(System.in); </span> + +<span class="nc" id="L101"> File file = new File(this.content);</span> +<span class="nc" id="L102"> AudioInputStream audioStream = AudioSystem.getAudioInputStream(file);</span> +<span class="nc" id="L103"> Clip clip = AudioSystem.getClip();</span> +<span class="nc" id="L104"> clip.open(audioStream);</span> + +<span class="nc" id="L106"> String action = "";</span> + +<span class="nc bnc" id="L108" title="All 2 branches missed."> while(!action.equals("Q")) {</span> +<span class="nc" id="L109"> System.out.println("P = Play \b S = Stop \b R = Reset \b Q = Quit");</span> +<span class="nc" id="L110"> System.out.println("Enter your choice");</span> +<span class="nc" id="L111"> action = scanner.next();</span> +<span class="nc" id="L112"> action = action.toUpperCase();</span> + +<span class="nc bnc" id="L114" title="All 5 branches missed."> switch(action) {</span> +<span class="nc" id="L115"> case "S" : clip.stop();</span> +<span class="nc" id="L116"> break;</span> +<span class="nc" id="L117"> case "P" : clip.start();</span> +<span class="nc" id="L118"> break;</span> +<span class="nc" id="L119"> case "R" : clip.setMicrosecondPosition(0);</span> +<span class="nc" id="L120"> break;</span> +<span class="nc" id="L121"> case "Q" : clip.stop();</span> +<span class="nc" id="L122"> break;</span> +<span class="nc" id="L123"> default : System.out.println("try again");</span> + } +<span class="nc" id="L125"> System.out.println("You stoped the Audio element");</span> + } + +<span class="nc" id="L128"> clip.close();</span> + +<span class="nc" id="L130"> }</span> + +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Category.html b/target/site/jacoco/musichub.business/Category.html new file mode 100644 index 0000000..d7e4df0 --- /dev/null +++ b/target/site/jacoco/musichub.business/Category.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Category</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">Category</span></div><h1>Category</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">49 of 49</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">3</td><td class="ctr2">3</td><td class="ctr1">6</td><td class="ctr2">6</td><td class="ctr1">3</td><td class="ctr2">3</td></tr></tfoot><tbody><tr><td id="a2"><a href="Category.java.html#L3" class="el_method">static {...}</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="38" alt="38"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h1">2</td><td class="ctr2" id="i1">2</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a0"><a href="Category.java.html#L7" class="el_method">Category(String, int, String)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="25" height="10" title="8" alt="8"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">1</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h0">3</td><td class="ctr2" id="i0">3</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a1"><a href="Category.java.html#L12" class="el_method">getCategory()</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="9" height="10" title="3" alt="3"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h2">1</td><td class="ctr2" id="i2">1</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Category.java.html b/target/site/jacoco/musichub.business/Category.java.html new file mode 100644 index 0000000..cdef51f --- /dev/null +++ b/target/site/jacoco/musichub.business/Category.java.html @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Category.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">Category.java</span></div><h1>Category.java</h1><pre class="source lang-java linenums">package musichub.business; + +<span class="nc" id="L3">public enum Category {</span> +<span class="nc" id="L4"> YOUTH("youth"), NOVEL("novel"), THEATER("theater"), DOCUMENTARY("documentary"), SPEECH("speech");</span> + private final String category; + +<span class="nc" id="L7"> Category(String category) {</span> +<span class="nc" id="L8"> this.category = category;</span> +<span class="nc" id="L9"> }</span> + + public String getCategory() { +<span class="nc" id="L12"> return category;</span> + } +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Genre.html b/target/site/jacoco/musichub.business/Genre.html new file mode 100644 index 0000000..88e0ecd --- /dev/null +++ b/target/site/jacoco/musichub.business/Genre.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Genre</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">Genre</span></div><h1>Genre</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">56 of 56</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">3</td><td class="ctr2">3</td><td class="ctr1">6</td><td class="ctr2">6</td><td class="ctr1">3</td><td class="ctr2">3</td></tr></tfoot><tbody><tr><td id="a2"><a href="Genre.java.html#L3" class="el_method">static {...}</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="45" alt="45"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h1">2</td><td class="ctr2" id="i1">2</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a0"><a href="Genre.java.html#L7" class="el_method">Genre(String, int, String)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="21" height="10" title="8" alt="8"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">1</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h0">3</td><td class="ctr2" id="i0">3</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a1"><a href="Genre.java.html#L12" class="el_method">getGenre()</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="3" alt="3"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h2">1</td><td class="ctr2" id="i2">1</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Genre.java.html b/target/site/jacoco/musichub.business/Genre.java.html new file mode 100644 index 0000000..021bb4b --- /dev/null +++ b/target/site/jacoco/musichub.business/Genre.java.html @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Genre.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">Genre.java</span></div><h1>Genre.java</h1><pre class="source lang-java linenums">package musichub.business; + +<span class="nc" id="L3">public enum Genre {</span> +<span class="nc" id="L4"> JAZZ("jazz"), CLASSIC("classic"), HIPHOP("hiphop"), ROCK("rock"), POP("pop"), RAP("rap");</span> + private final String genre; + +<span class="nc" id="L7"> Genre(String genre) {</span> +<span class="nc" id="L8"> this.genre = genre;</span> +<span class="nc" id="L9"> }</span> + + public String getGenre() { +<span class="nc" id="L12"> return genre;</span> + } +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Language.html b/target/site/jacoco/musichub.business/Language.html new file mode 100644 index 0000000..604af85 --- /dev/null +++ b/target/site/jacoco/musichub.business/Language.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Language</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">Language</span></div><h1>Language</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">49 of 49</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">3</td><td class="ctr2">3</td><td class="ctr1">6</td><td class="ctr2">6</td><td class="ctr1">3</td><td class="ctr2">3</td></tr></tfoot><tbody><tr><td id="a2"><a href="Language.java.html#L3" class="el_method">static {...}</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="38" alt="38"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h1">2</td><td class="ctr2" id="i1">2</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a1"><a href="Language.java.html#L7" class="el_method">Language(String, int, String)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="25" height="10" title="8" alt="8"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">1</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h0">3</td><td class="ctr2" id="i0">3</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a0"><a href="Language.java.html#L12" class="el_method">getLanguage()</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="9" height="10" title="3" alt="3"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h2">1</td><td class="ctr2" id="i2">1</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Language.java.html b/target/site/jacoco/musichub.business/Language.java.html new file mode 100644 index 0000000..f974811 --- /dev/null +++ b/target/site/jacoco/musichub.business/Language.java.html @@ -0,0 +1,15 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Language.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">Language.java</span></div><h1>Language.java</h1><pre class="source lang-java linenums">package musichub.business; + +<span class="nc" id="L3">public enum Language {</span> +<span class="nc" id="L4"> FRENCH("french"), ENGLISH("english"), ITALIAN("italian"), SPANISH("spanish"), GERMAN("german");</span> + private final String language; + +<span class="nc" id="L7"> Language(String language) {</span> +<span class="nc" id="L8"> this.language = language;</span> +<span class="nc" id="L9"> }</span> + + public String getLanguage() { +<span class="nc" id="L12"> return language;</span> + } +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/MusicHub.html b/target/site/jacoco/musichub.business/MusicHub.html new file mode 100644 index 0000000..6bedc98 --- /dev/null +++ b/target/site/jacoco/musichub.business/MusicHub.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>MusicHub</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">MusicHub</span></div><h1>MusicHub</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">803 of 803</td><td class="ctr2">0 %</td><td class="bar">114 of 114</td><td class="ctr2">0 %</td><td class="ctr1">79</td><td class="ctr2">79</td><td class="ctr1">195</td><td class="ctr2">195</td><td class="ctr1">22</td><td class="ctr2">22</td></tr></tfoot><tbody><tr><td id="a2"><a href="MusicHub.java.html#L158" class="el_method">addElementToAlbum(String, String)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="82" alt="82"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d2"><img src="../jacoco-resources/redbar.gif" width="102" height="10" title="12" alt="12"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f2">7</td><td class="ctr2" id="g2">7</td><td class="ctr1" id="h0">20</td><td class="ctr2" id="i0">20</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a3"><a href="MusicHub.java.html#L187" class="el_method">addElementToPlayList(String, String)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="82" alt="82"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d3"><img src="../jacoco-resources/redbar.gif" width="102" height="10" title="12" alt="12"/></td><td class="ctr2" id="e1">0 %</td><td class="ctr1" id="f3">7</td><td class="ctr2" id="g3">7</td><td class="ctr1" id="h1">20</td><td class="ctr2" id="i1">20</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a9"><a href="MusicHub.java.html#L135" class="el_method">getAlbumSongsSortedByGenre(String)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="115" height="10" title="79" alt="79"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="14" alt="14"/></td><td class="ctr2" id="e2">0 %</td><td class="ctr1" id="f0">8</td><td class="ctr2" id="g0">8</td><td class="ctr1" id="h3">16</td><td class="ctr2" id="i3">16</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a8"><a href="MusicHub.java.html#L113" class="el_method">getAlbumSongs(String)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="106" height="10" title="73" alt="73"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="14" alt="14"/></td><td class="ctr2" id="e3">0 %</td><td class="ctr1" id="f1">8</td><td class="ctr2" id="g1">8</td><td class="ctr1" id="h4">15</td><td class="ctr2" id="i4">15</td><td class="ctr1" id="j3">1</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a14"><a href="MusicHub.java.html#L254" class="el_method">loadElements()</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="93" height="10" title="64" alt="64"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d4"><img src="../jacoco-resources/redbar.gif" width="85" height="10" title="10" alt="10"/></td><td class="ctr2" id="e4">0 %</td><td class="ctr1" id="f4">6</td><td class="ctr2" id="g4">6</td><td class="ctr1" id="h2">18</td><td class="ctr2" id="i2">18</td><td class="ctr1" id="j4">1</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a11"><a href="MusicHub.java.html#L101" class="el_method">getAudiobooksTitlesSortedByAuthor()</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="77" height="10" title="53" alt="53"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d9"><img src="../jacoco-resources/redbar.gif" width="51" height="10" title="6" alt="6"/></td><td class="ctr2" id="e5">0 %</td><td class="ctr1" id="f9">4</td><td class="ctr2" id="g9">4</td><td class="ctr1" id="h11">9</td><td class="ctr2" id="i11">9</td><td class="ctr1" id="j5">1</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a19"><a href="MusicHub.java.html#L314" class="el_method">saveElements()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="68" height="10" title="47" alt="47"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d5"><img src="../jacoco-resources/redbar.gif" width="68" height="10" title="8" alt="8"/></td><td class="ctr2" id="e6">0 %</td><td class="ctr1" id="f5">5</td><td class="ctr2" id="g5">5</td><td class="ctr1" id="h5">12</td><td class="ctr2" id="i5">12</td><td class="ctr1" id="j6">1</td><td class="ctr2" id="k6">1</td></tr><tr><td id="a13"><a href="MusicHub.java.html#L218" class="el_method">loadAlbums()</a></td><td class="bar" id="b7"><img src="../jacoco-resources/redbar.gif" width="64" height="10" title="44" alt="44"/></td><td class="ctr2" id="c7">0 %</td><td class="bar" id="d6"><img src="../jacoco-resources/redbar.gif" width="68" height="10" title="8" alt="8"/></td><td class="ctr2" id="e7">0 %</td><td class="ctr1" id="f6">5</td><td class="ctr2" id="g6">5</td><td class="ctr1" id="h6">11</td><td class="ctr2" id="i6">11</td><td class="ctr1" id="j7">1</td><td class="ctr2" id="k7">1</td></tr><tr><td id="a15"><a href="MusicHub.java.html#L236" class="el_method">loadPlaylists()</a></td><td class="bar" id="b8"><img src="../jacoco-resources/redbar.gif" width="64" height="10" title="44" alt="44"/></td><td class="ctr2" id="c8">0 %</td><td class="bar" id="d7"><img src="../jacoco-resources/redbar.gif" width="68" height="10" title="8" alt="8"/></td><td class="ctr2" id="e8">0 %</td><td class="ctr1" id="f7">5</td><td class="ctr2" id="g7">5</td><td class="ctr1" id="h7">11</td><td class="ctr2" id="i7">11</td><td class="ctr1" id="j8">1</td><td class="ctr2" id="k8">1</td></tr><tr><td id="a6"><a href="MusicHub.java.html#L66" class="el_method">deletePlayList(String)</a></td><td class="bar" id="b9"><img src="../jacoco-resources/redbar.gif" width="58" height="10" title="40" alt="40"/></td><td class="ctr2" id="c9">0 %</td><td class="bar" id="d8"><img src="../jacoco-resources/redbar.gif" width="68" height="10" title="8" alt="8"/></td><td class="ctr2" id="e9">0 %</td><td class="ctr1" id="f8">5</td><td class="ctr2" id="g8">5</td><td class="ctr1" id="h8">11</td><td class="ctr2" id="i8">11</td><td class="ctr1" id="j9">1</td><td class="ctr2" id="k9">1</td></tr><tr><td id="a18"><a href="MusicHub.java.html#L282" class="el_method">saveAlbums()</a></td><td class="bar" id="b10"><img src="../jacoco-resources/redbar.gif" width="52" height="10" title="36" alt="36"/></td><td class="ctr2" id="c10">0 %</td><td class="bar" id="d10"><img src="../jacoco-resources/redbar.gif" width="34" height="10" title="4" alt="4"/></td><td class="ctr2" id="e10">0 %</td><td class="ctr1" id="f10">3</td><td class="ctr2" id="g10">3</td><td class="ctr1" id="h9">10</td><td class="ctr2" id="i9">10</td><td class="ctr1" id="j10">1</td><td class="ctr2" id="k10">1</td></tr><tr><td id="a20"><a href="MusicHub.java.html#L298" class="el_method">savePlayLists()</a></td><td class="bar" id="b11"><img src="../jacoco-resources/redbar.gif" width="52" height="10" title="36" alt="36"/></td><td class="ctr2" id="c11">0 %</td><td class="bar" id="d11"><img src="../jacoco-resources/redbar.gif" width="34" height="10" title="4" alt="4"/></td><td class="ctr2" id="e11">0 %</td><td class="ctr1" id="f11">3</td><td class="ctr2" id="g11">3</td><td class="ctr1" id="h10">10</td><td class="ctr2" id="i10">10</td><td class="ctr1" id="j11">1</td><td class="ctr2" id="k11">1</td></tr><tr><td id="a10"><a href="MusicHub.java.html#L93" class="el_method">getAlbumsTitlesSortedByDate()</a></td><td class="bar" id="b12"><img src="../jacoco-resources/redbar.gif" width="46" height="10" title="32" alt="32"/></td><td class="ctr2" id="c12">0 %</td><td class="bar" id="d13"><img src="../jacoco-resources/redbar.gif" width="17" height="10" title="2" alt="2"/></td><td class="ctr2" id="e12">0 %</td><td class="ctr1" id="f13">2</td><td class="ctr2" id="g13">2</td><td class="ctr1" id="h13">5</td><td class="ctr2" id="i13">5</td><td class="ctr1" id="j12">1</td><td class="ctr2" id="k12">1</td></tr><tr><td id="a16"><a href="MusicHub.java.html#L41" class="el_method">MusicHub()</a></td><td class="bar" id="b13"><img src="../jacoco-resources/redbar.gif" width="42" height="10" title="29" alt="29"/></td><td class="ctr2" id="c13">0 %</td><td class="bar" id="d14"/><td class="ctr2" id="e14">n/a</td><td class="ctr1" id="f14">1</td><td class="ctr2" id="g14">1</td><td class="ctr1" id="h12">9</td><td class="ctr2" id="i12">9</td><td class="ctr1" id="j13">1</td><td class="ctr2" id="k13">1</td></tr><tr><td id="a12"><a href="MusicHub.java.html#L335" class="el_method">getAudioElement(List, String)</a></td><td class="bar" id="b14"><img src="../jacoco-resources/redbar.gif" width="27" height="10" title="19" alt="19"/></td><td class="ctr2" id="c14">0 %</td><td class="bar" id="d12"><img src="../jacoco-resources/redbar.gif" width="34" height="10" title="4" alt="4"/></td><td class="ctr2" id="e13">0 %</td><td class="ctr1" id="f12">3</td><td class="ctr2" id="g12">3</td><td class="ctr1" id="h14">5</td><td class="ctr2" id="i14">5</td><td class="ctr1" id="j14">1</td><td class="ctr2" id="k14">1</td></tr><tr><td id="a21"><a href="MusicHub.java.html#L34" class="el_method">static {...}</a></td><td class="bar" id="b15"><img src="../jacoco-resources/redbar.gif" width="19" height="10" title="13" alt="13"/></td><td class="ctr2" id="c15">0 %</td><td class="bar" id="d15"/><td class="ctr2" id="e15">n/a</td><td class="ctr1" id="f15">1</td><td class="ctr2" id="g15">1</td><td class="ctr1" id="h15">4</td><td class="ctr2" id="i15">4</td><td class="ctr1" id="j15">1</td><td class="ctr2" id="k15">1</td></tr><tr><td id="a1"><a href="MusicHub.java.html#L53" class="el_method">addElement(AudioElement)</a></td><td class="bar" id="b16"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="6" alt="6"/></td><td class="ctr2" id="c16">0 %</td><td class="bar" id="d16"/><td class="ctr2" id="e16">n/a</td><td class="ctr1" id="f16">1</td><td class="ctr2" id="g16">1</td><td class="ctr1" id="h16">2</td><td class="ctr2" id="i16">2</td><td class="ctr1" id="j16">1</td><td class="ctr2" id="k16">1</td></tr><tr><td id="a0"><a href="MusicHub.java.html#L57" class="el_method">addAlbum(Album)</a></td><td class="bar" id="b17"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="6" alt="6"/></td><td class="ctr2" id="c17">0 %</td><td class="bar" id="d17"/><td class="ctr2" id="e17">n/a</td><td class="ctr1" id="f17">1</td><td class="ctr2" id="g17">1</td><td class="ctr1" id="h17">2</td><td class="ctr2" id="i17">2</td><td class="ctr1" id="j17">1</td><td class="ctr2" id="k17">1</td></tr><tr><td id="a4"><a href="MusicHub.java.html#L61" class="el_method">addPlaylist(PlayList)</a></td><td class="bar" id="b18"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="6" alt="6"/></td><td class="ctr2" id="c18">0 %</td><td class="bar" id="d18"/><td class="ctr2" id="e18">n/a</td><td class="ctr1" id="f18">1</td><td class="ctr2" id="g18">1</td><td class="ctr1" id="h18">2</td><td class="ctr2" id="i18">2</td><td class="ctr1" id="j18">1</td><td class="ctr2" id="k18">1</td></tr><tr><td id="a5"><a href="MusicHub.java.html#L81" class="el_method">albums()</a></td><td class="bar" id="b19"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="4" alt="4"/></td><td class="ctr2" id="c19">0 %</td><td class="bar" id="d19"/><td class="ctr2" id="e19">n/a</td><td class="ctr1" id="f19">1</td><td class="ctr2" id="g19">1</td><td class="ctr1" id="h19">1</td><td class="ctr2" id="i19">1</td><td class="ctr1" id="j19">1</td><td class="ctr2" id="k19">1</td></tr><tr><td id="a17"><a href="MusicHub.java.html#L85" class="el_method">playlists()</a></td><td class="bar" id="b20"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="4" alt="4"/></td><td class="ctr2" id="c20">0 %</td><td class="bar" id="d20"/><td class="ctr2" id="e20">n/a</td><td class="ctr1" id="f20">1</td><td class="ctr2" id="g20">1</td><td class="ctr1" id="h20">1</td><td class="ctr2" id="i20">1</td><td class="ctr1" id="j20">1</td><td class="ctr2" id="k20">1</td></tr><tr><td id="a7"><a href="MusicHub.java.html#L89" class="el_method">elements()</a></td><td class="bar" id="b21"><img src="../jacoco-resources/redbar.gif" width="5" height="10" title="4" alt="4"/></td><td class="ctr2" id="c21">0 %</td><td class="bar" id="d21"/><td class="ctr2" id="e21">n/a</td><td class="ctr1" id="f21">1</td><td class="ctr2" id="g21">1</td><td class="ctr1" id="h21">1</td><td class="ctr2" id="i21">1</td><td class="ctr1" id="j21">1</td><td class="ctr2" id="k21">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/MusicHub.java.html b/target/site/jacoco/musichub.business/MusicHub.java.html new file mode 100644 index 0000000..b9dfd09 --- /dev/null +++ b/target/site/jacoco/musichub.business/MusicHub.java.html @@ -0,0 +1,343 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>MusicHub.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">MusicHub.java</span></div><h1>MusicHub.java</h1><pre class="source lang-java linenums">package musichub.business; + +import musichub.util.XMLHandler; +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; + +import java.io.IOException; +import java.util.*; + +import javax.sound.sampled.LineUnavailableException; +import javax.sound.sampled.UnsupportedAudioFileException; + +<span class="nc" id="L15">class SortByDate implements Comparator<Album> {</span> + public int compare(Album a1, Album a2) { +<span class="nc" id="L17"> return a1.getDate().compareTo(a2.getDate());</span> + } +} + +<span class="nc" id="L21">class SortByGenre implements Comparator<Song> {</span> + public int compare(Song s1, Song s2) { +<span class="nc" id="L23"> return s1.getGenre().compareTo(s2.getGenre());</span> + } +} + +<span class="nc" id="L27">class SortByAuthor implements Comparator<AudioElement> {</span> + public int compare(AudioElement e1, AudioElement e2) { +<span class="nc" id="L29"> return e1.getArtist().compareTo(e2.getArtist());</span> + } +} + +public class MusicHub { +<span class="nc" id="L34"> public static final String DIR = System.getProperty("user.dir");</span> +<span class="nc" id="L35"> public static final String ALBUMS_FILE_PATH = DIR + "/files/albums.xml";</span> +<span class="nc" id="L36"> public static final String PLAYLISTS_FILE_PATH = DIR + "/files/playlists.xml";</span> +<span class="nc" id="L37"> public static final String ELEMENTS_FILE_PATH = DIR + "/files/elements.xml";</span> + private final List<Album> albums; + private final List<PlayList> playlists; + private final List<AudioElement> elements; +<span class="nc" id="L41"> private final XMLHandler xmlHandler = new XMLHandler();</span> + +<span class="nc" id="L43"> public MusicHub() {</span> +<span class="nc" id="L44"> albums = new LinkedList<>();</span> +<span class="nc" id="L45"> playlists = new LinkedList<>();</span> +<span class="nc" id="L46"> elements = new LinkedList<>();</span> +<span class="nc" id="L47"> this.loadElements();</span> +<span class="nc" id="L48"> this.loadAlbums();</span> +<span class="nc" id="L49"> this.loadPlaylists();</span> +<span class="nc" id="L50"> }</span> + + public void addElement(AudioElement element) { +<span class="nc" id="L53"> elements.add(element);</span> +<span class="nc" id="L54"> }</span> + + public void addAlbum(Album album) { +<span class="nc" id="L57"> albums.add(album);</span> +<span class="nc" id="L58"> }</span> + + public void addPlaylist(PlayList playlist) { +<span class="nc" id="L61"> playlists.add(playlist);</span> +<span class="nc" id="L62"> }</span> + + public void deletePlayList(String playListTitle) throws NoPlayListFoundException { + +<span class="nc" id="L66"> PlayList thePlayList = null;</span> +<span class="nc" id="L67"> boolean result = false;</span> +<span class="nc bnc" id="L68" title="All 2 branches missed."> for (PlayList pl : playlists) {</span> +<span class="nc bnc" id="L69" title="All 2 branches missed."> if (pl.getTitle().equalsIgnoreCase(playListTitle)) {</span> +<span class="nc" id="L70"> thePlayList = pl;</span> +<span class="nc" id="L71"> break;</span> + } +<span class="nc" id="L73"> }</span> + +<span class="nc bnc" id="L75" title="All 2 branches missed."> if (thePlayList != null)</span> +<span class="nc" id="L76"> result = playlists.remove(thePlayList);</span> +<span class="nc bnc" id="L77" title="All 2 branches missed."> if (!result) throw new NoPlayListFoundException("Playlist " + playListTitle + " not found!");</span> +<span class="nc" id="L78"> }</span> + + public Iterator<Album> albums() { +<span class="nc" id="L81"> return albums.listIterator();</span> + } + + public Iterator<PlayList> playlists() { +<span class="nc" id="L85"> return playlists.listIterator();</span> + } + + public Iterator<AudioElement> elements() { +<span class="nc" id="L89"> return elements.listIterator();</span> + } + + public String getAlbumsTitlesSortedByDate() { +<span class="nc" id="L93"> StringBuilder titleList = new StringBuilder();</span> +<span class="nc" id="L94"> albums.sort(new SortByDate());</span> +<span class="nc bnc" id="L95" title="All 2 branches missed."> for (Album al : albums)</span> +<span class="nc" id="L96"> titleList.append(al.getTitle()).append("\n");</span> +<span class="nc" id="L97"> return titleList.toString();</span> + } + + public String getAudiobooksTitlesSortedByAuthor() { +<span class="nc" id="L101"> StringBuilder titleList = new StringBuilder();</span> +<span class="nc" id="L102"> List<AudioElement> audioBookList = new ArrayList<>();</span> +<span class="nc bnc" id="L103" title="All 2 branches missed."> for (AudioElement ae : elements)</span> +<span class="nc bnc" id="L104" title="All 2 branches missed."> if (ae instanceof AudioBook)</span> +<span class="nc" id="L105"> audioBookList.add(ae);</span> +<span class="nc" id="L106"> audioBookList.sort(new SortByAuthor());</span> +<span class="nc bnc" id="L107" title="All 2 branches missed."> for (AudioElement ab : audioBookList)</span> +<span class="nc" id="L108"> titleList.append(ab.getArtist()).append("\n");</span> +<span class="nc" id="L109"> return titleList.toString();</span> + } + + public List<AudioElement> getAlbumSongs(String albumTitle) throws NoAlbumFoundException { +<span class="nc" id="L113"> Album theAlbum = null;</span> +<span class="nc" id="L114"> ArrayList<AudioElement> songsInAlbum = new ArrayList<>();</span> +<span class="nc bnc" id="L115" title="All 2 branches missed."> for (Album al : albums) {</span> +<span class="nc bnc" id="L116" title="All 2 branches missed."> if (al.getTitle().equalsIgnoreCase(albumTitle)) {</span> +<span class="nc" id="L117"> theAlbum = al;</span> +<span class="nc" id="L118"> break;</span> + } +<span class="nc" id="L120"> }</span> +<span class="nc bnc" id="L121" title="All 2 branches missed."> if (theAlbum == null) throw new NoAlbumFoundException("No album with this title in the MusicHub!");</span> + +<span class="nc" id="L123"> List<UUID> songIDs = theAlbum.getSongs();</span> +<span class="nc bnc" id="L124" title="All 2 branches missed."> for (UUID id : songIDs)</span> +<span class="nc bnc" id="L125" title="All 2 branches missed."> for (AudioElement el : elements) {</span> +<span class="nc bnc" id="L126" title="All 2 branches missed."> if (el instanceof Song) {</span> +<span class="nc bnc" id="L127" title="All 2 branches missed."> if (el.getUUID().equals(id)) songsInAlbum.add(el);</span> + } +<span class="nc" id="L129"> }</span> +<span class="nc" id="L130"> return songsInAlbum;</span> + + } + + public List<Song> getAlbumSongsSortedByGenre(String albumTitle) throws NoAlbumFoundException { +<span class="nc" id="L135"> Album theAlbum = null;</span> +<span class="nc" id="L136"> ArrayList<Song> songsInAlbum = new ArrayList<>();</span> +<span class="nc bnc" id="L137" title="All 2 branches missed."> for (Album al : albums) {</span> +<span class="nc bnc" id="L138" title="All 2 branches missed."> if (al.getTitle().equalsIgnoreCase(albumTitle)) {</span> +<span class="nc" id="L139"> theAlbum = al;</span> +<span class="nc" id="L140"> break;</span> + } +<span class="nc" id="L142"> }</span> +<span class="nc bnc" id="L143" title="All 2 branches missed."> if (theAlbum == null) throw new NoAlbumFoundException("No album with this title in the MusicHub!");</span> + +<span class="nc" id="L145"> List<UUID> songIDs = theAlbum.getSongs();</span> +<span class="nc bnc" id="L146" title="All 2 branches missed."> for (UUID id : songIDs)</span> +<span class="nc bnc" id="L147" title="All 2 branches missed."> for (AudioElement el : elements) {</span> +<span class="nc bnc" id="L148" title="All 2 branches missed."> if (el instanceof Song) {</span> +<span class="nc bnc" id="L149" title="All 2 branches missed."> if (el.getUUID().equals(id)) songsInAlbum.add((Song) el);</span> + } +<span class="nc" id="L151"> }</span> +<span class="nc" id="L152"> songsInAlbum.sort(new SortByGenre());</span> +<span class="nc" id="L153"> return songsInAlbum;</span> + + } + + public void addElementToAlbum(String elementTitle, String albumTitle) throws NoAlbumFoundException, NoElementFoundException { +<span class="nc" id="L158"> Album theAlbum = null;</span> + int i; +<span class="nc" id="L160"> boolean found = false;</span> +<span class="nc bnc" id="L161" title="All 2 branches missed."> for (i = 0; i < albums.size(); i++) {</span> +<span class="nc bnc" id="L162" title="All 2 branches missed."> if (albums.get(i).getTitle().equalsIgnoreCase(albumTitle)) {</span> +<span class="nc" id="L163"> theAlbum = albums.get(i);</span> +<span class="nc" id="L164"> found = true;</span> +<span class="nc" id="L165"> break;</span> + } + } + +<span class="nc bnc" id="L169" title="All 2 branches missed."> if (found) {</span> +<span class="nc" id="L170"> AudioElement theElement = null;</span> +<span class="nc bnc" id="L171" title="All 2 branches missed."> for (AudioElement ae : elements) {</span> +<span class="nc bnc" id="L172" title="All 2 branches missed."> if (ae.getTitle().equalsIgnoreCase(elementTitle)) {</span> +<span class="nc" id="L173"> theElement = ae;</span> +<span class="nc" id="L174"> break;</span> + } +<span class="nc" id="L176"> }</span> +<span class="nc bnc" id="L177" title="All 2 branches missed."> if (theElement != null) {</span> +<span class="nc" id="L178"> theAlbum.addSong(theElement.getUUID());</span> + //replace the album in the list +<span class="nc" id="L180"> albums.set(i, theAlbum);</span> +<span class="nc" id="L181"> } else throw new NoElementFoundException("Element " + elementTitle + " not found!");</span> +<span class="nc" id="L182"> } else throw new NoAlbumFoundException("Album " + albumTitle + " not found!");</span> + +<span class="nc" id="L184"> }</span> + + public void addElementToPlayList(String elementTitle, String playListTitle) throws NoPlayListFoundException, NoElementFoundException { +<span class="nc" id="L187"> PlayList thePlaylist = null;</span> + int i; +<span class="nc" id="L189"> boolean found = false;</span> + +<span class="nc bnc" id="L191" title="All 2 branches missed."> for (i = 0; i < playlists.size(); i++) {</span> +<span class="nc bnc" id="L192" title="All 2 branches missed."> if (playlists.get(i).getTitle().equalsIgnoreCase(playListTitle)) {</span> +<span class="nc" id="L193"> thePlaylist = playlists.get(i);</span> +<span class="nc" id="L194"> found = true;</span> +<span class="nc" id="L195"> break;</span> + } + } + +<span class="nc bnc" id="L199" title="All 2 branches missed."> if (found) {</span> +<span class="nc" id="L200"> AudioElement theElement = null;</span> +<span class="nc bnc" id="L201" title="All 2 branches missed."> for (AudioElement ae : elements) {</span> +<span class="nc bnc" id="L202" title="All 2 branches missed."> if (ae.getTitle().equalsIgnoreCase(elementTitle)) {</span> +<span class="nc" id="L203"> theElement = ae;</span> +<span class="nc" id="L204"> break;</span> + } +<span class="nc" id="L206"> }</span> +<span class="nc bnc" id="L207" title="All 2 branches missed."> if (theElement != null) {</span> +<span class="nc" id="L208"> thePlaylist.addElement(theElement.getUUID());</span> + //replace the album in the list +<span class="nc" id="L210"> playlists.set(i, thePlaylist);</span> +<span class="nc" id="L211"> } else throw new NoElementFoundException("Element " + elementTitle + " not found!");</span> + +<span class="nc" id="L213"> } else throw new NoPlayListFoundException("Playlist " + playListTitle + " not found!");</span> + +<span class="nc" id="L215"> }</span> + + private void loadAlbums() { +<span class="nc" id="L218"> NodeList albumNodes = xmlHandler.parseXMLFile(ALBUMS_FILE_PATH);</span> +<span class="nc bnc" id="L219" title="All 2 branches missed."> if (albumNodes == null) return;</span> + +<span class="nc bnc" id="L221" title="All 2 branches missed."> for (int i = 0; i < albumNodes.getLength(); i++) {</span> +<span class="nc bnc" id="L222" title="All 2 branches missed."> if (albumNodes.item(i).getNodeType() == Node.ELEMENT_NODE) {</span> +<span class="nc" id="L223"> Element albumElement = (Element) albumNodes.item(i);</span> +<span class="nc bnc" id="L224" title="All 2 branches missed."> if (albumElement.getNodeName().equals("album")) {</span> + try { +<span class="nc" id="L226"> this.addAlbum(new Album(albumElement));</span> +<span class="nc" id="L227"> } catch (Exception ex) {</span> +<span class="nc" id="L228"> System.out.println("Something is wrong with the XML album element");</span> +<span class="nc" id="L229"> }</span> + } + } + } +<span class="nc" id="L233"> }</span> + + private void loadPlaylists() { +<span class="nc" id="L236"> NodeList playlistNodes = xmlHandler.parseXMLFile(PLAYLISTS_FILE_PATH);</span> +<span class="nc bnc" id="L237" title="All 2 branches missed."> if (playlistNodes == null) return;</span> + +<span class="nc bnc" id="L239" title="All 2 branches missed."> for (int i = 0; i < playlistNodes.getLength(); i++) {</span> +<span class="nc bnc" id="L240" title="All 2 branches missed."> if (playlistNodes.item(i).getNodeType() == Node.ELEMENT_NODE) {</span> +<span class="nc" id="L241"> Element playlistElement = (Element) playlistNodes.item(i);</span> +<span class="nc bnc" id="L242" title="All 2 branches missed."> if (playlistElement.getNodeName().equals("playlist")) {</span> + try { +<span class="nc" id="L244"> this.addPlaylist(new PlayList(playlistElement));</span> +<span class="nc" id="L245"> } catch (Exception ex) {</span> +<span class="nc" id="L246"> System.out.println("Something is wrong with the XML playlist element");</span> +<span class="nc" id="L247"> }</span> + } + } + } +<span class="nc" id="L251"> }</span> + + private void loadElements() { +<span class="nc" id="L254"> NodeList audioelementsNodes = xmlHandler.parseXMLFile(ELEMENTS_FILE_PATH);</span> +<span class="nc bnc" id="L255" title="All 2 branches missed."> if (audioelementsNodes == null) return;</span> + +<span class="nc bnc" id="L257" title="All 2 branches missed."> for (int i = 0; i < audioelementsNodes.getLength(); i++) {</span> +<span class="nc bnc" id="L258" title="All 2 branches missed."> if (audioelementsNodes.item(i).getNodeType() == Node.ELEMENT_NODE) {</span> +<span class="nc" id="L259"> Element audioElement = (Element) audioelementsNodes.item(i);</span> +<span class="nc bnc" id="L260" title="All 2 branches missed."> if (audioElement.getNodeName().equals("song")) {</span> + try { +<span class="nc" id="L262"> AudioElement newSong = new Song(audioElement);</span> +<span class="nc" id="L263"> this.addElement(newSong);</span> +<span class="nc" id="L264"> } catch (Exception ex) {</span> +<span class="nc" id="L265"> System.out.println("Something is wrong with the XML song element");</span> +<span class="nc" id="L266"> }</span> + } +<span class="nc bnc" id="L268" title="All 2 branches missed."> if (audioElement.getNodeName().equals("audiobook")) {</span> + try { +<span class="nc" id="L270"> AudioElement newAudioBook = new AudioBook(audioElement);</span> +<span class="nc" id="L271"> this.addElement(newAudioBook);</span> +<span class="nc" id="L272"> } catch (Exception ex) {</span> +<span class="nc" id="L273"> System.out.println("Something is wrong with the XML audiobook element");</span> +<span class="nc" id="L274"> }</span> + } + } + } +<span class="nc" id="L278"> }</span> + + + public void saveAlbums() { +<span class="nc" id="L282"> Document document = xmlHandler.createXMLDocument();</span> +<span class="nc bnc" id="L283" title="All 2 branches missed."> if (document == null) return;</span> + + // root element +<span class="nc" id="L286"> Element root = document.createElement("albums");</span> +<span class="nc" id="L287"> document.appendChild(root);</span> + + //save all albums +<span class="nc bnc" id="L290" title="All 2 branches missed."> for (Iterator<Album> albumsIter = this.albums(); albumsIter.hasNext(); ) {</span> +<span class="nc" id="L291"> Album currentAlbum = albumsIter.next();</span> +<span class="nc" id="L292"> currentAlbum.createXMLElement(document, root);</span> +<span class="nc" id="L293"> }</span> +<span class="nc" id="L294"> xmlHandler.createXMLFile(document, ALBUMS_FILE_PATH);</span> +<span class="nc" id="L295"> }</span> + + public void savePlayLists() { +<span class="nc" id="L298"> Document document = xmlHandler.createXMLDocument();</span> +<span class="nc bnc" id="L299" title="All 2 branches missed."> if (document == null) return;</span> + + // root element +<span class="nc" id="L302"> Element root = document.createElement("playlists");</span> +<span class="nc" id="L303"> document.appendChild(root);</span> + + //save all playlists +<span class="nc bnc" id="L306" title="All 2 branches missed."> for (Iterator<PlayList> playlistsIter = this.playlists(); playlistsIter.hasNext(); ) {</span> +<span class="nc" id="L307"> PlayList currentPlayList = playlistsIter.next();</span> +<span class="nc" id="L308"> currentPlayList.createXMLElement(document, root);</span> +<span class="nc" id="L309"> }</span> +<span class="nc" id="L310"> xmlHandler.createXMLFile(document, PLAYLISTS_FILE_PATH);</span> +<span class="nc" id="L311"> }</span> + + public void saveElements() { +<span class="nc" id="L314"> Document document = xmlHandler.createXMLDocument();</span> +<span class="nc bnc" id="L315" title="All 2 branches missed."> if (document == null) return;</span> + + // root element +<span class="nc" id="L318"> Element root = document.createElement("elements");</span> +<span class="nc" id="L319"> document.appendChild(root);</span> + + //save all AudioElements +<span class="nc bnc" id="L322" title="All 2 branches missed."> for (AudioElement currentElement : elements) {</span> + +<span class="nc bnc" id="L324" title="All 2 branches missed."> if (currentElement instanceof Song) {</span> +<span class="nc" id="L325"> currentElement.createXMLElement(document, root);</span> + } +<span class="nc bnc" id="L327" title="All 2 branches missed."> if (currentElement instanceof AudioBook) {</span> +<span class="nc" id="L328"> currentElement.createXMLElement(document, root);</span> + } +<span class="nc" id="L330"> }</span> +<span class="nc" id="L331"> xmlHandler.createXMLFile(document, ELEMENTS_FILE_PATH);</span> +<span class="nc" id="L332"> }</span> + + public void getAudioElement(List<AudioElement> audios, String elementTitle) throws NoAlbumFoundException, UnsupportedAudioFileException, IOException, LineUnavailableException { +<span class="nc bnc" id="L335" title="All 2 branches missed."> for (AudioElement el : audios) {</span> +<span class="nc bnc" id="L336" title="All 2 branches missed."> if (el.getTitle().equalsIgnoreCase(elementTitle)) {</span> +<span class="nc" id="L337"> el.manageAudioElement();</span> + } +<span class="nc" id="L339"> }</span> + +<span class="nc" id="L341"> }</span> +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/NoAlbumFoundException.html b/target/site/jacoco/musichub.business/NoAlbumFoundException.html new file mode 100644 index 0000000..51bf5be --- /dev/null +++ b/target/site/jacoco/musichub.business/NoAlbumFoundException.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>NoAlbumFoundException</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">NoAlbumFoundException</span></div><h1>NoAlbumFoundException</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">4 of 4</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">1</td><td class="ctr2">1</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">1</td><td class="ctr2">1</td></tr></tfoot><tbody><tr><td id="a0"><a href="NoAlbumFoundException.java.html#L6" class="el_method">NoAlbumFoundException(String)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="4" alt="4"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">2</td><td class="ctr2" id="i0">2</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/NoAlbumFoundException.java.html b/target/site/jacoco/musichub.business/NoAlbumFoundException.java.html new file mode 100644 index 0000000..d78347b --- /dev/null +++ b/target/site/jacoco/musichub.business/NoAlbumFoundException.java.html @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>NoAlbumFoundException.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">NoAlbumFoundException.java</span></div><h1>NoAlbumFoundException.java</h1><pre class="source lang-java linenums">package musichub.business; + +public class NoAlbumFoundException extends Exception { + + public NoAlbumFoundException(String msg) { +<span class="nc" id="L6"> super(msg);</span> +<span class="nc" id="L7"> }</span> +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/NoElementFoundException.html b/target/site/jacoco/musichub.business/NoElementFoundException.html new file mode 100644 index 0000000..01fecbd --- /dev/null +++ b/target/site/jacoco/musichub.business/NoElementFoundException.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>NoElementFoundException</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">NoElementFoundException</span></div><h1>NoElementFoundException</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">4 of 4</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">1</td><td class="ctr2">1</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">1</td><td class="ctr2">1</td></tr></tfoot><tbody><tr><td id="a0"><a href="NoElementFoundException.java.html#L6" class="el_method">NoElementFoundException(String)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="4" alt="4"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">2</td><td class="ctr2" id="i0">2</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/NoElementFoundException.java.html b/target/site/jacoco/musichub.business/NoElementFoundException.java.html new file mode 100644 index 0000000..4d5f6bb --- /dev/null +++ b/target/site/jacoco/musichub.business/NoElementFoundException.java.html @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>NoElementFoundException.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">NoElementFoundException.java</span></div><h1>NoElementFoundException.java</h1><pre class="source lang-java linenums">package musichub.business; + +public class NoElementFoundException extends Exception { + + public NoElementFoundException(String msg) { +<span class="nc" id="L6"> super(msg);</span> +<span class="nc" id="L7"> }</span> +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/NoPlayListFoundException.html b/target/site/jacoco/musichub.business/NoPlayListFoundException.html new file mode 100644 index 0000000..d1803ad --- /dev/null +++ b/target/site/jacoco/musichub.business/NoPlayListFoundException.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>NoPlayListFoundException</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">NoPlayListFoundException</span></div><h1>NoPlayListFoundException</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">4 of 4</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">1</td><td class="ctr2">1</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">1</td><td class="ctr2">1</td></tr></tfoot><tbody><tr><td id="a0"><a href="NoPlayListFoundException.java.html#L6" class="el_method">NoPlayListFoundException(String)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="4" alt="4"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">2</td><td class="ctr2" id="i0">2</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/NoPlayListFoundException.java.html b/target/site/jacoco/musichub.business/NoPlayListFoundException.java.html new file mode 100644 index 0000000..f93e9a4 --- /dev/null +++ b/target/site/jacoco/musichub.business/NoPlayListFoundException.java.html @@ -0,0 +1,9 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>NoPlayListFoundException.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">NoPlayListFoundException.java</span></div><h1>NoPlayListFoundException.java</h1><pre class="source lang-java linenums">package musichub.business; + +public class NoPlayListFoundException extends Exception { + + public NoPlayListFoundException(String msg) { +<span class="nc" id="L6"> super(msg);</span> +<span class="nc" id="L7"> }</span> +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/PathValidation.html b/target/site/jacoco/musichub.business/PathValidation.html new file mode 100644 index 0000000..3b58bb2 --- /dev/null +++ b/target/site/jacoco/musichub.business/PathValidation.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>PathValidation</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">PathValidation</span></div><h1>PathValidation</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">0 of 17</td><td class="ctr2">100 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">0</td><td class="ctr2">2</td><td class="ctr1">0</td><td class="ctr2">4</td><td class="ctr1">0</td><td class="ctr2">2</td></tr></tfoot><tbody><tr><td id="a0"><a href="PathValidation.java.html#L34" class="el_method">isPathValid(String)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/greenbar.gif" width="120" height="10" title="10" alt="10"/></td><td class="ctr2" id="c0">100 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">0</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">0</td><td class="ctr2" id="i0">2</td><td class="ctr1" id="j0">0</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a1"><a href="PathValidation.java.html#L22" class="el_method">PathValidation()</a></td><td class="bar" id="b1"><img src="../jacoco-resources/greenbar.gif" width="84" height="10" title="7" alt="7"/></td><td class="ctr2" id="c1">100 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">0</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h1">0</td><td class="ctr2" id="i1">2</td><td class="ctr1" id="j1">0</td><td class="ctr2" id="k1">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/PathValidation.java.html b/target/site/jacoco/musichub.business/PathValidation.java.html new file mode 100644 index 0000000..4d22953 --- /dev/null +++ b/target/site/jacoco/musichub.business/PathValidation.java.html @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>PathValidation.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">PathValidation.java</span></div><h1>PathValidation.java</h1><pre class="source lang-java linenums">package musichub.business; + +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.Paths; + +/** + * Class offering a path validation method. + * + * @author Aimeric ADJUTOR + * @version 1.0 + */ + +public final class PathValidation { + + /** + * Method that just throws an AssertionError if the class is called + * @author Aimeric ADJUTOR + * @throws AssertionError you can't instantiate this class + */ + +<span class="fc" id="L22"> public PathValidation() {</span> +<span class="fc" id="L23"> throw new AssertionError("You just can't instantiate this class.");</span> + } + + /** + * Method that checks the validity of a given path + * + * @param inputPath the path given by the user + * @return a boolean + */ + + public static boolean isPathValid(String inputPath) { +<span class="fc" id="L34"> Path path = Paths.get(inputPath);</span> +<span class="fc" id="L35"> return Files.exists(path);</span> + } + +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/PlayList.html b/target/site/jacoco/musichub.business/PlayList.html new file mode 100644 index 0000000..ae17a14 --- /dev/null +++ b/target/site/jacoco/musichub.business/PlayList.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>PlayList</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">PlayList</span></div><h1>PlayList</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">202 of 202</td><td class="ctr2">0 %</td><td class="bar">14 of 14</td><td class="ctr2">0 %</td><td class="ctr1">14</td><td class="ctr2">14</td><td class="ctr1">53</td><td class="ctr2">53</td><td class="ctr1">7</td><td class="ctr2">7</td></tr></tfoot><tbody><tr><td id="a4"><a href="PlayList.java.html#L28" class="el_method">PlayList(Element)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="88" alt="88"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="12" alt="12"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f0">7</td><td class="ctr2" id="g0">7</td><td class="ctr1" id="h0">23</td><td class="ctr2" id="i0">23</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a1"><a href="PlayList.java.html#L78" class="el_method">createXMLElement(Document, Element)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="102" height="10" title="75" alt="75"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="20" height="10" title="2" alt="2"/></td><td class="ctr2" id="e1">0 %</td><td class="ctr1" id="f1">2</td><td class="ctr2" id="g1">2</td><td class="ctr1" id="h1">16</td><td class="ctr2" id="i1">16</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a5"><a href="PlayList.java.html#L22" class="el_method">PlayList(String)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="19" height="10" title="14" alt="14"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h2">5</td><td class="ctr2" id="i2">5</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a6"><a href="PlayList.java.html#L16" class="el_method">PlayList(String, String, ArrayList)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="17" height="10" title="13" alt="13"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d3"/><td class="ctr2" id="e3">n/a</td><td class="ctr1" id="f3">1</td><td class="ctr2" id="g3">1</td><td class="ctr1" id="h3">5</td><td class="ctr2" id="i3">5</td><td class="ctr1" id="j3">1</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a0"><a href="PlayList.java.html#L66" class="el_method">addElement(UUID)</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="6" alt="6"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d4"/><td class="ctr2" id="e4">n/a</td><td class="ctr1" id="f4">1</td><td class="ctr2" id="g4">1</td><td class="ctr1" id="h4">2</td><td class="ctr2" id="i4">2</td><td class="ctr1" id="j4">1</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a2"><a href="PlayList.java.html#L70" class="el_method">getElements()</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="4" height="10" title="3" alt="3"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d5"/><td class="ctr2" id="e5">n/a</td><td class="ctr1" id="f5">1</td><td class="ctr2" id="g5">1</td><td class="ctr1" id="h5">1</td><td class="ctr2" id="i5">1</td><td class="ctr1" id="j5">1</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a3"><a href="PlayList.java.html#L74" class="el_method">getTitle()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="4" height="10" title="3" alt="3"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f6">1</td><td class="ctr2" id="g6">1</td><td class="ctr1" id="h6">1</td><td class="ctr2" id="i6">1</td><td class="ctr1" id="j6">1</td><td class="ctr2" id="k6">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/PlayList.java.html b/target/site/jacoco/musichub.business/PlayList.java.html new file mode 100644 index 0000000..6a45004 --- /dev/null +++ b/target/site/jacoco/musichub.business/PlayList.java.html @@ -0,0 +1,101 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>PlayList.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">PlayList.java</span></div><h1>PlayList.java</h1><pre class="source lang-java linenums">package musichub.business; + +import org.w3c.dom.Document; +import org.w3c.dom.Element; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; + +import java.util.ArrayList; +import java.util.UUID; + +public class PlayList { + private final String title; + private final UUID uuid; + private ArrayList<UUID> elementUUIDs; + +<span class="nc" id="L16"> public PlayList(String title, String id, ArrayList<UUID> elementUUIDs) {</span> +<span class="nc" id="L17"> this.title = title;</span> +<span class="nc" id="L18"> this.uuid = UUID.fromString(id);</span> +<span class="nc" id="L19"> this.elementUUIDs = elementUUIDs;</span> +<span class="nc" id="L20"> }</span> + +<span class="nc" id="L22"> public PlayList(String title) {</span> +<span class="nc" id="L23"> this.title = title;</span> +<span class="nc" id="L24"> this.uuid = UUID.randomUUID();</span> +<span class="nc" id="L25"> this.elementUUIDs = new ArrayList<>();</span> +<span class="nc" id="L26"> }</span> + +<span class="nc" id="L28"> public PlayList(Element xmlElement) {</span> + { +<span class="nc" id="L30"> this.title = xmlElement.getElementsByTagName("title").item(0).getTextContent();</span> + +<span class="nc" id="L32"> String uuid = null;</span> + try { +<span class="nc" id="L34"> uuid = xmlElement.getElementsByTagName("UUID").item(0).getTextContent();</span> +<span class="nc" id="L35"> } catch (Exception ex) {</span> +<span class="nc" id="L36"> System.out.println("Empty playlist UUID, will create a new one");</span> +<span class="nc" id="L37"> }</span> +<span class="nc bnc" id="L38" title="All 4 branches missed."> if ((uuid == null) || (uuid.isEmpty()))</span> +<span class="nc" id="L39"> this.uuid = UUID.randomUUID();</span> +<span class="nc" id="L40"> else this.uuid = UUID.fromString(uuid);</span> + + //parse list of elements: +<span class="nc" id="L43"> Node elementsElement = xmlElement.getElementsByTagName("elements").item(0);</span> +<span class="nc" id="L44"> NodeList elementUUIDNodes = elementsElement.getChildNodes();</span> +<span class="nc bnc" id="L45" title="All 2 branches missed."> if (elementUUIDNodes == null) return;</span> + +<span class="nc" id="L47"> this.elementUUIDs = new ArrayList<>();</span> + + +<span class="nc bnc" id="L50" title="All 2 branches missed."> for (int i = 0; i < elementUUIDNodes.getLength(); i++) {</span> +<span class="nc bnc" id="L51" title="All 2 branches missed."> if (elementUUIDNodes.item(i).getNodeType() == Node.ELEMENT_NODE) {</span> +<span class="nc" id="L52"> Element elementElement = (Element) elementUUIDNodes.item(i);</span> +<span class="nc bnc" id="L53" title="All 2 branches missed."> if (elementElement.getNodeName().equals("UUID")) {</span> + try { +<span class="nc" id="L55"> this.addElement(UUID.fromString(elementElement.getTextContent()));</span> +<span class="nc" id="L56"> } catch (Exception ex) {</span> +<span class="nc" id="L57"> ex.printStackTrace();</span> +<span class="nc" id="L58"> }</span> + } + } + } + } +<span class="nc" id="L63"> }</span> + + public void addElement(UUID element) { +<span class="nc" id="L66"> elementUUIDs.add(element);</span> +<span class="nc" id="L67"> }</span> + + public ArrayList<UUID> getElements() { +<span class="nc" id="L70"> return elementUUIDs;</span> + } + + public String getTitle() { +<span class="nc" id="L74"> return title;</span> + } + + public void createXMLElement(Document document, Element parentElement) { +<span class="nc" id="L78"> Element playlistElement = document.createElement("playlist");</span> +<span class="nc" id="L79"> parentElement.appendChild(playlistElement);</span> + +<span class="nc" id="L81"> Element nameElement = document.createElement("title");</span> +<span class="nc" id="L82"> nameElement.appendChild(document.createTextNode(title));</span> +<span class="nc" id="L83"> playlistElement.appendChild(nameElement);</span> + +<span class="nc" id="L85"> Element UUIDElement = document.createElement("UUID");</span> +<span class="nc" id="L86"> UUIDElement.appendChild(document.createTextNode(uuid.toString()));</span> +<span class="nc" id="L87"> playlistElement.appendChild(UUIDElement);</span> + + +<span class="nc" id="L90"> Element elementsElement = document.createElement("elements");</span> +<span class="nc bnc" id="L91" title="All 2 branches missed."> for (UUID currentUUID : this.elementUUIDs) {</span> + +<span class="nc" id="L93"> Element elementUUIDElement = document.createElement("UUID");</span> +<span class="nc" id="L94"> elementUUIDElement.appendChild(document.createTextNode(currentUUID.toString()));</span> +<span class="nc" id="L95"> elementsElement.appendChild(elementUUIDElement);</span> +<span class="nc" id="L96"> }</span> +<span class="nc" id="L97"> playlistElement.appendChild(elementsElement);</span> +<span class="nc" id="L98"> }</span> + +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Song.html b/target/site/jacoco/musichub.business/Song.html new file mode 100644 index 0000000..4af18c3 --- /dev/null +++ b/target/site/jacoco/musichub.business/Song.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Song</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">Song</span></div><h1>Song</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">105 of 105</td><td class="ctr2">0 %</td><td class="bar">6 of 6</td><td class="ctr2">0 %</td><td class="ctr1">12</td><td class="ctr2">12</td><td class="ctr1">26</td><td class="ctr2">26</td><td class="ctr1">7</td><td class="ctr2">7</td></tr></tfoot><tbody><tr><td id="a2"><a href="Song.java.html#L30" class="el_method">setGenre(String)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="33" alt="33"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="6" alt="6"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f0">6</td><td class="ctr2" id="g0">6</td><td class="ctr1" id="h0">8</td><td class="ctr2" id="i0">8</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a0"><a href="Song.java.html#L46" class="el_method">createXMLElement(Document, Element)</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="105" height="10" title="29" alt="29"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">1</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h1">7</td><td class="ctr2" id="i1">7</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr><tr><td id="a3"><a href="Song.java.html#L21" class="el_method">Song(Element)</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="43" height="10" title="12" alt="12"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d2"/><td class="ctr2" id="e2">n/a</td><td class="ctr1" id="f2">1</td><td class="ctr2" id="g2">1</td><td class="ctr1" id="h2">3</td><td class="ctr2" id="i2">3</td><td class="ctr1" id="j2">1</td><td class="ctr2" id="k2">1</td></tr><tr><td id="a5"><a href="Song.java.html#L11" class="el_method">Song(String, String, int, String, String, String)</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="40" height="10" title="11" alt="11"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d3"/><td class="ctr2" id="e3">n/a</td><td class="ctr1" id="f3">1</td><td class="ctr2" id="g3">1</td><td class="ctr1" id="h3">3</td><td class="ctr2" id="i3">3</td><td class="ctr1" id="j3">1</td><td class="ctr2" id="k3">1</td></tr><tr><td id="a4"><a href="Song.java.html#L16" class="el_method">Song(String, String, int, String, String)</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="36" height="10" title="10" alt="10"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d4"/><td class="ctr2" id="e4">n/a</td><td class="ctr1" id="f4">1</td><td class="ctr2" id="g4">1</td><td class="ctr1" id="h4">3</td><td class="ctr2" id="i4">3</td><td class="ctr1" id="j4">1</td><td class="ctr2" id="k4">1</td></tr><tr><td id="a6"><a href="Song.java.html#L41" class="el_method">toString()</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="21" height="10" title="6" alt="6"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d5"/><td class="ctr2" id="e5">n/a</td><td class="ctr1" id="f5">1</td><td class="ctr2" id="g5">1</td><td class="ctr1" id="h5">1</td><td class="ctr2" id="i5">1</td><td class="ctr1" id="j5">1</td><td class="ctr2" id="k5">1</td></tr><tr><td id="a1"><a href="Song.java.html#L26" class="el_method">getGenre()</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="14" height="10" title="4" alt="4"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f6">1</td><td class="ctr2" id="g6">1</td><td class="ctr1" id="h6">1</td><td class="ctr2" id="i6">1</td><td class="ctr1" id="j6">1</td><td class="ctr2" id="k6">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/Song.java.html b/target/site/jacoco/musichub.business/Song.java.html new file mode 100644 index 0000000..4f7f01d --- /dev/null +++ b/target/site/jacoco/musichub.business/Song.java.html @@ -0,0 +1,59 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>Song.java</title><link rel="stylesheet" href="../jacoco-resources/prettify.css" type="text/css"/><script type="text/javascript" src="../jacoco-resources/prettify.js"></script></head><body onload="window['PR_TAB_WIDTH']=4;prettyPrint()"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.source.html" class="el_package">musichub.business</a> > <span class="el_source">Song.java</span></div><h1>Song.java</h1><pre class="source lang-java linenums">package musichub.business; + +import org.w3c.dom.Document; +import org.w3c.dom.Element; + + +public class Song extends AudioElement { + private Genre genre; + + public Song(String title, String artist, int length, String uid, String content, String genre) { +<span class="nc" id="L11"> super(title, artist, length, uid, content);</span> +<span class="nc" id="L12"> this.setGenre(genre);</span> +<span class="nc" id="L13"> }</span> + + public Song(String title, String artist, int length, String content, String genre) { +<span class="nc" id="L16"> super(title, artist, length, content);</span> +<span class="nc" id="L17"> this.setGenre(genre);</span> +<span class="nc" id="L18"> }</span> + + public Song(Element xmlElement) { +<span class="nc" id="L21"> super(xmlElement);</span> +<span class="nc" id="L22"> this.setGenre(xmlElement.getElementsByTagName("genre").item(0).getTextContent());</span> +<span class="nc" id="L23"> }</span> + + public String getGenre() { +<span class="nc" id="L26"> return genre.getGenre();</span> + } + + public void setGenre(String genre) { +<span class="nc bnc" id="L30" title="All 6 branches missed."> switch (genre.toLowerCase()) {</span> +<span class="nc" id="L31"> default -> this.genre = Genre.JAZZ;</span> +<span class="nc" id="L32"> case "classic" -> this.genre = Genre.CLASSIC;</span> +<span class="nc" id="L33"> case "hiphop" -> this.genre = Genre.HIPHOP;</span> +<span class="nc" id="L34"> case "rock" -> this.genre = Genre.ROCK;</span> +<span class="nc" id="L35"> case "pop" -> this.genre = Genre.POP;</span> +<span class="nc" id="L36"> case "rap" -> this.genre = Genre.RAP;</span> + } +<span class="nc" id="L38"> }</span> + + public String toString() { +<span class="nc" id="L41"> return super.toString() + ", Genre = " + getGenre() + "\n";</span> + } + + public void createXMLElement(Document document, Element parentElement) { + // song element +<span class="nc" id="L46"> Element song = document.createElement("song");</span> + +<span class="nc" id="L48"> super.createXMLElement(document, song);</span> + +<span class="nc" id="L50"> Element genreElement = document.createElement("genre");</span> +<span class="nc" id="L51"> genreElement.appendChild(document.createTextNode(genre.getGenre()));</span> +<span class="nc" id="L52"> song.appendChild(genreElement);</span> + +<span class="nc" id="L54"> parentElement.appendChild(song);</span> +<span class="nc" id="L55"> }</span> + + +} +</pre><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/SortByAuthor.html b/target/site/jacoco/musichub.business/SortByAuthor.html new file mode 100644 index 0000000..851cdce --- /dev/null +++ b/target/site/jacoco/musichub.business/SortByAuthor.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>SortByAuthor</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">SortByAuthor</span></div><h1>SortByAuthor</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">9 of 9</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">2</td><td class="ctr2">2</td></tr></tfoot><tbody><tr><td id="a0"><a href="MusicHub.java.html#L29" class="el_method">compare(AudioElement, AudioElement)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="6" alt="6"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i0">1</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a1"><a href="MusicHub.java.html#L27" class="el_method">SortByAuthor()</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="60" height="10" title="3" alt="3"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">1</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h1">1</td><td class="ctr2" id="i1">1</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/SortByDate.html b/target/site/jacoco/musichub.business/SortByDate.html new file mode 100644 index 0000000..8f4b2f7 --- /dev/null +++ b/target/site/jacoco/musichub.business/SortByDate.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>SortByDate</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">SortByDate</span></div><h1>SortByDate</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">9 of 9</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">2</td><td class="ctr2">2</td></tr></tfoot><tbody><tr><td id="a0"><a href="MusicHub.java.html#L17" class="el_method">compare(Album, Album)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="6" alt="6"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i0">1</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a1"><a href="MusicHub.java.html#L15" class="el_method">SortByDate()</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="60" height="10" title="3" alt="3"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">1</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h1">1</td><td class="ctr2" id="i1">1</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/SortByGenre.html b/target/site/jacoco/musichub.business/SortByGenre.html new file mode 100644 index 0000000..6dd6e7d --- /dev/null +++ b/target/site/jacoco/musichub.business/SortByGenre.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>SortByGenre</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <a href="index.html" class="el_package">musichub.business</a> > <span class="el_class">SortByGenre</span></div><h1>SortByGenre</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">9 of 9</td><td class="ctr2">0 %</td><td class="bar">0 of 0</td><td class="ctr2">n/a</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">2</td><td class="ctr2">2</td><td class="ctr1">2</td><td class="ctr2">2</td></tr></tfoot><tbody><tr><td id="a0"><a href="MusicHub.java.html#L23" class="el_method">compare(Song, Song)</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="6" alt="6"/></td><td class="ctr2" id="c0">0 %</td><td class="bar" id="d0"/><td class="ctr2" id="e0">n/a</td><td class="ctr1" id="f0">1</td><td class="ctr2" id="g0">1</td><td class="ctr1" id="h0">1</td><td class="ctr2" id="i0">1</td><td class="ctr1" id="j0">1</td><td class="ctr2" id="k0">1</td></tr><tr><td id="a1"><a href="MusicHub.java.html#L21" class="el_method">SortByGenre()</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="60" height="10" title="3" alt="3"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d1"/><td class="ctr2" id="e1">n/a</td><td class="ctr1" id="f1">1</td><td class="ctr2" id="g1">1</td><td class="ctr1" id="h1">1</td><td class="ctr2" id="i1">1</td><td class="ctr1" id="j1">1</td><td class="ctr2" id="k1">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/index.html b/target/site/jacoco/musichub.business/index.html new file mode 100644 index 0000000..178e60b --- /dev/null +++ b/target/site/jacoco/musichub.business/index.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>musichub.business</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb', 'coveragetable'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="index.source.html" class="el_source">Source Files</a><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <span class="el_package">musichub.business</span></div><h1>musichub.business</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td><td class="sortable ctr1" id="l" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="m" onclick="toggleSort(this)">Classes</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">2 063 of 2 080</td><td class="ctr2">0 %</td><td class="bar">169 of 169</td><td class="ctr2">0 %</td><td class="ctr1">172</td><td class="ctr2">174</td><td class="ctr1">499</td><td class="ctr2">503</td><td class="ctr1">81</td><td class="ctr2">83</td><td class="ctr1">15</td><td class="ctr2">16</td></tr></tfoot><tbody><tr><td id="a6"><a href="MusicHub.html" class="el_class">MusicHub</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="803" alt="803"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="114" alt="114"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f0">79</td><td class="ctr2" id="g0">79</td><td class="ctr1" id="h0">195</td><td class="ctr2" id="i0">195</td><td class="ctr1" id="j0">22</td><td class="ctr2" id="k0">22</td><td class="ctr1" id="l0">1</td><td class="ctr2" id="m0">1</td></tr><tr><td id="a0"><a href="Album.html" class="el_class">Album</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="49" height="10" title="330" alt="330"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="14" height="10" title="14" alt="14"/></td><td class="ctr2" id="e1">0 %</td><td class="ctr1" id="f2">16</td><td class="ctr2" id="g2">16</td><td class="ctr1" id="h1">84</td><td class="ctr2" id="i1">84</td><td class="ctr1" id="j1">9</td><td class="ctr2" id="k1">9</td><td class="ctr1" id="l1">1</td><td class="ctr2" id="m1">1</td></tr><tr><td id="a2"><a href="AudioElement.html" class="el_class">AudioElement</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="39" height="10" title="266" alt="266"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d3"><img src="../jacoco-resources/redbar.gif" width="11" height="10" title="11" alt="11"/></td><td class="ctr2" id="e2">0 %</td><td class="ctr1" id="f3">16</td><td class="ctr2" id="g3">16</td><td class="ctr1" id="h2">72</td><td class="ctr2" id="i2">72</td><td class="ctr1" id="j2">9</td><td class="ctr2" id="k2">9</td><td class="ctr1" id="l2">1</td><td class="ctr2" id="m2">1</td></tr><tr><td id="a11"><a href="PlayList.html" class="el_class">PlayList</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="30" height="10" title="202" alt="202"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d2"><img src="../jacoco-resources/redbar.gif" width="14" height="10" title="14" alt="14"/></td><td class="ctr2" id="e3">0 %</td><td class="ctr1" id="f4">14</td><td class="ctr2" id="g4">14</td><td class="ctr1" id="h3">53</td><td class="ctr2" id="i3">53</td><td class="ctr1" id="j4">7</td><td class="ctr2" id="k4">7</td><td class="ctr1" id="l3">1</td><td class="ctr2" id="m3">1</td></tr><tr><td id="a1"><a href="AudioBook.html" class="el_class">AudioBook</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="24" height="10" title="164" alt="164"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d4"><img src="../jacoco-resources/redbar.gif" width="10" height="10" title="10" alt="10"/></td><td class="ctr2" id="e4">0 %</td><td class="ctr1" id="f1">17</td><td class="ctr2" id="g1">17</td><td class="ctr1" id="h4">39</td><td class="ctr2" id="i4">39</td><td class="ctr1" id="j3">9</td><td class="ctr2" id="k3">9</td><td class="ctr1" id="l4">1</td><td class="ctr2" id="m4">1</td></tr><tr><td id="a12"><a href="Song.html" class="el_class">Song</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="15" height="10" title="105" alt="105"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d5"><img src="../jacoco-resources/redbar.gif" width="6" height="10" title="6" alt="6"/></td><td class="ctr2" id="e5">0 %</td><td class="ctr1" id="f5">12</td><td class="ctr2" id="g5">12</td><td class="ctr1" id="h5">26</td><td class="ctr2" id="i5">26</td><td class="ctr1" id="j5">7</td><td class="ctr2" id="k5">7</td><td class="ctr1" id="l5">1</td><td class="ctr2" id="m5">1</td></tr><tr><td id="a4"><a href="Genre.html" class="el_class">Genre</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="56" alt="56"/></td><td class="ctr2" id="c7">0 %</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f6">3</td><td class="ctr2" id="g6">3</td><td class="ctr1" id="h6">6</td><td class="ctr2" id="i6">6</td><td class="ctr1" id="j6">3</td><td class="ctr2" id="k6">3</td><td class="ctr1" id="l6">1</td><td class="ctr2" id="m6">1</td></tr><tr><td id="a5"><a href="Language.html" class="el_class">Language</a></td><td class="bar" id="b7"><img src="../jacoco-resources/redbar.gif" width="7" height="10" title="49" alt="49"/></td><td class="ctr2" id="c8">0 %</td><td class="bar" id="d7"/><td class="ctr2" id="e7">n/a</td><td class="ctr1" id="f7">3</td><td class="ctr2" id="g7">3</td><td class="ctr1" id="h7">6</td><td class="ctr2" id="i7">6</td><td class="ctr1" id="j7">3</td><td class="ctr2" id="k7">3</td><td class="ctr1" id="l7">1</td><td class="ctr2" id="m7">1</td></tr><tr><td id="a3"><a href="Category.html" class="el_class">Category</a></td><td class="bar" id="b8"><img src="../jacoco-resources/redbar.gif" width="7" height="10" title="49" alt="49"/></td><td class="ctr2" id="c9">0 %</td><td class="bar" id="d8"/><td class="ctr2" id="e8">n/a</td><td class="ctr1" id="f8">3</td><td class="ctr2" id="g8">3</td><td class="ctr1" id="h8">6</td><td class="ctr2" id="i8">6</td><td class="ctr1" id="j8">3</td><td class="ctr2" id="k8">3</td><td class="ctr1" id="l8">1</td><td class="ctr2" id="m8">1</td></tr><tr><td id="a13"><a href="SortByAuthor.html" class="el_class">SortByAuthor</a></td><td class="bar" id="b9"><img src="../jacoco-resources/redbar.gif" width="1" height="10" title="9" alt="9"/></td><td class="ctr2" id="c10">0 %</td><td class="bar" id="d9"/><td class="ctr2" id="e9">n/a</td><td class="ctr1" id="f9">2</td><td class="ctr2" id="g9">2</td><td class="ctr1" id="h9">2</td><td class="ctr2" id="i10">2</td><td class="ctr1" id="j9">2</td><td class="ctr2" id="k9">2</td><td class="ctr1" id="l9">1</td><td class="ctr2" id="m9">1</td></tr><tr><td id="a14"><a href="SortByDate.html" class="el_class">SortByDate</a></td><td class="bar" id="b10"><img src="../jacoco-resources/redbar.gif" width="1" height="10" title="9" alt="9"/></td><td class="ctr2" id="c11">0 %</td><td class="bar" id="d10"/><td class="ctr2" id="e10">n/a</td><td class="ctr1" id="f10">2</td><td class="ctr2" id="g10">2</td><td class="ctr1" id="h10">2</td><td class="ctr2" id="i11">2</td><td class="ctr1" id="j10">2</td><td class="ctr2" id="k10">2</td><td class="ctr1" id="l10">1</td><td class="ctr2" id="m10">1</td></tr><tr><td id="a15"><a href="SortByGenre.html" class="el_class">SortByGenre</a></td><td class="bar" id="b11"><img src="../jacoco-resources/redbar.gif" width="1" height="10" title="9" alt="9"/></td><td class="ctr2" id="c12">0 %</td><td class="bar" id="d11"/><td class="ctr2" id="e11">n/a</td><td class="ctr1" id="f11">2</td><td class="ctr2" id="g11">2</td><td class="ctr1" id="h11">2</td><td class="ctr2" id="i12">2</td><td class="ctr1" id="j11">2</td><td class="ctr2" id="k11">2</td><td class="ctr1" id="l11">1</td><td class="ctr2" id="m11">1</td></tr><tr><td id="a7"><a href="NoAlbumFoundException.html" class="el_class">NoAlbumFoundException</a></td><td class="bar" id="b12"/><td class="ctr2" id="c13">0 %</td><td class="bar" id="d12"/><td class="ctr2" id="e12">n/a</td><td class="ctr1" id="f12">1</td><td class="ctr2" id="g13">1</td><td class="ctr1" id="h12">2</td><td class="ctr2" id="i13">2</td><td class="ctr1" id="j12">1</td><td class="ctr2" id="k13">1</td><td class="ctr1" id="l12">1</td><td class="ctr2" id="m12">1</td></tr><tr><td id="a9"><a href="NoPlayListFoundException.html" class="el_class">NoPlayListFoundException</a></td><td class="bar" id="b13"/><td class="ctr2" id="c14">0 %</td><td class="bar" id="d13"/><td class="ctr2" id="e13">n/a</td><td class="ctr1" id="f13">1</td><td class="ctr2" id="g14">1</td><td class="ctr1" id="h13">2</td><td class="ctr2" id="i14">2</td><td class="ctr1" id="j13">1</td><td class="ctr2" id="k14">1</td><td class="ctr1" id="l13">1</td><td class="ctr2" id="m13">1</td></tr><tr><td id="a8"><a href="NoElementFoundException.html" class="el_class">NoElementFoundException</a></td><td class="bar" id="b14"/><td class="ctr2" id="c15">0 %</td><td class="bar" id="d14"/><td class="ctr2" id="e14">n/a</td><td class="ctr1" id="f14">1</td><td class="ctr2" id="g15">1</td><td class="ctr1" id="h14">2</td><td class="ctr2" id="i15">2</td><td class="ctr1" id="j14">1</td><td class="ctr2" id="k15">1</td><td class="ctr1" id="l14">1</td><td class="ctr2" id="m14">1</td></tr><tr><td id="a10"><a href="PathValidation.html" class="el_class">PathValidation</a></td><td class="bar" id="b15"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="17" alt="17"/></td><td class="ctr2" id="c0">100 %</td><td class="bar" id="d15"/><td class="ctr2" id="e15">n/a</td><td class="ctr1" id="f15">0</td><td class="ctr2" id="g12">2</td><td class="ctr1" id="h15">0</td><td class="ctr2" id="i9">4</td><td class="ctr1" id="j15">0</td><td class="ctr2" id="k12">2</td><td class="ctr1" id="l15">0</td><td class="ctr2" id="m15">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file diff --git a/target/site/jacoco/musichub.business/index.source.html b/target/site/jacoco/musichub.business/index.source.html new file mode 100644 index 0000000..45a5b59 --- /dev/null +++ b/target/site/jacoco/musichub.business/index.source.html @@ -0,0 +1 @@ +<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" lang="fr"><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8"/><link rel="stylesheet" href="../jacoco-resources/report.css" type="text/css"/><link rel="shortcut icon" href="../jacoco-resources/report.gif" type="image/gif"/><title>musichub.business</title><script type="text/javascript" src="../jacoco-resources/sort.js"></script></head><body onload="initialSort(['breadcrumb', 'coveragetable'])"><div class="breadcrumb" id="breadcrumb"><span class="info"><a href="index.html" class="el_class">Classes</a><a href="../jacoco-sessions.html" class="el_session">Sessions</a></span><a href="../index.html" class="el_report">spoteezer</a> > <span class="el_package">musichub.business</span></div><h1>musichub.business</h1><table class="coverage" cellspacing="0" id="coveragetable"><thead><tr><td class="sortable" id="a" onclick="toggleSort(this)">Element</td><td class="down sortable bar" id="b" onclick="toggleSort(this)">Missed Instructions</td><td class="sortable ctr2" id="c" onclick="toggleSort(this)">Cov.</td><td class="sortable bar" id="d" onclick="toggleSort(this)">Missed Branches</td><td class="sortable ctr2" id="e" onclick="toggleSort(this)">Cov.</td><td class="sortable ctr1" id="f" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="g" onclick="toggleSort(this)">Cxty</td><td class="sortable ctr1" id="h" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="i" onclick="toggleSort(this)">Lines</td><td class="sortable ctr1" id="j" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="k" onclick="toggleSort(this)">Methods</td><td class="sortable ctr1" id="l" onclick="toggleSort(this)">Missed</td><td class="sortable ctr2" id="m" onclick="toggleSort(this)">Classes</td></tr></thead><tfoot><tr><td>Total</td><td class="bar">2 063 of 2 080</td><td class="ctr2">0 %</td><td class="bar">169 of 169</td><td class="ctr2">0 %</td><td class="ctr1">172</td><td class="ctr2">174</td><td class="ctr1">499</td><td class="ctr2">503</td><td class="ctr1">81</td><td class="ctr2">83</td><td class="ctr1">15</td><td class="ctr2">16</td></tr></tfoot><tbody><tr><td id="a6"><a href="MusicHub.java.html" class="el_source">MusicHub.java</a></td><td class="bar" id="b0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="830" alt="830"/></td><td class="ctr2" id="c1">0 %</td><td class="bar" id="d0"><img src="../jacoco-resources/redbar.gif" width="120" height="10" title="114" alt="114"/></td><td class="ctr2" id="e0">0 %</td><td class="ctr1" id="f0">85</td><td class="ctr2" id="g0">85</td><td class="ctr1" id="h0">201</td><td class="ctr2" id="i0">201</td><td class="ctr1" id="j0">28</td><td class="ctr2" id="k0">28</td><td class="ctr1" id="l0">4</td><td class="ctr2" id="m0">4</td></tr><tr><td id="a0"><a href="Album.java.html" class="el_source">Album.java</a></td><td class="bar" id="b1"><img src="../jacoco-resources/redbar.gif" width="47" height="10" title="330" alt="330"/></td><td class="ctr2" id="c2">0 %</td><td class="bar" id="d1"><img src="../jacoco-resources/redbar.gif" width="14" height="10" title="14" alt="14"/></td><td class="ctr2" id="e1">0 %</td><td class="ctr1" id="f2">16</td><td class="ctr2" id="g2">16</td><td class="ctr1" id="h1">84</td><td class="ctr2" id="i1">84</td><td class="ctr1" id="j1">9</td><td class="ctr2" id="k1">9</td><td class="ctr1" id="l1">1</td><td class="ctr2" id="m1">1</td></tr><tr><td id="a2"><a href="AudioElement.java.html" class="el_source">AudioElement.java</a></td><td class="bar" id="b2"><img src="../jacoco-resources/redbar.gif" width="38" height="10" title="266" alt="266"/></td><td class="ctr2" id="c3">0 %</td><td class="bar" id="d3"><img src="../jacoco-resources/redbar.gif" width="11" height="10" title="11" alt="11"/></td><td class="ctr2" id="e2">0 %</td><td class="ctr1" id="f3">16</td><td class="ctr2" id="g3">16</td><td class="ctr1" id="h2">72</td><td class="ctr2" id="i2">72</td><td class="ctr1" id="j2">9</td><td class="ctr2" id="k2">9</td><td class="ctr1" id="l2">1</td><td class="ctr2" id="m2">1</td></tr><tr><td id="a11"><a href="PlayList.java.html" class="el_source">PlayList.java</a></td><td class="bar" id="b3"><img src="../jacoco-resources/redbar.gif" width="29" height="10" title="202" alt="202"/></td><td class="ctr2" id="c4">0 %</td><td class="bar" id="d2"><img src="../jacoco-resources/redbar.gif" width="14" height="10" title="14" alt="14"/></td><td class="ctr2" id="e3">0 %</td><td class="ctr1" id="f4">14</td><td class="ctr2" id="g4">14</td><td class="ctr1" id="h3">53</td><td class="ctr2" id="i3">53</td><td class="ctr1" id="j4">7</td><td class="ctr2" id="k4">7</td><td class="ctr1" id="l3">1</td><td class="ctr2" id="m3">1</td></tr><tr><td id="a1"><a href="AudioBook.java.html" class="el_source">AudioBook.java</a></td><td class="bar" id="b4"><img src="../jacoco-resources/redbar.gif" width="23" height="10" title="164" alt="164"/></td><td class="ctr2" id="c5">0 %</td><td class="bar" id="d4"><img src="../jacoco-resources/redbar.gif" width="10" height="10" title="10" alt="10"/></td><td class="ctr2" id="e4">0 %</td><td class="ctr1" id="f1">17</td><td class="ctr2" id="g1">17</td><td class="ctr1" id="h4">39</td><td class="ctr2" id="i4">39</td><td class="ctr1" id="j3">9</td><td class="ctr2" id="k3">9</td><td class="ctr1" id="l4">1</td><td class="ctr2" id="m4">1</td></tr><tr><td id="a12"><a href="Song.java.html" class="el_source">Song.java</a></td><td class="bar" id="b5"><img src="../jacoco-resources/redbar.gif" width="15" height="10" title="105" alt="105"/></td><td class="ctr2" id="c6">0 %</td><td class="bar" id="d5"><img src="../jacoco-resources/redbar.gif" width="6" height="10" title="6" alt="6"/></td><td class="ctr2" id="e5">0 %</td><td class="ctr1" id="f5">12</td><td class="ctr2" id="g5">12</td><td class="ctr1" id="h5">26</td><td class="ctr2" id="i5">26</td><td class="ctr1" id="j5">7</td><td class="ctr2" id="k5">7</td><td class="ctr1" id="l5">1</td><td class="ctr2" id="m5">1</td></tr><tr><td id="a4"><a href="Genre.java.html" class="el_source">Genre.java</a></td><td class="bar" id="b6"><img src="../jacoco-resources/redbar.gif" width="8" height="10" title="56" alt="56"/></td><td class="ctr2" id="c7">0 %</td><td class="bar" id="d6"/><td class="ctr2" id="e6">n/a</td><td class="ctr1" id="f6">3</td><td class="ctr2" id="g6">3</td><td class="ctr1" id="h6">6</td><td class="ctr2" id="i6">6</td><td class="ctr1" id="j6">3</td><td class="ctr2" id="k6">3</td><td class="ctr1" id="l6">1</td><td class="ctr2" id="m6">1</td></tr><tr><td id="a5"><a href="Language.java.html" class="el_source">Language.java</a></td><td class="bar" id="b7"><img src="../jacoco-resources/redbar.gif" width="7" height="10" title="49" alt="49"/></td><td class="ctr2" id="c8">0 %</td><td class="bar" id="d7"/><td class="ctr2" id="e7">n/a</td><td class="ctr1" id="f7">3</td><td class="ctr2" id="g7">3</td><td class="ctr1" id="h7">6</td><td class="ctr2" id="i7">6</td><td class="ctr1" id="j7">3</td><td class="ctr2" id="k7">3</td><td class="ctr1" id="l7">1</td><td class="ctr2" id="m7">1</td></tr><tr><td id="a3"><a href="Category.java.html" class="el_source">Category.java</a></td><td class="bar" id="b8"><img src="../jacoco-resources/redbar.gif" width="7" height="10" title="49" alt="49"/></td><td class="ctr2" id="c9">0 %</td><td class="bar" id="d8"/><td class="ctr2" id="e8">n/a</td><td class="ctr1" id="f8">3</td><td class="ctr2" id="g8">3</td><td class="ctr1" id="h8">6</td><td class="ctr2" id="i8">6</td><td class="ctr1" id="j8">3</td><td class="ctr2" id="k8">3</td><td class="ctr1" id="l8">1</td><td class="ctr2" id="m8">1</td></tr><tr><td id="a7"><a href="NoAlbumFoundException.java.html" class="el_source">NoAlbumFoundException.java</a></td><td class="bar" id="b9"/><td class="ctr2" id="c10">0 %</td><td class="bar" id="d9"/><td class="ctr2" id="e9">n/a</td><td class="ctr1" id="f9">1</td><td class="ctr2" id="g10">1</td><td class="ctr1" id="h9">2</td><td class="ctr2" id="i10">2</td><td class="ctr1" id="j9">1</td><td class="ctr2" id="k10">1</td><td class="ctr1" id="l9">1</td><td class="ctr2" id="m9">1</td></tr><tr><td id="a9"><a href="NoPlayListFoundException.java.html" class="el_source">NoPlayListFoundException.java</a></td><td class="bar" id="b10"/><td class="ctr2" id="c11">0 %</td><td class="bar" id="d10"/><td class="ctr2" id="e10">n/a</td><td class="ctr1" id="f10">1</td><td class="ctr2" id="g11">1</td><td class="ctr1" id="h10">2</td><td class="ctr2" id="i11">2</td><td class="ctr1" id="j10">1</td><td class="ctr2" id="k11">1</td><td class="ctr1" id="l10">1</td><td class="ctr2" id="m10">1</td></tr><tr><td id="a8"><a href="NoElementFoundException.java.html" class="el_source">NoElementFoundException.java</a></td><td class="bar" id="b11"/><td class="ctr2" id="c12">0 %</td><td class="bar" id="d11"/><td class="ctr2" id="e11">n/a</td><td class="ctr1" id="f11">1</td><td class="ctr2" id="g12">1</td><td class="ctr1" id="h11">2</td><td class="ctr2" id="i12">2</td><td class="ctr1" id="j11">1</td><td class="ctr2" id="k12">1</td><td class="ctr1" id="l11">1</td><td class="ctr2" id="m11">1</td></tr><tr><td id="a10"><a href="PathValidation.java.html" class="el_source">PathValidation.java</a></td><td class="bar" id="b12"><img src="../jacoco-resources/greenbar.gif" width="2" height="10" title="17" alt="17"/></td><td class="ctr2" id="c0">100 %</td><td class="bar" id="d12"/><td class="ctr2" id="e12">n/a</td><td class="ctr1" id="f12">0</td><td class="ctr2" id="g9">2</td><td class="ctr1" id="h12">0</td><td class="ctr2" id="i9">4</td><td class="ctr1" id="j12">0</td><td class="ctr2" id="k9">2</td><td class="ctr1" id="l12">0</td><td class="ctr2" id="m12">1</td></tr></tbody></table><div class="footer"><span class="right">Created with <a href="http://www.jacoco.org/jacoco">JaCoCo</a> 0.8.7.202105040129</span></div></body></html>
\ No newline at end of file |