PreviousUpNext

15.3.337  src/lib/make-library-glue/planfile-junk.api

## planfile-junk.api
#
# Convenience fns for use with
#     src/lib/make-library-glue/planfile.pkg

# Compiled by:
#     src/lib/std/standard.lib


stipulate
    package pfs =  patchfiles;                                                                                  # patchfiles            is from   src/lib/make-library-glue/patchfiles.pkg
    package plf =  planfile;                                                                                    # planfile              is from   src/lib/make-library-glue/planfile.pkg
    package sm  =  string_map;                                                                                  # string_map            is from   src/lib/src/string-map.pkg
herein

    # This api is implemented in:
    #
    #     src/lib/make-library-glue/planfile-junk.pkg
    #
    api  Planfile_Junk
    {
        set_patch:  { patchfiles: pfs::Patchfiles,  paragraph: plf::Paragraph,  x: X }  ->  pfs::Patchfiles;
            #
            # Fieldnames:
            #     filename
            #     patchname
            #     text
            #
            # Unconditionally sets patch { filename, patchname } to 'text', obliterating any previous contents.

        set_patch__definition:  plf::Paragraph_Definition(X);



        append_patch:  { patchfiles: pfs::Patchfiles,  paragraph: plf::Paragraph,  x: X }  ->  pfs::Patchfiles;
            #
            # Fieldnames:
            #     filename
            #     patchname
            #     text
            #
            # Appends given 'text' to patch { filename, patchname }.

        append_patch__definition:  plf::Paragraph_Definition(X);



        copy_patch:  { patchfiles: pfs::Patchfiles,  paragraph: plf::Paragraph,  x: X }  ->  pfs::Patchfiles;
            #
            # Fieldnames:
            #     srcfile
            #     srcptch
            #     dstfile
            #     dstptch
            #
            # Unconditionally copies contents of patch { filename => srcfile, patchname => srcptch }
            #                   over contents of patch { filename => dstfile, patchname => dstptch }
            # obliterating any previous contents.

        copy_patch__definition:  plf::Paragraph_Definition(X);
    };
end;


Comments and suggestions to: bugs@mythryl.org

PreviousUpNext