Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does the dot mean at the end of an association?

I reversed some Java code to get a uml class diagram using Visual Paradigm. The diagram shows some associations with little black circles on one end, which I never saw before.

Image

It's definitely not a composition and not a containment! Can anybody explain to me, what kind of association this is?

Here's the related code:

public class DataAdapter extends RecyclerView.Adapter<DataAdapter.ViewHolder> {
    public static final String TAG = DataAdapter.class.getSimpleName();

    private static Context mContext;
    private ArrayList<DataClass> mData;
    private static OnItemClickListener<DataClass> mListener;

    public static class ViewHolder extends RecyclerView.ViewHolder {}

    public DataAdapter(Context context, ArrayList<DataClass> data) {}

    public void setOnClickListener(OnItemClickListener listener) {}

    @Override
    public int getItemCount() {}

    @Override
    public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {}

    @Override
    public void onBindViewHolder(ViewHolder holder, int position) {}
}

public interface OnItemClickListener<T> {
    public void onItemClick(T item);
}
like image 529
Locdoc01 Avatar asked Dec 12 '17 12:12

Locdoc01


People also ask

What does the dot mean in UML?

From the UML specs v2. 5: Ownership of Association ends by an associated Classifier may be indicated graphically by a small filled circle, which for brevity we will term a dot.

What is used in association end?

An association end names is a name that uniquely identifies one end of an association. It specifies a role of an object of a class which it plays in the association. An association end names is written next to the association line near the class that plays the role.

What is called as one end of association?

Association end is a connection between the line depicting an association and the icon depicting the connected classifier. Name of the association end may be placed near the end of the line. The association end name is commonly referred to as role name (but it is not defined as such in the UML 2.4 standard).

How do you identify an association class?

An association class is an association that also has class properties (such as attributes, operations, and associations). It is shown by drawing a dashed line from the association path to a class symbol that holds the attributes, operations, and associations for the association.


2 Answers

To adorn Geert's correct answer: In former UML versions navigability (an open arrow at either side) was (mis-) used for that purpose. So now that you see a dot it also means you can navigate towards it (because it renders an attribute of the class type it's touching). It is still possible to mix both notations. But it does not make much sense. Personally I'd use (if ever) navigational arrows only in a conceptual phase.

like image 34
qwerty_so Avatar answered Sep 29 '22 01:09

qwerty_so


What you are seeing is the ownership indicator, commonly known as the dot
In this case it indicates that the property at right side of the association is owned by the class on the left side.

From the UML specs v2.5:

Ownership of Association ends by an associated Classifier may be indicated graphically by a small filled circle, which for brevity we will term a dot. The dot is to be drawn integral to the graphic path of the line, at the point where it meets the Classifier, inserted between the end of the line and the side of the node representing the Classifier. The diameter of the dot shall not exceed half the height of the aggregation diamond, and shall be larger than the width of the line. This avoids visual confusion with the filled diamond notation while ensuring that it can be distinguished from the line. The dot shows that the model includes a Property of the type represented by the Classifier touched by the dot. This Property is owned by the Classifier at the other end. In such a case it is normal to suppress the Property from the attributes compartment of the owning Classifier.

like image 186
Geert Bellekens Avatar answered Sep 29 '22 00:09

Geert Bellekens