summaryrefslogtreecommitdiff
path: root/model.lisp
diff options
context:
space:
mode:
Diffstat (limited to 'model.lisp')
-rw-r--r--model.lisp27
1 files changed, 16 insertions, 11 deletions
diff --git a/model.lisp b/model.lisp
index 3f0e4a1..7c863aa 100644
--- a/model.lisp
+++ b/model.lisp
@@ -7,26 +7,31 @@
(games :accessor games)))
(defclass game (db:store-object)
- ((name :initarg :name :reader name
- :index-type idx:string-unique-index
- :index-reader game-with-name
- :index-values all-games)
+ ((name
+ :initarg :name
+ :reader name
+ :index-type idx:string-unique-index
+ :index-reader game-with-name
+ :index-values all-games)
(rating :accessor rating)
(playtime :accessor playtime)
(icon-url :accessor icon-url)
(last-played :accessor last-played))
(:metaclass db:persistent-class))
+(defmethod print-object ((object game) stream)
+ (print-unreadable-object (object stream :type t :identity t)
+ (princ (name object) stream)))
+
(defclass steam-game (game)
- ((appid :initarg :appid :reader appid
- :index-type idx:unique-index
- :index-initargs (:test #'equal)
- :index-reader steam-game-with-appid))
+ ((appid
+ :initarg :appid
+ :reader appid
+ :index-type idx:unique-index
+ :index-initargs (:test #'equal)
+ :index-reader steam-game-with-appid))
(:metaclass db:persistent-class))
-(defmethod print-object ((object steam-game) stream)
- (format stream "#<STEAM GAME ~a>" (name object)))
-
(defclass feat (db:store-object)
((game
:reader game