1
package org.herac.tuxguitar.gui.tools.browser.filesystem;
4
import java.io.FileInputStream;
5
import java.io.FileNotFoundException;
6
import java.io.InputStream;
8
import org.herac.tuxguitar.gui.tools.browser.TGBrowserException;
9
import org.herac.tuxguitar.gui.tools.browser.base.TGBrowserElement;
11
public class TGBrowserElementImpl extends TGBrowserElement{
13
private TGBrowserElementImpl parent;
16
public TGBrowserElementImpl(TGBrowserElementImpl parent,File file) {
17
super(file.getName());
22
public File getFile() {
26
public TGBrowserElementImpl getParent() {
30
public boolean isFolder(){
31
return getFile().isDirectory();
34
public InputStream getInputStream()throws TGBrowserException {
37
return new FileInputStream(getFile());
38
} catch (FileNotFoundException e) {
39
throw new TGBrowserException(e);