m_librarian.db module

class m_librarian.db.Author(**kw)[исходный код]
Базовые классы: sqlobject.main.SQLObject
addBook(obj)
books
count
count_idx = <sqlobject.index.SODatabaseIndex object>
full_name_idx = <sqlobject.index.SODatabaseIndex object>
fullname
j = author
misc_name
name
q = author
removeBook(obj)
class sqlmeta(instance)
Базовые классы: sqlobject.main.sqlmeta
childName = None
columnDefinitions = {'misc_name': <UnicodeCol b5ba7dac misc_name>, 'name': <UnicodeCol b5ba7f2c name>, 'surname': <UnicodeCol b5ba7f4c surname>, 'count': <IntCol b5ba71ac count>}
columnList = [<SOUnicodeCol surname not null>, <SOUnicodeCol name not null>, <SOUnicodeCol misc_name not null>, <SOIntCol count not null>]
columns = {'misc_name': <SOUnicodeCol misc_name not null>, 'name': <SOUnicodeCol name not null>, 'surname': <SOUnicodeCol surname not null>, 'count': <SOIntCol count not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b5ba7dec {'unique': True, 'columns': (<UnicodeCol b5ba7f4c surname>, <UnicodeCol b5ba7f2c name>, <UnicodeCol b5ba7dac misc_name>), 'name': 'full_name_idx'}>, <DatabaseIndex b5ba706c {'columns': (<IntCol b5ba71ac count>,), 'name': 'count_idx'}>]
indexes = [<sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>]
joinDefinitions = [<sqlobject.joins.RelatedJoin object>]
joins = [<sqlobject.joins.SORelatedJoin object>]
soClass

псевдоним класса Author

style = <sqlobject.styles.MixedCaseUnderscoreStyle object>
table = 'author'
surname
class m_librarian.db.Book(**kw)[исходный код]
Базовые классы: sqlobject.main.SQLObject
addAuthor(obj)
addGenre(obj)
archive
archive_file_idx = <sqlobject.index.SODatabaseIndex object>
archive_idx = <sqlobject.index.SODatabaseIndex object>
authors
date
date_idx = <sqlobject.index.SODatabaseIndex object>
deleted
deleted_idx = <sqlobject.index.SODatabaseIndex object>
extension
extensionID
extension_idx = <sqlobject.index.SODatabaseIndex object>
file
file_idx = <sqlobject.index.SODatabaseIndex object>
genres
j = book
language
languageID
language_idx = <sqlobject.index.SODatabaseIndex object>
lib_id
q = book
removeAuthor(obj)
removeGenre(obj)
ser_no
ser_no_idx = <sqlobject.index.SODatabaseIndex object>
series
series_idx = <sqlobject.index.SODatabaseIndex object>
size
size_idx = <sqlobject.index.SODatabaseIndex object>
class sqlmeta(instance)
Базовые классы: sqlobject.main.sqlmeta
childName = None
columnDefinitions = {'lib_id': <StringCol b5b4df6c lib_id>, 'deleted': <BoolCol b5b4deac deleted>, 'file': <StringCol b5b4d46c file>, 'extensionID': <ForeignKey b5b4d98c extension>, 'size': <IntCol b5b4d50c size>, 'title': <UnicodeCol b5bb3f2c title>, 'languageID': <ForeignKey b5a4748c language>, 'date': <DateCol b5a4746c date>, 'archive': <StringCol b5b4dfec archive>, 'series': <UnicodeCol b5b4d0ac series>, 'ser_no': <IntCol b5b4deec ser_no>}
columnList = [<SOUnicodeCol title not null>, <SOUnicodeCol series not null>, <SOIntCol ser_no>, <SOStringCol archive not null>, <SOStringCol file not null>, <SOIntCol size not null>, <SOStringCol lib_id not null>, <SOBoolCol deleted not null>, <SOForeignKey extensionID connected to Extension not null>, <SODateCol date not null>, <SOForeignKey languageID connected to Language>]
columns = {'lib_id': <SOStringCol lib_id not null>, 'deleted': <SOBoolCol deleted not null>, 'file': <SOStringCol file not null>, 'extensionID': <SOForeignKey extensionID connected to Extension not null>, 'size': <SOIntCol size not null>, 'title': <SOUnicodeCol title not null>, 'languageID': <SOForeignKey languageID connected to Language>, 'date': <SODateCol date not null>, 'archive': <SOStringCol archive not null>, 'series': <SOUnicodeCol series not null>, 'ser_no': <SOIntCol ser_no>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b5a4754c {'columns': (<UnicodeCol b5bb3f2c title>,), 'name': 'title_idx'}>, <DatabaseIndex b5a4756c {'columns': (<UnicodeCol b5b4d0ac series>,), 'name': 'series_idx'}>, <DatabaseIndex b5a475ec {'columns': (<IntCol b5b4deec ser_no>,), 'name': 'ser_no_idx'}>, <DatabaseIndex b5a4766c {'columns': (<StringCol b5b4dfec archive>,), 'name': 'archive_idx'}>, <DatabaseIndex b5a4770c {'unique': True, 'columns': (<StringCol b5b4dfec archive>, <StringCol b5b4d46c file>), 'name': 'archive_file_idx'}>, <DatabaseIndex b5a4776c {'columns': (<StringCol b5b4d46c file>,), 'name': 'file_idx'}>, <DatabaseIndex b5a477cc {'columns': (<IntCol b5b4d50c size>,), 'name': 'size_idx'}>, <DatabaseIndex b5a4784c {'columns': (<BoolCol b5b4deac deleted>,), 'name': 'deleted_idx'}>, <DatabaseIndex b5a478cc {'columns': (<ForeignKey b5b4d98c extension>,), 'name': 'extension_idx'}>, <DatabaseIndex b5a4794c {'columns': (<DateCol b5a4746c date>,), 'name': 'date_idx'}>, <DatabaseIndex b5a479cc {'columns': (<ForeignKey b5a4748c language>,), 'name': 'language_idx'}>]
indexes = [<sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>]
joinDefinitions = [<sqlobject.joins.RelatedJoin object>, <sqlobject.joins.RelatedJoin object>]
joins = [<sqlobject.joins.SORelatedJoin object>, <sqlobject.joins.SORelatedJoin object>]
soClass

