Examples of FieldMapping

Note that a Filter with the pattern '*' no constraint and only an null value as mapping would create a 1:1 copy of the source. TODO: Is it OK to keep an actual implementation in the Service API package? @author Rupert Westenthaler
  • org.exolab.castor.mapping.xml.FieldMapping
    @version $Revision: 1.1.1.1 $ $Date: 2003/03/03 07:08:35 $
  • org.kitesdk.data.FieldMapping
    Represents how to store a Schema field. @since 0.14.0

  • Examples of com.cloudera.cdk.data.hbase.impl.EntitySchema.FieldMapping

      }

      public SingleFieldEntityFilter(EntitySchema entitySchema,
          EntitySerDe<?> entitySerDe, String fieldName, Object filterValue,
          CompareFilter.CompareOp equalityOperator) {
        FieldMapping fieldMapping = entitySchema.getFieldMapping(fieldName);
        if (fieldMapping.getMappingType() != MappingType.COLUMN) {
          throw new DatasetException(
              "SingleColumnValueFilter only compatible with COLUMN mapping types.");
        }

        byte[] family = fieldMapping.getFamily();
        byte[] qualifier = fieldMapping.getQualifier();
        byte[] comparisonBytes = entitySerDe.serializeColumnValueToBytes(fieldName,
            filterValue);

        this.filter = new SingleColumnValueFilter(family, qualifier,
            equalityOperator, comparisonBytes);
    View Full Code Here

    Examples of com.sun.jdo.api.persistence.support.FieldMapping

                if (size > 0) {
                    DBDriverHandler driverHandler =
                        dBDriverHandlerFactory.createDBDriverHandler(ps);
                    try {
                        for (int i = 0; i < size; i++) {
                            FieldMapping fieldMapping = (FieldMapping) columns.get(i);
                            int type = fieldMapping.getColumnType();
                            if (type == Types.CHAR || type == Types.VARCHAR) {
                                int len = fieldMapping.getColumnLength();
                                if (len > 0) {
                                    driverHandler.defineColumnType(i + 1, type, len);
                                } else {
                                    driverHandler.defineColumnType(i + 1, type);
                                }
    View Full Code Here

    Examples of de.innovationgate.wga.config.FieldMapping

             }

            if (fieldMappings != null) {
              Iterator<FieldMapping> mappings = fieldMappings.iterator();
              while (mappings.hasNext()) {
                FieldMapping mapping = mappings.next();
                if (mapping.getType().equals(FieldMapping.TYPE_META)) {
                  metaMappings.put(mapping.getName(), mapping.getExpression());
                } else if (mapping.getType().equals(FieldMapping.TYPE_ITEM)) {
                  itemMappings.put(mapping.getName(), mapping.getExpression());           
                }
              }
           }
        }
    View Full Code Here

    Examples of org.apache.isis.objectstore.sql.mapping.FieldMapping

                            if (sql.length() > initialLength) {
                                sql.append(" AND ");
                            }

                            final FieldMapping fieldMapping = fieldMappingFor(patternAssoc);
                            if (fieldMapping != null) {
                                fieldMapping.appendWhereClause(connector, sql, pattern);
                            } else {
                                // Have to use getXXX method if the fieldMapping is
                                // null..
                                final ObjectSpecification specification = patternAssoc.getSpecification();
    View Full Code Here

    Examples of org.apache.isis.runtimes.dflt.objectstores.sql.mapping.FieldMapping

                    simpleFieldNo++;
                }
            }

            for (final ObjectAssociation field : oneToOneProperties) {
                final FieldMapping mapping = lookup.createMapping(specification, field);
                fieldMappings.add(mapping);
                fieldMappingLookup.put(field, mapping);
            }

        }
    View Full Code Here

    Examples of org.apache.openjpa.jdbc.meta.FieldMapping

        }

        public void testOplockFieldMapping() {
            ClassMapping cm = (ClassMapping) JPAFacadeHelper.getMetaData(
                emf, OptimisticLockInstance.class);
            FieldMapping fm = cm.getFieldMapping("oplock");
            assertEquals(1, fm.getColumns().length);
        }
    View Full Code Here

    Examples of org.apache.openjpa.jdbc.meta.FieldMapping

         * Load the given state manager with data from the result set. Only
         * mappings originally selected will be loaded.
         */
        private void load(ClassMapping mapping, OpenJPAStateManager sm,
            JDBCFetchConfiguration fetch, Result res) throws SQLException {
            FieldMapping eagerToMany = load(mapping, sm, fetch, res, null);
            if (eagerToMany != null)
                eagerToMany.loadEagerJoin(sm, this, fetch.traverseJDBC(eagerToMany),
                    res);
            if (_active && _lm != null && res.isLocking())
                _lm.loadedForUpdate(sm);
        }
    View Full Code Here

    Examples of org.apache.openjpa.jdbc.meta.FieldMapping

            // create all our eager selects so that those fields are reserved
            // and cannot be reused during the actual eager select process,
            // preventing infinite recursion
            eager = Math.min(eager, fetch.getEagerFetchMode());
            FieldMapping eagerToMany = createEagerSelects(sel, mapping, sm, fields,
                fetch, eager);

            // select all base class mappings; do this after batching so that
            // the joins needed by these selects don't get in the WHERE clause
            // of the batched selects
            int seld = selectBaseMappings(sel, mapping, mapping, sm, fields,
                fetch, eager, eagerToMany, ident, joinedSupers);

            // select eager to-many relations last because during load they
            // advance the result set and could exhaust it, so no other mappings
            // can load afterwords
            if (eagerToMany != null)
                eagerToMany.selectEagerJoin(sel, sm, this,
                    fetch.traverseJDBC(eagerToMany), eager);

            // optionally select subclass mappings
            if (subs == Select.SUBS_JOINABLE || subs == Select.SUBS_ANY_JOINABLE)
                selectSubclassMappings(sel, mapping, sm, fetch);
    View Full Code Here

    Examples of org.apache.openjpa.jdbc.meta.FieldMapping

            OpenJPAStateManager sm, BitSet fields, JDBCFetchConfiguration fetch,
            int eager) {
            if (mapping == null || eager == JDBCFetchConfiguration.EAGER_NONE)
                return null;

            FieldMapping eagerToMany = createEagerSelects(sel,
                mapping.getJoinablePCSuperclassMapping(), sm, fields, fetch, eager);

            FieldMapping[] fms = mapping.getDefinedFieldMappings();
            boolean inEagerJoin = sel.hasEagerJoin(false);
            int sels;
    View Full Code Here

    Examples of org.apache.openjpa.jdbc.meta.FieldMapping

            // add more update clauses as needed.
            boolean augmentUpdates = true;

            for (Iterator i = updateParams.entrySet().iterator(); i.hasNext();) {
                Map.Entry next = (Map.Entry) i.next();
                FieldMapping fmd = (FieldMapping) next.getKey();

                if (fmd.isVersion())
                    augmentUpdates = false;

                Val val = (Val) next.getValue();

                Column col = fmd.getColumns()[0];
                sql.append(col.getName());
                sql.append(" = ");

                ExpState state = val.initialize(sel, ctx, 0);
                val.calculateValue(sel, ctx, state, null, null);
    View Full Code Here
    TOP
    Copyright © 2018 www.massapi.com. 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.