Package helma.objectmodel

Examples of helma.objectmodel.IProperty


        while (e.hasMoreElements()) {
            String key = (String) e.nextElement();
            if (dbmode && key.charAt(0) == '_') {
                continue;
            }
            IProperty prop = node.get(key);

            if (prop != null) {
                boolean validName = isValidElementName(key);
                String elementName;
                String propName;

                if (validName) {
                    elementName = key;
                    propName = null;
                } else {
                    elementName = "property";
                    propName = key;
                }

                int type = prop.getType();

                if (type == IProperty.NODE) {
                    write(prop.getNodeValue(), elementName, propName, level);
                } else {
                    writeProperty(prop, elementName, propName);
                }
            }
        }
View Full Code Here


                    if (columnName != null) {
                        DbMapping dbmap = nonvirtual.getDbMapping();
                        String propertyName = dbmap.columnNameToProperty(columnName);
                        if (propertyName == null)
                            propertyName = columnName;
                        IProperty property = nonvirtual.get(propertyName);
                        if (property != null) {
                            value = property.getStringValue();
                        }
                        if (value == null) {
                            if (columnName.equalsIgnoreCase(dbmap.getIDField())) {
                                value = nonvirtual.getID();
                            } else if (columnName.equalsIgnoreCase(dbmap.getNameField())) {
View Full Code Here

        // no need to make properties of virtual nodes persistable
        if (state == VIRTUAL) return;

        for (Enumeration e = properties(); e.hasMoreElements();) {
            String propname = (String) e.nextElement();
            IProperty next = get(propname);

            if (next == null || next.getType() != IProperty.NODE) {
                continue;
            }

            // check if this property actually needs to be persisted.
            Node node = (Node) next.getNodeValue();
            Relation rel = null;

            if (node == null || node == this) {
                continue;
            }

            rel = dbmap == null ? null : dbmap.getExactPropertyRelation(next.getName());
            if (rel != null && rel.isVirtual() && !rel.needsPersistence()) {
                convertToVirtual(node);
            } else {
                node.makePersistable();
                if (rel != null && rel.isComplexReference()) {
View Full Code Here

TOP

Related Classes of helma.objectmodel.IProperty

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.