Class: ThriftHadoopFileSystem::Client
- Inherits:
-
Object
- Object
- ThriftHadoopFileSystem::Client
- Includes:
- Thrift::Client
- Defined in:
- lib/thrift/thrift_hadoop_file_system.rb
Instance Method Summary collapse
- #append(path) ⇒ Object
- #chmod(path, mode) ⇒ Object
- #chown(path, owner, group) ⇒ Object
- #close(out) ⇒ Object
- #create(path) ⇒ Object
- #createFile(path, mode, overwrite, bufferSize, block_replication, blocksize) ⇒ Object
- #exists(path) ⇒ Object
- #getFileBlockLocations(path, start, length) ⇒ Object
- #listStatus(path) ⇒ Object
- #mkdirs(path) ⇒ Object
- #open(path) ⇒ Object
- #read(handle, offset, size) ⇒ Object
- #recv_append ⇒ Object
- #recv_chmod ⇒ Object
- #recv_chown ⇒ Object
- #recv_close ⇒ Object
- #recv_create ⇒ Object
- #recv_createFile ⇒ Object
- #recv_exists ⇒ Object
- #recv_getFileBlockLocations ⇒ Object
- #recv_listStatus ⇒ Object
- #recv_mkdirs ⇒ Object
- #recv_open ⇒ Object
- #recv_read ⇒ Object
- #recv_rename ⇒ Object
- #recv_rm ⇒ Object
- #recv_setInactivityTimeoutPeriod ⇒ Object
- #recv_setReplication ⇒ Object
- #recv_shutdown ⇒ Object
- #recv_stat ⇒ Object
- #recv_write ⇒ Object
- #rename(path, dest) ⇒ Object
- #rm(path, recursive) ⇒ Object
- #send_append(path) ⇒ Object
- #send_chmod(path, mode) ⇒ Object
- #send_chown(path, owner, group) ⇒ Object
- #send_close(out) ⇒ Object
- #send_create(path) ⇒ Object
- #send_createFile(path, mode, overwrite, bufferSize, block_replication, blocksize) ⇒ Object
- #send_exists(path) ⇒ Object
- #send_getFileBlockLocations(path, start, length) ⇒ Object
- #send_listStatus(path) ⇒ Object
- #send_mkdirs(path) ⇒ Object
- #send_open(path) ⇒ Object
- #send_read(handle, offset, size) ⇒ Object
- #send_rename(path, dest) ⇒ Object
- #send_rm(path, recursive) ⇒ Object
- #send_setInactivityTimeoutPeriod(periodInSeconds) ⇒ Object
- #send_setReplication(path, replication) ⇒ Object
- #send_shutdown(status) ⇒ Object
- #send_stat(path) ⇒ Object
- #send_write(handle, data) ⇒ Object
- #setInactivityTimeoutPeriod(periodInSeconds) ⇒ Object
- #setReplication(path, replication) ⇒ Object
- #shutdown(status) ⇒ Object
- #stat(path) ⇒ Object
- #write(handle, data) ⇒ Object
Instance Method Details
#append(path) ⇒ Object
90 91 92 93 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 90 def append(path) send_append(path) return recv_append() end |
#chmod(path, mode) ⇒ Object
250 251 252 253 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 250 def chmod(path, mode) send_chmod(path, mode) recv_chmod() end |
#chown(path, owner, group) ⇒ Object
265 266 267 268 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 265 def chown(path, owner, group) send_chown(path, owner, group) recv_chown() end |
#close(out) ⇒ Object
138 139 140 141 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 138 def close(out) send_close(out) return recv_close() end |
#create(path) ⇒ Object
42 43 44 45 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 42 def create(path) send_create(path) return recv_create() end |
#createFile(path, mode, overwrite, bufferSize, block_replication, blocksize) ⇒ Object
58 59 60 61 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 58 def createFile(path, mode, overwrite, bufferSize, block_replication, blocksize) send_createFile(path, mode, overwrite, bufferSize, block_replication, blocksize) return recv_createFile() end |
#exists(path) ⇒ Object
202 203 204 205 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 202 def exists(path) send_exists(path) return recv_exists() end |
#getFileBlockLocations(path, start, length) ⇒ Object
295 296 297 298 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 295 def getFileBlockLocations(path, start, length) send_getFileBlockLocations(path, start, length) return recv_getFileBlockLocations() end |
#listStatus(path) ⇒ Object
234 235 236 237 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 234 def listStatus(path) send_listStatus(path) return recv_listStatus() end |
#mkdirs(path) ⇒ Object
186 187 188 189 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 186 def mkdirs(path) send_mkdirs(path) return recv_mkdirs() end |
#open(path) ⇒ Object
74 75 76 77 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 74 def open(path) send_open(path) return recv_open() end |
#read(handle, offset, size) ⇒ Object
122 123 124 125 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 122 def read(handle, offset, size) send_read(handle, offset, size) return recv_read() end |
#recv_append ⇒ Object
99 100 101 102 103 104 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 99 def recv_append() result = (Append_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'append failed: unknown result') end |
#recv_chmod ⇒ Object
259 260 261 262 263 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 259 def recv_chmod() result = (Chmod_result) raise result.ouch unless result.ouch.nil? return end |
#recv_chown ⇒ Object
274 275 276 277 278 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 274 def recv_chown() result = (Chown_result) raise result.ouch unless result.ouch.nil? return end |
#recv_close ⇒ Object
147 148 149 150 151 152 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 147 def recv_close() result = (Close_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'close failed: unknown result') end |
#recv_create ⇒ Object
51 52 53 54 55 56 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 51 def recv_create() result = (Create_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'create failed: unknown result') end |
#recv_createFile ⇒ Object
67 68 69 70 71 72 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 67 def recv_createFile() result = (CreateFile_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'createFile failed: unknown result') end |
#recv_exists ⇒ Object
211 212 213 214 215 216 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 211 def recv_exists() result = (Exists_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'exists failed: unknown result') end |
#recv_getFileBlockLocations ⇒ Object
304 305 306 307 308 309 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 304 def recv_getFileBlockLocations() result = (GetFileBlockLocations_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'getFileBlockLocations failed: unknown result') end |
#recv_listStatus ⇒ Object
243 244 245 246 247 248 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 243 def recv_listStatus() result = (ListStatus_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'listStatus failed: unknown result') end |
#recv_mkdirs ⇒ Object
195 196 197 198 199 200 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 195 def recv_mkdirs() result = (Mkdirs_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'mkdirs failed: unknown result') end |
#recv_open ⇒ Object
83 84 85 86 87 88 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 83 def recv_open() result = (Open_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'open failed: unknown result') end |
#recv_read ⇒ Object
131 132 133 134 135 136 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 131 def recv_read() result = (Read_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'read failed: unknown result') end |
#recv_rename ⇒ Object
179 180 181 182 183 184 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 179 def recv_rename() result = (Rename_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'rename failed: unknown result') end |
#recv_rm ⇒ Object
163 164 165 166 167 168 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 163 def recv_rm() result = (Rm_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'rm failed: unknown result') end |
#recv_setInactivityTimeoutPeriod ⇒ Object
23 24 25 26 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 23 def recv_setInactivityTimeoutPeriod() result = (SetInactivityTimeoutPeriod_result) return end |
#recv_setReplication ⇒ Object
289 290 291 292 293 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 289 def recv_setReplication() result = (SetReplication_result) raise result.ouch unless result.ouch.nil? return end |
#recv_shutdown ⇒ Object
37 38 39 40 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 37 def recv_shutdown() result = (Shutdown_result) return end |
#recv_stat ⇒ Object
227 228 229 230 231 232 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 227 def recv_stat() result = (Stat_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'stat failed: unknown result') end |
#recv_write ⇒ Object
115 116 117 118 119 120 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 115 def recv_write() result = (Write_result) return result.success unless result.success.nil? raise result.ouch unless result.ouch.nil? raise ::Thrift::ApplicationException.new(::Thrift::ApplicationException::MISSING_RESULT, 'write failed: unknown result') end |
#rename(path, dest) ⇒ Object
170 171 172 173 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 170 def rename(path, dest) send_rename(path, dest) return recv_rename() end |
#rm(path, recursive) ⇒ Object
154 155 156 157 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 154 def rm(path, recursive) send_rm(path, recursive) return recv_rm() end |
#send_append(path) ⇒ Object
95 96 97 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 95 def send_append(path) ('append', Append_args, :path => path) end |
#send_chmod(path, mode) ⇒ Object
255 256 257 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 255 def send_chmod(path, mode) ('chmod', Chmod_args, :path => path, :mode => mode) end |
#send_chown(path, owner, group) ⇒ Object
270 271 272 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 270 def send_chown(path, owner, group) ('chown', Chown_args, :path => path, :owner => owner, :group => group) end |
#send_close(out) ⇒ Object
143 144 145 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 143 def send_close(out) ('close', Close_args, :out => out) end |
#send_create(path) ⇒ Object
47 48 49 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 47 def send_create(path) ('create', Create_args, :path => path) end |
#send_createFile(path, mode, overwrite, bufferSize, block_replication, blocksize) ⇒ Object
63 64 65 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 63 def send_createFile(path, mode, overwrite, bufferSize, block_replication, blocksize) ('createFile', CreateFile_args, :path => path, :mode => mode, :overwrite => overwrite, :bufferSize => bufferSize, :block_replication => block_replication, :blocksize => blocksize) end |
#send_exists(path) ⇒ Object
207 208 209 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 207 def send_exists(path) ('exists', Exists_args, :path => path) end |
#send_getFileBlockLocations(path, start, length) ⇒ Object
300 301 302 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 300 def send_getFileBlockLocations(path, start, length) ('getFileBlockLocations', GetFileBlockLocations_args, :path => path, :start => start, :length => length) end |
#send_listStatus(path) ⇒ Object
239 240 241 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 239 def send_listStatus(path) ('listStatus', ListStatus_args, :path => path) end |
#send_mkdirs(path) ⇒ Object
191 192 193 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 191 def send_mkdirs(path) ('mkdirs', Mkdirs_args, :path => path) end |
#send_open(path) ⇒ Object
79 80 81 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 79 def send_open(path) ('open', Open_args, :path => path) end |
#send_read(handle, offset, size) ⇒ Object
127 128 129 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 127 def send_read(handle, offset, size) ('read', Read_args, :handle => handle, :offset => offset, :size => size) end |
#send_rename(path, dest) ⇒ Object
175 176 177 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 175 def send_rename(path, dest) ('rename', Rename_args, :path => path, :dest => dest) end |
#send_rm(path, recursive) ⇒ Object
159 160 161 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 159 def send_rm(path, recursive) ('rm', Rm_args, :path => path, :recursive => recursive) end |
#send_setInactivityTimeoutPeriod(periodInSeconds) ⇒ Object
19 20 21 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 19 def send_setInactivityTimeoutPeriod(periodInSeconds) ('setInactivityTimeoutPeriod', SetInactivityTimeoutPeriod_args, :periodInSeconds => periodInSeconds) end |
#send_setReplication(path, replication) ⇒ Object
285 286 287 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 285 def send_setReplication(path, replication) ('setReplication', SetReplication_args, :path => path, :replication => replication) end |
#send_shutdown(status) ⇒ Object
33 34 35 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 33 def send_shutdown(status) ('shutdown', Shutdown_args, :status => status) end |
#send_stat(path) ⇒ Object
223 224 225 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 223 def send_stat(path) ('stat', Stat_args, :path => path) end |
#send_write(handle, data) ⇒ Object
111 112 113 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 111 def send_write(handle, data) ('write', Write_args, :handle => handle, :data => data) end |
#setInactivityTimeoutPeriod(periodInSeconds) ⇒ Object
14 15 16 17 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 14 def setInactivityTimeoutPeriod(periodInSeconds) send_setInactivityTimeoutPeriod(periodInSeconds) recv_setInactivityTimeoutPeriod() end |
#setReplication(path, replication) ⇒ Object
280 281 282 283 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 280 def setReplication(path, replication) send_setReplication(path, replication) recv_setReplication() end |
#shutdown(status) ⇒ Object
28 29 30 31 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 28 def shutdown(status) send_shutdown(status) recv_shutdown() end |
#stat(path) ⇒ Object
218 219 220 221 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 218 def stat(path) send_stat(path) return recv_stat() end |
#write(handle, data) ⇒ Object
106 107 108 109 |
# File 'lib/thrift/thrift_hadoop_file_system.rb', line 106 def write(handle, data) send_write(handle, data) return recv_write() end |