Examples of SwcScript


Examples of flex2.compiler.swc.SwcScript

                    {
                        Source dependent = symbolTable.findSourceByQName((QName) name);

                        if (dependent.isSwcScriptOwner())
                        {
                            SwcScript swcScript = (SwcScript) dependent.getOwner();
                            Swc swc = swcScript.getLibrary().getSwc();
                       
                            // Make sure each dependency's minimum
                            // supported version is less than or equal to
                            // the compatibility version.
                            if (compatibilityVersion < swc.getVersions().getMinimumVersion())
                            {
                                DependencyNotCompatible message =
                                    new DependencyNotCompatible(swcScript.getName().replace('/', '.'),
                                                                swc.getLocation(),
                                                                swc.getVersions().getMinimumVersionString(),
                                                                compilerConfiguration.getCompatibilityVersionString());
                                ThreadLocalToolkit.log(message, u.getSource());
                            }
View Full Code Here

Examples of flex2.compiler.swc.SwcScript

            assert compilationUnit != null : "Must have missed a forcedToStop() check after the most recent batch()";
            Source source = compilationUnit.getSource();

            if (source.isSwcScriptOwner())
            {
                SwcScript swcScript = (SwcScript) source.getOwner();
                Swc swc = swcScript.getLibrary().getSwc();
                VirtualFile defaultsCssFile = null;

                if (versionDefaultsCssFileName != null)
                {
                    defaultsCssFile = swc.getFile(versionDefaultsCssFileName);
View Full Code Here

Examples of flex2.compiler.swc.SwcScript

                // this later to figure out which RSLs to load.
                Source source = u.getSource();
               
                if (!source.isInternal() && source.isSwcScriptOwner())
                {
                    SwcScript script = (SwcScript)source.getOwner();
                    contributingSwcs.add(script.getSwcLocation());
                }
            }
        }

        String flexInitClass = null;
View Full Code Here

Examples of flex2.compiler.swc.SwcScript

    private static void addSignatureChecksumToData(ApplicationData data, CompilationUnit unit)
  {
    Long signatureChecksum = unit.getSignatureChecksum();
    if (signatureChecksum == null)
    {
      SwcScript script = (SwcScript) unit.getSource().getOwner();
      signatureChecksum = new Long(script.getLastModified());
    }

    if (data.swcDefSignatureChecksums != null)
    {
      for (Iterator iter = unit.topLevelDefinitions.iterator(); iter.hasNext();)
View Full Code Here

Examples of flex2.compiler.swc.SwcScript

            if (compilationUnit != null)
            {
                for (QName topLevelDefinition : compilationUnit.topLevelDefinitions)
                {
                    SwcScript swcScript = compilerSwcContext.getCachedScript(topLevelDefinition);

                    // Make sure the SwcScript's cached CompilationUnit isn't reused.
                    if (swcScript != null)
                    {
                        CompilationUnit swcScriptCompilationUnit = swcScript.getCompilationUnit();

                        if (swcScriptCompilationUnit != null)
                        {
                            // SwcContext's getSource() has the side effect of
                            // copying cached type information into a new
                            // Source object, so we need to clean that up too.
                            swcScriptCompilationUnit.getSource().removeCompilationUnit();
                            swcScript.setCompilationUnit(null);
                        }
                    }
                }
            }
View Full Code Here

Examples of org.apache.flex.swc.SWCScript

                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)
View Full Code Here

Examples of org.apache.flex.swc.SWCScript

       
        // Add the generated root class and its dependencies to the list of
        // scripts.
        if (librarySWFTarget.getRootClassName() != null)
        {
            final SWCScript script = new SWCScript();
            script.setName(librarySWFTarget.getRootClassName());
            script.addDefinition(librarySWFTarget.getRootClassName());
            // This class is synthetic and is supposed to be globally
            // unique, so nobody should care what the time stamp is.
            // If we set the time stamp to the current time, then
            // every SWC we make will be slightly different from all other
            // SWCs.
            script.setLastModified(1);

            // add baseclass as an inheritance dependency
            script.addDependency(librarySWFTarget.getBaseClassQName(), DependencyType.INHERITANCE);
            defaultLibrary.addScript(script);
        }
       
        if (librarySWFTarget.getASMetadataNames() != null)
        {
View Full Code Here

Examples of org.apache.flex.swc.SWCScript

     */
    private SWCScript createScript(ICompilationUnit cu,
            Collection<IDefinition> definitionsToBuild) throws InterruptedException
    {
        // Create a script model per compilation unit.
        final SWCScript script = new SWCScript();
        script.setName(cu.getSWFTagsRequest().get().getDoABCTagName());

        // Add all the externally visible definitions to the script model.
        final IFileScopeRequestResult fsResult = cu.getFileScopeRequest().get();
        for (final IDefinition def : fsResult.getExternallyVisibleDefinitions())
        {
            script.addDefinition(def.getQualifiedName());
            script.setLastModified(cu.getSyntaxTreeRequest().get().getLastModified());
           
            if (definitionsToBuild != null)
                definitionsToBuild.add(def);
        }
        final DependencyGraph dependencyGraph =
            flexProject.getDependencyGraph();
        Set<ICompilationUnit> directDependencies =
            dependencyGraph.getDirectDependencies(cu);
        for (ICompilationUnit directDependency : directDependencies)
        {
            final Map<String, DependencyTypeSet> dependenciesMap =
                dependencyGraph.getDependencySet(cu, directDependency);
            for (Map.Entry<String, DependencyTypeSet> dependencyEntry : dependenciesMap.entrySet())
            {
                for (DependencyType type : dependencyEntry.getValue())
                    script.addDependency(dependencyEntry.getKey(), type);
            }
           
        }

        return script;
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.