Package org.apache.chemistry.opencmis.commons.impl.dataobjects

Examples of org.apache.chemistry.opencmis.commons.impl.dataobjects.PropertyDecimalDefinitionImpl


                break;
            case DATETIME:
                result = new PropertyDateTimeDefinitionImpl();
                break;
            case DECIMAL:
                result = new PropertyDecimalDefinitionImpl();
                break;
            case HTML:
                result = new PropertyHtmlDefinitionImpl();
                break;
            case ID:
View Full Code Here


            break;
        case DATETIME:
            result = new PropertyDateTimeDefinitionImpl();
            break;
        case DECIMAL:
            result = new PropertyDecimalDefinitionImpl();
            break;
        case HTML:
            result = new PropertyHtmlDefinitionImpl();
            break;
        case ID:
View Full Code Here

            ((PropertyIntegerDefinitionImpl) result)
                    .setMinValue(((CmisPropertyIntegerDefinitionType) propertyDefinition).getMinValue());
            ((PropertyIntegerDefinitionImpl) result)
                    .setMaxValue(((CmisPropertyIntegerDefinitionType) propertyDefinition).getMaxValue());
        } else if (propertyDefinition instanceof CmisPropertyDecimalDefinitionType) {
            result = new PropertyDecimalDefinitionImpl();

            ((PropertyDecimalDefinitionImpl) result)
                    .setChoices(convertChoiceDecimalList(((CmisPropertyDecimalDefinitionType) propertyDefinition)
                            .getChoice()));
View Full Code Here

        createStandardDefinition(prop, id, PropertyType.DATETIME, displayName, Cardinality.MULTI);
        return prop;
    }

    public static PropertyDecimalDefinitionImpl createDecimalDefinition(String id, String displayName) {
        PropertyDecimalDefinitionImpl prop = new PropertyDecimalDefinitionImpl();
        createStandardDefinition(prop, id, PropertyType.DECIMAL, displayName, Cardinality.SINGLE);
        return prop;
    }
View Full Code Here

        createStandardDefinition(prop, id, PropertyType.DECIMAL, displayName, Cardinality.SINGLE);
        return prop;
    }

    public static PropertyDecimalDefinitionImpl createDecimalMultiDefinition(String id, String displayName) {
        PropertyDecimalDefinitionImpl prop = new PropertyDecimalDefinitionImpl();
        createStandardDefinition(prop, id, PropertyType.DECIMAL, displayName, Cardinality.MULTI);
        return prop;
    }
View Full Code Here

            prop2 = PropertyCreationHelper.createDateTimeMultiDefinition("DateTimePropMV",
                    "Sample DateTime multi-value Property");
            propertyDefinitions.put(prop2.getId(), prop2);

            PropertyDecimalDefinitionImpl prop3 = PropertyCreationHelper.createDecimalDefinition("DecimalProp",
                    "Sample Decimal Property");
            propertyDefinitions.put(prop3.getId(), prop3);

            prop3 = PropertyCreationHelper.createDecimalDefinition("DecimalPropMV",
                    "Sample Decimal multi-value Property");
            propertyDefinitions.put(prop3.getId(), prop3);

            PropertyHtmlDefinitionImpl prop4 = PropertyCreationHelper.createHtmlDefinition("HtmlProp",
                    "Sample Html Property");
            propertyDefinitions.put(prop4.getId(), prop4);
View Full Code Here

            ((PropertyIntegerDefinitionImpl) result)
                    .setMinValue(((CmisPropertyIntegerDefinitionType) propertyDefinition).getMinValue());
            ((PropertyIntegerDefinitionImpl) result)
                    .setMaxValue(((CmisPropertyIntegerDefinitionType) propertyDefinition).getMaxValue());
        } else if (propertyDefinition instanceof CmisPropertyDecimalDefinitionType) {
            result = new PropertyDecimalDefinitionImpl();

            ((PropertyDecimalDefinitionImpl) result)
                    .setChoices(convertChoiceDecimalList(((CmisPropertyDecimalDefinitionType) propertyDefinition)
                            .getChoice()));
View Full Code Here

                break;
            case DATETIME:
                result = new PropertyDateTimeDefinitionImpl();
                break;
            case DECIMAL:
                result = new PropertyDecimalDefinitionImpl();
                break;
            case HTML:
                result = new PropertyHtmlDefinitionImpl();
                break;
            case ID:
View Full Code Here

        prop2 = PropertyCreationHelper.createDateTimeMultiDefinition("DateTimePropMV",
                "Sample DateTime multi-value Property");
        propertyDefinitions.put(prop2.getId(), prop2);

        PropertyDecimalDefinitionImpl prop3 = PropertyCreationHelper.createDecimalDefinition("DecimalProp",
                "Sample Decimal Property");
        propertyDefinitions.put(prop3.getId(), prop3);

        prop3 = PropertyCreationHelper.createDecimalDefinition("DecimalPropMV", "Sample Decimal multi-value Property");
        propertyDefinitions.put(prop3.getId(), prop3);

        PropertyHtmlDefinitionImpl prop4 = PropertyCreationHelper.createHtmlDefinition("HtmlProp",
                "Sample Html Property");
        propertyDefinitions.put(prop4.getId(), prop4);
View Full Code Here

                "Decimal Document Type for Validation", InMemoryDocumentTypeDefinition.getRootDocumentType());

        Map<String, PropertyDefinition<?>> propertyDefinitions = new HashMap<String, PropertyDefinition<?>>();
        // create a String property definition

        PropertyDecimalDefinitionImpl propDef = PropertyCreationHelper.createDecimalDefinition(DECIMAL_PROP_TYPE,
                "Sample Decimal Property");
        propDef.setMinValue(BigDecimal.valueOf(-1.5));
        propDef.setMaxValue(BigDecimal.valueOf(1.5));
        propertyDefinitions.put(propDef.getId(), propDef);

        cmisType.setPropertyDefinitions(propertyDefinitions);

        return cmisType;
    }
View Full Code Here

TOP

Related Classes of org.apache.chemistry.opencmis.commons.impl.dataobjects.PropertyDecimalDefinitionImpl

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.