-my @ATTRS = qw(uuid custom_data entries groups);
-my %ATTRS = (
- # uuid => sub { generate_uuid(printable => 1) },
- name => '',
- notes => '',
- tags => '',
- icon_id => sub { defined $_[1] ? icon($_[1]) : ICON_FOLDER },
- custom_icon_uuid => undef,
- is_expanded => false,
- default_auto_type_sequence => '',
- enable_auto_type => undef,
- enable_searching => undef,
- last_top_visible_entry => undef,
- # custom_data => sub { +{} },
- previous_parent_group => undef,
- # entries => sub { +[] },
- # groups => sub { +[] },
-);
-my %ATTRS_TIMES = (
- last_modification_time => sub { scalar gmtime },
- creation_time => sub { scalar gmtime },
- last_access_time => sub { scalar gmtime },
- expiry_time => sub { scalar gmtime },
- expires => false,
- usage_count => 0,
- location_changed => sub { scalar gmtime },
-);
-
-while (my ($attr, $setter) = each %ATTRS) {
- no strict 'refs'; ## no critic (ProhibitNoStrict)
- *{$attr} = is_coderef $setter ? sub {
- my $self = shift;
- $self->{$attr} = $setter->($self, shift) if @_;
- $self->{$attr} //= $setter->($self);
- } : sub {
- my $self = shift;
- $self->{$attr} = shift if @_;
- $self->{$attr} //= $setter;
- };
-}
-while (my ($attr, $default) = each %ATTRS_TIMES) {
- no strict 'refs'; ## no critic (ProhibitNoStrict)
- *{$attr} = sub {
- my $self = shift;
- $self->{times}{$attr} = shift if @_;
- $self->{times}{$attr} //= (ref $default eq 'CODE') ? $default->($self) : $default;
- };
-}
+The human-readable name of the group.
+
+=attr notes
+
+Free form text string associated with the group.
+
+=attr is_expanded
+
+Whether or not subgroups are visible when listed for user selection.
+
+=attr default_auto_type_sequence
+
+The default auto-type keystroke sequence, inheritable by entries and subgroups.
+
+=attr enable_auto_type
+
+Whether or not the entry is eligible to be matched for auto-typing, inheritable by entries and subgroups.
+
+=attr enable_searching
+
+Whether or not entries within the group can show up in search results, inheritable by subgroups.
+
+=attr last_top_visible_entry
+
+The UUID of the entry visible at the top of the list.