BrightSide Workbench Full Report + Source Code
org.turro.erp.task.Workload Class Reference
Inheritance diagram for org.turro.erp.task.Workload:
Collaboration diagram for org.turro.erp.task.Workload:

Public Member Functions

 Workload (RequiredUsage requiredUsage)
 
 Workload (OrderItem orderItem)
 
RequiredUsage getRequiredUsage ()
 
OrderItem getOrderItem ()
 
boolean isChecked ()
 
void setChecked (boolean checked)
 
double getOrderUnits ()
 
void setOrderUnits (double orderUnits)
 
Task getTask ()
 
void setTask (Task task)
 
int compareTo (Workload o)
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 31 of file Workload.java.

Constructor & Destructor Documentation

◆ Workload() [1/2]

org.turro.erp.task.Workload.Workload ( RequiredUsage  requiredUsage)

Definition at line 39 of file Workload.java.

39  {
40  this.requiredUsage = requiredUsage;
41  task = requiredUsage.getTask();
42  task.checkStatus(new Date());
43  checked = !task.isWaiting();
44  }
Here is the call graph for this function:

◆ Workload() [2/2]

org.turro.erp.task.Workload.Workload ( OrderItem  orderItem)

Definition at line 46 of file Workload.java.

46  {
47  this.orderItem = orderItem;
48  task = orderItem.getOwnerRequiredUsage().getTask();
49  task.checkStatus(new Date());
50  checked = !task.isWaiting();
51  }
RequiredUsage getOwnerRequiredUsage()
Definition: OrderItem.java:374
Here is the call graph for this function:

Member Function Documentation

◆ compareTo()

int org.turro.erp.task.Workload.compareTo ( Workload  o)

Reimplemented in org.turro.erp.task.WorksheetItem.

Definition at line 86 of file Workload.java.

86  {
87  int result = 0;
88  if(orderItem != null) {
89  result = -CompareUtil.compare(orderItem.getDocumentDate(), o.orderItem.getDocumentDate());
90  if(result == 0) {
91  result = new PendingTask(task).compareTo(new PendingTask(o.task));
92  }
93  if(result == 0) {
94  result = CompareUtil.compare(orderItem.getId(), o.orderItem.getId());
95  }
96  } else {
97  result = new PendingTask(task).compareTo(new PendingTask(o.task));
98  if(result == 0) {
99  result = CompareUtil.compare(!requiredUsage.isCanChange(), !o.requiredUsage.isCanChange());
100  }
101  if(result == 0) {
102  result = CompareUtil.compare(requiredUsage.getId(), o.requiredUsage.getId());
103  }
104  }
105  return result;
106  }
Here is the call graph for this function:

◆ getOrderItem()

OrderItem org.turro.erp.task.Workload.getOrderItem ( )

Definition at line 57 of file Workload.java.

57  {
58  return orderItem;
59  }
Here is the caller graph for this function:

◆ getOrderUnits()

double org.turro.erp.task.Workload.getOrderUnits ( )

Definition at line 69 of file Workload.java.

69  {
70  return orderUnits;
71  }

◆ getRequiredUsage()

RequiredUsage org.turro.erp.task.Workload.getRequiredUsage ( )

Definition at line 53 of file Workload.java.

53  {
54  return requiredUsage;
55  }
Here is the caller graph for this function:

◆ getTask()

Task org.turro.erp.task.Workload.getTask ( )

Definition at line 77 of file Workload.java.

77  {
78  return task;
79  }
Here is the caller graph for this function:

◆ isChecked()

boolean org.turro.erp.task.Workload.isChecked ( )

Definition at line 61 of file Workload.java.

61  {
62  return checked;
63  }

◆ setChecked()

void org.turro.erp.task.Workload.setChecked ( boolean  checked)

Definition at line 65 of file Workload.java.

65  {
66  this.checked = checked;
67  }

◆ setOrderUnits()

void org.turro.erp.task.Workload.setOrderUnits ( double  orderUnits)

Definition at line 73 of file Workload.java.

73  {
74  this.orderUnits = orderUnits;
75  }

◆ setTask()

void org.turro.erp.task.Workload.setTask ( Task  task)

Definition at line 81 of file Workload.java.

81  {
82  this.task = task;
83  }

The documentation for this class was generated from the following file: