Object XML Mappings
Upcoming SlideShare
Loading in...5
×
 

Object XML Mappings

on

  • 1,074 views

 

Statistics

Views

Total Views
1,074
Views on SlideShare
1,048
Embed Views
26

Actions

Likes
1
Downloads
26
Comments
0

2 Embeds 26

http://www.joostdiepenmaat.com 25
http://www.slideshare.net 1

Accessibility

Upload Details

Uploaded via as Apple Keynote

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />
  • <br />

Object XML Mappings Object XML Mappings Presentation Transcript

  • Object XML Mappings An introduction Joost Diepenmaat j.h.b.diepennaat@student.utwente.nl Friday, February 27, 2009
  • 1. Introduction to ORM’s in the SQL world! 2. Object XML Mappings Friday, February 27, 2009
  • Enterprise Application Layers Presentation Interaction Domain Logic Data Source Storage Friday, February 27, 2009
  • Enterprise Application Layers Presentation Interaction ORM’s live Domain Logic here! Data Source Storage Friday, February 27, 2009
  • Object Relational Mapping firstname lastname age Joost Diepenmaat 26 Jan Klaassen 24 John Doe 23 Friday, February 27, 2009
  • Object Relational Mapping firstname lastname age Class Student Joost Diepenmaat 26 firstname Jan Klaassen 24 lastname John Doe 23 age Friday, February 27, 2009
  • Object Relational Mapping firstname lastname age Class Student Joost Diepenmaat 26 firstname Jan Klaassen 24 lastname John Doe 23 age Friday, February 27, 2009
  • ORM & ActiveRecord quot;An object that wraps a row in a database table or view, encapsulates the database access, and adds domain logic on that data.quot; - Martin Fowler Friday, February 27, 2009
  • Very short demo... Friday, February 27, 2009
  • More ORM! Friday, February 27, 2009
  • Associations class Student < ActiveRecord::Base has_many :courses belongs_to :university end student = Student.find_by_name(quot;Joostquot;) student.courses #returns all courses Friday, February 27, 2009
  • Validations class Student < ActiveRecord::Base validates_presence_of :firstname, :lastname validates_uniqueness_of :number validates_acceptance_of :terms_of_service validates_confirmation_of :password end Friday, February 27, 2009
  • ✓Associations ✓Inheritance ✓ ✓ Validations Direct manipulation ✓Finders ✓Transactions ✓ ✓ Callbacks Database abstraction ✓Observers ✓etc. etc. Friday, February 27, 2009
  • ORM’s are popular • Java: Hibernate • Ruby: ActiveRecord, DataMapper • .Net: LINQ • Python: Django’s ORM • More, more, more.... Friday, February 27, 2009
  • ORM’s are SQL based. Friday, February 27, 2009
  • Complex XML standards • OpenXML • ebXML • GIS • XBRL • Universal • Healthcare XML Business • Voice XML Language Friday, February 27, 2009
  • ORM’s do not support native XML storage. Friday, February 27, 2009
  • 2. Object Relational XML Mappings Friday, February 27, 2009
  • Place XML in domain logic into separate classes. Friday, February 27, 2009
  • <student> <name>Joost</name> <courses> <course> <title>XML & DB I</title> <score>7</score> </course> <course> <title>XML & DB II</title> <score>9</score> </course>... Friday, February 27, 2009
  • Student <student> Class <name>Joost</name> <courses> <course> <title>XML & DB I</title> <score>7</score> </course> <course> <title>XML & DB II</title> <score>9</score> </course>... Friday, February 27, 2009
  • Student <student> Class <name>Joost</name> <courses> Course <course> Class <title>XML & DB I</title> <score>7</score> </course> <course> <title>XML & DB II</title> <score>9</score> </course>... Friday, February 27, 2009
  • Student <student> Class <name>Joost</name> <courses> Course <course> Class <title>XML & DB I</title> <score>7</score> </course> <course> <title>XML & DB II</title> <score>9</score> </course>... student = Student.find_by_name(quot;Joostquot;) student.courses Friday, February 27, 2009
  • Thesis studies: The possibilities of an OXM with XML/XPath as a base language for storage. Friday, February 27, 2009
  • Research Questions 1. How can we extend RoR with XPath Accelerator to create an XML database for efficient XML storage and XPath processing? 2. How can we implement XML based Object Mapping on the XML database created? 3. What kind of XML related functionality can we add to the system? Friday, February 27, 2009
  • layer contains Object Student Elements map tag “<student>” Pathfinder core XPath to SQL queries SQL storage pre | size | level Friday, February 27, 2009
  • Elements Map University Student Course Objects Object Elements XPath Elements Etc. Mapping Map Register Queries Pathfinder SQL Friday, February 27, 2009
  • Questions? Friday, February 27, 2009