Package org.drools.ide.common.client.modeldriven

Examples of org.drools.ide.common.client.modeldriven.DropDownData


        } else {
            Map<String, String> mFactTypes = scenario.getVariableTypes();
            type = mFactTypes.get( this.mCall.getVariable() );
        }

        DropDownData enums = suggestionCompletionEngine.getEnums( type,
                val.field, this.mCall.getCallFieldValues()
        );
        return new MethodParameterCallValueEditor( val,
                                                   enums,
                                                   executionTrace,
View Full Code Here


            panel.add( datePicker );
        } else {
            Map<String, String> currentValueMap = new HashMap<String, String>();
            // TODO fill currentValueMap with values of other VerifyFields (if any)
            DropDownData dropDownData = sce.getEnums(factType, field.getFieldName(), currentValueMap);
            if ( dropDownData != null ) {
                //GUVNOR-1324: Java enums are of type TYPE_COMPARABLE whereas Guvnor enums are not.
                //The distinction here controls whether the EXPECTED value is handled as a true
                //Java enum or a literal with a selection list (i.e. Guvnor enum)
                String dataType = sce.getFieldType( key );
View Full Code Here

        } else if ( flType != null && flType.equals( SuggestionCompletionEngine.TYPE_DATE ) ) {
            valueEditorWidget = dateEditor();
            panel.add( valueEditorWidget );

        } else {
            final DropDownData dropDownData = helper.getEnums();

            if ( dropDownData != null ) {
                field.setNature( FieldData.TYPE_ENUM );
                dependentEnumEditors = new ArrayList<FieldDataConstraintEditor>();
                valueEditorWidget = dropDownEditor( dropDownData );
View Full Code Here

            if ( type == null && !this.readOnly ) {
                type = this.getModeller().getModel().getRHSBoundFact( this.model.variable ).factType;
            }
        }

        DropDownData enums = completions.getEnums( type,
                                                   val.field,
                                                   this.model.fieldValues
                );
        ActionValueEditor actionValueEditor = new ActionValueEditor( val,
                                                                     enums,
View Full Code Here

                    //a couple of drop-downs so it's quicker to simply update them all.
                    updateEnumDropDowns();
                }
            };

            DropDownData dropDownData = getDropDownData();
            resultWidget = new EnumDropDown( value.getValue(),
                                             handler,
                                             dropDownData );

            //Wrap widget within a HorizontalPanel to add a space before and after the Widget
View Full Code Here

            resultWidget.setDropDownData( selectedValue.getValue(),
                                          getDropDownData() );
        }

        private DropDownData getDropDownData() {
            DropDownData dropDownData = completions.getEnums( factType,
                                                              factField,
                                                              sentence.getEnumFieldValueMap() );
            return dropDownData;
        }
View Full Code Here

            if ( type == null ) {
                type = this.getModeller().getModel().getRHSBoundFact( this.model.variable ).factType;
            }
        }

        DropDownData enums = completions.getEnums( type,
                                                   val.field,
                                                   this.model.fieldValues
                );

        return new MethodParameterValueEditor( val,
View Full Code Here

                   defaultValue );
            this.sce = sce;
            this.context = context;

            //Check if there is an enumeration
            final DropDownData dd = sce.getEnums( context.getBasePattern().getFactType(),
                                                  ((ConditionCol52) context.getBaseColumn()).getFactField(),
                                                  new HashMap<String, String>() );
            if ( dd != null ) {
                this.values = convertValueList( getSplitValues( dd.fixedList ) );
                this.originalValues = this.values;
View Full Code Here

                            }
                        }
                    }
                }
                this.initialiseValueList = false;
                final DropDownData dd = sce.getEnums( context.getBasePattern().getFactType(),
                                                      ((ConditionCol52) context.getBaseColumn()).getFactField(),
                                                      currentValueMap );
                if ( dd != null ) {
                    this.values = convertValueList( getSplitValues( dd.fixedList ) );
                    this.originalValues = this.values;
View Full Code Here

    }

    private Widget valueEditor(final ActionFieldValue val) {
        SuggestionCompletionEngine completions = this.getModeller().getSuggestionCompletions();
        DropDownData enums = completions.getEnums( this.factType,
                                                   val.field,
                                                   this.model.fieldValues
                );

        ActionValueEditor actionValueEditor = new ActionValueEditor( val,
View Full Code Here

TOP

Related Classes of org.drools.ide.common.client.modeldriven.DropDownData

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.