2012-08-12 41 views
3

對於支持Windows 8/WP8關係的ORM的任何建議?具有關係的簡單ORM

class Person { 
    int id; 
    int Name; 
    List<Address> Addresses; 
} 

class Address { 
    int id; 
    string Street; 
    string Country; 
} 

如果你做的人創建的表應該建立地址表過了,任何選擇查詢的人也將返回相應的地址。我知道EF/nHibernate這樣做,但不幸的是我們沒有WinRT中的System.Data。

+0

這可能有所幫助:http://stackoverflow.com/questions/10905084/can-i-use-entity-framework-or-linq-to-sql-with-windows-8-metro-style-apps – Adam 2012-08-12 15:48:15

回答

0

你最好的選擇可能是使用sqlite-net這是SQLite的

微ORM

蒂姆·豪雅對這個文章在這裏。 http://timheuer.com/blog/archive/2012/05/20/using-sqlite-in-metro-style-app.aspx

+0

我看到這是一個較老的響應,但鏈接似乎是讓sqllite在metro應用中運行,但與ORM沒有任何關係。請參閱http://stackoverflow.com/questions/10905084/can-i-use-entity-framework-or-linq-to-sql-with-windows-8-metro-style-apps?lq=1 – ezaspi 2015-06-29 13:22:34