Class ServiceState

java.lang.Object
cz.metacentrum.perun.controller.model.ServiceState

public class ServiceState extends Object
ServiceState is object containing information about one service propagated on one facility.
Author:
Jana Cechackova, Pavel Zlámal <zlamal@cesnet.cz>
  • Constructor Details

    • ServiceState

      public ServiceState()
      Create new instance of ServiceState.
    • ServiceState

      public ServiceState(Service service, Facility facility)
  • Method Details

    • getService

      public Service getService()
    • setService

      public void setService(Service service)
    • getFacility

      public Facility getFacility()
    • setFacility

      public void setFacility(Facility facility)
    • getTask

      public Task getTask()
    • setTask

      public void setTask(Task task)
    • isBlockedGlobally

      public boolean isBlockedGlobally()
    • isBlockedOnFacility

      public boolean isBlockedOnFacility()
    • setBlockedOnFacility

      public void setBlockedOnFacility(boolean isBlockedOnFacility)
    • getHasDestinations

      public boolean getHasDestinations()
    • setHasDestinations

      public void setHasDestinations(boolean hasDestinations)
    • getTaskId

      public int getTaskId()
      Return ID of Task. If present SEND Task takes precedence. If not GEN Task is used or 0 is returned if none Task is present.
      Returns:
      ID of Task
    • getScheduled

      public Long getScheduled()
      Return time when was Task on Facility scheduled if ever for the last time.
      Returns:
      Time when was last task scheduled.
    • getStartTime

      public Long getStartTime()
      Return time when was Task on Facility scheduled if ever for the last time.
      Returns:
      Time when was last task scheduled.
    • getEndTime

      public Long getEndTime()
      Return time when was Task on Facility scheduled if ever for the last time.
      Returns:
      Time when was last task scheduled.
    • getStatus

      public Task.TaskStatus getStatus()
      Return status of service propagation (task status) based on current tasks states. Method compares "scheduled" dates of tasks in order to determine, which is more relevant. If can't determine, TaskStatus.NONE is returned.
      Returns:
      TaskStatus of service on facility
    • getBeanName

      public String getBeanName()
    • toString

      public String toString()
      Overrides:
      toString in class Object