Class TopicHome


  • public final class TopicHome
    extends Object
    This class provides instances management methods (create, find, ...) for Topic objects
    • Method Detail

      • create

        public static Topic create​(Topic topic)
        Create an instance of the topic class
        Parameters:
        topic - The instance of the Topic which contains the informations to store
        Returns:
        The instance of topic which has been created with its primary key.
      • update

        public static Topic update​(Topic topic)
        Update of the topic which is specified in parameter
        Parameters:
        topic - The instance of the Topic which contains the data to store
        Returns:
        The instance of the topic which has been updated
      • remove

        public static void remove​(int nTopicId)
        Remove the topic whose identifier is specified in parameter
        Parameters:
        nTopicId - The topic Id
      • findByPrimaryKey

        public static Topic findByPrimaryKey​(int nKey)
        Returns an instance of a topic whose identifier is specified in parameter
        Parameters:
        nKey - The topic primary key
        Returns:
        an instance of Topic
      • findByPrimaryKey

        public static Topic findByPrimaryKey​(String strTopicName)
        Find a topic by it's primary key
        Parameters:
        strTopicName - The topic name
        Returns:
        The topic
      • getTopicsList

        public static Collection<Topic> getTopicsList()
        Load the data of all the topic objects and returns them in form of a collection
        Returns:
        the collection which contains the data of all the topic objects