X-Git-Url: http://git.kpe.io/?p=clsql.git;a=blobdiff_plain;f=sql%2Fbase-classes.lisp;h=344e11ce60683811e1faf1a3bb889f1debd8ee04;hp=8e0cc496a5e7c4b0714dddc9b4e17e14fa7c0aa2;hb=HEAD;hpb=44c87a075cbe29141d90dc49c501f382a6d81fbe diff --git a/sql/base-classes.lisp b/sql/base-classes.lisp index 8e0cc49..344e11c 100644 --- a/sql/base-classes.lisp +++ b/sql/base-classes.lisp @@ -2,15 +2,13 @@ ;;;; ************************************************************************* ;;;; FILE IDENTIFICATION ;;;; -;;;; Name: classes.lisp -;;;; Purpose: Classes for High-level SQL interface +;;;; Name: base-classes.lisp +;;;; Purpose: Base classes for high-level SQL interface ;;;; Programmers: Kevin M. Rosenberg based on -;;;; original code by Pierre R. Mai +;;;; original code by Pierre R. Mai ;;;; Date Started: Feb 2002 ;;;; -;;;; $Id$ -;;;; -;;;; This file, part of CLSQL, is Copyright (c) 2002-2004 by Kevin M. Rosenberg +;;;; This file, part of CLSQL, is Copyright (c) 2002-2010 by Kevin M. Rosenberg ;;;; and Copyright (c) 1999-2001 by Pierre R. Mai ;;;; ;;;; CLSQL users are granted the rights to distribute and use this software @@ -25,9 +23,11 @@ ((name :initform nil :initarg :name :reader database-name) (connection-spec :initform nil :initarg :connection-spec :reader connection-spec - :documentation "Require to use connection pool") + :documentation "Required to use connection pool.") (database-type :initarg :database-type :initform :unknown - :reader database-type) + :reader database-type) + (encoding :initarg :encoding :initform nil + :documentation "External format character encoding.") (state :initform :closed :reader database-state) (autocommit :initform t :accessor database-autocommit) (command-recording-stream :accessor command-recording-stream :initform nil) @@ -37,9 +37,9 @@ (transaction-level :initform 0 :accessor transaction-level) (transaction :initform nil :accessor transaction) (conn-pool :initform nil :initarg :conn-pool :accessor conn-pool) - (attribute-cache :initform (make-hash-table :size 100 :test 'equal) - :accessor attribute-cache - :documentation "Internal cache of table attributes. It is keyed by table-name. Values + (attribute-cache :initform (make-hash-table :size 100 :test 'equal) + :accessor attribute-cache + :documentation "Internal cache of table attributes. It is keyed by table-name. Values are a list of ACTION specified for table and any cached value of list-attributes-types.")) (:documentation "This class is the supertype of all databases handled by CLSQL.")) @@ -47,10 +47,10 @@ are a list of ACTION specified for table and any cached value of list-attributes (defmethod print-object ((object database) stream) (print-unreadable-object (object stream :type t :identity t) (format stream "~A ~A" - (if (slot-boundp object 'name) - (database-name object) - "") - (database-state object))) + (if (slot-boundp object 'name) + (database-name object) + "") + (database-state object))) object) (setf (documentation 'database-name 'function)