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 = {'count': <IntCol b6089c8cL count>, 'misc_name': <UnicodeCol b60de3ecL misc_name>, 'surname': <UnicodeCol b614396cL surname>, 'name': <UnicodeCol b60de90cL name>}
columnList = [<SOUnicodeCol surname not null>, <SOUnicodeCol name not null>, <SOUnicodeCol misc_name not null>, <SOIntCol count not null>]
columns = {'count': <SOIntCol count not null>, 'misc_name': <SOUnicodeCol misc_name not null>, 'surname': <SOUnicodeCol surname not null>, 'name': <SOUnicodeCol name not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b6089c6cL {'unique': True, 'name': 'full_name_idx', 'columns': (<UnicodeCol b614396cL surname>, <UnicodeCol b60de90cL name>, <UnicodeCol b60de3ecL misc_name>)}>, <DatabaseIndex b6089cccL {'name': 'count_idx', 'columns': (<IntCol b6089c8cL count>,)}>]
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'
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 = {'extensionID': <ForeignKey b609c0acL extension>, 'title': <UnicodeCol b6093eecL title>, 'deleted': <BoolCol b609c08cL deleted>, 'series': <UnicodeCol b6093facL series>, 'languageID': <ForeignKey b609c0ecL language>, 'ser_no': <IntCol b6093fccL ser_no>, 'file': <StringCol b60938acL file>, 'lib_id': <StringCol b609c06cL lib_id>, 'date': <DateCol b609c0ccL date>, 'archive': <StringCol b6093fecL archive>, 'size': <IntCol b609c04cL size>}
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 = {'extensionID': <SOForeignKey extensionID connected to Extension not null>, 'title': <SOUnicodeCol title not null>, 'deleted': <SOBoolCol deleted not null>, 'series': <SOUnicodeCol series not null>, 'languageID': <SOForeignKey languageID connected to Language>, 'ser_no': <SOIntCol ser_no>, 'file': <SOStringCol file not null>, 'lib_id': <SOStringCol lib_id not null>, 'date': <SODateCol date not null>, 'archive': <SOStringCol archive not null>, 'size': <SOIntCol size not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b609c10cL {'name': 'title_idx', 'columns': (<UnicodeCol b6093eecL title>,)}>, <DatabaseIndex b609c02cL {'name': 'series_idx', 'columns': (<UnicodeCol b6093facL series>,)}>, <DatabaseIndex b609c12cL {'name': 'ser_no_idx', 'columns': (<IntCol b6093fccL ser_no>,)}>, <DatabaseIndex b609c16cL {'name': 'archive_idx', 'columns': (<StringCol b6093fecL archive>,)}>, <DatabaseIndex b609c1acL {'unique': True, 'name': 'archive_file_idx', 'columns': (<StringCol b6093fecL archive>, <StringCol b60938acL file>)}>, <DatabaseIndex b609c1ccL {'name': 'file_idx', 'columns': (<StringCol b60938acL file>,)}>, <DatabaseIndex b609c20cL {'name': 'size_idx', 'columns': (<IntCol b609c04cL size>,)}>, <DatabaseIndex b609c24cL {'name': 'deleted_idx', 'columns': (<BoolCol b609c08cL deleted>,)}>, <DatabaseIndex b609c28cL {'name': 'extension_idx', 'columns': (<ForeignKey b609c0acL extension>,)}>, <DatabaseIndex b609c2ccL {'name': 'date_idx', 'columns': (<DateCol b609c0ccL date>,)}>, <DatabaseIndex b609c30cL {'name': 'language_idx', 'columns': (<ForeignKey b609c0ecL language>,)}>]
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'
Book.title
Book.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 = {'count': <IntCol b60a47ccL count>, 'name': <UnicodeCol b60a4e0cL name>}
columnList = [<SOUnicodeCol name not null>, <SOIntCol count not null>]
columns = {'count': <SOIntCol count not null>, 'name': <SOUnicodeCol name not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b60a4e2cL {'name': 'count_idx', 'columns': (<IntCol b60a47ccL count>,)}>]
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 = {'count': <IntCol b60a924cL count>, 'name': <UnicodeCol b60a922cL name>, 'title': <UnicodeCol b60a914cL title>}
columnList = [<SOUnicodeCol name not null>, <SOUnicodeCol title not null>, <SOIntCol count not null>]
columns = {'count': <SOIntCol count not null>, 'name': <SOUnicodeCol name not null>, 'title': <SOUnicodeCol title not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b60a928cL {'name': 'title_idx', 'columns': (<UnicodeCol b60a914cL title>,)}>, <DatabaseIndex b60a92ecL {'name': 'count_idx', 'columns': (<IntCol b60a924cL count>,)}>]
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'
Genre.title
Genre.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 = {'count': <IntCol b60a998cL count>, 'name': <UnicodeCol b60a98acL name>}
columnList = [<SOUnicodeCol name not null>, <SOIntCol count not null>]
columns = {'count': <SOIntCol count not null>, 'name': <SOUnicodeCol name not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b60a99acL {'name': 'count_idx', 'columns': (<IntCol b60a998cL count>,)}>]
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 = {'authorID': <ForeignKey b60937ecL author>, 'bookID': <ForeignKey b609384cL book>}
columnList = [<SOForeignKey authorID connected to Author not null>, <SOForeignKey bookID connected to Book not null>]
columns = {'authorID': <SOForeignKey authorID connected to Author not null>, 'bookID': <SOForeignKey bookID connected to Book not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b60937ccL {'name': 'author_idx', 'columns': (<ForeignKey b60937ecL author>,)}>, <DatabaseIndex b60934ecL {'name': 'book_idx', 'columns': (<ForeignKey b609384cL book>,)}>, <DatabaseIndex b60932acL {'unique': True, 'name': 'main_idx', 'columns': (<ForeignKey b60937ecL author>, <ForeignKey b609384cL book>)}>]
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 = {'genreID': <ForeignKey b60a484cL genre>, 'bookID': <ForeignKey b60a46ecL book>}
columnList = [<SOForeignKey bookID connected to Book not null>, <SOForeignKey genreID connected to Genre not null>]
columns = {'genreID': <SOForeignKey genreID connected to Genre not null>, 'bookID': <SOForeignKey bookID connected to Book not null>}
idName = 'id'
indexDefinitions = [<DatabaseIndex b60a46ccL {'name': 'book_idx', 'columns': (<ForeignKey b60a46ecL book>,)}>, <DatabaseIndex b60a478cL {'name': 'genre_idx', 'columns': (<ForeignKey b60a484cL genre>,)}>, <DatabaseIndex b60a47ecL {'unique': True, 'name': 'main_idx', 'columns': (<ForeignKey b60a46ecL book>, <ForeignKey b60a484cL genre>)}>]
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()[исходный код]