Click here to Skip to main content
15,902,275 members
Home / Discussions / Java
   

Java

 
AnswerRe: Can some one help me with this school project?? Pin
SoMad16-Jun-12 8:32
professionalSoMad16-Jun-12 8:32 
GeneralRe: Can some one help me with this school project?? Pin
Paul Conrad18-Jun-12 17:50
professionalPaul Conrad18-Jun-12 17:50 
GeneralRe: Can some one help me with this school project?? Pin
SoMad18-Jun-12 17:59
professionalSoMad18-Jun-12 17:59 
GeneralRe: Can some one help me with this school project?? Pin
Paul Conrad18-Jun-12 18:01
professionalPaul Conrad18-Jun-12 18:01 
GeneralRe: Can some one help me with this school project?? Pin
Peter_in_278018-Jun-12 18:10
professionalPeter_in_278018-Jun-12 18:10 
GeneralRe: Can some one help me with this school project?? Pin
Paul Conrad18-Jun-12 18:11
professionalPaul Conrad18-Jun-12 18:11 
GeneralRe: Can some one help me with this school project?? Pin
Peter_in_278018-Jun-12 18:48
professionalPeter_in_278018-Jun-12 18:48 
AnswerRe: Can some one help me with this school project?? Pin
TorstenH.16-Jun-12 20:38
TorstenH.16-Jun-12 20:38 
Sure I'll help you. I formatted the text a bit - it's easier to read that way.

Feel free to come back and ask specific questions. We will help you in defined problems, but we can not do homework. Unless we get paid. well paid.

Java RMI JDBC Programming Practice  
 
Title: Java RMI JDBC Program for Automating and Controlling Access to Buildings 
Delivery Date:  June 25th, 2012 
 
The objective of this  practice  is  to  gain  skills  in  Java distributed programming  and assimilate  the main  concepts  and  techniques  of RMI JDBC programming  and  SQL 
database programming.  
 
An enterprise has a number of buildings in a Campus. Each building has a name that 
identifies it and a number of gates to access it. Buildings have floors. Each floor can be 
accessed  from  different  gates  and  has  a  number  of  rooms  (offices,  labs,  etc.).  The employees of an enterprise are given access to some buildings, and within a building they are given access to some floors and within a floor they are given access to some rooms.  
 
The enterprise is interested to develop software that would automate the controlled 
access  to  buildings  and  would  permit  the  enterprise  to  monitor  the  access  of 
employees, the time the employees stay in the enterprise’s facilities, etc.  
 
You are requested to design and implement a program in Java RMI JDBC that enables 
automatic access of employees to the buildings of the enterprise.  The objective of this 
practice  is  to  develop  a client/server program  in  Java RMI  JDBC that offers  to the employees (remote clients) the following options through a contextual menu 1: 
 
1. Connect a remote client to the server application: A client (employee) requests to 
enter the application by providing its username and its password.  
1.1. if the username and password (verified at the database) are correct, the client 
enters the program and the options are shown to him. 
1.2. the username or password (verified at the database) are incorrect, the server 
should notify "You don’t have access to the application". 
2. If identified correctly, a client (employee) can access any facility he/she has access to 

2  in the enterprise’s facilities. For that, the client is requested to go through the 
following steps: 
2.1. Access to a building:  
2.1.1. the employee is requested to provide: his ID, the name of the building 
and the access gate number of the building. 
2.1.2. based on the data, the server checks if the employee has granted access 
to the building. If yes, he receives the message "Access permitted to 
1 A Graphical User Interface (GUI) is not required, but would be positively evaluated. The GUI can be done following 
a similar example program in the course materials. 

2 In real life scenario the Access would be done with a ID card which stores the data; here we are simulating the process. 
building " If not, he receives the message "You don’t have access to this building " 
2.1.3. The employee can follow next step to enter a floor. 
2.2. Access to a floor:   
2.2.1. the employee is requested to provide the floor number and the access 
gate of the floor. 
2.2.2. based on the data, the server checks if the employee has granted access 
to the floor. If yes, he receives the message "Access permitted to floor " If 
not, he receives the message "You don’t have access to this floor " 
2.2.3. The employee can follow next step to enter a room. 
2.3. Access to a room:   
2.3.1. the employee is requested the room number. 
2.3.2. based on the data, the server checks if the employee has granted access 
to the room. If yes, he receives the message "Access permitted to room Enjoy working"

3 If not, the employee receives the message "You don’t have access to this room " 
3. Disconnect the user from application server: the employee leaves the building. The 
server computes the time the employee has been in, and the employee receives 
the message "You have stayed …. time in the building. Good bye "  
  
