openrat-cms

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

Target.class.php (797B)


      1 <?php
      2 
      3 
      4 namespace cms\generator\target;
      5 
      6 
      7 use util\Url;
      8 
      9 /**
     10  * A target is a target for publishing files. A target is the bridge to a place where files are being copied to.
     11  */
     12 interface Target
     13 {
     14 
     15 	/**
     16 	 * Creating the target.
     17 	 *
     18 	 * @param $targetUrl string target URL
     19 	 */
     20 	public function __construct( $targetUrl );
     21 
     22 
     23 	/**
     24 	 * Open the connection to the target.
     25 	 */
     26 	public function open();
     27 
     28 
     29 	/**
     30 	 * Pushing a file to the target.
     31 	 * @param $source string local filename
     32 	 * @param $dest string remote filename
     33 	 * @param $timestamp int timestamp of source file
     34 	 */
     35 	public function put($source, $dest, $timestamp);
     36 
     37 
     38 	/**
     39 	 * Closes the connection.
     40 	 */
     41 	public function close();
     42 
     43 
     44 	/**
     45 	 * Is this target available?
     46 	 *
     47 	 * @return boolean
     48 	 */
     49 	public static function isAvailable();
     50 
     51 }