Class: FluentCommandBuilder::Tf::TEE2010::Add

Inherits:
CommandBase
  • Object
show all
Defined in:
lib/fluent_command_builder/command_builders/tf_tee_2010.rb

Instance Method Summary collapse

Methods inherited from CommandBase

#execute!, #to_s

Constructor Details

#initialize(builder, item_spec) ⇒ Add



197
198
199
200
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 197

def initialize(builder, item_spec)
  super builder
  @builder.append " add #{@builder.format item_spec}"
end

Instance Method Details

#lock(lock_type) {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


201
202
203
204
205
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 201

def lock(lock_type)
  @builder.append " -lock:#{@builder.format lock_type}"
  yield @builder if block_given?
  self
end

#login(username, password = nil) {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


221
222
223
224
225
226
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 221

def (username, password=nil)
  @builder.append " -login:#{@builder.format username}"
  @builder.append ",#{@builder.format password}" unless password.nil?
  yield @builder if block_given?
  self
end

#no_prompt {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


211
212
213
214
215
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 211

def no_prompt
  @builder.append ' -noPrompt'
  yield @builder if block_given?
  self
end

#recursive {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


216
217
218
219
220
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 216

def recursive
  @builder.append ' -recursive'
  yield @builder if block_given?
  self
end

#type(file_type) {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


206
207
208
209
210
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 206

def type(file_type)
  @builder.append " -type:#{@builder.format file_type}"
  yield @builder if block_given?
  self
end