From 25937774e1a29a7944cc9bd9d88000e0947af708 Mon Sep 17 00:00:00 2001 From: Pedro Igor Date: Fri, 6 Jun 2014 08:49:23 -0300 Subject: [PATCH] [PLINK-479] - Remove cache api as it is not in use. --- .../main/java/org/picketlink/cache/Cache.java | 35 -------------- .../org/picketlink/cache/CacheManager.java | 33 ------------- .../java/org/picketlink/cache/Cacheable.java | 47 ------------------ .../org/picketlink/cache/package-info.java | 24 ---------- .../internal/cache/DefaultCache.java | 35 -------------- .../internal/cache/DefaultCacheManager.java | 48 ------------------- .../internal/cache/package-info.java | 24 ---------- 7 files changed, 246 deletions(-) delete mode 100644 modules/base/api/src/main/java/org/picketlink/cache/Cache.java delete mode 100644 modules/base/api/src/main/java/org/picketlink/cache/CacheManager.java delete mode 100644 modules/base/api/src/main/java/org/picketlink/cache/Cacheable.java delete mode 100644 modules/base/api/src/main/java/org/picketlink/cache/package-info.java delete mode 100644 modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCache.java delete mode 100644 modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCacheManager.java delete mode 100644 modules/base/impl/src/main/java/org/picketlink/internal/cache/package-info.java diff --git a/modules/base/api/src/main/java/org/picketlink/cache/Cache.java b/modules/base/api/src/main/java/org/picketlink/cache/Cache.java deleted file mode 100644 index 1ce75f2c6..000000000 --- a/modules/base/api/src/main/java/org/picketlink/cache/Cache.java +++ /dev/null @@ -1,35 +0,0 @@ -/* - * JBoss, Home of Professional Open Source. - * Copyright 2012, Red Hat, Inc., and individual contributors - * as indicated by the @author tags. See the copyright.txt file in the - * distribution for a full listing of individual contributors. - * - * This is free software; you can redistribute it and/or modify it - * under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation; either version 2.1 of - * the License, or (at your option) any later version. - * - * This software is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this software; if not, write to the Free - * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA - * 02110-1301 USA, or see the FSF site: http://www.fsf.org. - */ -package org.picketlink.cache; - -import java.util.Map; - -/** - * Cache Interface - * @author anil saldhana - * @since May 10, 2013 - * - * @param - * @param - */ -public interface Cache extends Map { -} \ No newline at end of file diff --git a/modules/base/api/src/main/java/org/picketlink/cache/CacheManager.java b/modules/base/api/src/main/java/org/picketlink/cache/CacheManager.java deleted file mode 100644 index b804b9146..000000000 --- a/modules/base/api/src/main/java/org/picketlink/cache/CacheManager.java +++ /dev/null @@ -1,33 +0,0 @@ -/* - * JBoss, Home of Professional Open Source - * - * Copyright 2013 Red Hat, Inc. and/or its affiliates. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.picketlink.cache; - -/** - * Manager to manage cache instances - * @author anil saldhana - * @param - * @since May 10, 2013 - */ -public interface CacheManager { - /** - * Given a name for the cache, return an instance of {@link Cache} - * @param cacheName - * @return - */ - Cache getCache(String cacheName); -} \ No newline at end of file diff --git a/modules/base/api/src/main/java/org/picketlink/cache/Cacheable.java b/modules/base/api/src/main/java/org/picketlink/cache/Cacheable.java deleted file mode 100644 index 2dba4bbbc..000000000 --- a/modules/base/api/src/main/java/org/picketlink/cache/Cacheable.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * JBoss, Home of Professional Open Source. - * Copyright 2012, Red Hat, Inc., and individual contributors - * as indicated by the @author tags. See the copyright.txt file in the - * distribution for a full listing of individual contributors. - * - * This is free software; you can redistribute it and/or modify it - * under the terms of the GNU Lesser General Public License as - * published by the Free Software Foundation; either version 2.1 of - * the License, or (at your option) any later version. - * - * This software is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this software; if not, write to the Free - * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA - * 02110-1301 USA, or see the FSF site: http://www.fsf.org. - */ -package org.picketlink.cache; - -/** - * Interface indicating an - * entity has access to a cache - * - * @author anil saldhana - * @since May 10, 2013 - */ -public interface Cacheable { - - /** - * Get the {@link Cache} - * - * @return - */ - Cache getCache(); - - /** - * Set the {@link CacheManager} - * - * @param - * @param cacheManager - */ - void setCacheManager(Cache cache); -} \ No newline at end of file diff --git a/modules/base/api/src/main/java/org/picketlink/cache/package-info.java b/modules/base/api/src/main/java/org/picketlink/cache/package-info.java deleted file mode 100644 index bd6f3e9ee..000000000 --- a/modules/base/api/src/main/java/org/picketlink/cache/package-info.java +++ /dev/null @@ -1,24 +0,0 @@ -/* - * JBoss, Home of Professional Open Source - * - * Copyright 2013 Red Hat, Inc. and/or its affiliates. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * Package containing the caching wrapper - * @author anil saldhana - * @since May 10, 2013 - */ -package org.picketlink.cache; \ No newline at end of file diff --git a/modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCache.java b/modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCache.java deleted file mode 100644 index bde3bc3ae..000000000 --- a/modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCache.java +++ /dev/null @@ -1,35 +0,0 @@ -/* - * JBoss, Home of Professional Open Source - * - * Copyright 2013 Red Hat, Inc. and/or its affiliates. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.picketlink.internal.cache; - -import java.util.concurrent.ConcurrentHashMap; - -import org.picketlink.cache.Cache; - -/** - * Default instance of {@link Cache} which is essentially - * {@link ConcurrentHashMap} - * @author anil saldhana - * @since May 10, 2013 - * - * @param - * @param - */ -public class DefaultCache extends ConcurrentHashMap implements Cache { - private static final long serialVersionUID = -8062636630346762771L; -} \ No newline at end of file diff --git a/modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCacheManager.java b/modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCacheManager.java deleted file mode 100644 index b24a313d6..000000000 --- a/modules/base/impl/src/main/java/org/picketlink/internal/cache/DefaultCacheManager.java +++ /dev/null @@ -1,48 +0,0 @@ -/* - * JBoss, Home of Professional Open Source - * - * Copyright 2013 Red Hat, Inc. and/or its affiliates. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.picketlink.internal.cache; - -import java.util.HashMap; -import java.util.Map; - -import org.picketlink.cache.Cache; -import org.picketlink.cache.CacheManager; - -/** - * Default implementation of {@link CacheManager} - * @author anil saldhana - * @param - * @param - * @since May 10, 2013 - */ -@SuppressWarnings("unchecked") -public class DefaultCacheManager implements CacheManager { - protected Map> map = new HashMap>(); - @Override - public Cache getCache(String cacheName) { - return (Cache) map.get(cacheName); - } - /** - * Set the cache - * @param cacheName - * @param cache - */ - public void setCache(String cacheName, Cache cache){ - this.map.put(cacheName, cache); - } -} \ No newline at end of file diff --git a/modules/base/impl/src/main/java/org/picketlink/internal/cache/package-info.java b/modules/base/impl/src/main/java/org/picketlink/internal/cache/package-info.java deleted file mode 100644 index 0028044c4..000000000 --- a/modules/base/impl/src/main/java/org/picketlink/internal/cache/package-info.java +++ /dev/null @@ -1,24 +0,0 @@ -/* - * JBoss, Home of Professional Open Source - * - * Copyright 2013 Red Hat, Inc. and/or its affiliates. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * Package contains default cache implementation - * @author anil saldhana - * @since May 10, 2013 - */ -package org.picketlink.internal.cache; \ No newline at end of file