<!DOCTYPE html>
<html>
<head>
	<meta charset="utf-8">

	<title>Class AMI_Tx_Cmd_Storage_Copier | PHPOID - Amiro.CMS functionality extension</title>

	<link rel="stylesheet" href="resources/style.css?95ada9fb523b6ab4fd1c47bb375f713f2cc65542">

</head>

<body>
<div id="left">
	<div id="menu">
		<a href="index.html" title="Overview"><span>Overview</span></a>


		<div id="groups">
		</div>



		<div id="elements">
			<h3>Classes</h3>
			<ul>
				<li><a href="class-AMI_Tx.html">AMI_Tx</a></li>
				<li><a href="class-AMI_Tx_Cmd.html">AMI_Tx_Cmd</a></li>
				<li><a href="class-AMI_Tx_Cmd_Args.html">AMI_Tx_Cmd_Args</a></li>
				<li><a href="class-AMI_Tx_Cmd_INI_ContentInstall.html">AMI_Tx_Cmd_INI_ContentInstall</a></li>
				<li><a href="class-AMI_Tx_Cmd_INI_ContentModifier.html">AMI_Tx_Cmd_INI_ContentModifier</a></li>
				<li><a href="class-AMI_Tx_Cmd_INI_ContentUninstall.html">AMI_Tx_Cmd_INI_ContentUninstall</a></li>
				<li><a href="class-AMI_Tx_Cmd_PHP_ContentIntsall.html">AMI_Tx_Cmd_PHP_ContentIntsall</a></li>
				<li><a href="class-AMI_Tx_Cmd_PHP_ContentModifier.html">AMI_Tx_Cmd_PHP_ContentModifier</a></li>
				<li><a href="class-AMI_Tx_Cmd_PHP_ContentUninstall.html">AMI_Tx_Cmd_PHP_ContentUninstall</a></li>
				<li><a href="class-AMI_Tx_Cmd_Storage.html">AMI_Tx_Cmd_Storage</a></li>
				<li><a href="class-AMI_Tx_Cmd_Storage_Cleaner.html">AMI_Tx_Cmd_Storage_Cleaner</a></li>
				<li><a href="class-AMI_Tx_Cmd_Storage_ContentModifier.html">AMI_Tx_Cmd_Storage_ContentModifier</a></li>
				<li><a href="class-AMI_Tx_Cmd_Storage_ContentSetter.html">AMI_Tx_Cmd_Storage_ContentSetter</a></li>
				<li class="active"><a href="class-AMI_Tx_Cmd_Storage_Copier.html">AMI_Tx_Cmd_Storage_Copier</a></li>
				<li><a href="class-AMI_Tx_Cmd_Tpl_ContentInstall.html">AMI_Tx_Cmd_Tpl_ContentInstall</a></li>
				<li><a href="class-AMI_Tx_Cmd_Tpl_ContentModifier.html">AMI_Tx_Cmd_Tpl_ContentModifier</a></li>
				<li><a href="class-AMI_Tx_Cmd_Tpl_ContentUninstall.html">AMI_Tx_Cmd_Tpl_ContentUninstall</a></li>
				<li><a href="class-AMI_Tx_DB.html">AMI_Tx_DB</a></li>
				<li><a href="class-AMI_Tx_Storage.html">AMI_Tx_Storage</a></li>
				<li><a href="class-PHPOID_Distribution_TemplateUpdater.html">PHPOID_Distribution_TemplateUpdater</a></li>
				<li><a href="class-PHPOID_Distribution_Tx_Cmd_CSS_ContentIntsall.html">PHPOID_Distribution_Tx_Cmd_CSS_ContentIntsall</a></li>
				<li><a href="class-PHPOID_Distribution_Tx_Cmd_CSS_ContentModifier.html">PHPOID_Distribution_Tx_Cmd_CSS_ContentModifier</a></li>
				<li><a href="class-PHPOID_Distribution_Tx_Cmd_CSS_ContentUninstall.html">PHPOID_Distribution_Tx_Cmd_CSS_ContentUninstall</a></li>
			</ul>

			<h3>Interfaces</h3>
			<ul>
				<li><a href="class-AMI_iTx.html">AMI_iTx</a></li>
				<li><a href="class-AMI_iTx_Cmd.html">AMI_iTx_Cmd</a></li>
			</ul>


			<h3>Exceptions</h3>
			<ul>
				<li><a href="class-AMI_Exception.html">AMI_Exception</a></li>
				<li><a href="class-AMI_Tx_Exception.html">AMI_Tx_Exception</a></li>
			</ul>


		</div>
	</div>
</div>

<div id="splitter"></div>

<div id="right">
<div id="rightInner">
	<form id="search">
		<input type="hidden" name="cx" value="">
		<input type="hidden" name="ie" value="UTF-8">
		<input type="text" name="q" class="text" placeholder="Search">
	</form>

	<div id="navigation">
		<ul>
			<li>
				<a href="index.html" title="Overview"><span>Overview</span></a>
			</li>
			<li class="active">
