class SergeantUnit extends Unit {

  public SergeantUnit(String name) {
    super(name);
  }

  @Override
  public UnitExtension getUnitExtension(String extensionName) {<FILL_FUNCTION_BODY>}
}


    if (extensionName.equals("SergeantExtension")) {
      return Optional.ofNullable(unitExtension).orElseGet(() -> new Sergeant(this));
    }

    return super.getUnitExtension(extensionName);
  
<methods>public void <init>(java.lang.String) ,public abstractextensions.UnitExtension getUnitExtension(java.lang.String) <variables>private java.lang.String name,protected abstractextensions.UnitExtension unitExtension