org.springframework.boot.loader.tools

Class Library



  • public class Library
    extends Object
    Encapsulates information about a single library that may be packed into the archive.
    Since:
    1.1.2
    Author:
    Phillip Webb
    See Also:
    Libraries
    • Constructor Detail

      • Library

        public Library(File file,
                       LibraryScope scope)
        Create a new Library.
        Parameters:
        file - the source file
        scope - the scope of the library
      • Library

        public Library(File file,
                       LibraryScope scope,
                       boolean unpackRequired)
        Create a new Library.
        Parameters:
        file - the source file
        scope - the scope of the library
        unpackRequired - if the library needs to be unpacked before it can be used
      • Library

        public Library(String name,
                       File file,
                       LibraryScope scope,
                       boolean unpackRequired)
        Create a new Library.
        Parameters:
        name - the name of the library as it should be written or null to use the file name
        file - the source file
        scope - the scope of the library
        unpackRequired - if the library needs to be unpacked before it can be used
    • Method Detail

      • getName

        public String getName()
        Return the name of file as it should be written.
        Returns:
        the name
      • getFile

        public File getFile()
        Return the library file.
        Returns:
        the file
      • getScope

        public LibraryScope getScope()
        Return the scope of the library.
        Returns:
        the scope
      • isUnpackRequired

        public boolean isUnpackRequired()
        Return if the file cannot be used directly as a nested jar and needs to be unpacked.
        Returns:
        if unpack is required