<span>Class</span>			</li>
		</ul>
		<ul>
			<li>
				<a href="tree.html" title="Tree view of classes, interfaces, traits and exceptions"><span>Tree</span></a>
			</li>
				<li>
					<a href="annotation-group-todo.html" title="List of elements with todo annotation">
						<span>Todo</span>
					</a>
				</li>
		</ul>
		<ul>
		</ul>
	</div>

<div id="content" class="class">
	<h1>Class AMI_Tx_Cmd_Storage_Copier</h1>


	<div class="description">
	<p>Storage data copier transaction command.</p>

<p>Sets content to target.
Example:</p>

<pre><span class="php-comment">// &quot;install_after.php&quot; / &quot;install.php&quot; context</span>

<span class="php-var">$srcPath</span> = <span class="php-keyword2">dirname</span>(__FILE__) . <span class="php-quote">'/'</span>;
<span class="php-var">$destPath</span> = AMI_Registry::get(<span class="php-quote">'path/root'</span>) . <span class="php-quote">'_local/eshop/'</span>;

<span class="php-var">$oStorage</span> = AMI::getResource(<span class="php-quote">'storage/fs'</span>);

<span class="php-var">$file</span> = <span class="php-quote">'AtoPaymentSystem.php'</span>;

<span class="php-var">$oArgs</span> = <span class="php-keyword1">new</span> AMI_Tx_Cmd_Args(
    <span class="php-keyword1">array</span>(
        <span class="php-comment">// Installation mode</span>
        <span class="php-quote">'mode'</span>     =&gt; AMI_iTx_Cmd::MODE_APPEND,
        <span class="php-comment">// Source file path</span>
        <span class="php-quote">'source'</span>   =&gt; <span class="php-var">$srcPath</span> . <span class="php-var">$file</span>,
        <span class="php-comment">// Target file path</span>
        <span class="php-quote">'target'</span>   =&gt; <span class="php-var">$destPath</span> . <span class="php-var">$file</span>,
        <span class="php-comment">// Storage driver</span>
        <span class="php-quote">'oStorage'</span> =&gt; <span class="php-var">$oStorage</span>
    )
);
<span class="php-var">$this</span>-&gt;aTx[<span class="php-quote">'storage'</span>]-&gt;addCommand(<span class="php-quote">'storage/set'</span>, <span class="php-var">$oArgs</span>);

<span class="php-comment">// File 'AtoPaymentSystem.php' contains PHP code starting from opening PHP tag</span></pre>
	</div>

	<dl class="tree">
		<dd style="padding-left:0px">
			<a href="class-AMI_Tx_Cmd.html"><span>AMI_Tx_Cmd</span></a>
			
			 implements 
				<a href="class-AMI_iTx_Cmd.html"><span>AMI_iTx_Cmd</span></a>
			
			
		</dd>
		<dd style="padding-left:30px">
			<img src="resources/inherit.png" alt="Extended by">
			<a href="class-AMI_Tx_Cmd_Storage.html"><span>AMI_Tx_Cmd_Storage</span></a>
			
			
			
		</dd>
		<dd style="padding-left:60px">
			<img src="resources/inherit.png" alt="Extended by">
<b><span>AMI_Tx_Cmd_Storage_Copier</span></b>			
			
			
		</dd>
	</dl>








	<div class="info">
		
		
		
		<b>Package:</b> TxCommand\Controller<br>

				<b>Copyright:</b>
				Amiro.CMS. All rights reserved. The changes are undesirable and dangerous.<br>
				<b>Since:</b>
				6.0.2<br>
				<b>Resource:</b>
				<p>tx/cmd/storage/copy</p>

