Class UserFactory

  • All Implemented Interfaces:
    UserConfig

    public class UserFactory
    extends UserManager

    UserFactory class.

    Version:
    $Id: $
    Author:
    ranger
    • Constructor Detail

      • UserFactory

        public UserFactory()
                    throws java.io.FileNotFoundException,
                           java.io.IOException
        Initializes the factory
        Throws:
        java.io.IOException - if any.
        java.io.FileNotFoundException - if any.
    • Method Detail

      • init

        public static void init()
                         throws java.io.IOException,
                                java.io.FileNotFoundException

        init

        Throws:
        java.io.IOException - if any.
        java.io.FileNotFoundException - if any.
      • getInstance

        public static UserManager getInstance()
        Singleton static call to get the only instance that should exist for the UserFactory
        Returns:
        the single user factory instance
      • setInstance

        public static void setInstance​(UserManager mgr)

        Setter for the field instance.

        Parameters:
        mgr - a UserManager object.
      • reload

        public void reload()
                    throws java.io.IOException,
                           java.io.FileNotFoundException

        reload

        Specified by:
        reload in class UserManager
        Throws:
        java.io.IOException - if any.
        java.io.FileNotFoundException - if any.
      • saveXML

        protected void saveXML​(java.lang.String writerString)
                        throws java.io.IOException

        saveXML

        Specified by:
        saveXML in class UserManager
        Parameters:
        writerString - a String object.
        Throws:
        java.io.IOException - if any.
      • isUpdateNeeded

        public boolean isUpdateNeeded()

        isUpdateNeeded

        Specified by:
        isUpdateNeeded in class UserManager
        Returns:
        a boolean.
      • doUpdate

        public void doUpdate()
                      throws java.io.IOException,
                             java.io.FileNotFoundException

        update

        Specified by:
        doUpdate in class UserManager
        Throws:
        java.io.IOException - if any.
        java.io.FileNotFoundException - if any.