grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Handler support


From: Bean
Subject: Re: [PATCH] Handler support
Date: Mon, 23 Feb 2009 03:40:52 +0800

Hi,

Any comment about this ?

On Sun, Feb 15, 2009 at 11:14 PM, Bean <address@hidden> wrote:
> Hi,
>
> The new version contains the following changes:
>
> 1, The handler module register commands terminal_input and
> terminal_output. This is for backward compatible of grub.cfg.
> Currently, the commands are registered manually, but this process
> could be automated with a new command interface design.
>
> 2, Add a new class, grub_named_list, which represents a named list:
>
> struct grub_named_list
> {
>  struct grub_named_list *next;
>  const char *name;
> };
>
> it also introduce a new function, grub_named_list_find, which can be
> used to lookup a object by name.
>
> The relationship between different class:
>
> list - named list + - handler + - terminal input
>                        |                |
>                        |               + - terminal output
>                       + - handler class
>
> You can use macros like GRUB_AS_LIST, GRUB_AS_NAMED_LIST and
> GRUB_AS_HANDLER to cast pointer of a certain class to its ancestors.
>
> --
> Bean
>



-- 
Bean




reply via email to

[Prev in Thread] Current Thread [Next in Thread]