001/** 002 * Copyright 2010-2013 The Kuali Foundation 003 * 004 * Licensed under the Educational Community License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.opensource.org/licenses/ecl2.php 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package org.kuali.common.util.spring; 017 018import org.springframework.beans.factory.FactoryBean; 019 020/** 021 * Use <code>ScmConfig</code> instead. 022 * 023 * @deprecated 024 */ 025@Deprecated 026public class ScmServiceFactoryBean implements FactoryBean<org.kuali.common.util.service.ScmService> { 027 028 String url; 029 boolean singleton = true; 030 031 @Override 032 public org.kuali.common.util.service.ScmService getObject() { 033 return org.kuali.common.util.ScmUtils.getScmService(url); 034 } 035 036 @Override 037 public Class<org.kuali.common.util.service.ScmService> getObjectType() { 038 return org.kuali.common.util.service.ScmService.class; 039 } 040 041 @Override 042 public boolean isSingleton() { 043 return singleton; 044 } 045 046 public String getUrl() { 047 return url; 048 } 049 050 public void setUrl(String url) { 051 this.url = url; 052 } 053 054 public void setSingleton(boolean singleton) { 055 this.singleton = singleton; 056 } 057 058}