On Wed, 01 Mar 2006 00:05:02 -0500, John Siracusa wrote:

Hi John

> On 2/28/06 11:34 PM, Ron Savage wrote:
>> When it says: "Here's a complete example..." how exactly do I
>> tell the code to connect to a registry entry so as to read the
>> metadata from the database?
>>
>
> Er, tell what code?  The loader?  A call to auto_initialize() from
> within a class?  Something else?

Tell my code, as based on the docs. Eg:

#!/usr/bin/perl
#
# Name:
#       generate-class-code.pl.

# -----------------------------------------------

package AcademicTitle;

our @ISA = 'Rose::DB::Object';

__PACKAGE__ -> meta -> table('academic_title');
__PACKAGE__ -> meta -> auto_initialize;

# -----------------------------------------------

package Faculty;

our @ISA = 'Rose::DB::Object';

__PACKAGE__ -> meta -> table('faculty');
__PACKAGE__ -> meta -> auto_initialize;

# -----------------------------------------------

print AcademicTitle -> meta -> perl_class_definition
(
        braces => 'bsd',
);

print Faculty -> meta -> perl_class_definition
(
        braces => 'bsd',
);


--
Ron Savage
[EMAIL PROTECTED]
http://savage.net.au/index.html




-------------------------------------------------------
This SF.Net email is sponsored by xPML, a groundbreaking scripting language
that extends applications into web and mobile media. Attend the live webcast
and join the prime developer group breaking into this new coding territory!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642
_______________________________________________
Rose-db-object mailing list
Rose-db-object@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rose-db-object

Reply via email to