blob: ea6a0be12d8749ec0ac5a4bdf2e06b9930d3e98a [file]
<!DOCTYPE html>
<html class="writer-html5" lang="en" >
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>pyarrow.fs.SubTreeFileSystem &mdash; Apache Arrow v2.0.0</title>
<link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<!--[if lt IE 9]>
<script src="../../_static/js/html5shiv.min.js"></script>
<![endif]-->
<script type="text/javascript" id="documentation_options" data-url_root="../../" src="../../_static/documentation_options.js"></script>
<script src="../../_static/jquery.js"></script>
<script src="../../_static/underscore.js"></script>
<script src="../../_static/doctools.js"></script>
<script src="../../_static/language_data.js"></script>
<script type="text/javascript" src="../../_static/js/theme.js"></script>
<link rel="canonical" href="https://arrow.apache.org/docs/python/generated/pyarrow.fs.SubTreeFileSystem.html" />
<link rel="index" title="Index" href="../../genindex.html" />
<link rel="search" title="Search" href="../../search.html" />
<link rel="next" title="pyarrow.fs.PyFileSystem" href="pyarrow.fs.PyFileSystem.html" />
<link rel="prev" title="pyarrow.fs.HadoopFileSystem" href="pyarrow.fs.HadoopFileSystem.html" />
<!-- Matomo -->
<script>
var _paq = window._paq = window._paq || [];
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */
_paq.push(["setDoNotTrack", true]);
_paq.push(["disableCookies"]);
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="https://analytics.apache.org/";
_paq.push(['setTrackerUrl', u+'matomo.php']);
_paq.push(['setSiteId', '20']);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
})();
</script>
<!-- End Matomo Code -->
</head>
<body class="wy-body-for-nav">
<div class="wy-grid-for-nav">
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<div class="wy-side-scroll">
<div class="wy-side-nav-search" >
<a href="../../index.html" class="icon icon-home" alt="Documentation Home"> Apache Arrow
</a>
<div class="version">
2.0.0
</div>
<div role="search">
<form id="rtd-search-form" class="wy-form" action="../../search.html" method="get">
<input type="text" name="q" placeholder="Search docs" />
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
</div>
</div>
<div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
<p class="caption"><span class="caption-text">Specifications and Protocols</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../format/Versioning.html">Format Versioning and Stability</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../format/Columnar.html">Arrow Columnar Format</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../format/Flight.html">Arrow Flight RPC</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../format/Integration.html">Integration Testing</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../format/CDataInterface.html">The Arrow C data interface</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../format/CStreamInterface.html">The Arrow C stream interface</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../format/Other.html">Other Data Structures</a></li>
</ul>
<p class="caption"><span class="caption-text">Libraries</span></p>
<ul class="current">
<li class="toctree-l1"><a class="reference internal" href="../../status.html">Implementation Status</a></li>
<li class="toctree-l1"><a class="reference external" href="https://arrow.apache.org/docs/c_glib/">C/GLib</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../cpp/index.html">C++</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/apache/arrow/blob/master/csharp/README.md">C#</a></li>
<li class="toctree-l1"><a class="reference external" href="https://godoc.org/github.com/apache/arrow/go/arrow">Go</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../java/index.html">Java</a></li>
<li class="toctree-l1"><a class="reference external" href="https://arrow.apache.org/docs/js/">JavaScript</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/apache/arrow/blob/master/matlab/README.md">MATLAB</a></li>
<li class="toctree-l1 current"><a class="reference internal" href="../index.html">Python</a><ul class="current">
<li class="toctree-l2"><a class="reference internal" href="../install.html">Installing PyArrow</a></li>
<li class="toctree-l2"><a class="reference internal" href="../memory.html">Memory and IO Interfaces</a></li>
<li class="toctree-l2"><a class="reference internal" href="../data.html">Data Types and In-Memory Data Model</a></li>
<li class="toctree-l2"><a class="reference internal" href="../compute.html">Compute Functions</a></li>
<li class="toctree-l2"><a class="reference internal" href="../ipc.html">Streaming, Serialization, and IPC</a></li>
<li class="toctree-l2"><a class="reference internal" href="../filesystems.html">Filesystem Interface</a></li>
<li class="toctree-l2"><a class="reference internal" href="../filesystems_deprecated.html">Filesystem Interface (legacy)</a></li>
<li class="toctree-l2"><a class="reference internal" href="../plasma.html">The Plasma In-Memory Object Store</a></li>
<li class="toctree-l2"><a class="reference internal" href="../numpy.html">NumPy Integration</a></li>
<li class="toctree-l2"><a class="reference internal" href="../pandas.html">Pandas Integration</a></li>
<li class="toctree-l2"><a class="reference internal" href="../timestamps.html">Timestamps</a></li>
<li class="toctree-l2"><a class="reference internal" href="../csv.html">Reading CSV files</a></li>
<li class="toctree-l2"><a class="reference internal" href="../feather.html">Feather File Format</a></li>
<li class="toctree-l2"><a class="reference internal" href="../json.html">Reading JSON files</a></li>
<li class="toctree-l2"><a class="reference internal" href="../parquet.html">Reading and Writing the Apache Parquet Format</a></li>
<li class="toctree-l2"><a class="reference internal" href="../dataset.html">Tabular Datasets</a></li>
<li class="toctree-l2"><a class="reference internal" href="../cuda.html">CUDA Integration</a></li>
<li class="toctree-l2"><a class="reference internal" href="../extending_types.html">Extending pyarrow</a></li>
<li class="toctree-l2"><a class="reference internal" href="../extending.html">Using pyarrow from C++ and Cython Code</a></li>
<li class="toctree-l2 current"><a class="reference internal" href="../api.html">API Reference</a><ul class="current">
<li class="toctree-l3"><a class="reference internal" href="../api/datatypes.html">Data Types and Schemas</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/arrays.html">Arrays and Scalars</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/memory.html">Buffers and Memory</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/compute.html">Compute Functions</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/files.html">Streams and File Access</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/tables.html">Tables and Tensors</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/ipc.html">Serialization and IPC</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/flight.html">Arrow Flight</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/formats.html">Tabular File Formats</a></li>
<li class="toctree-l3 current"><a class="reference internal" href="../api/filesystems.html">Filesystems</a><ul class="current">
<li class="toctree-l4"><a class="reference internal" href="../api/filesystems.html#interface">Interface</a></li>
<li class="toctree-l4 current"><a class="reference internal" href="../api/filesystems.html#concrete-subclasses">Concrete Subclasses</a></li>
</ul>
</li>
<li class="toctree-l3"><a class="reference internal" href="../api/dataset.html">Dataset</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/plasma.html">Plasma In-Memory Object Store</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/cuda.html">CUDA Integration</a></li>
<li class="toctree-l3"><a class="reference internal" href="../api/misc.html">Miscellaneous</a></li>
</ul>
</li>
<li class="toctree-l2"><a class="reference internal" href="../getting_involved.html">Getting Involved</a></li>
<li class="toctree-l2"><a class="reference internal" href="../benchmarks.html">Benchmarks</a></li>
</ul>
</li>
<li class="toctree-l1"><a class="reference external" href="https://arrow.apache.org/docs/r/">R</a></li>
<li class="toctree-l1"><a class="reference external" href="https://github.com/apache/arrow/blob/master/ruby/README.md">Ruby</a></li>
<li class="toctree-l1"><a class="reference external" href="https://docs.rs/crate/arrow/">Rust</a></li>
</ul>
<p class="caption"><span class="caption-text">Development</span></p>
<ul>
<li class="toctree-l1"><a class="reference internal" href="../../developers/contributing.html">Contributing to Apache Arrow</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../developers/cpp/index.html">C++ Development</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../developers/python.html">Python Development</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../developers/archery.html">Daily Development using Archery</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../developers/crossbow.html">Packaging and Testing with Crossbow</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../developers/docker.html">Running Docker Builds</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../developers/benchmarks.html">Benchmarks</a></li>
<li class="toctree-l1"><a class="reference internal" href="../../developers/documentation.html">Building the Documentation</a></li>
</ul>
</div>
</div>
</nav>
<section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
<nav class="wy-nav-top" aria-label="top navigation">
<i data-toggle="wy-nav-top" class="fa fa-bars"></i>
<a href="../../index.html">Apache Arrow</a>
</nav>
<div class="wy-nav-content">
<div class="rst-content">
<div role="navigation" aria-label="breadcrumbs navigation">
<ul class="wy-breadcrumbs">
<li><a href="../../index.html" class="icon icon-home"></a> &raquo;</li>
<li><a href="../index.html">Python bindings</a> &raquo;</li>
<li><a href="../api.html">API Reference</a> &raquo;</li>
<li><a href="../api/filesystems.html">Filesystems</a> &raquo;</li>
<li>pyarrow.fs.SubTreeFileSystem</li>
<li class="wy-breadcrumbs-aside">
<a href="../../_sources/python/generated/pyarrow.fs.SubTreeFileSystem.rst.txt" rel="nofollow"> View page source</a>
</li>
</ul>
<hr/>
</div>
<div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
<div itemprop="articleBody">
<div class="section" id="pyarrow-fs-subtreefilesystem">
<h1>pyarrow.fs.SubTreeFileSystem<a class="headerlink" href="#pyarrow-fs-subtreefilesystem" title="Permalink to this headline"></a></h1>
<dl class="py class">
<dt id="pyarrow.fs.SubTreeFileSystem">
<em class="property">class </em><code class="sig-prename descclassname">pyarrow.fs.</code><code class="sig-name descname">SubTreeFileSystem</code><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem" title="Permalink to this definition"></a></dt>
<dd><p>Bases: <code class="xref py py-class docutils literal notranslate"><span class="pre">pyarrow._fs.FileSystem</span></code></p>
<p>Delegates to another implementation after prepending a fixed base path.</p>
<p>This is useful to expose a logical view of a subtree of a filesystem,
for example a directory in a LocalFileSystem.</p>
<p>Note, that this makes no security guarantee. For example, symlinks may
allow to “escape” the subtree and access other parts of the underlying
filesystem.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>base_path</strong> (<em>str</em>) – The root of the subtree.</p></li>
<li><p><strong>base_fs</strong> (<a class="reference internal" href="pyarrow.fs.FileSystem.html#pyarrow.fs.FileSystem" title="pyarrow.fs.FileSystem"><em>FileSystem</em></a>) – FileSystem object the operations delegated to.</p></li>
</ul>
</dd>
</dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.__init__">
<code class="sig-name descname">__init__</code><span class="sig-paren">(</span><em class="sig-param"><span class="o">*</span><span class="n">args</span></em>, <em class="sig-param"><span class="o">**</span><span class="n">kwargs</span></em><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.__init__" title="Permalink to this definition"></a></dt>
<dd><p>Initialize self. See help(type(self)) for accurate signature.</p>
</dd></dl>
<p class="rubric">Methods</p>
<table class="longtable docutils align-default">
<colgroup>
<col style="width: 10%" />
<col style="width: 90%" />
</colgroup>
<tbody>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.__init__" title="pyarrow.fs.SubTreeFileSystem.__init__"><code class="xref py py-obj docutils literal notranslate"><span class="pre">__init__</span></code></a>(*args, **kwargs)</p></td>
<td><p>Initialize self.</p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.copy_file" title="pyarrow.fs.SubTreeFileSystem.copy_file"><code class="xref py py-obj docutils literal notranslate"><span class="pre">copy_file</span></code></a></p></td>
<td><p>Copy a file.</p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.create_dir" title="pyarrow.fs.SubTreeFileSystem.create_dir"><code class="xref py py-obj docutils literal notranslate"><span class="pre">create_dir</span></code></a></p></td>
<td><p>Create a directory and subdirectories.</p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.delete_dir" title="pyarrow.fs.SubTreeFileSystem.delete_dir"><code class="xref py py-obj docutils literal notranslate"><span class="pre">delete_dir</span></code></a></p></td>
<td><p>Delete a directory and its contents, recursively.</p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.delete_dir_contents" title="pyarrow.fs.SubTreeFileSystem.delete_dir_contents"><code class="xref py py-obj docutils literal notranslate"><span class="pre">delete_dir_contents</span></code></a></p></td>
<td><p>Delete a directory’s contents, recursively.</p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.delete_file" title="pyarrow.fs.SubTreeFileSystem.delete_file"><code class="xref py py-obj docutils literal notranslate"><span class="pre">delete_file</span></code></a></p></td>
<td><p>Delete a file.</p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.equals" title="pyarrow.fs.SubTreeFileSystem.equals"><code class="xref py py-obj docutils literal notranslate"><span class="pre">equals</span></code></a></p></td>
<td><p></p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.from_uri" title="pyarrow.fs.SubTreeFileSystem.from_uri"><code class="xref py py-obj docutils literal notranslate"><span class="pre">from_uri</span></code></a></p></td>
<td><p>Create a new FileSystem from URI or Path.</p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.get_file_info" title="pyarrow.fs.SubTreeFileSystem.get_file_info"><code class="xref py py-obj docutils literal notranslate"><span class="pre">get_file_info</span></code></a></p></td>
<td><p>Get info for the given files.</p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.move" title="pyarrow.fs.SubTreeFileSystem.move"><code class="xref py py-obj docutils literal notranslate"><span class="pre">move</span></code></a></p></td>
<td><p>Move / rename a file or directory.</p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.normalize_path" title="pyarrow.fs.SubTreeFileSystem.normalize_path"><code class="xref py py-obj docutils literal notranslate"><span class="pre">normalize_path</span></code></a></p></td>
<td><p>Normalize filesystem path.</p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.open_append_stream" title="pyarrow.fs.SubTreeFileSystem.open_append_stream"><code class="xref py py-obj docutils literal notranslate"><span class="pre">open_append_stream</span></code></a></p></td>
<td><p>Open an output stream for appending.</p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.open_input_file" title="pyarrow.fs.SubTreeFileSystem.open_input_file"><code class="xref py py-obj docutils literal notranslate"><span class="pre">open_input_file</span></code></a></p></td>
<td><p>Open an input file for random access reading.</p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.open_input_stream" title="pyarrow.fs.SubTreeFileSystem.open_input_stream"><code class="xref py py-obj docutils literal notranslate"><span class="pre">open_input_stream</span></code></a></p></td>
<td><p>Open an input stream for sequential reading.</p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.open_output_stream" title="pyarrow.fs.SubTreeFileSystem.open_output_stream"><code class="xref py py-obj docutils literal notranslate"><span class="pre">open_output_stream</span></code></a></p></td>
<td><p>Open an output stream for sequential writing.</p></td>
</tr>
</tbody>
</table>
<p class="rubric">Attributes</p>
<table class="longtable docutils align-default">
<colgroup>
<col style="width: 10%" />
<col style="width: 90%" />
</colgroup>
<tbody>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.base_fs" title="pyarrow.fs.SubTreeFileSystem.base_fs"><code class="xref py py-obj docutils literal notranslate"><span class="pre">base_fs</span></code></a></p></td>
<td><p></p></td>
</tr>
<tr class="row-even"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.base_path" title="pyarrow.fs.SubTreeFileSystem.base_path"><code class="xref py py-obj docutils literal notranslate"><span class="pre">base_path</span></code></a></p></td>
<td><p></p></td>
</tr>
<tr class="row-odd"><td><p><a class="reference internal" href="#pyarrow.fs.SubTreeFileSystem.type_name" title="pyarrow.fs.SubTreeFileSystem.type_name"><code class="xref py py-obj docutils literal notranslate"><span class="pre">type_name</span></code></a></p></td>
<td><p>The filesystem’s type name.</p></td>
</tr>
</tbody>
</table>
<dl class="py attribute">
<dt id="pyarrow.fs.SubTreeFileSystem.base_fs">
<code class="sig-name descname">base_fs</code><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.base_fs" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py attribute">
<dt id="pyarrow.fs.SubTreeFileSystem.base_path">
<code class="sig-name descname">base_path</code><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.base_path" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.copy_file">
<code class="sig-name descname">copy_file</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.copy_file" title="Permalink to this definition"></a></dt>
<dd><p>Copy a file.</p>
<p>If the destination exists and is a directory, an error is returned.
Otherwise, it is replaced.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>src</strong> (<em>str</em>) – The path of the file to be copied from.</p></li>
<li><p><strong>dest</strong> (<em>str</em>) – The destination path where the file is copied to.</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.create_dir">
<code class="sig-name descname">create_dir</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.create_dir" title="Permalink to this definition"></a></dt>
<dd><p>Create a directory and subdirectories.</p>
<p>This function succeeds if the directory already exists.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>path</strong> (<em>str</em>) – The path of the new directory.</p></li>
<li><p><strong>recursive</strong> (<em>bool</em><em>, </em><em>default True</em>) – Create nested directories as well.</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.delete_dir">
<code class="sig-name descname">delete_dir</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.delete_dir" title="Permalink to this definition"></a></dt>
<dd><p>Delete a directory and its contents, recursively.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – The path of the directory to be deleted.</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.delete_dir_contents">
<code class="sig-name descname">delete_dir_contents</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.delete_dir_contents" title="Permalink to this definition"></a></dt>
<dd><p>Delete a directory’s contents, recursively.</p>
<p>Like delete_dir, but doesn’t delete the directory itself.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>path</strong> (<em>str</em>) – The path of the directory to be deleted.</p></li>
<li><p><strong>accept_root_dir</strong> (<em>boolean</em><em>, </em><em>default False</em>) – Allow deleting the root directory’s contents
(if path is empty or “/”)</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.delete_file">
<code class="sig-name descname">delete_file</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.delete_file" title="Permalink to this definition"></a></dt>
<dd><p>Delete a file.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – The path of the file to be deleted.</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.equals">
<code class="sig-name descname">equals</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.equals" title="Permalink to this definition"></a></dt>
<dd></dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.from_uri">
<em class="property">static </em><code class="sig-name descname">from_uri</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.from_uri" title="Permalink to this definition"></a></dt>
<dd><p>Create a new FileSystem from URI or Path.</p>
<p>Recognized URI schemes are “file”, “mock”, “s3fs”, “hdfs” and “viewfs”.
In addition, the argument can be a pathlib.Path object, or a string
describing an absolute local path.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>uri</strong> (<em>string</em>) – URI-based path, for example: <a class="reference external" href="file:///some/local/path">file:///some/local/path</a>.</p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><ul class="simple">
<li><p><em>With (filesystem, path) tuple where path is the abstract path inside</em></p></li>
<li><p><em>the FileSystem instance.</em></p></li>
</ul>
</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.get_file_info">
<code class="sig-name descname">get_file_info</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.get_file_info" title="Permalink to this definition"></a></dt>
<dd><p>Get info for the given files.</p>
<p>Any symlink is automatically dereferenced, recursively. A non-existing
or unreachable file returns a FileStat object and has a FileType of
value NotFound. An exception indicates a truly exceptional condition
(low-level I/O error, etc.).</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>paths_or_selector</strong> (<a class="reference internal" href="pyarrow.fs.FileSelector.html#pyarrow.fs.FileSelector" title="pyarrow.fs.FileSelector"><em>FileSelector</em></a><em>, </em><em>path-like</em><em> or </em><em>list of path-likes</em>) – Either a selector object, a path-like object or a list of
path-like objects. The selector’s base directory will not be
part of the results, even if it exists. If it doesn’t exist,
use <cite>allow_not_found</cite>.</p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><em>FileInfo or list of FileInfo</em> – Single FileInfo object is returned for a single path, otherwise
a list of FileInfo objects is returned.</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.move">
<code class="sig-name descname">move</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.move" title="Permalink to this definition"></a></dt>
<dd><p>Move / rename a file or directory.</p>
<p>If the destination exists:
- if it is a non-empty directory, an error is returned
- otherwise, if it has the same type as the source, it is replaced
- otherwise, behavior is unspecified (implementation-dependent).</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>src</strong> (<em>str</em>) – The path of the file or the directory to be moved.</p></li>
<li><p><strong>dest</strong> (<em>str</em>) – The destination path where the file or directory is moved to.</p></li>
</ul>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.normalize_path">
<code class="sig-name descname">normalize_path</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.normalize_path" title="Permalink to this definition"></a></dt>
<dd><p>Normalize filesystem path.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – The path to normalize</p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><strong>normalized_path</strong> (<em>str</em>) – The normalized path</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.open_append_stream">
<code class="sig-name descname">open_append_stream</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.open_append_stream" title="Permalink to this definition"></a></dt>
<dd><p>Open an output stream for appending.</p>
<p>If the target doesn’t exist, a new empty file is created.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>path</strong> (<em>str</em>) – The source to open for writing.</p></li>
<li><p><strong>compression</strong> (<em>str optional</em><em>, </em><em>default 'detect'</em>) – The compression algorithm to use for on-the-fly compression.
If “detect” and source is a file path, then compression will be
chosen based on the file extension.
If None, no compression will be applied. Otherwise, a well-known
algorithm name must be supplied (e.g. “gzip”).</p></li>
<li><p><strong>buffer_size</strong> (<em>int optional</em><em>, </em><em>default None</em>) – If None or 0, no buffering will happen. Otherwise the size of the
temporary write buffer.</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><strong>stream</strong> (<em>NativeFile</em>)</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.open_input_file">
<code class="sig-name descname">open_input_file</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.open_input_file" title="Permalink to this definition"></a></dt>
<dd><p>Open an input file for random access reading.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><p><strong>path</strong> (<em>str</em>) – The source to open for reading.</p>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><strong>stram</strong> (<em>NativeFile</em>)</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.open_input_stream">
<code class="sig-name descname">open_input_stream</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.open_input_stream" title="Permalink to this definition"></a></dt>
<dd><p>Open an input stream for sequential reading.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>source</strong> (<em>str</em>) – The source to open for reading.</p></li>
<li><p><strong>compression</strong> (<em>str optional</em><em>, </em><em>default 'detect'</em>) – The compression algorithm to use for on-the-fly decompression.
If “detect” and source is a file path, then compression will be
chosen based on the file extension.
If None, no compression will be applied. Otherwise, a well-known
algorithm name must be supplied (e.g. “gzip”).</p></li>
<li><p><strong>buffer_size</strong> (<em>int optional</em><em>, </em><em>default None</em>) – If None or 0, no buffering will happen. Otherwise the size of the
temporary read buffer.</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><strong>stream</strong> (<em>NativeFile</em>)</p>
</dd>
</dl>
</dd></dl>
<dl class="py method">
<dt id="pyarrow.fs.SubTreeFileSystem.open_output_stream">
<code class="sig-name descname">open_output_stream</code><span class="sig-paren">(</span><span class="sig-paren">)</span><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.open_output_stream" title="Permalink to this definition"></a></dt>
<dd><p>Open an output stream for sequential writing.</p>
<p>If the target already exists, existing data is truncated.</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters</dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>path</strong> (<em>str</em>) – The source to open for writing.</p></li>
<li><p><strong>compression</strong> (<em>str optional</em><em>, </em><em>default 'detect'</em>) – The compression algorithm to use for on-the-fly compression.
If “detect” and source is a file path, then compression will be
chosen based on the file extension.
If None, no compression will be applied. Otherwise, a well-known
algorithm name must be supplied (e.g. “gzip”).</p></li>
<li><p><strong>buffer_size</strong> (<em>int optional</em><em>, </em><em>default None</em>) – If None or 0, no buffering will happen. Otherwise the size of the
temporary write buffer.</p></li>
</ul>
</dd>
<dt class="field-even">Returns</dt>
<dd class="field-even"><p><strong>stream</strong> (<em>NativeFile</em>)</p>
</dd>
</dl>
</dd></dl>
<dl class="py attribute">
<dt id="pyarrow.fs.SubTreeFileSystem.type_name">
<code class="sig-name descname">type_name</code><a class="headerlink" href="#pyarrow.fs.SubTreeFileSystem.type_name" title="Permalink to this definition"></a></dt>
<dd><p>The filesystem’s type name.</p>
</dd></dl>
</dd></dl>
</div>
</div>
</div>
<footer>
<div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
<a href="pyarrow.fs.PyFileSystem.html" class="btn btn-neutral float-right" title="pyarrow.fs.PyFileSystem" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
<a href="pyarrow.fs.HadoopFileSystem.html" class="btn btn-neutral float-left" title="pyarrow.fs.HadoopFileSystem" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
</div>
<hr/>
<div role="contentinfo">
<p>
&copy; Copyright 2016-2019 Apache Software Foundation
</p>
</div>
Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a
<a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a>
provided by <a href="https://readthedocs.org">Read the Docs</a>.
</footer>
</div>
</div>
</section>
</div>
<script type="text/javascript">
jQuery(function () {
SphinxRtdTheme.Navigation.enable(true);
});
</script>
<script type="text/javascript" src="/docs/_static/versionwarning.js"></script></body>
</html>