Difference between revisions of "Python Object Classes"

From ISFDB
Jump to navigation Jump to search
(→‎authors: detail)
(Moving authors)
Line 1: Line 1:
==authors==
+
==Editing Classes==
 +
* [[ObjectClass:authors]] - Used to edit author information.
  
'''Location:''' common/authorClass.py
+
==Bibliographic Classes==
 +
* Later
  
===Data===
 
  
* '''self.db''' - Pointer to the MySQLdb object. Set on initialization.
 
 
 
These following are the core data values of this object. They have default values of ''.
 
 
* '''self.author_id''' - The database record number for the author.
 
* '''self.author_canonical''' - The author's canonical name.
 
* '''self.author_legalname''' - The author's legal name.
 
* '''self.author_lastname''' - The author's last name.
 
* '''self.author_birthplace''' - Birthplace of the author.
 
* '''self.author_birthdate''' - Birthdate of the author.
 
* '''self.author_deathdate''' - Deathdate of the author.
 
* '''self.author_emails''' - Email addresses associated with the author.
 
* '''self.author_webpages''' - Webpages associated with the author.
 
* '''self.author_wikipedia''' - The author's wikipedia URL.
 
* '''self.author_imdb''' - The author's IMDB URL.
 
* '''self.author_image''' - The author's image URL.
 
 
 
The following data are used to indicate whether of not one of the data values above have been set. This is necessary when editing to differentiate between a data value which hasn't been set yet, to one that is being cleared. These all have default values of 0:
 
 
* '''self.used_id''' - Indicates if '''self.author_id''' has been set.
 
* '''self.used_canonical''' - Indicates if '''self.author_canonical''' has been set.
 
* '''self.used_legalname''' - Indicates if '''self.author_legalname''' has been set.
 
* '''self.used_lastname''' - Indicates if '''self.author_lastname''' has been set.
 
* '''self.used_birthplace''' - Indicates if '''self.author_birthplace''' has been set.
 
* '''self.used_birthdate''' - Indicates if '''self.author_birthdate''' has been set.
 
* '''self.used_deathdate''' - Indicates if '''self.author_deathdate''' has been set.
 
* '''self.used_emails''' - Indicates if '''self.author_emails''' has been set.
 
* '''self.used_webpages''' - Indicates if '''self.author_webpages''' has been set.
 
* '''self.used_wikipedia''' - Indicates if '''self.author_wikipedia''' has been set.
 
* '''self.used_imdb''' - Indicates if '''self.author_imdb''' has been set.
 
* '''self.used_image''' - Indicates if '''self.author_image''' has been set.
 
 
 
===Methods===
 
 
* '''load(self, id)''' - Loads from the database with record=id into object data format.
 
* '''obj2xml(self)''' - Converts from object data format to XML.
 
* '''xml2obj(self, xml)''' - Converts from the XML data into object data format.
 
* '''cgi2obj(self)''' - Converts CGI form information into object data format.
 
 
==awards==
 
 
Methods:
 
 
* authors(self):
 
* load(self, id):
 
* loadXML(self, id):
 
* loadCommon(self, id, doXML):
 
* cgi2obj(self):
 
  
 
==Bibliography==
 
==Bibliography==

Revision as of 13:31, 2 June 2008

Editing Classes

Bibliographic Classes

  • Later


Bibliography

Methods:

  • loadAuthorData(self, author):
  • setViewsMode(self):
  • setAlphaMode(self):
  • setChronMode(self):
  • loadAllAuthorTitles(self):
  • loadAllPseudoTitles(self):
  • loadLongAuthorTitles(self):
  • loadShortAuthorTitles(self):
  • loadSerialTitles(self):
  • loadAuthorAwards(self):
  • loadAuthorCollaborators(self):
  • loadAuthorVariants(self):
  • loadNCSeriesData(self):
  • loadASeriesData(self):
  • loadESeriesData(self):
  • loadNFSeriesData(self):
  • loadShortSeriesData(self):
  • loadEssaySeriesData(self):
  • selfPseudo(self):
  • printIsPseudo(self, printLabel):
  • printHasPseudo(self, printLabel):
  • printAuthorData(self):
  • printNCSeries(self):
  • printASeries(self):
  • printESeries(self):
  • printNFSeries(self):
  • printShortSeries(self):
  • printEssaySeries(self):
  • displayWorks(self, type, add_serials = DISPLAY_ADD_SERIALS):
  • printStrayPubs(self):

interviewEntry

Methods:

  • setPage(self, page):
  • setTitle(self, title):
  • setID(self, id):
  • setDate(self, date):
  • setInterviewees(self, authors):
  • setInterviewers(self, authors):
  • setOldInterview(self, oldinterview):
  • xmlTitle(self):
  • xmlCloneTitle(self):
  • printTitle(self):

ISFDB

Methods:

  • SetForm(self, form):
  • SetPubID(self, pubid):
  • SetDb(self, db):
  • GetColumnList(self):
  • GetValueList(self):
  • GetChanges(self):
  • GetStart(self):
  • SyncTablesNew(self, newtitle, newauthor, newtag, newyear, newctype):
  • BuildColumnValues(self, target):
  • HTMLBuildColumnValues(self, target):
  • updatetable(self, newvar, oldvar, field, label, table):
  • ExtractTermsFromForm(self, default_order):
  • ExtractTermsFromCmdline(self):
  • BuildSearchNow(self):
  • BuildSearchNext(self):
  • BuildPubSQL_FromForm(self, form, start):
  • BuildAuthSQL_FromForm(self, form, start):
  • BuildTitleSQL_FromForm(self, form, start):
  • BuildPubSQL_FromCmdline(self):
  • BuildAuthSQL_FromCmdline(self):
  • BuildTitleSQL_FromCmdline(self):
  • updatepub(self, newvar, oldvar, field, label):
  • updateauth(self, newvar, oldvar, field, label):
  • updatetitle(self, newvar, oldvar, field, label):
  • updatenote(self, newnote, oldnote, pubid, label):

publishers

Methods:

  • load(self, id):
  • obj2xml(self):
  • xml2obj(self, xml):
  • cgi2obj(self):

pubs

Methods:

  • pushTitle(self, titleEntry):
  • pushReview(self, reviewEntry):
  • pushInterview(self, interviewEntry):
  • xmlContent(self):
  • xmlCloneContent(self):
  • printContent(self):
  • authors(self):
  • artists(self):
  • load(self, id):
  • obj2xml(self):
  • cgi2obj(self):

reviewEntry

Methods:

  • setPage(self, page):
  • setTitle(self, title):
  • setID(self, id):
  • setDate(self, date):
  • setBookAuthors(self, authors):
  • setReviewers(self, authors):
  • setOldReview(self, oldreview):
  • xmlTitle(self):
  • xmlCloneTitle(self):
  • printTitle(self):

series

Methods:

  • load(self, id):
  • loadXML(self, id):
  • loadCommon(self, id, doXML):
  • cgi2obj(self):

Series

Methods:

  • Print(self, works, nottype, id, collabs, serials, variants, series_type):
  • AddSeries(self, id, label, parent):
  • Fixup(self):

titleEntry

Methods:

  • setPage(self, page):
  • setTitle(self, title):
  • setID(self, id):
  • setDate(self, date):
  • setType(self, type):
  • setLength(self, length):
  • setAuthors(self, authors):
  • setOldTitle(self, oldtitle):
  • xmlTitle(self):
  • xmlCloneTitle(self):
  • printTitle(self):

titles

Methods:

  • authors(self):
  • load(self, id):
  • loadXML(self, id):
  • loadCommon(self, id, doXML):
  • cgi2obj(self):