Commit e47c0f12 authored by Matija Obreza's avatar Matija Obreza

Added setters to OAuthClient for Jackson deserialization

parent 566f5e64
......@@ -79,7 +79,7 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
/** The resource ids. */
@JsonView(JsonViews.Protected.class)
@Transient
private final Set<String> resourceIds = new HashSet<>();
private Set<String> resourceIds = new HashSet<>();
/** The auto approve. */
@Column(nullable = false)
......@@ -93,7 +93,7 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
/** The auto approve scopes. */
@JsonView(JsonViews.Protected.class)
@Transient
private final Set<String> autoApproveScopes = new HashSet<>();
private Set<String> autoApproveScopes = new HashSet<>();
/** The scope. */
@JsonIgnore
......@@ -103,7 +103,7 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
/** The scopes. */
@JsonView(JsonViews.Protected.class)
@Transient
private final Set<String> scopes = new HashSet<>();
private Set<String> scopes = new HashSet<>();
/** The grants. */
@JsonIgnore
......@@ -113,7 +113,7 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
/** The grant types. */
@JsonView(JsonViews.Protected.class)
@Transient
private final Set<String> grantTypes = new HashSet<>();
private Set<String> grantTypes = new HashSet<>();
/** The redirect. */
@JsonIgnore
......@@ -123,7 +123,7 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
/** The redirect uris. */
@JsonView(JsonViews.Protected.class)
@Transient
private final Set<String> redirectUris = new HashSet<>();
private Set<String> redirectUris = new HashSet<>();
/** The roles. */
@JsonView(JsonViews.Protected.class)
......@@ -135,7 +135,7 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
/** The additional information. */
@Transient
private final Map<String, Object> additionalInformation = null;
private Map<String, Object> additionalInformation = null;
/** The access token validity. */
private Integer accessTokenValidity;
......@@ -361,6 +361,10 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
return autoApproveScopes;
}
public void setAutoApproveScopes(Set<String> autoApproveScopes) {
this.autoApproveScopes = autoApproveScopes;
}
/*
* (non-Javadoc)
* @see
......@@ -371,6 +375,10 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
return resourceIds;
}
public void setResourceIds(Set<String> resourceIds) {
this.resourceIds = resourceIds;
}
/**
* Client secret is required when provided.
*
......@@ -399,6 +407,10 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
return scopes;
}
public void setScopes(Set<String> scopes) {
this.scopes = scopes;
}
/*
* (non-Javadoc)
* @see org.springframework.security.oauth2.provider.ClientDetails#
......@@ -409,6 +421,10 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
return grantTypes;
}
public void setGrantTypes(Set<String> grantTypes) {
this.grantTypes = grantTypes;
}
/*
* (non-Javadoc)
* @see org.springframework.security.oauth2.provider.ClientDetails#
......@@ -419,6 +435,11 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
return redirectUris;
}
public void setRedirectUris(Set<String> redirectUris) {
this.redirectUris = redirectUris;
}
/*
* (non-Javadoc)
* @see
......@@ -506,6 +527,10 @@ public class OAuthClient extends AclSid implements ClientDetails, Copyable<OAuth
return additionalInformation;
}
public void setAdditionalInformation(Map<String, Object> additionalInformation) {
this.additionalInformation = additionalInformation;
}
/**
* Sets the title.
*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment