Changeset 13696


Ignore:
Timestamp:
Oct 8, 2019 2:26:04 PM (2 months ago)
Author:
molsson
Message:

#5843 Refactored ModelicaCompiler.packUnit().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/dev-mo-2265/Compiler/ModelicaCompiler/src/jastadd/ModelicaCompiler.jrag

    r13686 r13696  
    21982198    protected Path ModelicaCompiler.packUnit(String className,
    21992199            TargetObject target, FClass fClass) throws PackingFailedException {
    2200 
    22012200        Path unitFile = fClass.root().getUtilInterface().getCompilationOutputPath().toPath();
    2202 
     2201       
    22032202        hookPackFmu(fClass, outDir);
    22042203        hookCheckAbort();
     2204        packUnit(className, target, fClass, unitFile);
     2205        hookFmuPacked(fClass, unitFile.toAbsolutePath().toFile());
     2206       
     2207        return unitFile;
     2208    }
     2209   
     2210    private void ModelicaCompiler.packUnit(String className, TargetObject target, FClass fClass, Path unitFile) {
    22052211        try {
    22062212            copySourceFiles(fClass, sourceDir, outDir);
     
    22122218            throw new PackingFailedException(String.format("Could not write to '%s'.", unitFile), e);
    22132219        }
    2214 
    2215         hookFmuPacked(fClass, unitFile.toAbsolutePath().toFile());
    2216         return unitFile;
    22172220    }
    22182221
Note: See TracChangeset for help on using the changeset viewer.