title: How to create a UML diagram from a given java class?
body: <p>I am wondering how I would create a UML diagram from a java class that I have already wrote. One main question that I have is do I need to include all the override functions in this box of the UML diagram? Also does everything else look correct? I was very ill during the lecture of UML so I had to teach myself and am not 100% confident in my work.</p>
  
  <p>Here is my java class and then I will post the diagram I made for this class.</p>
  
  <pre><code>public class Dog extends Pet implements LicensedPet, TrainedDog {
  
  public static final String GENUS = "canis";
  
  private Boolean isHappy = false;
  private Boolean isSitting = false;
  private LocalDateTime whenLicensed;
  
  public Dog(String name, int age, Gender gender) {
      super(name, age, "dog", gender);
  }
  
  public void petDog() {
      isHappy = true;
  }
  
  public void praiseDog() {
      isHappy = true;
  }
  
  public void yellAtDog() {
      isHappy = false;
  }
  
  public Boolean getIsHappy() {
      return isHappy;
  }
  
  public String getIsHappyAsString() {
      if (isHappy) {
          return "happy";
      } else {
          return "sad";
      }
  }
  
  @Override
  public String[] getCoreVaccines() {
  
      String[] coreVaccines = {
          "Rabies 1-year",
          "Rabies 3-year",
          "Distemper",
          "Parvovirus",
          "Adenovirus"
      };
  
      return coreVaccines;
  }
  
  @Override
  public String[] getNonCoreVaccines() {
  
      String[] nonCoreVaccines = {
          "Parainfluenza",
          "Bordetella bronchiseptica",
          "Lyme disease",
          "Leptospirosis",
          "Canine influenza"
      };
  
      return nonCoreVaccines;
  }
  
  @Override
  public Boolean isLicensed() {
      return whenLicensed != null;
  }
  
  @Override
  public void assignLicense() {
      whenLicensed = LocalDateTime.now();
  }
  
  @Override
  public LocalDateTime whenLicensed() {
      return whenLicensed;
  }
  
  @Override
  public void sit() {
      isSitting = true;
  }
  
  @Override
  public void unsit() {
      isSitting = false;
  }
  
  @Override
  public String speak() {
      return "Yawyahwer";
  }
  
  @Override
  public String bark(int numBarks) {
     String barks = "";
     for (int i = 0; i &lt; numBarks; i++) {
         barks += "bark!";
     }
  
     return barks;
  }
  
  @Override
  public String toString() {
      String info = super.toString();
  
     String updatedInfo =  String.format("%s, isHappy: %s", info, isHappy);
  
     if (whenLicensed != null) {
         updatedInfo +=  ", whenLicensed: " + whenLicensed;
     }
  
     return updatedInfo;
  }
  }
  </code></pre>
  
  <p>Here is what I created so far for this class.</p>
  
  <pre><code>    Dog
  ---------
      +GENUS:string 
      -isHappy:boolean
      -isSitting:boolean
      -whenLicensed:LocalDateTime
  ----------------
      +«constructor»Dog(name:string, age:int, gender:gender)
      +petDog()
      +praiseDog()
      +yellAtDog()
      +getIsHappy():boolean
      +getIsHappyAsString():string
  </code></pre>
  
  <p>Thanks for the help in advance i appreciate it</p>