xy.py
changeset 5627 a7e40cccdc9b
parent 5613 bc0ebfbf5c5d
child 5663 d93a875a9d94
equal deleted inserted replaced
5611:55366f5b7a9f 5627:a7e40cccdc9b
    13 # FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
    13 # FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more
    14 # details.
    14 # details.
    15 #
    15 #
    16 # You should have received a copy of the GNU Lesser General Public License along
    16 # You should have received a copy of the GNU Lesser General Public License along
    17 # with CubicWeb.  If not, see <http://www.gnu.org/licenses/>.
    17 # with CubicWeb.  If not, see <http://www.gnu.org/licenses/>.
    18 """map standard cubicweb schema to xml vocabularies
    18 """map standard cubicweb schema to xml vocabularies"""
    19 
       
    20 """
       
    21 
    19 
    22 from yams import xy
    20 from yams import xy
    23 
    21 
       
    22 xy.register_prefix('http://www.w3.org/1999/02/22-rdf-syntax-ns#', 'rdf')
    24 xy.register_prefix('http://purl.org/dc/elements/1.1/', 'dc')
    23 xy.register_prefix('http://purl.org/dc/elements/1.1/', 'dc')
    25 xy.register_prefix('http://xmlns.com/foaf/0.1/',       'foaf')
    24 xy.register_prefix('http://xmlns.com/foaf/0.1/',       'foaf')
    26 xy.register_prefix('http://usefulinc.com/ns/doap#',    'doap')
    25 xy.register_prefix('http://usefulinc.com/ns/doap#',    'doap')
    27 xy.register_prefix('http://rdfs.org/sioc/ns#',         'sioc')
    26 xy.register_prefix('http://rdfs.org/sioc/ns#',         'sioc')
    28 xy.register_prefix('http://www.w3.org/2002/07/owl#',   'owl')
    27 xy.register_prefix('http://www.w3.org/2002/07/owl#',   'owl')
    30 
    29 
    31 xy.add_equivalence('creation_date', 'dc:date')
    30 xy.add_equivalence('creation_date', 'dc:date')
    32 xy.add_equivalence('created_by', 'dc:creator')
    31 xy.add_equivalence('created_by', 'dc:creator')
    33 xy.add_equivalence('description', 'dc:description')
    32 xy.add_equivalence('description', 'dc:description')
    34 xy.add_equivalence('CWUser', 'foaf:Person')
    33 xy.add_equivalence('CWUser', 'foaf:Person')
    35 xy.add_equivalence('CWUser login', 'dc:title')
    34 xy.add_equivalence('CWUser login', 'foaf:Person dc:title')
    36 xy.add_equivalence('CWUser surname', 'foaf:Person foaf:name')
    35 xy.add_equivalence('CWUser surname', 'foaf:Person foaf:name')