Class: FluentCommandBuilder::TeamFoundation::V100::Permission

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

Instance Method Summary collapse

Methods inherited from CommandBase

#configure!, #execute!, #to_s

Constructor Details

#initialize(underlying_builder, item_spec) ⇒ Permission

Returns a new instance of Permission.



1214
1215
1216
1217
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1214

def initialize(underlying_builder, item_spec)
  super underlying_builder
  @b.append " permission #{@b.format item_spec}"
end

Instance Method Details

#allow(permission) {|@b| ... } ⇒ Object

Yields:

  • (@b)


1218
1219
1220
1221
1222
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1218

def allow(permission)
  @b.append " /allow:#{@b.format permission, ','}"
  yield @b if block_given?
  self
end

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

Yields:

  • (@b)


1248
1249
1250
1251
1252
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1248

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

#deny(permission) {|@b| ... } ⇒ Object

Yields:

  • (@b)


1223
1224
1225
1226
1227
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1223

def deny(permission)
  @b.append " /deny:#{@b.format permission, ','}"
  yield @b if block_given?
  self
end

#global {|@b| ... } ⇒ Object

Yields:

  • (@b)


1258
1259
1260
1261
1262
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1258

def global
  @b.append ' /global'
  yield @b if block_given?
  self
end

#group(group_name) {|@b| ... } ⇒ Object

Yields:

  • (@b)


1243
1244
1245
1246
1247
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1243

def group(group_name)
  @b.append " /group:#{@b.format group_name, ','}"
  yield @b if block_given?
  self
end

#inherit(inherit) {|@b| ... } ⇒ Object

Yields:

  • (@b)


1233
1234
1235
1236
1237
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1233

def inherit(inherit)
  @b.append " /inherit:#{@b.format inherit}"
  yield @b if block_given?
  self
end

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

Yields:

  • (@b)


1263
1264
1265
1266
1267
1268
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1263

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

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

Yields:

  • (@b)


1253
1254
1255
1256
1257
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1253

def recursive
  @b.append ' /recursive'
  yield @b if block_given?
  self
end

#remove(permission) {|@b| ... } ⇒ Object

Yields:

  • (@b)


1228
1229
1230
1231
1232
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1228

def remove(permission)
  @b.append " /remove:#{@b.format permission, ','}"
  yield @b if block_given?
  self
end

#user(user_name) {|@b| ... } ⇒ Object

Yields:

  • (@b)


1238
1239
1240
1241
1242
# File 'lib/fluent_command_builder/command_builders/team_foundation_100.rb', line 1238

def user(user_name)
  @b.append " /user:#{@b.format user_name, ','}"
  yield @b if block_given?
  self
end