class Spaceship::Portal::AppGroup

Represents an app group of the Apple Dev Portal

Attributes

app_group_id[RW]

@return (String) The identifier of this app group, provided by the Dev Portal @example

"2MAY7NPHAA"
group_id[RW]

@return (String) The identifier assigned to this group @example

"group.com.example.application"
name[RW]

@return (String) The name of this group @example

"App Group"
prefix[RW]

@return (String) The prefix assigned to this group @example

"9J57U9392R"
status[RW]

@return (String) Status of the group @example

"current"

Private Class Methods

all() click to toggle source

@return (Array) Returns all app groups available for this account

# File spaceship/lib/spaceship/portal/app_group.rb, line 42
def all
  client.app_groups.map { |group| self.factory(group) }
end
create!(group_id: nil, name: nil) click to toggle source

Creates a new App Group on the Apple Dev Portal

@param group_id [String] the identifier to assign to this group @param name [String] the name of the group @return (AppGroup) The group you just created

# File spaceship/lib/spaceship/portal/app_group.rb, line 51
def create!(group_id: nil, name: nil)
  new_group = client.create_app_group!(name, group_id)
  self.new(new_group)
end
find(group_id) click to toggle source

Find a specific App Group group_id @return (AppGroup) The app group you're looking for. This is nil if the app group can't be found.

# File spaceship/lib/spaceship/portal/app_group.rb, line 58
def find(group_id)
  all.find do |group|
    group.group_id == group_id
  end
end

Private Instance Methods

delete!() click to toggle source

Delete this app group @return (AppGroup) The app group you just deletd

# File spaceship/lib/spaceship/portal/app_group.rb, line 67
def delete!
  client.delete_app_group!(app_group_id)
  self
end