Examples of TypeMap


Examples of org.apache.axis2.schema.typemap.TypeMap

                    }
                }
            }

            //create a type mapper
            TypeMap basicTypeMap = new JavaTypeMap();
            if (schemaType instanceof XmlSchemaComplexType) {
                processXMLSchemaComplexType(schemaType, mapper, opName, schemaMap, qnameSuffix);
            } else if ((schemaTypeQname != null) && basicTypeMap.getTypeMap().containsKey(schemaTypeQname)){
                QName partQName = WSDLUtil.getPartQName(opName,
                        qnameSuffix,
                        message.getElementQName().getLocalPart());
                mapper.addTypeMappingName(partQName, (String)basicTypeMap.getTypeMap().get(schemaTypeQname));
            } else if (schemaType instanceof XmlSchemaSimpleType) {
                XmlSchemaSimpleType xmlSchemaSimpleType = (XmlSchemaSimpleType) schemaType;
                populateClassName(xmlSchemaSimpleType.getMetaInfoMap(),
                        mapper,
                        opName,
View Full Code Here

Examples of org.apache.axis2.schema.typemap.TypeMap

                    }
                }
            }

            //create a type mapper
            TypeMap basicTypeMap = new JavaTypeMap();
            if (schemaType instanceof XmlSchemaComplexType) {
                processXMLSchemaComplexType(schemaType, mapper, opName, schemaMap, qnameSuffix);
            } else if ((schemaTypeQname != null) && basicTypeMap.getTypeMap().containsKey(schemaTypeQname)){
                QName partQName = WSDLUtil.getPartQName(opName,
                        qnameSuffix,
                        message.getElementQName().getLocalPart());
                mapper.addTypeMappingName(partQName, (String)basicTypeMap.getTypeMap().get(schemaTypeQname));
            } else if (schemaType instanceof XmlSchemaSimpleType) {
                XmlSchemaSimpleType xmlSchemaSimpleType = (XmlSchemaSimpleType) schemaType;
                populateClassName(xmlSchemaSimpleType.getMetaInfoMap(),
                        mapper,
                        opName,
View Full Code Here

Examples of org.apache.uima.simpleserver.config.TypeMap

        filter = readFilter(filterBean.getFilter());
      }
    }

    // create a type map with the given information
    TypeMap typeMap = ConfigFactory.newTypeMap(typeBean.getName(), filter, typeBean.getOutputTag(),
        coveredText, typeBean.getOutputAll(), typeBean.getShortDescription(), typeBean
            .getLongDescription());

    // check if for the current type output features are mapped
    if (typeBean.getOutputs() != null) {
      Outputs outputBean = typeBean.getOutputs();
      // get mapped output features
      OutputType[] outputTypes = outputBean.getOutputArray();
      for (int i = 0; i < outputTypes.length; i++) {
        // parse output feature featurePath
        List<String> featurePath = parseFeaturePath(outputTypes[i].getFeaturePath());
        Output output = ConfigFactory.newOutput(featurePath, outputTypes[i].getOutputAttribute(),
            outputTypes[i].getShortDescription(), outputTypes[i].getLongDescription());
        // add output feature to the typeMap
        typeMap.addOutput(output);
      }
    }
    return typeMap;
  }
View Full Code Here

Examples of org.apache.uima.simpleserver.config.TypeMap

      AnnotationFS annot = (AnnotationFS) it.get();
      if (annot.getType().equals(docAnnotationType)) {
        // Skip the document annotation
        continue;
      }
      TypeMap typeMap = this.defaultTypeMap.get(annot.getType());
      // Create a new result entry, fill with attributes and add result set.
      ResultEntryImpl resultEntry = new ResultEntryImpl(typeMap.getOutputTag(), annot.getBegin(),
          annot.getEnd());
      makeOutputs(resultEntry, annot, typeMap);
      resultEntries.add(resultEntry);
    }
  }
View Full Code Here

Examples of org.apache.uima.simpleserver.config.TypeMap

        createMapForType(type);
      }
    }

    private void createMapForType(Type type) {
      TypeMap tm = ConfigFactory.newTypeMap(type.getName(), null, type.getShortName(), true);
      Iterator<?> featureIt = type.getFeatures().iterator();
      while (featureIt.hasNext()) {
        Feature feat = (Feature) featureIt.next();
        if (feat.getRange().isPrimitive()) {
          ArrayList<String> path = new ArrayList<String>(1);
          path.add(feat.getShortName());
          Output out = ConfigFactory.newOutput(path, feat.getShortName(),
              "No description provided", "No description provided");
          tm.addOutput(out);
        }
      }
      this.typeMap.put(type, tm);
    }
