/**
 * Copyright 2009-2012 OpenAIRE PROJECT (Bielefeld University)
 * Original author: Marek Imialek <marek.imialek at uni-bielefeld.de>
 *
 * 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 eu.dnetlib.data.udm;

import javax.jws.WebMethod;
import javax.jws.WebParam;
import javax.jws.WebService;

/**
 * The Interface IUsageDataMergingService.
 * 
 * @author <a href="mailto:marek.imialek at uni-bielefeld.de">Marek Imialek</a>
 */
@WebService
public interface IUsageDataMergingService {

	/**
	 * Identifies service version.
	 * 
	 * @return the string
	 */
	@WebMethod(operationName="identify", action="identify")
	public String identify();
	
	/**
	 * Gets data from all "harvesting" mdstores and stores them in one package.
	 * The package is named with the current date
	 *
	 * @throws UsageDataMergingServiceException the usage data merging service exception
	 */
	@WebMethod(operationName = "createCompleteDataCollection", action = "createCompleteDataCollection")
	public void createCompleteDataCollection() throws UsageDataMergingServiceException;
	
	/**
	 * Gets all data from the harvesting mdstores that was stored between the day
	 * specified by the storingDate parameter and one day before the storingDate.
	 * If the storingDate parameter is not defined then the current date is used.
	 * The following date format of storingDate parameter is accepted by the function:
	 * YYYY-MM-DD
	 * 
	 * @param storingDate  
	 * @throws UsageDataMergingServiceException the usage data merging service exception
	 */
	@WebMethod(operationName = "createYesterdaysDataCollection", action = "createYesterdaysDataCollection")
	public void createYesterdaysDataCollection (
			@WebParam(name = "storingDate")  String storingDate	
		)throws UsageDataMergingServiceException;
	
}
