Package org.jitterbit.integration.structure.crom

Examples of org.jitterbit.integration.structure.crom.CROM.addType()


*/
public class SimpleTextStructureMappingTreeConverter {

    public MappingTreeStructure convert(SimpleTextStructure text, CallbackResult callback) {
        CROM root=new CROM(null, true, "", -1, CromType.CROM_t_Text);
        root.addType(CROM.CROM_t_Root);
        Segment seg=text.getSegment();
        CROM flat_node=new CROM(root, true, seg.getName(), -1, CromType.CROM_t_Text);
        flat_node.addType(CROM.CROM_t_Collection);
        if(text.getDelimiter()!=null || text.getStringQualifier()!=null){
          CROM_ext ext=flat_node.getExtension();
View Full Code Here


    public MappingTreeStructure convert(SimpleTextStructure text, CallbackResult callback) {
        CROM root=new CROM(null, true, "", -1, CromType.CROM_t_Text);
        root.addType(CROM.CROM_t_Root);
        Segment seg=text.getSegment();
        CROM flat_node=new CROM(root, true, seg.getName(), -1, CromType.CROM_t_Text);
        flat_node.addType(CROM.CROM_t_Collection);
        if(text.getDelimiter()!=null || text.getStringQualifier()!=null){
          CROM_ext ext=flat_node.getExtension();
          if(ext==null)ext=new CROM_Text();        
            if(text.getDelimiter()!=null)ext.setDelimiter(Utils.getDelimiterString(text));
            ext.setStrQual(text.getStringQualifier());
View Full Code Here

            ext.setStrQual(text.getStringQualifier());
        }
        for(Field f:text.getSegment().fieldList){
          CROM field=new CROM(flat_node, false, f.fieldName, -1, CromType.CROM_t_Text);
          field.setValueType(f.dataType);
          field.addType(CROM.CROM_t_Attribute | CROM.CROM_t_Optional);
          field.setDefaultValue(f.defaultValue);
          field.getExtension().setFormat(f.format);
          field.getExtension().setFieldPos((short)f.getBeginPosition());
          field.getExtension().setFieldLength((short)f.getLength());
        }
View Full Code Here

        for (Segment s : text.getSegmentList()) {
            Segment parent = s.findParent(text);
            CROM parent_crom=map.get(parent);
            CROM crom=new CROM(parent_crom, true, s.getName(), -1, CromType.CROM_t_Text);
            if(parent_crom==null){
              crom.addType(CROM.CROM_t_Root);
            }
            CROM_ext ext=crom.getExtension();
            String del=Utils.getDelimiterString(text);
            ext.setDelimiter(del);
            ext.setStrQual(text.getStringQualifier());
View Full Code Here

            }
            for (Field f : s.getFieldList()) {
                CROM field=new CROM(crom, false, f.fieldName, -1, CromType.CROM_t_Text);
              field.setValueType(f.dataType);
              if(f.equals(identifier)){
                  field.addType(CROM.CROM_t_Attribute);
              }
              else {
                field.addType(CROM.CROM_t_Attribute | CROM.CROM_t_Optional);
              }
              if(f.defaultValue!=null && f.defaultValue.length()>0){
View Full Code Here

                if(shouldRowIdsBeRemovedFromInformixTables(dbStruct)) {
                    column_info.removeInformixRowIdColumn();
                }
              TreeItem<DbTranRelations.Relation> item = tree.getRoot();
              CROM root=new CROM(null, true, "", 0, CromType.CROM_t_DB), node=null;
              root.addType(CROM.CROM_t_Root);
              for (TreeItem<DbTranRelations.Relation> child : item.getChildren()) {
                node=createCromTreeForTable(root, node, child, isFlat, column_info, isManualSqlStatement);
              }
              structure = updateProperties(dbStruct, root);
              if (callback != null) {
View Full Code Here

              field.setValueType(f.dataType);
              if(f.equals(identifier)){
                  field.addType(CROM.CROM_t_Attribute);
              }
              else {
                field.addType(CROM.CROM_t_Attribute | CROM.CROM_t_Optional);
              }
              if(f.defaultValue!=null && f.defaultValue.length()>0){
                field.setDefaultValue(f.defaultValue);
                field.addType(CROM.CROM_t_HasDefault);
              }
View Full Code Here

              else {
                field.addType(CROM.CROM_t_Attribute | CROM.CROM_t_Optional);
              }
              if(f.defaultValue!=null && f.defaultValue.length()>0){
                field.setDefaultValue(f.defaultValue);
                field.addType(CROM.CROM_t_HasDefault);
              }
              ext=field.getExtension();
              ext.setFormat(f.format);
              if(isFixedField){
                ext.setFieldPos((short)f.getBeginPosition());
View Full Code Here

            return svc.getCache(LdapStructureServerCache.class);
        }

        private CROM createCromTree(LdapStructure structure, ObjectClassStructure[] classes, boolean isTarget) {
            CROM root = new CROM(null, true, "LDAP", 0, CromType.CROM_t_Ldap);
            root.addType(CROM.CROM_t_Element | CROM.CROM_t_Root);
            LdapToCromConverter converter = isTarget ? LdapToCromConverterFactory.newTargetStructureConverter()
                            : LdapToCromConverterFactory.newSourceStructureConverter();
            converter.setAttributeOrder(new NameSorter<LdapStructureAttribute>(true));
            AttributeFilter filter = new StructureAttributeFilter(structure);
            for (LdapStructureEntryNode node : getEntryNodes(structure, classes)) {
View Full Code Here

    public static Node insertAttributeCommand(TreeComponent tree, Node node) {
        if (!isLdapAttribute(tree, node)) {
            return null;
        }
        CROM dn = new CROM(node.m_CROM, false, LdapStringConstants.attribute_command_display_name, 1, node.m_CROM.m_CromType);
        dn.addType(CROM.CROM_t_Attribute | CROM.CROM_t_Optional);
        dn.setValueType("String");
        return new Node(tree, node, dn);
    }

    public static Node insertOldValueNode(TreeComponent tree, Node node) {
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.