From abf1e3d2eaf6f4190c30f0ad4c61e3c14b6c17b7 Mon Sep 17 00:00:00 2001 From: prabathabey Date: Thu, 21 May 2015 19:16:40 +0530 Subject: [PATCH] Fixing build failures --- .../WebappAuthenticatorRepository.java | 40 +++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 components/webapp-authenticator-framework/org.wso2.carbon.webapp.authenticator.framework/src/main/java/org/wso2/carbon/webapp/authenticator/framework/WebappAuthenticatorRepository.java diff --git a/components/webapp-authenticator-framework/org.wso2.carbon.webapp.authenticator.framework/src/main/java/org/wso2/carbon/webapp/authenticator/framework/WebappAuthenticatorRepository.java b/components/webapp-authenticator-framework/org.wso2.carbon.webapp.authenticator.framework/src/main/java/org/wso2/carbon/webapp/authenticator/framework/WebappAuthenticatorRepository.java new file mode 100644 index 0000000000..02a86ce9cc --- /dev/null +++ b/components/webapp-authenticator-framework/org.wso2.carbon.webapp.authenticator.framework/src/main/java/org/wso2/carbon/webapp/authenticator/framework/WebappAuthenticatorRepository.java @@ -0,0 +1,40 @@ +/* + * Copyright (c) 2015, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. + * + * WSO2 Inc. licenses this file to you 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.wso2.carbon.webapp.authenticator.framework; + +import java.util.HashMap; +import java.util.Map; + +public class WebappAuthenticatorRepository { + + private Map authenticators; + + public WebappAuthenticatorRepository() { + this.authenticators = new HashMap(); + } + + public void addAuthenticator(WebappAuthenticator authenticator) { + authenticators.put(authenticator.getName(), authenticator); + } + + public WebappAuthenticator getAuthenticator(String name) { + return authenticators.get(name); + } + +}