001: /**********************************************************************************
002: * $URL: https://source.sakaiproject.org/svn/sam/trunk/component/src/java/org/sakaiproject/tool/assessment/integration/context/spring/IntegrationContext.java $
003: * $Id: IntegrationContext.java 9347 2006-05-13 04:13:19Z daisyf@stanford.edu $
004: ***********************************************************************************
005: *
006: * Copyright (c) 2004, 2005, 2006 The Sakai Foundation.
007: *
008: * Licensed under the Educational Community License, Version 1.0 (the"License");
009: * you may not use this file except in compliance with the License.
010: * You may obtain a copy of the License at
011: *
012: * http://www.opensource.org/licenses/ecl1.php
013: *
014: * Unless required by applicable law or agreed to in writing, software
015: * distributed under the License is distributed on an "AS IS" BASIS,
016: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
017: * See the License for the specific language governing permissions and
018: * limitations under the License.
019: *
020: **********************************************************************************/package org.sakaiproject.tool.assessment.integration.context.spring;
021:
022: import org.apache.commons.logging.Log;
023: import org.apache.commons.logging.LogFactory;
024:
025: import org.sakaiproject.tool.assessment.integration.context.IntegrationContextFactory;
026: import org.sakaiproject.tool.assessment.integration.helper.ifc.AgentHelper;
027: import org.sakaiproject.tool.assessment.integration.helper.ifc.GradebookHelper;
028: import org.sakaiproject.tool.assessment.integration.helper.ifc.GradebookServiceHelper;
029: import org.sakaiproject.tool.assessment.integration.helper.ifc.PublishingTargetHelper;
030: import org.sakaiproject.tool.assessment.integration.helper.ifc.SectionAwareServiceHelper;
031: import org.sakaiproject.tool.assessment.integration.helper.ifc.ServerConfigurationServiceHelper;
032:
033: /**
034: * IntegrationContext is an internal implementation of IntegrationContextFactory.
035: * It is the implementation class actually used by Spring and returned by its
036: * abstract superclasses' (IntegrationContextFactory) getInstance method.
037: * @author Ed Smiley
038: */
039: public class IntegrationContext extends IntegrationContextFactory {
040: private static Log log = LogFactory
041: .getLog(IntegrationContext.class);
042:
043: private boolean integrated;
044: private AgentHelper agentHelper;
045: private GradebookHelper gradebookHelper;
046: private GradebookServiceHelper gradebookServiceHelper;
047: private PublishingTargetHelper publishingTargetHelper;
048: private SectionAwareServiceHelper sectionAwareServiceHelper;
049: private ServerConfigurationServiceHelper serverConfigurationServiceHelper;
050:
051: // plain old Java bean properties, nothing mysterious here
052: // just that we add mutators for Spring to hook, these are not
053: // part of the factory api, so IntegrationContextFactory doesn't have
054: // the setXXX() methods.
055: public boolean isIntegrated() {
056: return integrated;
057: }
058:
059: public void setIntegrated(boolean integrated) {
060: this .integrated = integrated;
061: }
062:
063: public AgentHelper getAgentHelper() {
064: return agentHelper;
065: }
066:
067: public void setAgentHelper(AgentHelper agentHelper) {
068: this .agentHelper = agentHelper;
069: }
070:
071: public GradebookHelper getGradebookHelper() {
072: return gradebookHelper;
073: }
074:
075: public void setGradebookHelper(GradebookHelper gradebookHelper) {
076: this .gradebookHelper = gradebookHelper;
077: }
078:
079: public GradebookServiceHelper getGradebookServiceHelper() {
080: return gradebookServiceHelper;
081: }
082:
083: public void setGradebookServiceHelper(
084: GradebookServiceHelper gradebookServiceHelper) {
085: this .gradebookServiceHelper = gradebookServiceHelper;
086: }
087:
088: public PublishingTargetHelper getPublishingTargetHelper() {
089: return publishingTargetHelper;
090: }
091:
092: public void setPublishingTargetHelper(
093: PublishingTargetHelper publishingTargetHelper) {
094: this .publishingTargetHelper = publishingTargetHelper;
095: }
096:
097: public SectionAwareServiceHelper getSectionAwareServiceHelper() {
098: return sectionAwareServiceHelper;
099: }
100:
101: public void setSectionAwareServiceHelper(
102: SectionAwareServiceHelper sectionAwareServiceHelper) {
103: this .sectionAwareServiceHelper = sectionAwareServiceHelper;
104: }
105:
106: public ServerConfigurationServiceHelper getServerConfigurationServiceHelper() {
107: return serverConfigurationServiceHelper;
108: }
109:
110: public void setServerConfigurationServiceHelper(
111: ServerConfigurationServiceHelper serverConfigurationServiceHelper) {
112: this.serverConfigurationServiceHelper = serverConfigurationServiceHelper;
113: }
114: }
|