[ Index ]

PHP Cross Reference of Unnamed Project

title

Body

[close]

/se3-unattended/var/se3/unattended/install/linuxaux/opt/perl/lib/site_perl/5.10.0/i586-linux-thread-multi/DBD/Gofer/Policy/ -> classic.pm (source)

   1  package DBD::Gofer::Policy::classic;
   2  
   3  #   $Id: classic.pm 10087 2007-10-16 12:42:37Z timbo $
   4  #
   5  #   Copyright (c) 2007, Tim Bunce, Ireland
   6  #
   7  #   You may distribute under the terms of either the GNU General Public
   8  #   License or the Artistic License, as specified in the Perl README file.
   9  
  10  use strict;
  11  use warnings;
  12  
  13  our $VERSION = sprintf("0.%06d", q$Revision: 10087 $ =~ /(\d+)/o);
  14  
  15  use base qw(DBD::Gofer::Policy::Base);
  16  
  17  __PACKAGE__->create_policy_subs({
  18  
  19      # always use connect_cached on server
  20      connect_method => 'connect_cached',
  21  
  22      # use same methods on server as is called on client
  23      prepare_method => '',
  24  
  25      # don't skip the connect check since that also sets dbh attributes
  26      # although this makes connect more expensive, that's partly offset
  27      # by skip_ping=>1 below, which makes connect_cached very fast.
  28      skip_connect_check => 0,
  29  
  30      # most code doesn't rely on sth attributes being set after prepare
  31      skip_prepare_check => 1,
  32  
  33      # we're happy to use local method if that's the same as the remote
  34      skip_default_methods => 1,
  35  
  36      # ping is not important for DBD::Gofer and most transports
  37      skip_ping => 1,
  38  
  39      # only update dbh attributes on first contact with server
  40      dbh_attribute_update => 'first',
  41  
  42      # we'd like to set locally_* but can't because drivers differ
  43  
  44      # get_info results usually don't change
  45      cache_get_info => 1,
  46  });
  47  
  48  
  49  1;
  50  
  51  =head1 NAME
  52  
  53  DBD::Gofer::Policy::classic - The 'classic' policy for DBD::Gofer
  54  
  55  =head1 SYNOPSIS
  56  
  57    $dbh = DBI->connect("dbi:Gofer:transport=...;policy=classic", ...)
  58  
  59  The C<classic> policy is the default DBD::Gofer policy, so need not be included in the DSN.
  60  
  61  =head1 DESCRIPTION
  62  
  63  Temporary docs: See the source code for list of policies and their defaults.
  64  
  65  In a future version the policies and their defaults will be defined in the pod and parsed out at load-time.
  66  
  67  =head1 AUTHOR
  68  
  69  Tim Bunce, L<http://www.tim.bunce.name>
  70  
  71  =head1 LICENCE AND COPYRIGHT
  72  
  73  Copyright (c) 2007, Tim Bunce, Ireland. All rights reserved.
  74  
  75  This module is free software; you can redistribute it and/or
  76  modify it under the same terms as Perl itself. See L<perlartistic>.
  77  
  78  =cut
  79  


Generated: Tue Mar 17 22:47:18 2015 Cross-referenced by PHPXref 0.7.1