//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by FernFlower decompiler)
//

package kinosearch.core;

import kinosearch.core.warez.KinoWarez;

public class Kino {
    private String name;
    private String url;
    private boolean player = false;
    private KinoWarez kinowarez;

    public Kino(String name, String url, KinoWarez kinoWarez) {
        this.name = name;
        this.url = url;
        this.kinowarez = kinoWarez;
    }

    public String getName() {
        return this.name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getUrl() {
        return this.url;
    }

    public boolean hasPlayer() {
        return this.player;
    }

    public void setPlayer(boolean value) {
        this.player = value;
    }

    public KinoWarez getKinowarez() {
        return this.kinowarez;
    }

    public String getPlayerUrl() {
        if (this.player) {
            String path = this.url.substring(this.kinowarez.getDomain().length());
            return this.kinowarez.getName().toLowerCase() + path;
        } else {
            return "#";
        }
    }
}
