contents 7.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
  2. <model name="" userDefinedModelVersionIdentifier="" type="com.apple.IDECoreDataModeler.DataModel" documentVersion="1.0" lastSavedToolsVersion="1811" systemVersion="12C60" minimumToolsVersion="Xcode 4.3" macOSVersion="Automatic" iOSVersion="Automatic">
  3. <entity name="Contact" representedClassName="Contact" syncable="YES">
  4. <attribute name="abRecordId" optional="YES" attributeType="Integer 32" indexed="YES" syncable="YES"/>
  5. <attribute name="firstName" optional="YES" attributeType="String" syncable="YES"/>
  6. <attribute name="identity" attributeType="String" indexed="YES" syncable="YES"/>
  7. <attribute name="imageData" optional="YES" attributeType="Binary" syncable="YES"/>
  8. <attribute name="lastName" optional="YES" attributeType="String" syncable="YES"/>
  9. <attribute name="publicKey" attributeType="Binary" syncable="YES"/>
  10. <attribute name="sortIndex" optional="YES" attributeType="Integer 32" defaultValueString="0" indexed="YES" syncable="YES"/>
  11. <attribute name="sortInitial" optional="YES" attributeType="String" syncable="YES"/>
  12. <attribute name="verificationLevel" attributeType="Integer 16" syncable="YES"/>
  13. <attribute name="verifiedEmail" optional="YES" attributeType="String" syncable="YES"/>
  14. <attribute name="verifiedMobileNo" optional="YES" attributeType="String" syncable="YES"/>
  15. <relationship name="conversations" optional="YES" toMany="YES" deletionRule="Cascade" destinationEntity="Conversation" inverseName="contact" inverseEntity="Conversation" syncable="YES"/>
  16. </entity>
  17. <entity name="Conversation" representedClassName="Conversation" syncable="YES">
  18. <attribute name="lastTypingStart" optional="YES" transient="YES" attributeType="Date" syncable="YES"/>
  19. <attribute name="typing" transient="YES" attributeType="Boolean" defaultValueString="NO" syncable="YES"/>
  20. <attribute name="unreadMessageCount" attributeType="Integer 32" defaultValueString="0" syncable="YES"/>
  21. <relationship name="contact" minCount="1" maxCount="1" deletionRule="Nullify" destinationEntity="Contact" inverseName="conversations" inverseEntity="Contact" syncable="YES"/>
  22. <relationship name="lastMessage" optional="YES" minCount="1" maxCount="1" deletionRule="Nullify" destinationEntity="Message" syncable="YES"/>
  23. <relationship name="messages" optional="YES" toMany="YES" deletionRule="Cascade" ordered="YES" destinationEntity="Message" inverseName="conversation" inverseEntity="Message" syncable="YES"/>
  24. </entity>
  25. <entity name="ImageData" representedClassName="ImageData" syncable="YES">
  26. <attribute name="data" attributeType="Binary" allowsExternalBinaryDataStorage="YES" syncable="YES"/>
  27. <attribute name="height" attributeType="Integer 16" defaultValueString="0" syncable="YES"/>
  28. <attribute name="width" attributeType="Integer 16" defaultValueString="0" syncable="YES"/>
  29. </entity>
  30. <entity name="ImageMessage" representedClassName="ImageMessage" parentEntity="Message" syncable="YES">
  31. <attribute name="encryptionKey" optional="YES" attributeType="Binary" syncable="YES"/>
  32. <attribute name="imageBlobId" optional="YES" attributeType="Binary" syncable="YES"/>
  33. <attribute name="imageNonce" optional="YES" attributeType="Binary" syncable="YES"/>
  34. <attribute name="imageSize" optional="YES" attributeType="Integer 32" defaultValueString="0" syncable="YES"/>
  35. <attribute name="progress" optional="YES" transient="YES" attributeType="Float" syncable="YES"/>
  36. <relationship name="image" optional="YES" maxCount="1" deletionRule="Cascade" destinationEntity="ImageData" syncable="YES"/>
  37. <relationship name="thumbnail" optional="YES" maxCount="1" deletionRule="Cascade" destinationEntity="ImageData" syncable="YES"/>
  38. </entity>
  39. <entity name="LocationMessage" representedClassName="LocationMessage" parentEntity="Message" syncable="YES">
  40. <attribute name="accuracy" optional="YES" attributeType="Double" defaultValueString="0.0" syncable="YES"/>
  41. <attribute name="latitude" attributeType="Double" defaultValueString="0.0" syncable="YES"/>
  42. <attribute name="longitude" attributeType="Double" defaultValueString="0.0" syncable="YES"/>
  43. <attribute name="reverseGeocodingResult" optional="YES" attributeType="String" syncable="YES"/>
  44. </entity>
  45. <entity name="Message" representedClassName="BaseMessage" isAbstract="YES" syncable="YES">
  46. <attribute name="date" attributeType="Date" indexed="YES" syncable="YES"/>
  47. <attribute name="delivered" attributeType="Boolean" syncable="YES"/>
  48. <attribute name="deliveryDate" optional="YES" attributeType="Date" syncable="YES"/>
  49. <attribute name="id" attributeType="Binary" indexed="YES" syncable="YES"/>
  50. <attribute name="isOwn" attributeType="Boolean" indexed="YES" syncable="YES"/>
  51. <attribute name="read" attributeType="Boolean" indexed="YES" syncable="YES"/>
  52. <attribute name="readDate" optional="YES" attributeType="Date" syncable="YES"/>
  53. <attribute name="sendFailed" optional="YES" attributeType="Boolean" syncable="YES"/>
  54. <attribute name="sent" attributeType="Boolean" syncable="YES"/>
  55. <attribute name="userack" attributeType="Boolean" syncable="YES"/>
  56. <attribute name="userackDate" optional="YES" attributeType="Date" syncable="YES"/>
  57. <relationship name="conversation" minCount="1" maxCount="1" deletionRule="Nullify" destinationEntity="Conversation" inverseName="messages" inverseEntity="Conversation" syncable="YES"/>
  58. </entity>
  59. <entity name="TextMessage" representedClassName="TextMessage" parentEntity="Message" syncable="YES">
  60. <attribute name="text" attributeType="String" syncable="YES"/>
  61. </entity>
  62. <entity name="VideoData" representedClassName="VideoData" syncable="YES">
  63. <attribute name="data" attributeType="Binary" allowsExternalBinaryDataStorage="YES" syncable="YES"/>
  64. </entity>
  65. <entity name="VideoMessage" representedClassName="VideoMessage" parentEntity="Message" syncable="YES">
  66. <attribute name="duration" attributeType="Float" defaultValueString="0.0" syncable="YES"/>
  67. <attribute name="encryptionKey" optional="YES" attributeType="Binary" syncable="YES"/>
  68. <attribute name="progress" optional="YES" transient="YES" attributeType="Float" syncable="YES"/>
  69. <attribute name="videoBlobId" optional="YES" attributeType="Binary" syncable="YES"/>
  70. <attribute name="videoSize" optional="YES" attributeType="Integer 32" defaultValueString="0" syncable="YES"/>
  71. <relationship name="thumbnail" minCount="1" maxCount="1" deletionRule="Cascade" destinationEntity="ImageData" syncable="YES"/>
  72. <relationship name="video" optional="YES" maxCount="1" deletionRule="Cascade" destinationEntity="VideoData" syncable="YES"/>
  73. </entity>
  74. <elements>
  75. <element name="Contact" positionX="0" positionY="0" width="128" height="225"/>
  76. <element name="Conversation" positionX="0" positionY="0" width="128" height="135"/>
  77. <element name="ImageData" positionX="160" positionY="192" width="128" height="90"/>
  78. <element name="ImageMessage" positionX="0" positionY="0" width="128" height="150"/>
  79. <element name="LocationMessage" positionX="160" positionY="192" width="128" height="105"/>
  80. <element name="Message" positionX="0" positionY="0" width="128" height="225"/>
  81. <element name="TextMessage" positionX="0" positionY="0" width="128" height="60"/>
  82. <element name="VideoData" positionX="160" positionY="192" width="128" height="60"/>
  83. <element name="VideoMessage" positionX="160" positionY="192" width="128" height="150"/>
  84. </elements>
  85. </model>