EMlab-generation Documentation  1.0
Documentation of the EMLab-Generation model.
SegmentLoad.java
1 /*******************************************************************************
2  * Copyright 2012 the original author or authors.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  ******************************************************************************/
16 package emlab.gen.domain.market.electricity;
17 
18 import org.neo4j.graphdb.Direction;
19 import org.springframework.data.neo4j.annotation.NodeEntity;
20 import org.springframework.data.neo4j.annotation.RelatedTo;
21 
22 @NodeEntity
23 public class SegmentLoad {
24 
25  @RelatedTo(type = "SEGMENTLOAD_SEGMENT", elementClass = Segment.class, direction = Direction.OUTGOING)
26  private Segment segment;
27 
28  @RelatedTo(type = "SEGMENT_LOAD", elementClass = ElectricitySpotMarket.class, direction = Direction.INCOMING)
29  private ElectricitySpotMarket electricitySpotMarket;
30 
31  private double baseLoad;
32 
33  private double currentLoad;
34 
35  public Segment getSegment() {
36  return segment;
37  }
38 
39  public void setSegment(Segment segment) {
40  this.segment = segment;
41  }
42 
43  public ElectricitySpotMarket getElectricitySpotMarket() {
44  return electricitySpotMarket;
45  }
46 
47  public void setElectricitySpotMarket(ElectricitySpotMarket electricitySpotMarket) {
48  this.electricitySpotMarket = electricitySpotMarket;
49  }
50 
51  public double getBaseLoad() {
52  return baseLoad;
53  }
54 
55  public void setBaseLoad(double baseLoad) {
56  this.baseLoad = baseLoad;
57  }
58 
59 
60  public double getCurrentLoad() {
61  return currentLoad;
62  }
63 
64  public void setCurrentLoad(double currentLoad) {
65  this.currentLoad = currentLoad;
66  }
67 
68  @Override
69  public String toString() {
70  return "segment: " + segment + " load: " + getBaseLoad();
71  }
72 
73 }