Changeset 1316 for DCWoRMS


Ignore:
Timestamp:
03/31/14 16:01:19 (11 years ago)
Author:
wojtekp
Message:
 
Location:
DCWoRMS/branches/coolemall/src
Files:
1 added
5 edited

Legend:

Unmodified
Added
Removed
  • DCWoRMS/branches/coolemall/src/gridsim/dcworms/DCWormsTags.java

    r1295 r1316  
    3434        public static final int TASK_REQUESTED_TIME_EXPIRED = DCWORMSBASE + 6; 
    3535         
    36         public static final int POWER_LIMIT_EXCEEDED = DCWORMSBASE + 7; 
     36        public static final int RESOURCE_STATE_CHANGED = DCWORMSBASE + 7; 
     37         
     38        public static final int POWER_LIMIT_EXCEEDED = DCWORMSBASE + 8; 
    3739 
    3840         
  • DCWoRMS/branches/coolemall/src/schedframe/events/EventCommand.java

    r477 r1316  
    44 
    55public interface EventCommand { 
    6  
    7         public void execute(EventType evType); 
    86         
    97        public void execute(Event event); 
  • DCWoRMS/branches/coolemall/src/schedframe/events/ResourceEventCommand.java

    r1207 r1316  
    1010                this.resource = resource; 
    1111        } 
    12          
    13         public void execute(EventType evType) { 
    14                 //TODO - add event factory 
    15                 throw new RuntimeException("not implemented"); 
    16         } 
    1712 
    1813        public void execute(Event event) { 
  • DCWoRMS/branches/coolemall/src/schedframe/events/scheduling/SchedulingEvent.java

    r477 r1316  
    1616         
    1717        public SchedulingEvent(EventType eventType, EventReason eventReason){ 
    18                 type = eventType; 
    19                 reason = eventReason; 
     18                this.type = eventType; 
     19                this.reason = eventReason; 
    2020        } 
    2121         
     
    3939         
    4040        public String getSource(){ 
    41                 return this.source; 
     41                return source; 
    4242        } 
    4343 
     
    4646        } 
    4747 
    48         @Override 
    4948        public Object getData() { 
    5049                return null; 
  • DCWoRMS/branches/coolemall/src/schedframe/events/scheduling/SchedulingEventCommand.java

    r1207 r1316  
    33import schedframe.events.Event; 
    44import schedframe.events.EventCommand; 
    5 import schedframe.events.EventType; 
    65import schedframe.resources.computing.ComputingResource; 
    76 
     
    1413        } 
    1514         
    16         public void execute(EventType evType) { 
    17                 SchedulingEvent ev = new SchedulingEvent(evType); 
    18                 ev.setSource(compResource.getFullName()); 
    19                 compResource.getEventHandler().handleSchedulingEvent(ev); 
    20         } 
    21          
    2215        public void execute(Event event) { 
    23                 SchedulingEvent ev = new SchedulingEvent(event.getType()); 
     16                SchedulingEvent ev = new ResourceStateChangedEvent(compResource.getFullName(), event.getType()); 
    2417                ev.setSource(compResource.getFullName()); 
    2518                compResource.getEventHandler().handleSchedulingEvent(ev); 
Note: See TracChangeset for help on using the changeset viewer.