Skip to content

About the MutexSafe in lesson1 #2

@plallallla

Description

@plallallla

Why not create a class that inherits from mutex? This would establish a perfect is-a relationship. Using the mutex object as a member variable for encapsulation, as shown in the sample code, forms a has-a relationship, which deviates a bit from what was explained in the video. However, this is just a difference in implementation and does not affect the final usage demonstration. I hope to get an answer for this.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions