In UML 2.5.1, released 2017, a Class has Properties (typically a "property" in many programming languages) and Operations (reoughly a "method" in many programming languages).
Abstract Operations
The C# "methods" Job
and Job2
are Abstract Operations.
An Operation (section 9.6) is a kind of BehavioralFeature. A BehavioralFeature can be abstract (section 9.9.2.5). A BehavioralFeature is itself an abstract Class (section 9.9.2.5). Every Class is an EncapsulatedClassifier (section 11.4.1). Every EncapsulatedClassifier is a StructuredClassifier (11.3.1). Every StructuredClassifier is a Classifier (section 11.1). I quote the standard now (from section 9.2.4.1):
The name of an abstract Classifier is shown in italics, where permitted by the font in use. Alternatively or in addition, an abstract Classifier may be shown using the textual annotation {abstract} after or below its name
In all cases, MyClass
, Job
and Job2
are all abstract classifiers, and the preferred way to show this is by italic font. And/or use notation {abstact}
. The notation <<abstract>>
comes from an older UML standard.
Properties
a
and b
are Properties owned by the Class MyClass
. Such an owned Property is also called an Attribute. (11.4.3.1). Section 11.4.4 states about notation
A Class has four mandatory compartments: attributes, operations, receptions (see 9.2.4) and internal structure (see 11.2.4).
One can read more about compartments in section 9.2.4. The take home message there is: The fact that a
and b
are properties is conveyed by simply placing them in the topmost compartment on the Class box - the "attributes" box. This is exactly what you did. Writing <<property>>
could be omitted.
The notation <<property>>
means that the Properties a
and b
follow a stereotype called property
. It is not defined in UML, but can be part of some UML Profile. According to https://stackoverflow.com/a/63784017 , this is a specific C# stereotype. So I guess you can keep the notation you have, indicating that a
and b
are not only UML Properties, but also C# property
.