Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
reg-app
Regapp
Commits
7a078d1b
Commit
7a078d1b
authored
Jan 28, 2015
by
michael.simon
Browse files
Config option with federation which entities to poll
parent
dc53c5c9
Changes
1
Hide whitespace changes
Inline
Side-by-side
bwreg-jpa/src/main/java/edu/kit/scc/webreg/entity/FederationEntity.java
View file @
7a078d1b
...
...
@@ -17,6 +17,7 @@ import javax.persistence.Column;
import
javax.persistence.Entity
;
import
javax.persistence.ManyToMany
;
import
javax.persistence.ManyToOne
;
import
javax.persistence.PostLoad
;
import
javax.persistence.Table
;
@Entity
(
name
=
"FederationEntity"
)
...
...
@@ -43,9 +44,35 @@ public class FederationEntity extends AbstractBaseEntity {
@Column
(
name
=
"polled_at"
)
private
Date
polledAt
;
@Column
(
name
=
"fetch_idps"
)
private
Boolean
fetchIdps
;
@Column
(
name
=
"fetch_sps"
)
private
Boolean
fetchSps
;
@Column
(
name
=
"fetch_aas"
)
private
Boolean
fetchAAs
;
@ManyToMany
(
targetEntity
=
SamlIdpMetadataEntity
.
class
,
mappedBy
=
"federations"
)
private
Set
<
SamlIdpMetadataEntity
>
idps
;
@ManyToMany
(
targetEntity
=
SamlSpMetadataEntity
.
class
,
mappedBy
=
"federations"
)
private
Set
<
SamlSpMetadataEntity
>
sps
;
@ManyToMany
(
targetEntity
=
SamlAAMetadataEntity
.
class
,
mappedBy
=
"federations"
)
private
Set
<
SamlAAMetadataEntity
>
aas
;
@PostLoad
public
void
postLoad
()
{
// Populate standard values if null, which is the case for updated webreg
if
(
fetchIdps
==
null
)
fetchIdps
=
Boolean
.
TRUE
;
if
(
fetchSps
==
null
)
fetchSps
=
Boolean
.
FALSE
;
if
(
fetchAAs
==
null
)
fetchAAs
=
Boolean
.
FALSE
;
}
public
String
getEntityId
()
{
return
entityId
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment