Class: FluentCommandBuilder::Tf::TEE2010::Labels

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 = nil) ⇒ Labels

Returns a new instance of Labels.



948
949
950
951
952
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 948

def initialize(builder, label_name=nil)
  super builder
  @builder.append ' labels'
  @builder.append " #{@builder.format label_name}" unless label_name.nil?
end

Instance Method Details

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

Yields:

  • (@builder)


963
964
965
966
967
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 963

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

#format(format) {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


958
959
960
961
962
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 958

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

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

Yields:

  • (@builder)


968
969
970
971
972
973
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 968

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

#owner(owner_name) {|@builder| ... } ⇒ Object

Yields:

  • (@builder)


953
954
955
956
957
# File 'lib/fluent_command_builder/command_builders/tf_tee_2010.rb', line 953

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