jadex.micro.examples.helpline
Class HelplineService

java.lang.Object
  extended by jadex.commons.service.BasicService
      extended by jadex.micro.examples.helpline.HelplineService
All Implemented Interfaces:
IRemotable, IInternalService, IService, IHelpline

public class HelplineService
extends BasicService
implements IHelpline

Helpline service implementation.


Field Summary
protected  HelplineAgent agent
          The agent.
 
Fields inherited from class jadex.commons.service.BasicService
idcnt, properties, shutdowned, sid, started, startfutures
 
Fields inherited from interface jadex.commons.service.IService
EMPTY_SERVICES
 
Constructor Summary
HelplineService(HelplineAgent agent)
          Create a new helpline service.
 
Method Summary
 void addInformation(String name, String info)
          Add an information about a person.
 IFuture getInformation(String name)
          Get all locally stored information about a person.
 String toString()
          Get the string representation.
 
Methods inherited from class jadex.commons.service.BasicService
createServiceIdentifier, generateServiceName, getPropertyMap, getServiceIdentifier, isValid, setPropertyMap, shutdownService, signalStarted, startService
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

agent

protected HelplineAgent agent
The agent.

Constructor Detail

HelplineService

public HelplineService(HelplineAgent agent)
Create a new helpline service.

Method Detail

addInformation

public void addInformation(String name,
                           String info)
Add an information about a person.

Specified by:
addInformation in interface IHelpline
Parameters:
name - The person's name.
info - The information.

getInformation

public IFuture getInformation(String name)
Get all locally stored information about a person.

Specified by:
getInformation in interface IHelpline
Parameters:
name - The person's name.
Returns:
Future that contains the information.

toString

public String toString()
Get the string representation.

Overrides:
toString in class Object
Returns:
The string representation.


Copyright © 2010. All Rights Reserved.