DB
Database
name
tables
Table
name
foreignkeys
primary_key
columns
database
Column
table
type
int
notNull
false
name
key
foreign
ForeignKey
isMany
referencedKey
foreign_column
DataType
int
int
varchar
varchar
text
text
unknown
unknown
bool
bool
decimal
decimal
Key
name
key_column
referenced
<?xml version="1.0" encoding="UTF-8"?>
<ecore:EPackage xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:ecore="http://www.eclipse.org/emf/2002/Ecore" name="DB" nsURI="DB" nsPrefix="DB">
  <eClassifiers xsi:type="ecore:EClass" name="Database">
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="tables" lowerBound="1"
        upperBound="-1" eType="#//Table" containment="true"/>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="Table">
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="foreignkeys" upperBound="-1"
        eType="#//ForeignKey" containment="true"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="primary_key" upperBound="-1"
        eType="#//Key" containment="true"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="columns" lowerBound="1"
        upperBound="-1" eType="#//Column" containment="true"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="database" lowerBound="1"
        eType="#//Database"/>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="Column">
    <eStructuralFeatures xsi:type="ecore:EReference" name="table" eType="#//Table"/>
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="type" eType="#//DataType"
        defaultValueLiteral="int"/>
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="notNull" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBoolean"
        defaultValueLiteral="false"/>
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="key" eType="#//Key"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="foreign" upperBound="-1"
        eType="#//ForeignKey"/>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="ForeignKey">
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="isMany" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EBooleanObject"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="referencedKey" eType="#//Key"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="foreign_column" eType="#//Column"/>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EEnum" name="DataType">
    <eLiterals name="int"/>
    <eLiterals name="varchar" literal="varchar"/>
    <eLiterals name="text"/>
    <eLiterals name="unknown" literal="unknown"/>
    <eLiterals name="bool" literal="bool"/>
    <eLiterals name="decimal"/>
  </eClassifiers>
  <eClassifiers xsi:type="ecore:EClass" name="Key">
    <eStructuralFeatures xsi:type="ecore:EAttribute" name="name" eType="ecore:EDataType http://www.eclipse.org/emf/2002/Ecore#//EString"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="key_column" lowerBound="1"
        upperBound="-1" eType="#//Column"/>
    <eStructuralFeatures xsi:type="ecore:EReference" name="referenced" eType="#//ForeignKey"/>
  </eClassifiers>
</ecore:EPackage>

{"directed":true,"nodes":[{"nsPrefix":"DB","nsURI":"DB","name":"DB","id":0,"eClass":"EPackage"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"Database","instanceClass":null,"abstract":false,"id":1,"interface":false,"eClass":"EClass"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"Table","instanceClass":null,"abstract":false,"id":2,"interface":false,"eClass":"EClass"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"Column","instanceClass":null,"abstract":false,"id":3,"interface":false,"eClass":"EClass"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"ForeignKey","instanceClass":null,"abstract":false,"id":4,"interface":false,"eClass":"EClass"},{"instanceTypeName":null,"instanceClassName":null,"name":"DataType","instanceClass":null,"id":5,"serializable":true,"eClass":"EEnum"},{"instanceTypeName":null,"defaultValue":null,"instanceClassName":null,"name":"Key","instanceClass":null,"abstract":false,"id":6,"interface":false,"eClass":"EClass"},{"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EAttribute","defaultValueLiteral":null,"unsettable":false,"transient":false,"unique":true,"name":"name","changeable":true,"lowerBound":0,"iD":false,"id":7,"derived":false},{"container":false,"ordered":true,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":true,"eClass":"EReference","defaultValueLiteral":null,"containment":true,"unsettable":false,"transient":false,"unique":true,"name":"tables","changeable":true,"resolveProxies":true,"lowerBound":1,"id":8,"derived":false},{"id":9,"eClass":"EGenericType"},{"id":10,"eClass":"EGenericType"},{"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EAttribute","defaultValueLiteral":null,"unsettable":false,"transient":false,"unique":true,"name":"name","changeable":true,"lowerBound":0,"iD":false,"id":11,"derived":false},{"container":false,"ordered":true,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":true,"unsettable":false,"transient":false,"unique":true,"name":"foreignkeys","changeable":true,"resolveProxies":true,"lowerBound":0,"id":12,"derived":false},{"container":false,"ordered":true,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":true,"unsettable":false,"transient":false,"unique":true,"name":"primary_key","changeable":true,"resolveProxies":true,"lowerBound":0,"id":13,"derived":false},{"container":false,"ordered":true,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":true,"eClass":"EReference","defaultValueLiteral":null,"containment":true,"unsettable":false,"transient":false,"unique":true,"name":"columns","changeable":true,"resolveProxies":true,"lowerBound":1,"id":14,"derived":false},{"container":false,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":true,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"database","changeable":true,"resolveProxies":true,"lowerBound":1,"id":15,"derived":false},{"id":16,"eClass":"EGenericType"},{"id":17,"eClass":"EGenericType"},{"id":18,"eClass":"EGenericType"},{"id":19,"eClass":"EGenericType"},{"id":20,"eClass":"EGenericType"},{"container":false,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"table","changeable":true,"resolveProxies":true,"lowerBound":0,"id":21,"derived":false},{"ordered":true,"upperBound":1,"volatile":false,"many":false,"required":false,"eClass":"EAttribute","defaultValueLiteral":"int","unsettable":false,"transient":false,"unique":true,"name":"type","changeable":true,"lowerBound":0,"iD":false,"id":22,"derived":false},{"ordered":true,"upperBound":1,"defaultValue":false,"volatile":false,"many":false,"required":false,"eClass":"EAttribute","defaultValueLiteral":"false","unsettable":false,"transient":false,"unique":true,"name":"notNull","changeable":true,"lowerBound":0,"iD":false,"id":23,"derived":false},{"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EAttribute","defaultValueLiteral":null,"unsettable":false,"transient":false,"unique":true,"name":"name","changeable":true,"lowerBound":0,"iD":false,"id":24,"derived":false},{"container":false,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"key","changeable":true,"resolveProxies":true,"lowerBound":0,"id":25,"derived":false},{"container":false,"ordered":true,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"foreign","changeable":true,"resolveProxies":true,"lowerBound":0,"id":26,"derived":false},{"id":27,"eClass":"EGenericType"},{"id":28,"eClass":"EGenericType"},{"id":29,"eClass":"EGenericType"},{"id":30,"eClass":"EGenericType"},{"id":31,"eClass":"EGenericType"},{"id":32,"eClass":"EGenericType"},{"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EAttribute","defaultValueLiteral":null,"unsettable":false,"transient":false,"unique":true,"name":"isMany","changeable":true,"lowerBound":0,"iD":false,"id":33,"derived":false},{"container":false,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"referencedKey","changeable":true,"resolveProxies":true,"lowerBound":0,"id":34,"derived":false},{"container":false,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"foreign_column","changeable":true,"resolveProxies":true,"lowerBound":0,"id":35,"derived":false},{"id":36,"eClass":"EGenericType"},{"id":37,"eClass":"EGenericType"},{"id":38,"eClass":"EGenericType"},{"name":"int","id":39,"value":0,"literal":"int","eClass":"EEnumLiteral"},{"name":"varchar","id":40,"value":0,"literal":"varchar","eClass":"EEnumLiteral"},{"name":"text","id":41,"value":0,"literal":"text","eClass":"EEnumLiteral"},{"name":"unknown","id":42,"value":0,"literal":"unknown","eClass":"EEnumLiteral"},{"name":"bool","id":43,"value":0,"literal":"bool","eClass":"EEnumLiteral"},{"name":"decimal","id":44,"value":0,"literal":"decimal","eClass":"EEnumLiteral"},{"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EAttribute","defaultValueLiteral":null,"unsettable":false,"transient":false,"unique":true,"name":"name","changeable":true,"lowerBound":0,"iD":false,"id":45,"derived":false},{"container":false,"ordered":true,"upperBound":-1,"defaultValue":null,"volatile":false,"many":true,"required":true,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"key_column","changeable":true,"resolveProxies":true,"lowerBound":1,"id":46,"derived":false},{"container":false,"ordered":true,"upperBound":1,"defaultValue":null,"volatile":false,"many":false,"required":false,"eClass":"EReference","defaultValueLiteral":null,"containment":false,"unsettable":false,"transient":false,"unique":true,"name":"referenced","changeable":true,"resolveProxies":true,"lowerBound":0,"id":47,"derived":false},{"id":48,"eClass":"EGenericType"},{"id":49,"eClass":"EGenericType"},{"id":50,"eClass":"EGenericType"}],"links":[{"source":0,"target":1},{"source":0,"target":2},{"source":0,"target":3},{"source":0,"target":4},{"source":0,"target":5},{"source":0,"target":6},{"source":1,"target":0},{"source":1,"target":7},{"source":1,"target":8},{"source":7,"target":9},{"source":7,"target":1},{"source":8,"target":2},{"source":8,"target":10},{"source":8,"target":1},{"source":10,"target":2},{"source":2,"target":0},{"source":2,"target":11},{"source":2,"target":12},{"source":2,"target":13},{"source":2,"target":14},{"source":2,"target":15},{"source":11,"target":16},{"source":11,"target":2},{"source":12,"target":4},{"source":12,"target":17},{"source":12,"target":2},{"source":17,"target":4},{"source":13,"target":6},{"source":13,"target":18},{"source":13,"target":2},{"source":18,"target":6},{"source":14,"target":3},{"source":14,"target":19},{"source":14,"target":2},{"source":19,"target":3},{"source":15,"target":1},{"source":15,"target":20},{"source":15,"target":2},{"source":20,"target":1},{"source":3,"target":0},{"source":3,"target":21},{"source":3,"target":22},{"source":3,"target":23},{"source":3,"target":24},{"source":3,"target":25},{"source":3,"target":26},{"source":21,"target":2},{"source":21,"target":27},{"source":21,"target":3},{"source":27,"target":2},{"source":22,"target":5},{"source":22,"target":28},{"source":22,"target":3},{"source":28,"target":5},{"source":23,"target":29},{"source":23,"target":3},{"source":24,"target":30},{"source":24,"target":3},{"source":25,"target":6},{"source":25,"target":31},{"source":25,"target":3},{"source":31,"target":6},{"source":26,"target":4},{"source":26,"target":32},{"source":26,"target":3},{"source":32,"target":4},{"source":4,"target":0},{"source":4,"target":33},{"source":4,"target":34},{"source":4,"target":35},{"source":33,"target":36},{"source":33,"target":4},{"source":34,"target":6},{"source":34,"target":37},{"source":34,"target":4},{"source":37,"target":6},{"source":35,"target":3},{"source":35,"target":38},{"source":35,"target":4},{"source":38,"target":3},{"source":5,"target":0},{"source":5,"target":39},{"source":5,"target":40},{"source":5,"target":41},{"source":5,"target":42},{"source":5,"target":43},{"source":5,"target":44},{"source":39,"target":5},{"source":40,"target":5},{"source":41,"target":5},{"source":42,"target":5},{"source":43,"target":5},{"source":44,"target":5},{"source":6,"target":0},{"source":6,"target":45},{"source":6,"target":46},{"source":6,"target":47},{"source":45,"target":48},{"source":45,"target":6},{"source":46,"target":3},{"source":46,"target":49},{"source":46,"target":6},{"source":49,"target":3},{"source":47,"target":4},{"source":47,"target":50},{"source":47,"target":6},{"source":50,"target":4}],"multigraph":true}