Package org.jibx.util

Examples of org.jibx.util.InsertionOrderedMap$ValueIterator


        m_outBinding = out;
        m_trimWhitespace = trim;
        m_uriPrefixDefaults = new HashMap();
        m_keyObjects = new ArrayList();
        m_objectBindings = new HashMap();
        m_referenceUriBinding = new InsertionOrderedMap();
        m_nsRootUris = new InsertionOrderedSet();
        m_formats = new LazyList();
    }
View Full Code Here


   
    /**
     * Constructor.
     */
    public ValidationContext() {
        m_idSchemaMap = new InsertionOrderedMap();
        m_namespaceSchemaMap = new HashMap();
        m_duplicateNamespaces = new HashSet();
        m_problemList = new ArrayList();
        m_skipSet = new HashSet();
    }
View Full Code Here

     * @return map
     */
    private Map mapPropertyReadMethods(IClassItem[] methods, Set inclset, Set exclset) {
       
        // check all methods for property read access matches
        InsertionOrderedMap getmap = new InsertionOrderedMap();
        for (int i = 0; i < methods.length; i++) {
            IClassItem item = methods[i];
            String name = item.getName();
            int flags = item.getAccessFlags();
            if (item.getArgumentCount() == 0 && (flags & Modifier.STATIC) == 0 && (flags & Modifier.PUBLIC) != 0 &&
                ((name.startsWith("get") && !item.getTypeName().equals("void")) || (name.startsWith("is") &&
                item.getTypeName().equals("boolean")))) {
               
                // have what appears to be a getter, check if it should be used
                String memb = ValueCustom.memberNameFromGetMethod(name);
                boolean use = true;
                if (inclset != null) {
                    use = inclset.contains(memb.toLowerCase());
                } else if (exclset != null) {
                    use = !exclset.contains(memb.toLowerCase());
                }
                if (use) {
                    getmap.put(memb, item);
                }
               
            }
        }
        return getmap;
View Full Code Here

     * @return map
     */
    private Map mapPropertyWriteMethods(IClassItem[] methods, Set inclset, Set exclset) {
       
        // check all methods for property write access matches
        InsertionOrderedMap setmap = new InsertionOrderedMap();
        for (int i = 0; i < methods.length; i++) {
            IClassItem item = methods[i];
            String name = item.getName();
            int flags = item.getAccessFlags();
            if (item.getArgumentCount() == 1 && (flags & Modifier.STATIC) == 0 && (flags & Modifier.PUBLIC) != 0 &&
                name.startsWith("set") && item.getTypeName().equals("void")) {
               
                // have what appears to be a setter, check if it should be used
                String memb = ValueCustom.memberNameFromSetMethod(name);
                boolean use = true;
                if (inclset != null) {
                    use = inclset.contains(memb.toLowerCase());
                } else if (exclset != null) {
                    use = !exclset.contains(memb.toLowerCase());
                }
                if (use) {
                    setmap.put(memb, item);
                }
               
            }
        }
        return setmap;
View Full Code Here

     * @return map
     */
    private Map mapFields(IClassItem[] fields, String[] prefs, String[] suffs, Set inclset, Set exclset) {
       
        // check all fields for use as members
        InsertionOrderedMap fieldmap = new InsertionOrderedMap();
        for (int i = 0; i < fields.length; i++) {
            IClassItem item = fields[i];
            if ((item.getAccessFlags() & (Modifier.FINAL | Modifier.STATIC | Modifier.TRANSIENT)) == 0) {
               
                // not final, static, or transient, so check if it should be used
                String name = item.getName();
                String memb = ValueCustom.memberNameFromField(name, prefs, suffs);
                boolean use = true;
                if (inclset != null) {
                    use = inclset.contains(memb.toLowerCase());
                } else if (exclset != null) {
                    use = !exclset.contains(memb.toLowerCase());
                }
                if (use) {
                    fieldmap.put(memb, item);
                }
            }
        }
        return fieldmap;
    }
View Full Code Here

                }
            }
        }
       
        // process all members found in class
        m_memberMap = new InsertionOrderedMap();
        boolean auto = !getName().startsWith("java.") && !getName().startsWith("javax.");
        List names = nameset.asList();
        for (Iterator iter = names.iterator(); iter.hasNext();) {
           
            // get basic member information
View Full Code Here

        m_namespaceLeadMatches = Utility.EMPTY_STRING_ARRAY;
        m_namespaceLeadReplaces = Utility.EMPTY_STRING_ARRAY;
        m_namespacePackageMap = Collections.EMPTY_MAP;
        m_packageDirectoryMap = Collections.EMPTY_MAP;
        m_uriPackageMap = new HashMap();
        m_namePackageMap = new InsertionOrderedMap();
        m_noNamespacePackage = npkg;
        m_namePackageMap.put("", new PackageHolder("", basedir, null));
    }
View Full Code Here

TOP

Related Classes of org.jibx.util.InsertionOrderedMap$ValueIterator

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.