псевдоним класса Book

style = <sqlobject.styles.MixedCaseUnderscoreStyle object>
table = 'book'
title
title_idx = <sqlobject.index.SODatabaseIndex object>
class m_librarian.db.Extension(**kw)[исходный код]
Базовые классы: sqlobject.main.SQLObject
classmethod byName(val, connection=None)
count
count_idx = <sqlobject.index.SODatabaseIndex object>
j = extension
name
q = extension
class sqlmeta(instance)
Базовые классы: sqlobject.main.sqlmeta
childName = None
columnDefinitions = {'name': <UnicodeCol b5a54e2c name>, 'count': <IntCol b5a54ecc count>}
columnList = [<SOUnicodeCol name not null>, <SOIntCol count not null>]
columns = {'name': <SOUnicodeCol name not null>, 'count': <SOIntCol count not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b5a54f0c {'columns': (<IntCol b5a54ecc count>,), 'name': 'count_idx'}>]
indexes = [<sqlobject.index.SODatabaseIndex object>]
joinDefinitions = []
joins = []
soClass

псевдоним класса Extension

style = <sqlobject.styles.MixedCaseUnderscoreStyle object>
table = 'extension'
class m_librarian.db.Genre(**kw)[исходный код]
Базовые классы: sqlobject.main.SQLObject
addBook(obj)
books
classmethod byName(val, connection=None)
count
count_idx = <sqlobject.index.SODatabaseIndex object>
j = genre
name
q = genre
removeBook(obj)
class sqlmeta(instance)
Базовые классы: sqlobject.main.sqlmeta
childName = None
columnDefinitions = {'title': <UnicodeCol b5a566ec title>, 'name': <UnicodeCol b5a565ec name>, 'count': <IntCol b5a5672c count>}
columnList = [<SOUnicodeCol name not null>, <SOUnicodeCol title not null>, <SOIntCol count not null>]
columns = {'title': <SOUnicodeCol title not null>, 'name': <SOUnicodeCol name not null>, 'count': <SOIntCol count not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b5a5676c {'columns': (<UnicodeCol b5a566ec title>,), 'name': 'title_idx'}>, <DatabaseIndex b5a567cc {'columns': (<IntCol b5a5672c count>,), 'name': 'count_idx'}>]
indexes = [<sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>]
joinDefinitions = [<sqlobject.joins.RelatedJoin object>]
joins = [<sqlobject.joins.SORelatedJoin object>]
soClass

псевдоним класса Genre

