#!/usr/bin/python # This file generated by a program. do not edit. import Bio.EUtils.POM # $Id: LinkOut.py,v 1.2 2003/06/13 02:08:57 chapmanb Exp $ # LinkOut DTD version 1.1 # # This document is still under revision and may change. # # Changes: # version 1.1: # - SubjectType and Attribute lists updated # - DTD is XML # version 1.6: # - tag added # # version sequence refreshed to 1.1 on 2001/09/20 # # version 1.2: # - SubObjectSelector updated to # # # # version 1.3: # - Entities added: lo.name, lo.genus, lo.species, lo.subsp # # version 1.6: # - Enitities added: lo.month, lo.authln # # # Typical usage: # # # # ... # # # or: # # # # ... # # # # # # Rule based URL generation. In general, to build the # URL both base and rule are required, where base is the # HTTP base address, for example: # # http://www.sciencemag.org/cgi/content/full/ # # and rule is in the following format: # # &lo.vol;/&lo.iss;/&lo.page; # # LinkOut will replace the keywords in rule with the actual # value for a retrieved citation. Therefore, rule will be # translated into: 281/5384/1863 # # The program will concatenate base with rule: # # http://www.sciencemag.org/cgi/content/full/281/5384/1863 # # The following keywords are supported for any database: # # lo.id - Unique identifier (PMID, GI, TaxID, etc.) # # For PubMed only: # # lo.pii - Publisher Item Identification. Must be submitted # by the publisher. For example, 6847, in the PubMed DTD this # ID is an attribute of the ArticleId element. # # lo.doi - Article DOI # # lo.issn - Journal ISSN code # # lo.issnl - Journal ISSN code without the dash # # lo.jtit - Journal title (MEDLINE abbreviation) # # lo.muid - MEDLINE Unique Identifier # # lo.msrc - MEDLINE source. For example, Exp Brain Res 1998 # Oct; 122(3):339-350 # # lo.vol - Volume # # lo.iss - Issue # # lo.page - First page # # lo.inum - Item number for online journals. May be a # single letter. # # lo.year - Four digit year. For example, 1998 # # lo.yr - Last two digit of year. For example, 98; 00 # # lo.yl - Last digit of year. For example, for 1999 use 9; # for 1990 use 0 # # lo.month - The month. For example, September # # lo.mon - The 3 letter month abbreviation. For example, Sep # # lo.mo - Two digit month. For example, 01; 12 # # lo.day - Two digit day. For example, 01; 31 # # lo.otit - Article title # # lo.auth - First author # # lo.authln - Last name of the first author # # # For Sequence databases (Nucleotide, Protein, Structure, Genome): # # lo.pacc - Primary accession for sequences # # For Taxonomy only: # # lo.name - Full scientific name. For example: "Homo sapiens neanderthalensis" # # lo.genus - Genius name. For example: "Homo" # # lo.species - Species epithet. For example: "sapiens" # # lo.subsp - Sub-species epithet. For example: "neanderthalensis" # # # # internal DTD entities class SubjectType(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) # can be one of the following; see LinkOut SubjectTypes and Attributes # at http://www.ncbi.nlm.nih.gov/entrez/linkout/doc/subjecttypes.html for a description # of these elements: # # //EDUCATION # conferences/meetings/workshops # glossaries/dictionaries # online tutorials/courses # # //FUNDING SOURCES # funding sources # # //LITERATURE # abstracts/indexes/summaries # aggregators # books # individual online article # images # libraries # patent databases # publishers/providers # # //MEDICAL # clinical trials # consumer health # diagnostics # disease organizations # medical equipment and devices # pharmacology # treatment guidelines # # //MOLECULAR BIOLOGY DATABASES # DNA/protein sequence # gene/protein/disease-specific # gene expression # mapping # organism-specific # population/variation # structure # taxonomy/phylogenetic # # //RESEARCH MATERIALS # clones/clone libraries # culture/stock collections # laboratory equipment # oligonucleotides # other reagents # # //RESEARCHERS # colleges/universities # companies/research institutes # directories # individuals # societies/associations # # //TOOLS # 3D structure prediction/functional modeling # primer design # protein identification/characterization # restriction mapping # sequence screening/similarity/alignment # sequence viewer # translation # # class Attribute(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) # can be one of the following; see LinkOut SubjectTypes and Attributes # at http://www.ncbi.nlm.nih.gov/entrez/linkout/doc/subjecttypes.html for a description # of these elements: # //BARRIERS # registration required # subscription/membership/fee required # # //OWNERSHIP # author of URL # publisher of information in URL # # //PUBLICATIONS # document delivery # full-text first published # full-text online # full-text PDF # full-text PostScript # library-local # summary # # # This is the top level element for Provider class Provider(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u',', [(u'ProviderId', ''), (u'Name', ''), (u'NameAbbr', ''), (u'SubjectType', u'*'), (u'Attribute', u'*'), (u'Url', u'*'), (u'IconUrl', u'*'), (u'Brief', u'?')], '')) class ProviderId(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class Name(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class NameAbbr(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class Url(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) ATTLIST = Bio.EUtils.POM.AttributeList([Bio.EUtils.POM.XMLAttribute('LNG', ['DA', 'DE', 'EN', 'EL', 'ES', 'FR', 'IT', 'IW', 'JA', 'NL', 'NO', 'RU', 'SV', 'ZH'], 13, u'EN')]) class IconUrl(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) ATTLIST = Bio.EUtils.POM.AttributeList([Bio.EUtils.POM.XMLAttribute('LNG', ['DA', 'DE', 'EN', 'EL', 'ES', 'FR', 'IT', 'IW', 'JA', 'NL', 'NO', 'RU', 'SV', 'ZH'], 13, u'EN')]) class Brief(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) # End of Privider group class LinkSet(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [(u'Link', u'+')], '')) class Link(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u',', [(u'LinkId', ''), (u'ProviderId', ''), (u'IconUrl', u'*'), (u'|', [(u'ObjectSelector', ''), (u'SubObjectSelector', '')], ''), (u'ObjectUrl', u'+')], '')) class LinkId(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class ObjectSelector(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u',', [(u'Database', ''), (u'ObjectList', '')], '')) class Database(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) # The databases available in LinkOut include the following: # PubMed, Nucleotide, Protein, Genome, Structure, PopSet, Taxonomy and OMIM class ObjectList(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u'|', [(u'Query', ''), (u'ObjId', '')], u'+')) class Query(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class ObjId(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) # End of ObjectList group # End of ObjectSelector group # Libraries must use SubObjectSelector to refer to the sub providers class SubObjectSelector(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u',', [(u'Database', ''), (u'SubProvider', '')], '')) class SubProvider(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u',', [(u'NameAbbr', ''), (u'|', [(u'InclQuery', ''), (u'ExclQuery', '')], u'*')], '')) class InclQuery(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class ExclQuery(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) # End of SubObjectSelector group class ObjectUrl(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u',', [(u'|', [(u',', [(u'Base', ''), (u'|', [(u'Rule', ''), (u'RuleToMany', '')], u'?')], ''), (u'|', [(u'Rule', ''), (u'RuleToMany', '')], '')], ''), (u'UrlName', u'?'), (u'SubjectType', u'*'), (u'Attribute', u'*')], '')) ATTLIST = Bio.EUtils.POM.AttributeList([Bio.EUtils.POM.XMLAttribute('LNG', ['DA', 'DE', 'EN', 'EL', 'ES', 'FR', 'IT', 'IW', 'JA', 'NL', 'NO', 'RU', 'SV', 'ZH'], 13, u'EN')]) class Base(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class pad(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) ATTLIST = Bio.EUtils.POM.AttributeList([Bio.EUtils.POM.XMLAttribute('with', 1, 11, None), Bio.EUtils.POM.XMLAttribute('width', 1, 11, None), Bio.EUtils.POM.XMLAttribute('align', ['left', 'right'], 13, u'right')]) # used to mark up strings that require padding to create fixed-length string # attributes. # with a character to pad with (required) # width result string size (required) (integer) # align the text should align to (left|right) (default:right) # class apad(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) ATTLIST = Bio.EUtils.POM.AttributeList([Bio.EUtils.POM.XMLAttribute('with', 1, 11, None), Bio.EUtils.POM.XMLAttribute('width', 1, 11, None), Bio.EUtils.POM.XMLAttribute('align', ['left', 'right'], 13, u'right')]) # used to mark up strings that require padding to create fixed-length string # attributes. It skips all preceding alpha characters before padding # with a character to pad with (required) # width result string size (required) (integer) # align the text should align to (left|right) (default:right) # Examples: # E32 => "E00032" # 640 => "000640" # class subs(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) ATTLIST = Bio.EUtils.POM.AttributeList([Bio.EUtils.POM.XMLAttribute('for', 1, 11, None), Bio.EUtils.POM.XMLAttribute('with', 1, 11, None)]) # substitute one string for another in the element's content # # for the string to replace # with the string to substitute # class toupper(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) # convert element content into upper case class tolower(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) # convert element content into lower case class strip(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) ATTLIST = Bio.EUtils.POM.AttributeList([Bio.EUtils.POM.XMLAttribute('what', ['spaces', 'letters', 'nondigits', 'digits'], 11, None)]) # strip off spaces/letters/digits in the element's content # class normalize(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) # are used for normalization of &lo.voll , &lo.iss; elements. # Examples: # "Pt 5" ==> "5" # "3 Suppl" ==> "3" # "2A Pt 3" ==> "2A" # "10 Suppl 2 Pt 1" ==> "10" # "2/3" ==> "2/3" # class Rule(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('|', [('#PCDATA', ''), (u'pad', ''), (u'apad', ''), (u'subs', ''), (u'toupper', ''), (u'tolower', ''), (u'strip', ''), (u'normalize', '')], '*')) class UrlName(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) class RuleToMany(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel((u',', [(u'Rule', ''), (u'Separator', '')], '')) class Separator(Bio.EUtils.POM.ElementNode): CONTENTMODEL = Bio.EUtils.POM.ContentModel(('', [('#PCDATA', '')], '')) # End of ObjectUrl group # End of Link group # End of LinkSet group