001: /***
002: * Retrotranslator: a Java bytecode transformer that translates Java classes
003: * compiled with JDK 5.0 into classes that can be run on JVM 1.4.
004: *
005: * Copyright (c) 2005 - 2008 Taras Puchko
006: * All rights reserved.
007: *
008: * Redistribution and use in source and binary forms, with or without
009: * modification, are permitted provided that the following conditions
010: * are met:
011: * 1. Redistributions of source code must retain the above copyright
012: * notice, this list of conditions and the following disclaimer.
013: * 2. Redistributions in binary form must reproduce the above copyright
014: * notice, this list of conditions and the following disclaimer in the
015: * documentation and/or other materials provided with the distribution.
016: * 3. Neither the name of the copyright holders nor the names of its
017: * contributors may be used to endorse or promote products derived from
018: * this software without specific prior written permission.
019: *
020: * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
021: * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
022: * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
023: * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
024: * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
025: * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
026: * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
027: * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
028: * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
029: * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
030: * THE POSSIBILITY OF SUCH DAMAGE.
031: */package net.sf.retrotranslator.tests;
032:
033: /**
034: * @author Taras Puchko
035: */
036: public class TestBean {
037:
038: private boolean visible;
039: private char sign;
040: private byte code;
041: private short width;
042: private int height;
043: private float opacity;
044: private long area;
045: private double weight;
046: private String name;
047: private String direction;
048: private String state;
049:
050: public TestBean(boolean visible, char sign, byte code, short width,
051: int height, float opacity, long area, double weight,
052: String name) {
053: this .direction = "right";
054: this .visible = visible;
055: this .sign = sign;
056: this .code = code;
057: this .width = width;
058: this .height = height;
059: this .opacity = opacity;
060: this .area = area;
061: this .weight = weight;
062: this .name = name;
063: }
064:
065: public TestBean(String name, double weight, long area,
066: float opacity, int height, short width, byte code,
067: char sign, boolean visible) {
068: this .direction = "reverse";
069: this .name = name;
070: this .weight = weight;
071: this .area = area;
072: this .opacity = opacity;
073: this .height = height;
074: this .width = width;
075: this .code = code;
076: this .sign = sign;
077: this .visible = visible;
078: }
079:
080: public TestBean(String state) {
081: this .direction = "A";
082: this .state = state;
083: }
084:
085: public TestBean() {
086: this .direction = "B";
087: }
088:
089: public boolean isVisible() {
090: return visible;
091: }
092:
093: public char getSign() {
094: return sign;
095: }
096:
097: public byte getCode() {
098: return code;
099: }
100:
101: public short getWidth() {
102: return width;
103: }
104:
105: public int getHeight() {
106: return height;
107: }
108:
109: public float getOpacity() {
110: return opacity;
111: }
112:
113: public long getArea() {
114: return area;
115: }
116:
117: public double getWeight() {
118: return weight;
119: }
120:
121: public String getName() {
122: return name;
123: }
124:
125: public String getDirection() {
126: return direction;
127: }
128:
129: public String getState() {
130: return state;
131: }
132:
133: public void setState(String state) {
134: this.state = state;
135: }
136: }
|