style = <sqlobject.styles.MixedCaseUnderscoreStyle object>
table = 'genre'
title
title_idx = <sqlobject.index.SODatabaseIndex object>
class m_librarian.db.Language(**kw)[исходный код]
Базовые классы: sqlobject.main.SQLObject
classmethod byName(val, connection=None)
count
count_idx = <sqlobject.index.SODatabaseIndex object>
j = language
name
q = language
class sqlmeta(instance)
Базовые классы: sqlobject.main.sqlmeta
childName = None
columnDefinitions = {'name': <UnicodeCol b5a5930c name>, 'count': <IntCol b5a5932c count>}
columnList = [<SOUnicodeCol name not null>, <SOIntCol count not null>]
columns = {'name': <SOUnicodeCol name not null>, 'count': <SOIntCol count not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b5a5934c {'columns': (<IntCol b5a5932c count>,), 'name': 'count_idx'}>]
indexes = [<sqlobject.index.SODatabaseIndex object>]
joinDefinitions = []
joins = []
soClass

псевдоним класса Language

style = <sqlobject.styles.MixedCaseUnderscoreStyle object>
table = 'language'
class m_librarian.db.AuthorBook(**kw)[исходный код]
Базовые классы: sqlobject.main.SQLObject
author
authorID
author_idx = <sqlobject.index.SODatabaseIndex object>
book
bookID
book_idx = <sqlobject.index.SODatabaseIndex object>
j = author_book
main_idx = <sqlobject.index.SODatabaseIndex object>
q = author_book
class sqlmeta(instance)
Базовые классы: sqlobject.main.sqlmeta
childName = None
columnDefinitions = {'bookID': <ForeignKey b5b3988c book>, 'authorID': <ForeignKey b5b3964c author>}
columnList = [<SOForeignKey authorID connected to Author not null>, <SOForeignKey bookID connected to Book not null>]
columns = {'bookID': <SOForeignKey bookID connected to Book not null>, 'authorID': <SOForeignKey authorID connected to Author not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b5b39eac {'columns': (<ForeignKey b5b3964c author>,), 'name': 'author_idx'}>, <DatabaseIndex b5b3904c {'columns': (<ForeignKey b5b3988c book>,), 'name': 'book_idx'}>, <DatabaseIndex b5b3976c {'unique': True, 'columns': (<ForeignKey b5b3964c author>, <ForeignKey b5b3988c book>), 'name': 'main_idx'}>]
indexes = [<sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>]
joinDefinitions = []
joins = []
soClass

псевдоним класса AuthorBook

style = <sqlobject.styles.MixedCaseUnderscoreStyle object>
table = 'author_book'
class m_librarian.db.BookGenre(**kw)[исходный код]
Базовые классы: sqlobject.main.SQLObject
book
bookID
book_idx = <sqlobject.index.SODatabaseIndex object>
genre
genreID
genre_idx = <sqlobject.index.SODatabaseIndex object>
j = book_genre
main_idx = <sqlobject.index.SODatabaseIndex object>
q = book_genre
class sqlmeta(instance)
Базовые классы: sqlobject.main.sqlmeta
childName = None
columnDefinitions = {'bookID': <ForeignKey b5a544ec book>, 'genreID': <ForeignKey b5a5458c genre>}
columnList = [<SOForeignKey bookID connected to Book not null>, <SOForeignKey genreID connected to Genre not null>]
columns = {'bookID': <SOForeignKey bookID connected to Book not null>, 'genreID': <SOForeignKey genreID connected to Genre not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b5a544ac {'columns': (<ForeignKey b5a544ec book>,), 'name': 'book_idx'}>, <DatabaseIndex b5a5460c {'columns': (<ForeignKey b5a5458c genre>,), 'name': 'genre_idx'}>, <DatabaseIndex b5a5442c {'unique': True, 'columns': (<ForeignKey b5a544ec book>, <ForeignKey b5a5458c genre>), 'name': 'main_idx'}>]
indexes = [<sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>, <sqlobject.index.SODatabaseIndex object>]
joinDefinitions = []
joins = []
soClass

псевдоним класса BookGenre

style = <sqlobject.styles.MixedCaseUnderscoreStyle object>
table = 'book_genre'
m_librarian.db.open_db(db_uri=None)[исходный код]
m_librarian.db.init_db()[исходный код]
m_librarian.db.insert_name(table, name, **kw)[исходный код]
m_librarian.db.insert_author(surname, name, misc_name)[исходный код]
m_librarian.db.update_counters()[исходный код]