TileSet ext = unmarshalTilesetFile(xmlPath + set.getSource());
TileSet ext = unmarshalTilesetFile(new FileInputStream(xmlPath + set.getSource()));
    private TileSet unmarshalTileset(Node t) throws Exception {        TileSet set = null;        try {            set = (TileSet)unmarshalClass(TileSet.class, t);        } catch (Exception e) {            e.printStackTrace();        }        int tileWidth = getAttribute(t, "tilewidth", 0);        int tileHeight = getAttribute(t, "tileheight", 0);        int tileSpacing = getAttribute(t, "spacing", 0);        if (set.getSource() != null) {            TileSet ext = unmarshalTilesetFile(xmlPath + set.getSource());            ext.setFirstGid(set.getFirstGid());            return ext;        } else {            NodeList children = t.getChildNodes();            for (int i = 0; i < children.getLength(); i++) {                Node child = children.item(i);                if (child.getNodeName().equalsIgnoreCase("tile")) {                    set.addTile(unmarshalTile(child));                } else if (child.getNodeName().equalsIgnoreCase("image")) {                    String source = getAttributeValue(child, "source");                    File sourceFile = new File(source);                    String sourcePath;                    if (sourceFile.getAbsolutePath().equals(source)) {                        sourcePath = sourceFile.getCanonicalPath();                    } else {                        sourcePath =                            new File(xmlPath + source).getCanonicalPath();                    }                    set.importTileBitmap(sourcePath,                            tileWidth, tileHeight, tileSpacing);                    // There can be only one image element                    break;                }            }        }        return set;    }