4659 |
return NULL; |
return NULL; |
4660 |
} |
} |
4661 |
|
|
4662 |
|
/** |
4663 |
|
* Returns the group with the given group name. |
4664 |
|
* |
4665 |
|
* Note: group names don't have to be unique in the gig format! So there |
4666 |
|
* can be multiple groups with the same name. This method will simply |
4667 |
|
* return the first group found with the given name. |
4668 |
|
* |
4669 |
|
* @param name - name of the sought group |
4670 |
|
* @returns sought group or NULL if there's no group with that name |
4671 |
|
*/ |
4672 |
|
Group* File::GetGroup(String name) { |
4673 |
|
if (!pGroups) LoadGroups(); |
4674 |
|
GroupsIterator = pGroups->begin(); |
4675 |
|
for (uint i = 0; GroupsIterator != pGroups->end(); ++GroupsIterator, ++i) |
4676 |
|
if ((*GroupsIterator)->Name == name) return *GroupsIterator; |
4677 |
|
return NULL; |
4678 |
|
} |
4679 |
|
|
4680 |
Group* File::AddGroup() { |
Group* File::AddGroup() { |
4681 |
if (!pGroups) LoadGroups(); |
if (!pGroups) LoadGroups(); |
4682 |
// there must always be at least one group |
// there must always be at least one group |