<pre>AMI::getResource(<span class="php-quote">'tx/cmd/storage/copy'</span>)</pre><br>
			<b>Located at</b> <a href="source-class-AMI_Tx_Cmd_Storage_Copier.html#342-400" title="Go to source code">PHPOID/Distribution/AMI_Tx_Cmd_Storage.php</a>
		<br>
	</div>



	<table class="summary methods" id="methods">
	<caption>Methods summary</caption>
	<tr data-order="validateArgs" id="_validateArgs">

		<td class="attributes"><code>
			 protected 

			
			
			</code>
		</td>

		<td class="name"><div>
		<a class="anchor" href="#_validateArgs">#</a>
		<code><a href="source-class-AMI_Tx_Cmd_Storage_Copier.html#380-390" title="Go to source code">validateArgs</a>( )</code>

		<div class="description short">
			<p>Validates passed arguments.</p>
		</div>

		<div class="description detailed hidden">
			<p>Validates passed arguments.</p>




				<h4>Throws</h4>
				<div class="list">
					<code><a href="class-AMI_Tx_Exception.html">AMI_Tx_Exception</a></code><br>In case of problems.
				</div>

				<h4>See</h4>
				<div class="list">
						<code><a href="class-AMI_Tx_Cmd.html#___construct">AMI_Tx_Cmd::__construct()</a></code><br>
				</div>

				<h4>Overrides</h4>
				<div class="list"><code><a href="class-AMI_Tx_Cmd_Storage.html#_validateArgs">AMI_Tx_Cmd_Storage::validateArgs()</a></code></div>

		</div>
		</div></td>
	</tr>
	<tr data-order="run" id="_run">

		<td class="attributes"><code>
			 protected 

			
			
			</code>
		</td>

		<td class="name"><div>
		<a class="anchor" href="#_run">#</a>
		<code><a href="source-class-AMI_Tx_Cmd_Storage_Copier.html#392-399" title="Go to source code">run</a>( )</code>

		<div class="description short">
			<p>Runs command.</p>
		</div>

		<div class="description detailed hidden">
			<p>Runs command.</p>







		</div>
		</div></td>
	</tr>
	</table>

	<table class="summary inherited">
	<caption>Methods inherited from <a href="class-AMI_Tx_Cmd_Storage.html#methods">AMI_Tx_Cmd_Storage</a></caption>
	<tr>
		<td><code>
			<a href="class-AMI_Tx_Cmd_Storage.html#_addResources">addResources()</a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#_backup">backup()</a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#_commit">commit()</a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#_copy">copy()</a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#_init">init()</a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#_rollback">rollback()</a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#_set">set()</a>
		</code></td>
	</tr>
	</table>
	<table class="summary inherited">
	<caption>Methods inherited from <a href="class-AMI_Tx_Cmd.html#methods">AMI_Tx_Cmd</a></caption>
	<tr>
		<td><code>
			<a href="class-AMI_Tx_Cmd.html#___construct">__construct()</a>, 
			<a href="class-AMI_Tx_Cmd.html#_argsToString">argsToString()</a>, 
			<a href="class-AMI_Tx_Cmd.html#_getLoggingArgs">getLoggingArgs()</a>, 
			<a href="class-AMI_Tx_Cmd.html#_validateObligatoryArgs">validateObligatoryArgs()</a>
		</code></td>
	</tr>
	</table>








	<table class="summary inherited">
	<caption>Constants inherited from <a href="class-AMI_iTx_Cmd.html#constants">AMI_iTx_Cmd</a></caption>
	<tr>
		<td><code>
			<a href="class-AMI_iTx_Cmd.html#MODE_APPEND"><b>MODE_APPEND</b></a>, 
			<a href="class-AMI_iTx_Cmd.html#MODE_COMMON"><b>MODE_COMMON</b></a>, 
			<a href="class-AMI_iTx_Cmd.html#MODE_DELETE_BACKUP_ON_COMMIT"><b>MODE_DELETE_BACKUP_ON_COMMIT</b></a>, 
			<a href="class-AMI_iTx_Cmd.html#MODE_IGNORE_DATA_EXISTENCE"><b>MODE_IGNORE_DATA_EXISTENCE</b></a>, 
			<a href="class-AMI_iTx_Cmd.html#MODE_IGNORE_TARGET_EXISTENCE"><b>MODE_IGNORE_TARGET_EXISTENCE</b></a>, 
			<a href="class-AMI_iTx_Cmd.html#MODE_OVERWRITE"><b>MODE_OVERWRITE</b></a>, 
			<a href="class-AMI_iTx_Cmd.html#MODE_PURGE"><b>MODE_PURGE</b></a>, 
			<a href="class-AMI_iTx_Cmd.html#MODE_SOFT"><b>MODE_SOFT</b></a>
		</code></td>
	</tr>
	</table>




	<table class="summary inherited">
	<caption>Properties inherited from <a href="class-AMI_Tx_Cmd_Storage.html#properties">AMI_Tx_Cmd_Storage</a></caption>
	<tr>
		<td><code>
			<a href="class-AMI_Tx_Cmd_Storage.html#$backupPath"><var>$backupPath</var></a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#$backuped"><var>$backuped</var></a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#$eol"><var>$eol</var></a>, 
			<a href="class-AMI_Tx_Cmd_Storage.html#$oStorage"><var>$oStorage</var></a>
		</code></td>
	</tr>
	</table>
	<table class="summary inherited">
	<caption>Properties inherited from <a href="class-AMI_Tx_Cmd.html#properties">AMI_Tx_Cmd</a></caption>
	<tr>
		<td><code>
			<a href="class-AMI_Tx_Cmd.html#$backupName"><var>$backupName</var></a>, 
			<a href="class-AMI_Tx_Cmd.html#$oArgs"><var>$oArgs</var></a>, 
			<a href="class-AMI_Tx_Cmd.html#$oTx"><var>$oTx</var></a>, 
			<a href="class-AMI_Tx_Cmd.html#$replaceOnCommit"><var>$replaceOnCommit</var></a>
		</code></td>
	</tr>
	</table>





</div>

	<div id="footer">
		PHPOID - Amiro.CMS functionality extension API documentation generated by <a href="http://apigen.org">ApiGen</a><br>
		Documentation generated on Wed, 02 Mar 2016 15:43:37 +0700
	</div>
</div>
</div>
<script src="resources/combined.js"></script>
<script src="elementlist.js"></script>
</body>
</html>
