lib/pione/location/ftp-location.rb in pione-0.2.2 vs lib/pione/location/ftp-location.rb in pione-0.3.0
- old
+ new
@@ -31,18 +31,20 @@
path = Temppath.create
Location[path].create(data)
ftp.put(path, @path.to_s)
end
end
+ return self
end
def append(data)
if exist?
update(read + data)
else
create(data)
end
+ return self
end
def read
file = Temppath.create
connect {|ftp| ftp.get(@path, file.to_s)}
@@ -71,9 +73,13 @@
connect {|ftp| makedirs(ftp, @path)} unless exist?
end
def mtime
connect {|ftp| exist? ? ftp.mtime(@path.to_s) : (raise NotFound.new(self))}
+ end
+
+ def mtime=(time)
+
end
def size
connect {|ftp| exist? ? ftp.size(@path.to_s) : (raise NotFound.new(self))}
end