1SQL::Statement::TermFacUtsoerry(C3o)ntributed Perl DocumSeQnLt:a:tSitoantement::TermFactory(3)
2
3
4
6 SQL::Statement::TermFactory - Factory for SQL::Statement::Term
7 instances
8
10 my $termFactory = SQL::Statement::TermFactory->new($stmt);
11 my $whereTerms = $termFactory->buildCondition( $stmt->{where_clause} );
12 my $col = $termFactory->buildCondition( $stmt->{col_obj}->{$name}->{content} );
13
15 This package implements a factory to create type and operation based
16 terms. Those terms are used to access data from the table(s) - either
17 when evaluating the where clause or returning column data.
18
19 The concept of a factory can be studied in Design Patterns by the Gang
20 of Four. The concept of using polymorphism instead of conditions is
21 suggested by Martin Fowler in his book Refactoring.
22
24 buildCondition
25 Builds a condition object from a given (part of a) where clause. This
26 method calls itself recursively for predicates.
27
29 Copyright (c) 2001,2005 by Jeff Zucker: jzuckerATcpan.org Copyright (c)
30 2008-2010 by Jens Rehsack: rehsackATcpan.org
31
32 Portions Copyright (C) 1998 by Jochen Wiedmann: jwiedATcpan.org
33
34 All rights reserved.
35
36 You may distribute this module under the terms of either the GNU
37 General Public License or the Artistic License, as specified in the
38 Perl README file.
39
40
41
42perl v5.12.1 2010-08-11 SQL::Statement::TermFactory(3)