Class: FluentCommandBuilder::Tf::V2010::Rename

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

Instance Method Summary collapse

Methods inherited from CommandBase

#execute!, #to_s

Constructor Details

#initialize(builder, old_item, new_item) ⇒ Rename



1377
1378
1379
1380
# File 'lib/fluent_command_builder/command_builders/tf_2010.rb', line 1377

def initialize(builder, old_item, new_item)
  super builder
  @builder.append " rename #{@builder.format old_item} #{@builder.format new_item}"
end

Instance Method Details

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

Yields:

  • (@builder)


1381
1382
1383
1384
1385
# File 'lib/fluent_command_builder/command_builders/tf_2010.rb', line 1381

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)


1386
1387
1388
1389
1390
1391
# File 'lib/fluent_command_builder/command_builders/tf_2010.rb', line 1386

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