Thesaurus (Swing, JDBC, SQLite)

Download Sources

Example of how to use generated data access code

DataStoreManager dm = new DataStoreManager();

dm.open();

ThesaurusDao dao = dm.createThesaurusDao();

List<Word> words = dao.getWordsByKey(key);

// process the list 

dm.close();

XML meta-program

<dto-classes>		
	<dto-class name="Word" ref="WORDS">
		<field java-type="Integer" column="W_ID" />
		<field java-type="String" column="W_WORD" />
	</dto-class>
	<dto-class name="RelatedWord" ref="getRelatedWords.sql" />
</dto-classes>
<dao-class>		
	<query ref="getTotalWordsCount.sql"
		method="getTotalWordsCount" return-type="Integer" />
	<query-dto-list ref="getWordsByKey.sql" dto="Word"
		method="getWordsByKey(key)" />
	<query-dto-list ref="getRelatedWords.sql" dto="RelatedWord"
		method="getRelatedWords(Integer w_id)" />
</dao-class>