Package core.system

Class MyVelibSystemFactory


  • public class MyVelibSystemFactory
    extends java.lang.Object
    The MyVelibSystemFactory class : This class is responsible for creating the new system on the core.Main application (the application itself) It is used to implement the Factory design pattern (but, here due to time and design constraints, we used the simple factory)
    • Constructor Detail

      • MyVelibSystemFactory

        public MyVelibSystemFactory()
    • Method Detail

      • createMyVelibSystem

        public static MyVelibSystem createMyVelibSystem​(java.util.List<Station> stations,
                                                        java.util.List<User> users,
                                                        double money)
        Method for creating a new system in the core main application
        Parameters:
        stations - a list of stations
        users - a list of users
        money - an amount of money for the (new) system
        Returns:
        the system created
      • createMyVelibSystem

        public static MyVelibSystem createMyVelibSystem()
        (Simpler) method for creating a new system in the core main application
        Returns:
        the system created
      • createMyVelibSystem

        public static MyVelibSystem createMyVelibSystem​(java.util.List<Station> stations)
        (Intermediate) method for creating a new system in the core main application
        Parameters:
        stations - a list of stations
        Returns:
        the (new) system