For the application, you should design and implement a database. The database should 
have tables to store the following information (and other information that you may 
need for implementing the application):  
• Employees: information on all employees (clients): Id, name, surname, 
username, and password. 
• Buildings: information on buildings and their access gates. 
• Floors: information on floors of a building and their access gates. 
• Rooms: information on rooms of a floor of a building. 
• Accesses: access rights of employees to buildings, floors and rooms 
 
To implement the program follow the steps below: 
 
1. Design and implement the database in postgresql 
2. Define the remote interface (only one remote interface in this case) 
3. Implement the remote interface 
4. Implement a Java server application 
5. Implement a Java client application that uses the remote interface. 
6. Compile all java sources (with javac) and further generate stubs and skeletons (with rmic) 
7. Deploy and run the application (registry, server and one or more clients). For 
running and testing the application you can use the localhost. 

3 At this point, the server saves the entry time. 

Notes: 
o The  practice should be necessarily done in  groups  of  two  students. No 
changes are allowed once groups are established. 
o You can use the java classes and source code of the examples used during 
the course. 

WHAT TO DELIVER: 
You should deliver a zip file named surname1_surname2.zip with the following: 
1. All java source files,  
2. All objects .class files 
3. Two  sql  scripts:  one  for  creating  the  database,  another  one  for  inserting 
registers (rows) in the tables of the database. The name of the database should be AccessControl 
4. The config.properties file 
5. A document (doc or pdf) including: 
a. Title of the practice, authors and delivery date 
b. Problem formulation and main aspects of the proposed solution 
c. UML design 
d. Database design (tables and relations, EntitydRelationship) 
e. A  selfdevaluation,  indicating  which  objectives  of  the  practice  were achieved. 
f. A manual with instructions on how to execute the program 

TO WHOM TO DELIVER: 
Deliver the zip file to Prof Bexhet Kamo 
WHEN TO DELIVER: 
On or before 25th of June 2012
 
CHEATING: 
Attempts at cheating at practice will imply failure to enter the exam. 

regards Torsten
When I'm not working

QuestionWhat are some of the equivalent statements of C# in Java? Pin
atoi_powered13-Jun-12 5:10
atoi_powered13-Jun-12 5:10 
AnswerRe: What are some of the equivalent statements of C# in Java? Pin
Nagy Vilmos13-Jun-12 5:53
professionalNagy Vilmos13-Jun-12 5:53 
GeneralRe: What are some of the equivalent statements of C# in Java? Pin
atoi_powered13-Jun-12 7:42
atoi_powered13-Jun-12 7:42 
AnswerRe: What are some of the equivalent statements of C# in Java? Pin
Richard MacCutchan13-Jun-12 6:38
mveRichard MacCutchan13-Jun-12 6:38 
AnswerRe: What are some of the equivalent statements of C# in Java? Pin
TorstenH.13-Jun-12 19:07
TorstenH.13-Jun-12 19:07 
Questionvoice recognition Pin
Nileshbhoi12-Jun-12 21:11
Nileshbhoi12-Jun-12 21:11 
AnswerRe: voice recognition Pin
Richard MacCutchan12-Jun-12 22:05
mveRichard MacCutchan12-Jun-12 22:05 
AnswerRe: voice recognition Pin
Bernhard Hiller12-Jun-12 23:19
Bernhard Hiller12-Jun-12 23:19 
AnswerRe: voice recognition Pin
Manfred Rudolf Bihy13-Jun-12 0:11
professionalManfred Rudolf Bihy13-Jun-12 0:11 
Questionjava Pin
Basavaraj Neelagund11-Jun-12 18:58
Basavaraj Neelagund11-Jun-12 18:58 
AnswerRe: java Pin
Richard MacCutchan11-Jun-12 22:19
mveRichard MacCutchan11-Jun-12 22:19 
AnswerRe: java Pin
CodingLover11-Jun-12 22:29
CodingLover11-Jun-12 22:29 
Questionresponse to the execution of an commande by code java Pin
ahmadiss8-Jun-12 6:00
ahmadiss8-Jun-12 6:00 
AnswerRe: response to the execution of an commande by code java Pin
TorstenH.8-Jun-12 8:13
TorstenH.8-Jun-12 8:13 
GeneralRe: response to the execution of an commande by code java Pin
jschell8-Jun-12 11:55
jschell8-Jun-12 11:55 
AnswerRe: response to the execution of an commande by code java Pin
jschell8-Jun-12 11:59
jschell8-Jun-12 11:59 
Questionjava Pin
ssachin5797-Jun-12 20:50
ssachin5797-Jun-12 20:50 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.