/* 
 * Diplomová práce ÚSI VUT 
 * Forenzní analýza webového prohlížeče
 *
 * Autor: Michal Bača
 * Datum: 20.5.2015
 */
package yafft.FFModel;

import javafx.collections.FXCollections;
import javafx.collections.ObservableList;
import yafft.FFModel.ModelItems.Bookmark;
import yafft.FFModel.ModelItems.Cookie;
import yafft.FFModel.ModelItems.CookieValue;
import yafft.FFModel.ModelItems.DownloadsItem;
import yafft.FFModel.ModelItems.FormItem;
import yafft.FFModel.ModelItems.HistoryItem;
import yafft.FFModel.ModelItems.PasswordItem;

/**
 *
 * @author michal
 */
public class Model {

    private ObservableList<HistoryItem> history = FXCollections.observableArrayList();
    private ObservableList<DownloadsItem> downloads = FXCollections.observableArrayList();
    private ObservableList<Cookie> cookies = FXCollections.observableArrayList();
    private ObservableList<FormItem> forms = FXCollections.observableArrayList();
    private ObservableList<Bookmark> bookmarks = FXCollections.observableArrayList();

    private ObservableList<CookieValue> cookies2 = FXCollections.observableArrayList();
    private ObservableList<PasswordItem> passwords = FXCollections.observableArrayList();

    /**
     *
     */
    public Model() {
    }

    public ObservableList<PasswordItem> getPasswords() {
        return passwords;
    }

    public void setPasswords(ObservableList<PasswordItem> passwords) {
        this.passwords = passwords;
    }

    public void printPasswords() {
        System.out.println("\nPasswords:");
        for (PasswordItem p : this.passwords) {
            System.out.println(p);

        }
    }

    /**
     *
     * @return
     */
    public ObservableList<HistoryItem> getHistory() {
        return history;
    }

    /**
     *
     * @param list
     */
    public void setHistory(ObservableList<HistoryItem> list) {
        this.history = list;
    }

    /**
     *
     */
    public void printHistory() {
        for (HistoryItem item : this.history) {
            System.out.print(item);
        }

    }

    //model.fill
    //model.export
    public ObservableList<DownloadsItem> getDownloads() {
        return downloads;
    }

    public void setDownloads(ObservableList<DownloadsItem> downloads) {
        this.downloads = downloads;
    }

    public void printDownloads() {
        System.out.println("\nDownloaded files: ");
        for (DownloadsItem item : this.downloads) {
            System.out.println(item);
        }
    }

    public ObservableList<CookieValue> getCookies2() {
        return cookies2;
    }

    public void setCookies2(ObservableList<CookieValue> cookies2) {
        this.cookies2 = cookies2;
    }

    public void printCookies2() {
        System.out.println("\nCookies: ");
        for (CookieValue item : this.cookies2) {
            System.out.println(item);
        }
    }

    public ObservableList<Cookie> getCookies() {
        return this.cookies;
    }

    public void setCookies(ObservableList<Cookie> cookies) {
        this.cookies = cookies;
    }

    public void printCookies() {
        System.out.println("\nCookies: ");
        for (Cookie item : this.cookies) {
            System.out.println(item);
        }
    }

    public ObservableList<FormItem> getForms() {
        return forms;
    }

    public void setForms(ObservableList<FormItem> forms) {
        this.forms = forms;
    }

    public void printForms() {
        System.out.println("\nFomrs: ");
        for (FormItem item : this.forms) {
            System.out.println(item);
        }
    }

    public ObservableList<Bookmark> getBookmarks() {
        return bookmarks;
    }

    public void setBookmarks(ObservableList<Bookmark> bookmarks) {
        this.bookmarks = bookmarks;
    }

    public void printBookmarks() {
        System.out.println("\nBookmarks: ");
        for (Bookmark item : this.bookmarks) {
            System.out.println(item);
        }
    }

}
