package edu.chl.proton.model;

/**
 * @author Stina Werme
 * Created by stinawerme on 01/05/17.
 */
public class File extends FileSystemEntity {

    private Document document;

    public File(String name, Document document) {
        this.setName(name);
        this.document = document;
    }

    public File(String name, Document document, Folder parentFolder) {
        this(name, document);
        parentFolder.addFile(this);
    }

    protected Document getDocument() {
        return this.document;
    }

    protected void setDocument(Document document) {
        this.document = document;
    }

    // What should be saved? Shouldn't this be in document?
    protected void save(File file) {

    }

    protected boolean isSaved() {
        return true;
    }
}

@@ -143,16 +143,18 @@
  %7B%0A%0A    
+//
 private 
@@ -200,35 +200,16 @@
 ing name
-, Document document
 ) %7B%0A    
@@ -236,42 +236,8 @@
 e);%0A
-        this.document = document;%0A
     
@@ -271,27 +271,8 @@
 ame,
- Document document,
  Fol
@@ -307,23 +307,21 @@
 this
-(name, document
+.setName(name
 );%0A 
@@ -358,32 +358,34 @@
 is);%0A    %7D%0A%0A    
+//
 protected Docume
@@ -399,32 +399,34 @@
 ocument() %7B%0A    
+//
     return this.
@@ -435,31 +435,35 @@
 cument;%0A    
+//
 %7D%0A%0A    
+//
 protected vo
@@ -494,32 +494,34 @@
 document) %7B%0A    
+//
     this.documen
@@ -534,24 +534,26 @@
 cument;%0A    
+//
 %7D%0A%0A    // Wh
@@ -678,16 +678,25 @@
 isSaved(
+File file
 ) %7B%0A    

Remove things related to 'document'