Package org.apache.flex.swc

Examples of org.apache.flex.swc.SWCComponent


                        continue;
                    }
                   
                    final String icon = reader.getAttributeValue(null, ATTR_ICON);
                    final String preview = reader.getAttributeValue(null, ATTR_PREVIEW);
                    final SWCComponent component = new SWCComponent();
                    if (className != null)
                        component.setQName(className.intern());
                    if (componentName != null)
                        component.setName(componentName.intern());
                   
                    // uri is null-checked already
                    component.setURI(uri.intern());
                   
                    if (icon != null)
                        component.setIcon(icon.intern());
                    if (preview != null)
                        component.setPreview(preview.intern());
                    swc.addComponent(component);
                    componentIndex.put(className, component);
                }
                else if (tagName.equals(TAG_SCRIPT))
                {
                    String name = reader.getAttributeValue(null, ATTR_NAME);
                    String mod = reader.getAttributeValue(null, ATTR_MOD);
                    String signatureChecksum = reader.getAttributeValue(null, ATTR_SIGNATURE_CHECKSUM);
                    currentScript = new SWCScript();
                    if (name != null)
                        currentScript.setName(name.intern());
                    if (mod != null)
                        currentScript.setLastModified(Long.parseLong(mod));
                    if (signatureChecksum != null)
                        currentScript.setSignatureChecksum(signatureChecksum);
                    currentLibrary.addScript(currentScript);
                    timeStamps.put(name, mod);
                }
                else if (tagName.equals(TAG_FLEX))
                {
                    final String flexVersion = reader.getAttributeValue(null, ATTR_VERSION);
                    final String minSupportedVersion = reader.getAttributeValue(null, ATTR_MINIMUM_SUPPORTED_VERSION);
                    final String flexBuild = reader.getAttributeValue(null, ATTR_BUILD);
                    ISWCVersion swcVersion = swc.getVersion();
                    swcVersion.setFlexVersion(flexVersion);
                    swcVersion.setFlexMinSupportedVersion(minSupportedVersion);
                    swcVersion.setFlexBuild(flexBuild);
                }
                else if (tagName.equals(TAG_SWC))
                {
                    final String swcVersion = reader.getAttributeValue(null, ATTR_VERSION);
                    swc.getVersion().setSWCVersion(swcVersion);
                }
                else if (tagName.equals(TAG_DEF))
                {
                    String id = reader.getAttributeValue(null, ATTR_ID);
                    id = QNameNormalization.normalize(id);
                    currentScript.addDefinition(id);

                    final SWCComponent component = componentIndex.get(id);
                    if (component != null)
                        component.setScript(currentScript);
                }
                else if (tagName.equals(TAG_DEP))
                {
                    String id = reader.getAttributeValue(null, ATTR_ID);
                    id = QNameNormalization.normalize(id);
View Full Code Here


            final Collection<XMLName> tagNames = flexProject.getTagNamesForClass(qName);
            for (XMLName tagName : tagNames)
            {
                if (includeComponent(tagName, includedNamespaces))
                {
                    final SWCComponent component = new SWCComponent();
                    component.setName(tagName.getName());
                    component.setURI(tagName.getXMLNamespace());
                    component.setQName(qName);
                    swc.addComponent(component);                   
                }
            }
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.flex.swc.SWCComponent

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.