caoss.simulator.hardware

## Class RAM

- java.lang.Object
- - caoss.simulator.hardware.RAM

- All Implemented Interfaces:
    Clockable

      public class RAM
      extends java.lang.Object
      implements Clockable

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `int` | `addressingUnit` Unit of addressing (in bytes)
    `long` | `capacity` Capacity in bytes
    `int` | `physicalAddressSize` Physical address size (in bits)

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `RAM(long capacity, int physicalAddressSize)` Constructor for byte-addressable memory
    `RAM(long capacity, int physicalAddressSize, int addressingUnit)` Constructor

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.lang.String` | `getDescription()` Textual description of the hardware
    `void` | `tick()` Method invoked by `Clock` in each time instance

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

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

- - ### Field Detail

    - #### capacity

          public final long capacity

      Capacity in bytes

    - #### physicalAddressSize

          public final int physicalAddressSize

      Physical address size (in bits)

    - #### addressingUnit

          public final int addressingUnit

      Unit of addressing (in bytes)

  - ### Constructor Detail

    - #### RAM

          public RAM(long capacity,
                     int physicalAddressSize)

      Constructor for byte-addressable memory
      Parameters:
        `capacity` - Capacity in bytes
        `physicalAddressSize` - Physical address size (in bits)

    - #### RAM

          public RAM(long capacity,
                     int physicalAddressSize,
                     int addressingUnit)

      Constructor
      Parameters:
        `capacity` - Capacity in bytes
        `physicalAddressSize` - Physical address size (in bits)
        `addressingUnit` - Unit of addressing (in bytes)

  - ### Method Detail

    - #### tick

          public void tick()

      Description copied from interface: `Clockable`
      Method invoked by `Clock` in each time instance
      Specified by:
        `tick` in interface `Clockable`

    - #### getDescription

          public java.lang.String getDescription()

      Description copied from interface: `Clockable`
      Textual description of the hardware
      Specified by:
        `getDescription` in interface `Clockable`
      Returns:
        The textual description