} catch (URISyntaxException e) { env.warning(e); } finally { try { if (in != null) in.close(); } catch (IOException e) { env.warning(e); }
  public static Value get_meta_tags(Env env, String filename,                                     @Optional("false") boolean use_include_path)  {    Path file = null;    ArrayValue result = new ArrayValueImpl();        if (use_include_path) {      String [] includePaths = env.getIni("include_path").toString().split(":");      for (String includePath : includePaths) {        Path oldPath = Vfs.getPwd();        Path newPath = oldPath.lookup(includePath);        if (! newPath.exists())          break;        Vfs.setPwd(newPath);        // can only be a local file        file = Vfs.lookupNative(filename);        Vfs.setPwd(oldPath);        if (file.exists())          break;      }    } else      file = Vfs.lookup(filename);        if (file == null || ! file.exists())      return result;    try {      InputStream in = file.openRead();      PushbackReader reader = new PushbackReader(new InputStreamReader(in));      while (reader.ready()) {        String tag = getNextTag(reader);        if (tag.equalsIgnoreCase("meta")) {          String name = null;          String content = null;          String [] attr;          while ((attr = getNextAttribute(reader)) != null) {            if (name == null && attr[0].equalsIgnoreCase("name")) {              if (attr.length > 1)                name = attr[1];            } else if (content == null && attr[0].equalsIgnoreCase("content")) {              if (attr.length > 1)                content = attr[1];            }            if (name != null && content != null) {              result.put(new StringValueImpl(name),                          new StringValueImpl(content));              break;            }          }        } else if (tag.equalsIgnoreCase("/head"))          break;      }    } catch (IOException e) {      env.warning(e);    }    return result;  }