Project

General

Profile

1
package eu.dnetlib.enabling.is.rmi;
2

    
3
import java.util.List;
4

    
5
import javax.jws.WebParam;
6
import javax.jws.WebService;
7

    
8
import eu.dnetlib.common.rmi.BaseService;
9
import eu.dnetlib.enabling.is.rmi.objects.BlackboardMessage;
10
import eu.dnetlib.enabling.is.rmi.objects.DnetDataStructure;
11
import eu.dnetlib.enabling.is.rmi.objects.DnetResourceType;
12
import eu.dnetlib.enabling.is.rmi.objects.DnetService;
13
import eu.dnetlib.enabling.is.rmi.objects.Subcription;
14

    
15
@WebService(targetNamespace = "http://services.dnetlib.eu/")
16
public interface InformationService extends BaseService {
17

    
18
	// Resource Type
19
	boolean addResourceType(@WebParam(name = "type") DnetResourceType type) throws InformationServiceException;
20

    
21
	List<DnetResourceType> listResourceTypes() throws InformationServiceException;
22

    
23
	// Generic search/update methods
24
	String findOneSql(@WebParam(name = "sql") String sql) throws InformationServiceException;
25

    
26
	List<String> searchSql(@WebParam(name = "sql") String sql) throws InformationServiceException;
27

    
28
	int updateSql(@WebParam(name = "sql") String sql) throws InformationServiceException;
29

    
30
	// Services
31
	List<DnetService> listServices() throws InformationServiceException;
32

    
33
	String registerService(@WebParam(name = "service") DnetService service) throws InformationServiceException;
34

    
35
	DnetService getService(@WebParam(name = "id") String id) throws InformationServiceException;
36

    
37
	DnetService getServiceByAddress(@WebParam(name = "address") String address) throws InformationServiceException;
38

    
39
	boolean deleteService(@WebParam(name = "id") String id) throws InformationServiceException;
40

    
41
	boolean isRegisteredService(@WebParam(name = "address") String address);
42

    
43
	boolean addBlackBoardMessage(@WebParam(name = "serviceId") String serviceId, @WebParam(name = "message") BlackboardMessage message)
44
			throws InformationServiceException;
45

    
46
	boolean updateBlackBoardMessage(@WebParam(name = "message") BlackboardMessage message) throws InformationServiceException;
47

    
48
	List<BlackboardMessage> listBlackboardMessages();
49

    
50
	boolean deleteBlackBoardMessage(@WebParam(name = "message") BlackboardMessage message) throws InformationServiceException;
51

    
52
	String addSubscription(@WebParam(name = "subscription") Subcription subcription) throws InformationServiceException;
53

    
54
	boolean deleteSubscription(@WebParam(name = "subscriptionId") String subscriptionId) throws InformationServiceException;
55

    
56
	List<Subcription> listSubcriptions() throws InformationServiceException;
57

    
58
	// DS
59
	DnetDataStructure getDsById(@WebParam(name = "id") String id) throws InformationServiceException;
60

    
61
	DnetDataStructure getDsByCode(@WebParam(name = "code") String code, @WebParam(name = "type") String type) throws InformationServiceException;
62

    
63
	String registerDs(@WebParam(name = "resource") DnetDataStructure ds) throws InformationServiceException;
64

    
65
	boolean deleteDsById(@WebParam(name = "id") String id) throws InformationServiceException;
66

    
67
	boolean deleteDsByCode(@WebParam(name = "code") String code, @WebParam(name = "type") String type) throws InformationServiceException;
68

    
69
	boolean isRegisteredDs(@WebParam(name = "code") String code, @WebParam(name = "type") String type);
70

    
71
	List<DnetDataStructure> listDatastructures(@WebParam(name = "type") String type);
72

    
73
	// Generic resources
74
	boolean validateResource(@WebParam(name = "id") String id, @WebParam(name = "valid") boolean valid) throws InformationServiceException;
75

    
76
}
(1-1/2)