class HentaiCafeRipper extends AbstractHTMLRipper {

    public HentaiCafeRipper(URL url) throws IOException {
        super(url);
    }

        @Override
        public String getHost() {
            return "hentai";
        }

        @Override
        public String getDomain() {
            return "hentai.cafe";
        }

        @Override
        public String getGID(URL url) throws MalformedURLException {
            Pattern p = Pattern.compile("https?://hentai\\.cafe/([a-zA-Z0-9_\\-%]*)/?$");
            Matcher m = p.matcher(url.toExternalForm());
            if (m.matches()) {
                return m.group(1);
            }
            throw new MalformedURLException("Expected hentai.cafe URL format: " +
                            "hentai.cafe/COMIC - got " + url + " instead");
        }

        @Override
        public Document getFirstPage() throws IOException {
            // "url" is an instance field of the superclass
            Document tempDoc = Http.url(url).get();
            String firstPageUrl = tempDoc.select("div.last > p > a.x-btn").attr("href");
            // workaround for https://github.com/RipMeApp/ripme/issues/1083
            if (firstPageUrl.contains("<br />")) {
                firstPageUrl = firstPageUrl.replaceAll("<br />", "");
            }
            return Http.url(firstPageUrl).get();
        }

        @Override
        public Document getNextPage(Document doc) throws IOException {
            String nextPageURL = doc.select("div[id=page] > div.inner > a").attr("href");
            int totalPages = Integer.parseInt(doc.select("div.panel > div.topbar > div > div.topbar_right > div.tbtitle > div.text").text().replace(" ⤵", ""));
            String[] nextPageURLSplite = nextPageURL.split("/");
            // This checks if the next page number is greater than the total number of pages
            if (totalPages >= Integer.parseInt(nextPageURLSplite[nextPageURLSplite.length -1])) {
                return Http.url(nextPageURL).get();
            }
            throw new IOException("No more pages");
        }

        @Override
        public List<String> getURLsFromPage(Document doc) {<FILL_FUNCTION_BODY>}

        @Override
        public void downloadURL(URL url, int index) {
            addURLToDownload(url, getPrefix(index));
        }
    }

            List<String> result = new ArrayList<>();
                result.add(doc.select("div[id=page] > div.inner > a > img.open").attr("src"));
                return result;
        
<methods>public boolean addURLToDownload(java.net.URL, java.io.File, java.lang.String, Map<java.lang.String,java.lang.String>, java.lang.Boolean) ,public boolean addURLToDownload(java.net.URL, java.io.File) ,public boolean canRip(java.net.URL) ,public void downloadCompleted(java.net.URL, java.io.File) ,public void downloadErrored(java.net.URL, java.lang.String) ,public void downloadExists(java.net.URL, java.io.File) ,public int getCompletionPercentage() ,public int getCount() ,public abstract java.lang.String getHost() ,public Document getNextPage(Document) throws java.io.IOException,public java.lang.String getStatusText() ,public void rip() throws java.io.IOException,public java.net.URL sanitizeURL(java.net.URL) throws java.net.MalformedURLException,public boolean saveText(java.net.URL, java.lang.String, java.lang.String, int) ,public void setWorkingDir(java.net.URL) throws java.io.IOException<variables>private Map<java.net.URL,java.io.File> itemsCompleted,private Map<java.net.URL,java.lang.String> itemsErrored,private Map<java.net.URL,java.io.File> itemsPending