FreeWRL/FreeX3D  3.0.0
EventInMFInt32.java
1 package vrml.external.field;
3 import vrml.external.Node;
5 
6 public class EventInMFInt32 extends EventIn {
7 
8  public EventInMFInt32() { EventType = FieldTypes.MFINT32; }
9 
10  public void setValue(int value[]) throws IllegalArgumentException {
11  int count;
12  String val;
13 
14  if (value == null) {
15  throw new IllegalArgumentException();
16  }
17  val = "[";
18 
19  for (count = 0; count < value.length; count++) {
20  val = val + " " + value[count] + ",";
21  }
22  val = val + "]";
23  Browser.newSendEvent(this,val);
24  return;
25  }
26 
27  public void set1Value(int index, int value) throws IllegalArgumentException {
28  if (index < 0) {
29  throw new IllegalArgumentException();
30  }
31  Browser.newSendEvent(this, " ONEVAL " + index + " " + value);
32 
33  return;
34  }
35 }