AccountGroup
public class AccountGroup : AccountItem
A group of accounts.
If e.g. Assets:Cash:CAD and Assets:Cash:EUR are Account
s, Assets and Assets:Cash would be AccountGroups.
In this case Assets would be a baseGroup
-
Last part of the name, for Assets:Cash:CAD this would be CAD
Declaration
Swift
public let nameItem: String
-
Indicates if this a a base group, meaning it directly is one of the 5
AccountType
sDeclaration
Swift
public let baseGroup: Bool
-
Type, see
AccountType
Declaration
Swift
public let accountType: AccountType
-
Creates an AccountGroup
Declaration
Swift
public init(nameItem: String, accountType: AccountType, baseGroup: Bool = false)
Parameters
nameItem
name for the group, without any :
accountType
type
baseGroup
if this group is one of the five base
AccountType
s -
Get all
AccountItem
s which are children of this groupAccountItems are the
Account
s which are direct children under this group and the subAccountGroup
s under this group.Declaration
Swift
public func children() -> [AccountItem]
Return Value
Array sorted by name item of children