Jump to content

File:UML class pet.svg

Page contents not supported in other languages.
This is a file from the Wikimedia Commons
From Wikipedia, the free encyclopedia
    Original file (SVG file, nominally 529 × 202 pixels, file size: 8 KB)

    Summary

    Description
    English: UML diagram of a abstract class named Pet with two classes; Cat and Dog which inherits from Pet. The abstract class Pet declares an abstract method called Speak which needs to be implemented by any class that inherits from the abstract class.
    Date
    Source Own work
    Author Frap

    Licensing

    I, the copyright holder of this work, hereby publish it under the following license:
    Creative Commons CC-Zero This file is made available under the Creative Commons CC0 1.0 Universal Public Domain Dedication.
    The person who associated a work with this deed has dedicated the work to the public domain by waiving all of their rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law. You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission.

    Source code

    PlantUML source code.

    @startuml
    abstract class Pet
    {
        +{abstract} Speak()
    }
    
    class Cat extends Pet
    {
        +Speak()
    }
    
    class Dog extends Pet
    {
        +Speak()
    }
    
    note left of Cat::Speak()
      Cat says meow!
    end note
    
    note right of Dog::Speak()
      Dog says woof!
    end note
    @enduml
    

    Captions

    Add a one-line explanation of what this file represents

    Items portrayed in this file

    depicts

    17 May 2023

    image/svg+xml

    8,412 byte

    09fb2f82c20289aa151276c40d8a526b208f7862

    File history

    Click on a date/time to view the file as it appeared at that time.

    Date/TimeThumbnailDimensionsUserComment
    current13:53, 17 May 2023Thumbnail for version as of 13:53, 17 May 2023529 × 202 (8 KB)FrapUploaded own work with UploadWizard

    Global file usage

    The following other wikis use this file:

    Metadata