All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.viaoa.html.OAForm Maven / Gradle / Ivy

/* 
This software and documentation is the confidential and proprietary 
information of ViaOA, Inc. ("Confidential Information").  
You shall not disclose such Confidential Information and shall use 
it only in accordance with the terms of the license agreement you 
entered into with ViaOA, Inc..

ViaOA, Inc. MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
PURPOSE, OR NON-INFRINGEMENT. ViaOA, Inc. SHALL NOT BE LIABLE FOR ANY DAMAGES
SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR DISTRIBUTING
THIS SOFTWARE OR ITS DERIVATIVES.
 
Copyright (c) 2001 ViaOA, Inc.
All rights reserved.
*/ 
package com.viaoa.html;

//   response.setHeader("refresh", "1200;URL=Login.jsp");


import java.awt.*;
import java.io.*;
import java.util.*;
import javax.servlet.*;
import com.viaoa.object.*;
import com.viaoa.hub.*;
import com.viaoa.util.OAFile;
/*
    processing commands: 
        1: create an OAHtmlAdapter that implements the processCommand() method
        2: form.put("NAME", adapter)
        3: use a submit image with the name="oacommand_nameLength_NAME:[ID]" on html page
        4: the form will call your processCommand(form, command)
        5: your processCommand can return an url to go to or null to keep same
*/
/** Container that represents a HTML Form and holds OAHtmlComponents.
    [Java Code]
    OAForm form = new OAForm(oaFormId);
    form.setName("Expert Edit");
    ... add OAHtmlComponents ...
    ....
    [HTML Code]
    <form method="post" action="<%=form.getAction()%>">

    This will set the scrolling postion 
    <BODY <%=form.getJavaScriptOnLoad()%>>
*/ public class OAForm extends OABase implements Serializable { private static final long serialVersionUID = 1L; protected Hashtable hashComponent = new Hashtable(13,0.75f); protected Vector vecComponent = new Vector(5,5); protected String url; // jsp name String status,name; boolean bFormEnded = true; // name of last command or subCommand processed. // This does not include the command prefix "oacommand_NAME_" protected String lastCommand; protected transient OAObject lastObject; // last object used. Set by OACommand.processCommand() protected transient OASession session; protected transient OAFrame frame; // set by oasession protected String forwardUrl; // set during processRequest() protected boolean bNeedsRefreshed; protected int scrollx, scrolly; protected boolean readOnly; protected int top; // y scroll position protected boolean autoScroll=true, bScroll; protected String frameName; // set by processRequest, the name of the frame that sent request protected String targetName; // set by processRequest, the name of the request target /** @param url name of jsp that this form is used on; must be unique within session ex: "education.jsp" */ public OAForm(String url) { this.url = url; if (url == null || url.length() == 0) throw new IllegalArgumentException("OAForm url required"); if (url.indexOf('-') >= 0) throw new IllegalArgumentException("OAForm url can not have any '-' characters"); } public String getUrl() { return url; } public int getTop() { return top; } public void setTop(int y) { top = y; } /** calls OAFrame.getPreviousUrl() to get the return url. If this form is not yet in a frame, then return will be null. @see OAFrame#getPreviousUrl */ public String getReturnUrl() { if (frame == null) return null; return frame.getPreviousUrl(); } /** calls OAFrame.setUrlToPrevious(url). @see OAFrame#setUrlToPrevious */ public void setReturnUrl(String url) { if (frame != null) frame.setUrlToPrevious(url); } /** scroll position of upper left corner of window. */ public Point getScrollPosition() { return new Point(scrollx, scrolly); } public void setScrollPosition(Point p) { if (p != null) { scrollx = p.x; scrolly = p.y; } } /** return the frame that this form is currently under. */ public OAFrame getFrame() { return frame; } /** if true then components will not receive data from submit. Note: commands and listeners are not affected. */ public boolean getReadOnly() { return readOnly; } public void setReadOnly(boolean b) { this.readOnly = b; } /** if true then top of form will automatically be scrolled. Default is false. @see OAForm#getJavaScriptOnLoad @see OAForm#getTop */ public boolean getAutoScroll() { return autoScroll; } public void setAutoScroll(boolean b) { this.autoScroll = b; } /** flag to know if the getEndHtml() has been called. This can be used by a "footer", so that it can include a "return" img button */ public boolean hasFormEnded() { return bFormEnded; } /** set by OAForm.processRequest() and OACommand.processCommand() to store the last command name or subCommand name processed. This does not include the command prefix "oacommand_NAME_". This is only needed by OAForm so that it will know that it is a command to process */ public String getLastCommand() { return lastCommand; } public void setLastCommand(String s) { lastCommand = s; } /** set by OACommad.processCommand() */ public OAObject getLastObject() { return lastObject; } public void setLastObject(OAObject obj) { lastObject = obj; } /** automatically turned on when a component is added, and set to false when getAction() is called */ public void setNeedsRefreshed(boolean b) { bNeedsRefreshed = b; } public boolean needsRefreshed() { if (bNeedsRefreshed) return true; // see if any component needs refreshed Enumeration enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); if (oh.needsRefreshed()) return true; } return false; } public String getName() { return name; } public void setName(String s) { this.name = s; } /** resets the form, takes off any edits not saved */ public void reset() { Enumeration enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); oh.reset(); } } /** finds out if any of the values have changed */ public boolean isChanged() { Enumeration enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); if (oh.isChanged()) return true; } return false; } /** finds out the name of components that have changed */ public String[] getChanges() { Vector v = new Vector(); Enumeration enumx = hashComponent.keys(); for ( ; enumx.hasMoreElements(); ) { String s = ((String) enumx.nextElement()); OAHtmlComponent oc = (OAHtmlComponent)hashComponent.get(s.toUpperCase()); if ( oc.isChanged()) { v.addElement(s); } } String[] ss = new String[v.size()]; v.copyInto(ss); return ss; } public OAHtmlComponent[] getComponents() { OAHtmlComponent[] comps = new OAHtmlComponent[hashComponent.size()]; Enumeration enumx = hashComponent.elements(); for (int i=0; enumx.hasMoreElements(); i++) { comps[i] = (OAHtmlComponent) enumx.nextElement(); } return comps; } /** updates the objects bound to the form */ public void update() { Enumeration enumx = hashComponent.keys(); for ( ; enumx.hasMoreElements(); ) { String name = (String) enumx.nextElement(); OAHtmlComponent oh = (OAHtmlComponent) hashComponent.get(name.toUpperCase()); oh.update(); /**** try { oh.update(); } catch (Exception e) { OAException oae = new OAException(OAForm.class, "OAForm.update() component="+name+" "+e.getMessage()); } **/ } } /** returns null if not found @param name is not case sensitive */ public OAHtmlComponent getComponent(String name) { if (name == null) return null; return (OAHtmlComponent) hashComponent.get(name.toUpperCase()); } /** stores component by name. @param name is not case sensitive */ public void put(String name, OAHtmlComponent obj) { if (obj == null) return; if (name == null || name.length() == 0) throw new IllegalArgumentException("OAForm.add() name required"); if (hashComponent.get(name.toUpperCase()) != null) { String s = "OAForm.add() \""+name+"\" already exists on form - it will be overwritten"; System.out.println(s); this.addError(s); } hashComponent.put(name.toUpperCase(), obj); obj.form = this; obj.name = name; bNeedsRefreshed = true; vecComponent.addElement(obj); } /** stores component by name. @param name is not case sensitive @see OAForm#put */ public void add(String name, OAHtmlComponent obj) { put(name, obj); } /** @param name is not case sensitive */ public OARelationshipGrid getRelationshipGrid(String name) { Object obj = getComponent(name); if (obj instanceof OARelationshipGrid) return (OARelationshipGrid) obj; throw new RuntimeException("OAForm.getRelationshipGrid() \""+name+"\" not found"); } /** @param name is not case sensitive */ public OARadio getRadio(String name) { Object obj = getComponent(name); if (obj instanceof OARadio) return (OARadio) obj; throw new RuntimeException("OAForm.getRadio() Radio \""+name+"\" not found"); } /** @param name is not case sensitive */ public OACheckBox getCheckBox(String name) { Object obj = getComponent(name); if (obj instanceof OACheckBox) return (OACheckBox) obj; throw new RuntimeException("OAForm.getCheckBox() CheckBox \""+name+"\" not found"); } /** @param name is not case sensitive */ public OAComboBox getComboBox(String name) { Object obj = getComponent(name); if (obj instanceof OAComboBox) return (OAComboBox) obj; throw new RuntimeException("OAForm.getComboBox() ComboBox \""+name+"\" not found"); } /** @param name is not case sensitive */ public OAList getList(String name) { Object obj = getComponent(name); if (obj instanceof OAList) return (OAList) obj; throw new RuntimeException("OAForm.getList() List \""+name+"\" not found"); } /** @param name is not case sensitive */ public OATextArea getTextArea(String name) { Object obj = getComponent(name); if (obj instanceof OATextArea) return (OATextArea) obj; throw new RuntimeException("OAForm.getTextArea() TextArea \""+name+"\" not found"); } /** @param name is not case sensitive */ public OATree getTree(String name) { Object obj = getComponent(name); if (obj instanceof OATree) return (OATree) obj; throw new RuntimeException("OAForm.getTree() Tree \""+name+"\" not found"); } /** @param name is not case sensitive */ public OATextField getTextField(String name) { Object obj = getComponent(name); if (obj instanceof OATextField) return (OATextField) obj; throw new RuntimeException("OAForm.getTextField() TextField \""+name+"\" not found"); } /** @param name is not case sensitive */ public OAPasswordField getPasswordField(String name) { Object obj = getComponent(name); if (obj instanceof OAPasswordField) return (OAPasswordField) obj; throw new RuntimeException("OAForm.getPasswordField() PasswordField \""+name+"\" not found"); } /** @param name is not case sensitive */ public OATable getTable(String name) { Object obj = getComponent(name); if (obj instanceof OATable) return (OATable) obj; throw new RuntimeException("OAForm.getTable() Table \""+name+"\" not found"); } public OADataTable getDataTable(String name) { Object obj = getComponent(name); if (obj instanceof OADataTable) return (OADataTable) obj; throw new RuntimeException("OAForm.getDataTable() DataTable \""+name+"\" not found"); } /** @param name is not case sensitive */ public OACommand getCommand(String name) { Object obj = getComponent(name); if (obj instanceof OACommand) return (OACommand) obj; throw new RuntimeException("OAForm.getCommand() Command \""+name+"\" not found"); } /** @param name is not case sensitive */ public OATabbedPane getTabbedPane(String name) { Object obj = getComponent(name); if (obj instanceof OATabbedPane) return (OATabbedPane) obj; throw new RuntimeException("OAForm.getTabbedPane() \""+name+"\" not found"); } /** @param name is not case sensitive */ public OAImage getImage(String name) { Object obj = getComponent(name); if (obj instanceof OAImage) return (OAImage) obj; throw new RuntimeException("OAForm.getImage() name \""+name+"\" not found"); } /** @param name is not case sensitive */ public OAFileInput getFileInput(String name) { Object obj = getComponent(name); if (obj instanceof OAFileInput) return (OAFileInput) obj; throw new RuntimeException("OAForm.getFileInput() \""+name+"\" not found"); } /** @param name is not case sensitive */ public OALink getLink(String name) { Object obj = getComponent(name); if (obj instanceof OALink) return (OALink) obj; throw new RuntimeException("OAForm.getLink() Link \""+name+"\" not found"); } /** @param name is not case sensitive */ public OAToggleButton getToggleButton(String name) { Object obj = getComponent(name); if (obj instanceof OAToggleButton) return (OAToggleButton) obj; throw new RuntimeException("OAForm.getToggleButton() ToggleButton \""+name+"\" not found"); } /** @param name is not case sensitive */ public OAButtonGroup getButtonGroup(String name) { Object obj = getComponent(name); if (obj instanceof OAButtonGroup) return (OAButtonGroup) obj; throw new RuntimeException("OAForm.getButtonGroup() ButtonGroup \""+name+"\" not found"); } /** @param name is not case sensitive */ public OALabel getLabel(String name) { Object obj = getComponent(name); if (obj instanceof OALabel) return (OALabel) obj; throw new RuntimeException("OAForm.getLabel() Label \""+name+"\" not found"); } /** tag to use inside of BODY tag to set the pages top scroll position. */ public String getJavaScriptOnLoad() { if (top != 0) { Enumeration enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); if (oh.resetTop()) { top = 0; break; } } } bScroll = true; if (top != 0) return "onLoad=\"window.scrollTo(0,"+top+");\""; return ""; } /** used for supplying needed HTML within a form tag. This will also set "enctype="multipart/form-data"" if the form has any OAFileInput components on it. Calls all components on the form "getInitScript()" to get any initialization javascript. Note: this will set OASession.setCurrentForm(this) ex: <form method="post" action="<=form.getAction()>"> <form method="post" action="oaform.jsp" enctype="multipart/form-data"><input type="hidden" name="oaform" value="formName"> */ public String getAction() { // if (session != null) session.setCurrentForm(this); bNeedsRefreshed = false; bFormEnded = false; String js = ""; /********* js = "\r\n"; js += "\r\n"; String s = "oaform.jsp\" onSubmit=\"doSubmit();\">"+js+"\r\n\r\n"; js += "function submitOA(cmd) {\r\n"; js += "setOA();"; js += "document.forms[0].action += '?' + cmd + '=1';"; js += "document.forms[0].submit();"; js += ""; js += "}\r\n"; js += "// -->\r\n"; Enumeration enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); String s = oh.getInitScript(); if (s != null) js += s + "\r\n"; } js += "\r\n"; if (session != null) { if (session.bSubmitFlag) { session.bSubmitFlag = false; if (session.lastForm != null && session.lastForm.forwardUrl != null) { js += session.getJavaScript(session.lastForm.forwardUrl, false); // 12/15 } } } if (autoScroll && !bScroll) { js += ""; } //qqqqqqqqqqqqqqqqqqqqqqvvvvvvvvvvvvvvvvvv sssssssssssssssss //qqqqqqqqqqqqqqqqqqqqqqvvvvvvvvvvvvvvvvvv //qqqqqqqqqqqqqqqqqqqqqqvvvvvvvvvvvvvvvvvv String s2 = ""; enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); // if form has an OAFileInput comp on it, then it will need to be able to get the file and // parse out the other component name/value pairs if (oh instanceof OAFileInput) { s2 = "?oaform="+url+"\""; s2 += " enctype=\"multipart/form-data"; break; } } /*
*/ String s = "oaform.jsp"+s2+"\" onSubmit=\"setOA();\" accept-charset=\"UTF-8\">\r\n"; s += "\r\n" + js + "\r\n"; s += "\r\n"; s += "\r\n"; s += "\r\n"; s += " */ // String s = "oaform.jsp\">"; } /** calls setEnd(true) */ public String setEnd() { return setEnd(true); } /** flags the form to know that the </form> tag has been set. */ public String setEnd(boolean b) { status = ""; bFormEnded = b; return ""; } public void setStatus(String s) { status = s; } public String getStatus() { return status; } public OASession getSession() { return session; } /** called by (oaform.jsp .. form .. frame) calls setValues on all OAHtml components and processCommand on any commands @return forwardUrl
        STEPS:
        1: set form.session 
        2: makes sure oasession.topUrl is correct
        3: notify all form comps by calling their beforeSetValuesInternal() 
        4: see if form is a multipart (used for OAFileInput)
        5: set all component values
        6: have components update object(s)
        7: call command component processCommand() method
        8: call session.checkBindings()
        9: call frameset and its parents processRequest() method
       10: return this.forwardUrl
       
*/ public String processRequest(OASession session) { if (session == null) return null; this.session = session; session.bSubmitFlag = true; // flag used by getAction() to only get javascript once per submit ServletRequest request = session.getRequest(); session.lastForm = this; boolean bError = false; Enumeration enumx; try { request.setCharacterEncoding("UTF-8"); } catch (Exception e) {} // let all components know that form was submitted. // this is because a checkbox that is not checked will // not send a name/value pair in the request enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); if (!readOnly) oh.beforeSetValuesInternal(); if (oh instanceof OAFileInput) ((OAFileInput)oh).setSaved(false); } Hashtable hashNameValue = new Hashtable(); String contentType = request.getContentType(); if ((contentType != null) && (contentType.indexOf("multipart/form-data") >= 0)) { try { processMultipart(request, hashNameValue); } catch (Exception e){ this.addError(e.toString()); bError = true; } } else { enumx = request.getParameterNames(); while ( enumx.hasMoreElements()) { String name = (String) enumx.nextElement(); String[] values = request.getParameterValues(name); hashNameValue.put(name,values); } } String[] ss; ss = (String[]) hashNameValue.get("oatarget"); targetName = (ss == null) ? null : ss[0]; ss = (String[]) hashNameValue.get("oaname"); frameName = (ss == null) ? null : ss[0]; bScroll = false; ss = (String[]) hashNameValue.get("oaTableName"); if (ss != null && ss.length == 1) { String s = ss[0]; ss = (String[]) hashNameValue.get("oaTableCommand"); if (ss != null && ss.length == 1) { if (s.length() > 0) hashNameValue.put(s, ss); hashNameValue.remove("oaTableName"); hashNameValue.remove("oaTableCommand"); } } // make sure topUrl is correctly set String topUrl = this.url; if (this.frame != null) { OAFrameSet fs = this.frame.frameSet; for ( ;fs != null; ) { topUrl = fs.url; if (fs.frame == null) fs = null; else fs = fs.frame.frameSet; } } if (this.frame == null || !topUrl.equalsIgnoreCase(session.frame.getUrl())) { if (topUrl != this.url || frameName==null || frameName.length()==0 || frameName.equalsIgnoreCase("_top")) { session.setTopUrl(topUrl); if (session.frame != null) { session.frame.setChanged(false); // form has already been display in browser } } } forwardUrl = null; lastCommand = null; lastObject = null; Vector vec = new Vector(5); try { ss = (String[]) hashNameValue.get("oatop"); top = 0; if (ss != null) top = Integer.parseInt(ss[0]); } catch (NumberFormatException e) { } // see if a reset command was submitted enumx = hashNameValue.keys(); while ( enumx.hasMoreElements()) { String command = (String) enumx.nextElement(); if (command.indexOf("oacommand_") != 0) continue; if (command.endsWith(".y")) continue; // only use ".x" if (command.endsWith(".x")) { command = command.substring(0,command.length() - 2); } // command to run int len = 0; try { len = Integer.parseInt(com.viaoa.html.Util.field(command,'_',2)); } catch (NumberFormatException e) { } // oacommand_9_cmdSelect2 // oacommand_10_tabAddress_9_cmdSelect2 String cmdid = com.viaoa.html.Util.field(command,'_',3,99); if (len > 0) cmdid = cmdid.substring(0, len); OAHtmlComponent oh = getComponent(cmdid); if (oh != null) { vec.addElement(command); if ( (oh instanceof OALink) && ((OALink)oh).isReset() ) { hashNameValue.clear(); break; } } else System.out.println("OAForm.processRequest() no component for command => "+command);//qqqqqqqqqq } enumx = hashNameValue.keys(); while ( enumx.hasMoreElements()) { String name = (String) enumx.nextElement(); String[] values = (String[]) hashNameValue.get(name); String fullName = name; // find out the name of the component in case it was encoded with an object id name = Util.getEncodedName(name); OAHtmlComponent oh = getComponent(name); if ((oh == null || oh instanceof OARadio) && values.length == 1) { if (name.indexOf("oacommand_") != 0) { name = Util.getEncodedName(values[0]); oh = getComponent(name); // OARadio if (oh != null) fullName = values[0]; // OARadio full name } } if (oh != null) { try { if (!readOnly) oh.setValuesInternal(fullName,values); } catch (Exception e) { System.out.println("OAForm.processRequest() Exception "+e); e.printStackTrace(); this.addError(e.toString()); bError = true; } } } if (bError) return getUrl(); // go back to this page if (!readOnly) update(); // save values to object String origUrl = null; if (this.frame != null) origUrl = this.frame.getUrl(); // commands int x = vec.size(); for (int i=0; i 0) cmdid = cmdid.substring(0, len); OAHtmlComponent oh = getComponent(cmdid); if (oh != null) { try { String s = oh.processCommand(session, this, command); if (s != null && s.length() > 0) forwardUrl = s; } catch (Exception e) { System.out.println("OAForm.processRequest() Exception "+e); e.printStackTrace(); this.addError(e.toString()); return getUrl(); } } else System.out.println("OAForm.processRequest() no component for command => "+command);//qqqqqqqqqq break; } } // check bindings in OASession // see if command is bound to another command or a frameset/frame/url session.checkBindings(url,getLastCommand()); if (frame != null && frame.getUrl() != null && !frame.getUrl().equalsIgnoreCase(this.url)) forwardUrl = frame.getUrl(); enumx = hashComponent.elements(); for ( ; enumx.hasMoreElements(); ) { OAHtmlComponent oh = (OAHtmlComponent) enumx.nextElement(); oh.afterSetValuesInternal(); if (oh instanceof OAFileInput || oh instanceof OADataTable) { String s = oh.processCommand(session, this,""); if (s != null) forwardUrl = s; } } if (forwardUrl == null || forwardUrl.length() == 0) forwardUrl = getUrl(); // go back to this page forwardUrl = afterPost(forwardUrl); // call listeners x = vecListener.size(); for (int i=0; i= 0) fname = fname.substring(x+1); fname = com.viaoa.util.OAString.convert(fname, "\"", null); } /* [0]=fiFile [1]=budget.txt */ hashNameValue.put(name, new String[] { fname }); if (fname != null && fname.length() > 0) { OAFileInput fi = (OAFileInput) oh; int max = fi.getMax(); if (max >= 0 && len > max) { throw new RuntimeException("Uploaded file size greater then "+max); } fi.setSaved(true); String sx = fi.getFileName(); OAFile.mkdirsForFile(sx); File file = new File(sx); String sz = file.getAbsolutePath(); BufferedOutputStream bos = new BufferedOutputStream(new FileOutputStream(file)); getNext(bis, bos, "\r\n"+sep); // this will write to file bos.flush(); bos.close(); } } } } bis.close(); } /* returns all data upto sep and "eats" the sep */ protected String getNext(BufferedInputStream bis, BufferedOutputStream bos, String sep) throws IOException { if (sep == null) return null; StringBuffer sb = new StringBuffer(1024); int c=0; boolean eof = false; String sep2 = null; if (bos == null) sep2 = "\r\nContent-Type:"; // this marks the beginning of a file int sepLen = sep.length(); int sep2Len = (sep2!=null)?sep2.length():0; for (;;) { c = bis.read(); if (c < 0) { eof = true; break; } if (sep2 != null && c == sep2.charAt(0)) { int hold = c; bis.mark(sep2Len+1); int j=1; for (;j 0;) { char c = value.charAt(0); if (c == '\n' || c == '\r') { value = value.substring(1); j++; } else break; } // test[13][10] pos = value.indexOf('\r'); if (pos >= 0) value = value.substring(0,pos); // test return new String[] { name, value }; } /** override from OAObject to make sure object is not saved to datasource. */ public void onSave() { } public String getHtml() { StringBuffer sb = new StringBuffer(4096); sb.append("\r\n"); sb.append("\r\n"); sb.append("\r\n"); sb.append(getHtmlStart()); sb.append("\r\n"); sb.append("\r\n"); sb.append("\r\n"); int x = vecComponent.size(); for (int i=0; i\r\n"); sb.append(" \r\n"); sb.append(" \r\n"); } sb.append(" \r\n"); sb.append(" \r\n"); sb.append(" \r\n"); sb.append("\r\n"); sb.append("
\r\n"); sb.append(" "); String s = c.getName(); int xx = s.length(); boolean b = false; for (int j=0; j\r\n"); sb.append(" \r\n"); sb.append(" "+c.getHtml()+"\r\n"); sb.append("
\r\n"); sb.append(" \r\n"); for (int i=0; i 0) sb.append(" "+s+"\r\n"); } sb.append("
\r\n"); sb.append("\r\n"); sb.append("\r\n"); sb.append(getHtmlEnd()); sb.append("\r\n"); sb.append("\r\n"); return new String(sb); } public String getHtmlStart() { // String s = ""; return s; } /** sets formEnded=true and returns </form> */ public String getHtmlEnd() { return getEndHtml(); } // 20180317 public void onBegin() { } // 20180317 public void onEnd() { } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy