public class ModuleExtractorUtils
extends java.lang.Object
| Constructor and Description |
|---|
ModuleExtractorUtils() |
| Modifier and Type | Method and Description |
|---|---|
static org.jfrog.build.api.Module |
jsonStringToModule(java.lang.String json)
Given a serialized json module string, deserialize it into a Module object.
|
static java.lang.String |
moduleToJsonString(org.jfrog.build.api.Module module)
Given a Module object, serialize it as a json string.
|
static org.jfrog.build.api.Module |
readModuleFromFile(java.io.File fromFile)
Given a file, read its contents as a json string and deserialize it as a Module object.
|
static void |
saveModuleToFile(org.jfrog.build.api.Module module,
java.io.File toFile)
Given a Module object, serialize it to a json string and write it to the provided file.
|
public static java.lang.String moduleToJsonString(org.jfrog.build.api.Module module)
throws java.io.IOException
module - The module to serializejava.io.IOExceptionpublic static org.jfrog.build.api.Module jsonStringToModule(java.lang.String json)
throws java.io.IOException
json - The serialized json module stringjava.io.IOExceptionpublic static void saveModuleToFile(org.jfrog.build.api.Module module,
java.io.File toFile)
throws java.io.IOException
module - The module objecttoFile - The file to write the serialized module tojava.io.IOExceptionpublic static org.jfrog.build.api.Module readModuleFromFile(java.io.File fromFile)
throws java.io.IOException
fromFile - The file containing a serialized json stringjava.io.IOException