Interface IELFRelocationApplicator

All Known Implementing Classes:
ELFRelocationApplicator, ELFStandardRelocator

public interface IELFRelocationApplicator
Apply one specific relocation type.
  • Method Details

    • getType

      int getType()
      Get the relocation type.
      Returns:
      relocation type
    • canApply

      default boolean canApply(IELFRelocationApplicator.RelocInstance relocInstance)
      Determine whether the relocation can be applied. By default, the relocation is not applied when the symbol, if there is one, is not mapped. This is particularly important to avoid applying meaningless relocations in static analysis context.
      Parameters:
      relocInstance - relocation instance
      Returns:
      true if the relocation can be applied
    • apply

      Apply the relocation on the provided 'file' instance.
      Parameters:
      relocatedFile - relocated file
      relocInstance - relocation instance
      Throws:
      MemoryException - if relocation application fails