@startuml package com.iluwatar.embedded.value { class App { - LOGGER : Logger {static} + App() + main(args : String[]) {static} } class DataSource { - LOGGER : Logger {static} - conn : Connection - createschema : Statement - deleteschema : Statement - getschema : Statement - insertIntoOrders : PreparedStatement - queryOrders : Statement - queyOrderByID : PreparedStatement - removeorder : PreparedStatement + DataSource() + createSchema() : boolean + deleteSchema() : boolean + getSchema() : String + insertOrder(order : Order) : boolean + queryOrder(id : int) : Order + queryOrders() : Stream + removeOrder(id : int) } ~interface DataSourceInterface { + CREATE_SCHEMA : String {static} + DELETE_SCHEMA : String {static} + GET_SCHEMA : String {static} + INSERT_ORDER : String {static} + JDBC_URL : String {static} + QUERY_ORDER : String {static} + QUERY_ORDERS : String {static} + REMOVE_ORDER : String {static} + createSchema() : boolean {abstract} + deleteSchema() : boolean {abstract} + getSchema() : String {abstract} + insertOrder(Order) : boolean {abstract} + queryOrder(int) : Order {abstract} + queryOrders() : Stream {abstract} + removeOrder(int) {abstract} } class Order { - id : int - item : String - orderedBy : String - shippingAddress : ShippingAddress + Order() + Order(id : int, item : String, orderedBy : String, shippingAddress : ShippingAddress) + Order(item : String, orderedBy : String, shippingAddress : ShippingAddress) + getId() : int + getItem() : String + getOrderedBy() : String + getShippingAddress() : ShippingAddress + setId(id : int) + setItem(item : String) + setOrderedBy(orderedBy : String) + setShippingAddress(shippingAddress : ShippingAddress) + toString() : String } class ShippingAddress { - city : String - pincode : String - state : String + ShippingAddress() + ShippingAddress(city : String, state : String, pincode : String) + getCity() : String + getPincode() : String + getState() : String + setCity(city : String) + setPincode(pincode : String) + setState(state : String) + toString() : String } } Order --> "-shippingAddress" ShippingAddress DataSource ..|> DataSourceInterface @enduml