|
| 1 | +/* |
| 2 | + * Copyright 2013 Peter Lawrey |
| 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 net.openhft.fix.include.v42; |
| 17 | + |
| 18 | +import net.openhft.fix.model.FixField; |
| 19 | +import net.openhft.lang.collection.HugeArray; |
| 20 | +import net.openhft.lang.collection.HugeCollections; |
| 21 | + |
| 22 | +public class Field |
| 23 | +{ |
| 24 | + protected HugeArray<Value> value; |
| 25 | + protected String name; |
| 26 | + protected int number; |
| 27 | + protected String required; |
| 28 | + protected FixField type; |
| 29 | + protected int valueSize; |
| 30 | + |
| 31 | + public Field setValueSize(int valueSize){ |
| 32 | + this.valueSize = valueSize; |
| 33 | + return this; |
| 34 | + } |
| 35 | + |
| 36 | + public HugeArray<Value> getValue() { |
| 37 | + if (value == null) { |
| 38 | + value = HugeCollections.newArray(Value.class, valueSize); |
| 39 | + } |
| 40 | + return this.value; |
| 41 | + } |
| 42 | + |
| 43 | + public String getName() { |
| 44 | + return name; |
| 45 | + } |
| 46 | + |
| 47 | + public void setName(String value) { |
| 48 | + this.name = value; |
| 49 | + } |
| 50 | + |
| 51 | + public double getNumber() { |
| 52 | + return number; |
| 53 | + } |
| 54 | + |
| 55 | + public void setNumber(int value) { |
| 56 | + this.number = value; |
| 57 | + } |
| 58 | + |
| 59 | + public String getRequired() { |
| 60 | + return required; |
| 61 | + } |
| 62 | + |
| 63 | + public void setRequired(String value) { |
| 64 | + this.required = value; |
| 65 | + } |
| 66 | + |
| 67 | + public FixField getType() { |
| 68 | + return type; |
| 69 | + } |
| 70 | + |
| 71 | + public void setType(FixField value) { |
| 72 | + this.type = value; |
| 73 | + } |
| 74 | + |
| 75 | +} |
0 commit comments