1<?php 2 3declare(strict_types=1); 4 5namespace Sabre\DAV; 6 7/** 8 * Node class. 9 * 10 * This is a helper class, that should aid in getting nodes setup. 11 * 12 * @copyright Copyright (C) fruux GmbH (https://fruux.com/) 13 * @author Evert Pot (http://evertpot.com/) 14 * @license http://sabre.io/license/ Modified BSD License 15 */ 16abstract class Node implements INode 17{ 18 /** 19 * Returns the last modification time as a unix timestamp. 20 * 21 * If the information is not available, return null. 22 * 23 * @return int 24 */ 25 public function getLastModified() 26 { 27 return null; 28 } 29 30 /** 31 * Deletes the current node. 32 * 33 * @throws Exception\Forbidden 34 */ 35 public function delete() 36 { 37 throw new Exception\Forbidden('Permission denied to delete node'); 38 } 39 40 /** 41 * Renames the node. 42 * 43 * @param string $name The new name 44 * 45 * @throws Exception\Forbidden 46 */ 47 public function setName($name) 48 { 49 throw new Exception\Forbidden('Permission denied to rename file'); 50 } 51} 52