Class: FluentCommandBuilder::Tf::TEE2010::DeleteLabel

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, label_name, item_spec, scope = nil) ⇒ DeleteLabel

Returns a new instance of DeleteLabel.



929
930
931
932
933
934
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 929

def initialize(builder, label_name, item_spec, scope=nil)
  super builder
  @builder.append " label -delete #{@builder.format label_name}"
  @builder.append "@#{@builder.format scope}" unless scope.nil?
  @builder.append " #{@builder.format item_spec}"
end

Instance Method Details

#collection(team_project_collection_url) {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


941
942
943
944
945
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 941

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

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

Yields:

  • (@builder)


935
936
937
938
939
940
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 935

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