public void add ( final ITopicNode specTopic , final String key ) { if ( specTopic == null ) return ; final Integer topicId = specTopic . getDBId ( ) ; if ( ! topics . containsKey ( topicId ) ) { topics . put ( topicId , new LinkedList < ITopicNode > ( ) ) ; } // Make sure the key exists if ( ! topicsKeys . containsKey ( key ) ) { topicsKeys . put ( key , new LinkedList < ITopicNode > ( ) ) ; } topics . get ( topicId ) . add ( specTopic ) ; topicsKeys . get ( key ) . add ( specTopic ) ; }
Add a SpecTopic to the database .