Package net.minecraftforge.gradle.patching

Examples of net.minecraftforge.gradle.patching.ContextualPatch


        zin.close();
    }

    private void applySingleMcpPatch(File patchFile) throws Throwable
    {
        ContextualPatch patch = ContextualPatch.create(Files.toString(patchFile, Charset.defaultCharset()), new ContextProvider(sourceMap));
        printPatchErrors(patch.patch(false));
    }
View Full Code Here


            }
        }

        for (String key : patches.keySet())
        {
            ContextualPatch patch = findPatch(patches.get(key));
            if (patch == null)
            {
                getLogger().lifecycle("Patch not found for set: " + key); //This should never happen, but whatever
            }
            else
            {
                printPatchErrors(patch.patch(false));
            }
        }
    }
View Full Code Here

        }
    }

    private ContextualPatch findPatch(Collection<File> files) throws Throwable
    {
        ContextualPatch patch = null;
        for (File f : files)
        {
            patch = ContextualPatch.create(Files.toString(f, Charset.defaultCharset()), new ContextProvider(sourceMap));
            List<PatchReport> errors = patch.patch(true);
           
            boolean success = true;
            for (PatchReport rep : errors)
            {
                if (!rep.getStatus().isSuccess()) success = false;
View Full Code Here

TOP

Related Classes of net.minecraftforge.gradle.patching.ContextualPatch

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.