~vcs-imports/evaristo/trunk

« back to all changes in this revision

Viewing changes to com/m16e/mpbiz/tables/DbProdInvent.java

  • Committer: m16e
  • Date: 2004-01-21 17:10:58 UTC
  • Revision ID: vcs-imports@canonical.com-20040121171058-00w8f93ynnk2xwve
Initial revision

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * $Log: DbProdInvent.java,v $
 
3
 * Revision 1.1  2004/01/21 17:17:13  m16e
 
4
 * Initial revision
 
5
 *
 
6
 *
 
7
 *
 
8
 */
 
9
 
 
10
package com.m16e.mpbiz.tables;
 
11
 
 
12
import java.io.*;
 
13
import java.util.*;
 
14
import java.text.*;
 
15
import java.sql.*;
 
16
import com.m16e.free.tools.*;
 
17
import com.m16e.free.tools.db.*;
 
18
import com.m16e.free.tools.debug.*;
 
19
import com.m16e.free.tools.xml.*;
 
20
 
 
21
////////////////////////////////////////////////////////////
 
22
public class DbProdInvent
 
23
        extends DbTab
 
24
        implements DbTableInterface
 
25
{
 
26
        public final static String XGUI_FORM_PROD_INVENT =
 
27
                "xgui-form-prod-invent.xml";
 
28
        public final static String XGUI_FORM_PROD_INVENT_FRAME =
 
29
                "form-prod-invent-frame";
 
30
        public final static String XGUI_LIST_PROD_INVENT =
 
31
                "xgui-list-prod-invent.xml";
 
32
        public final static String XGUI_LIST_PROD_INVENT_FRAME =
 
33
                "list-prod-invent-frame";
 
34
 
 
35
        public final static String T_NAME = "prod_invent";
 
36
        public final static String[] FIELDS = 
 
37
                {       "prod_id",
 
38
                        "nome",
 
39
                        "barcode",
 
40
                        "ult_p_custo",
 
41
                        "pvenda",
 
42
                        "quant",
 
43
                        "taxa_id",
 
44
                        "tipo_prod_id",
 
45
                        "uni_mov_id",
 
46
                        "data_ult_p_custo",
 
47
                        "familia_id",
 
48
                        "sub_familia_id",
 
49
                        "img_file",
 
50
                        "versao",
 
51
                        "data_versao",
 
52
                        "obs",
 
53
                        "qt1",
 
54
                        "qt2",
 
55
                        "qt3",
 
56
                        "qt4",
 
57
                        "qt5",
 
58
                        "qt6" };
 
59
        public final static String[] FIELD_NAMES = 
 
60
                {       "prod_id",
 
61
                        "nome",
 
62
                        "barcode",
 
63
                        "ult_p_custo",
 
64
                        "pvenda",
 
65
                        "quant",
 
66
                        "taxa_id",
 
67
                        "tipo_prod_id",
 
68
                        "uni_mov_id",
 
69
                        "data_ult_p_custo",
 
70
                        "familia_id",
 
71
                        "sub_familia_id",
 
72
                        "img_file",
 
73
                        "versao",
 
74
                        "data_versao",
 
75
                        "obs",
 
76
                        "qt1",
 
77
                        "qt2",
 
78
                        "qt3",
 
79
                        "qt4",
 
80
                        "qt5",
 
81
                        "qt6" };
 
82
        public final static int PROD_ID = 0;
 
83
        public final static int NOME = 1;
 
84
        public final static int BARCODE = 2;
 
85
        public final static int ULT_P_CUSTO = 3;
 
86
        public final static int PVENDA = 4;
 
87
        public final static int QUANT = 5;
 
88
        public final static int TAXA_ID = 6;
 
89
        public final static int TIPO_PROD_ID = 7;
 
90
        public final static int UNI_MOV_ID = 8;
 
91
        public final static int DATA_ULT_P_CUSTO = 9;
 
92
        public final static int FAMILIA_ID = 10;
 
93
        public final static int SUB_FAMILIA_ID = 11;
 
94
        public final static int IMG_FILE = 12;
 
95
        public final static int VERSAO = 13;
 
96
        public final static int DATA_VERSAO = 14;
 
97
        public final static int OBS = 15;
 
98
        public final static int QT1 = 16;
 
99
        public final static int QT2 = 17;
 
100
        public final static int QT3 = 18;
 
101
        public final static int QT4 = 19;
 
102
        public final static int QT5 = 20;
 
103
        public final static int QT6 = 21;
 
104
        public final static TupleColDataModel[] TCDM =
 
105
        {
 
106
                // prod_id
 
107
                new TupleColDataModel( 
 
108
                                Integer.class, FIELDS[0], 8, false ),
 
109
                // nome
 
110
                new TupleColDataModel( 
 
111
                                String.class, FIELDS[1], 40, false ),
 
112
                // barcode
 
113
                new TupleColDataModel( 
 
114
                                String.class, FIELDS[2], 20, false ),
 
115
                // ult_p_custo
 
116
                new TupleColDataModel( 
 
117
                                Double.class, FIELDS[3], 15, false ),
 
118
                // pvenda
 
119
                new TupleColDataModel( 
 
120
                                Double.class, FIELDS[4], 15, false ),
 
121
                // quant
 
122
                new TupleColDataModel( 
 
123
                                Double.class, FIELDS[5], 15, false ),
 
124
                // taxa_id
 
125
                new TupleColDataModel( 
 
126
                                Integer.class, FIELDS[6], 8, false ),
 
127
                // tipo_prod_id
 
128
                new TupleColDataModel( 
 
129
                                Integer.class, FIELDS[7], 8, false ),
 
130
                // uni_mov_id
 
131
                new TupleColDataModel( 
 
132
                                Integer.class, FIELDS[8], 8, false ),
 
133
                // data_ult_p_custo
 
134
                new TupleColDataModel( 
 
135
                                java.sql.Date.class, FIELDS[9], 10, false ),
 
136
                // familia_id
 
137
                new TupleColDataModel( 
 
138
                                Integer.class, FIELDS[10], 8, false ),
 
139
                // sub_familia_id
 
140
                new TupleColDataModel( 
 
141
                                Integer.class, FIELDS[11], 8, false ),
 
142
                // img_file
 
143
                new TupleColDataModel( 
 
144
                                String.class, FIELDS[12], 256, false ),
 
145
                // versao
 
146
                new TupleColDataModel( 
 
147
                                String.class, FIELDS[13], 10, false ),
 
148
                // data_versao
 
149
                new TupleColDataModel( 
 
150
                                java.sql.Date.class, FIELDS[14], 10, false ),
 
151
                // obs
 
152
                new TupleColDataModel( 
 
153
                                String.class, FIELDS[15], 1024, false ),
 
154
                // qt1
 
155
                new TupleColDataModel( 
 
156
                                Double.class, FIELDS[16], 15, false ),
 
157
                // qt2
 
158
                new TupleColDataModel( 
 
159
                                Double.class, FIELDS[17], 15, false ),
 
160
                // qt3
 
161
                new TupleColDataModel( 
 
162
                                Double.class, FIELDS[18], 15, false ),
 
163
                // qt4
 
164
                new TupleColDataModel( 
 
165
                                Double.class, FIELDS[19], 15, false ),
 
166
                // qt5
 
167
                new TupleColDataModel( 
 
168
                                Double.class, FIELDS[20], 15, false ),
 
169
                // qt6
 
170
                new TupleColDataModel( 
 
171
                                Double.class, FIELDS[21], 15, false )
 
172
        };
 
173
 
 
174
        public final static TupleDataModel TDM =
 
175
                new TupleDataModel( "DbProdInvent.class", TCDM );
 
176
 
 
177
        ////////////////////////////////////////////////////////////
 
178
        public DbProdInvent( Database db )
 
179
                throws SQLException
 
180
        {
 
181
                super( db, T_NAME, TDM );
 
182
        }
 
183
 
 
184
        ////////////////////////////////////////////////////////////
 
185
        public DbProdInvent( Database db, ResultSet rs )
 
186
                throws SQLException
 
187
        {
 
188
                super( db, T_NAME, TDM );
 
189
                setTuple( rs );
 
190
        }
 
191
 
 
192
        ////////////////////////////////////////////////////////////
 
193
        public DbTableInterface createTab( Database db,  String tableName, ResultSet rs)
 
194
                throws SQLException
 
195
        {
 
196
                DbProdInvent dbProdInvent = new DbProdInvent( db, rs );
 
197
                return dbProdInvent;
 
198
        }
 
199
 
 
200
        ////////////////////////////////////////////////////////////
 
201
        public String getTabLayout()
 
202
        {
 
203
                return XGUI_LIST_PROD_INVENT;
 
204
        }
 
205
 
 
206
        ////////////////////////////////////////////////////////////
 
207
        public String getFormLayout()
 
208
        {
 
209
                return XGUI_FORM_PROD_INVENT;
 
210
        }
 
211
 
 
212
        ////////////////////////////////////////////////////////////
 
213
        public void setData( String xmlData )
 
214
                throws SQLException
 
215
        {
 
216
                DateFormat df = MpAppContext.getInstance().getDateFormat();
 
217
                DateFormat tsf = MpAppContext.getInstance().getTimestampFormat();
 
218
                // prod_id
 
219
                String aux =
 
220
                        XmlInterpreter.getElementValue(
 
221
                                xmlData,
 
222
                                FIELDS[ PROD_ID ] );
 
223
                if ( aux.length() == 0 )
 
224
                        aux = "0";
 
225
                setValue( PROD_ID, Integer.parseInt( aux ) );
 
226
 
 
227
                setChangedField( PROD_ID, hasChanged( xmlData, FIELDS[ PROD_ID ] ) );
 
228
                // nome
 
229
                aux =
 
230
                        XmlInterpreter.getElementValue(
 
231
                                xmlData,
 
232
                                FIELDS[ NOME ] );
 
233
                setValue( NOME, aux );
 
234
 
 
235
                setChangedField( NOME, hasChanged( xmlData, FIELDS[ NOME ] ) );
 
236
                // barcode
 
237
                aux =
 
238
                        XmlInterpreter.getElementValue(
 
239
                                xmlData,
 
240
                                FIELDS[ BARCODE ] );
 
241
                setValue( BARCODE, aux );
 
242
 
 
243
                setChangedField( BARCODE, hasChanged( xmlData, FIELDS[ BARCODE ] ) );
 
244
                // ult_p_custo
 
245
                aux =
 
246
                        XmlInterpreter.getElementValue(
 
247
                                xmlData,
 
248
                                FIELDS[ ULT_P_CUSTO ] );
 
249
                if ( aux.length() == 0 )
 
250
                        aux = "0.0";
 
251
                setValue( ULT_P_CUSTO,
 
252
                        Double.parseDouble(
 
253
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
254
 
 
255
                setChangedField( ULT_P_CUSTO, hasChanged( xmlData, FIELDS[ ULT_P_CUSTO ] ) );
 
256
                // pvenda
 
257
                aux =
 
258
                        XmlInterpreter.getElementValue(
 
259
                                xmlData,
 
260
                                FIELDS[ PVENDA ] );
 
261
                if ( aux.length() == 0 )
 
262
                        aux = "0.0";
 
263
                setValue( PVENDA,
 
264
                        Double.parseDouble(
 
265
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
266
 
 
267
                setChangedField( PVENDA, hasChanged( xmlData, FIELDS[ PVENDA ] ) );
 
268
                // quant
 
269
                aux =
 
270
                        XmlInterpreter.getElementValue(
 
271
                                xmlData,
 
272
                                FIELDS[ QUANT ] );
 
273
                if ( aux.length() == 0 )
 
274
                        aux = "0.0";
 
275
                setValue( QUANT,
 
276
                        Double.parseDouble(
 
277
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
278
 
 
279
                setChangedField( QUANT, hasChanged( xmlData, FIELDS[ QUANT ] ) );
 
280
                // taxa_id
 
281
                aux =
 
282
                        XmlInterpreter.getElementValue(
 
283
                                xmlData,
 
284
                                FIELDS[ TAXA_ID ] );
 
285
                if ( aux.length() == 0 )
 
286
                        aux = "0";
 
287
                setValue( TAXA_ID, Integer.parseInt( aux ) );
 
288
 
 
289
                setChangedField( TAXA_ID, hasChanged( xmlData, FIELDS[ TAXA_ID ] ) );
 
290
                // tipo_prod_id
 
291
                aux =
 
292
                        XmlInterpreter.getElementValue(
 
293
                                xmlData,
 
294
                                FIELDS[ TIPO_PROD_ID ] );
 
295
                if ( aux.length() == 0 )
 
296
                        aux = "0";
 
297
                setValue( TIPO_PROD_ID, Integer.parseInt( aux ) );
 
298
 
 
299
                setChangedField( TIPO_PROD_ID, hasChanged( xmlData, FIELDS[ TIPO_PROD_ID ] ) );
 
300
                // uni_mov_id
 
301
                aux =
 
302
                        XmlInterpreter.getElementValue(
 
303
                                xmlData,
 
304
                                FIELDS[ UNI_MOV_ID ] );
 
305
                if ( aux.length() == 0 )
 
306
                        aux = "0";
 
307
                setValue( UNI_MOV_ID, Integer.parseInt( aux ) );
 
308
 
 
309
                setChangedField( UNI_MOV_ID, hasChanged( xmlData, FIELDS[ UNI_MOV_ID ] ) );
 
310
                // data_ult_p_custo
 
311
                aux =
 
312
                        XmlInterpreter.getElementValue(
 
313
                                xmlData,
 
314
                                FIELDS[ DATA_ULT_P_CUSTO ] );
 
315
                if ( aux.length() > 0 )
 
316
                {
 
317
                        try
 
318
                        {
 
319
                                setValue( DATA_ULT_P_CUSTO, new java.util.Date( df.parse( aux ).getTime() ) );
 
320
 
 
321
                        }
 
322
                        catch( java.text.ParseException pe )
 
323
                        {
 
324
                                DebugFactory.print( "prod_invent.setValue", pe.getMessage() );
 
325
                                pe.printStackTrace();
 
326
                                throw new IllegalArgumentException( pe.getMessage() );
 
327
                        }
 
328
                }
 
329
                setChangedField( DATA_ULT_P_CUSTO, hasChanged( xmlData, FIELDS[ DATA_ULT_P_CUSTO ] ) );
 
330
                // familia_id
 
331
                aux =
 
332
                        XmlInterpreter.getElementValue(
 
333
                                xmlData,
 
334
                                FIELDS[ FAMILIA_ID ] );
 
335
                if ( aux.length() == 0 )
 
336
                        aux = "0";
 
337
                setValue( FAMILIA_ID, Integer.parseInt( aux ) );
 
338
 
 
339
                setChangedField( FAMILIA_ID, hasChanged( xmlData, FIELDS[ FAMILIA_ID ] ) );
 
340
                // sub_familia_id
 
341
                aux =
 
342
                        XmlInterpreter.getElementValue(
 
343
                                xmlData,
 
344
                                FIELDS[ SUB_FAMILIA_ID ] );
 
345
                if ( aux.length() == 0 )
 
346
                        aux = "0";
 
347
                setValue( SUB_FAMILIA_ID, Integer.parseInt( aux ) );
 
348
 
 
349
                setChangedField( SUB_FAMILIA_ID, hasChanged( xmlData, FIELDS[ SUB_FAMILIA_ID ] ) );
 
350
                // img_file
 
351
                aux =
 
352
                        XmlInterpreter.getElementValue(
 
353
                                xmlData,
 
354
                                FIELDS[ IMG_FILE ] );
 
355
                setValue( IMG_FILE, aux );
 
356
 
 
357
                setChangedField( IMG_FILE, hasChanged( xmlData, FIELDS[ IMG_FILE ] ) );
 
358
                // versao
 
359
                aux =
 
360
                        XmlInterpreter.getElementValue(
 
361
                                xmlData,
 
362
                                FIELDS[ VERSAO ] );
 
363
                setValue( VERSAO, aux );
 
364
 
 
365
                setChangedField( VERSAO, hasChanged( xmlData, FIELDS[ VERSAO ] ) );
 
366
                // data_versao
 
367
                aux =
 
368
                        XmlInterpreter.getElementValue(
 
369
                                xmlData,
 
370
                                FIELDS[ DATA_VERSAO ] );
 
371
                if ( aux.length() > 0 )
 
372
                {
 
373
                        try
 
374
                        {
 
375
                                setValue( DATA_VERSAO, new java.util.Date( df.parse( aux ).getTime() ) );
 
376
 
 
377
                        }
 
378
                        catch( java.text.ParseException pe )
 
379
                        {
 
380
                                DebugFactory.print( "prod_invent.setValue", pe.getMessage() );
 
381
                                pe.printStackTrace();
 
382
                                throw new IllegalArgumentException( pe.getMessage() );
 
383
                        }
 
384
                }
 
385
                setChangedField( DATA_VERSAO, hasChanged( xmlData, FIELDS[ DATA_VERSAO ] ) );
 
386
                // obs
 
387
                aux =
 
388
                        XmlInterpreter.getElementValue(
 
389
                                xmlData,
 
390
                                FIELDS[ OBS ] );
 
391
                setValue( OBS, aux );
 
392
 
 
393
                setChangedField( OBS, hasChanged( xmlData, FIELDS[ OBS ] ) );
 
394
                // qt1
 
395
                aux =
 
396
                        XmlInterpreter.getElementValue(
 
397
                                xmlData,
 
398
                                FIELDS[ QT1 ] );
 
399
                if ( aux.length() == 0 )
 
400
                        aux = "0.0";
 
401
                setValue( QT1,
 
402
                        Double.parseDouble(
 
403
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
404
 
 
405
                setChangedField( QT1, hasChanged( xmlData, FIELDS[ QT1 ] ) );
 
406
                // qt2
 
407
                aux =
 
408
                        XmlInterpreter.getElementValue(
 
409
                                xmlData,
 
410
                                FIELDS[ QT2 ] );
 
411
                if ( aux.length() == 0 )
 
412
                        aux = "0.0";
 
413
                setValue( QT2,
 
414
                        Double.parseDouble(
 
415
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
416
 
 
417
                setChangedField( QT2, hasChanged( xmlData, FIELDS[ QT2 ] ) );
 
418
                // qt3
 
419
                aux =
 
420
                        XmlInterpreter.getElementValue(
 
421
                                xmlData,
 
422
                                FIELDS[ QT3 ] );
 
423
                if ( aux.length() == 0 )
 
424
                        aux = "0.0";
 
425
                setValue( QT3,
 
426
                        Double.parseDouble(
 
427
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
428
 
 
429
                setChangedField( QT3, hasChanged( xmlData, FIELDS[ QT3 ] ) );
 
430
                // qt4
 
431
                aux =
 
432
                        XmlInterpreter.getElementValue(
 
433
                                xmlData,
 
434
                                FIELDS[ QT4 ] );
 
435
                if ( aux.length() == 0 )
 
436
                        aux = "0.0";
 
437
                setValue( QT4,
 
438
                        Double.parseDouble(
 
439
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
440
 
 
441
                setChangedField( QT4, hasChanged( xmlData, FIELDS[ QT4 ] ) );
 
442
                // qt5
 
443
                aux =
 
444
                        XmlInterpreter.getElementValue(
 
445
                                xmlData,
 
446
                                FIELDS[ QT5 ] );
 
447
                if ( aux.length() == 0 )
 
448
                        aux = "0.0";
 
449
                setValue( QT5,
 
450
                        Double.parseDouble(
 
451
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
452
 
 
453
                setChangedField( QT5, hasChanged( xmlData, FIELDS[ QT5 ] ) );
 
454
                // qt6
 
455
                aux =
 
456
                        XmlInterpreter.getElementValue(
 
457
                                xmlData,
 
458
                                FIELDS[ QT6 ] );
 
459
                if ( aux.length() == 0 )
 
460
                        aux = "0.0";
 
461
                setValue( QT6,
 
462
                        Double.parseDouble(
 
463
                                DataFactory.fixNumberSeparator( aux, null ) ) );
 
464
 
 
465
                setChangedField( QT6, hasChanged( xmlData, FIELDS[ QT6 ] ) );
 
466
        }
 
467
 
 
468
        ////////////////////////////////////////////////////////////
 
469
        // Get/Set methods: BEGIN
 
470
        ////////////////////////////////////////////////////////////
 
471
 
 
472
        ////////////////////////////////////////////////////////////
 
473
        public int getProdId()
 
474
        {
 
475
                return getProdId( getTuple() );
 
476
        }
 
477
 
 
478
        ////////////////////////////////////////////////////////////
 
479
        public static int getProdId( Object[] tuple )
 
480
        {
 
481
                int value = toInt( tuple, PROD_ID );
 
482
                return value;
 
483
        }
 
484
 
 
485
        ////////////////////////////////////////////////////////////
 
486
        public void setProdId( int value )
 
487
        {
 
488
                setProdId( getTuple(), value );
 
489
        }
 
490
 
 
491
        ////////////////////////////////////////////////////////////
 
492
        public static void setProdId( Object[] tuple, int value )
 
493
        {
 
494
                setValue( tuple, PROD_ID, value );
 
495
        }
 
496
 
 
497
        ////////////////////////////////////////////////////////////
 
498
        public String getNome()
 
499
        {
 
500
                return getNome( getTuple() );
 
501
        }
 
502
 
 
503
        ////////////////////////////////////////////////////////////
 
504
        public static String getNome( Object[] tuple )
 
505
        {
 
506
                String value = toString( tuple, NOME );
 
507
                return value;
 
508
        }
 
509
 
 
510
        ////////////////////////////////////////////////////////////
 
511
        public void setNome( String value )
 
512
        {
 
513
                setNome( getTuple(), value );
 
514
        }
 
515
 
 
516
        ////////////////////////////////////////////////////////////
 
517
        public static void setNome( Object[] tuple, String value )
 
518
        {
 
519
                setValue( tuple, NOME, value );
 
520
        }
 
521
 
 
522
        ////////////////////////////////////////////////////////////
 
523
        public String getBarcode()
 
524
        {
 
525
                return getBarcode( getTuple() );
 
526
        }
 
527
 
 
528
        ////////////////////////////////////////////////////////////
 
529
        public static String getBarcode( Object[] tuple )
 
530
        {
 
531
                String value = toString( tuple, BARCODE );
 
532
                return value;
 
533
        }
 
534
 
 
535
        ////////////////////////////////////////////////////////////
 
536
        public void setBarcode( String value )
 
537
        {
 
538
                setBarcode( getTuple(), value );
 
539
        }
 
540
 
 
541
        ////////////////////////////////////////////////////////////
 
542
        public static void setBarcode( Object[] tuple, String value )
 
543
        {
 
544
                setValue( tuple, BARCODE, value );
 
545
        }
 
546
 
 
547
        ////////////////////////////////////////////////////////////
 
548
        public double getUltPCusto()
 
549
        {
 
550
                return getUltPCusto( getTuple() );
 
551
        }
 
552
 
 
553
        ////////////////////////////////////////////////////////////
 
554
        public static double getUltPCusto( Object[] tuple )
 
555
        {
 
556
                double value = toDouble( tuple, ULT_P_CUSTO );
 
557
                return value;
 
558
        }
 
559
 
 
560
        ////////////////////////////////////////////////////////////
 
561
        public void setUltPCusto( double value )
 
562
        {
 
563
                setUltPCusto( getTuple(), value );
 
564
        }
 
565
 
 
566
        ////////////////////////////////////////////////////////////
 
567
        public static void setUltPCusto( Object[] tuple, double value )
 
568
        {
 
569
                setValue( tuple, ULT_P_CUSTO, value );
 
570
        }
 
571
 
 
572
        ////////////////////////////////////////////////////////////
 
573
        public double getPvenda()
 
574
        {
 
575
                return getPvenda( getTuple() );
 
576
        }
 
577
 
 
578
        ////////////////////////////////////////////////////////////
 
579
        public static double getPvenda( Object[] tuple )
 
580
        {
 
581
                double value = toDouble( tuple, PVENDA );
 
582
                return value;
 
583
        }
 
584
 
 
585
        ////////////////////////////////////////////////////////////
 
586
        public void setPvenda( double value )
 
587
        {
 
588
                setPvenda( getTuple(), value );
 
589
        }
 
590
 
 
591
        ////////////////////////////////////////////////////////////
 
592
        public static void setPvenda( Object[] tuple, double value )
 
593
        {
 
594
                setValue( tuple, PVENDA, value );
 
595
        }
 
596
 
 
597
        ////////////////////////////////////////////////////////////
 
598
        public double getQuant()
 
599
        {
 
600
                return getQuant( getTuple() );
 
601
        }
 
602
 
 
603
        ////////////////////////////////////////////////////////////
 
604
        public static double getQuant( Object[] tuple )
 
605
        {
 
606
                double value = toDouble( tuple, QUANT );
 
607
                return value;
 
608
        }
 
609
 
 
610
        ////////////////////////////////////////////////////////////
 
611
        public void setQuant( double value )
 
612
        {
 
613
                setQuant( getTuple(), value );
 
614
        }
 
615
 
 
616
        ////////////////////////////////////////////////////////////
 
617
        public static void setQuant( Object[] tuple, double value )
 
618
        {
 
619
                setValue( tuple, QUANT, value );
 
620
        }
 
621
 
 
622
        ////////////////////////////////////////////////////////////
 
623
        public int getTaxaId()
 
624
        {
 
625
                return getTaxaId( getTuple() );
 
626
        }
 
627
 
 
628
        ////////////////////////////////////////////////////////////
 
629
        public static int getTaxaId( Object[] tuple )
 
630
        {
 
631
                int value = toInt( tuple, TAXA_ID );
 
632
                return value;
 
633
        }
 
634
 
 
635
        ////////////////////////////////////////////////////////////
 
636
        public void setTaxaId( int value )
 
637
        {
 
638
                setTaxaId( getTuple(), value );
 
639
        }
 
640
 
 
641
        ////////////////////////////////////////////////////////////
 
642
        public static void setTaxaId( Object[] tuple, int value )
 
643
        {
 
644
                setValue( tuple, TAXA_ID, value );
 
645
        }
 
646
 
 
647
        ////////////////////////////////////////////////////////////
 
648
        public int getTipoProdId()
 
649
        {
 
650
                return getTipoProdId( getTuple() );
 
651
        }
 
652
 
 
653
        ////////////////////////////////////////////////////////////
 
654
        public static int getTipoProdId( Object[] tuple )
 
655
        {
 
656
                int value = toInt( tuple, TIPO_PROD_ID );
 
657
                return value;
 
658
        }
 
659
 
 
660
        ////////////////////////////////////////////////////////////
 
661
        public void setTipoProdId( int value )
 
662
        {
 
663
                setTipoProdId( getTuple(), value );
 
664
        }
 
665
 
 
666
        ////////////////////////////////////////////////////////////
 
667
        public static void setTipoProdId( Object[] tuple, int value )
 
668
        {
 
669
                setValue( tuple, TIPO_PROD_ID, value );
 
670
        }
 
671
 
 
672
        ////////////////////////////////////////////////////////////
 
673
        public int getUniMovId()
 
674
        {
 
675
                return getUniMovId( getTuple() );
 
676
        }
 
677
 
 
678
        ////////////////////////////////////////////////////////////
 
679
        public static int getUniMovId( Object[] tuple )
 
680
        {
 
681
                int value = toInt( tuple, UNI_MOV_ID );
 
682
                return value;
 
683
        }
 
684
 
 
685
        ////////////////////////////////////////////////////////////
 
686
        public void setUniMovId( int value )
 
687
        {
 
688
                setUniMovId( getTuple(), value );
 
689
        }
 
690
 
 
691
        ////////////////////////////////////////////////////////////
 
692
        public static void setUniMovId( Object[] tuple, int value )
 
693
        {
 
694
                setValue( tuple, UNI_MOV_ID, value );
 
695
        }
 
696
 
 
697
        ////////////////////////////////////////////////////////////
 
698
        public java.util.Date getDataUltPCusto()
 
699
        {
 
700
                return getDataUltPCusto( getTuple() );
 
701
        }
 
702
 
 
703
        ////////////////////////////////////////////////////////////
 
704
        public static java.util.Date getDataUltPCusto( Object[] tuple )
 
705
        {
 
706
                java.util.Date value = toDate( tuple, DATA_ULT_P_CUSTO );
 
707
                return value;
 
708
        }
 
709
 
 
710
        ////////////////////////////////////////////////////////////
 
711
        public void setDataUltPCusto( java.util.Date value )
 
712
        {
 
713
                setDataUltPCusto( getTuple(), value );
 
714
        }
 
715
 
 
716
        ////////////////////////////////////////////////////////////
 
717
        public static void setDataUltPCusto( Object[] tuple, java.util.Date value )
 
718
        {
 
719
                setValue( tuple, DATA_ULT_P_CUSTO, value );
 
720
        }
 
721
 
 
722
        ////////////////////////////////////////////////////////////
 
723
        public int getFamiliaId()
 
724
        {
 
725
                return getFamiliaId( getTuple() );
 
726
        }
 
727
 
 
728
        ////////////////////////////////////////////////////////////
 
729
        public static int getFamiliaId( Object[] tuple )
 
730
        {
 
731
                int value = toInt( tuple, FAMILIA_ID );
 
732
                return value;
 
733
        }
 
734
 
 
735
        ////////////////////////////////////////////////////////////
 
736
        public void setFamiliaId( int value )
 
737
        {
 
738
                setFamiliaId( getTuple(), value );
 
739
        }
 
740
 
 
741
        ////////////////////////////////////////////////////////////
 
742
        public static void setFamiliaId( Object[] tuple, int value )
 
743
        {
 
744
                setValue( tuple, FAMILIA_ID, value );
 
745
        }
 
746
 
 
747
        ////////////////////////////////////////////////////////////
 
748
        public int getSubFamiliaId()
 
749
        {
 
750
                return getSubFamiliaId( getTuple() );
 
751
        }
 
752
 
 
753
        ////////////////////////////////////////////////////////////
 
754
        public static int getSubFamiliaId( Object[] tuple )
 
755
        {
 
756
                int value = toInt( tuple, SUB_FAMILIA_ID );
 
757
                return value;
 
758
        }
 
759
 
 
760
        ////////////////////////////////////////////////////////////
 
761
        public void setSubFamiliaId( int value )
 
762
        {
 
763
                setSubFamiliaId( getTuple(), value );
 
764
        }
 
765
 
 
766
        ////////////////////////////////////////////////////////////
 
767
        public static void setSubFamiliaId( Object[] tuple, int value )
 
768
        {
 
769
                setValue( tuple, SUB_FAMILIA_ID, value );
 
770
        }
 
771
 
 
772
        ////////////////////////////////////////////////////////////
 
773
        public String getImgFile()
 
774
        {
 
775
                return getImgFile( getTuple() );
 
776
        }
 
777
 
 
778
        ////////////////////////////////////////////////////////////
 
779
        public static String getImgFile( Object[] tuple )
 
780
        {
 
781
                String value = toString( tuple, IMG_FILE );
 
782
                return value;
 
783
        }
 
784
 
 
785
        ////////////////////////////////////////////////////////////
 
786
        public void setImgFile( String value )
 
787
        {
 
788
                setImgFile( getTuple(), value );
 
789
        }
 
790
 
 
791
        ////////////////////////////////////////////////////////////
 
792
        public static void setImgFile( Object[] tuple, String value )
 
793
        {
 
794
                setValue( tuple, IMG_FILE, value );
 
795
        }
 
796
 
 
797
        ////////////////////////////////////////////////////////////
 
798
        public String getVersao()
 
799
        {
 
800
                return getVersao( getTuple() );
 
801
        }
 
802
 
 
803
        ////////////////////////////////////////////////////////////
 
804
        public static String getVersao( Object[] tuple )
 
805
        {
 
806
                String value = toString( tuple, VERSAO );
 
807
                return value;
 
808
        }
 
809
 
 
810
        ////////////////////////////////////////////////////////////
 
811
        public void setVersao( String value )
 
812
        {
 
813
                setVersao( getTuple(), value );
 
814
        }
 
815
 
 
816
        ////////////////////////////////////////////////////////////
 
817
        public static void setVersao( Object[] tuple, String value )
 
818
        {
 
819
                setValue( tuple, VERSAO, value );
 
820
        }
 
821
 
 
822
        ////////////////////////////////////////////////////////////
 
823
        public java.util.Date getDataVersao()
 
824
        {
 
825
                return getDataVersao( getTuple() );
 
826
        }
 
827
 
 
828
        ////////////////////////////////////////////////////////////
 
829
        public static java.util.Date getDataVersao( Object[] tuple )
 
830
        {
 
831
                java.util.Date value = toDate( tuple, DATA_VERSAO );
 
832
                return value;
 
833
        }
 
834
 
 
835
        ////////////////////////////////////////////////////////////
 
836
        public void setDataVersao( java.util.Date value )
 
837
        {
 
838
                setDataVersao( getTuple(), value );
 
839
        }
 
840
 
 
841
        ////////////////////////////////////////////////////////////
 
842
        public static void setDataVersao( Object[] tuple, java.util.Date value )
 
843
        {
 
844
                setValue( tuple, DATA_VERSAO, value );
 
845
        }
 
846
 
 
847
        ////////////////////////////////////////////////////////////
 
848
        public String getObs()
 
849
        {
 
850
                return getObs( getTuple() );
 
851
        }
 
852
 
 
853
        ////////////////////////////////////////////////////////////
 
854
        public static String getObs( Object[] tuple )
 
855
        {
 
856
                String value = toString( tuple, OBS );
 
857
                return value;
 
858
        }
 
859
 
 
860
        ////////////////////////////////////////////////////////////
 
861
        public void setObs( String value )
 
862
        {
 
863
                setObs( getTuple(), value );
 
864
        }
 
865
 
 
866
        ////////////////////////////////////////////////////////////
 
867
        public static void setObs( Object[] tuple, String value )
 
868
        {
 
869
                setValue( tuple, OBS, value );
 
870
        }
 
871
 
 
872
        ////////////////////////////////////////////////////////////
 
873
        public double getQt1()
 
874
        {
 
875
                return getQt1( getTuple() );
 
876
        }
 
877
 
 
878
        ////////////////////////////////////////////////////////////
 
879
        public static double getQt1( Object[] tuple )
 
880
        {
 
881
                double value = toDouble( tuple, QT1 );
 
882
                return value;
 
883
        }
 
884
 
 
885
        ////////////////////////////////////////////////////////////
 
886
        public void setQt1( double value )
 
887
        {
 
888
                setQt1( getTuple(), value );
 
889
        }
 
890
 
 
891
        ////////////////////////////////////////////////////////////
 
892
        public static void setQt1( Object[] tuple, double value )
 
893
        {
 
894
                setValue( tuple, QT1, value );
 
895
        }
 
896
 
 
897
        ////////////////////////////////////////////////////////////
 
898
        public double getQt2()
 
899
        {
 
900
                return getQt2( getTuple() );
 
901
        }
 
902
 
 
903
        ////////////////////////////////////////////////////////////
 
904
        public static double getQt2( Object[] tuple )
 
905
        {
 
906
                double value = toDouble( tuple, QT2 );
 
907
                return value;
 
908
        }
 
909
 
 
910
        ////////////////////////////////////////////////////////////
 
911
        public void setQt2( double value )
 
912
        {
 
913
                setQt2( getTuple(), value );
 
914
        }
 
915
 
 
916
        ////////////////////////////////////////////////////////////
 
917
        public static void setQt2( Object[] tuple, double value )
 
918
        {
 
919
                setValue( tuple, QT2, value );
 
920
        }
 
921
 
 
922
        ////////////////////////////////////////////////////////////
 
923
        public double getQt3()
 
924
        {
 
925
                return getQt3( getTuple() );
 
926
        }
 
927
 
 
928
        ////////////////////////////////////////////////////////////
 
929
        public static double getQt3( Object[] tuple )
 
930
        {
 
931
                double value = toDouble( tuple, QT3 );
 
932
                return value;
 
933
        }
 
934
 
 
935
        ////////////////////////////////////////////////////////////
 
936
        public void setQt3( double value )
 
937
        {
 
938
                setQt3( getTuple(), value );
 
939
        }
 
940
 
 
941
        ////////////////////////////////////////////////////////////
 
942
        public static void setQt3( Object[] tuple, double value )
 
943
        {
 
944
                setValue( tuple, QT3, value );
 
945
        }
 
946
 
 
947
        ////////////////////////////////////////////////////////////
 
948
        public double getQt4()
 
949
        {
 
950
                return getQt4( getTuple() );
 
951
        }
 
952
 
 
953
        ////////////////////////////////////////////////////////////
 
954
        public static double getQt4( Object[] tuple )
 
955
        {
 
956
                double value = toDouble( tuple, QT4 );
 
957
                return value;
 
958
        }
 
959
 
 
960
        ////////////////////////////////////////////////////////////
 
961
        public void setQt4( double value )
 
962
        {
 
963
                setQt4( getTuple(), value );
 
964
        }
 
965
 
 
966
        ////////////////////////////////////////////////////////////
 
967
        public static void setQt4( Object[] tuple, double value )
 
968
        {
 
969
                setValue( tuple, QT4, value );
 
970
        }
 
971
 
 
972
        ////////////////////////////////////////////////////////////
 
973
        public double getQt5()
 
974
        {
 
975
                return getQt5( getTuple() );
 
976
        }
 
977
 
 
978
        ////////////////////////////////////////////////////////////
 
979
        public static double getQt5( Object[] tuple )
 
980
        {
 
981
                double value = toDouble( tuple, QT5 );
 
982
                return value;
 
983
        }
 
984
 
 
985
        ////////////////////////////////////////////////////////////
 
986
        public void setQt5( double value )
 
987
        {
 
988
                setQt5( getTuple(), value );
 
989
        }
 
990
 
 
991
        ////////////////////////////////////////////////////////////
 
992
        public static void setQt5( Object[] tuple, double value )
 
993
        {
 
994
                setValue( tuple, QT5, value );
 
995
        }
 
996
 
 
997
        ////////////////////////////////////////////////////////////
 
998
        public double getQt6()
 
999
        {
 
1000
                return getQt6( getTuple() );
 
1001
        }
 
1002
 
 
1003
        ////////////////////////////////////////////////////////////
 
1004
        public static double getQt6( Object[] tuple )
 
1005
        {
 
1006
                double value = toDouble( tuple, QT6 );
 
1007
                return value;
 
1008
        }
 
1009
 
 
1010
        ////////////////////////////////////////////////////////////
 
1011
        public void setQt6( double value )
 
1012
        {
 
1013
                setQt6( getTuple(), value );
 
1014
        }
 
1015
 
 
1016
        ////////////////////////////////////////////////////////////
 
1017
        public static void setQt6( Object[] tuple, double value )
 
1018
        {
 
1019
                setValue( tuple, QT6, value );
 
1020
        }
 
1021
 
 
1022
        ////////////////////////////////////////////////////////////
 
1023
        // Get/Set methods: END
 
1024
        ////////////////////////////////////////////////////////////
 
1025
 
 
1026
 
 
1027
}