Abcd

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 1

I.

SƠ ĐỒ LỚP

Appt
Account
IDAppt
IDAccount
IDAccount
1 n
Username
NameAppt
Pwd
LocationAppt

TimeStart

TimeEnd

Reminder

IsMeeting

Meeting

IDMeeting

IDAppt

IDAccount

II. SEQUENCE DIAGRAM

:LoginForm :AccountBLL :AccountDAL :MainForm

Enter username, pwd

CheckAccountBLL(username, pwd)
GetAllAccountDAL()

listAccount
account

[account != null]showMainForm()

[account == null]showError()

ADD APPT

:MainForm :Appointment_BLL :Appointment_DAL

Login

AddAppt_Click
<<create>>
:AddForm

Enter information
checkValid()

alt
[Valid information]
CheckSameApptNotMeetingByIDAcc_BLL()

GetAllApptNotMeetingByIDAcc_DAL

listAppt
appt

alt [appt != null] (exist appt that is not a meeting with same time)

alt [If appt is not a meeting] Ask to choose another time or update appt

choose yes
UpdateAppt_BLL()
UpdateAppt_DAL()
choose no

[else]
Show ("You have an appt at this time")

IsSameMeetingCreateOrAttend_BLL()

GetAllApptMtByIDAcc_DAL()

GetAllApptMtByIDAcc_DAL()

list
result

alt [result == true] (exist at least 1 meeting with same time and same name that was both created and joined by you)

Show ("You have an meeting at this time")

GetSameApptMeetingNotByIDAcc_BLL()

GetAllApptMeetingNotByIDAcc_DAL

listAppt
list appt

alt [listAppt.Count != 0 && isMeeting] (exist other meetings that are created by others with same time and same name)

Ask to join one of other meetings

alt [Yes]
<<create>>
:SameTimeMeetingForm

Ask to join one of same meetings

choose yes JoinMeetingOfOther_BLL()

JoinMeetingOfOther_DAL()
choose no
CloseForm()

<<Destroy>>

[No]
AddApptMeeting_BLL()
AddApptMeeting_DAL()

[else] (appt is not a meeting or no meetings at this time)


AddAppt_BLL()
AddAppt_DAL()

[Unvalid information]
Show error

<<Destroy>>

II. COLLABORATION DIAGRAM

3: [account == null] showError


Enter username, pwd 1: account := CheckAccountBLL(username, pwd) 1.1: listAccount := GetAllAccountDAL()

:LoginForm :AccountBLL :AccountDAL


2: [account != null] showMainForm()

:MainForm

2: AddAppt_Click
1: Login

:MainForm

2.4. 2.2:
2: [a Ente
ppt r info
2.4. != nu r 2.1: <<create>>
2.5. 4: [a ll && 2.6:
3.2: ppt appt [unv
[list.C 2.5. != nu alid 2.7: <<destroy>>
ll && is no
ount 2: [re
sult appt t a m infor] Sh
!= 0 == is a eetin ow
&& true] m g] as erro
isM
eetin Show eeting] k to r
g] as ("You show ch oose :AddForm :Appointment_BLL :Appointment_DAL
k to have ("You anot
join a ha her
one mee ve an time 2.4: [valid infor] appt:=CheckSameApptNotMeetingByIDAcc_BLL() 2.4.1: listAppt := GetAllApptNotMeetingByIDAcc_DAL()
of ot ting appt or up
her at th
mee is tim at this date
appt 2.4.2.1: [Choose Yes] UpdateAppt_BLL() 2.4.2.1.2: UpdateAppt_DAL()
ting e") time"
with )
sam 2.3: CheckValid() 2.5: [valid infor] result:=IsSameMeetingCreateOrAttend_BLL() 2.5.1: list:=GetAllMeetingCreateOrAttend_DAL()
e na
me
and 2.5.3: [result = true] list := GetSameApptMeetingNotByIDAcc_BLL() 2.5.3.1: list := GetSameApptMeetingNotByIDAcc_DAL()
sam
e tim
e 2.5.3.2.1.1.1.1: JoinMeetingOfOther_DAL()
2.5.3.2.2.1: addApptMeeting_DAL()

2.5.3.2.1: [Choose Yes] <<create>>


2.5.3.2.3: <<destroy>>

2.5.3.2.1.1.2: [choose no] CloseForm()


2.5.3.2.1.1: ask to join one of same meetings
:SameTimeMeeting
2.5.3.2.2: [choose no] addApptMeeting_BLL()

2.5.3.2.1.1.1: [choose yes] JoinMeetingOfOther_BLL()

You might also like