LOGO E-Accountant Sys. By 潘潘 , 潘潘潘 , 潘潘潘 Silver Moon Corp. ebank.miho.cn
LOGO
E-Accountant Sys.E-Accountant Sys.
By 潘旎 , 刘明慧 , 汪之旻
Silver Moon Corp.
ebank.miho.cn
Contents
E-Accountant System Overview1
Design Pattern && Architecture2
Highlights of the System3
Special Thanks4
E-Accountant System Overview
Brief Description
The E-Accountant System enables the banks to reduce their unnecessary manual work while providing remote services and on-line management. It also enables the bank to serve as long as 24 hours and will definitely increase the efficiency.
Use-Case Diagram
Inquire card info
Revoke maincard
Revoke subcards
Apply maincard
Apply subcards
LogOff
LogOn
Set password
Consume
Pay off loans
User
Admi n
Consumer
I nqUser
总体上用户被我们分为三类:
Consumer,Admin,InqUser
主要按照登陆的机器来区分操作权限,具体实现上用接口加以限制
1.Services in Bank
•Create an Account•Apply for a sub credit card•Change the card password
•Revoke Sub card•Revoke the Account•Pay off the debt•Change the view password
Operations
Demo
Activity Diagram
VOPC for the bank Service
1 0..*
1
0..*
1
0..*
1
1
0..*
1
<<control>>
ApplyCardcontrol
+++
//create e-account ()//create password ()//createSubCardid ()
: int: int: int
<<boundary>>
ApplyCardForm
++++
//show msg ()//show card id ()//show log state ()//show enter password ()
: int: int: int: int
<<entity>>
Card
+ //new card () : int
<<controller>>
Server
++++
//create card id ()//create e-account ()//update password ()//create a person ()
: int: int: int: int
<<entity>>
user
+++++
//apply card ()//logout card ()//change card password ()//apply sub-card ()//logout sub-card ()
: void: int: int: int: int
SSD for the bank Service
1: //CreateE-Account
2: //Create E-Account
6: //show card id
7: //create password(pwd)
8: //create password(pwd)9: //create passward (pwd)
3: //create E-Account
5: //create user(card)
4: //create card
10: //show success
Admin
<<Boundary>>
ApplyCardForm
<<coutroller>>
ApplyCardControl
<<entity>>
Card
<<entity>>
user
<<controller>>
Server
1: //CreateE-Account
2: //Create E-Account
6: //show card id
7: //create password(pwd)
8: //create password(pwd)9: //create passward (pwd)
3: //create E-Account
5: //create user(card)
4: //create card
10: //show success
2.Services in POS.
Check the authorityCheck the authority Remote consumeRemote consume Record the event in cardRecord the event in card
Login Consume Records
Demo ConsumptionDemo Consumption
2.Services in POS.
Activity Diagram >>>
SSD >>>
VOPC for Remote Consume Service
1 1
1 0..*
0..*
1
0..1
0..1
1 1..*
<<boundary>>
ConsumerClientForm
+++++++++
//check numbers(numbers) ()//prompt user to enter password() ()//check password(psw) ()//display money available() ()//prompt user to enter money needed() ()//check if consume(money) ()//transfer money() ()//record consuming(adress) ()//dispaly success() ()
: Boolean: void: Boolean: void: void: Boolean: Boolean: Boolean: void
<<control>>
ConsumerClientController
+++++
//check numbers(numbers) ()//check password(psw) ()//check if consume(money) ()//transfer money() ()//record consuming(adress) ()
: Boolean: Boolean: Boolean: Boolean: Boolean
<<control>>
Sever
++++++
//check numbers(numbers) ()//check password(psw) ()//check if consume(money) ()//transfer money() ()//create a record(adress) ()//add a record(record) ()
: Boolean: Boolean: Boolean: Boolean: record: Boolean
<<entity>>
Card
<<entity>>
Record<<entity>>
User
3.Service in the Internet
ResetSub cardPassword
RevokeSub card
Apply a Sub card
View the Account credit
Inquire Account
information
Demo Web Service
ebank.miho.cn
Software Pattern
Brief Description
We use the observer pattern to design our system.
We divide the system into three layers. They are view layer, control layer and model layer, which is the classical structure of MVC architecture.
E-Accountant System Overview
LAN
Internet
LAN
Internet
Bank serverE-Accountant
ServerE-Accountant/user-defined
Database
PCE-AccountantConsumer Client
PCE-AccountantInquiry Client
PCE-Accountant Bank Service System Administrator
Bank E-Accountant System Overview
Domain Model
1..1
1..1
1..1
1..1
1..1
1..1
1..1
1..1
0..*
1..1
0..1 1..1
1..1
1..1
1..1
1..1
1..1
1..1
0..1
0..*
Client
AdminClient ConsumerClientInqClient
UserAdmin Card
Record
MainCard SubCard
VOPC for the Sys.
0. . 10. . *
0. . 1
0. . *
0. . 10. . *
0. . 10. . *
0. . 1
0. . *
0. . 1
0. . *
0. . 1
0. . *
0. . 1
0. . *
0. . 1
0. . * 0. . 1
0. . *
0. . 1
0. . *
0. . 1
0. . *
0. . 1
0. . *
DBI O(DBI O)
+++++
DBI O(St r i ng x) ( )ReadUser( l ong I D) ( )Wri teUser( l ong I D) ( )Del eteUser( l ong I D) ( )SeekCardI D( l ong cardi d) ( )
: voi d: St r i ng: bool ean: bool ean: l ong
DBS(DBS)
- Temp : User I
+##+++++++++++++
Setmpsw( l ong cardi d, l ong password) ( )SeekI D( l ong i d) ( )LoadDataI D( l ong i d) ( )Chkvpsw( l ong i d, l ong psw) ( )Chkspsw( l ong cardi d, l ong psw) ( )SeekCardI D( l ong cardi d) ( )get I ni tData( l ong i d) ( )Appl yCardI D( l ong i d) ( )RevokeMai nCard( l ong i d) ( )get I nqData( l ong i d) ( )Setspsw( l ong cardi d, l ong psw) ( )Setvpsw( l ong cardi d, l ong psw) ( )RevokeCardI D( l ong cardi d, l ong password) ( )Chkmpsw( l ong i d, l ong password) ( )Pay( l ong money) ( )Consume( l ong i d, l ong money, l ong mci d) ( )
: bool ean: bool ean: bool ean: bool ean: bool ean: l ong: St r i ng: bool ean: St r i ng: St r i ng: bool ean: bool ean: St r i ng: bool ean: bool ean: bool ean
<<Control >>I nqCl i entCont rol l er
(Cl i ent )
#+++++++
RequestAndRecei ve(St r i ng x) ( )LogOff ( ) ( )LogOn( ) ( )Revoke( ) ( )I nqui re( ) ( )Appl y( ) ( )SetPassword( ) ( )I ni tData( ) ( )
: St r i ng: bool ean: i nt: St r i ng: St r i ng: St r i ng: St r i ng: St r i ng
<<Boundary>>I nqCl i entForm
(Cl i ent )
Mai nCard(Mai ncard)
--
subcardsrecords
: SubCard: Record
++++++++++
pri ntData( ) ( )revoke( ) ( )revokesub( l ong cardi d) ( )appl y( l ong cardi d) ( )get I ni tData( ) ( )checkvpsw( l ong password) ( )checkpsw( l ong cardi d, l ong password) ( )setpassword( l ong cardi d, l ong password) ( )setvpsw( l ong password) ( )Consume( i nt i d, i nt money, i nt mci d) ( )
: St r i ng: bool ean: bool ean: bool ean: St r i ng: bool ean: bool ean: bool ean: bool ean: bool ean
Record(Record)
----
Locat i onTi mecar i dMoney
: St r i ng: l ong: l ong: l ong
+++++
pri ntcard( ) ( )getTi me( ) ( )getMoney( ) ( )Record(St r i ng x) ( )Consume( i nt i d, i nt money, i nt mci d) ( )
: St r i ng: l ong: l ong: Record: bool ean
Server(Server)
++++
Regi ster I D( l ong i d, l ong password) ( )Repl y(St r i ng x) ( )I ni tData( ) ( )LogOff ( ) ( )
: bool ean: St r i ng: bool ean: bool ean
SubCard(SubCard)
- records : Record
++++++
revoke( ) ( )pr i ntData( ) ( )checkpsw( l ong password) ( )setpsw( l ong password) ( )SubCard(St r i ng x) ( )Consume( i nt i d, i nt money, i nt mci d) ( )
: bool ean: St r i ng: bool ean: bool ean: SubCard: i nt
<<Ent i ty>>User
(User)
- mc : Mai nCard
++++++++++++++
pri ntData( ) ( )i ni tData( ) ( )getCredi t ( ) ( )revokemai n( ) ( )revokesub( l ong cardi d) ( )appl y( l ong cardi d) ( )setmai nvpsw( l ong psw) ( )setpsw( l ong cardi d, l ong psw) ( )checkvpsw( l ong psw) ( )checkpsw( l ong cardi d, l ong psw) ( )setvpsw( l ong psw) ( )ReadUser( l ong i d) ( )Pay( i nt money) ( )Consume( i nt i d, i nt money, i nt mci d) ( )
: St r i ng: St r i ng: i nt: bool ean: bool ean: bool ean: bool ean: bool ean: bool ean: bool ean: bool ean: User I: bool ean: bool ean
User I
Observer Design Pattern
ServerDataBase
Observer and Observable
ApplyView
RevokeView
PayOffView
ChangeView
View6
MVC Architecture Pattern
Presentation Layer
V
We put all the swing graphical presentation components and JSP files in this layer when designing the windows forms and the web pages.
C
We design an abstract controller class to play the control role in this program, which is heritaged by a class named buttonctrl.In JSP, we make JavaBean functions in this layer.
Logic Layer
M
Data Layer
In this layer, we design a class connecting to dataservice, which can modify the database and notify all the views.
Demo
ObservableObserver
Wmvc Framework
JSP
Window Form(Bank Client)
Highlights of the System
The Network VersionThe Network VersionThe Network VersionThe Network Version
Java MailUsing RMIto interact
Web Server
Using XML to Store
Data
XML Serialization
Details We use a middle library called XStream to serialize objects
to XML and back again. Here our projects coding:public class User extends UserI
{
protected String UserName;
protected int ID;
protected double account=0;
protected static double credit=5000;
protected MainCard mc=null;
……
}
When it serialize to XML, it can be shown:
demo.xml
back
Web Server
Details
Using JSP to design the presentation layer of the program.
Using JavaBean to control the business handlers.
Using tomcat 5.5 to configure the server Using Lomboz to edit the jsp files. Using session to confirm that these web pages
can not be visited unless the user has log in.
back
RMI
Details
We use RMI to connect POS and Server, E-Account Bank System and Server.
IAccountModel a = new RAccountModel(); IConsumeModel c =new RConsumeModel(); LocateRegistry.createRegistry(1099); Naming.rebind("rmi://localhost:1099/Service", a);
Naming.rebind("rmi://localhost:1099/Service2", c);
IAccountModel is the bank system remote interfaceIConsumeModel is the POS remote interface
In the client,we make the model class to use these interface.
back
JAVA MAIL
Details
we using the javamail api which can be found in J2EE to write a Mail Client. It can connect to some SMTP Server Provider and send mail to anyone else's mail box.
In this project, once the client apply or revoke a sub-card, change the card password, we'll send the email to notify him these changes. On the 25th day of every month, we will send the bills to every account by email.
back
About Our Team
Develop the MVC architecture
of the bank System.
Develop the Email Client
Develop the RMI remote Services
Develop the MVC architecture
of the bank System.
Develop the Email Client
Develop the RMI remote Services
Make the MVC architecture of
POS system.
The developer of JSP web page.
Make the MVC architecture of
POS system.
The developer of JSP web page.
Develop the DBS system
develop the file IO
develop the XML Serialize
Make the thread Operation
Develop the DBS system
develop the file IO
develop the XML Serialize
Make the thread Operation
汪之旻汪之旻 潘旎潘旎 刘明慧刘明慧
Special Thanks
Special Thanks for the instructions of our dear teacher Rao.
We really appreciate all the help from our lovely TAs.
Also, we are very grateful for all the help we got from our classmates.
LOGO
ebank.miho.cn