View Full Code Here

Examples of org.apache.wsif.wsdl.extensions.format.TypeMap

        }

        // Build the hashmap
        bindingIterator = typeMapping.getMaps().iterator();
        while (bindingIterator.hasNext()) {
            TypeMap typeMap = (TypeMap) bindingIterator.next();
            ///////////////////////////////////
            QName typeName = typeMap.getTypeName();
            if (typeName == null) typeName = typeMap.getElementName();
            String type = typeMap.getFormatType();
            if (typeName != null && type != null) {
                if (fieldTypeMaps.containsKey(typeName)) {
                  Vector v = null;
                  Object obj = fieldTypeMaps.get(typeName);                 
                  if (obj instanceof Vector) {
View Full Code Here

Examples of org.apache.wsif.wsdl.extensions.format.TypeMap

        }

        // Build the hashmap
        bindingIterator = typeMapping.getMaps().iterator();
        while (bindingIterator.hasNext()) {
            TypeMap typeMap = (TypeMap) bindingIterator.next();
            ///////////////////////////////////
            QName typeName = typeMap.getTypeName();
            if (typeName == null) typeName = typeMap.getElementName();
            String type = typeMap.getFormatType();
            if (typeName != null && type != null) {
                if (fieldTypeMaps.containsKey(typeName)) {
                    Vector v = null;
                  Object obj = fieldTypeMaps.get(typeName);                 
                  if (obj instanceof Vector) {
View Full Code Here

Examples of org.openengsb.core.edbi.jdbc.api.TypeMap

    }

    public JdbcIndexEngine create() {
        LOG.info("Creating new JdbcIndexEngine with driver {}", driver.getClass());

        TypeMap typeMap = driver.getTypeMap();
        DataSource dataSource = driver.getDataSource();

        TableEngine headTableEngine = new HeadTableEngine(dataSource, typeMap);
        TableEngine historyTableEngine = new HistoryTableEngine(dataSource, typeMap);
View Full Code Here

Examples of org.openengsb.core.edbi.jdbc.api.TypeMap

    HistoryTableEngine historyTableEngine;

    @Before
    public void setUp() throws Exception {
        // Type Map
        TypeMap typeMap = mock(TypeMap.class);
        when(typeMap.getType(String.class)).thenReturn(new DataType(Types.LONGVARCHAR, "LONGVARCHAR"));
        when(typeMap.getType(Integer.class)).thenReturn(new DataType(Types.INTEGER, "INTEGER"));
        when(typeMap.getType(Long.class)).thenReturn(new DataType(Types.BIGINT, "LONG"));
        when(typeMap.getType(Date.class)).thenReturn(new DataType(Types.TIMESTAMP, "TIMESTAMP"));
        when(typeMap.getType(UUID.class)).thenReturn(new DataType(Types.VARCHAR, "VARCHAR"));

        // Translators
        IndexNameTranslator headIndexNameTranslator = new IndexNameTranslator() {
            @Override
            public String translate(Index<?> index) {
View Full Code Here

Examples of org.openengsb.core.edbi.jdbc.api.TypeMap

        subModel.setType(SubTestModel.class);

        testIndex.setFields(Arrays.asList(testId, testInteger, subModel));

        // Type Map
        TypeMap typeMap = mock(TypeMap.class);
        when(typeMap.getType(String.class)).thenReturn(new DataType(Types.LONGNVARCHAR, "LONGVARCHAR"));
        when(typeMap.getType(UUID.class)).thenReturn(new DataType(Types.VARCHAR, "VARCHAR"));
        when(typeMap.getType(Integer.class)).thenReturn(new DataType(Types.INTEGER, "INTEGER"));
        when(typeMap.getType(Long.class)).thenReturn(new DataType(Types.BIGINT, "LONG"));
        when(typeMap.getType(Date.class)).thenReturn(new DataType(Types.TIMESTAMP, "TIMESTAMP"));

        engine = createEngine(getDataSource(), typeMap);
    }
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.