Package org.jbpm.formapi.shared.api.items

Examples of org.jbpm.formapi.shared.api.items.TextFieldRepresentation


                labelName.setEventActions(asMapOfNull(labelActions, FBScript.class));
                labelName.setEffectClasses(labelEffects);
                labelName.setValue(output.getName());
                labelName.setWidth("100px");
                tableOfOutputs.setElement(index, 0, labelName);
                TextFieldRepresentation textField = new TextFieldRepresentation();
                textField.setEventActions(asMapOfNull(textfieldActions, FBScript.class));
                textField.setWidth("200px");
                textField.setEffectClasses(textfieldEffects);
                OutputData data = new OutputData();
                data.setName(output.getName());
                data.setValue(output.getSourceExpresion());
                data.setMimeType("multipart/form-data");
                data.setFormatter(new Formatter() {
                    @Override
                    public Object format(Object object) {
                        return object;
                    }
                    @Override
                    public Map<String, Object> getDataMap() {
                        return new HashMap<String, Object>();
                    }
                });
                textField.setOutput(data);
                tableOfOutputs.setElement(index, 1, textField);
            }
            LabelRepresentation labelOutputs = new LabelRepresentation();
            labelOutputs.setEventActions(asMapOfNull(labelActions, FBScript.class));
            labelOutputs.setEffectClasses(labelEffects);
View Full Code Here


            String paramName = params[index];
            LabelRepresentation labelName = new LabelRepresentation();
            labelName.setValue(paramName);
            labelName.setWidth("100px");
            table.setElement(index, 0, labelName);
            TextFieldRepresentation textField = new TextFieldRepresentation();
            textField.setWidth("200px");
            OutputData data = new OutputData();
            data.setName(paramName);
            data.setMimeType("multipart/form-data");
            data.setFormatter(null);
            textField.setOutput(data);
            table.setElement(index, 1, textField);
        }
        LabelRepresentation labelParams = new LabelRepresentation();
        labelParams.setValue("Parameters:");
        form.addFormItem(labelParams);
View Full Code Here

        }
    }
   
    @Override
    public FormItemRepresentation getRepresentation() {
        TextFieldRepresentation rep = super.getRepresentation(new TextFieldRepresentation());
        rep.setDefaultValue(this.defaultContent);
        rep.setName(this.name);
        rep.setId(this.id);
        rep.setMaxLength(this.maxlength);
        return rep;
    }
View Full Code Here

    public void populate(FormItemRepresentation rep) throws FormBuilderException {
        if (!(rep instanceof TextFieldRepresentation)) {
            throw new FormBuilderException(i18n.RepNotOfType(rep.getClass().getName(), "TextFieldRepresentation"));
        }
        super.populate(rep);
        TextFieldRepresentation trep = (TextFieldRepresentation) rep;
        this.defaultContent = trep.getDefaultValue();
        this.name = trep.getName();
        this.id = trep.getId();
        this.maxlength = trep.getMaxLength();
        if (trep.getWidth() != null && !"".equals(trep.getWidth())) {
            setWidth(trep.getWidth());
        }
        if (trep.getHeight() != null && !"".equals(trep.getHeight())) {
            setHeight(trep.getHeight());
        }
        populate(this.textBox);
    }
View Full Code Here

TOP

Related Classes of org.jbpm.formapi.shared.api.items.TextFieldRepresentation

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.