001    package railo.runtime.tag;
002    
003    import java.awt.Color;
004    import java.io.Serializable;
005    import java.util.ArrayList;
006    
007    public class ChartSeriesBean implements Serializable {
008    
009            public static final int MARKER_STYLE_RECTANGLE = 0;
010            public static final int MARKER_STYLE_TRIANGLE = 1;
011            public static final int MARKER_STYLE_DIAMOND = 2;
012            public static final int MARKER_STYLE_CIRCLE = 3;
013            public static final int MARKER_STYLE_LETTER = 4;
014            public static final int MARKER_STYLE_MCROSS = 5;
015            public static final int MARKER_STYLE_SNOW = 6;
016            public static final int MARKER_STYLE_RCROSS = 7;
017    
018            public static final int PAINT_STYLE_PLAIN = 0;
019            public static final int PAINT_STYLE_RAISE = 1;
020            public static final int PAINT_STYLE_SHADE = 2;
021            public static final int PAINT_STYLE_LIGHT = 3;
022            
023            public static final int TYPE_BAR = 0;
024            public static final int TYPE_LINE = 1;
025            public static final int TYPE_PYRAMID = 2;
026            public static final int TYPE_AREA = 3;
027            public static final int TYPE_HORIZONTALBAR = 4;
028            public static final int TYPE_CONE = 5;
029            public static final int TYPE_CURVE = 6;
030            public static final int TYPE_CYLINDER = 7;
031            public static final int TYPE_STEP = 8;
032            public static final int TYPE_SCATTER = 9;
033            public static final int TYPE_PIE = 10;
034            public static final int TYPE_TIME = 11;
035    
036            public static final int DATA_LABEL_STYLE_NONE = 0;
037            public static final int DATA_LABEL_STYLE_VALUE = 1;
038            public static final int DATA_LABEL_STYLE_ROWLABEL = 2;
039            public static final int DATA_LABEL_STYLE_COLUMNLABEL = 3;
040            public static final int DATA_LABEL_STYLE_PATTERN = 4;
041    
042            private Color[] colorlist=null;
043            private int markerStyle=MARKER_STYLE_RECTANGLE;
044            private int paintStyle=PAINT_STYLE_PLAIN;
045            private Color seriesColor;
046            private String seriesLabel;
047            private int type=TYPE_BAR;
048            private int dataLabelStyle=DATA_LABEL_STYLE_NONE;
049            private java.util.List datas=new ArrayList();
050            /**
051             * @return the colorlist
052             */
053            public Color[] getColorlist() {
054                    if(colorlist==null) return new Color[0];
055                    return colorlist;
056            }
057            /**
058             * @param colorlist the colorlist to set
059             */
060            public void setColorlist(Color[] colorlist) {
061                    this.colorlist = colorlist;
062            }
063            /**
064             * @return the dataLabelStyle
065             */
066            public int getDataLabelStyle() {
067                    return dataLabelStyle;
068            }
069            /**
070             * @param dataLabelStyle the dataLabelStyle to set
071             */
072            public void setDataLabelStyle(int dataLabelStyle) {
073                    this.dataLabelStyle = dataLabelStyle;
074            }
075            
076    
077            /**
078             * @return the markerStyle
079             */
080            public int getMarkerStyle() {
081                    return markerStyle;
082            }
083            /**
084             * @param markerStyle the markerStyle to set
085             */
086            public void setMarkerStyle(int markerStyle) {
087                    this.markerStyle = markerStyle;
088            }
089            /**
090             * @return the paintStyle
091             */
092            public int getPaintStyle() {
093                    return paintStyle;
094            }
095            /**
096             * @param paintStyle the paintStyle to set
097             */
098            public void setPaintStyle(int paintStyle) {
099                    this.paintStyle = paintStyle;
100            }
101            /**
102             * @return the seriesColor
103             */
104            public Color getSeriesColor() {
105                    return seriesColor;
106            }
107            /**
108             * @param seriesColor the seriesColor to set
109             */
110            public void setSeriesColor(Color seriesColor) {
111                    this.seriesColor = seriesColor;
112            }
113            /**
114             * @return the seriesLabel
115             */
116            public String getSeriesLabel() {
117                    return seriesLabel;
118            }
119            /**
120             * @param seriesLabel the seriesLabel to set
121             */
122            public void setSeriesLabel(String seriesLabel) {
123                    this.seriesLabel = seriesLabel;
124            }
125            /**
126             * @return the type
127             */
128            public int getType() {
129                    return type;
130            }
131            /**
132             * @param type the type to set
133             */
134            public void setType(int type) {
135                    this.type = type;
136            }
137            public void addChartData(ChartDataBean data) {
138                    datas.add(data);
139            }
140            /**
141             * @return the datas
142             */
143            public java.util.List getDatas() {
144                    return datas;
145            }
146            
147    }