001/******************************************************************************* 002 * Copyright 2014 The MITRE Corporation 003 * and the MIT Kerberos and Internet Trust Consortium 004 * 005 * Licensed under the Apache License, Version 2.0 (the "License"); 006 * you may not use this file except in compliance with the License. 007 * You may obtain a copy of the License at 008 * 009 * http://www.apache.org/licenses/LICENSE-2.0 010 * 011 * Unless required by applicable law or agreed to in writing, software 012 * distributed under the License is distributed on an "AS IS" BASIS, 013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 014 * See the License for the specific language governing permissions and 015 * limitations under the License. 016 ******************************************************************************/ 017/** 018 * 019 */ 020package org.mitre.openid.connect.model; 021 022import javax.persistence.Basic; 023import javax.persistence.Column; 024import javax.persistence.Entity; 025import javax.persistence.GeneratedValue; 026import javax.persistence.GenerationType; 027import javax.persistence.Id; 028import javax.persistence.NamedQueries; 029import javax.persistence.NamedQuery; 030import javax.persistence.Table; 031 032/** 033 * @author jricher 034 * 035 */ 036@Entity 037@Table(name="blacklisted_site") 038@NamedQueries({ 039 @NamedQuery(name = "BlacklistedSite.getAll", query = "select b from BlacklistedSite b") 040}) 041public class BlacklistedSite { 042 043 // unique id 044 private Long id; 045 046 // URI pattern to black list 047 private String uri; 048 049 public BlacklistedSite() { 050 051 } 052 053 /** 054 * @return the id 055 */ 056 @Id 057 @GeneratedValue(strategy = GenerationType.IDENTITY) 058 @Column(name = "id") 059 public Long getId() { 060 return id; 061 } 062 063 /** 064 * @param id the id to set 065 */ 066 public void setId(Long id) { 067 this.id = id; 068 } 069 070 @Basic 071 @Column(name="uri") 072 public String getUri() { 073 return uri; 074 } 075 076 public void setUri(String uri) { 077 this.uri = uri; 078 } 079 080 081}