View Javadoc

1   /**
2    * Copyright 2005-2014 The Kuali Foundation
3    *
4    * Licensed under the Educational Community License, Version 2.0 (the "License");
5    * you may not use this file except in compliance with the License.
6    * You may obtain a copy of the License at
7    *
8    * http://www.opensource.org/licenses/ecl2.php
9    *
10   * Unless required by applicable law or agreed to in writing, software
11   * distributed under the License is distributed on an "AS IS" BASIS,
12   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13   * See the License for the specific language governing permissions and
14   * limitations under the License.
15   */
16  package org.kuali.rice.ksb.impl.bus.diff;
17  
18  import java.util.Collections;
19  import java.util.List;
20  import java.util.Map;
21  
22  import org.kuali.rice.ksb.api.registry.ServiceInfo;
23  import org.kuali.rice.ksb.impl.bus.LocalService;
24  
25  /**
26   * TODO... 
27   * 
28   * @author Kuali Rice Team (rice.collab@kuali.org)
29   *
30   */
31  public class LocalServicesDiff {
32  
33  	private final List<ServiceInfo> servicesToRemoveFromRegistry;
34  	private final List<LocalService> localServicesToPublish;
35  	private final Map<LocalService, ServiceInfo> localServicesToUpdate;
36  		
37  	public LocalServicesDiff(List<ServiceInfo> servicesToRemoveFromRegistry,
38  			List<LocalService> localServicesToPublish,
39  			Map<LocalService, ServiceInfo> localServicesToUpdate) {
40  		this.servicesToRemoveFromRegistry = servicesToRemoveFromRegistry == null ? Collections.<ServiceInfo>emptyList() : servicesToRemoveFromRegistry;
41  		this.localServicesToPublish = localServicesToPublish == null ? Collections.<LocalService>emptyList() : localServicesToPublish;
42  		this.localServicesToUpdate = localServicesToUpdate == null ? Collections.<LocalService, ServiceInfo>emptyMap() : localServicesToUpdate;
43  	}
44  
45  	public List<ServiceInfo> getServicesToRemoveFromRegistry() {
46  		return this.servicesToRemoveFromRegistry;
47  	}
48  
49  	public List<LocalService> getLocalServicesToPublish() {
50  		return this.localServicesToPublish;
51  	}
52  	
53  	public Map<LocalService, ServiceInfo> getLocalServicesToUpdate() {
54  		return this.localServicesToUpdate;
55  	}
56  
57  }