# LLD

1. UML DIAGRAM.

UML diagram is way to expess how application work what are entity of application and they intract with each other.

Types of UML DIAGRAM.

1. Structual(Static): Explain structure of application/object/class. and how they are link with each other.
2. Behaviour(Dynamic): How object are intract with each other.

![](https://cdn.hashnode.com/uploads/covers/67bb93958fdd2f72865f1ed7/249770da-8bbb-43d3-9926-3b3cf7bc2564.png align="center")

Note: We have to study Class Diagram and Sequence Diagram.

## Class Diagram.

1. Class structure
2. Assoication/Connection

![](https://cdn.hashnode.com/uploads/covers/67bb93958fdd2f72865f1ed7/decb23e0-c732-4720-8bee-1a562ff698ae.png align="center")

Assoiciation

![](https://cdn.hashnode.com/uploads/covers/67bb93958fdd2f72865f1ed7/8d1e0efe-6737-49b6-a0cc-486ed8074da2.png align="center")

A. Inheritance: is-a relation

![](https://cdn.hashnode.com/uploads/covers/67bb93958fdd2f72865f1ed7/1c393a8f-a112-4d11-a7e0-b5d3e4093478.png align="center")

B. Composition: has-a relation. (most used)

![](https://cdn.hashnode.com/uploads/covers/67bb93958fdd2f72865f1ed7/f974f69b-4877-4f56-9ca9-6b570eb0ff29.png align="center")

Example:

```java
class A { 
    method1(); 
} 
class B { 
    A a; 
    B() { a = new A(); }
    method2(); 
} 

main { 
    B b = new B(); 
    b.method2(); 
    b.a.method1();
}
```

## Sequence Diagram

to coming...

## SOLID PRINCIPLE

What problem arises. when thoused of classes create in Application then these problem occurse.

- Maintainbility
- Readbility
- BUGS
