Package com.io7m.montarre.nativepack.internal

# Class MNPackagerAbstract

java.lang.Object
com.io7m.montarre.nativepack.internal.MNPackagerAbstract

All Implemented Interfaces:
  `MNativePackagerServiceType`

Direct Known Subclasses:
  `MNPackagerAppImage`, `MNPackagerDeb`, `MNPackagerFlatpak`, `MNPackagerMSI`, `MNPackagerShell`

public abstract class MNPackagerAbstract extends Object implements MNativePackagerServiceType
An abstract packager.

- ## Constructor Summary

  Constructors
  Modifier
  Constructor
  Description
  `protected`
  `MNPackagerAbstract(MNativePackagerServiceProviderType inProvider)`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `final String`
  `describe()`
  `protected final MException`
  `error(Throwable e)`
  `protected final Optional<MResource>`
  `findBestIcon(MNativeWorkspaceType workspace, MPackageReaderType reader)`
  `protected final Optional<MResource>`
  `findLicense(MPackageReaderType reader)`
  `final com.io7m.lanark.core.RDottedName`
  `name()`
  `protected final void`
  `setAttribute(String name, Object value)`
  `protected final Map<String,String>`
  `takeAttributes()`
  `protected final com.io7m.verona.core.Version`
  `translateVersion(MNativeWorkspaceType workspace, com.io7m.verona.core.Version version)`
  `protected final Optional<Path>`
  `unpackIcon(MNativeWorkspaceType workspace, MPackageReaderType packageV, Path directory)`
  `protected final Optional<Path>`
  `unpackLicense(MPackageReaderType packageV, Path directory)`
  `protected final OpenOption[]`
  `writeReplaceOptions()`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

  ### Methods inherited from interface com.io7m.montarre.api.natives.MNativePackagerServiceType

  `execute, unsupportedReason`

- ## Constructor Details

  - ### MNPackagerAbstract

    protected MNPackagerAbstract(MNativePackagerServiceProviderType inProvider)

- ## Method Details

  - ### writeReplaceOptions

    protected final OpenOption[] writeReplaceOptions()

  - ### describe

    public final String describe()
    Specified by:
      `describe` in interface `MNativePackagerServiceType`
    Returns:
      A description of the service

  - ### name

    public final com.io7m.lanark.core.RDottedName name()
    Specified by:
      `name` in interface `MNativePackagerServiceType`
    Returns:
      The name of the packager

  - ### takeAttributes

    protected final Map<String,String> takeAttributes()

  - ### setAttribute

    protected final void setAttribute(String name, Object value)

  - ### error

    protected final MException error(Throwable e)

  - ### findLicense

    protected final Optional<MResource> findLicense(MPackageReaderType reader)

  - ### findBestIcon

    protected final Optional<MResource> findBestIcon(MNativeWorkspaceType workspace, MPackageReaderType reader)

  - ### unpackIcon

    protected final Optional<Path> unpackIcon(MNativeWorkspaceType workspace, MPackageReaderType packageV, Path directory) throws IOException, MException
    Throws:
      `IOException`
      `MException`

  - ### unpackLicense

    protected final Optional<Path> unpackLicense(MPackageReaderType packageV, Path directory) throws IOException, MException
    Throws:
      `IOException`
      `MException`

  - ### translateVersion

    protected final com.io7m.verona.core.Version translateVersion(MNativeWorkspaceType workspace, com.io7m.verona.core.Version version)