[Idrs-commit] CVS: Idrs/dev/src/net/sourceforge/idrs/deploy/compile/units Fields.java,NONE,1.1 Tag.j
Brought to you by:
bigman921
|
From: Marc B. <big...@us...> - 2004-08-29 04:50:40
|
Update of /cvsroot/idrs/Idrs/dev/src/net/sourceforge/idrs/deploy/compile/units In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv11199/src/net/sourceforge/idrs/deploy/compile/units Modified Files: Tag.java Attribute.java Body.java Added Files: Fields.java Log Message: * Removed "proprietary" xml binding * Added support for JAXB * Added "fields" tag, so that if the fields are not known ahead of time, they may be iterated over * updated some copyrights --- NEW FILE: Fields.java --- /* Fields.java Copyright (C) 2002 Marc Boorshtein The contents of this file are subject to the Mozilla Public License Version 1.0 (the License); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.mozilla.org/MPL/ Software distributed under the License is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License. */ package net.sourceforge.idrs.deploy.compile.units; import java.util.Vector; import net.sourceforge.idrs.core.report.FieldsLine; import net.sourceforge.idrs.core.report.TagLine; import net.sourceforge.idrs.deploy.compile.CompilerState; import org.xml.sax.Attributes; /** * @author mlb * * TODO To change the template for this generated type comment go to * Window - Preferences - Java - Code Style - Code Templates */ public class Fields extends Body { String name; FieldsLine fieldsLine; /** *allows for a compiler to use the attributes of the calling tag */ public void setAttributes(Attributes atts) throws Exception { this.atts = atts; name = atts.getValue("db"); this.fieldsLine = new FieldsLine(name); } /** *allows for the compiler to work with the current state of the page compilation */ public void setState(CompilerState state) throws Exception { this.state = state; state.sealLine(); state.pushLines(); //state.addRepeatLine(id,color1,color2); } /** * allows for the execution of any wrap-up code at the hitting of the end tag */ public void seal() throws Exception { //if (state.getCurrentLine() != null) state.sealLine(); Vector lines = state.popLines(); //System.out.println("num lines repeat : " + lines.size()); fieldsLine.setLines(lines); state.setLine(fieldsLine); state.sealLine(); } } Index: Tag.java =================================================================== RCS file: /cvsroot/idrs/Idrs/dev/src/net/sourceforge/idrs/deploy/compile/units/Tag.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Tag.java 22 Aug 2004 23:52:31 -0000 1.1 --- Tag.java 29 Aug 2004 04:50:29 -0000 1.2 *************** *** 1,8 **** /* ! * Created on Aug 22, 2004 ! * ! * TODO To change the template for this generated file go to ! * Window - Preferences - Java - Code Style - Code Templates ! */ package net.sourceforge.idrs.deploy.compile.units; --- 1,14 ---- /* ! Tag.java ! Copyright (C) 2002 Marc Boorshtein ! ! The contents of this file are subject to the Mozilla Public License Version 1.0 (the License); ! you may not use this file except in compliance with the License. You may obtain a copy of the ! License at http://www.mozilla.org/MPL/ ! ! Software distributed under the License is distributed on an "AS IS" basis, ! WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific ! language governing rights and limitations under the License. ! */ package net.sourceforge.idrs.deploy.compile.units; Index: Attribute.java =================================================================== RCS file: /cvsroot/idrs/Idrs/dev/src/net/sourceforge/idrs/deploy/compile/units/Attribute.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Attribute.java 22 Aug 2004 23:52:31 -0000 1.1 --- Attribute.java 29 Aug 2004 04:50:30 -0000 1.2 *************** *** 1,8 **** /* ! * Created on Aug 22, 2004 ! * ! * TODO To change the template for this generated file go to ! * Window - Preferences - Java - Code Style - Code Templates ! */ package net.sourceforge.idrs.deploy.compile.units; --- 1,14 ---- /* ! Attribute.java ! Copyright (C) 2002 Marc Boorshtein ! ! The contents of this file are subject to the Mozilla Public License Version 1.0 (the License); ! you may not use this file except in compliance with the License. You may obtain a copy of the ! License at http://www.mozilla.org/MPL/ ! ! Software distributed under the License is distributed on an "AS IS" basis, ! WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific ! language governing rights and limitations under the License. ! */ package net.sourceforge.idrs.deploy.compile.units; Index: Body.java =================================================================== RCS file: /cvsroot/idrs/Idrs/dev/src/net/sourceforge/idrs/deploy/compile/units/Body.java,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** Body.java 19 Apr 2003 03:13:48 -0000 1.12 --- Body.java 29 Aug 2004 04:50:30 -0000 1.13 *************** *** 79,82 **** --- 79,87 ---- } + public void currentField(String val,Attributes atts) throws Exception { + CurrentField cf = new CurrentField(val); + state.getCurrentLine().addChunk(cf); + } + public void field(String val, Attributes atts) throws Exception { |