Welcome to the Java Programming Forums


The professional, friendly Java community. 21,500 members and growing!


The Java Programming Forums are a community of Java programmers from all around the World. Our members have a wide range of skills and they all have one thing in common: A passion to learn and code Java. We invite beginner Java programmers right through to Java professionals to post here and share your knowledge. Become a part of the community, help others, expand your knowledge of Java and enjoy talking with like minded people. Registration is quick and best of all free. We look forward to meeting you.


>> REGISTER NOW TO START POSTING


Members have full access to the forums. Advertisements are removed for registered users.

Results 1 to 2 of 2

Thread: Help needed on a ride - sharing app development project. I need a Mentor/Coach.

  1. #1
    Junior Member
    Join Date
    May 2022
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Help needed on a ride - sharing app development project. I need a Mentor/Coach.

    Project (In progress) - Thanks for helping me.

    Your ride-sharing app/taxi driver.
    *
    * TODO Requirements:
    * 1. Create a constructor that takes a Vehicle object to store as
    * the instance variable 'vehicle' but you also need a no-argument constructor.
    * You must have one constructor Driver() and another constructor Driver(Vehicle)
    *
    * 2. Implement the 'drive' method so that it tells the vehicle to drive. Since vehicle has
    * a drive method, you only need to call this method. This is called the delegation pattern.
    *
    * 3. The Driver is-a User, so they also have 'name' and 'email' properties. Hint: extend User
    *
    * 4. Ensure this class is properly encapsulated with getters/setters for each field.
    * Hint: Getters and setters must conform to JavaBean specification.
    * Use the Ride class as an example for how to write these methods properly.
    * You should not have any public variables in this class. All fields must be private.
    */
    public class Driver {

    public Driveable vehicle;

    public void drive() {
    // drive the vehicle
    }

    }

    pulic class Vehicle {

    private int value;
    }

  2. #2
    Junior Member
    Join Date
    Nov 2023
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Re: Help needed on a ride - sharing app development project. I need a Mentor/Coach.

    I see no one responded.. Did you manage to work this out? I am stuck trying to do the same thing. I am not asking for someone to do it but help me figure it out.
    Thanks.

Similar Threads

  1. Hello There Java Mentor Needed
    By smatt in forum Member Introductions
    Replies: 1
    Last Post: July 8th, 2014, 07:16 AM
  2. [PROJECT] Java MMORPG Development
    By Quasar in forum The Cafe
    Replies: 11
    Last Post: February 21st, 2013, 03:48 PM
  3. Help needed for some Java Development
    By rizzy73 in forum What's Wrong With My Code?
    Replies: 3
    Last Post: January 17th, 2013, 08:28 AM
  4. My project development issues ?
    By kaliyaodi in forum Java Theory & Questions
    Replies: 5
    Last Post: December 6th, 2011, 11:16 AM

Tags for this Thread