org.powertac.visualizer.services
Class CustomerService
java.lang.Object
org.powertac.visualizer.services.CustomerService
- All Implemented Interfaces:
- Recyclable, TimeslotCompleteActivation
@Service
public class CustomerService
- extends Object
- implements TimeslotCompleteActivation, Recyclable
Contains data about the customers.
- Author:
- Jurica Babic
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CustomerService
public CustomerService()
addCustomers
public void addCustomers(List<org.powertac.common.CustomerInfo> customerInfos)
- Creates and adds a customer object into the map. Map key will be a given
customerInfo.
findCustomerByNameAndType
public Customer findCustomerByNameAndType(String customerName,
org.powertac.common.enumerations.PowerType type)
- Parameters:
customerName -
- Returns:
- Customer associated by the given name, or null if the customer
cannot be found.
recycle
public void recycle()
- Specified by:
recycle in interface Recyclable
getCustomerList
public List<Customer> getCustomerList()
activate
public void activate(int timeslotIndex,
org.joda.time.Instant postedTime)
- Specified by:
activate in interface TimeslotCompleteActivation
- Parameters:
timeslotIndex - index of completed timeslot.
findCustomerByCustomerInfo
public Customer findCustomerByCustomerInfo(org.powertac.common.CustomerInfo customerInfo)
Copyright © 2013 Power TAC. All Rights Reserved.