Module openj9.dtfj

Class Dll

java.lang.Object
com.ibm.dtfj.corereaders.zos.le.Dll

public class Dll extends Object
This class represents a DLL (Dynamically Linked Library).
  • Constructor Details

    • Dll

      public Dll(long address, AddressSpace space)
      Constructs a new Dll given the address of the DLCB (DLL Control Block) structure. The normal way for a user to get hold of an instance though would be via Edb.getFirstDll().
  • Method Details

    • getName

      public String getName() throws IOException
      Returns the name of this DLL.
      Throws:
      IOException
    • getLoadAddress

      public long getLoadAddress()
      Returns the load address for this DLL.
    • getWsa

      public long getWsa() throws IOException
      Returns the address of the WSA (Writable Static Area) for this DLL.
      Throws:
      IOException
    • getNext

      public Dll getNext() throws IOException
      Returns the next Dll in the chain (or null if none).
      Throws:
      IOException
    • getVariable

      public DllVariable getVariable(String name) throws IOException
      Returns the named DllVariable (or null if it can't be found).
      Throws:
      IOException
    • getVariables

      public DllVariable[] getVariables() throws IOException
      Returns an array of the DllVariables belonging to this DLL
      Throws:
      IOException
    • getFunction

      public DllFunction getFunction(String name) throws IOException
      Returns the named DllFunction (or null if it can't be found).
      Throws:
      IOException
    • getFunctions

      public DllFunction[] getFunctions() throws IOException
      Returns an array of the DllFunctions belonging to this DLL
      Throws:
      IOException
    • getFunction

      public static DllFunction getFunction(AddressSpace space, String name) throws IOException
      From the given AddressSpace returns the named DllFunction (or null if it can't be found). This caches previously found functions for speed. Note that this searches all the Dlls and returns the first match it finds so take care if multiple Dlls declare the same name!
      Parameters:
      space - the AddressSpace to search
      name - the name of the required function
      Throws:
      IOException
    • addFunction

      public static void addFunction(AddressSpace space, String name, DllFunction function)
      Add the given DllFunction to the set of functions for this AddressSpace. This can be used to add fake entries, eg see com.ibm.dtfj.corereaders.zos.le.FunctionEmulator#recordCalledFunctions