官术网_书友最值得收藏!

Association

The association relationship maintains a has a kind of relationship between the objects of the classes. The has a relation can either be one-to-one or one-to-many. In the following example, we can see that there is a one-to-one association relationship between the Employee and Manager classes, as an Employee would only have one Manager class. We also have a one-to-one association relation between Employee and Department. The reverse of these relationships would be one-to-many relationships as one Department class might have many employees and one manager might have many employees reporting to them. The following code snippet depicts the association relationship:

主站蜘蛛池模板: 长海县| 揭西县| 五常市| 长海县| 繁峙县| 宜兰县| 保山市| 墨竹工卡县| 常熟市| 石家庄市| 扎鲁特旗| 海兴县| 景泰县| 门源| 文昌市| 新建县| 图木舒克市| 会宁县| 确山县| 宝坻区| 灵山县| 海林市| 八宿县| 濉溪县| 金塔县| 青龙| 诏安县| 赤壁市| 阳曲县| 宿松县| 崇义县| 女性| 呼玛县| 定南县| 新丰县| 平凉市| 吉林省| 海伦市| 保靖县| 吴川市| 延长县|