/*********************************************************************/ /* */ /* AgentService Framework */ /* www.agentservice.it */ /* */ /* Copyright (C) 2007 l.i.d.o. - DIST, University of Genoa, Italy */ /* GNU Lesser General Public License */ /* */ /* This library is free software; you can redistribute it and/or */ /* modify it under the terms of the GNU Lesser General Public */ /* License as published by the Free Software Foundation, */ /* version 2.1 of the License. */ /* */ /* This library is distributed in the hope that it will be useful, */ /* but WITHOUT ANY WARRANTY; without even the implied warranty of */ /* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU */ /* Lesser General Public License for more details. */ /* */ /* You should have received a copy of the GNU Lesser General Public */ /* License along with this library; if not, write to the */ /* Free Software Foundation, Inc., 59 Temple Place - Suite 330, */ /* Boston, MA 02111-1307, USA. */ /* */ /*********************************************************************/ using System; using System.ServiceModel; using AgentService.Platform.DF; using AgentService.Platform.AMS; using AgentService.Platform.Modules; namespace AgentService.Agent.Runtime { /// /// Interface IYellowPagesServer. Interface to the Directory Facilitator Agent of the /// Platform. /// public interface IYellowPagesServer { /// /// Looks for agents that offer the requested service. /// /// Description of the requested service /// An array of DFAgentDescription objects DFAgentDescription[] SearchAgent(ServiceDescription sd); /// /// Looks for agents that offer the requested service. /// /// Description of the requested service /// Flags that specify which fields are used to compare the services /// An array of DFAgentDescription objects DFAgentDescription[] SearchAgent(ServiceDescription sd, ServiceComparison flags); /// /// Looks for agents that offer the requested service and applies the given constraint to the search. /// /// Description of the requested service /// Constraint applied to the search process /// An array of DFAgentDescription objects DFAgentDescription[] SearchAgent(ServiceDescription sd, SearchConstraints constraint); /// /// Looks for agents that offer the requested service and applies the given constraint to the search. /// /// Description of the requested service /// Constraint applied to the search process /// Flags that specify which fields are used to compare the services /// An array of DFAgentDescription objects DFAgentDescription[] SearchAgent(ServiceDescription sd, ServiceComparison flags, SearchConstraints constraint); /// /// Registers an agent with the directory facilitator service. /// /// description of the services promoted by the agent void Register(DFAgentDescription description); /// /// Modifies the agent description previously registered with the directory facilitator service. /// /// description of the services promoted by the agent void Edit(DFAgentDescription description); /// /// Registers an agent with the directory facilitator service. /// /// identifier of the agents whoes description has to be removed void Deregister(AID aid); } /// /// Interface IYellowPagesClient. Interface to the Directory Facilitator Agent of the /// Platform. /// [ServiceContract] [ServiceKnownType(typeof(AgentTemplateDescriptor))] [ServiceKnownType(typeof(KnowledgeDescriptor))] [ServiceKnownType(typeof(BehaviourDescriptor))] public interface IYellowPagesClient : IRuntimeBindable { /// /// Looks for agents that offer the requested service. /// /// Description of the requested service /// An array of DFAgentDescription objects [OperationContract(Name = "SearchAgent_Description")] DFAgentDescription[] SearchAgent(ServiceDescription sd); /// /// Looks for agents that offer the requested service. /// /// Description of the requested service /// Flags that specify which fields are used to compare the services /// An array of DFAgentDescription objects [OperationContract(Name = "SearchAgent_Description_Comparison")] DFAgentDescription[] SearchAgent(ServiceDescription sd, ServiceComparison flags); /// /// Looks for agents that offer the requested service and applies the given constraint to the search. /// /// Description of the requested service /// Constraint applied to the search process /// An array of DFAgentDescription objects [OperationContract(Name = "SearchAgent_Description_Constraint")] DFAgentDescription[] SearchAgent(ServiceDescription sd, SearchConstraints constraint); /// /// Looks for agents that offer the requested service and applies the given constraint to the search. /// /// Description of the requested service /// Constraint applied to the search process /// Flags that specify which fields are used to compare the services /// An array of DFAgentDescription objects [OperationContract(Name = "SearchAgent_Description_Comparison_Constraint")] DFAgentDescription[] SearchAgent(ServiceDescription sd, ServiceComparison flags, SearchConstraints constraint); /// /// Registers an agent with the directory facilitator service. /// /// description of the services promoted by the agent [OperationContract] void Register(DFAgentDescription description); /// /// Modifies the agent description previously registered with the directory facilitator service. /// /// description of the services promoted by the agent [OperationContract] void Edit(DFAgentDescription description); /// /// Deregisters an agent with the directory facilitator service. /// void Deregister(); /// /// Deregisters an agent with the directory facilitator service. /// /// identifier of the agents whoes description has to be removed [OperationContract] void Deregister(AID aid); } }