CodeKit Perl API Quick Reference

[PHP Handle Creation] [Index] [Perl Handle Creation] ## CodeKit Perl API Quick Reference #### CodeKit Handle Creation
    use DBIx::CodeKit;

    $codekit = new DBIx::CodeKit($dbh,
                    table     => 'ck_code',
                    getparam  => \&get_scalar,
                    getparams => \&get_list
                ):
#### Display Methods
    $code_desc = $codekit->desc(   $code_set, $code_code);
    $Code_desc = $codekit->ucfirst($code_set, $code_code);
    $Code_Desc = $codekit->ucwords($code_set, $code_code);
#### Data Methods
    $code_desc = $codekit->data(  $code_set, $code_code);
#### HTML Select Common Options
    print $codekit->select('day',
                            var_name => 'start_day',
                            value    => $start_day,
                            default  => 1,
                            subset   => [ 1, 2, 3, 4, 5 ],
                            options  => 'onchange="submit()"'
                            );
#### HTML Select Single Value Methods
    $html = $codekit->select($code_set,
                              select_prompt => 'Code set description?',
                              blank_prompt  => 'None'
                              );

    $html = $codekit->radio($code_set,
                             blank_prompt => 'None'
                             sep          => "<br>\n",
                             );
#### HTML Select Multiple Value Methods
    $html = $codekit->multiple($code_set,
                                size => 10
                                );

    $html = $codekit->checkbox($code_set,
                                sep => "<br>\n"
                                );
#### Code Set Methods
    $rows = $codekit->code_set($code_set);
#### Code Table Update Methods
    $codekit->remove($code_set, $code_code);

    ( $code_desc, $code_order, $code_flag ) =
        $codekit->get($code_set, $code_code);

    $codekit->put($code_set,  $code_code,
                  $code_desc, $code_order, $code_flag);
[PHP Handle Creation] [Index] [Perl Handle Creation]