~thermoteam/thermopi/model

« back to all changes in this revision

Viewing changes to Slot.java

  • Committer: Alain
  • Date: 2008-04-21 13:49:19 UTC
  • Revision ID: alain@faramir-20080421134919-n17rpvf7pydhzsoa
Les fichiers du modèle

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
package modele;
 
2
 
 
3
import java.util.Collection;
 
4
import java.util.Iterator;
 
5
 
 
6
 
 
7
public class Slot {
 
8
 
 
9
        /** 
 
10
         * @uml.property name="ship"
 
11
         * @uml.stereotype uml_id="JavaProfile::JavaType" value="java.util.Collection" 
 
12
         * @uml.associationEnd inverse="slot:modele.Ship"
 
13
         */
 
14
        private Ship    ship;
 
15
 
 
16
        /** 
 
17
         * Getter of the property <tt>ship</tt>
 
18
         * @return  Returns the ship.
 
19
         * @uml.property  name="ship"
 
20
         * @uml.stereotype  uml_id="JavaProfile::JavaType" value="java.util.Collection" 
 
21
         * @uml.associationEnd  inverse="slot:modele.Ship"
 
22
         */
 
23
        public Ship getShip() {
 
24
                return ship;
 
25
        }
 
26
 
 
27
        /** 
 
28
         * Setter of the property <tt>ship</tt>
 
29
         * @param ship  the ship to set.
 
30
         * @uml.property  name="ship"
 
31
         * @uml.stereotype  uml_id="JavaProfile::JavaType" value="java.util.Collection" 
 
32
         * @uml.associationEnd  inverse="slot:modele.Ship"
 
33
         */
 
34
        public void setShip(Ship ship) {
 
35
                this.ship = ship;
 
36
        }
 
37
 
 
38
        /**
 
39
         * @uml.property  name="position"
 
40
         */
 
41
        private CartesianPosition       position;
 
42
 
 
43
        /**
 
44
         * Getter of the property <tt>position</tt>
 
45
         * @return  Returns the position.
 
46
         * @uml.property  name="position"
 
47
         */
 
48
        public CartesianPosition getPosition() {
 
49
                return position;
 
50
        }
 
51
 
 
52
        /**
 
53
         * Setter of the property <tt>position</tt>
 
54
         * @param position  The position to set.
 
55
         * @uml.property  name="position"
 
56
         */
 
57
        public void setPosition(CartesianPosition position) {
 
58
                this.position = position;
 
59
        }
 
60
 
 
61
}
 
62
 
 
63
///**
 
64
//       * Returns the number of elements in this collection.
 
65
//       * @return  the number of elements in this collection
 
66
//       * @see java.util.Collection#size()
 
67
//       * @uml.property  name="ship"
 
68
//       */
 
69
//      public int shipSize() {
 
70
//              return ship.size();
 
71
//      }
 
72
///**
 
73
//       * Setter of the property <tt>ship</tt>
 
74
//       * @param ship  the ship to set.
 
75
//       * @uml.property  name="ship"
 
76
//       */
 
77
//      public void setShip(Collection ship) {
 
78
//              this.ship = ship;
 
79
//      }
 
80
///**
 
81
//       * Ensures that this collection contains the specified element (optional operation). 
 
82
//       * @param element  whose presence in this collection is to be ensured.
 
83
//       * @see java.util.Collection#add(Object)
 
84
//       * @uml.property  name="ship"
 
85
//       */
 
86
//      public boolean addShip(Ship Ship) {
 
87
//              return ship.add(Ship);
 
88
//      }
 
89
///**
 
90
//       * Returns <tt>true</tt> if this collection contains all of the elements in the specified collection.
 
91
//       * @param elements  collection to be checked for containment in this collection.
 
92
//       * @see java.util.Collection#containsAll(Collection)
 
93
//       * @uml.property  name="ship"
 
94
//       */
 
95
//      public boolean containsAllShip(Collection ship) {
 
96
//              return this.ship.containsAll(ship);
 
97
//      }
 
98
///**
 
99
//       * Removes all of the elements from this collection (optional operation).
 
100
//       * @see java.util.Collection#clear()
 
101
//       * @uml.property  name="ship"
 
102
//       */
 
103
//      public void clearShip() {
 
104
//              ship.clear();
 
105
//      }
 
106
///**
 
107
//       * Returns all elements of this collection in an array.
 
108
//       * @return  an array containing all of the elements in this collection
 
109
//       * @see java.util.Collection#toArray()
 
110
//       * @uml.property  name="ship"
 
111
//       */
 
112
//      public Ship[] shipToArray() {
 
113
//              return (Ship[]) ship.toArray(new Ship[ship.size()]);
 
114
//      }
 
115
///**
 
116
//       * Removes a single instance of the specified element from this collection, if it is present (optional operation).
 
117
//       * @param element  to be removed from this collection, if present.
 
118
//       * @see java.util.Collection#add(Object)
 
119
//       * @uml.property  name="ship"
 
120
//       */
 
121
//      public boolean removeShip(Ship Ship) {
 
122
//              return ship.remove(Ship);
 
123
//      }
 
124
///**
 
125
//       * Getter of the property <tt>ship</tt>
 
126
//       * @return  Returns the ship.
 
127
//       * @uml.property  name="ship"
 
128
//       */
 
129
//      public Collection getShip() {
 
130
//              return ship;
 
131
//      }
 
132
///**
 
133
//       * Returns <tt>true</tt> if this collection contains the specified element. 
 
134
//       * @param element  whose presence in this collection is to be tested.
 
135
//       * @see java.util.Collection#contains(Object)
 
136
//       * @uml.property  name="ship"
 
137
//       */
 
138
//      public boolean containsShip(Ship Ship) {
 
139
//              return ship.contains(Ship);
 
140
//      }
 
141
///**
 
142
//       * Returns <tt>true</tt> if this collection contains no elements.
 
143
//       * @return  <tt>true</tt> if this collection contains no elements
 
144
//       * @see java.util.Collection#isEmpty()
 
145
//       * @uml.property  name="ship"
 
146
//       */
 
147
//      public boolean isShipEmpty() {
 
148
//              return ship.isEmpty();
 
149
//      }
 
150
///**
 
151
//       * Returns an iterator over the elements in this collection. 
 
152
//       * @return  an <tt>Iterator</tt> over the elements in this collection
 
153
//       * @see java.util.Collection#iterator()
 
154
//       * @uml.property  name="ship"
 
155
//       */
 
156
//      public Iterator shipIterator() {
 
157
//              return ship.iterator();
 
158
//      }
 
 
b'\\ No newline at end of file'