Find Jobs
Hire Freelancers

File Handling in Java

$30-100 USD

Cerrado
Publicado hace casi 18 años

$30-100 USD

Pagado a la entrega
Write a program, which imitates a simple organizer. This organizer will be used to create, keep, view and delete names, phone numbers and birthdates of your friends. The information must be stored in the file “[login to view URL]”. Task A Create a design for your program from the following specifications: • class Person which contains the fields for name, surname, phone number, date of birth. Also the class must contain a non-static method “public int compareTo(Person p)” that compares lexicographically full names of the current person object you called the method on and the person p which is passed as a parameter to the method. It should return +1, 0, or –1 depending on whether the current person’s name comes earlier, is the same or comes later in the lexicographical order as that of the parameter p. • class Date, objects of which represent dates. It must contain three integer fields for day, month, and year. Also the class must contain a non-static method “public int compareTo(Date d)” that compares the date represented by the current date object you called the method on with the date represented by the parameter passed to the method. It should return +1, 0, or –1 depending on whether the current date is earlier, is the same or is later then the date represented by the parameter p. Both classes must implement Serializable interface. The compareTo methods are used for sorting. Task B Create a class Organizer (extends JFrame), which opens the file “[login to view URL]” (if the file does not exist program must create it) and outputs information stored in the file in the following Organizer: All Person objects stored in the file “[login to view URL]” are displayed in JList with scrollbar. When you choose some element from the JList, information about corresponding person displays in the form. You can sort persons either by Full Name (lexicographically) or by Date of Birth clicking appropriate radio buttons. You also can delete several items from the JList by clicking the Delete button. You can undo the last delete by clicking the Undo button. If you close the form (by clicking either the Close button or x button), current information will be written to “[login to view URL]” file. To input information about a person you must click the “Create Entry” button in the Organizer. In this case the following modal JDialog “Input Form” appears on the screen (class InputDialog extending JDialog). You can fill the text fields of the form with the information of the person. If everything is correct click Write, otherwise click Cancel. In both cases all text fields become clear, but in the first case information is stored, in the second is discarded. Clicking the Close button or x-button of the “Input Form” makes the dialog invisible, and all the changes made are displayed in the “View Form”. Note:- GUI images for the project attached in a word document. Just have a look. This program must be done in Eclipse.
ID del proyecto: 65784

Información sobre el proyecto

19 propuestas
Proyecto remoto
Activo hace 17 años

¿Buscas ganar dinero?

Beneficios de presentar ofertas en Freelancer

Fija tu plazo y presupuesto
Cobra por tu trabajo
Describe tu propuesta
Es gratis registrarse y presentar ofertas en los trabajos

Sobre este cliente

Bandera de INDIA
Ahmedabad, India
5,0
2
Miembro desde jun 6, 2006

Verificación del cliente

¡Gracias! Te hemos enviado un enlace para reclamar tu crédito gratuito.
Algo salió mal al enviar tu correo electrónico. Por favor, intenta de nuevo.
Usuarios registrados Total de empleos publicados
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Cargando visualización previa
Permiso concedido para Geolocalización.
Tu sesión de acceso ha expirado y has sido desconectado. Por favor, inica sesión nuevamente.