# Class ManagerHandler

java.lang.Object
com.university.bookstore.chain.DiscountHandler
com.university.bookstore.chain.ManagerHandler

public class ManagerHandler extends DiscountHandler
Manager-level discount approval handler. Can approve discounts up to 15%.

Since:
  2024-09-15
Version:
  3.0
Author:
  Navid Mohaghegh

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `ManagerHandler()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `String`
  `getHandlerName()`
  Gets the name of this handler for identification purposes.
  `double`
  `getMaxDiscount()`
  Gets the maximum discount this handler can approve.
  `void`
  `handleRequest(DiscountRequest request)`
  Handles a discount request.

  ### Methods inherited from class com.university.bookstore.chain.DiscountHandler

  `canApprove, getChainLength, getHandlerInfo, getNext, setNext, toString`

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

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

- ## Constructor Details

  - ### ManagerHandler

    public ManagerHandler()

- ## Method Details

  - ### handleRequest

    public void handleRequest(DiscountRequest request)
    Description copied from class: `DiscountHandler`
    Handles a discount request. Subclasses must implement this method to define their approval logic.
    Specified by:
      `handleRequest` in class `DiscountHandler`
    Parameters:
      `request` - the discount request to handle

  - ### getHandlerName

    public String getHandlerName()
    Description copied from class: `DiscountHandler`
    Gets the name of this handler for identification purposes.
    Specified by:
      `getHandlerName` in class `DiscountHandler`
    Returns:
      the handler name

  - ### getMaxDiscount

    public double getMaxDiscount()
    Description copied from class: `DiscountHandler`
    Gets the maximum discount this handler can approve.
    Specified by:
      `getMaxDiscount` in class `DiscountHandler`
    Returns:
      the maximum discount rate (0.0 to 1.0)