public class VBAMacroExtractor
extends java.lang.Object
Constructor and Description |
---|
VBAMacroExtractor() |
Modifier and Type | Method and Description |
---|---|
void |
extract(java.io.File input,
java.io.File outputDir)
Extracts the VBA modules from a macro-enabled office file and writes them
to
.vba files in outputDir . |
void |
extract(java.io.File input,
java.io.File outputDir,
java.lang.String extension)
Extracts the VBA modules from a macro-enabled office file and writes them
to files in
outputDir . |
static void |
main(java.lang.String[] args) |
public static void main(java.lang.String[] args) throws java.io.IOException
java.io.IOException
public void extract(java.io.File input, java.io.File outputDir, java.lang.String extension) throws java.io.IOException
outputDir
.
Creates the outputDir
, directory, including any necessary but
nonexistent parent directories, if outputDir
does not exist.
If outputDir
is null, writes the contents to standard out instead.input
- the macro-enabled office file.outputDir
- the directory to write the extracted VBA modules to.extension
- file extension of the extracted VBA modulesjava.io.IOException
public void extract(java.io.File input, java.io.File outputDir) throws java.io.IOException
.vba
files in outputDir
.
Creates the outputDir
, directory, including any necessary but
nonexistent parent directories, if outputDir
does not exist.
If outputDir
is null, writes the contents to standard out instead.input
- the macro-enabled office file.outputDir
- the directory to write the extracted VBA modules to.java.io.IOException
Copyright 2022 The Apache Software Foundation or its licensors, as applicable.