Skip to content

Commit

Permalink
Add missing application property in API Key entity
Browse files Browse the repository at this point in the history
  • Loading branch information
brasseld committed Nov 26, 2015
1 parent dacd34d commit 77de7f4
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions src/main/java/io/gravitee/repository/management/model/ApiKey.java
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
package io.gravitee.repository.management.model;

import java.util.Date;
import java.util.Objects;

/**
* @author David BRASSELY (brasseld at gmail.com)
Expand Down Expand Up @@ -52,6 +53,11 @@ public class ApiKey {
*/
private String api;

/**
* The application for which the key is defined.
*/
private String application;

public boolean isRevoked() {
return revoked;
}
Expand Down Expand Up @@ -99,4 +105,25 @@ public String getApi() {
public void setApi(String api) {
this.api = api;
}

public String getApplication() {
return application;
}

public void setApplication(String application) {
this.application = application;
}

@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
ApiKey apiKey = (ApiKey) o;
return Objects.equals(key, apiKey.key);
}

@Override
public int hashCode() {
return Objects.hash(key);
}
}

0 comments on commit 77de7f4

Please sign in to comment.