Added table definition files for the model classes. Note that these are untested and may need modification. TODO: the Maven replacer plugin needs to be configured in order to replace the DB_URL, etc variables in data-context.xml with local values.
parent
b47d22e0fd
commit
01ec777af6
|
@ -4,7 +4,6 @@ import java.util.Date;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
import javax.persistence.Basic;
|
import javax.persistence.Basic;
|
||||||
import javax.persistence.CollectionTable;
|
|
||||||
import javax.persistence.ElementCollection;
|
import javax.persistence.ElementCollection;
|
||||||
import javax.persistence.Entity;
|
import javax.persistence.Entity;
|
||||||
import javax.persistence.FetchType;
|
import javax.persistence.FetchType;
|
||||||
|
|
|
@ -3,6 +3,7 @@ package org.mitre.openid.connect.model;
|
||||||
import javax.persistence.Basic;
|
import javax.persistence.Basic;
|
||||||
import javax.persistence.Entity;
|
import javax.persistence.Entity;
|
||||||
import javax.persistence.Id;
|
import javax.persistence.Id;
|
||||||
|
import javax.persistence.JoinColumn;
|
||||||
import javax.persistence.NamedQueries;
|
import javax.persistence.NamedQueries;
|
||||||
import javax.persistence.NamedQuery;
|
import javax.persistence.NamedQuery;
|
||||||
import javax.persistence.OneToOne;
|
import javax.persistence.OneToOne;
|
||||||
|
@ -233,6 +234,7 @@ public class UserInfo {
|
||||||
* @return the address
|
* @return the address
|
||||||
*/
|
*/
|
||||||
@OneToOne
|
@OneToOne
|
||||||
|
@JoinColumn(name="address_id")
|
||||||
public Address getAddress() {
|
public Address getAddress() {
|
||||||
return address;
|
return address;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,9 @@
|
||||||
|
CREATE TABLE address (
|
||||||
|
id BIGINT AUTO_INCREMENT PRIMARY KEY,
|
||||||
|
formatted VARCHAR(256),
|
||||||
|
streetAddress VARCHAR(256),
|
||||||
|
locality VARCHAR(256),
|
||||||
|
region VARCHAR(256),
|
||||||
|
postalCode VARCHAR(256),
|
||||||
|
country VARCHAR(256)
|
||||||
|
);
|
|
@ -0,0 +1,8 @@
|
||||||
|
CREATE TABLE approvedsite (
|
||||||
|
id BIGINT AUTO_INCREMENT PRIMARY KEY,
|
||||||
|
userinfo_id VARCHAR(256),
|
||||||
|
clientdetails_id VARCHAR(256),
|
||||||
|
creationDate DATE,
|
||||||
|
accessDate DATE,
|
||||||
|
timeoutDate DATE
|
||||||
|
);
|
|
@ -0,0 +1,5 @@
|
||||||
|
CREATE TABLE event (
|
||||||
|
id BIGINT AUTO_INCREMENT PRIMARY KEY,
|
||||||
|
type INT(3),
|
||||||
|
timestamp DATE
|
||||||
|
);
|
|
@ -0,0 +1,3 @@
|
||||||
|
CREATE TABLE idtoken (
|
||||||
|
id BIGINT AUTO_INCREMENT PRIMARY KEY
|
||||||
|
);
|
|
@ -0,0 +1,3 @@
|
||||||
|
CREATE TABLE idtokenclaims (
|
||||||
|
id BIGINT AUTO_INCREMENT PRIMARY KEY
|
||||||
|
);
|
|
@ -0,0 +1,20 @@
|
||||||
|
CREATE TABLE userinfo (
|
||||||
|
id BIGINT AUTO_INCREMENT PRIMARY KEY,
|
||||||
|
userId VARCHAR(256),
|
||||||
|
name VARCHAR(256),
|
||||||
|
givenName VARCHAR(256),
|
||||||
|
familyName VARCHAR(256),
|
||||||
|
middleName VARCHAR(256),
|
||||||
|
nickname VARCHAR(256),
|
||||||
|
profile VARCHAR(256),
|
||||||
|
picture VARCHAR(256),
|
||||||
|
website VARCHAR(256),
|
||||||
|
email VARCHAR(256),
|
||||||
|
verified BOOLEAN,
|
||||||
|
gender VARCHAR(256),
|
||||||
|
zoneinfo VARCHAR(256),
|
||||||
|
locale VARCHAR(256),
|
||||||
|
phoneNumber VARCHAR(256),
|
||||||
|
address_id VARCHAR(256),
|
||||||
|
updatedTime VARCHAR(256)
|
||||||
|
);
|
|
@ -0,0 +1,5 @@
|
||||||
|
CREATE TABLE whitelistedsite (
|
||||||
|
id BIGINT AUTO_INCREMENT PRIMARY KEY,
|
||||||
|
userinfo_id VARCHAR(256),
|
||||||
|
clientdetails_id VARCHAR(256)
|
||||||
|
);
|
Loading…
Reference in New Issue